* calendar/calendar.el (calendar-generate-month, calendar-font-lock-keywords):
[emacs.git] / autogen / configure
blob3d207e12537113ddcdeef80a7dd3e8ba2c87a860
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_strtoull_FALSE
618 gl_GNULIB_ENABLED_strtoull_TRUE
619 gl_GNULIB_ENABLED_strtoll_FALSE
620 gl_GNULIB_ENABLED_strtoll_TRUE
621 gl_GNULIB_ENABLED_stat_FALSE
622 gl_GNULIB_ENABLED_stat_TRUE
623 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
624 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
625 gl_GNULIB_ENABLED_pathmax_FALSE
626 gl_GNULIB_ENABLED_pathmax_TRUE
627 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
628 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
629 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
630 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
631 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
632 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
633 gl_GNULIB_ENABLED_getgroups_FALSE
634 gl_GNULIB_ENABLED_getgroups_TRUE
635 gl_GNULIB_ENABLED_getdtablesize_FALSE
636 gl_GNULIB_ENABLED_getdtablesize_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 --with-sound=VALUE compile with sound support (VALUE one of: yes,
2237 ossaudio, alsa, no; default yes). Only for
2238 GNU/Linux, FreeBSD, NetBSD, MinGW.
2239 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2240 gtk3, lucid or athena, motif, no)
2241 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2242 --without-xpm don't compile with XPM image support
2243 --without-jpeg don't compile with JPEG image support
2244 --without-tiff don't compile with TIFF image support
2245 --without-gif don't compile with GIF image support
2246 --without-png don't compile with PNG image support
2247 --without-rsvg don't compile with SVG image support
2248 --without-xml2 don't compile with XML parsing support
2249 --without-imagemagick don't compile with ImageMagick image support
2250 --without-xft don't use XFT for anti aliased fonts
2251 --without-libotf don't use libotf for OpenType font support
2252 --without-m17n-flt don't use m17n-flt for text shaping
2253 --without-toolkit-scroll-bars
2254 don't use Motif or Xaw3d scroll bars
2255 --without-xaw3d don't use Xaw3d
2256 --without-xim don't use X11 XIM
2257 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2258 --with-w32 use native MS Windows GUI in a Cygwin build
2259 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2260 console
2261 --without-dbus don't compile with D-Bus support
2262 --without-gconf don't compile with GConf support
2263 --without-gsettings don't compile with GSettings support
2264 --without-selinux don't compile with SELinux support
2265 --without-gnutls don't use -lgnutls for SSL/TLS support
2266 --with-file-notification=LIB
2267 use a file notification library (LIB one of: yes,
2268 gfile, inotify, w32, no)
2269 --without-makeinfo don't require makeinfo for building manuals
2270 --without-compress-info don't compress the installed Info pages
2271 --with-pkg-config-prog=FILENAME
2272 file name of pkg-config for finding GTK and librsvg
2273 --with-gameuser=USER user for shared game score files
2274 --with-gnustep-conf=FILENAME
2275 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2276 or /etc/GNUstep/GNUstep.conf
2277 --with-x use the X Window System
2279 Some influential environment variables:
2280 CC C compiler command
2281 CFLAGS C compiler flags
2282 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2283 nonstandard directory <lib dir>
2284 LIBS libraries to pass to the linker, e.g. -l<library>
2285 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2286 you have headers in a nonstandard directory <include dir>
2287 CPP C preprocessor
2288 XMKMF Path to xmkmf, Makefile generator for X Window System
2290 Use these variables to override the choices made by `configure' or to help
2291 it to find libraries and programs with nonstandard names/locations.
2293 Report bugs to the package provider.
2294 _ACEOF
2295 ac_status=$?
2298 if test "$ac_init_help" = "recursive"; then
2299 # If there are subdirs, report their specific --help.
2300 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2301 test -d "$ac_dir" ||
2302 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2303 continue
2304 ac_builddir=.
2306 case "$ac_dir" in
2307 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2309 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2310 # A ".." for each directory in $ac_dir_suffix.
2311 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2312 case $ac_top_builddir_sub in
2313 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2314 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2315 esac ;;
2316 esac
2317 ac_abs_top_builddir=$ac_pwd
2318 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2319 # for backward compatibility:
2320 ac_top_builddir=$ac_top_build_prefix
2322 case $srcdir in
2323 .) # We are building in place.
2324 ac_srcdir=.
2325 ac_top_srcdir=$ac_top_builddir_sub
2326 ac_abs_top_srcdir=$ac_pwd ;;
2327 [\\/]* | ?:[\\/]* ) # Absolute name.
2328 ac_srcdir=$srcdir$ac_dir_suffix;
2329 ac_top_srcdir=$srcdir
2330 ac_abs_top_srcdir=$srcdir ;;
2331 *) # Relative name.
2332 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2333 ac_top_srcdir=$ac_top_build_prefix$srcdir
2334 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2335 esac
2336 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2338 cd "$ac_dir" || { ac_status=$?; continue; }
2339 # Check for guested configure.
2340 if test -f "$ac_srcdir/configure.gnu"; then
2341 echo &&
2342 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2343 elif test -f "$ac_srcdir/configure"; then
2344 echo &&
2345 $SHELL "$ac_srcdir/configure" --help=recursive
2346 else
2347 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2348 fi || ac_status=$?
2349 cd "$ac_pwd" || { ac_status=$?; break; }
2350 done
2353 test -n "$ac_init_help" && exit $ac_status
2354 if $ac_init_version; then
2355 cat <<\_ACEOF
2356 emacs configure 24.3.50
2357 generated by GNU Autoconf 2.65
2359 Copyright (C) 2009 Free Software Foundation, Inc.
2360 This configure script is free software; the Free Software Foundation
2361 gives unlimited permission to copy, distribute and modify it.
2362 _ACEOF
2363 exit
2366 ## ------------------------ ##
2367 ## Autoconf initialization. ##
2368 ## ------------------------ ##
2370 # ac_fn_c_try_compile LINENO
2371 # --------------------------
2372 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2373 ac_fn_c_try_compile ()
2375 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2376 rm -f conftest.$ac_objext
2377 if { { ac_try="$ac_compile"
2378 case "(($ac_try" in
2379 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2380 *) ac_try_echo=$ac_try;;
2381 esac
2382 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2383 $as_echo "$ac_try_echo"; } >&5
2384 (eval "$ac_compile") 2>conftest.err
2385 ac_status=$?
2386 if test -s conftest.err; then
2387 grep -v '^ *+' conftest.err >conftest.er1
2388 cat conftest.er1 >&5
2389 mv -f conftest.er1 conftest.err
2391 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2392 test $ac_status = 0; } && {
2393 test -z "$ac_c_werror_flag" ||
2394 test ! -s conftest.err
2395 } && test -s conftest.$ac_objext; then :
2396 ac_retval=0
2397 else
2398 $as_echo "$as_me: failed program was:" >&5
2399 sed 's/^/| /' conftest.$ac_ext >&5
2401 ac_retval=1
2403 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2404 as_fn_set_status $ac_retval
2406 } # ac_fn_c_try_compile
2408 # ac_fn_c_try_cpp LINENO
2409 # ----------------------
2410 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2411 ac_fn_c_try_cpp ()
2413 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2414 if { { ac_try="$ac_cpp conftest.$ac_ext"
2415 case "(($ac_try" in
2416 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2417 *) ac_try_echo=$ac_try;;
2418 esac
2419 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2420 $as_echo "$ac_try_echo"; } >&5
2421 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2422 ac_status=$?
2423 if test -s conftest.err; then
2424 grep -v '^ *+' conftest.err >conftest.er1
2425 cat conftest.er1 >&5
2426 mv -f conftest.er1 conftest.err
2428 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2429 test $ac_status = 0; } >/dev/null && {
2430 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2431 test ! -s conftest.err
2432 }; then :
2433 ac_retval=0
2434 else
2435 $as_echo "$as_me: failed program was:" >&5
2436 sed 's/^/| /' conftest.$ac_ext >&5
2438 ac_retval=1
2440 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2441 as_fn_set_status $ac_retval
2443 } # ac_fn_c_try_cpp
2445 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2446 # -------------------------------------------------------
2447 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2448 # the include files in INCLUDES and setting the cache variable VAR
2449 # accordingly.
2450 ac_fn_c_check_header_mongrel ()
2452 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2453 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2455 $as_echo_n "checking for $2... " >&6; }
2456 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2457 $as_echo_n "(cached) " >&6
2459 eval ac_res=\$$3
2460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2461 $as_echo "$ac_res" >&6; }
2462 else
2463 # Is the header compilable?
2464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2465 $as_echo_n "checking $2 usability... " >&6; }
2466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2467 /* end confdefs.h. */
2469 #include <$2>
2470 _ACEOF
2471 if ac_fn_c_try_compile "$LINENO"; then :
2472 ac_header_compiler=yes
2473 else
2474 ac_header_compiler=no
2476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2478 $as_echo "$ac_header_compiler" >&6; }
2480 # Is the header present?
2481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2482 $as_echo_n "checking $2 presence... " >&6; }
2483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2484 /* end confdefs.h. */
2485 #include <$2>
2486 _ACEOF
2487 if ac_fn_c_try_cpp "$LINENO"; then :
2488 ac_header_preproc=yes
2489 else
2490 ac_header_preproc=no
2492 rm -f conftest.err conftest.$ac_ext
2493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2494 $as_echo "$ac_header_preproc" >&6; }
2496 # So? What about this header?
2497 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2498 yes:no: )
2499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2500 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2501 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2502 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2504 no:yes:* )
2505 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2506 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2507 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2508 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2509 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2510 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2512 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2513 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2514 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2516 esac
2517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2518 $as_echo_n "checking for $2... " >&6; }
2519 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2520 $as_echo_n "(cached) " >&6
2521 else
2522 eval "$3=\$ac_header_compiler"
2524 eval ac_res=\$$3
2525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2526 $as_echo "$ac_res" >&6; }
2528 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2530 } # ac_fn_c_check_header_mongrel
2532 # ac_fn_c_try_run LINENO
2533 # ----------------------
2534 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2535 # that executables *can* be run.
2536 ac_fn_c_try_run ()
2538 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2539 if { { ac_try="$ac_link"
2540 case "(($ac_try" in
2541 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2542 *) ac_try_echo=$ac_try;;
2543 esac
2544 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2545 $as_echo "$ac_try_echo"; } >&5
2546 (eval "$ac_link") 2>&5
2547 ac_status=$?
2548 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2549 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2550 { { case "(($ac_try" in
2551 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2552 *) ac_try_echo=$ac_try;;
2553 esac
2554 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2555 $as_echo "$ac_try_echo"; } >&5
2556 (eval "$ac_try") 2>&5
2557 ac_status=$?
2558 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2559 test $ac_status = 0; }; }; then :
2560 ac_retval=0
2561 else
2562 $as_echo "$as_me: program exited with status $ac_status" >&5
2563 $as_echo "$as_me: failed program was:" >&5
2564 sed 's/^/| /' conftest.$ac_ext >&5
2566 ac_retval=$ac_status
2568 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2569 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2570 as_fn_set_status $ac_retval
2572 } # ac_fn_c_try_run
2574 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2575 # -------------------------------------------------------
2576 # Tests whether HEADER exists and can be compiled using the include files in
2577 # INCLUDES, setting the cache variable VAR accordingly.
2578 ac_fn_c_check_header_compile ()
2580 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2582 $as_echo_n "checking for $2... " >&6; }
2583 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2584 $as_echo_n "(cached) " >&6
2585 else
2586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2587 /* end confdefs.h. */
2589 #include <$2>
2590 _ACEOF
2591 if ac_fn_c_try_compile "$LINENO"; then :
2592 eval "$3=yes"
2593 else
2594 eval "$3=no"
2596 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2598 eval ac_res=\$$3
2599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2600 $as_echo "$ac_res" >&6; }
2601 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2603 } # ac_fn_c_check_header_compile
2605 # ac_fn_c_try_link LINENO
2606 # -----------------------
2607 # Try to link conftest.$ac_ext, and return whether this succeeded.
2608 ac_fn_c_try_link ()
2610 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2611 rm -f conftest.$ac_objext conftest$ac_exeext
2612 if { { ac_try="$ac_link"
2613 case "(($ac_try" in
2614 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2615 *) ac_try_echo=$ac_try;;
2616 esac
2617 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2618 $as_echo "$ac_try_echo"; } >&5
2619 (eval "$ac_link") 2>conftest.err
2620 ac_status=$?
2621 if test -s conftest.err; then
2622 grep -v '^ *+' conftest.err >conftest.er1
2623 cat conftest.er1 >&5
2624 mv -f conftest.er1 conftest.err
2626 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2627 test $ac_status = 0; } && {
2628 test -z "$ac_c_werror_flag" ||
2629 test ! -s conftest.err
2630 } && test -s conftest$ac_exeext && {
2631 test "$cross_compiling" = yes ||
2632 $as_test_x conftest$ac_exeext
2633 }; then :
2634 ac_retval=0
2635 else
2636 $as_echo "$as_me: failed program was:" >&5
2637 sed 's/^/| /' conftest.$ac_ext >&5
2639 ac_retval=1
2641 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2642 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2643 # interfere with the next link command; also delete a directory that is
2644 # left behind by Apple's compiler. We do this before executing the actions.
2645 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2646 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2647 as_fn_set_status $ac_retval
2649 } # ac_fn_c_try_link
2651 # ac_fn_c_check_decl LINENO SYMBOL VAR
2652 # ------------------------------------
2653 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2654 ac_fn_c_check_decl ()
2656 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2658 $as_echo_n "checking whether $2 is declared... " >&6; }
2659 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2660 $as_echo_n "(cached) " >&6
2661 else
2662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2663 /* end confdefs.h. */
2666 main ()
2668 #ifndef $2
2669 (void) $2;
2670 #endif
2673 return 0;
2675 _ACEOF
2676 if ac_fn_c_try_compile "$LINENO"; then :
2677 eval "$3=yes"
2678 else
2679 eval "$3=no"
2681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2683 eval ac_res=\$$3
2684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2685 $as_echo "$ac_res" >&6; }
2686 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2688 } # ac_fn_c_check_decl
2690 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2691 # ----------------------------------------------
2692 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2693 ac_fn_c_check_header_preproc ()
2695 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2697 $as_echo_n "checking for $2... " >&6; }
2698 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2699 $as_echo_n "(cached) " >&6
2700 else
2701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2702 /* end confdefs.h. */
2703 #include <$2>
2704 _ACEOF
2705 if ac_fn_c_try_cpp "$LINENO"; then :
2706 eval "$3=yes"
2707 else
2708 eval "$3=no"
2710 rm -f conftest.err conftest.$ac_ext
2712 eval ac_res=\$$3
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2714 $as_echo "$ac_res" >&6; }
2715 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2717 } # ac_fn_c_check_header_preproc
2719 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2720 # ----------------------------------------------------
2721 # Tries to find if the field MEMBER exists in type AGGR, after including
2722 # INCLUDES, setting cache variable VAR accordingly.
2723 ac_fn_c_check_member ()
2725 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2727 $as_echo_n "checking for $2.$3... " >&6; }
2728 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2729 $as_echo_n "(cached) " >&6
2730 else
2731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2732 /* end confdefs.h. */
2735 main ()
2737 static $2 ac_aggr;
2738 if (ac_aggr.$3)
2739 return 0;
2741 return 0;
2743 _ACEOF
2744 if ac_fn_c_try_compile "$LINENO"; then :
2745 eval "$4=yes"
2746 else
2747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2748 /* end confdefs.h. */
2751 main ()
2753 static $2 ac_aggr;
2754 if (sizeof ac_aggr.$3)
2755 return 0;
2757 return 0;
2759 _ACEOF
2760 if ac_fn_c_try_compile "$LINENO"; then :
2761 eval "$4=yes"
2762 else
2763 eval "$4=no"
2765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2769 eval ac_res=\$$4
2770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2771 $as_echo "$ac_res" >&6; }
2772 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2774 } # ac_fn_c_check_member
2776 # ac_fn_c_check_func LINENO FUNC VAR
2777 # ----------------------------------
2778 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2779 ac_fn_c_check_func ()
2781 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2783 $as_echo_n "checking for $2... " >&6; }
2784 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2785 $as_echo_n "(cached) " >&6
2786 else
2787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2788 /* end confdefs.h. */
2789 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2790 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2791 #define $2 innocuous_$2
2793 /* System header to define __stub macros and hopefully few prototypes,
2794 which can conflict with char $2 (); below.
2795 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2796 <limits.h> exists even on freestanding compilers. */
2798 #ifdef __STDC__
2799 # include <limits.h>
2800 #else
2801 # include <assert.h>
2802 #endif
2804 #undef $2
2806 /* Override any GCC internal prototype to avoid an error.
2807 Use char because int might match the return type of a GCC
2808 builtin and then its argument prototype would still apply. */
2809 #ifdef __cplusplus
2810 extern "C"
2811 #endif
2812 char $2 ();
2813 /* The GNU C library defines this for functions which it implements
2814 to always fail with ENOSYS. Some functions are actually named
2815 something starting with __ and the normal name is an alias. */
2816 #if defined __stub_$2 || defined __stub___$2
2817 choke me
2818 #endif
2821 main ()
2823 return $2 ();
2825 return 0;
2827 _ACEOF
2828 if ac_fn_c_try_link "$LINENO"; then :
2829 eval "$3=yes"
2830 else
2831 eval "$3=no"
2833 rm -f core conftest.err conftest.$ac_objext \
2834 conftest$ac_exeext conftest.$ac_ext
2836 eval ac_res=\$$3
2837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2838 $as_echo "$ac_res" >&6; }
2839 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2841 } # ac_fn_c_check_func
2843 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2844 # -------------------------------------------
2845 # Tests whether TYPE exists after having included INCLUDES, setting cache
2846 # variable VAR accordingly.
2847 ac_fn_c_check_type ()
2849 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2851 $as_echo_n "checking for $2... " >&6; }
2852 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2853 $as_echo_n "(cached) " >&6
2854 else
2855 eval "$3=no"
2856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2857 /* end confdefs.h. */
2860 main ()
2862 if (sizeof ($2))
2863 return 0;
2865 return 0;
2867 _ACEOF
2868 if ac_fn_c_try_compile "$LINENO"; then :
2869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2870 /* end confdefs.h. */
2873 main ()
2875 if (sizeof (($2)))
2876 return 0;
2878 return 0;
2880 _ACEOF
2881 if ac_fn_c_try_compile "$LINENO"; then :
2883 else
2884 eval "$3=yes"
2886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2890 eval ac_res=\$$3
2891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2892 $as_echo "$ac_res" >&6; }
2893 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2895 } # ac_fn_c_check_type
2897 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2898 # --------------------------------------------
2899 # Tries to find the compile-time value of EXPR in a program that includes
2900 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2901 # computed
2902 ac_fn_c_compute_int ()
2904 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2905 if test "$cross_compiling" = yes; then
2906 # Depending upon the size, compute the lo and hi bounds.
2907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2908 /* end confdefs.h. */
2911 main ()
2913 static int test_array [1 - 2 * !(($2) >= 0)];
2914 test_array [0] = 0
2917 return 0;
2919 _ACEOF
2920 if ac_fn_c_try_compile "$LINENO"; then :
2921 ac_lo=0 ac_mid=0
2922 while :; do
2923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2924 /* end confdefs.h. */
2927 main ()
2929 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2930 test_array [0] = 0
2933 return 0;
2935 _ACEOF
2936 if ac_fn_c_try_compile "$LINENO"; then :
2937 ac_hi=$ac_mid; break
2938 else
2939 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2940 if test $ac_lo -le $ac_mid; then
2941 ac_lo= ac_hi=
2942 break
2944 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2947 done
2948 else
2949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2950 /* end confdefs.h. */
2953 main ()
2955 static int test_array [1 - 2 * !(($2) < 0)];
2956 test_array [0] = 0
2959 return 0;
2961 _ACEOF
2962 if ac_fn_c_try_compile "$LINENO"; then :
2963 ac_hi=-1 ac_mid=-1
2964 while :; do
2965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2966 /* end confdefs.h. */
2969 main ()
2971 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2972 test_array [0] = 0
2975 return 0;
2977 _ACEOF
2978 if ac_fn_c_try_compile "$LINENO"; then :
2979 ac_lo=$ac_mid; break
2980 else
2981 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2982 if test $ac_mid -le $ac_hi; then
2983 ac_lo= ac_hi=
2984 break
2986 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2988 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2989 done
2990 else
2991 ac_lo= ac_hi=
2993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2996 # Binary search between lo and hi bounds.
2997 while test "x$ac_lo" != "x$ac_hi"; do
2998 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3000 /* end confdefs.h. */
3003 main ()
3005 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3006 test_array [0] = 0
3009 return 0;
3011 _ACEOF
3012 if ac_fn_c_try_compile "$LINENO"; then :
3013 ac_hi=$ac_mid
3014 else
3015 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3018 done
3019 case $ac_lo in #((
3020 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3021 '') ac_retval=1 ;;
3022 esac
3023 else
3024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3025 /* end confdefs.h. */
3027 static long int longval () { return $2; }
3028 static unsigned long int ulongval () { return $2; }
3029 #include <stdio.h>
3030 #include <stdlib.h>
3032 main ()
3035 FILE *f = fopen ("conftest.val", "w");
3036 if (! f)
3037 return 1;
3038 if (($2) < 0)
3040 long int i = longval ();
3041 if (i != ($2))
3042 return 1;
3043 fprintf (f, "%ld", i);
3045 else
3047 unsigned long int i = ulongval ();
3048 if (i != ($2))
3049 return 1;
3050 fprintf (f, "%lu", i);
3052 /* Do not output a trailing newline, as this causes \r\n confusion
3053 on some platforms. */
3054 return ferror (f) || fclose (f) != 0;
3057 return 0;
3059 _ACEOF
3060 if ac_fn_c_try_run "$LINENO"; then :
3061 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3062 else
3063 ac_retval=1
3065 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3066 conftest.$ac_objext conftest.beam conftest.$ac_ext
3067 rm -f conftest.val
3070 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3071 as_fn_set_status $ac_retval
3073 } # ac_fn_c_compute_int
3074 cat >config.log <<_ACEOF
3075 This file contains any messages produced by compilers while
3076 running configure, to aid debugging if configure makes a mistake.
3078 It was created by emacs $as_me 24.3.50, which was
3079 generated by GNU Autoconf 2.65. Invocation command line was
3081 $ $0 $@
3083 _ACEOF
3084 exec 5>>config.log
3086 cat <<_ASUNAME
3087 ## --------- ##
3088 ## Platform. ##
3089 ## --------- ##
3091 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3092 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3093 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3094 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3095 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3097 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3098 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3100 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3101 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3102 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3103 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3104 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3105 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3106 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3108 _ASUNAME
3110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3111 for as_dir in $PATH
3113 IFS=$as_save_IFS
3114 test -z "$as_dir" && as_dir=.
3115 $as_echo "PATH: $as_dir"
3116 done
3117 IFS=$as_save_IFS
3119 } >&5
3121 cat >&5 <<_ACEOF
3124 ## ----------- ##
3125 ## Core tests. ##
3126 ## ----------- ##
3128 _ACEOF
3131 # Keep a trace of the command line.
3132 # Strip out --no-create and --no-recursion so they do not pile up.
3133 # Strip out --silent because we don't want to record it for future runs.
3134 # Also quote any args containing shell meta-characters.
3135 # Make two passes to allow for proper duplicate-argument suppression.
3136 ac_configure_args=
3137 ac_configure_args0=
3138 ac_configure_args1=
3139 ac_must_keep_next=false
3140 for ac_pass in 1 2
3142 for ac_arg
3144 case $ac_arg in
3145 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3146 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3147 | -silent | --silent | --silen | --sile | --sil)
3148 continue ;;
3149 *\'*)
3150 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3151 esac
3152 case $ac_pass in
3153 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3155 as_fn_append ac_configure_args1 " '$ac_arg'"
3156 if test $ac_must_keep_next = true; then
3157 ac_must_keep_next=false # Got value, back to normal.
3158 else
3159 case $ac_arg in
3160 *=* | --config-cache | -C | -disable-* | --disable-* \
3161 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3162 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3163 | -with-* | --with-* | -without-* | --without-* | --x)
3164 case "$ac_configure_args0 " in
3165 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3166 esac
3168 -* ) ac_must_keep_next=true ;;
3169 esac
3171 as_fn_append ac_configure_args " '$ac_arg'"
3173 esac
3174 done
3175 done
3176 { ac_configure_args0=; unset ac_configure_args0;}
3177 { ac_configure_args1=; unset ac_configure_args1;}
3179 # When interrupted or exit'd, cleanup temporary files, and complete
3180 # config.log. We remove comments because anyway the quotes in there
3181 # would cause problems or look ugly.
3182 # WARNING: Use '\'' to represent an apostrophe within the trap.
3183 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3184 trap 'exit_status=$?
3185 # Save into config.log some information that might help in debugging.
3187 echo
3189 cat <<\_ASBOX
3190 ## ---------------- ##
3191 ## Cache variables. ##
3192 ## ---------------- ##
3193 _ASBOX
3194 echo
3195 # The following way of writing the cache mishandles newlines in values,
3197 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3198 eval ac_val=\$$ac_var
3199 case $ac_val in #(
3200 *${as_nl}*)
3201 case $ac_var in #(
3202 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3203 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3204 esac
3205 case $ac_var in #(
3206 _ | IFS | as_nl) ;; #(
3207 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3208 *) { eval $ac_var=; unset $ac_var;} ;;
3209 esac ;;
3210 esac
3211 done
3212 (set) 2>&1 |
3213 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3214 *${as_nl}ac_space=\ *)
3215 sed -n \
3216 "s/'\''/'\''\\\\'\'''\''/g;
3217 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3218 ;; #(
3220 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3222 esac |
3223 sort
3225 echo
3227 cat <<\_ASBOX
3228 ## ----------------- ##
3229 ## Output variables. ##
3230 ## ----------------- ##
3231 _ASBOX
3232 echo
3233 for ac_var in $ac_subst_vars
3235 eval ac_val=\$$ac_var
3236 case $ac_val in
3237 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3238 esac
3239 $as_echo "$ac_var='\''$ac_val'\''"
3240 done | sort
3241 echo
3243 if test -n "$ac_subst_files"; then
3244 cat <<\_ASBOX
3245 ## ------------------- ##
3246 ## File substitutions. ##
3247 ## ------------------- ##
3248 _ASBOX
3249 echo
3250 for ac_var in $ac_subst_files
3252 eval ac_val=\$$ac_var
3253 case $ac_val in
3254 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3255 esac
3256 $as_echo "$ac_var='\''$ac_val'\''"
3257 done | sort
3258 echo
3261 if test -s confdefs.h; then
3262 cat <<\_ASBOX
3263 ## ----------- ##
3264 ## confdefs.h. ##
3265 ## ----------- ##
3266 _ASBOX
3267 echo
3268 cat confdefs.h
3269 echo
3271 test "$ac_signal" != 0 &&
3272 $as_echo "$as_me: caught signal $ac_signal"
3273 $as_echo "$as_me: exit $exit_status"
3274 } >&5
3275 rm -f core *.core core.conftest.* &&
3276 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3277 exit $exit_status
3279 for ac_signal in 1 2 13 15; do
3280 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3281 done
3282 ac_signal=0
3284 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3285 rm -f -r conftest* confdefs.h
3287 $as_echo "/* confdefs.h */" > confdefs.h
3289 # Predefined preprocessor variables.
3291 cat >>confdefs.h <<_ACEOF
3292 #define PACKAGE_NAME "$PACKAGE_NAME"
3293 _ACEOF
3295 cat >>confdefs.h <<_ACEOF
3296 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3297 _ACEOF
3299 cat >>confdefs.h <<_ACEOF
3300 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3301 _ACEOF
3303 cat >>confdefs.h <<_ACEOF
3304 #define PACKAGE_STRING "$PACKAGE_STRING"
3305 _ACEOF
3307 cat >>confdefs.h <<_ACEOF
3308 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3309 _ACEOF
3311 cat >>confdefs.h <<_ACEOF
3312 #define PACKAGE_URL "$PACKAGE_URL"
3313 _ACEOF
3316 # Let the site file select an alternate cache file if it wants to.
3317 # Prefer an explicitly selected file to automatically selected ones.
3318 ac_site_file1=NONE
3319 ac_site_file2=NONE
3320 if test -n "$CONFIG_SITE"; then
3321 ac_site_file1=$CONFIG_SITE
3322 elif test "x$prefix" != xNONE; then
3323 ac_site_file1=$prefix/share/config.site
3324 ac_site_file2=$prefix/etc/config.site
3325 else
3326 ac_site_file1=$ac_default_prefix/share/config.site
3327 ac_site_file2=$ac_default_prefix/etc/config.site
3329 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3331 test "x$ac_site_file" = xNONE && continue
3332 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3333 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3334 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3335 sed 's/^/| /' "$ac_site_file" >&5
3336 . "$ac_site_file"
3338 done
3340 if test -r "$cache_file"; then
3341 # Some versions of bash will fail to source /dev/null (special files
3342 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3343 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3344 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3345 $as_echo "$as_me: loading cache $cache_file" >&6;}
3346 case $cache_file in
3347 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3348 *) . "./$cache_file";;
3349 esac
3351 else
3352 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3353 $as_echo "$as_me: creating cache $cache_file" >&6;}
3354 >$cache_file
3357 as_fn_append ac_header_list " sys/systeminfo.h"
3358 as_fn_append ac_header_list " coff.h"
3359 as_fn_append ac_header_list " pty.h"
3360 as_fn_append ac_header_list " sys/resource.h"
3361 as_fn_append ac_header_list " sys/utsname.h"
3362 as_fn_append ac_header_list " pwd.h"
3363 as_fn_append ac_header_list " utmp.h"
3364 as_fn_append ac_header_list " util.h"
3365 as_fn_append ac_header_list " sys/socket.h"
3366 as_fn_append ac_header_list " stdlib.h"
3367 as_fn_append ac_header_list " unistd.h"
3368 as_fn_append ac_header_list " sys/param.h"
3369 as_fn_append ac_header_list " pthread.h"
3370 as_fn_append ac_header_list " malloc/malloc.h"
3371 as_fn_append ac_header_list " maillock.h"
3372 as_fn_append ac_header_list " sys/un.h"
3373 as_fn_append ac_func_list " tzset"
3374 as_fn_append ac_func_list " readlinkat"
3375 as_fn_append ac_header_list " dirent.h"
3376 as_fn_append ac_header_list " execinfo.h"
3377 as_fn_append ac_func_list " faccessat"
3378 as_fn_append ac_func_list " fcntl"
3379 as_fn_append ac_func_list " fdopendir"
3380 as_fn_append ac_header_list " stdio_ext.h"
3381 as_fn_append ac_func_list " __fpending"
3382 as_fn_append ac_func_list " fstatat"
3383 as_fn_append ac_func_list " fsync"
3384 gl_getopt_required=GNU
3385 as_fn_append ac_header_list " getopt.h"
3386 as_fn_append ac_func_list " gettimeofday"
3387 as_fn_append ac_func_list " nanotime"
3388 as_fn_append ac_header_list " sys/time.h"
3389 as_fn_append ac_header_list " wchar.h"
3390 as_fn_append ac_header_list " stdint.h"
3391 as_fn_append ac_header_list " inttypes.h"
3392 as_fn_append ac_func_list " lstat"
3393 as_fn_append ac_func_list " pipe2"
3394 as_fn_append ac_header_list " sys/select.h"
3395 as_fn_append ac_func_list " pselect"
3396 as_fn_append ac_func_list " pthread_sigmask"
3397 as_fn_append ac_func_list " readlink"
3398 as_fn_append ac_func_list " strtoimax"
3399 as_fn_append ac_func_list " strtoumax"
3400 as_fn_append ac_func_list " symlink"
3401 as_fn_append ac_header_list " sys/stat.h"
3402 as_fn_append ac_func_list " localtime_r"
3403 as_fn_append ac_header_list " utime.h"
3404 as_fn_append ac_func_list " futimes"
3405 as_fn_append ac_func_list " futimesat"
3406 as_fn_append ac_func_list " futimens"
3407 as_fn_append ac_func_list " utimensat"
3408 as_fn_append ac_func_list " lutimes"
3409 as_fn_append ac_func_list " getdtablesize"
3410 # Check that the precious variables saved in the cache have kept the same
3411 # value.
3412 ac_cache_corrupted=false
3413 for ac_var in $ac_precious_vars; do
3414 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3415 eval ac_new_set=\$ac_env_${ac_var}_set
3416 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3417 eval ac_new_val=\$ac_env_${ac_var}_value
3418 case $ac_old_set,$ac_new_set in
3419 set,)
3420 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3421 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3422 ac_cache_corrupted=: ;;
3423 ,set)
3424 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3425 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3426 ac_cache_corrupted=: ;;
3427 ,);;
3429 if test "x$ac_old_val" != "x$ac_new_val"; then
3430 # differences in whitespace do not lead to failure.
3431 ac_old_val_w=`echo x $ac_old_val`
3432 ac_new_val_w=`echo x $ac_new_val`
3433 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3434 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3435 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3436 ac_cache_corrupted=:
3437 else
3438 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3439 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3440 eval $ac_var=\$ac_old_val
3442 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3443 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3444 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3445 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3446 fi;;
3447 esac
3448 # Pass precious variables to config.status.
3449 if test "$ac_new_set" = set; then
3450 case $ac_new_val in
3451 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3452 *) ac_arg=$ac_var=$ac_new_val ;;
3453 esac
3454 case " $ac_configure_args " in
3455 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3456 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3457 esac
3459 done
3460 if $ac_cache_corrupted; then
3461 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3462 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3463 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3464 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3465 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3467 ## -------------------- ##
3468 ## Main body of script. ##
3469 ## -------------------- ##
3471 ac_ext=c
3472 ac_cpp='$CPP $CPPFLAGS'
3473 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3474 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3475 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3479 emacs_config_options="$@"
3480 ## Add some environment variables, if they were passed via the environment
3481 ## rather than on the command-line.
3482 for var in CFLAGS CPPFLAGS LDFLAGS; do
3483 case "$emacs_config_options" in
3484 *$var=*) continue ;;
3485 esac
3486 eval val="\$${var}"
3487 test x"$val" = x && continue
3488 emacs_config_options="${emacs_config_options}${emacs_config_options:+ }$var=\"$val\""
3489 done
3491 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3494 ac_aux_dir=
3495 for ac_dir in build-aux "$srcdir"/build-aux; do
3496 for ac_t in install-sh install.sh shtool; do
3497 if test -f "$ac_dir/$ac_t"; then
3498 ac_aux_dir=$ac_dir
3499 ac_install_sh="$ac_aux_dir/$ac_t -c"
3500 break 2
3502 done
3503 done
3504 if test -z "$ac_aux_dir"; then
3505 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3508 # These three variables are undocumented and unsupported,
3509 # and are intended to be withdrawn in a future Autoconf release.
3510 # They can cause serious problems if a builder's source tree is in a directory
3511 # whose full name contains unusual characters.
3512 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3513 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3514 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3517 am__api_version='1.11'
3519 # Find a good install program. We prefer a C program (faster),
3520 # so one script is as good as another. But avoid the broken or
3521 # incompatible versions:
3522 # SysV /etc/install, /usr/sbin/install
3523 # SunOS /usr/etc/install
3524 # IRIX /sbin/install
3525 # AIX /bin/install
3526 # AmigaOS /C/install, which installs bootblocks on floppy discs
3527 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3528 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3529 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3530 # OS/2's system install, which has a completely different semantic
3531 # ./install, which can be erroneously created by make from ./install.sh.
3532 # Reject install programs that cannot install multiple files.
3533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3534 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3535 if test -z "$INSTALL"; then
3536 if test "${ac_cv_path_install+set}" = set; then :
3537 $as_echo_n "(cached) " >&6
3538 else
3539 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3540 for as_dir in $PATH
3542 IFS=$as_save_IFS
3543 test -z "$as_dir" && as_dir=.
3544 # Account for people who put trailing slashes in PATH elements.
3545 case $as_dir/ in #((
3546 ./ | .// | /[cC]/* | \
3547 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3548 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3549 /usr/ucb/* ) ;;
3551 # OSF1 and SCO ODT 3.0 have their own names for install.
3552 # Don't use installbsd from OSF since it installs stuff as root
3553 # by default.
3554 for ac_prog in ginstall scoinst install; do
3555 for ac_exec_ext in '' $ac_executable_extensions; do
3556 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3557 if test $ac_prog = install &&
3558 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3559 # AIX install. It has an incompatible calling convention.
3561 elif test $ac_prog = install &&
3562 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3563 # program-specific install script used by HP pwplus--don't use.
3565 else
3566 rm -rf conftest.one conftest.two conftest.dir
3567 echo one > conftest.one
3568 echo two > conftest.two
3569 mkdir conftest.dir
3570 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3571 test -s conftest.one && test -s conftest.two &&
3572 test -s conftest.dir/conftest.one &&
3573 test -s conftest.dir/conftest.two
3574 then
3575 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3576 break 3
3580 done
3581 done
3583 esac
3585 done
3586 IFS=$as_save_IFS
3588 rm -rf conftest.one conftest.two conftest.dir
3591 if test "${ac_cv_path_install+set}" = set; then
3592 INSTALL=$ac_cv_path_install
3593 else
3594 # As a last resort, use the slow shell script. Don't cache a
3595 # value for INSTALL within a source directory, because that will
3596 # break other packages using the cache if that directory is
3597 # removed, or if the value is a relative name.
3598 INSTALL=$ac_install_sh
3601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3602 $as_echo "$INSTALL" >&6; }
3604 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3605 # It thinks the first close brace ends the variable substitution.
3606 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3608 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3610 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3613 $as_echo_n "checking whether build environment is sane... " >&6; }
3614 # Just in case
3615 sleep 1
3616 echo timestamp > conftest.file
3617 # Reject unsafe characters in $srcdir or the absolute working directory
3618 # name. Accept space and tab only in the latter.
3619 am_lf='
3621 case `pwd` in
3622 *[\\\"\#\$\&\'\`$am_lf]*)
3623 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3624 esac
3625 case $srcdir in
3626 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3627 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3628 esac
3630 # Do `set' in a subshell so we don't clobber the current shell's
3631 # arguments. Must try -L first in case configure is actually a
3632 # symlink; some systems play weird games with the mod time of symlinks
3633 # (eg FreeBSD returns the mod time of the symlink's containing
3634 # directory).
3635 if (
3636 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3637 if test "$*" = "X"; then
3638 # -L didn't work.
3639 set X `ls -t "$srcdir/configure" conftest.file`
3641 rm -f conftest.file
3642 if test "$*" != "X $srcdir/configure conftest.file" \
3643 && test "$*" != "X conftest.file $srcdir/configure"; then
3645 # If neither matched, then we have a broken ls. This can happen
3646 # if, for instance, CONFIG_SHELL is bash and it inherits a
3647 # broken ls alias from the environment. This has actually
3648 # happened. Such a system could not be considered "sane".
3649 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3650 alias in your environment" "$LINENO" 5
3653 test "$2" = conftest.file
3655 then
3656 # Ok.
3658 else
3659 as_fn_error "newly created file is older than distributed files!
3660 Check your system clock" "$LINENO" 5
3662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3663 $as_echo "yes" >&6; }
3664 test "$program_prefix" != NONE &&
3665 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3666 # Use a double $ so make ignores it.
3667 test "$program_suffix" != NONE &&
3668 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3669 # Double any \ or $.
3670 # By default was `s,x,x', remove it if useless.
3671 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3672 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3674 # expand $ac_aux_dir to an absolute path
3675 am_aux_dir=`cd $ac_aux_dir && pwd`
3677 if test x"${MISSING+set}" != xset; then
3678 case $am_aux_dir in
3679 *\ * | *\ *)
3680 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3682 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3683 esac
3685 # Use eval to expand $SHELL
3686 if eval "$MISSING --run true"; then
3687 am_missing_run="$MISSING --run "
3688 else
3689 am_missing_run=
3690 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3691 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3694 if test x"${install_sh}" != xset; then
3695 case $am_aux_dir in
3696 *\ * | *\ *)
3697 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3699 install_sh="\${SHELL} $am_aux_dir/install-sh"
3700 esac
3703 # Installed binaries are usually stripped using `strip' when the user
3704 # run `make install-strip'. However `strip' might not be the right
3705 # tool to use in cross-compilation environments, therefore Automake
3706 # will honor the `STRIP' environment variable to overrule this program.
3707 if test "$cross_compiling" != no; then
3708 if test -n "$ac_tool_prefix"; then
3709 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3710 set dummy ${ac_tool_prefix}strip; ac_word=$2
3711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3712 $as_echo_n "checking for $ac_word... " >&6; }
3713 if test "${ac_cv_prog_STRIP+set}" = set; then :
3714 $as_echo_n "(cached) " >&6
3715 else
3716 if test -n "$STRIP"; then
3717 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3718 else
3719 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3720 for as_dir in $PATH
3722 IFS=$as_save_IFS
3723 test -z "$as_dir" && as_dir=.
3724 for ac_exec_ext in '' $ac_executable_extensions; do
3725 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3726 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3727 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3728 break 2
3730 done
3731 done
3732 IFS=$as_save_IFS
3736 STRIP=$ac_cv_prog_STRIP
3737 if test -n "$STRIP"; then
3738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3739 $as_echo "$STRIP" >&6; }
3740 else
3741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3742 $as_echo "no" >&6; }
3747 if test -z "$ac_cv_prog_STRIP"; then
3748 ac_ct_STRIP=$STRIP
3749 # Extract the first word of "strip", so it can be a program name with args.
3750 set dummy strip; ac_word=$2
3751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3752 $as_echo_n "checking for $ac_word... " >&6; }
3753 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3754 $as_echo_n "(cached) " >&6
3755 else
3756 if test -n "$ac_ct_STRIP"; then
3757 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3758 else
3759 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3760 for as_dir in $PATH
3762 IFS=$as_save_IFS
3763 test -z "$as_dir" && as_dir=.
3764 for ac_exec_ext in '' $ac_executable_extensions; do
3765 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3766 ac_cv_prog_ac_ct_STRIP="strip"
3767 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3768 break 2
3770 done
3771 done
3772 IFS=$as_save_IFS
3776 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3777 if test -n "$ac_ct_STRIP"; then
3778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3779 $as_echo "$ac_ct_STRIP" >&6; }
3780 else
3781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3782 $as_echo "no" >&6; }
3785 if test "x$ac_ct_STRIP" = x; then
3786 STRIP=":"
3787 else
3788 case $cross_compiling:$ac_tool_warned in
3789 yes:)
3790 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3791 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3792 ac_tool_warned=yes ;;
3793 esac
3794 STRIP=$ac_ct_STRIP
3796 else
3797 STRIP="$ac_cv_prog_STRIP"
3801 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3804 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3805 if test -z "$MKDIR_P"; then
3806 if test "${ac_cv_path_mkdir+set}" = set; then :
3807 $as_echo_n "(cached) " >&6
3808 else
3809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3810 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3812 IFS=$as_save_IFS
3813 test -z "$as_dir" && as_dir=.
3814 for ac_prog in mkdir gmkdir; do
3815 for ac_exec_ext in '' $ac_executable_extensions; do
3816 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3817 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3818 'mkdir (GNU coreutils) '* | \
3819 'mkdir (coreutils) '* | \
3820 'mkdir (fileutils) '4.1*)
3821 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3822 break 3;;
3823 esac
3824 done
3825 done
3826 done
3827 IFS=$as_save_IFS
3831 test -d ./--version && rmdir ./--version
3832 if test "${ac_cv_path_mkdir+set}" = set; then
3833 MKDIR_P="$ac_cv_path_mkdir -p"
3834 else
3835 # As a last resort, use the slow shell script. Don't cache a
3836 # value for MKDIR_P within a source directory, because that will
3837 # break other packages using the cache if that directory is
3838 # removed, or if the value is a relative name.
3839 MKDIR_P="$ac_install_sh -d"
3842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3843 $as_echo "$MKDIR_P" >&6; }
3845 mkdir_p="$MKDIR_P"
3846 case $mkdir_p in
3847 [\\/$]* | ?:[\\/]*) ;;
3848 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3849 esac
3851 for ac_prog in gawk mawk nawk awk
3853 # Extract the first word of "$ac_prog", so it can be a program name with args.
3854 set dummy $ac_prog; ac_word=$2
3855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3856 $as_echo_n "checking for $ac_word... " >&6; }
3857 if test "${ac_cv_prog_AWK+set}" = set; then :
3858 $as_echo_n "(cached) " >&6
3859 else
3860 if test -n "$AWK"; then
3861 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3862 else
3863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3864 for as_dir in $PATH
3866 IFS=$as_save_IFS
3867 test -z "$as_dir" && as_dir=.
3868 for ac_exec_ext in '' $ac_executable_extensions; do
3869 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3870 ac_cv_prog_AWK="$ac_prog"
3871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3872 break 2
3874 done
3875 done
3876 IFS=$as_save_IFS
3880 AWK=$ac_cv_prog_AWK
3881 if test -n "$AWK"; then
3882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3883 $as_echo "$AWK" >&6; }
3884 else
3885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3886 $as_echo "no" >&6; }
3890 test -n "$AWK" && break
3891 done
3893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3894 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3895 set x ${MAKE-make}
3896 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3897 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3898 $as_echo_n "(cached) " >&6
3899 else
3900 cat >conftest.make <<\_ACEOF
3901 SHELL = /bin/sh
3902 all:
3903 @echo '@@@%%%=$(MAKE)=@@@%%%'
3904 _ACEOF
3905 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3906 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3907 *@@@%%%=?*=@@@%%%*)
3908 eval ac_cv_prog_make_${ac_make}_set=yes;;
3910 eval ac_cv_prog_make_${ac_make}_set=no;;
3911 esac
3912 rm -f conftest.make
3914 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3916 $as_echo "yes" >&6; }
3917 SET_MAKE=
3918 else
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3920 $as_echo "no" >&6; }
3921 SET_MAKE="MAKE=${MAKE-make}"
3924 rm -rf .tst 2>/dev/null
3925 mkdir .tst 2>/dev/null
3926 if test -d .tst; then
3927 am__leading_dot=.
3928 else
3929 am__leading_dot=_
3931 rmdir .tst 2>/dev/null
3933 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3934 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3935 # is not polluted with repeated "-I."
3936 am__isrc=' -I$(srcdir)'
3937 # test to see if srcdir already configured
3938 if test -f $srcdir/config.status; then
3939 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3943 # test whether we have cygpath
3944 if test -z "$CYGPATH_W"; then
3945 if (cygpath --version) >/dev/null 2>/dev/null; then
3946 CYGPATH_W='cygpath -w'
3947 else
3948 CYGPATH_W=echo
3953 # Define the identity of the package.
3954 PACKAGE='emacs'
3955 VERSION='24.3.50'
3958 cat >>confdefs.h <<_ACEOF
3959 #define PACKAGE "$PACKAGE"
3960 _ACEOF
3963 cat >>confdefs.h <<_ACEOF
3964 #define VERSION "$VERSION"
3965 _ACEOF
3967 # Some tools Automake needs.
3969 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3972 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3975 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3978 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3981 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3983 # We need awk for the "check" target. The system "awk" is bad on
3984 # some platforms.
3985 # Always define AMTAR for backward compatibility.
3987 AMTAR=${AMTAR-"${am_missing_run}tar"}
3989 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3998 lispdir='${datadir}/emacs/${version}/lisp'
3999 leimdir='${datadir}/emacs/${version}/leim'
4000 standardlisppath='${lispdir}:${leimdir}'
4001 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
4002 '${datadir}/emacs/site-lisp'
4003 lisppath='${locallisppath}:${standardlisppath}'
4004 etcdir='${datadir}/emacs/${version}/etc'
4005 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4006 docdir='${datadir}/emacs/${version}/etc'
4007 gamedir='${localstatedir}/games/emacs'
4010 # Check whether --with-all was given.
4011 if test "${with_all+set}" = set; then :
4012 withval=$with_all; with_features=$withval
4013 else
4014 with_features=yes
4021 # Check whether --with-pop was given.
4022 if test "${with_pop+set}" = set; then :
4023 withval=$with_pop;
4024 else
4025 with_pop=$with_features
4028 if test "$with_pop" = yes; then
4029 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4034 # Check whether --with-kerberos was given.
4035 if test "${with_kerberos+set}" = set; then :
4036 withval=$with_kerberos;
4037 else
4038 with_kerberos=no
4041 if test "$with_kerberos" != no; then
4042 $as_echo "#define KERBEROS 1" >>confdefs.h
4047 # Check whether --with-kerberos5 was given.
4048 if test "${with_kerberos5+set}" = set; then :
4049 withval=$with_kerberos5;
4050 else
4051 with_kerberos5=no
4054 if test "${with_kerberos5}" != no; then
4055 if test "${with_kerberos}" = no; then
4056 with_kerberos=yes
4057 $as_echo "#define KERBEROS 1" >>confdefs.h
4061 $as_echo "#define KERBEROS5 1" >>confdefs.h
4066 # Check whether --with-hesiod was given.
4067 if test "${with_hesiod+set}" = set; then :
4068 withval=$with_hesiod;
4069 else
4070 with_hesiod=no
4073 if test "$with_hesiod" != no; then
4075 $as_echo "#define HESIOD 1" >>confdefs.h
4080 # Check whether --with-mmdf was given.
4081 if test "${with_mmdf+set}" = set; then :
4082 withval=$with_mmdf;
4083 else
4084 with_mmdf=no
4087 if test "$with_mmdf" != no; then
4089 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4094 # Check whether --with-mail-unlink was given.
4095 if test "${with_mail_unlink+set}" = set; then :
4096 withval=$with_mail_unlink;
4097 else
4098 with_mail_unlink=no
4101 if test "$with_mail_unlink" != no; then
4103 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4108 # Check whether --with-mailhost was given.
4109 if test "${with_mailhost+set}" = set; then :
4110 withval=$with_mailhost;
4111 cat >>confdefs.h <<_ACEOF
4112 #define MAILHOST "$withval"
4113 _ACEOF
4119 # Check whether --with-sound was given.
4120 if test "${with_sound+set}" = set; then :
4121 withval=$with_sound; case "${withval}" in
4122 yes|no|ossaudio|alsa) val=$withval ;;
4123 *) as_fn_error "\`--with-sound=$withval' is invalid;
4124 this option's value should be \`yes', \`no', \`ossaudio', or \`alsa'." "$LINENO" 5
4126 esac
4127 with_sound=$val
4129 else
4130 with_sound=$with_features
4135 # Check whether --with-x-toolkit was given.
4136 if test "${with_x_toolkit+set}" = set; then :
4137 withval=$with_x_toolkit; case "${withval}" in
4138 y | ye | yes ) val=gtk ;;
4139 n | no ) val=no ;;
4140 l | lu | luc | luci | lucid ) val=lucid ;;
4141 a | at | ath | athe | athen | athena ) val=athena ;;
4142 m | mo | mot | moti | motif ) val=motif ;;
4143 g | gt | gtk ) val=gtk ;;
4144 gtk2 ) val=gtk2 ;;
4145 gtk3 ) val=gtk3 ;;
4147 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4148 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4149 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4150 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4152 esac
4153 with_x_toolkit=$val
4159 # Check whether --with-wide-int was given.
4160 if test "${with_wide_int+set}" = set; then :
4161 withval=$with_wide_int;
4162 else
4163 with_wide_int=no
4166 if test "$with_wide_int" = yes; then
4168 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4173 # Check whether --with-xpm was given.
4174 if test "${with_xpm+set}" = set; then :
4175 withval=$with_xpm;
4176 else
4177 with_xpm=$with_features
4181 # Check whether --with-jpeg was given.
4182 if test "${with_jpeg+set}" = set; then :
4183 withval=$with_jpeg;
4184 else
4185 with_jpeg=$with_features
4189 # Check whether --with-tiff was given.
4190 if test "${with_tiff+set}" = set; then :
4191 withval=$with_tiff;
4192 else
4193 with_tiff=$with_features
4197 # Check whether --with-gif was given.
4198 if test "${with_gif+set}" = set; then :
4199 withval=$with_gif;
4200 else
4201 with_gif=$with_features
4205 # Check whether --with-png was given.
4206 if test "${with_png+set}" = set; then :
4207 withval=$with_png;
4208 else
4209 with_png=$with_features
4213 # Check whether --with-rsvg was given.
4214 if test "${with_rsvg+set}" = set; then :
4215 withval=$with_rsvg;
4216 else
4217 with_rsvg=$with_features
4221 # Check whether --with-xml2 was given.
4222 if test "${with_xml2+set}" = set; then :
4223 withval=$with_xml2;
4224 else
4225 with_xml2=$with_features
4229 # Check whether --with-imagemagick was given.
4230 if test "${with_imagemagick+set}" = set; then :
4231 withval=$with_imagemagick;
4232 else
4233 with_imagemagick=$with_features
4238 # Check whether --with-xft was given.
4239 if test "${with_xft+set}" = set; then :
4240 withval=$with_xft;
4241 else
4242 with_xft=$with_features
4246 # Check whether --with-libotf was given.
4247 if test "${with_libotf+set}" = set; then :
4248 withval=$with_libotf;
4249 else
4250 with_libotf=$with_features
4254 # Check whether --with-m17n-flt was given.
4255 if test "${with_m17n_flt+set}" = set; then :
4256 withval=$with_m17n_flt;
4257 else
4258 with_m17n_flt=$with_features
4263 # Check whether --with-toolkit-scroll-bars was given.
4264 if test "${with_toolkit_scroll_bars+set}" = set; then :
4265 withval=$with_toolkit_scroll_bars;
4266 else
4267 with_toolkit_scroll_bars=$with_features
4271 # Check whether --with-xaw3d was given.
4272 if test "${with_xaw3d+set}" = set; then :
4273 withval=$with_xaw3d;
4274 else
4275 with_xaw3d=$with_features
4279 # Check whether --with-xim was given.
4280 if test "${with_xim+set}" = set; then :
4281 withval=$with_xim;
4282 else
4283 with_xim=$with_features
4287 # Check whether --with-ns was given.
4288 if test "${with_ns+set}" = set; then :
4289 withval=$with_ns;
4290 else
4291 with_ns=no
4295 # Check whether --with-w32 was given.
4296 if test "${with_w32+set}" = set; then :
4297 withval=$with_w32;
4298 else
4299 with_w32=no
4304 # Check whether --with-gpm was given.
4305 if test "${with_gpm+set}" = set; then :
4306 withval=$with_gpm;
4307 else
4308 with_gpm=$with_features
4312 # Check whether --with-dbus was given.
4313 if test "${with_dbus+set}" = set; then :
4314 withval=$with_dbus;
4315 else
4316 with_dbus=$with_features
4320 # Check whether --with-gconf was given.
4321 if test "${with_gconf+set}" = set; then :
4322 withval=$with_gconf;
4323 else
4324 with_gconf=$with_features
4328 # Check whether --with-gsettings was given.
4329 if test "${with_gsettings+set}" = set; then :
4330 withval=$with_gsettings;
4331 else
4332 with_gsettings=$with_features
4336 # Check whether --with-selinux was given.
4337 if test "${with_selinux+set}" = set; then :
4338 withval=$with_selinux;
4339 else
4340 with_selinux=$with_features
4344 # Check whether --with-gnutls was given.
4345 if test "${with_gnutls+set}" = set; then :
4346 withval=$with_gnutls;
4347 else
4348 with_gnutls=$with_features
4353 # Check whether --with-file-notification was given.
4354 if test "${with_file_notification+set}" = set; then :
4355 withval=$with_file_notification; case "${withval}" in
4356 y | ye | yes ) val=yes ;;
4357 n | no ) val=no ;;
4358 g | gf | gfi | gfil | gfile ) val=gfile ;;
4359 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4360 w | w3 | w32 ) val=w32 ;;
4361 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4362 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4363 \`yes' is a synonym for \`w32' on MS-Windows, for \`no' on Nextstep,
4364 otherwise for the first of \`gfile' or \`inotify' that is usable." "$LINENO" 5
4366 esac
4367 with_file_notification=$val
4369 else
4370 with_file_notification=$with_features
4374 ## For the times when you want to build Emacs but don't have
4375 ## a suitable makeinfo, and can live without the manuals.
4377 # Check whether --with-makeinfo was given.
4378 if test "${with_makeinfo+set}" = set; then :
4379 withval=$with_makeinfo;
4380 else
4381 with_makeinfo=$with_features
4385 ## Makefile.in needs the cache file name.
4388 ## This is an option because I do not know if all info/man support
4389 ## compressed files, nor how to test if they do so.
4391 # Check whether --with-compress-info was given.
4392 if test "${with_compress_info+set}" = set; then :
4393 withval=$with_compress_info;
4394 else
4395 with_compress_info=$with_features
4398 if test $with_compress_info = yes; then
4399 GZIP_INFO=yes
4400 else
4401 GZIP_INFO=
4406 # Check whether --with-pkg-config-prog was given.
4407 if test "${with_pkg_config_prog+set}" = set; then :
4408 withval=$with_pkg_config_prog;
4411 if test "X${with_pkg_config_prog}" != X; then
4412 if test "${with_pkg_config_prog}" != yes; then
4413 PKG_CONFIG="${with_pkg_config_prog}"
4418 # Check whether --with-gameuser was given.
4419 if test "${with_gameuser+set}" = set; then :
4420 withval=$with_gameuser;
4423 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4424 && gameuser="${with_gameuser}"
4425 test "X$gameuser" = X && gameuser=games
4428 # Check whether --with-gnustep-conf was given.
4429 if test "${with_gnustep_conf+set}" = set; then :
4430 withval=$with_gnustep_conf;
4433 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4434 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4435 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4436 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4438 # Check whether --enable-ns-self-contained was given.
4439 if test "${enable_ns_self_contained+set}" = set; then :
4440 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4441 else
4442 EN_NS_SELF_CONTAINED=yes
4446 # Check whether --enable-locallisppath was given.
4447 if test "${enable_locallisppath+set}" = set; then :
4448 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4449 locallisppath=
4450 elif test "${enableval}" != "yes"; then
4451 locallisppath=${enableval}
4456 # Check whether --enable-checking was given.
4457 if test "${enable_checking+set}" = set; then :
4458 enableval=$enable_checking; ac_checking_flags="${enableval}"
4461 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4462 for check in $ac_checking_flags
4464 case $check in
4465 # these set all the flags to specific states
4466 yes) ac_enable_checking=1 ;;
4467 no) ac_enable_checking= ;
4468 ac_gc_check_stringbytes= ;
4469 ac_gc_check_string_overrun= ;
4470 ac_gc_check_string_free_list= ;
4471 ac_xmalloc_overrun= ;
4472 ac_gc_check_cons_list= ;
4473 ac_glyphs_debug= ;;
4474 all) ac_enable_checking=1 ;
4475 ac_gc_check_stringbytes=1 ;
4476 ac_gc_check_string_overrun=1 ;
4477 ac_gc_check_string_free_list=1 ;
4478 ac_xmalloc_overrun=1 ;
4479 ac_gc_check_cons_list=1 ;
4480 ac_glyphs_debug=1 ;;
4481 # these enable particular checks
4482 stringbytes) ac_gc_check_stringbytes=1 ;;
4483 stringoverrun) ac_gc_check_string_overrun=1 ;;
4484 stringfreelist) ac_gc_check_string_free_list=1 ;;
4485 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4486 conslist) ac_gc_check_cons_list=1 ;;
4487 glyphs) ac_glyphs_debug=1 ;;
4488 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4489 esac
4490 done
4491 IFS="$ac_save_IFS"
4493 if test x$ac_enable_checking != x ; then
4495 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4498 if test x$ac_gc_check_stringbytes != x ; then
4500 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4503 if test x$ac_gc_check_string_overrun != x ; then
4505 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4508 if test x$ac_gc_check_string_free_list != x ; then
4510 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4513 if test x$ac_xmalloc_overrun != x ; then
4515 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4518 if test x$ac_gc_check_cons_list != x ; then
4520 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4523 if test x$ac_glyphs_debug != x ; then
4525 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4529 # Check whether --enable-check-lisp-object-type was given.
4530 if test "${enable_check_lisp_object_type+set}" = set; then :
4531 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4533 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4540 # Check whether --enable-profiling was given.
4541 if test "${enable_profiling+set}" = set; then :
4542 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4545 if test x$ac_enable_profiling != x ; then
4546 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4547 else
4548 PROFILING_CFLAGS=
4552 # Check whether --enable-autodepend was given.
4553 if test "${enable_autodepend+set}" = set; then :
4554 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4555 else
4556 ac_enable_autodepend=yes
4560 # Check whether --enable-gtk-deprecation-warnings was given.
4561 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4562 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4566 #### Make srcdir absolute, if it isn't already. It's important to
4567 #### avoid running the file name through pwd unnecessarily, since pwd can
4568 #### give you automounter prefixes, which can go away. We do all this
4569 #### so Emacs can find its files when run uninstalled.
4570 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4571 unset CDPATH
4572 case "${srcdir}" in
4573 [\\/]* | ?:[\\/]*) ;;
4575 ## We may be able to use the $PWD environment variable to make this
4576 ## absolute. But sometimes PWD is inaccurate.
4577 ## Note: we used to use $PWD at the end instead of `pwd`,
4578 ## but that tested only for a well-formed and valid PWD,
4579 ## it did not object when PWD was well-formed and valid but just wrong.
4580 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4581 then
4582 srcdir="$PWD"
4583 else
4584 srcdir=`(cd "$srcdir"; pwd)`
4587 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4588 esac
4590 ### Canonicalize the configuration name.
4592 # Make sure we can run config.sub.
4593 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4594 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4597 $as_echo_n "checking build system type... " >&6; }
4598 if test "${ac_cv_build+set}" = set; then :
4599 $as_echo_n "(cached) " >&6
4600 else
4601 ac_build_alias=$build_alias
4602 test "x$ac_build_alias" = x &&
4603 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4604 test "x$ac_build_alias" = x &&
4605 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4606 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4607 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4611 $as_echo "$ac_cv_build" >&6; }
4612 case $ac_cv_build in
4613 *-*-*) ;;
4614 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4615 esac
4616 build=$ac_cv_build
4617 ac_save_IFS=$IFS; IFS='-'
4618 set x $ac_cv_build
4619 shift
4620 build_cpu=$1
4621 build_vendor=$2
4622 shift; shift
4623 # Remember, the first character of IFS is used to create $*,
4624 # except with old shells:
4625 build_os=$*
4626 IFS=$ac_save_IFS
4627 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4631 $as_echo_n "checking host system type... " >&6; }
4632 if test "${ac_cv_host+set}" = set; then :
4633 $as_echo_n "(cached) " >&6
4634 else
4635 if test "x$host_alias" = x; then
4636 ac_cv_host=$ac_cv_build
4637 else
4638 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4639 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4644 $as_echo "$ac_cv_host" >&6; }
4645 case $ac_cv_host in
4646 *-*-*) ;;
4647 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4648 esac
4649 host=$ac_cv_host
4650 ac_save_IFS=$IFS; IFS='-'
4651 set x $ac_cv_host
4652 shift
4653 host_cpu=$1
4654 host_vendor=$2
4655 shift; shift
4656 # Remember, the first character of IFS is used to create $*,
4657 # except with old shells:
4658 host_os=$*
4659 IFS=$ac_save_IFS
4660 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4663 canonical=$host
4664 configuration=${host_alias-${build_alias-$host}}
4668 ### If you add support for a new configuration, add code to this
4669 ### switch statement to recognize your configuration name and select
4670 ### the appropriate operating system file.
4672 ### You would hope that you could choose an s/*.h
4673 ### file based on the operating system portion. However, it turns out
4674 ### that each s/*.h file is pretty manufacturer-specific.
4675 ### So we basically have to have a special case for each
4676 ### configuration name.
4678 ### As far as handling version numbers on operating systems is
4679 ### concerned, make sure things will fail in a fixable way. If
4680 ### /etc/MACHINES doesn't say anything about version numbers, be
4681 ### prepared to handle anything reasonably. If version numbers
4682 ### matter, be sure /etc/MACHINES says something about it.
4684 opsys='' unported=no
4685 case "${canonical}" in
4687 ## GNU/Linux and similar ports
4688 *-*-linux* )
4689 opsys=gnu-linux
4692 ## FreeBSD ports
4693 *-*-freebsd* )
4694 opsys=freebsd
4697 ## DragonFly ports
4698 *-*-dragonfly* )
4699 opsys=dragonfly
4702 ## FreeBSD kernel + glibc based userland
4703 *-*-kfreebsd*gnu* )
4704 opsys=gnu-kfreebsd
4707 ## NetBSD ports
4708 *-*-netbsd* )
4709 opsys=netbsd
4712 ## OpenBSD ports
4713 *-*-openbsd* )
4714 opsys=openbsd
4717 ## Apple Darwin / Mac OS X
4718 *-apple-darwin* )
4719 case "${canonical}" in
4720 i[3456]86-* ) ;;
4721 powerpc-* ) ;;
4722 x86_64-* ) ;;
4723 * ) unported=yes ;;
4724 esac
4725 opsys=darwin
4726 ## Use fink packages if available.
4727 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4728 ## if test -d /sw/include && test -d /sw/lib; then
4729 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4730 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4731 ## fi
4734 ## Cygwin ports
4735 *-*-cygwin )
4736 opsys=cygwin
4739 ## HP 9000 series 700 and 800, running HP/UX
4740 hppa*-hp-hpux10.2* )
4741 opsys=hpux10-20
4743 hppa*-hp-hpux1[1-9]* )
4744 opsys=hpux11
4745 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4748 ## IBM machines
4749 rs6000-ibm-aix4.[23]* )
4750 opsys=aix4-2
4752 powerpc-ibm-aix4.[23]* )
4753 opsys=aix4-2
4755 rs6000-ibm-aix[56]* )
4756 opsys=aix4-2
4758 powerpc-ibm-aix[56]* )
4759 opsys=aix4-2
4762 ## Silicon Graphics machines
4763 ## Iris 4D
4764 mips-sgi-irix6.5 )
4765 opsys=irix6-5
4766 # Without defining _LANGUAGE_C, things get masked out in the headers
4767 # so that, for instance, grepping for `free' in stdlib.h fails and
4768 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4769 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4772 ## Suns
4773 *-sun-solaris* \
4774 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4775 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4776 case "${canonical}" in
4777 i[3456]86-*-* ) ;;
4778 amd64-*-*|x86_64-*-*) ;;
4779 sparc* ) ;;
4780 * ) unported=yes ;;
4781 esac
4782 case "${canonical}" in
4783 *-sunos5.6* | *-solaris2.6* )
4784 opsys=sol2-6
4785 RANLIB="ar -ts"
4787 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4788 opsys=sol2-6
4789 emacs_check_sunpro_c=yes
4791 *-sunos5* | *-solaris* )
4792 opsys=sol2-10
4793 emacs_check_sunpro_c=yes
4795 esac
4796 ## Watch out for a compiler that we know will not work.
4797 case "${canonical}" in
4798 *-solaris* | *-sunos5* )
4799 if [ "x$CC" = x/usr/ucb/cc ]; then
4800 ## /usr/ucb/cc doesn't work;
4801 ## we should find some other compiler that does work.
4802 unset CC
4805 *) ;;
4806 esac
4809 ## Intel 386 machines where we don't care about the manufacturer.
4810 i[3456]86-*-* )
4811 case "${canonical}" in
4812 *-darwin* ) opsys=darwin ;;
4813 *-mingw32 )
4814 opsys=mingw32
4815 # MinGW overrides and adds some system headers in nt/inc.
4816 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4818 *-sysv4.2uw* ) opsys=unixware ;;
4819 *-sysv5uw* ) opsys=unixware ;;
4820 *-sysv5OpenUNIX* ) opsys=unixware ;;
4821 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4822 esac
4826 unported=yes
4828 esac
4830 ### If the code above didn't choose an operating system, just choose
4831 ### an operating system based on the configuration name. You really
4832 ### only want to use this when you have no idea what the right
4833 ### operating system is; if you know what operating systems a machine
4834 ### runs, it's cleaner to make it explicit in the case statement
4835 ### above.
4836 if test x"${opsys}" = x; then
4837 case "${canonical}" in
4838 *-gnu* ) opsys=gnu ;;
4840 unported=yes
4842 esac
4847 if test $unported = yes; then
4848 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4849 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4853 #### Choose a compiler.
4855 ac_ext=c
4856 ac_cpp='$CPP $CPPFLAGS'
4857 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4858 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4859 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4860 if test -n "$ac_tool_prefix"; then
4861 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4862 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4864 $as_echo_n "checking for $ac_word... " >&6; }
4865 if test "${ac_cv_prog_CC+set}" = set; then :
4866 $as_echo_n "(cached) " >&6
4867 else
4868 if test -n "$CC"; then
4869 ac_cv_prog_CC="$CC" # Let the user override the test.
4870 else
4871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4872 for as_dir in $PATH
4874 IFS=$as_save_IFS
4875 test -z "$as_dir" && as_dir=.
4876 for ac_exec_ext in '' $ac_executable_extensions; do
4877 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4878 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4880 break 2
4882 done
4883 done
4884 IFS=$as_save_IFS
4888 CC=$ac_cv_prog_CC
4889 if test -n "$CC"; then
4890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4891 $as_echo "$CC" >&6; }
4892 else
4893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4894 $as_echo "no" >&6; }
4899 if test -z "$ac_cv_prog_CC"; then
4900 ac_ct_CC=$CC
4901 # Extract the first word of "gcc", so it can be a program name with args.
4902 set dummy gcc; ac_word=$2
4903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4904 $as_echo_n "checking for $ac_word... " >&6; }
4905 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4906 $as_echo_n "(cached) " >&6
4907 else
4908 if test -n "$ac_ct_CC"; then
4909 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4910 else
4911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4912 for as_dir in $PATH
4914 IFS=$as_save_IFS
4915 test -z "$as_dir" && as_dir=.
4916 for ac_exec_ext in '' $ac_executable_extensions; do
4917 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4918 ac_cv_prog_ac_ct_CC="gcc"
4919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4920 break 2
4922 done
4923 done
4924 IFS=$as_save_IFS
4928 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4929 if test -n "$ac_ct_CC"; then
4930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4931 $as_echo "$ac_ct_CC" >&6; }
4932 else
4933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4934 $as_echo "no" >&6; }
4937 if test "x$ac_ct_CC" = x; then
4938 CC=""
4939 else
4940 case $cross_compiling:$ac_tool_warned in
4941 yes:)
4942 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4943 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4944 ac_tool_warned=yes ;;
4945 esac
4946 CC=$ac_ct_CC
4948 else
4949 CC="$ac_cv_prog_CC"
4952 if test -z "$CC"; then
4953 if test -n "$ac_tool_prefix"; then
4954 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4955 set dummy ${ac_tool_prefix}cc; ac_word=$2
4956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4957 $as_echo_n "checking for $ac_word... " >&6; }
4958 if test "${ac_cv_prog_CC+set}" = set; then :
4959 $as_echo_n "(cached) " >&6
4960 else
4961 if test -n "$CC"; then
4962 ac_cv_prog_CC="$CC" # Let the user override the test.
4963 else
4964 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4965 for as_dir in $PATH
4967 IFS=$as_save_IFS
4968 test -z "$as_dir" && as_dir=.
4969 for ac_exec_ext in '' $ac_executable_extensions; do
4970 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4971 ac_cv_prog_CC="${ac_tool_prefix}cc"
4972 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4973 break 2
4975 done
4976 done
4977 IFS=$as_save_IFS
4981 CC=$ac_cv_prog_CC
4982 if test -n "$CC"; then
4983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4984 $as_echo "$CC" >&6; }
4985 else
4986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4987 $as_echo "no" >&6; }
4993 if test -z "$CC"; then
4994 # Extract the first word of "cc", so it can be a program name with args.
4995 set dummy cc; ac_word=$2
4996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4997 $as_echo_n "checking for $ac_word... " >&6; }
4998 if test "${ac_cv_prog_CC+set}" = set; then :
4999 $as_echo_n "(cached) " >&6
5000 else
5001 if test -n "$CC"; then
5002 ac_cv_prog_CC="$CC" # Let the user override the test.
5003 else
5004 ac_prog_rejected=no
5005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5006 for as_dir in $PATH
5008 IFS=$as_save_IFS
5009 test -z "$as_dir" && as_dir=.
5010 for ac_exec_ext in '' $ac_executable_extensions; do
5011 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5012 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5013 ac_prog_rejected=yes
5014 continue
5016 ac_cv_prog_CC="cc"
5017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5018 break 2
5020 done
5021 done
5022 IFS=$as_save_IFS
5024 if test $ac_prog_rejected = yes; then
5025 # We found a bogon in the path, so make sure we never use it.
5026 set dummy $ac_cv_prog_CC
5027 shift
5028 if test $# != 0; then
5029 # We chose a different compiler from the bogus one.
5030 # However, it has the same basename, so the bogon will be chosen
5031 # first if we set CC to just the basename; use the full file name.
5032 shift
5033 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5038 CC=$ac_cv_prog_CC
5039 if test -n "$CC"; then
5040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5041 $as_echo "$CC" >&6; }
5042 else
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5044 $as_echo "no" >&6; }
5049 if test -z "$CC"; then
5050 if test -n "$ac_tool_prefix"; then
5051 for ac_prog in cl.exe
5053 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5054 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5056 $as_echo_n "checking for $ac_word... " >&6; }
5057 if test "${ac_cv_prog_CC+set}" = set; then :
5058 $as_echo_n "(cached) " >&6
5059 else
5060 if test -n "$CC"; then
5061 ac_cv_prog_CC="$CC" # Let the user override the test.
5062 else
5063 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5064 for as_dir in $PATH
5066 IFS=$as_save_IFS
5067 test -z "$as_dir" && as_dir=.
5068 for ac_exec_ext in '' $ac_executable_extensions; do
5069 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5070 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5071 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5072 break 2
5074 done
5075 done
5076 IFS=$as_save_IFS
5080 CC=$ac_cv_prog_CC
5081 if test -n "$CC"; then
5082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5083 $as_echo "$CC" >&6; }
5084 else
5085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5086 $as_echo "no" >&6; }
5090 test -n "$CC" && break
5091 done
5093 if test -z "$CC"; then
5094 ac_ct_CC=$CC
5095 for ac_prog in cl.exe
5097 # Extract the first word of "$ac_prog", so it can be a program name with args.
5098 set dummy $ac_prog; ac_word=$2
5099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5100 $as_echo_n "checking for $ac_word... " >&6; }
5101 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5102 $as_echo_n "(cached) " >&6
5103 else
5104 if test -n "$ac_ct_CC"; then
5105 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5106 else
5107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5108 for as_dir in $PATH
5110 IFS=$as_save_IFS
5111 test -z "$as_dir" && as_dir=.
5112 for ac_exec_ext in '' $ac_executable_extensions; do
5113 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5114 ac_cv_prog_ac_ct_CC="$ac_prog"
5115 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5116 break 2
5118 done
5119 done
5120 IFS=$as_save_IFS
5124 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5125 if test -n "$ac_ct_CC"; then
5126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5127 $as_echo "$ac_ct_CC" >&6; }
5128 else
5129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5130 $as_echo "no" >&6; }
5134 test -n "$ac_ct_CC" && break
5135 done
5137 if test "x$ac_ct_CC" = x; then
5138 CC=""
5139 else
5140 case $cross_compiling:$ac_tool_warned in
5141 yes:)
5142 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5143 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5144 ac_tool_warned=yes ;;
5145 esac
5146 CC=$ac_ct_CC
5153 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5154 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5155 as_fn_error "no acceptable C compiler found in \$PATH
5156 See \`config.log' for more details." "$LINENO" 5; }
5158 # Provide some information about the compiler.
5159 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5160 set X $ac_compile
5161 ac_compiler=$2
5162 for ac_option in --version -v -V -qversion; do
5163 { { ac_try="$ac_compiler $ac_option >&5"
5164 case "(($ac_try" in
5165 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5166 *) ac_try_echo=$ac_try;;
5167 esac
5168 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5169 $as_echo "$ac_try_echo"; } >&5
5170 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5171 ac_status=$?
5172 if test -s conftest.err; then
5173 sed '10a\
5174 ... rest of stderr output deleted ...
5175 10q' conftest.err >conftest.er1
5176 cat conftest.er1 >&5
5178 rm -f conftest.er1 conftest.err
5179 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5180 test $ac_status = 0; }
5181 done
5183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5184 /* end confdefs.h. */
5187 main ()
5191 return 0;
5193 _ACEOF
5194 ac_clean_files_save=$ac_clean_files
5195 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5196 # Try to create an executable without -o first, disregard a.out.
5197 # It will help us diagnose broken compilers, and finding out an intuition
5198 # of exeext.
5199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5200 $as_echo_n "checking whether the C compiler works... " >&6; }
5201 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5203 # The possible output files:
5204 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5206 ac_rmfiles=
5207 for ac_file in $ac_files
5209 case $ac_file in
5210 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5211 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5212 esac
5213 done
5214 rm -f $ac_rmfiles
5216 if { { ac_try="$ac_link_default"
5217 case "(($ac_try" in
5218 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5219 *) ac_try_echo=$ac_try;;
5220 esac
5221 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5222 $as_echo "$ac_try_echo"; } >&5
5223 (eval "$ac_link_default") 2>&5
5224 ac_status=$?
5225 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5226 test $ac_status = 0; }; then :
5227 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5228 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5229 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5230 # so that the user can short-circuit this test for compilers unknown to
5231 # Autoconf.
5232 for ac_file in $ac_files ''
5234 test -f "$ac_file" || continue
5235 case $ac_file in
5236 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5238 [ab].out )
5239 # We found the default executable, but exeext='' is most
5240 # certainly right.
5241 break;;
5242 *.* )
5243 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5244 then :; else
5245 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5247 # We set ac_cv_exeext here because the later test for it is not
5248 # safe: cross compilers may not add the suffix if given an `-o'
5249 # argument, so we may need to know it at that point already.
5250 # Even if this section looks crufty: it has the advantage of
5251 # actually working.
5252 break;;
5254 break;;
5255 esac
5256 done
5257 test "$ac_cv_exeext" = no && ac_cv_exeext=
5259 else
5260 ac_file=''
5262 if test -z "$ac_file"; then :
5263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5264 $as_echo "no" >&6; }
5265 $as_echo "$as_me: failed program was:" >&5
5266 sed 's/^/| /' conftest.$ac_ext >&5
5268 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5269 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5270 { as_fn_set_status 77
5271 as_fn_error "C compiler cannot create executables
5272 See \`config.log' for more details." "$LINENO" 5; }; }
5273 else
5274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5275 $as_echo "yes" >&6; }
5277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5278 $as_echo_n "checking for C compiler default output file name... " >&6; }
5279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5280 $as_echo "$ac_file" >&6; }
5281 ac_exeext=$ac_cv_exeext
5283 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5284 ac_clean_files=$ac_clean_files_save
5285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5286 $as_echo_n "checking for suffix of executables... " >&6; }
5287 if { { ac_try="$ac_link"
5288 case "(($ac_try" in
5289 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5290 *) ac_try_echo=$ac_try;;
5291 esac
5292 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5293 $as_echo "$ac_try_echo"; } >&5
5294 (eval "$ac_link") 2>&5
5295 ac_status=$?
5296 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5297 test $ac_status = 0; }; then :
5298 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5299 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5300 # work properly (i.e., refer to `conftest.exe'), while it won't with
5301 # `rm'.
5302 for ac_file in conftest.exe conftest conftest.*; do
5303 test -f "$ac_file" || continue
5304 case $ac_file in
5305 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5306 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5307 break;;
5308 * ) break;;
5309 esac
5310 done
5311 else
5312 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5313 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5314 as_fn_error "cannot compute suffix of executables: cannot compile and link
5315 See \`config.log' for more details." "$LINENO" 5; }
5317 rm -f conftest conftest$ac_cv_exeext
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5319 $as_echo "$ac_cv_exeext" >&6; }
5321 rm -f conftest.$ac_ext
5322 EXEEXT=$ac_cv_exeext
5323 ac_exeext=$EXEEXT
5324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5325 /* end confdefs.h. */
5326 #include <stdio.h>
5328 main ()
5330 FILE *f = fopen ("conftest.out", "w");
5331 return ferror (f) || fclose (f) != 0;
5334 return 0;
5336 _ACEOF
5337 ac_clean_files="$ac_clean_files conftest.out"
5338 # Check that the compiler produces executables we can run. If not, either
5339 # the compiler is broken, or we cross compile.
5340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5341 $as_echo_n "checking whether we are cross compiling... " >&6; }
5342 if test "$cross_compiling" != yes; then
5343 { { ac_try="$ac_link"
5344 case "(($ac_try" in
5345 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5346 *) ac_try_echo=$ac_try;;
5347 esac
5348 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5349 $as_echo "$ac_try_echo"; } >&5
5350 (eval "$ac_link") 2>&5
5351 ac_status=$?
5352 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5353 test $ac_status = 0; }
5354 if { ac_try='./conftest$ac_cv_exeext'
5355 { { case "(($ac_try" in
5356 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5357 *) ac_try_echo=$ac_try;;
5358 esac
5359 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5360 $as_echo "$ac_try_echo"; } >&5
5361 (eval "$ac_try") 2>&5
5362 ac_status=$?
5363 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5364 test $ac_status = 0; }; }; then
5365 cross_compiling=no
5366 else
5367 if test "$cross_compiling" = maybe; then
5368 cross_compiling=yes
5369 else
5370 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5371 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5372 as_fn_error "cannot run C compiled programs.
5373 If you meant to cross compile, use \`--host'.
5374 See \`config.log' for more details." "$LINENO" 5; }
5378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5379 $as_echo "$cross_compiling" >&6; }
5381 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5382 ac_clean_files=$ac_clean_files_save
5383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5384 $as_echo_n "checking for suffix of object files... " >&6; }
5385 if test "${ac_cv_objext+set}" = set; then :
5386 $as_echo_n "(cached) " >&6
5387 else
5388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5389 /* end confdefs.h. */
5392 main ()
5396 return 0;
5398 _ACEOF
5399 rm -f conftest.o conftest.obj
5400 if { { ac_try="$ac_compile"
5401 case "(($ac_try" in
5402 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5403 *) ac_try_echo=$ac_try;;
5404 esac
5405 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5406 $as_echo "$ac_try_echo"; } >&5
5407 (eval "$ac_compile") 2>&5
5408 ac_status=$?
5409 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5410 test $ac_status = 0; }; then :
5411 for ac_file in conftest.o conftest.obj conftest.*; do
5412 test -f "$ac_file" || continue;
5413 case $ac_file in
5414 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5415 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5416 break;;
5417 esac
5418 done
5419 else
5420 $as_echo "$as_me: failed program was:" >&5
5421 sed 's/^/| /' conftest.$ac_ext >&5
5423 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5424 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5425 as_fn_error "cannot compute suffix of object files: cannot compile
5426 See \`config.log' for more details." "$LINENO" 5; }
5428 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5431 $as_echo "$ac_cv_objext" >&6; }
5432 OBJEXT=$ac_cv_objext
5433 ac_objext=$OBJEXT
5434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5435 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5436 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5437 $as_echo_n "(cached) " >&6
5438 else
5439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5440 /* end confdefs.h. */
5443 main ()
5445 #ifndef __GNUC__
5446 choke me
5447 #endif
5450 return 0;
5452 _ACEOF
5453 if ac_fn_c_try_compile "$LINENO"; then :
5454 ac_compiler_gnu=yes
5455 else
5456 ac_compiler_gnu=no
5458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5459 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5463 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5464 if test $ac_compiler_gnu = yes; then
5465 GCC=yes
5466 else
5467 GCC=
5469 ac_test_CFLAGS=${CFLAGS+set}
5470 ac_save_CFLAGS=$CFLAGS
5471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5472 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5473 if test "${ac_cv_prog_cc_g+set}" = set; then :
5474 $as_echo_n "(cached) " >&6
5475 else
5476 ac_save_c_werror_flag=$ac_c_werror_flag
5477 ac_c_werror_flag=yes
5478 ac_cv_prog_cc_g=no
5479 CFLAGS="-g"
5480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5481 /* end confdefs.h. */
5484 main ()
5488 return 0;
5490 _ACEOF
5491 if ac_fn_c_try_compile "$LINENO"; then :
5492 ac_cv_prog_cc_g=yes
5493 else
5494 CFLAGS=""
5495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5496 /* end confdefs.h. */
5499 main ()
5503 return 0;
5505 _ACEOF
5506 if ac_fn_c_try_compile "$LINENO"; then :
5508 else
5509 ac_c_werror_flag=$ac_save_c_werror_flag
5510 CFLAGS="-g"
5511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5512 /* end confdefs.h. */
5515 main ()
5519 return 0;
5521 _ACEOF
5522 if ac_fn_c_try_compile "$LINENO"; then :
5523 ac_cv_prog_cc_g=yes
5525 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5530 ac_c_werror_flag=$ac_save_c_werror_flag
5532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5533 $as_echo "$ac_cv_prog_cc_g" >&6; }
5534 if test "$ac_test_CFLAGS" = set; then
5535 CFLAGS=$ac_save_CFLAGS
5536 elif test $ac_cv_prog_cc_g = yes; then
5537 if test "$GCC" = yes; then
5538 CFLAGS="-g -O2"
5539 else
5540 CFLAGS="-g"
5542 else
5543 if test "$GCC" = yes; then
5544 CFLAGS="-O2"
5545 else
5546 CFLAGS=
5549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5550 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5551 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5552 $as_echo_n "(cached) " >&6
5553 else
5554 ac_cv_prog_cc_c89=no
5555 ac_save_CC=$CC
5556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5557 /* end confdefs.h. */
5558 #include <stdarg.h>
5559 #include <stdio.h>
5560 #include <sys/types.h>
5561 #include <sys/stat.h>
5562 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5563 struct buf { int x; };
5564 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5565 static char *e (p, i)
5566 char **p;
5567 int i;
5569 return p[i];
5571 static char *f (char * (*g) (char **, int), char **p, ...)
5573 char *s;
5574 va_list v;
5575 va_start (v,p);
5576 s = g (p, va_arg (v,int));
5577 va_end (v);
5578 return s;
5581 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5582 function prototypes and stuff, but not '\xHH' hex character constants.
5583 These don't provoke an error unfortunately, instead are silently treated
5584 as 'x'. The following induces an error, until -std is added to get
5585 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5586 array size at least. It's necessary to write '\x00'==0 to get something
5587 that's true only with -std. */
5588 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5590 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5591 inside strings and character constants. */
5592 #define FOO(x) 'x'
5593 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5595 int test (int i, double x);
5596 struct s1 {int (*f) (int a);};
5597 struct s2 {int (*f) (double a);};
5598 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5599 int argc;
5600 char **argv;
5602 main ()
5604 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5606 return 0;
5608 _ACEOF
5609 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5610 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5612 CC="$ac_save_CC $ac_arg"
5613 if ac_fn_c_try_compile "$LINENO"; then :
5614 ac_cv_prog_cc_c89=$ac_arg
5616 rm -f core conftest.err conftest.$ac_objext
5617 test "x$ac_cv_prog_cc_c89" != "xno" && break
5618 done
5619 rm -f conftest.$ac_ext
5620 CC=$ac_save_CC
5623 # AC_CACHE_VAL
5624 case "x$ac_cv_prog_cc_c89" in
5626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5627 $as_echo "none needed" >&6; } ;;
5628 xno)
5629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5630 $as_echo "unsupported" >&6; } ;;
5632 CC="$CC $ac_cv_prog_cc_c89"
5633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5634 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5635 esac
5636 if test "x$ac_cv_prog_cc_c89" != xno; then :
5640 ac_ext=c
5641 ac_cpp='$CPP $CPPFLAGS'
5642 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5643 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5644 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5645 DEPDIR="${am__leading_dot}deps"
5647 ac_config_commands="$ac_config_commands depfiles"
5650 am_make=${MAKE-make}
5651 cat > confinc << 'END'
5652 am__doit:
5653 @echo this is the am__doit target
5654 .PHONY: am__doit
5656 # If we don't find an include directive, just comment out the code.
5657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5658 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5659 am__include="#"
5660 am__quote=
5661 _am_result=none
5662 # First try GNU make style include.
5663 echo "include confinc" > confmf
5664 # Ignore all kinds of additional output from `make'.
5665 case `$am_make -s -f confmf 2> /dev/null` in #(
5666 *the\ am__doit\ target*)
5667 am__include=include
5668 am__quote=
5669 _am_result=GNU
5671 esac
5672 # Now try BSD make style include.
5673 if test "$am__include" = "#"; then
5674 echo '.include "confinc"' > confmf
5675 case `$am_make -s -f confmf 2> /dev/null` in #(
5676 *the\ am__doit\ target*)
5677 am__include=.include
5678 am__quote="\""
5679 _am_result=BSD
5681 esac
5685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5686 $as_echo "$_am_result" >&6; }
5687 rm -f confinc confmf
5689 # Check whether --enable-dependency-tracking was given.
5690 if test "${enable_dependency_tracking+set}" = set; then :
5691 enableval=$enable_dependency_tracking;
5694 if test "x$enable_dependency_tracking" != xno; then
5695 am_depcomp="$ac_aux_dir/depcomp"
5696 AMDEPBACKSLASH='\'
5698 if test "x$enable_dependency_tracking" != xno; then
5699 AMDEP_TRUE=
5700 AMDEP_FALSE='#'
5701 else
5702 AMDEP_TRUE='#'
5703 AMDEP_FALSE=
5708 depcc="$CC" am_compiler_list=
5710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5711 $as_echo_n "checking dependency style of $depcc... " >&6; }
5712 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5713 $as_echo_n "(cached) " >&6
5714 else
5715 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5716 # We make a subdir and do the tests there. Otherwise we can end up
5717 # making bogus files that we don't know about and never remove. For
5718 # instance it was reported that on HP-UX the gcc test will end up
5719 # making a dummy file named `D' -- because `-MD' means `put the output
5720 # in D'.
5721 mkdir conftest.dir
5722 # Copy depcomp to subdir because otherwise we won't find it if we're
5723 # using a relative directory.
5724 cp "$am_depcomp" conftest.dir
5725 cd conftest.dir
5726 # We will build objects and dependencies in a subdirectory because
5727 # it helps to detect inapplicable dependency modes. For instance
5728 # both Tru64's cc and ICC support -MD to output dependencies as a
5729 # side effect of compilation, but ICC will put the dependencies in
5730 # the current directory while Tru64 will put them in the object
5731 # directory.
5732 mkdir sub
5734 am_cv_CC_dependencies_compiler_type=none
5735 if test "$am_compiler_list" = ""; then
5736 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5738 am__universal=false
5739 case " $depcc " in #(
5740 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5741 esac
5743 for depmode in $am_compiler_list; do
5744 # Setup a source with many dependencies, because some compilers
5745 # like to wrap large dependency lists on column 80 (with \), and
5746 # we should not choose a depcomp mode which is confused by this.
5748 # We need to recreate these files for each test, as the compiler may
5749 # overwrite some of them when testing with obscure command lines.
5750 # This happens at least with the AIX C compiler.
5751 : > sub/conftest.c
5752 for i in 1 2 3 4 5 6; do
5753 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5754 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5755 # Solaris 8's {/usr,}/bin/sh.
5756 touch sub/conftst$i.h
5757 done
5758 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5760 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5761 # mode. It turns out that the SunPro C++ compiler does not properly
5762 # handle `-M -o', and we need to detect this. Also, some Intel
5763 # versions had trouble with output in subdirs
5764 am__obj=sub/conftest.${OBJEXT-o}
5765 am__minus_obj="-o $am__obj"
5766 case $depmode in
5767 gcc)
5768 # This depmode causes a compiler race in universal mode.
5769 test "$am__universal" = false || continue
5771 nosideeffect)
5772 # after this tag, mechanisms are not by side-effect, so they'll
5773 # only be used when explicitly requested
5774 if test "x$enable_dependency_tracking" = xyes; then
5775 continue
5776 else
5777 break
5780 msvisualcpp | msvcmsys)
5781 # This compiler won't grok `-c -o', but also, the minuso test has
5782 # not run yet. These depmodes are late enough in the game, and
5783 # so weak that their functioning should not be impacted.
5784 am__obj=conftest.${OBJEXT-o}
5785 am__minus_obj=
5787 none) break ;;
5788 esac
5789 if depmode=$depmode \
5790 source=sub/conftest.c object=$am__obj \
5791 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5792 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5793 >/dev/null 2>conftest.err &&
5794 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5795 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5796 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5797 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5798 # icc doesn't choke on unknown options, it will just issue warnings
5799 # or remarks (even with -Werror). So we grep stderr for any message
5800 # that says an option was ignored or not supported.
5801 # When given -MP, icc 7.0 and 7.1 complain thusly:
5802 # icc: Command line warning: ignoring option '-M'; no argument required
5803 # The diagnosis changed in icc 8.0:
5804 # icc: Command line remark: option '-MP' not supported
5805 if (grep 'ignoring option' conftest.err ||
5806 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5807 am_cv_CC_dependencies_compiler_type=$depmode
5808 break
5811 done
5813 cd ..
5814 rm -rf conftest.dir
5815 else
5816 am_cv_CC_dependencies_compiler_type=none
5820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5821 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5822 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5825 test "x$enable_dependency_tracking" != xno \
5826 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5827 am__fastdepCC_TRUE=
5828 am__fastdepCC_FALSE='#'
5829 else
5830 am__fastdepCC_TRUE='#'
5831 am__fastdepCC_FALSE=
5835 if test "x$CC" != xcc; then
5836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5837 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5838 else
5839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5840 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5842 set dummy $CC; ac_cc=`$as_echo "$2" |
5843 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5844 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5845 $as_echo_n "(cached) " >&6
5846 else
5847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5848 /* end confdefs.h. */
5851 main ()
5855 return 0;
5857 _ACEOF
5858 # Make sure it works both with $CC and with simple cc.
5859 # We do the test twice because some compilers refuse to overwrite an
5860 # existing .o file with -o, though they will create one.
5861 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5862 rm -f conftest2.*
5863 if { { case "(($ac_try" in
5864 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5865 *) ac_try_echo=$ac_try;;
5866 esac
5867 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5868 $as_echo "$ac_try_echo"; } >&5
5869 (eval "$ac_try") 2>&5
5870 ac_status=$?
5871 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5872 test $ac_status = 0; } &&
5873 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5874 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5875 *) ac_try_echo=$ac_try;;
5876 esac
5877 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5878 $as_echo "$ac_try_echo"; } >&5
5879 (eval "$ac_try") 2>&5
5880 ac_status=$?
5881 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5882 test $ac_status = 0; };
5883 then
5884 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5885 if test "x$CC" != xcc; then
5886 # Test first that cc exists at all.
5887 if { ac_try='cc -c conftest.$ac_ext >&5'
5888 { { 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; }; }; then
5898 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5899 rm -f conftest2.*
5900 if { { case "(($ac_try" in
5901 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5902 *) ac_try_echo=$ac_try;;
5903 esac
5904 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5905 $as_echo "$ac_try_echo"; } >&5
5906 (eval "$ac_try") 2>&5
5907 ac_status=$?
5908 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5909 test $ac_status = 0; } &&
5910 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5911 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5912 *) ac_try_echo=$ac_try;;
5913 esac
5914 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5915 $as_echo "$ac_try_echo"; } >&5
5916 (eval "$ac_try") 2>&5
5917 ac_status=$?
5918 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5919 test $ac_status = 0; };
5920 then
5921 # cc works too.
5923 else
5924 # cc exists but doesn't like -o.
5925 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5929 else
5930 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5932 rm -f core conftest*
5935 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5937 $as_echo "yes" >&6; }
5938 else
5939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5940 $as_echo "no" >&6; }
5942 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5946 # FIXME: we rely on the cache variable name because
5947 # there is no other way.
5948 set dummy $CC
5949 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5950 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5951 if test "$am_t" != yes; then
5952 # Losing compiler, so override with the script.
5953 # FIXME: It is wrong to rewrite CC.
5954 # But if we don't then we get into trouble of one sort or another.
5955 # A longer-term fix would be to have automake use am__CC in this case,
5956 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5957 CC="$am_aux_dir/compile $CC"
5962 if test x$GCC = xyes; then
5963 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5964 else
5965 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5968 if test "x$opsys" = "xmingw32"; then
5969 BUILDING_FOR_WINDOWSNT_TRUE=
5970 BUILDING_FOR_WINDOWSNT_FALSE='#'
5971 else
5972 BUILDING_FOR_WINDOWSNT_TRUE='#'
5973 BUILDING_FOR_WINDOWSNT_FALSE=
5977 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
5978 # as we don't use them.
5980 # Avoid gnulib's threadlib module, as we do threads our own way.
5983 # Initialize gnulib right after choosing the compiler.
5985 ac_ext=c
5986 ac_cpp='$CPP $CPPFLAGS'
5987 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5988 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5989 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5991 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5992 # On Suns, sometimes $CPP names a directory.
5993 if test -n "$CPP" && test -d "$CPP"; then
5994 CPP=
5996 if test -z "$CPP"; then
5997 if test "${ac_cv_prog_CPP+set}" = set; then :
5998 $as_echo_n "(cached) " >&6
5999 else
6000 # Double quotes because CPP needs to be expanded
6001 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6003 ac_preproc_ok=false
6004 for ac_c_preproc_warn_flag in '' yes
6006 # Use a header file that comes with gcc, so configuring glibc
6007 # with a fresh cross-compiler works.
6008 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6009 # <limits.h> exists even on freestanding compilers.
6010 # On the NeXT, cc -E runs the code through the compiler's parser,
6011 # not just through cpp. "Syntax error" is here to catch this case.
6012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6013 /* end confdefs.h. */
6014 #ifdef __STDC__
6015 # include <limits.h>
6016 #else
6017 # include <assert.h>
6018 #endif
6019 Syntax error
6020 _ACEOF
6021 if ac_fn_c_try_cpp "$LINENO"; then :
6023 else
6024 # Broken: fails on valid input.
6025 continue
6027 rm -f conftest.err conftest.$ac_ext
6029 # OK, works on sane cases. Now check whether nonexistent headers
6030 # can be detected and how.
6031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6032 /* end confdefs.h. */
6033 #include <ac_nonexistent.h>
6034 _ACEOF
6035 if ac_fn_c_try_cpp "$LINENO"; then :
6036 # Broken: success on invalid input.
6037 continue
6038 else
6039 # Passes both tests.
6040 ac_preproc_ok=:
6041 break
6043 rm -f conftest.err conftest.$ac_ext
6045 done
6046 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6047 rm -f conftest.err conftest.$ac_ext
6048 if $ac_preproc_ok; then :
6049 break
6052 done
6053 ac_cv_prog_CPP=$CPP
6056 CPP=$ac_cv_prog_CPP
6057 else
6058 ac_cv_prog_CPP=$CPP
6060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6061 $as_echo "$CPP" >&6; }
6062 ac_preproc_ok=false
6063 for ac_c_preproc_warn_flag in '' yes
6065 # Use a header file that comes with gcc, so configuring glibc
6066 # with a fresh cross-compiler works.
6067 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6068 # <limits.h> exists even on freestanding compilers.
6069 # On the NeXT, cc -E runs the code through the compiler's parser,
6070 # not just through cpp. "Syntax error" is here to catch this case.
6071 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6072 /* end confdefs.h. */
6073 #ifdef __STDC__
6074 # include <limits.h>
6075 #else
6076 # include <assert.h>
6077 #endif
6078 Syntax error
6079 _ACEOF
6080 if ac_fn_c_try_cpp "$LINENO"; then :
6082 else
6083 # Broken: fails on valid input.
6084 continue
6086 rm -f conftest.err conftest.$ac_ext
6088 # OK, works on sane cases. Now check whether nonexistent headers
6089 # can be detected and how.
6090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6091 /* end confdefs.h. */
6092 #include <ac_nonexistent.h>
6093 _ACEOF
6094 if ac_fn_c_try_cpp "$LINENO"; then :
6095 # Broken: success on invalid input.
6096 continue
6097 else
6098 # Passes both tests.
6099 ac_preproc_ok=:
6100 break
6102 rm -f conftest.err conftest.$ac_ext
6104 done
6105 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6106 rm -f conftest.err conftest.$ac_ext
6107 if $ac_preproc_ok; then :
6109 else
6110 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6111 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6112 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6113 See \`config.log' for more details." "$LINENO" 5; }
6116 ac_ext=c
6117 ac_cpp='$CPP $CPPFLAGS'
6118 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6119 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6120 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6124 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6125 if test "${ac_cv_path_GREP+set}" = set; then :
6126 $as_echo_n "(cached) " >&6
6127 else
6128 if test -z "$GREP"; then
6129 ac_path_GREP_found=false
6130 # Loop through the user's path and test for each of PROGNAME-LIST
6131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6132 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6134 IFS=$as_save_IFS
6135 test -z "$as_dir" && as_dir=.
6136 for ac_prog in grep ggrep; do
6137 for ac_exec_ext in '' $ac_executable_extensions; do
6138 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6139 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6140 # Check for GNU ac_path_GREP and select it if it is found.
6141 # Check for GNU $ac_path_GREP
6142 case `"$ac_path_GREP" --version 2>&1` in
6143 *GNU*)
6144 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6146 ac_count=0
6147 $as_echo_n 0123456789 >"conftest.in"
6148 while :
6150 cat "conftest.in" "conftest.in" >"conftest.tmp"
6151 mv "conftest.tmp" "conftest.in"
6152 cp "conftest.in" "conftest.nl"
6153 $as_echo 'GREP' >> "conftest.nl"
6154 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6155 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6156 as_fn_arith $ac_count + 1 && ac_count=$as_val
6157 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6158 # Best one so far, save it but keep looking for a better one
6159 ac_cv_path_GREP="$ac_path_GREP"
6160 ac_path_GREP_max=$ac_count
6162 # 10*(2^10) chars as input seems more than enough
6163 test $ac_count -gt 10 && break
6164 done
6165 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6166 esac
6168 $ac_path_GREP_found && break 3
6169 done
6170 done
6171 done
6172 IFS=$as_save_IFS
6173 if test -z "$ac_cv_path_GREP"; then
6174 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6176 else
6177 ac_cv_path_GREP=$GREP
6181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6182 $as_echo "$ac_cv_path_GREP" >&6; }
6183 GREP="$ac_cv_path_GREP"
6186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6187 $as_echo_n "checking for egrep... " >&6; }
6188 if test "${ac_cv_path_EGREP+set}" = set; then :
6189 $as_echo_n "(cached) " >&6
6190 else
6191 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6192 then ac_cv_path_EGREP="$GREP -E"
6193 else
6194 if test -z "$EGREP"; then
6195 ac_path_EGREP_found=false
6196 # Loop through the user's path and test for each of PROGNAME-LIST
6197 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6198 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6200 IFS=$as_save_IFS
6201 test -z "$as_dir" && as_dir=.
6202 for ac_prog in egrep; do
6203 for ac_exec_ext in '' $ac_executable_extensions; do
6204 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6205 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6206 # Check for GNU ac_path_EGREP and select it if it is found.
6207 # Check for GNU $ac_path_EGREP
6208 case `"$ac_path_EGREP" --version 2>&1` in
6209 *GNU*)
6210 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6212 ac_count=0
6213 $as_echo_n 0123456789 >"conftest.in"
6214 while :
6216 cat "conftest.in" "conftest.in" >"conftest.tmp"
6217 mv "conftest.tmp" "conftest.in"
6218 cp "conftest.in" "conftest.nl"
6219 $as_echo 'EGREP' >> "conftest.nl"
6220 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6221 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6222 as_fn_arith $ac_count + 1 && ac_count=$as_val
6223 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6224 # Best one so far, save it but keep looking for a better one
6225 ac_cv_path_EGREP="$ac_path_EGREP"
6226 ac_path_EGREP_max=$ac_count
6228 # 10*(2^10) chars as input seems more than enough
6229 test $ac_count -gt 10 && break
6230 done
6231 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6232 esac
6234 $ac_path_EGREP_found && break 3
6235 done
6236 done
6237 done
6238 IFS=$as_save_IFS
6239 if test -z "$ac_cv_path_EGREP"; then
6240 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6242 else
6243 ac_cv_path_EGREP=$EGREP
6248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6249 $as_echo "$ac_cv_path_EGREP" >&6; }
6250 EGREP="$ac_cv_path_EGREP"
6255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6256 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6257 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6258 $as_echo_n "(cached) " >&6
6259 else
6261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6262 /* end confdefs.h. */
6264 #ifdef __ACK__
6265 Amsterdam
6266 #endif
6268 _ACEOF
6269 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6270 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6271 gl_cv_c_amsterdam_compiler=yes
6272 else
6273 gl_cv_c_amsterdam_compiler=no
6275 rm -f conftest*
6279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6280 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6281 if test -z "$AR"; then
6282 if test $gl_cv_c_amsterdam_compiler = yes; then
6283 AR='cc -c.a'
6284 if test -z "$ARFLAGS"; then
6285 ARFLAGS='-o'
6287 else
6288 if test -n "$ac_tool_prefix"; then
6289 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6290 set dummy ${ac_tool_prefix}ar; ac_word=$2
6291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6292 $as_echo_n "checking for $ac_word... " >&6; }
6293 if test "${ac_cv_prog_AR+set}" = set; then :
6294 $as_echo_n "(cached) " >&6
6295 else
6296 if test -n "$AR"; then
6297 ac_cv_prog_AR="$AR" # Let the user override the test.
6298 else
6299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6300 for as_dir in $PATH
6302 IFS=$as_save_IFS
6303 test -z "$as_dir" && as_dir=.
6304 for ac_exec_ext in '' $ac_executable_extensions; do
6305 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6306 ac_cv_prog_AR="${ac_tool_prefix}ar"
6307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6308 break 2
6310 done
6311 done
6312 IFS=$as_save_IFS
6316 AR=$ac_cv_prog_AR
6317 if test -n "$AR"; then
6318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6319 $as_echo "$AR" >&6; }
6320 else
6321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6322 $as_echo "no" >&6; }
6327 if test -z "$ac_cv_prog_AR"; then
6328 ac_ct_AR=$AR
6329 # Extract the first word of "ar", so it can be a program name with args.
6330 set dummy ar; ac_word=$2
6331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6332 $as_echo_n "checking for $ac_word... " >&6; }
6333 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6334 $as_echo_n "(cached) " >&6
6335 else
6336 if test -n "$ac_ct_AR"; then
6337 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6338 else
6339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6340 for as_dir in $PATH
6342 IFS=$as_save_IFS
6343 test -z "$as_dir" && as_dir=.
6344 for ac_exec_ext in '' $ac_executable_extensions; do
6345 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6346 ac_cv_prog_ac_ct_AR="ar"
6347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6348 break 2
6350 done
6351 done
6352 IFS=$as_save_IFS
6356 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6357 if test -n "$ac_ct_AR"; then
6358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6359 $as_echo "$ac_ct_AR" >&6; }
6360 else
6361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6362 $as_echo "no" >&6; }
6365 if test "x$ac_ct_AR" = x; then
6366 AR="ar"
6367 else
6368 case $cross_compiling:$ac_tool_warned in
6369 yes:)
6370 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6371 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6372 ac_tool_warned=yes ;;
6373 esac
6374 AR=$ac_ct_AR
6376 else
6377 AR="$ac_cv_prog_AR"
6380 if test -z "$ARFLAGS"; then
6381 ARFLAGS='cru'
6384 else
6385 if test -z "$ARFLAGS"; then
6386 ARFLAGS='cru'
6391 if test -z "$RANLIB"; then
6392 if test $gl_cv_c_amsterdam_compiler = yes; then
6393 RANLIB=':'
6394 else
6395 if test -n "$ac_tool_prefix"; then
6396 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6397 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6399 $as_echo_n "checking for $ac_word... " >&6; }
6400 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6401 $as_echo_n "(cached) " >&6
6402 else
6403 if test -n "$RANLIB"; then
6404 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6405 else
6406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6407 for as_dir in $PATH
6409 IFS=$as_save_IFS
6410 test -z "$as_dir" && as_dir=.
6411 for ac_exec_ext in '' $ac_executable_extensions; do
6412 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6413 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6415 break 2
6417 done
6418 done
6419 IFS=$as_save_IFS
6423 RANLIB=$ac_cv_prog_RANLIB
6424 if test -n "$RANLIB"; then
6425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6426 $as_echo "$RANLIB" >&6; }
6427 else
6428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6429 $as_echo "no" >&6; }
6434 if test -z "$ac_cv_prog_RANLIB"; then
6435 ac_ct_RANLIB=$RANLIB
6436 # Extract the first word of "ranlib", so it can be a program name with args.
6437 set dummy ranlib; ac_word=$2
6438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6439 $as_echo_n "checking for $ac_word... " >&6; }
6440 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6441 $as_echo_n "(cached) " >&6
6442 else
6443 if test -n "$ac_ct_RANLIB"; then
6444 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6445 else
6446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6447 for as_dir in $PATH
6449 IFS=$as_save_IFS
6450 test -z "$as_dir" && as_dir=.
6451 for ac_exec_ext in '' $ac_executable_extensions; do
6452 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6453 ac_cv_prog_ac_ct_RANLIB="ranlib"
6454 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6455 break 2
6457 done
6458 done
6459 IFS=$as_save_IFS
6463 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6464 if test -n "$ac_ct_RANLIB"; then
6465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6466 $as_echo "$ac_ct_RANLIB" >&6; }
6467 else
6468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6469 $as_echo "no" >&6; }
6472 if test "x$ac_ct_RANLIB" = x; then
6473 RANLIB=":"
6474 else
6475 case $cross_compiling:$ac_tool_warned in
6476 yes:)
6477 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6478 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6479 ac_tool_warned=yes ;;
6480 esac
6481 RANLIB=$ac_ct_RANLIB
6483 else
6484 RANLIB="$ac_cv_prog_RANLIB"
6491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6492 $as_echo_n "checking for ANSI C header files... " >&6; }
6493 if test "${ac_cv_header_stdc+set}" = set; then :
6494 $as_echo_n "(cached) " >&6
6495 else
6496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6497 /* end confdefs.h. */
6498 #include <stdlib.h>
6499 #include <stdarg.h>
6500 #include <string.h>
6501 #include <float.h>
6504 main ()
6508 return 0;
6510 _ACEOF
6511 if ac_fn_c_try_compile "$LINENO"; then :
6512 ac_cv_header_stdc=yes
6513 else
6514 ac_cv_header_stdc=no
6516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6518 if test $ac_cv_header_stdc = yes; then
6519 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6521 /* end confdefs.h. */
6522 #include <string.h>
6524 _ACEOF
6525 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6526 $EGREP "memchr" >/dev/null 2>&1; then :
6528 else
6529 ac_cv_header_stdc=no
6531 rm -f conftest*
6535 if test $ac_cv_header_stdc = yes; then
6536 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6538 /* end confdefs.h. */
6539 #include <stdlib.h>
6541 _ACEOF
6542 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6543 $EGREP "free" >/dev/null 2>&1; then :
6545 else
6546 ac_cv_header_stdc=no
6548 rm -f conftest*
6552 if test $ac_cv_header_stdc = yes; then
6553 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6554 if test "$cross_compiling" = yes; then :
6556 else
6557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6558 /* end confdefs.h. */
6559 #include <ctype.h>
6560 #include <stdlib.h>
6561 #if ((' ' & 0x0FF) == 0x020)
6562 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6563 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6564 #else
6565 # define ISLOWER(c) \
6566 (('a' <= (c) && (c) <= 'i') \
6567 || ('j' <= (c) && (c) <= 'r') \
6568 || ('s' <= (c) && (c) <= 'z'))
6569 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6570 #endif
6572 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6574 main ()
6576 int i;
6577 for (i = 0; i < 256; i++)
6578 if (XOR (islower (i), ISLOWER (i))
6579 || toupper (i) != TOUPPER (i))
6580 return 2;
6581 return 0;
6583 _ACEOF
6584 if ac_fn_c_try_run "$LINENO"; then :
6586 else
6587 ac_cv_header_stdc=no
6589 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6590 conftest.$ac_objext conftest.beam conftest.$ac_ext
6595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6596 $as_echo "$ac_cv_header_stdc" >&6; }
6597 if test $ac_cv_header_stdc = yes; then
6599 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6603 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6604 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6605 inttypes.h stdint.h unistd.h
6606 do :
6607 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6608 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6610 eval as_val=\$$as_ac_Header
6611 if test "x$as_val" = x""yes; then :
6612 cat >>confdefs.h <<_ACEOF
6613 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6614 _ACEOF
6618 done
6622 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6623 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6624 MINIX=yes
6625 else
6626 MINIX=
6630 if test "$MINIX" = yes; then
6632 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6635 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6638 $as_echo "#define _MINIX 1" >>confdefs.h
6641 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6647 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6648 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6649 $as_echo_n "(cached) " >&6
6650 else
6651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6652 /* end confdefs.h. */
6654 # define __EXTENSIONS__ 1
6655 $ac_includes_default
6657 main ()
6661 return 0;
6663 _ACEOF
6664 if ac_fn_c_try_compile "$LINENO"; then :
6665 ac_cv_safe_to_define___extensions__=yes
6666 else
6667 ac_cv_safe_to_define___extensions__=no
6669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6672 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6673 test $ac_cv_safe_to_define___extensions__ = yes &&
6674 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6676 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6678 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6680 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6682 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6684 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6687 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6688 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6689 $as_echo_n "(cached) " >&6
6690 else
6691 ac_cv_should_define__xopen_source=no
6692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6693 /* end confdefs.h. */
6695 #include <wchar.h>
6696 mbstate_t x;
6698 main ()
6702 return 0;
6704 _ACEOF
6705 if ac_fn_c_try_compile "$LINENO"; then :
6707 else
6708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6709 /* end confdefs.h. */
6711 #define _XOPEN_SOURCE 500
6712 #include <wchar.h>
6713 mbstate_t x;
6715 main ()
6719 return 0;
6721 _ACEOF
6722 if ac_fn_c_try_compile "$LINENO"; then :
6723 ac_cv_should_define__xopen_source=yes
6725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6730 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6731 test $ac_cv_should_define__xopen_source = yes &&
6732 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6741 # Check whether --enable-largefile was given.
6742 if test "${enable_largefile+set}" = set; then :
6743 enableval=$enable_largefile;
6746 if test "$enable_largefile" != no; then
6748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6749 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6750 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6751 $as_echo_n "(cached) " >&6
6752 else
6753 ac_cv_sys_largefile_CC=no
6754 if test "$GCC" != yes; then
6755 ac_save_CC=$CC
6756 while :; do
6757 # IRIX 6.2 and later do not support large files by default,
6758 # so use the C compiler's -n32 option if that helps.
6759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6760 /* end confdefs.h. */
6761 #include <sys/types.h>
6762 /* Check that off_t can represent 2**63 - 1 correctly.
6763 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6764 since some C++ compilers masquerading as C compilers
6765 incorrectly reject 9223372036854775807. */
6766 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6767 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6768 && LARGE_OFF_T % 2147483647 == 1)
6769 ? 1 : -1];
6771 main ()
6775 return 0;
6777 _ACEOF
6778 if ac_fn_c_try_compile "$LINENO"; then :
6779 break
6781 rm -f core conftest.err conftest.$ac_objext
6782 CC="$CC -n32"
6783 if ac_fn_c_try_compile "$LINENO"; then :
6784 ac_cv_sys_largefile_CC=' -n32'; break
6786 rm -f core conftest.err conftest.$ac_objext
6787 break
6788 done
6789 CC=$ac_save_CC
6790 rm -f conftest.$ac_ext
6793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6794 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6795 if test "$ac_cv_sys_largefile_CC" != no; then
6796 CC=$CC$ac_cv_sys_largefile_CC
6799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6800 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6801 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6802 $as_echo_n "(cached) " >&6
6803 else
6804 while :; do
6805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6806 /* end confdefs.h. */
6807 #include <sys/types.h>
6808 /* Check that off_t can represent 2**63 - 1 correctly.
6809 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6810 since some C++ compilers masquerading as C compilers
6811 incorrectly reject 9223372036854775807. */
6812 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6813 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6814 && LARGE_OFF_T % 2147483647 == 1)
6815 ? 1 : -1];
6817 main ()
6821 return 0;
6823 _ACEOF
6824 if ac_fn_c_try_compile "$LINENO"; then :
6825 ac_cv_sys_file_offset_bits=no; break
6827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6829 /* end confdefs.h. */
6830 #define _FILE_OFFSET_BITS 64
6831 #include <sys/types.h>
6832 /* Check that off_t can represent 2**63 - 1 correctly.
6833 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6834 since some C++ compilers masquerading as C compilers
6835 incorrectly reject 9223372036854775807. */
6836 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6837 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6838 && LARGE_OFF_T % 2147483647 == 1)
6839 ? 1 : -1];
6841 main ()
6845 return 0;
6847 _ACEOF
6848 if ac_fn_c_try_compile "$LINENO"; then :
6849 ac_cv_sys_file_offset_bits=64; break
6851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6852 ac_cv_sys_file_offset_bits=unknown
6853 break
6854 done
6856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6857 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6858 case $ac_cv_sys_file_offset_bits in #(
6859 no | unknown) ;;
6861 cat >>confdefs.h <<_ACEOF
6862 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6863 _ACEOF
6865 esac
6866 rm -rf conftest*
6867 if test $ac_cv_sys_file_offset_bits = unknown; then
6868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6869 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6870 if test "${ac_cv_sys_large_files+set}" = set; then :
6871 $as_echo_n "(cached) " >&6
6872 else
6873 while :; do
6874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6875 /* end confdefs.h. */
6876 #include <sys/types.h>
6877 /* Check that off_t can represent 2**63 - 1 correctly.
6878 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6879 since some C++ compilers masquerading as C compilers
6880 incorrectly reject 9223372036854775807. */
6881 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6882 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6883 && LARGE_OFF_T % 2147483647 == 1)
6884 ? 1 : -1];
6886 main ()
6890 return 0;
6892 _ACEOF
6893 if ac_fn_c_try_compile "$LINENO"; then :
6894 ac_cv_sys_large_files=no; break
6896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6898 /* end confdefs.h. */
6899 #define _LARGE_FILES 1
6900 #include <sys/types.h>
6901 /* Check that off_t can represent 2**63 - 1 correctly.
6902 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6903 since some C++ compilers masquerading as C compilers
6904 incorrectly reject 9223372036854775807. */
6905 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6906 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6907 && LARGE_OFF_T % 2147483647 == 1)
6908 ? 1 : -1];
6910 main ()
6914 return 0;
6916 _ACEOF
6917 if ac_fn_c_try_compile "$LINENO"; then :
6918 ac_cv_sys_large_files=1; break
6920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6921 ac_cv_sys_large_files=unknown
6922 break
6923 done
6925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6926 $as_echo "$ac_cv_sys_large_files" >&6; }
6927 case $ac_cv_sys_large_files in #(
6928 no | unknown) ;;
6930 cat >>confdefs.h <<_ACEOF
6931 #define _LARGE_FILES $ac_cv_sys_large_files
6932 _ACEOF
6934 esac
6935 rm -rf conftest*
6939 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6943 case $ac_cv_prog_cc_stdc in #(
6944 no) :
6945 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6946 *) :
6947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6948 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6949 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6950 $as_echo_n "(cached) " >&6
6951 else
6952 ac_cv_prog_cc_c99=no
6953 ac_save_CC=$CC
6954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6955 /* end confdefs.h. */
6956 #include <stdarg.h>
6957 #include <stdbool.h>
6958 #include <stdlib.h>
6959 #include <wchar.h>
6960 #include <stdio.h>
6962 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6963 #define debug(...) fprintf (stderr, __VA_ARGS__)
6964 #define showlist(...) puts (#__VA_ARGS__)
6965 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6966 static void
6967 test_varargs_macros (void)
6969 int x = 1234;
6970 int y = 5678;
6971 debug ("Flag");
6972 debug ("X = %d\n", x);
6973 showlist (The first, second, and third items.);
6974 report (x>y, "x is %d but y is %d", x, y);
6977 // Check long long types.
6978 #define BIG64 18446744073709551615ull
6979 #define BIG32 4294967295ul
6980 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6981 #if !BIG_OK
6982 your preprocessor is broken;
6983 #endif
6984 #if BIG_OK
6985 #else
6986 your preprocessor is broken;
6987 #endif
6988 static long long int bignum = -9223372036854775807LL;
6989 static unsigned long long int ubignum = BIG64;
6991 struct incomplete_array
6993 int datasize;
6994 double data[];
6997 struct named_init {
6998 int number;
6999 const wchar_t *name;
7000 double average;
7003 typedef const char *ccp;
7005 static inline int
7006 test_restrict (ccp restrict text)
7008 // See if C++-style comments work.
7009 // Iterate through items via the restricted pointer.
7010 // Also check for declarations in for loops.
7011 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7012 continue;
7013 return 0;
7016 // Check varargs and va_copy.
7017 static void
7018 test_varargs (const char *format, ...)
7020 va_list args;
7021 va_start (args, format);
7022 va_list args_copy;
7023 va_copy (args_copy, args);
7025 const char *str;
7026 int number;
7027 float fnumber;
7029 while (*format)
7031 switch (*format++)
7033 case 's': // string
7034 str = va_arg (args_copy, const char *);
7035 break;
7036 case 'd': // int
7037 number = va_arg (args_copy, int);
7038 break;
7039 case 'f': // float
7040 fnumber = va_arg (args_copy, double);
7041 break;
7042 default:
7043 break;
7046 va_end (args_copy);
7047 va_end (args);
7051 main ()
7054 // Check bool.
7055 _Bool success = false;
7057 // Check restrict.
7058 if (test_restrict ("String literal") == 0)
7059 success = true;
7060 char *restrict newvar = "Another string";
7062 // Check varargs.
7063 test_varargs ("s, d' f .", "string", 65, 34.234);
7064 test_varargs_macros ();
7066 // Check flexible array members.
7067 struct incomplete_array *ia =
7068 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7069 ia->datasize = 10;
7070 for (int i = 0; i < ia->datasize; ++i)
7071 ia->data[i] = i * 1.234;
7073 // Check named initializers.
7074 struct named_init ni = {
7075 .number = 34,
7076 .name = L"Test wide string",
7077 .average = 543.34343,
7080 ni.number = 58;
7082 int dynamic_array[ni.number];
7083 dynamic_array[ni.number - 1] = 543;
7085 // work around unused variable warnings
7086 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7087 || dynamic_array[ni.number - 1] != 543);
7090 return 0;
7092 _ACEOF
7093 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7095 CC="$ac_save_CC $ac_arg"
7096 if ac_fn_c_try_compile "$LINENO"; then :
7097 ac_cv_prog_cc_c99=$ac_arg
7099 rm -f core conftest.err conftest.$ac_objext
7100 test "x$ac_cv_prog_cc_c99" != "xno" && break
7101 done
7102 rm -f conftest.$ac_ext
7103 CC=$ac_save_CC
7106 # AC_CACHE_VAL
7107 case "x$ac_cv_prog_cc_c99" in
7109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7110 $as_echo "none needed" >&6; } ;;
7111 xno)
7112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7113 $as_echo "unsupported" >&6; } ;;
7115 CC="$CC $ac_cv_prog_cc_c99"
7116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7117 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7118 esac
7119 if test "x$ac_cv_prog_cc_c99" != xno; then :
7120 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7121 else
7122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7123 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7124 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7125 $as_echo_n "(cached) " >&6
7126 else
7127 ac_cv_prog_cc_c89=no
7128 ac_save_CC=$CC
7129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7130 /* end confdefs.h. */
7131 #include <stdarg.h>
7132 #include <stdio.h>
7133 #include <sys/types.h>
7134 #include <sys/stat.h>
7135 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7136 struct buf { int x; };
7137 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7138 static char *e (p, i)
7139 char **p;
7140 int i;
7142 return p[i];
7144 static char *f (char * (*g) (char **, int), char **p, ...)
7146 char *s;
7147 va_list v;
7148 va_start (v,p);
7149 s = g (p, va_arg (v,int));
7150 va_end (v);
7151 return s;
7154 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7155 function prototypes and stuff, but not '\xHH' hex character constants.
7156 These don't provoke an error unfortunately, instead are silently treated
7157 as 'x'. The following induces an error, until -std is added to get
7158 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7159 array size at least. It's necessary to write '\x00'==0 to get something
7160 that's true only with -std. */
7161 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7163 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7164 inside strings and character constants. */
7165 #define FOO(x) 'x'
7166 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7168 int test (int i, double x);
7169 struct s1 {int (*f) (int a);};
7170 struct s2 {int (*f) (double a);};
7171 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7172 int argc;
7173 char **argv;
7175 main ()
7177 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7179 return 0;
7181 _ACEOF
7182 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7183 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7185 CC="$ac_save_CC $ac_arg"
7186 if ac_fn_c_try_compile "$LINENO"; then :
7187 ac_cv_prog_cc_c89=$ac_arg
7189 rm -f core conftest.err conftest.$ac_objext
7190 test "x$ac_cv_prog_cc_c89" != "xno" && break
7191 done
7192 rm -f conftest.$ac_ext
7193 CC=$ac_save_CC
7196 # AC_CACHE_VAL
7197 case "x$ac_cv_prog_cc_c89" in
7199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7200 $as_echo "none needed" >&6; } ;;
7201 xno)
7202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7203 $as_echo "unsupported" >&6; } ;;
7205 CC="$CC $ac_cv_prog_cc_c89"
7206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7207 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7208 esac
7209 if test "x$ac_cv_prog_cc_c89" != xno; then :
7210 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7211 else
7212 ac_cv_prog_cc_stdc=no
7217 esac
7218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7219 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7220 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7221 $as_echo_n "(cached) " >&6
7224 case $ac_cv_prog_cc_stdc in #(
7225 no) :
7226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7227 $as_echo "unsupported" >&6; } ;; #(
7228 '') :
7229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7230 $as_echo "none needed" >&6; } ;; #(
7231 *) :
7232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7233 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7234 esac
7238 # Code from module alloca-opt:
7239 # Code from module allocator:
7240 # Code from module at-internal:
7241 # Code from module binary-io:
7242 # Code from module c-ctype:
7243 # Code from module c-strcase:
7244 # Code from module careadlinkat:
7245 # Code from module clock-time:
7246 # Code from module close-stream:
7247 # Code from module crypto/md5:
7248 # Code from module crypto/sha1:
7249 # Code from module crypto/sha256:
7250 # Code from module crypto/sha512:
7251 # Code from module dirent:
7252 # Code from module dosname:
7253 # Code from module dtoastr:
7254 # Code from module dtotimespec:
7255 # Code from module dup2:
7256 # Code from module environ:
7257 # Code from module errno:
7258 # Code from module euidaccess:
7259 # Code from module execinfo:
7260 # Code from module extensions:
7262 # Code from module extern-inline:
7263 # Code from module faccessat:
7264 # Code from module fcntl:
7265 # Code from module fcntl-h:
7266 # Code from module fdatasync:
7267 # Code from module fdopendir:
7268 # Code from module filemode:
7269 # Code from module fpending:
7270 # Code from module fstatat:
7271 # Code from module fsync:
7272 # Code from module getdtablesize:
7273 # Code from module getgroups:
7274 # Code from module getloadavg:
7275 # Code from module getopt-gnu:
7276 # Code from module getopt-posix:
7277 # Code from module gettext-h:
7278 # Code from module gettime:
7279 # Code from module gettimeofday:
7280 # Code from module group-member:
7281 # Code from module include_next:
7282 # Code from module intprops:
7283 # Code from module inttypes-incomplete:
7284 # Code from module largefile:
7286 # Code from module lstat:
7287 # Code from module manywarnings:
7288 # Code from module memrchr:
7289 # Code from module mktime:
7290 # Code from module multiarch:
7291 # Code from module nocrash:
7292 # Code from module openat-h:
7293 # Code from module pathmax:
7294 # Code from module pipe2:
7295 # Code from module pselect:
7296 # Code from module pthread_sigmask:
7297 # Code from module putenv:
7298 # Code from module qacl:
7299 # Code from module readlink:
7300 # Code from module readlinkat:
7301 # Code from module root-uid:
7302 # Code from module sig2str:
7303 # Code from module signal-h:
7304 # Code from module snippet/_Noreturn:
7305 # Code from module snippet/arg-nonnull:
7306 # Code from module snippet/c++defs:
7307 # Code from module snippet/warn-on-use:
7308 # Code from module socklen:
7309 # Code from module ssize_t:
7310 # Code from module stat:
7311 # Code from module stat-time:
7312 # Code from module stdalign:
7313 # Code from module stdarg:
7317 # Code from module stdbool:
7318 # Code from module stddef:
7319 # Code from module stdint:
7320 # Code from module stdio:
7321 # Code from module stdlib:
7322 # Code from module strftime:
7323 # Code from module string:
7324 # Code from module strtoimax:
7325 # Code from module strtoll:
7326 # Code from module strtoull:
7327 # Code from module strtoumax:
7328 # Code from module symlink:
7329 # Code from module sys_select:
7330 # Code from module sys_stat:
7331 # Code from module sys_time:
7332 # Code from module time:
7333 # Code from module time_r:
7334 # Code from module timer-time:
7335 # Code from module timespec:
7336 # Code from module timespec-add:
7337 # Code from module timespec-sub:
7338 # Code from module u64:
7339 # Code from module unistd:
7340 # Code from module unsetenv:
7341 # Code from module utimens:
7342 # Code from module verify:
7343 # Code from module warnings:
7344 # Code from module xalloc-oversized:
7347 if test "$ac_test_CFLAGS" != set; then
7348 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7349 # if -g3 works and the user does not specify CFLAGS.
7350 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7351 case $CFLAGS in
7352 '-g')
7353 emacs_g3_CFLAGS='-g3';;
7354 '-g -O2')
7355 emacs_g3_CFLAGS='-g3 -O2';;
7357 emacs_g3_CFLAGS='';;
7358 esac
7359 if test -n "$emacs_g3_CFLAGS"; then
7360 emacs_save_CFLAGS=$CFLAGS
7361 CFLAGS=$emacs_g3_CFLAGS
7362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7363 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7364 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7365 $as_echo_n "(cached) " >&6
7366 else
7367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7368 /* end confdefs.h. */
7371 main ()
7375 return 0;
7377 _ACEOF
7378 if ac_fn_c_try_link "$LINENO"; then :
7379 emacs_cv_prog_cc_g3=yes
7380 else
7381 emacs_cv_prog_cc_g3=no
7383 rm -f core conftest.err conftest.$ac_objext \
7384 conftest$ac_exeext conftest.$ac_ext
7386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7387 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7388 if test $emacs_cv_prog_cc_g3 != yes; then
7389 CFLAGS=$emacs_save_CFLAGS
7391 if test $opsys = mingw32; then
7392 CFLAGS="$CFLAGS -gdwarf-2"
7396 case $CFLAGS in
7397 *-O*) ;;
7399 # No optimization flag was inferred for this non-GCC compiler.
7400 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7401 emacs_save_CFLAGS=$CFLAGS
7402 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7403 CFLAGS=${CFLAGS}-O
7404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7405 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7406 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7407 $as_echo_n "(cached) " >&6
7408 else
7409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7410 /* end confdefs.h. */
7413 main ()
7417 return 0;
7419 _ACEOF
7420 if ac_fn_c_try_link "$LINENO"; then :
7421 emacs_cv_prog_cc_o=yes
7422 else
7423 emacs_cv_prog_cc_o=no
7425 rm -f core conftest.err conftest.$ac_objext \
7426 conftest$ac_exeext conftest.$ac_ext
7428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7429 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7430 if test $emacs_cv_prog_cc_o != yes; then
7431 CFLAGS=$emacs_save_CFLAGS
7432 fi ;;
7433 esac
7436 # Check whether --enable-gcc-warnings was given.
7437 if test "${enable_gcc_warnings+set}" = set; then :
7438 enableval=$enable_gcc_warnings; case $enableval in
7439 yes|no) ;;
7440 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7441 esac
7442 gl_gcc_warnings=$enableval
7443 else
7444 gl_gcc_warnings=no
7449 # Check whether --enable-link-time-optimization was given.
7450 if test "${enable_link_time_optimization+set}" = set; then :
7451 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7453 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7454 ac_lto_supported=no
7455 if test x$GCC = xyes; then
7456 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7457 if test x$CPUS != x; then
7458 LTO="-flto=$CPUS"
7459 else
7460 LTO="-flto"
7462 old_CFLAGS=$CFLAGS
7463 CFLAGS="$CFLAGS $LTO"
7464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7465 /* end confdefs.h. */
7468 main ()
7472 return 0;
7474 _ACEOF
7475 if ac_fn_c_try_compile "$LINENO"; then :
7476 ac_lto_supported=yes
7477 else
7478 ac_lto_supported=no
7480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7481 CFLAGS="$old_CFLAGS"
7483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7484 $as_echo "$ac_lto_supported" >&6; }
7485 if test "$ac_lto_supported" = "yes"; then
7486 CFLAGS="$CFLAGS $LTO"
7492 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7493 # ------------------------------------------------
7494 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7495 # Otherwise, run RUN-IF-NOT-FOUND.
7498 # When compiling with GCC, prefer -isystem to -I when including system
7499 # include files, to avoid generating useless diagnostics for the files.
7500 if test "$gl_gcc_warnings" != yes; then
7501 isystem='-I'
7502 else
7503 isystem='-isystem '
7505 # This, $nw, is the list of warnings we disable.
7508 case $with_x_toolkit in
7509 lucid | athena | motif)
7510 # Old toolkits mishandle 'const'.
7511 nw="$nw -Wwrite-strings"
7514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7515 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7516 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7517 $as_echo_n "(cached) " >&6
7518 else
7520 gl_save_compiler_FLAGS="$CFLAGS"
7521 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7523 /* end confdefs.h. */
7526 main ()
7530 return 0;
7532 _ACEOF
7533 if ac_fn_c_try_compile "$LINENO"; then :
7534 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7535 else
7536 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7539 CFLAGS="$gl_save_compiler_FLAGS"
7542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7543 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7544 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7545 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7546 else
7547 gl_unknown_warnings_are_errors=
7551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7552 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7553 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7554 $as_echo_n "(cached) " >&6
7555 else
7557 gl_save_compiler_FLAGS="$CFLAGS"
7558 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7560 /* end confdefs.h. */
7563 main ()
7567 return 0;
7569 _ACEOF
7570 if ac_fn_c_try_compile "$LINENO"; then :
7571 gl_cv_warn_c__Werror=yes
7572 else
7573 gl_cv_warn_c__Werror=no
7575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7576 CFLAGS="$gl_save_compiler_FLAGS"
7579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7580 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7581 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7582 as_fn_append WERROR_CFLAGS " -Werror"
7587 esac
7590 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7591 nw="$nw -Woverlength-strings" # Not a problem these days
7592 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7593 nw="$nw -Wformat-nonliteral" # we do this a lot
7594 nw="$nw -Wvla" # warnings in gettext.h
7595 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7596 nw="$nw -Wswitch-default" # Too many warnings for now
7597 nw="$nw -Winline" # OK to ignore 'inline'
7598 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7599 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7600 # signed overflow has undefined behavior
7601 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7602 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7603 nw="$nw -Wbad-function-cast" # These casts are no worse than others.
7605 # Emacs doesn't care about shadowing; see
7606 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7607 nw="$nw -Wshadow"
7609 # Emacs's use of alloca inhibits protecting the stack.
7610 nw="$nw -Wstack-protector"
7612 # The following line should be removable at some point.
7613 nw="$nw -Wsuggest-attribute=pure"
7615 # clang is unduly picky about some things.
7616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7617 $as_echo_n "checking whether the compiler is clang... " >&6; }
7618 if test "${emacs_cv_clang+set}" = set; then :
7619 $as_echo_n "(cached) " >&6
7620 else
7621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7622 /* end confdefs.h. */
7624 #ifndef __clang__
7625 #error "not clang"
7626 #endif
7629 main ()
7633 return 0;
7635 _ACEOF
7636 if ac_fn_c_try_compile "$LINENO"; then :
7637 emacs_cv_clang=yes
7638 else
7639 emacs_cv_clang=no
7641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7644 $as_echo "$emacs_cv_clang" >&6; }
7645 if test $emacs_cv_clang = yes; then
7646 nw="$nw -Wcast-align"
7651 if test -n "$GCC"; then
7653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7654 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7655 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7656 $as_echo_n "(cached) " >&6
7657 else
7659 gl_save_CFLAGS="$CFLAGS"
7660 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7662 /* end confdefs.h. */
7665 main ()
7669 return 0;
7671 _ACEOF
7672 if ac_fn_c_try_compile "$LINENO"; then :
7673 gl_cv_cc_nomfi_supported=yes
7674 else
7675 gl_cv_cc_nomfi_supported=no
7677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7678 CFLAGS="$gl_save_CFLAGS"
7681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7682 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7684 if test "$gl_cv_cc_nomfi_supported" = yes; then
7685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7686 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7687 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7688 $as_echo_n "(cached) " >&6
7689 else
7691 gl_save_CFLAGS="$CFLAGS"
7692 CFLAGS="$CFLAGS -W -Werror"
7693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7694 /* end confdefs.h. */
7695 void f (void)
7697 typedef struct { int a; int b; } s_t;
7698 s_t s1 = { 0, };
7702 main ()
7706 return 0;
7708 _ACEOF
7709 if ac_fn_c_try_compile "$LINENO"; then :
7710 gl_cv_cc_nomfi_needed=no
7711 else
7712 gl_cv_cc_nomfi_needed=yes
7714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7715 CFLAGS="$gl_save_CFLAGS"
7719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7720 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7724 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7725 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7726 $as_echo_n "(cached) " >&6
7727 else
7729 gl_save_CFLAGS="$CFLAGS"
7730 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7732 /* end confdefs.h. */
7735 main ()
7739 return 0;
7741 _ACEOF
7742 if ac_fn_c_try_compile "$LINENO"; then :
7743 gl_cv_cc_uninitialized_supported=yes
7744 else
7745 gl_cv_cc_uninitialized_supported=no
7747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7748 CFLAGS="$gl_save_CFLAGS"
7751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7752 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7756 # List all gcc warning categories.
7757 gl_manywarn_set=
7758 for gl_manywarn_item in \
7759 -W \
7760 -Wabi \
7761 -Waddress \
7762 -Waggressive-loop-optimizations \
7763 -Wall \
7764 -Warray-bounds \
7765 -Wattributes \
7766 -Wbad-function-cast \
7767 -Wbuiltin-macro-redefined \
7768 -Wcast-align \
7769 -Wchar-subscripts \
7770 -Wclobbered \
7771 -Wcomment \
7772 -Wcomments \
7773 -Wcoverage-mismatch \
7774 -Wcpp \
7775 -Wdeprecated \
7776 -Wdeprecated-declarations \
7777 -Wdisabled-optimization \
7778 -Wdiv-by-zero \
7779 -Wdouble-promotion \
7780 -Wempty-body \
7781 -Wendif-labels \
7782 -Wenum-compare \
7783 -Wextra \
7784 -Wformat-contains-nul \
7785 -Wformat-extra-args \
7786 -Wformat-nonliteral \
7787 -Wformat-security \
7788 -Wformat-y2k \
7789 -Wformat-zero-length \
7790 -Wfree-nonheap-object \
7791 -Wignored-qualifiers \
7792 -Wimplicit \
7793 -Wimplicit-function-declaration \
7794 -Wimplicit-int \
7795 -Winit-self \
7796 -Winline \
7797 -Wint-to-pointer-cast \
7798 -Winvalid-memory-model \
7799 -Winvalid-pch \
7800 -Wjump-misses-init \
7801 -Wlogical-op \
7802 -Wmain \
7803 -Wmaybe-uninitialized \
7804 -Wmissing-braces \
7805 -Wmissing-declarations \
7806 -Wmissing-field-initializers \
7807 -Wmissing-include-dirs \
7808 -Wmissing-parameter-type \
7809 -Wmissing-prototypes \
7810 -Wmudflap \
7811 -Wmultichar \
7812 -Wnarrowing \
7813 -Wnested-externs \
7814 -Wnonnull \
7815 -Wnormalized=nfc \
7816 -Wold-style-declaration \
7817 -Wold-style-definition \
7818 -Woverflow \
7819 -Woverlength-strings \
7820 -Woverride-init \
7821 -Wpacked \
7822 -Wpacked-bitfield-compat \
7823 -Wparentheses \
7824 -Wpointer-arith \
7825 -Wpointer-sign \
7826 -Wpointer-to-int-cast \
7827 -Wpragmas \
7828 -Wreturn-local-addr \
7829 -Wreturn-type \
7830 -Wsequence-point \
7831 -Wshadow \
7832 -Wsizeof-pointer-memaccess \
7833 -Wstack-protector \
7834 -Wstrict-aliasing \
7835 -Wstrict-overflow \
7836 -Wstrict-prototypes \
7837 -Wsuggest-attribute=const \
7838 -Wsuggest-attribute=format \
7839 -Wsuggest-attribute=noreturn \
7840 -Wsuggest-attribute=pure \
7841 -Wswitch \
7842 -Wswitch-default \
7843 -Wsync-nand \
7844 -Wsystem-headers \
7845 -Wtrampolines \
7846 -Wtrigraphs \
7847 -Wtype-limits \
7848 -Wuninitialized \
7849 -Wunknown-pragmas \
7850 -Wunsafe-loop-optimizations \
7851 -Wunused \
7852 -Wunused-but-set-parameter \
7853 -Wunused-but-set-variable \
7854 -Wunused-function \
7855 -Wunused-label \
7856 -Wunused-local-typedefs \
7857 -Wunused-macros \
7858 -Wunused-parameter \
7859 -Wunused-result \
7860 -Wunused-value \
7861 -Wunused-variable \
7862 -Wvarargs \
7863 -Wvariadic-macros \
7864 -Wvector-operation-performance \
7865 -Wvla \
7866 -Wvolatile-register-var \
7867 -Wwrite-strings \
7869 ; do
7870 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7871 done
7873 # Disable specific options as needed.
7874 if test "$gl_cv_cc_nomfi_needed" = yes; then
7875 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7878 if test "$gl_cv_cc_uninitialized_supported" = no; then
7879 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7882 ws=$gl_manywarn_set
7885 gl_warn_set=
7886 set x $ws; shift
7887 for gl_warn_item
7889 case " $nw " in
7890 *" $gl_warn_item "*)
7893 gl_warn_set="$gl_warn_set $gl_warn_item"
7895 esac
7896 done
7897 ws=$gl_warn_set
7899 for w in $ws; do
7901 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7903 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7904 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7905 $as_echo_n "(cached) " >&6
7906 else
7908 gl_save_compiler_FLAGS="$CFLAGS"
7909 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $w"
7910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7911 /* end confdefs.h. */
7914 main ()
7918 return 0;
7920 _ACEOF
7921 if ac_fn_c_try_compile "$LINENO"; then :
7922 eval "$as_gl_Warn=yes"
7923 else
7924 eval "$as_gl_Warn=no"
7926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7927 CFLAGS="$gl_save_compiler_FLAGS"
7930 eval ac_res=\$$as_gl_Warn
7931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7932 $as_echo "$ac_res" >&6; }
7933 eval as_val=\$$as_gl_Warn
7934 if test "x$as_val" = x""yes; then :
7935 as_fn_append WARN_CFLAGS " $w"
7939 done
7941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7942 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7943 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7944 $as_echo_n "(cached) " >&6
7945 else
7947 gl_save_compiler_FLAGS="$CFLAGS"
7948 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-missing-field-initializers"
7949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7950 /* end confdefs.h. */
7953 main ()
7957 return 0;
7959 _ACEOF
7960 if ac_fn_c_try_compile "$LINENO"; then :
7961 gl_cv_warn_c__Wno_missing_field_initializers=yes
7962 else
7963 gl_cv_warn_c__Wno_missing_field_initializers=no
7965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7966 CFLAGS="$gl_save_compiler_FLAGS"
7969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7970 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7971 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7972 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7975 # We need this one
7977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7978 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7979 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7980 $as_echo_n "(cached) " >&6
7981 else
7983 gl_save_compiler_FLAGS="$CFLAGS"
7984 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-sign-compare"
7985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7986 /* end confdefs.h. */
7989 main ()
7993 return 0;
7995 _ACEOF
7996 if ac_fn_c_try_compile "$LINENO"; then :
7997 gl_cv_warn_c__Wno_sign_compare=yes
7998 else
7999 gl_cv_warn_c__Wno_sign_compare=no
8001 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8002 CFLAGS="$gl_save_compiler_FLAGS"
8005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
8006 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
8007 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
8008 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
8011 # Too many warnings for now
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
8014 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
8015 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8016 $as_echo_n "(cached) " >&6
8017 else
8019 gl_save_compiler_FLAGS="$CFLAGS"
8020 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-type-limits"
8021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8022 /* end confdefs.h. */
8025 main ()
8029 return 0;
8031 _ACEOF
8032 if ac_fn_c_try_compile "$LINENO"; then :
8033 gl_cv_warn_c__Wno_type_limits=yes
8034 else
8035 gl_cv_warn_c__Wno_type_limits=no
8037 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8038 CFLAGS="$gl_save_compiler_FLAGS"
8041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8042 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8043 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8044 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8047 # Too many warnings for now
8049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8050 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8051 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8052 $as_echo_n "(cached) " >&6
8053 else
8055 gl_save_compiler_FLAGS="$CFLAGS"
8056 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-switch"
8057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8058 /* end confdefs.h. */
8061 main ()
8065 return 0;
8067 _ACEOF
8068 if ac_fn_c_try_compile "$LINENO"; then :
8069 gl_cv_warn_c__Wno_switch=yes
8070 else
8071 gl_cv_warn_c__Wno_switch=no
8073 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8074 CFLAGS="$gl_save_compiler_FLAGS"
8077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8078 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8079 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8080 as_fn_append WARN_CFLAGS " -Wno-switch"
8083 # Too many warnings for now
8085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8086 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8087 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8088 $as_echo_n "(cached) " >&6
8089 else
8091 gl_save_compiler_FLAGS="$CFLAGS"
8092 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-parameter"
8093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8094 /* end confdefs.h. */
8097 main ()
8101 return 0;
8103 _ACEOF
8104 if ac_fn_c_try_compile "$LINENO"; then :
8105 gl_cv_warn_c__Wno_unused_parameter=yes
8106 else
8107 gl_cv_warn_c__Wno_unused_parameter=no
8109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8110 CFLAGS="$gl_save_compiler_FLAGS"
8113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8114 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8115 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8116 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8119 # Too many warnings for now
8121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8122 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8123 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8124 $as_echo_n "(cached) " >&6
8125 else
8127 gl_save_compiler_FLAGS="$CFLAGS"
8128 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-format-nonliteral"
8129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8130 /* end confdefs.h. */
8133 main ()
8137 return 0;
8139 _ACEOF
8140 if ac_fn_c_try_compile "$LINENO"; then :
8141 gl_cv_warn_c__Wno_format_nonliteral=yes
8142 else
8143 gl_cv_warn_c__Wno_format_nonliteral=no
8145 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8146 CFLAGS="$gl_save_compiler_FLAGS"
8149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8150 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8151 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8152 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8157 # In spite of excluding -Wlogical-op above, it is enabled, as of
8158 # gcc 4.5.0 20090517.
8160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8161 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8162 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8163 $as_echo_n "(cached) " >&6
8164 else
8166 gl_save_compiler_FLAGS="$CFLAGS"
8167 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-logical-op"
8168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8169 /* end confdefs.h. */
8172 main ()
8176 return 0;
8178 _ACEOF
8179 if ac_fn_c_try_compile "$LINENO"; then :
8180 gl_cv_warn_c__Wno_logical_op=yes
8181 else
8182 gl_cv_warn_c__Wno_logical_op=no
8184 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8185 CFLAGS="$gl_save_compiler_FLAGS"
8188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8189 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8190 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8191 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8196 # More things that clang is unduly picky about.
8197 if test $emacs_cv_clang = yes; then
8199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8200 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8201 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8202 $as_echo_n "(cached) " >&6
8203 else
8205 gl_save_compiler_FLAGS="$CFLAGS"
8206 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-format-extra-args"
8207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8208 /* end confdefs.h. */
8211 main ()
8215 return 0;
8217 _ACEOF
8218 if ac_fn_c_try_compile "$LINENO"; then :
8219 gl_cv_warn_c__Wno_format_extra_args=yes
8220 else
8221 gl_cv_warn_c__Wno_format_extra_args=no
8223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8224 CFLAGS="$gl_save_compiler_FLAGS"
8227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8228 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8229 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8230 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8236 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8237 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8238 $as_echo_n "(cached) " >&6
8239 else
8241 gl_save_compiler_FLAGS="$CFLAGS"
8242 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-tautological-constant-out-of-range-compare"
8243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8244 /* end confdefs.h. */
8247 main ()
8251 return 0;
8253 _ACEOF
8254 if ac_fn_c_try_compile "$LINENO"; then :
8255 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8256 else
8257 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8260 CFLAGS="$gl_save_compiler_FLAGS"
8263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8264 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8265 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8266 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8272 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8273 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8274 $as_echo_n "(cached) " >&6
8275 else
8277 gl_save_compiler_FLAGS="$CFLAGS"
8278 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-command-line-argument"
8279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8280 /* end confdefs.h. */
8283 main ()
8287 return 0;
8289 _ACEOF
8290 if ac_fn_c_try_compile "$LINENO"; then :
8291 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8292 else
8293 gl_cv_warn_c__Wno_unused_command_line_argument=no
8295 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8296 CFLAGS="$gl_save_compiler_FLAGS"
8299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8300 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8301 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8302 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8308 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8309 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8310 $as_echo_n "(cached) " >&6
8311 else
8313 gl_save_compiler_FLAGS="$CFLAGS"
8314 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-value"
8315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8316 /* end confdefs.h. */
8319 main ()
8323 return 0;
8325 _ACEOF
8326 if ac_fn_c_try_compile "$LINENO"; then :
8327 gl_cv_warn_c__Wno_unused_value=yes
8328 else
8329 gl_cv_warn_c__Wno_unused_value=no
8331 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8332 CFLAGS="$gl_save_compiler_FLAGS"
8335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8336 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8337 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8338 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
8346 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
8347 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
8348 $as_echo_n "(cached) " >&6
8349 else
8351 gl_save_compiler_FLAGS="$CFLAGS"
8352 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
8353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8354 /* end confdefs.h. */
8357 main ()
8361 return 0;
8363 _ACEOF
8364 if ac_fn_c_try_compile "$LINENO"; then :
8365 gl_cv_warn_c__fdiagnostics_show_option=yes
8366 else
8367 gl_cv_warn_c__fdiagnostics_show_option=no
8369 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8370 CFLAGS="$gl_save_compiler_FLAGS"
8373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
8374 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
8375 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
8376 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
8381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
8382 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
8383 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
8384 $as_echo_n "(cached) " >&6
8385 else
8387 gl_save_compiler_FLAGS="$CFLAGS"
8388 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
8389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8390 /* end confdefs.h. */
8393 main ()
8397 return 0;
8399 _ACEOF
8400 if ac_fn_c_try_compile "$LINENO"; then :
8401 gl_cv_warn_c__funit_at_a_time=yes
8402 else
8403 gl_cv_warn_c__funit_at_a_time=no
8405 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8406 CFLAGS="$gl_save_compiler_FLAGS"
8409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
8410 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
8411 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
8412 as_fn_append WARN_CFLAGS " -funit-at-a-time"
8418 $as_echo "#define lint 1" >>confdefs.h
8422 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8425 # We use a slightly smaller set of warning options for lib/.
8426 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8428 nw="$nw -Wunused-macros"
8431 gl_warn_set=
8432 set x $WARN_CFLAGS; shift
8433 for gl_warn_item
8435 case " $nw " in
8436 *" $gl_warn_item "*)
8439 gl_warn_set="$gl_warn_set $gl_warn_item"
8441 esac
8442 done
8443 GNULIB_WARN_CFLAGS=$gl_warn_set
8453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8454 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8455 rm -f conf$$ conf$$.file
8457 LN_S_FILEONLY='cp -p'
8459 if (echo >conf$$.file) 2>/dev/null; then
8460 if ln -s conf$$.file conf$$ 2>/dev/null; then
8461 LN_S_FILEONLY='ln -s'
8462 elif ln conf$$.file conf$$ 2>/dev/null; then
8463 LN_S_FILEONLY=ln
8467 rm -f conf$$ conf$$.file
8469 if test "$LN_S_FILEONLY" = "ln -s"; then
8470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8471 $as_echo "yes" >&6; }
8472 else
8473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8474 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8480 if test "$opsys" = "mingw32"; then
8481 LN_S="ln"
8484 # Extract the first word of "install-info", so it can be a program name with args.
8485 set dummy install-info; ac_word=$2
8486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8487 $as_echo_n "checking for $ac_word... " >&6; }
8488 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8489 $as_echo_n "(cached) " >&6
8490 else
8491 case $INSTALL_INFO in
8492 [\\/]* | ?:[\\/]*)
8493 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8497 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8499 IFS=$as_save_IFS
8500 test -z "$as_dir" && as_dir=.
8501 for ac_exec_ext in '' $ac_executable_extensions; do
8502 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8503 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8505 break 2
8507 done
8508 done
8509 IFS=$as_save_IFS
8511 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8513 esac
8515 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8516 if test -n "$INSTALL_INFO"; then
8517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8518 $as_echo "$INSTALL_INFO" >&6; }
8519 else
8520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8521 $as_echo "no" >&6; }
8525 # Extract the first word of "gzip", so it can be a program name with args.
8526 set dummy gzip; ac_word=$2
8527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8528 $as_echo_n "checking for $ac_word... " >&6; }
8529 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8530 $as_echo_n "(cached) " >&6
8531 else
8532 case $GZIP_PROG in
8533 [\\/]* | ?:[\\/]*)
8534 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8538 for as_dir in $PATH
8540 IFS=$as_save_IFS
8541 test -z "$as_dir" && as_dir=.
8542 for ac_exec_ext in '' $ac_executable_extensions; do
8543 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8544 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8546 break 2
8548 done
8549 done
8550 IFS=$as_save_IFS
8553 esac
8555 GZIP_PROG=$ac_cv_path_GZIP_PROG
8556 if test -n "$GZIP_PROG"; then
8557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8558 $as_echo "$GZIP_PROG" >&6; }
8559 else
8560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8561 $as_echo "no" >&6; }
8566 if test $opsys = gnu-linux; then
8567 # Extract the first word of "paxctl", so it can be a program name with args.
8568 set dummy paxctl; ac_word=$2
8569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8570 $as_echo_n "checking for $ac_word... " >&6; }
8571 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8572 $as_echo_n "(cached) " >&6
8573 else
8574 case $PAXCTL in
8575 [\\/]* | ?:[\\/]*)
8576 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8580 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8582 IFS=$as_save_IFS
8583 test -z "$as_dir" && as_dir=.
8584 for ac_exec_ext in '' $ac_executable_extensions; do
8585 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8586 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8587 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8588 break 2
8590 done
8591 done
8592 IFS=$as_save_IFS
8595 esac
8597 PAXCTL=$ac_cv_path_PAXCTL
8598 if test -n "$PAXCTL"; then
8599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8600 $as_echo "$PAXCTL" >&6; }
8601 else
8602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8603 $as_echo "no" >&6; }
8607 if test "X$PAXCTL" != X; then
8608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8609 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8611 /* end confdefs.h. */
8614 main ()
8618 return 0;
8620 _ACEOF
8621 if ac_fn_c_try_link "$LINENO"; then :
8622 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8623 $as_echo "yes" >&6; }
8624 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8625 $as_echo "no" >&6; }; PAXCTL=""; fi
8627 rm -f core conftest.err conftest.$ac_objext \
8628 conftest$ac_exeext conftest.$ac_ext
8632 ## Need makeinfo >= 4.7 (?) to build the manuals.
8633 # Extract the first word of "makeinfo", so it can be a program name with args.
8634 set dummy makeinfo; ac_word=$2
8635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8636 $as_echo_n "checking for $ac_word... " >&6; }
8637 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8638 $as_echo_n "(cached) " >&6
8639 else
8640 case $MAKEINFO in
8641 [\\/]* | ?:[\\/]*)
8642 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8646 for as_dir in $PATH
8648 IFS=$as_save_IFS
8649 test -z "$as_dir" && as_dir=.
8650 for ac_exec_ext in '' $ac_executable_extensions; do
8651 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8652 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8654 break 2
8656 done
8657 done
8658 IFS=$as_save_IFS
8660 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8662 esac
8664 MAKEINFO=$ac_cv_path_MAKEINFO
8665 if test -n "$MAKEINFO"; then
8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8667 $as_echo "$MAKEINFO" >&6; }
8668 else
8669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8670 $as_echo "no" >&6; }
8674 if test "$MAKEINFO" != "no"; then
8675 case `
8676 $MAKEINFO --version 2> /dev/null |
8677 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8678 ` in
8679 '') MAKEINFO=no;;
8680 esac
8683 ## Makeinfo is unusual. For a released Emacs, the manuals are
8684 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8685 ## therefore in the category of "special tools" not normally required, which
8686 ## configure does not have to check for (eg autoconf itself).
8687 ## In a Bazaar checkout on the other hand, the manuals are not included.
8688 ## So makeinfo is a requirement to build from Bazaar, and configure
8689 ## should test for it as it does for any other build requirement.
8690 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8691 ## with pre-built manuals, from a Bazaar checkout.
8692 HAVE_MAKEINFO=yes
8694 if test "$MAKEINFO" = "no"; then
8695 MAKEINFO=makeinfo
8696 if test "x${with_makeinfo}" = "xno"; then
8697 HAVE_MAKEINFO=no
8698 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8699 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8700 source tree does not seem to have pre-built manuals in the \`info' directory.
8701 Either install a suitable version of makeinfo, or re-run configure
8702 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8707 INFO_EXT=.info
8708 INFO_OPTS=--no-split
8713 if test x$GCC = xyes; then
8714 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8715 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8716 else
8717 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8718 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8722 late_LDFLAGS=$LDFLAGS
8723 if test x$GCC = xyes; then
8724 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8725 else
8726 LDFLAGS="$LDFLAGS -znocombreloc"
8729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8730 $as_echo_n "checking for -znocombreloc... " >&6; }
8731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8732 /* end confdefs.h. */
8735 main ()
8739 return 0;
8741 _ACEOF
8742 if ac_fn_c_try_link "$LINENO"; then :
8743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8744 $as_echo "yes" >&6; }
8745 else
8746 LDFLAGS=$late_LDFLAGS
8747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8748 $as_echo "no" >&6; }
8750 rm -f core conftest.err conftest.$ac_objext \
8751 conftest$ac_exeext conftest.$ac_ext
8754 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8755 case "$opsys" in
8756 your-opsys-here) CANNOT_DUMP=yes ;;
8757 esac
8759 test "$CANNOT_DUMP" = "yes" && \
8761 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8767 UNEXEC_OBJ=unexelf.o
8768 case "$opsys" in
8769 # MSDOS uses unexcoff.o
8770 aix4-2)
8771 UNEXEC_OBJ=unexaix.o
8773 cygwin)
8774 UNEXEC_OBJ=unexcw.o
8776 darwin)
8777 UNEXEC_OBJ=unexmacosx.o
8779 hpux10-20 | hpux11)
8780 UNEXEC_OBJ=unexhp9k800.o
8782 mingw32)
8783 UNEXEC_OBJ=unexw32.o
8785 sol2-10)
8786 # Use the Solaris dldump() function, called from unexsol.c, to dump
8787 # emacs, instead of the generic ELF dump code found in unexelf.c.
8788 # The resulting binary has a complete symbol table, and is better
8789 # for debugging and other observability tools (debuggers, pstack, etc).
8791 # If you encounter a problem using dldump(), please consider sending
8792 # a message to the OpenSolaris tools-linking mailing list:
8793 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8795 # It is likely that dldump() works with older Solaris too, but this has
8796 # not been tested, so for now this change is for Solaris 10 or newer.
8797 UNEXEC_OBJ=unexsol.o
8799 esac
8801 LD_SWITCH_SYSTEM=
8802 case "$opsys" in
8803 freebsd|dragonfly)
8804 ## Let `ld' find image libs and similar things in /usr/local/lib.
8805 ## The system compiler, GCC, has apparently been modified to not
8806 ## look there, contrary to what a stock GCC would do.
8807 ### It's not our place to do this. See bug#10313#17.
8808 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8812 gnu-linux)
8813 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8814 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8817 netbsd)
8818 ### It's not our place to do this. See bug#10313#17.
8819 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8823 openbsd)
8824 ## Han Boetes <han@boetes.org> says this is necessary,
8825 ## otherwise Emacs dumps core on elf systems.
8826 LD_SWITCH_SYSTEM="-Z"
8828 esac
8831 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8833 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8834 ## which has not been defined yet. When this was handled with cpp,
8835 ## it was expanded to null when configure sourced the s/*.h file.
8836 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8837 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8838 ## (or somesuch), but because it is supposed to go at the _front_
8839 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8840 ## Compare with the gnu-linux case below, which added to the end
8841 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8842 ## LD_SWITCH_SYSTEM_TEMACS.
8843 case "$opsys" in
8844 netbsd|openbsd)
8845 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8846 esac
8849 C_SWITCH_MACHINE=
8850 case $canonical in
8851 alpha*)
8852 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8853 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8857 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8858 ## With ELF, make sure that all common symbols get allocated to in the
8859 ## data section. Otherwise, the dump of temacs may miss variables in
8860 ## the shared library that have been initialized. For example, with
8861 ## GNU libc, __malloc_initialized would normally be resolved to the
8862 ## shared library's .bss section, which is fatal.
8863 if test "x$GCC" = "xyes"; then
8864 C_SWITCH_MACHINE="-fno-common"
8865 else
8866 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8868 else
8869 UNEXEC_OBJ=unexalpha.o
8872 esac
8877 C_SWITCH_SYSTEM=
8878 ## Some programs in src produce warnings saying certain subprograms
8879 ## are too complex and need a MAXMEM value greater than 2000 for
8880 ## additional optimization. --nils@exp-math.uni-essen.de
8881 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8882 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8883 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
8884 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8885 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8889 LIBS_SYSTEM=
8890 case "$opsys" in
8891 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8892 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8894 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
8896 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8898 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8900 ## Motif needs -lgen.
8901 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8902 esac
8906 ### Make sure subsequent tests use flags consistent with the build flags.
8908 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8909 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8910 else
8911 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8914 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8916 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8920 LIB_MATH=-lm
8921 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8923 case $opsys in
8924 cygwin )
8925 LIB_MATH=
8927 darwin )
8928 ## Adding -lm confuses the dynamic linker, so omit it.
8929 LIB_MATH=
8931 freebsd | dragonfly )
8932 SYSTEM_TYPE=berkeley-unix
8934 gnu-linux | gnu-kfreebsd )
8936 hpux10-20 | hpux11 )
8938 mingw32 )
8939 LIB_MATH=
8940 SYSTEM_TYPE=windows-nt
8942 netbsd | openbsd )
8943 SYSTEM_TYPE=berkeley-unix
8946 sol2* | unixware )
8947 SYSTEM_TYPE=usg-unix-v
8950 esac
8954 cat >>confdefs.h <<_ACEOF
8955 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8956 _ACEOF
8960 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8961 pre_PKG_CONFIG_LIBS=$LIBS
8963 # Extract the first word of "pkg-config", so it can be a program name with args.
8964 set dummy pkg-config; ac_word=$2
8965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8966 $as_echo_n "checking for $ac_word... " >&6; }
8967 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8968 $as_echo_n "(cached) " >&6
8969 else
8970 case $PKG_CONFIG in
8971 [\\/]* | ?:[\\/]*)
8972 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8976 for as_dir in $PATH
8978 IFS=$as_save_IFS
8979 test -z "$as_dir" && as_dir=.
8980 for ac_exec_ext in '' $ac_executable_extensions; do
8981 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8982 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8983 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8984 break 2
8986 done
8987 done
8988 IFS=$as_save_IFS
8990 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8992 esac
8994 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8995 if test -n "$PKG_CONFIG"; then
8996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8997 $as_echo "$PKG_CONFIG" >&6; }
8998 else
8999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9000 $as_echo "no" >&6; }
9007 HAVE_SOUND=no
9008 if test "${with_sound}" != "no"; then
9009 # Sound support for GNU/Linux, the free BSDs, and MinGW.
9010 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
9011 do :
9012 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9013 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9014 #ifdef __MINGW32__
9015 #define WIN32_LEAN_AND_MEAN
9016 #include <windows.h>
9017 #endif
9020 eval as_val=\$$as_ac_Header
9021 if test "x$as_val" = x""yes; then :
9022 cat >>confdefs.h <<_ACEOF
9023 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9024 _ACEOF
9025 have_sound_header=yes
9028 done
9030 if test "${with_sound}" = "ossaudio" || test "${with_sound}" = "yes"; then
9031 # Emulation library used on NetBSD.
9032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9033 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9034 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9035 $as_echo_n "(cached) " >&6
9036 else
9037 ac_check_lib_save_LIBS=$LIBS
9038 LIBS="-lossaudio $LIBS"
9039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9040 /* end confdefs.h. */
9042 /* Override any GCC internal prototype to avoid an error.
9043 Use char because int might match the return type of a GCC
9044 builtin and then its argument prototype would still apply. */
9045 #ifdef __cplusplus
9046 extern "C"
9047 #endif
9048 char _oss_ioctl ();
9050 main ()
9052 return _oss_ioctl ();
9054 return 0;
9056 _ACEOF
9057 if ac_fn_c_try_link "$LINENO"; then :
9058 ac_cv_lib_ossaudio__oss_ioctl=yes
9059 else
9060 ac_cv_lib_ossaudio__oss_ioctl=no
9062 rm -f core conftest.err conftest.$ac_objext \
9063 conftest$ac_exeext conftest.$ac_ext
9064 LIBS=$ac_check_lib_save_LIBS
9066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9067 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9068 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9069 LIBSOUND=-lossaudio
9070 else
9071 LIBSOUND=
9074 test "${with_sound}" = "ossaudio" && test -z "$LIBSOUND" && \
9075 as_fn_error "ossaudio sound support requested but not found." "$LINENO" 5
9079 if test "${with_sound}" = "alsa" || test "${with_sound}" = "yes"; then
9080 ALSA_REQUIRED=1.0.0
9081 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9083 succeeded=no
9085 if test "$PKG_CONFIG" = "no" ; then
9086 HAVE_ALSA=no
9087 else
9088 PKG_CONFIG_MIN_VERSION=0.9.0
9089 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9091 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9093 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9094 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9095 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9096 edit_cflags="
9097 s,///*,/,g
9098 s/^/ /
9099 s/ -I/ $isystem/g
9100 s/^ //
9102 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9103 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9105 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9106 succeeded=yes
9107 else
9108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9109 $as_echo "no" >&6; }
9110 ALSA_CFLAGS=""
9111 ALSA_LIBS=""
9112 ## If we have a custom action on failure, don't print errors, but
9113 ## do set a variable so people can do so. Do it in a subshell
9114 ## to capture any diagnostics in invoking pkg-config.
9115 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9121 else
9122 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9123 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9127 if test $succeeded = yes; then
9128 HAVE_ALSA=yes
9129 else
9130 HAVE_ALSA=no
9133 if test $HAVE_ALSA = yes; then
9134 SAVE_CFLAGS="$CFLAGS"
9135 SAVE_LIBS="$LIBS"
9136 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9137 LIBS="$ALSA_LIBS $LIBS"
9138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9139 /* end confdefs.h. */
9140 #include <asoundlib.h>
9142 main ()
9144 snd_lib_error_set_handler (0);
9146 return 0;
9148 _ACEOF
9149 if ac_fn_c_try_compile "$LINENO"; then :
9150 emacs_alsa_normal=yes
9151 else
9152 emacs_alsa_normal=no
9154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9155 if test "$emacs_alsa_normal" != yes; then
9156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9157 /* end confdefs.h. */
9158 #include <alsa/asoundlib.h>
9160 main ()
9162 snd_lib_error_set_handler (0);
9164 return 0;
9166 _ACEOF
9167 if ac_fn_c_try_compile "$LINENO"; then :
9168 emacs_alsa_subdir=yes
9169 else
9170 emacs_alsa_subdir=no
9172 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9173 if test "$emacs_alsa_subdir" != yes; then
9174 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9176 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9179 CFLAGS="$SAVE_CFLAGS"
9180 LIBS="$SAVE_LIBS"
9181 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9182 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9184 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9186 elif test "${with_sound}" = "alsa"; then
9187 as_fn_error "ALSA sound support requested but not found." "$LINENO" 5
9190 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9191 case "$opsys" in
9192 gnu-linux|freebsd|netbsd|mingw32)
9194 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9196 HAVE_SOUND=yes
9198 esac
9207 for ac_header in $ac_header_list
9208 do :
9209 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9210 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9212 eval as_val=\$$as_ac_Header
9213 if test "x$as_val" = x""yes; then :
9214 cat >>confdefs.h <<_ACEOF
9215 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9216 _ACEOF
9220 done
9240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9241 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9243 /* end confdefs.h. */
9244 #include <sys/personality.h>
9246 main ()
9248 personality (PER_LINUX32)
9250 return 0;
9252 _ACEOF
9253 if ac_fn_c_try_compile "$LINENO"; then :
9254 emacs_cv_personality_linux32=yes
9255 else
9256 emacs_cv_personality_linux32=no
9258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9260 $as_echo "$emacs_cv_personality_linux32" >&6; }
9262 if test $emacs_cv_personality_linux32 = yes; then
9264 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9268 for ac_header in term.h
9269 do :
9270 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9271 if test "x$ac_cv_header_term_h" = x""yes; then :
9272 cat >>confdefs.h <<_ACEOF
9273 #define HAVE_TERM_H 1
9274 _ACEOF
9278 done
9280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9281 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9282 if test "${ac_cv_header_time+set}" = set; then :
9283 $as_echo_n "(cached) " >&6
9284 else
9285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9286 /* end confdefs.h. */
9287 #include <sys/types.h>
9288 #include <sys/time.h>
9289 #include <time.h>
9292 main ()
9294 if ((struct tm *) 0)
9295 return 0;
9297 return 0;
9299 _ACEOF
9300 if ac_fn_c_try_compile "$LINENO"; then :
9301 ac_cv_header_time=yes
9302 else
9303 ac_cv_header_time=no
9305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9308 $as_echo "$ac_cv_header_time" >&6; }
9309 if test $ac_cv_header_time = yes; then
9311 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9315 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9318 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9319 ac_have_decl=1
9320 else
9321 ac_have_decl=0
9324 cat >>confdefs.h <<_ACEOF
9325 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9326 _ACEOF
9328 if test $ac_cv_have_decl_sys_siglist != yes; then
9329 # For Tru64, at least:
9330 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9333 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9334 ac_have_decl=1
9335 else
9336 ac_have_decl=0
9339 cat >>confdefs.h <<_ACEOF
9340 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9341 _ACEOF
9344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9345 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9346 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
9347 $as_echo_n "(cached) " >&6
9348 else
9349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9350 /* end confdefs.h. */
9351 #include <sys/types.h>
9352 #include <sys/wait.h>
9353 #ifndef WEXITSTATUS
9354 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9355 #endif
9356 #ifndef WIFEXITED
9357 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9358 #endif
9361 main ()
9363 int s;
9364 wait (&s);
9365 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9367 return 0;
9369 _ACEOF
9370 if ac_fn_c_try_compile "$LINENO"; then :
9371 ac_cv_header_sys_wait_h=yes
9372 else
9373 ac_cv_header_sys_wait_h=no
9375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9378 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9379 if test $ac_cv_header_sys_wait_h = yes; then
9381 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9389 for ac_header in net/if.h
9390 do :
9391 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9392 #if HAVE_SYS_SOCKET_H
9393 #include <sys/socket.h>
9394 #endif
9396 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9397 cat >>confdefs.h <<_ACEOF
9398 #define HAVE_NET_IF_H 1
9399 _ACEOF
9403 done
9405 for ac_header in ifaddrs.h
9406 do :
9407 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9408 #if HAVE_SYS_SOCKET_H
9409 #include <sys/socket.h>
9410 #endif
9412 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9413 cat >>confdefs.h <<_ACEOF
9414 #define HAVE_IFADDRS_H 1
9415 _ACEOF
9419 done
9421 for ac_header in net/if_dl.h
9422 do :
9423 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9424 #if HAVE_SYS_SOCKET_H
9425 #include <sys/socket.h>
9426 #endif
9428 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9429 cat >>confdefs.h <<_ACEOF
9430 #define HAVE_NET_IF_DL_H 1
9431 _ACEOF
9435 done
9438 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9439 #if HAVE_SYS_SOCKET_H
9440 #include <sys/socket.h>
9441 #endif
9442 #if HAVE_NET_IF_H
9443 #include <net/if.h>
9444 #endif
9446 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9448 cat >>confdefs.h <<_ACEOF
9449 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9450 _ACEOF
9454 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9455 #if HAVE_SYS_SOCKET_H
9456 #include <sys/socket.h>
9457 #endif
9458 #if HAVE_NET_IF_H
9459 #include <net/if.h>
9460 #endif
9462 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9464 cat >>confdefs.h <<_ACEOF
9465 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9466 _ACEOF
9470 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9471 #if HAVE_SYS_SOCKET_H
9472 #include <sys/socket.h>
9473 #endif
9474 #if HAVE_NET_IF_H
9475 #include <net/if.h>
9476 #endif
9478 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9480 cat >>confdefs.h <<_ACEOF
9481 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9482 _ACEOF
9486 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9487 #if HAVE_SYS_SOCKET_H
9488 #include <sys/socket.h>
9489 #endif
9490 #if HAVE_NET_IF_H
9491 #include <net/if.h>
9492 #endif
9494 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9496 cat >>confdefs.h <<_ACEOF
9497 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9498 _ACEOF
9502 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9503 #if HAVE_SYS_SOCKET_H
9504 #include <sys/socket.h>
9505 #endif
9506 #if HAVE_NET_IF_H
9507 #include <net/if.h>
9508 #endif
9510 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9512 cat >>confdefs.h <<_ACEOF
9513 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9514 _ACEOF
9518 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9519 #if HAVE_SYS_SOCKET_H
9520 #include <sys/socket.h>
9521 #endif
9522 #if HAVE_NET_IF_H
9523 #include <net/if.h>
9524 #endif
9526 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9528 cat >>confdefs.h <<_ACEOF
9529 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9530 _ACEOF
9538 DEPFLAGS=
9539 MKDEPDIR=":"
9540 deps_frag=deps.mk
9541 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9543 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9544 HAVE_GNU_MAKE=no
9545 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9546 if test "x$testval" != x; then
9547 HAVE_GNU_MAKE=yes
9548 else
9549 ac_enable_autodepend=no
9551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9552 $as_echo "$HAVE_GNU_MAKE" >&6; }
9553 if test $HAVE_GNU_MAKE = yes; then
9554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9555 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9556 SAVE_CFLAGS="$CFLAGS"
9557 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9559 /* end confdefs.h. */
9562 main ()
9566 return 0;
9568 _ACEOF
9569 if ac_fn_c_try_compile "$LINENO"; then :
9571 else
9572 ac_enable_autodepend=no
9574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9575 CFLAGS="$SAVE_CFLAGS"
9576 test -f deps.d || ac_enable_autodepend=no
9577 rm -rf deps.d
9578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9579 $as_echo "$ac_enable_autodepend" >&6; }
9581 if test $ac_enable_autodepend = yes; then
9582 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9583 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9584 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9585 deps_frag=autodeps.mk
9588 deps_frag=$srcdir/src/$deps_frag
9594 lisp_frag=$srcdir/src/lisp.mk
9598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9599 $as_echo_n "checking for long file names... " >&6; }
9600 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9601 $as_echo_n "(cached) " >&6
9602 else
9603 ac_cv_sys_long_file_names=yes
9604 # Test for long file names in all the places we know might matter:
9605 # . the current directory, where building will happen
9606 # $prefix/lib where we will be installing things
9607 # $exec_prefix/lib likewise
9608 # $TMPDIR if set, where it might want to write temporary files
9609 # /tmp where it might want to write temporary files
9610 # /var/tmp likewise
9611 # /usr/tmp likewise
9612 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9613 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9614 # in the usual case where exec_prefix is '${prefix}'.
9615 case $ac_dir in #(
9616 . | /* | ?:[\\/]*) ;; #(
9617 *) continue;;
9618 esac
9619 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9620 ac_xdir=$ac_dir/cf$$
9621 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9622 ac_tf1=$ac_xdir/conftest9012345
9623 ac_tf2=$ac_xdir/conftest9012346
9624 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9625 ac_cv_sys_long_file_names=no
9626 rm -f -r "$ac_xdir" 2>/dev/null
9627 test $ac_cv_sys_long_file_names = no && break
9628 done
9630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9631 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9632 if test $ac_cv_sys_long_file_names = yes; then
9634 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9639 #### Choose a window system.
9641 ## We leave window_system equal to none if
9642 ## we end up building without one. Any new window system should
9643 ## set window_system to an appropriate value and add objects to
9644 ## window-system-specific substs.
9646 window_system=none
9647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9648 $as_echo_n "checking for X... " >&6; }
9651 # Check whether --with-x was given.
9652 if test "${with_x+set}" = set; then :
9653 withval=$with_x;
9656 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9657 if test "x$with_x" = xno; then
9658 # The user explicitly disabled X.
9659 have_x=disabled
9660 else
9661 case $x_includes,$x_libraries in #(
9662 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9663 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9664 $as_echo_n "(cached) " >&6
9665 else
9666 # One or both of the vars are not set, and there is no cached value.
9667 ac_x_includes=no ac_x_libraries=no
9668 rm -f -r conftest.dir
9669 if mkdir conftest.dir; then
9670 cd conftest.dir
9671 cat >Imakefile <<'_ACEOF'
9672 incroot:
9673 @echo incroot='${INCROOT}'
9674 usrlibdir:
9675 @echo usrlibdir='${USRLIBDIR}'
9676 libdir:
9677 @echo libdir='${LIBDIR}'
9678 _ACEOF
9679 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9680 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9681 for ac_var in incroot usrlibdir libdir; do
9682 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9683 done
9684 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9685 for ac_extension in a so sl dylib la dll; do
9686 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9687 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9688 ac_im_usrlibdir=$ac_im_libdir; break
9690 done
9691 # Screen out bogus values from the imake configuration. They are
9692 # bogus both because they are the default anyway, and because
9693 # using them would break gcc on systems where it needs fixed includes.
9694 case $ac_im_incroot in
9695 /usr/include) ac_x_includes= ;;
9696 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9697 esac
9698 case $ac_im_usrlibdir in
9699 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9700 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9701 esac
9703 cd ..
9704 rm -f -r conftest.dir
9707 # Standard set of common directories for X headers.
9708 # Check X11 before X11Rn because it is often a symlink to the current release.
9709 ac_x_header_dirs='
9710 /usr/X11/include
9711 /usr/X11R7/include
9712 /usr/X11R6/include
9713 /usr/X11R5/include
9714 /usr/X11R4/include
9716 /usr/include/X11
9717 /usr/include/X11R7
9718 /usr/include/X11R6
9719 /usr/include/X11R5
9720 /usr/include/X11R4
9722 /usr/local/X11/include
9723 /usr/local/X11R7/include
9724 /usr/local/X11R6/include
9725 /usr/local/X11R5/include
9726 /usr/local/X11R4/include
9728 /usr/local/include/X11
9729 /usr/local/include/X11R7
9730 /usr/local/include/X11R6
9731 /usr/local/include/X11R5
9732 /usr/local/include/X11R4
9734 /usr/X386/include
9735 /usr/x386/include
9736 /usr/XFree86/include/X11
9738 /usr/include
9739 /usr/local/include
9740 /usr/unsupported/include
9741 /usr/athena/include
9742 /usr/local/x11r5/include
9743 /usr/lpp/Xamples/include
9745 /usr/openwin/include
9746 /usr/openwin/share/include'
9748 if test "$ac_x_includes" = no; then
9749 # Guess where to find include files, by looking for Xlib.h.
9750 # First, try using that file with no special directory specified.
9751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9752 /* end confdefs.h. */
9753 #include <X11/Xlib.h>
9754 _ACEOF
9755 if ac_fn_c_try_cpp "$LINENO"; then :
9756 # We can compile using X headers with no special include directory.
9757 ac_x_includes=
9758 else
9759 for ac_dir in $ac_x_header_dirs; do
9760 if test -r "$ac_dir/X11/Xlib.h"; then
9761 ac_x_includes=$ac_dir
9762 break
9764 done
9766 rm -f conftest.err conftest.$ac_ext
9767 fi # $ac_x_includes = no
9769 if test "$ac_x_libraries" = no; then
9770 # Check for the libraries.
9771 # See if we find them without any special options.
9772 # Don't add to $LIBS permanently.
9773 ac_save_LIBS=$LIBS
9774 LIBS="-lX11 $LIBS"
9775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9776 /* end confdefs.h. */
9777 #include <X11/Xlib.h>
9779 main ()
9781 XrmInitialize ()
9783 return 0;
9785 _ACEOF
9786 if ac_fn_c_try_link "$LINENO"; then :
9787 LIBS=$ac_save_LIBS
9788 # We can link X programs with no special library path.
9789 ac_x_libraries=
9790 else
9791 LIBS=$ac_save_LIBS
9792 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9794 # Don't even attempt the hair of trying to link an X program!
9795 for ac_extension in a so sl dylib la dll; do
9796 if test -r "$ac_dir/libX11.$ac_extension"; then
9797 ac_x_libraries=$ac_dir
9798 break 2
9800 done
9801 done
9803 rm -f core conftest.err conftest.$ac_objext \
9804 conftest$ac_exeext conftest.$ac_ext
9805 fi # $ac_x_libraries = no
9807 case $ac_x_includes,$ac_x_libraries in #(
9808 no,* | *,no | *\'*)
9809 # Didn't find X, or a directory has "'" in its name.
9810 ac_cv_have_x="have_x=no";; #(
9812 # Record where we found X for the cache.
9813 ac_cv_have_x="have_x=yes\
9814 ac_x_includes='$ac_x_includes'\
9815 ac_x_libraries='$ac_x_libraries'"
9816 esac
9818 ;; #(
9819 *) have_x=yes;;
9820 esac
9821 eval "$ac_cv_have_x"
9822 fi # $with_x != no
9824 if test "$have_x" != yes; then
9825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9826 $as_echo "$have_x" >&6; }
9827 no_x=yes
9828 else
9829 # If each of the values was on the command line, it overrides each guess.
9830 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9831 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9832 # Update the cache value to reflect the command line values.
9833 ac_cv_have_x="have_x=yes\
9834 ac_x_includes='$x_includes'\
9835 ac_x_libraries='$x_libraries'"
9836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9837 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9840 if test "$no_x" != yes; then
9841 window_system=x11
9844 LD_SWITCH_X_SITE_RPATH=
9845 if test "${x_libraries}" != NONE; then
9846 if test -n "${x_libraries}"; then
9847 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9848 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9850 x_default_search_path=""
9851 x_search_path=${x_libraries}
9852 if test -z "${x_search_path}"; then
9853 x_search_path=/usr/lib
9855 for x_library in `echo ${x_search_path}: | \
9856 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9857 x_search_path="\
9858 ${x_library}/X11/%L/%T/%N%C%S:\
9859 ${x_library}/X11/%l/%T/%N%C%S:\
9860 ${x_library}/X11/%T/%N%C%S:\
9861 ${x_library}/X11/%L/%T/%N%S:\
9862 ${x_library}/X11/%l/%T/%N%S:\
9863 ${x_library}/X11/%T/%N%S"
9864 if test x"${x_default_search_path}" = x; then
9865 x_default_search_path=${x_search_path}
9866 else
9867 x_default_search_path="${x_search_path}:${x_default_search_path}"
9869 done
9873 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9874 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9877 if test x"${x_includes}" = x; then
9878 bitmapdir=/usr/include/X11/bitmaps
9879 else
9880 # accumulate include directories that have X11 bitmap subdirectories
9881 bmd_acc="dummyval"
9882 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9883 if test -d "${bmd}/X11/bitmaps"; then
9884 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9886 if test -d "${bmd}/bitmaps"; then
9887 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9889 done
9890 if test ${bmd_acc} != "dummyval"; then
9891 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9895 HAVE_NS=no
9896 NS_IMPL_COCOA=no
9897 NS_IMPL_GNUSTEP=no
9898 tmp_CPPFLAGS="$CPPFLAGS"
9899 tmp_CFLAGS="$CFLAGS"
9900 CPPFLAGS="$CPPFLAGS -x objective-c"
9901 CFLAGS="$CFLAGS -x objective-c"
9902 GNU_OBJC_CFLAGS=
9903 LIBS_GNUSTEP=
9904 if test "${with_ns}" != no; then
9905 if test "${opsys}" = darwin; then
9906 NS_IMPL_COCOA=yes
9907 ns_appdir=`pwd`/nextstep/Emacs.app
9908 ns_appbindir=${ns_appdir}/Contents/MacOS
9909 ns_appresdir=${ns_appdir}/Contents/Resources
9910 ns_appsrc=Cocoa/Emacs.base
9911 elif test -f $GNUSTEP_CONFIG_FILE; then
9912 NS_IMPL_GNUSTEP=yes
9913 ns_appdir=`pwd`/nextstep/Emacs.app
9914 ns_appbindir=${ns_appdir}
9915 ns_appresdir=${ns_appdir}/Resources
9916 ns_appsrc=GNUstep/Emacs.base
9917 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9918 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9919 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9920 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9921 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9922 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9923 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9924 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9925 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9926 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9927 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9928 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
9929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9930 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9931 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9932 $as_echo_n "(cached) " >&6
9933 else
9934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9935 /* end confdefs.h. */
9936 #include <GNUstepBase/GSConfig.h>
9938 main ()
9940 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9942 #else
9943 fail;
9944 #endif
9946 return 0;
9948 _ACEOF
9949 if ac_fn_c_try_compile "$LINENO"; then :
9950 emacs_cv_objc_exceptions=yes
9951 else
9952 emacs_cv_objc_exceptions=no
9954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9957 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9958 if test $emacs_cv_objc_exceptions = yes; then
9960 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9962 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9966 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9968 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9969 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9970 HAVE_NS=yes
9971 else
9972 as_fn_error "\`--with-ns' was specified, but the include
9973 files are missing or cannot be compiled." "$LINENO" 5
9978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9979 /* end confdefs.h. */
9980 #include <AppKit/AppKit.h>
9982 main ()
9985 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9986 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
9987 ; /* OK */
9988 #else
9989 #error "OSX 10.4 or newer required"
9990 #endif
9991 #endif
9994 return 0;
9996 _ACEOF
9997 if ac_fn_c_try_compile "$LINENO"; then :
9998 ns_osx_have_104=yes
9999 else
10000 ns_osx_have_104=no
10002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10004 /* end confdefs.h. */
10005 #include <Foundation/NSObjCRuntime.h>
10007 main ()
10009 NSInteger i;
10011 return 0;
10013 _ACEOF
10014 if ac_fn_c_try_compile "$LINENO"; then :
10015 ns_have_nsinteger=yes
10016 else
10017 ns_have_nsinteger=no
10019 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10020 if test $ns_osx_have_104 = no; then
10021 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10023 if test $ns_have_nsinteger = yes; then
10025 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10032 INSTALL_ARCH_INDEP_EXTRA=install-etc
10033 ns_self_contained=no
10034 NS_OBJ=
10035 NS_OBJC_OBJ=
10036 if test "${HAVE_NS}" = yes; then
10037 if test "$with_toolkit_scroll_bars" = "no"; then
10038 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10041 window_system=nextstep
10042 # set up packaging dirs
10043 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10044 ns_self_contained=yes
10045 prefix=${ns_appresdir}
10046 exec_prefix=${ns_appbindir}
10047 libexecdir="\${ns_appbindir}/libexec"
10048 archlibdir="\${ns_appbindir}/libexec"
10049 docdir="\${ns_appresdir}/etc"
10050 etcdir="\${ns_appresdir}/etc"
10051 infodir="\${ns_appresdir}/info"
10052 mandir="\${ns_appresdir}/man"
10053 lispdir="\${ns_appresdir}/lisp"
10054 leimdir="\${ns_appresdir}/leim"
10055 INSTALL_ARCH_INDEP_EXTRA=
10057 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
10059 CFLAGS="$tmp_CFLAGS"
10060 CPPFLAGS="$tmp_CPPFLAGS"
10066 HAVE_W32=no
10067 W32_OBJ=
10068 W32_LIBS=
10069 EMACSRES=
10070 CLIENTRES=
10071 CLIENTW=
10072 W32_RES_LINK=
10073 EMACS_MANIFEST=
10074 if test "${with_w32}" != no; then
10075 case "${opsys}" in
10076 cygwin)
10077 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10078 if test "x$ac_cv_header_windows_h" = x""yes; then :
10079 HAVE_W32=yes
10080 else
10081 as_fn_error "\`--with-w32' was specified, but windows.h
10082 cannot be found." "$LINENO" 5
10087 mingw32)
10088 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10091 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10093 esac
10096 if test "${opsys}" = "mingw32"; then
10097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10098 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10100 /* end confdefs.h. */
10102 #include <windows.h>
10103 #include <usp10.h>
10105 main ()
10107 PIMAGE_NT_HEADERS pHeader;
10108 PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader)
10110 return 0;
10112 _ACEOF
10113 if ac_fn_c_try_compile "$LINENO"; then :
10114 emacs_cv_w32api=yes
10115 HAVE_W32=yes
10116 else
10117 emacs_cv_w32api=no
10119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10121 $as_echo "$emacs_cv_w32api" >&6; }
10122 if test "${emacs_cv_w32api}" = "no"; then
10123 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10127 FIRSTFILE_OBJ=
10128 NTDIR=
10129 LIBS_ECLIENT=
10130 LIB_WSOCK32=
10131 NTLIB=
10132 CM_OBJ="cm.o"
10133 XARGS_LIMIT=
10134 if test "${HAVE_W32}" = "yes"; then
10136 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10138 if test -n "$ac_tool_prefix"; then
10139 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10140 set dummy ${ac_tool_prefix}windres; ac_word=$2
10141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10142 $as_echo_n "checking for $ac_word... " >&6; }
10143 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10144 $as_echo_n "(cached) " >&6
10145 else
10146 if test -n "$WINDRES"; then
10147 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10148 else
10149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10150 for as_dir in $PATH
10152 IFS=$as_save_IFS
10153 test -z "$as_dir" && as_dir=.
10154 for ac_exec_ext in '' $ac_executable_extensions; do
10155 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10156 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10157 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10158 break 2
10160 done
10161 done
10162 IFS=$as_save_IFS
10166 WINDRES=$ac_cv_prog_WINDRES
10167 if test -n "$WINDRES"; then
10168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10169 $as_echo "$WINDRES" >&6; }
10170 else
10171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10172 $as_echo "no" >&6; }
10177 if test -z "$ac_cv_prog_WINDRES"; then
10178 ac_ct_WINDRES=$WINDRES
10179 # Extract the first word of "windres", so it can be a program name with args.
10180 set dummy windres; ac_word=$2
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10182 $as_echo_n "checking for $ac_word... " >&6; }
10183 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10184 $as_echo_n "(cached) " >&6
10185 else
10186 if test -n "$ac_ct_WINDRES"; then
10187 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10188 else
10189 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10190 for as_dir in $PATH
10192 IFS=$as_save_IFS
10193 test -z "$as_dir" && as_dir=.
10194 for ac_exec_ext in '' $ac_executable_extensions; do
10195 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10196 ac_cv_prog_ac_ct_WINDRES="windres"
10197 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10198 break 2
10200 done
10201 done
10202 IFS=$as_save_IFS
10206 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10207 if test -n "$ac_ct_WINDRES"; then
10208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10209 $as_echo "$ac_ct_WINDRES" >&6; }
10210 else
10211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10212 $as_echo "no" >&6; }
10215 if test "x$ac_ct_WINDRES" = x; then
10216 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10217 else
10218 case $cross_compiling:$ac_tool_warned in
10219 yes:)
10220 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10221 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10222 ac_tool_warned=yes ;;
10223 esac
10224 WINDRES=$ac_ct_WINDRES
10226 else
10227 WINDRES="$ac_cv_prog_WINDRES"
10230 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10231 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10232 EMACSRES="emacs.res"
10233 case "$canonical" in
10234 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10235 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10236 esac
10237 if test "${opsys}" = "cygwin"; then
10238 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10239 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10240 # Tell the linker that emacs.res is an object (which we compile from
10241 # the rc file), not a linker script.
10242 W32_RES_LINK="-Wl,emacs.res"
10243 else
10244 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10245 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10246 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10247 W32_RES_LINK="\$(EMACSRES)"
10248 CLIENTRES="emacsclient.res"
10249 CLIENTW="emacsclientw\$(EXEEXT)"
10250 FIRSTFILE_OBJ=firstfile.o
10251 NTDIR=nt
10252 CM_OBJ=
10253 LIBS_ECLIENT="-lcomctl32"
10254 LIB_WSOCK32="-lwsock32"
10255 NTLIB="ntlib.$ac_objext"
10256 XARGS_LIMIT="-s 10000"
10274 if test "${HAVE_W32}" = "yes"; then
10275 window_system=w32
10276 with_xft=no
10279 ## $window_system is now set to the window system we will
10280 ## ultimately use.
10282 term_header=
10283 HAVE_X_WINDOWS=no
10284 HAVE_X11=no
10285 USE_X_TOOLKIT=none
10287 case "${window_system}" in
10288 x11 )
10289 HAVE_X_WINDOWS=yes
10290 HAVE_X11=yes
10291 term_header=xterm.h
10292 case "${with_x_toolkit}" in
10293 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10294 motif ) USE_X_TOOLKIT=MOTIF ;;
10295 gtk ) with_gtk=yes
10296 term_header=gtkutil.h
10297 USE_X_TOOLKIT=none ;;
10298 gtk2 ) with_gtk2=yes
10299 term_header=gtkutil.h
10300 USE_X_TOOLKIT=none ;;
10301 gtk3 ) with_gtk3=yes
10302 term_header=gtkutil.h
10303 USE_X_TOOLKIT=none ;;
10304 no ) USE_X_TOOLKIT=none ;;
10305 * ) USE_X_TOOLKIT=maybe ;;
10306 esac
10308 nextstep )
10309 term_header=nsterm.h
10311 w32 )
10312 term_header=w32term.h
10314 esac
10316 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10317 # Extract the first word of "X", so it can be a program name with args.
10318 set dummy X; ac_word=$2
10319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10320 $as_echo_n "checking for $ac_word... " >&6; }
10321 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10322 $as_echo_n "(cached) " >&6
10323 else
10324 if test -n "$HAVE_XSERVER"; then
10325 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10326 else
10327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10328 for as_dir in $PATH
10330 IFS=$as_save_IFS
10331 test -z "$as_dir" && as_dir=.
10332 for ac_exec_ext in '' $ac_executable_extensions; do
10333 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10334 ac_cv_prog_HAVE_XSERVER="true"
10335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10336 break 2
10338 done
10339 done
10340 IFS=$as_save_IFS
10342 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10345 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10346 if test -n "$HAVE_XSERVER"; then
10347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10348 $as_echo "$HAVE_XSERVER" >&6; }
10349 else
10350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10351 $as_echo "no" >&6; }
10355 if test "$HAVE_XSERVER" = true ||
10356 test -n "$DISPLAY" ||
10357 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10358 as_fn_error "You seem to be running X, but no X development libraries
10359 were found. You should install the relevant development files for X
10360 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10361 sure you have development files for image handling, i.e.
10362 tiff, gif, jpeg, png and xpm.
10363 If you are sure you want Emacs compiled without X window support, pass
10364 --without-x
10365 to configure." "$LINENO" 5
10369 ### If we're using X11, we should use the X menu package.
10370 HAVE_MENUS=no
10371 case ${HAVE_X11} in
10372 yes ) HAVE_MENUS=yes ;;
10373 esac
10375 # Does the opsystem file prohibit the use of the GNU malloc?
10376 # Assume not, until told otherwise.
10377 GNU_MALLOC=yes
10379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10380 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10381 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10382 $as_echo_n "(cached) " >&6
10383 else
10384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10385 /* end confdefs.h. */
10386 #include <malloc.h>
10387 static void hook (void) {}
10389 main ()
10391 malloc_set_state (malloc_get_state ());
10392 __after_morecore_hook = hook;
10393 __malloc_initialize_hook = hook;
10395 return 0;
10397 _ACEOF
10398 if ac_fn_c_try_link "$LINENO"; then :
10399 emacs_cv_var_doug_lea_malloc=yes
10400 else
10401 emacs_cv_var_doug_lea_malloc=no
10403 rm -f core conftest.err conftest.$ac_objext \
10404 conftest$ac_exeext conftest.$ac_ext
10406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10407 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10408 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10411 system_malloc=no
10412 case "$opsys" in
10413 ## darwin ld insists on the use of malloc routines in the System framework.
10414 darwin|sol2-10) system_malloc=yes ;;
10415 esac
10417 if test "${system_malloc}" = "yes"; then
10419 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10421 GNU_MALLOC=no
10422 GNU_MALLOC_reason="
10423 (The GNU allocators don't work with this system configuration.)"
10424 GMALLOC_OBJ=
10425 VMLIMIT_OBJ=
10426 else
10427 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10428 VMLIMIT_OBJ=vm-limit.o
10430 for ac_header in sys/vlimit.h
10431 do :
10432 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10433 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10434 cat >>confdefs.h <<_ACEOF
10435 #define HAVE_SYS_VLIMIT_H 1
10436 _ACEOF
10440 done
10442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10443 $as_echo_n "checking for data_start... " >&6; }
10444 if test "${emacs_cv_data_start+set}" = set; then :
10445 $as_echo_n "(cached) " >&6
10446 else
10447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10448 /* end confdefs.h. */
10449 extern char data_start[]; char ch;
10451 main ()
10453 return data_start < &ch;
10455 return 0;
10457 _ACEOF
10458 if ac_fn_c_try_link "$LINENO"; then :
10459 emacs_cv_data_start=yes
10460 else
10461 emacs_cv_data_start=no
10463 rm -f core conftest.err conftest.$ac_objext \
10464 conftest$ac_exeext conftest.$ac_ext
10466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10467 $as_echo "$emacs_cv_data_start" >&6; }
10468 if test $emacs_cv_data_start = yes; then
10470 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10477 if test "$doug_lea_malloc" = "yes" ; then
10478 if test "$GNU_MALLOC" = yes ; then
10479 GNU_MALLOC_reason="
10480 (Using Doug Lea's new malloc from the GNU C Library.)"
10483 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10486 ## Use mmap directly for allocating larger buffers.
10487 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10488 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10489 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10490 case "$opsys" in
10491 gnu*) REL_ALLOC=no ;;
10492 esac
10495 if test x"${REL_ALLOC}" = x; then
10496 REL_ALLOC=${GNU_MALLOC}
10499 use_mmap_for_buffers=no
10500 case "$opsys" in
10501 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10502 esac
10511 for ac_func in getpagesize
10512 do :
10513 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10514 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10515 cat >>confdefs.h <<_ACEOF
10516 #define HAVE_GETPAGESIZE 1
10517 _ACEOF
10520 done
10522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10523 $as_echo_n "checking for working mmap... " >&6; }
10524 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10525 $as_echo_n "(cached) " >&6
10526 else
10527 if test "$cross_compiling" = yes; then :
10528 ac_cv_func_mmap_fixed_mapped=no
10529 else
10530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10531 /* end confdefs.h. */
10532 $ac_includes_default
10533 /* malloc might have been renamed as rpl_malloc. */
10534 #undef malloc
10536 /* Thanks to Mike Haertel and Jim Avera for this test.
10537 Here is a matrix of mmap possibilities:
10538 mmap private not fixed
10539 mmap private fixed at somewhere currently unmapped
10540 mmap private fixed at somewhere already mapped
10541 mmap shared not fixed
10542 mmap shared fixed at somewhere currently unmapped
10543 mmap shared fixed at somewhere already mapped
10544 For private mappings, we should verify that changes cannot be read()
10545 back from the file, nor mmap's back from the file at a different
10546 address. (There have been systems where private was not correctly
10547 implemented like the infamous i386 svr4.0, and systems where the
10548 VM page cache was not coherent with the file system buffer cache
10549 like early versions of FreeBSD and possibly contemporary NetBSD.)
10550 For shared mappings, we should conversely verify that changes get
10551 propagated back to all the places they're supposed to be.
10553 Grep wants private fixed already mapped.
10554 The main things grep needs to know about mmap are:
10555 * does it exist and is it safe to write into the mmap'd area
10556 * how to use it (BSD variants) */
10558 #include <fcntl.h>
10559 #include <sys/mman.h>
10561 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10562 char *malloc ();
10563 #endif
10565 /* This mess was copied from the GNU getpagesize.h. */
10566 #ifndef HAVE_GETPAGESIZE
10567 # ifdef _SC_PAGESIZE
10568 # define getpagesize() sysconf(_SC_PAGESIZE)
10569 # else /* no _SC_PAGESIZE */
10570 # ifdef HAVE_SYS_PARAM_H
10571 # include <sys/param.h>
10572 # ifdef EXEC_PAGESIZE
10573 # define getpagesize() EXEC_PAGESIZE
10574 # else /* no EXEC_PAGESIZE */
10575 # ifdef NBPG
10576 # define getpagesize() NBPG * CLSIZE
10577 # ifndef CLSIZE
10578 # define CLSIZE 1
10579 # endif /* no CLSIZE */
10580 # else /* no NBPG */
10581 # ifdef NBPC
10582 # define getpagesize() NBPC
10583 # else /* no NBPC */
10584 # ifdef PAGESIZE
10585 # define getpagesize() PAGESIZE
10586 # endif /* PAGESIZE */
10587 # endif /* no NBPC */
10588 # endif /* no NBPG */
10589 # endif /* no EXEC_PAGESIZE */
10590 # else /* no HAVE_SYS_PARAM_H */
10591 # define getpagesize() 8192 /* punt totally */
10592 # endif /* no HAVE_SYS_PARAM_H */
10593 # endif /* no _SC_PAGESIZE */
10595 #endif /* no HAVE_GETPAGESIZE */
10598 main ()
10600 char *data, *data2, *data3;
10601 const char *cdata2;
10602 int i, pagesize;
10603 int fd, fd2;
10605 pagesize = getpagesize ();
10607 /* First, make a file with some known garbage in it. */
10608 data = (char *) malloc (pagesize);
10609 if (!data)
10610 return 1;
10611 for (i = 0; i < pagesize; ++i)
10612 *(data + i) = rand ();
10613 umask (0);
10614 fd = creat ("conftest.mmap", 0600);
10615 if (fd < 0)
10616 return 2;
10617 if (write (fd, data, pagesize) != pagesize)
10618 return 3;
10619 close (fd);
10621 /* Next, check that the tail of a page is zero-filled. File must have
10622 non-zero length, otherwise we risk SIGBUS for entire page. */
10623 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10624 if (fd2 < 0)
10625 return 4;
10626 cdata2 = "";
10627 if (write (fd2, cdata2, 1) != 1)
10628 return 5;
10629 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10630 if (data2 == MAP_FAILED)
10631 return 6;
10632 for (i = 0; i < pagesize; ++i)
10633 if (*(data2 + i))
10634 return 7;
10635 close (fd2);
10636 if (munmap (data2, pagesize))
10637 return 8;
10639 /* Next, try to mmap the file at a fixed address which already has
10640 something else allocated at it. If we can, also make sure that
10641 we see the same garbage. */
10642 fd = open ("conftest.mmap", O_RDWR);
10643 if (fd < 0)
10644 return 9;
10645 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10646 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10647 return 10;
10648 for (i = 0; i < pagesize; ++i)
10649 if (*(data + i) != *(data2 + i))
10650 return 11;
10652 /* Finally, make sure that changes to the mapped area do not
10653 percolate back to the file as seen by read(). (This is a bug on
10654 some variants of i386 svr4.0.) */
10655 for (i = 0; i < pagesize; ++i)
10656 *(data2 + i) = *(data2 + i) + 1;
10657 data3 = (char *) malloc (pagesize);
10658 if (!data3)
10659 return 12;
10660 if (read (fd, data3, pagesize) != pagesize)
10661 return 13;
10662 for (i = 0; i < pagesize; ++i)
10663 if (*(data + i) != *(data3 + i))
10664 return 14;
10665 close (fd);
10666 return 0;
10668 _ACEOF
10669 if ac_fn_c_try_run "$LINENO"; then :
10670 ac_cv_func_mmap_fixed_mapped=yes
10671 else
10672 ac_cv_func_mmap_fixed_mapped=no
10674 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10675 conftest.$ac_objext conftest.beam conftest.$ac_ext
10679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10680 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10681 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10683 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10686 rm -f conftest.mmap conftest.txt
10688 if test $use_mmap_for_buffers = yes; then
10690 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10692 REL_ALLOC=no
10695 LIBS="$LIBS_SYSTEM $LIBS"
10697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10698 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10699 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10700 $as_echo_n "(cached) " >&6
10701 else
10702 ac_check_lib_save_LIBS=$LIBS
10703 LIBS="-ldnet $LIBS"
10704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10705 /* end confdefs.h. */
10707 /* Override any GCC internal prototype to avoid an error.
10708 Use char because int might match the return type of a GCC
10709 builtin and then its argument prototype would still apply. */
10710 #ifdef __cplusplus
10711 extern "C"
10712 #endif
10713 char dnet_ntoa ();
10715 main ()
10717 return dnet_ntoa ();
10719 return 0;
10721 _ACEOF
10722 if ac_fn_c_try_link "$LINENO"; then :
10723 ac_cv_lib_dnet_dnet_ntoa=yes
10724 else
10725 ac_cv_lib_dnet_dnet_ntoa=no
10727 rm -f core conftest.err conftest.$ac_objext \
10728 conftest$ac_exeext conftest.$ac_ext
10729 LIBS=$ac_check_lib_save_LIBS
10731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10732 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10733 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10734 cat >>confdefs.h <<_ACEOF
10735 #define HAVE_LIBDNET 1
10736 _ACEOF
10738 LIBS="-ldnet $LIBS"
10743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10744 $as_echo_n "checking for main in -lXbsd... " >&6; }
10745 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10746 $as_echo_n "(cached) " >&6
10747 else
10748 ac_check_lib_save_LIBS=$LIBS
10749 LIBS="-lXbsd $LIBS"
10750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10751 /* end confdefs.h. */
10755 main ()
10757 return main ();
10759 return 0;
10761 _ACEOF
10762 if ac_fn_c_try_link "$LINENO"; then :
10763 ac_cv_lib_Xbsd_main=yes
10764 else
10765 ac_cv_lib_Xbsd_main=no
10767 rm -f core conftest.err conftest.$ac_objext \
10768 conftest$ac_exeext conftest.$ac_ext
10769 LIBS=$ac_check_lib_save_LIBS
10771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10772 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10773 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10774 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10778 LIB_PTHREAD=
10782 if test "$ac_cv_header_pthread_h"; then
10783 if test "$GMALLOC_OBJ" = gmalloc.o; then
10784 emacs_pthread_function=pthread_atfork
10785 else
10786 emacs_pthread_function=pthread_self
10788 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10790 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10791 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10792 $as_echo_n "(cached) " >&6
10793 else
10794 ac_check_lib_save_LIBS=$LIBS
10795 LIBS="-lpthread $LIBS"
10796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10797 /* end confdefs.h. */
10799 /* Override any GCC internal prototype to avoid an error.
10800 Use char because int might match the return type of a GCC
10801 builtin and then its argument prototype would still apply. */
10802 #ifdef __cplusplus
10803 extern "C"
10804 #endif
10805 char $emacs_pthread_function ();
10807 main ()
10809 return $emacs_pthread_function ();
10811 return 0;
10813 _ACEOF
10814 if ac_fn_c_try_link "$LINENO"; then :
10815 eval "$as_ac_Lib=yes"
10816 else
10817 eval "$as_ac_Lib=no"
10819 rm -f core conftest.err conftest.$ac_objext \
10820 conftest$ac_exeext conftest.$ac_ext
10821 LIBS=$ac_check_lib_save_LIBS
10823 eval ac_res=\$$as_ac_Lib
10824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10825 $as_echo "$ac_res" >&6; }
10826 eval as_val=\$$as_ac_Lib
10827 if test "x$as_val" = x""yes; then :
10828 HAVE_PTHREAD=yes
10832 if test "$HAVE_PTHREAD" = yes; then
10833 case "${canonical}" in
10834 *-hpux*) ;;
10835 *) LIB_PTHREAD="-lpthread"
10836 LIBS="$LIB_PTHREAD $LIBS" ;;
10837 esac
10839 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10845 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10846 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10847 $as_echo_n "(cached) " >&6
10848 else
10849 ac_check_lib_save_LIBS=$LIBS
10850 LIBS="-lpthreads $LIBS"
10851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10852 /* end confdefs.h. */
10854 /* Override any GCC internal prototype to avoid an error.
10855 Use char because int might match the return type of a GCC
10856 builtin and then its argument prototype would still apply. */
10857 #ifdef __cplusplus
10858 extern "C"
10859 #endif
10860 char cma_open ();
10862 main ()
10864 return cma_open ();
10866 return 0;
10868 _ACEOF
10869 if ac_fn_c_try_link "$LINENO"; then :
10870 ac_cv_lib_pthreads_cma_open=yes
10871 else
10872 ac_cv_lib_pthreads_cma_open=no
10874 rm -f core conftest.err conftest.$ac_objext \
10875 conftest$ac_exeext conftest.$ac_ext
10876 LIBS=$ac_check_lib_save_LIBS
10878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10879 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10880 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10881 cat >>confdefs.h <<_ACEOF
10882 #define HAVE_LIBPTHREADS 1
10883 _ACEOF
10885 LIBS="-lpthreads $LIBS"
10890 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10891 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10892 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10893 ## added to LIBS in configure would never contain the pthreads part,
10894 ## but the value used in Makefiles might. FIXME?
10896 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10897 ## be harmless on older versions of X where it happens to exist.
10898 test "$opsys" = "aix4-2" && \
10899 test $ac_cv_lib_pthreads_cma_open = yes && \
10900 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10903 case ${host_os} in
10904 aix*)
10905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10906 $as_echo_n "checking for -bbigtoc option... " >&6; }
10907 if test "${gdb_cv_bigtoc+set}" = set; then :
10908 $as_echo_n "(cached) " >&6
10909 else
10911 case $GCC in
10912 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10913 *) gdb_cv_bigtoc=-bbigtoc ;;
10914 esac
10916 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10918 /* end confdefs.h. */
10921 main ()
10923 int i;
10925 return 0;
10927 _ACEOF
10928 if ac_fn_c_try_link "$LINENO"; then :
10930 else
10931 gdb_cv_bigtoc=
10933 rm -f core conftest.err conftest.$ac_objext \
10934 conftest$ac_exeext conftest.$ac_ext
10937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10938 $as_echo "$gdb_cv_bigtoc" >&6; }
10940 esac
10942 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10943 # used for the tests that follow. We set them back to REAL_CFLAGS and
10944 # REAL_CPPFLAGS later on.
10946 REAL_CFLAGS="$CFLAGS"
10947 REAL_CPPFLAGS="$CPPFLAGS"
10949 if test "${HAVE_X11}" = "yes"; then
10950 DEFS="$C_SWITCH_X_SITE $DEFS"
10951 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10952 LIBS="-lX11 $LIBS"
10953 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10954 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10956 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10957 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10958 # but it's more convenient here to set LD_RUN_PATH since this
10959 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10960 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10961 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10962 export LD_RUN_PATH
10965 if test "${opsys}" = "gnu-linux"; then
10966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10967 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10969 /* end confdefs.h. */
10972 main ()
10974 XOpenDisplay ("foo");
10976 return 0;
10978 _ACEOF
10979 if ac_fn_c_try_link "$LINENO"; then :
10980 xgnu_linux_first_failure=no
10981 else
10982 xgnu_linux_first_failure=yes
10984 rm -f core conftest.err conftest.$ac_objext \
10985 conftest$ac_exeext conftest.$ac_ext
10986 if test "${xgnu_linux_first_failure}" = "yes"; then
10987 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10988 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10989 OLD_CPPFLAGS="$CPPFLAGS"
10990 OLD_LIBS="$LIBS"
10991 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10992 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10993 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10994 LIBS="$LIBS -b i486-linuxaout"
10995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10996 /* end confdefs.h. */
10999 main ()
11001 XOpenDisplay ("foo");
11003 return 0;
11005 _ACEOF
11006 if ac_fn_c_try_link "$LINENO"; then :
11007 xgnu_linux_second_failure=no
11008 else
11009 xgnu_linux_second_failure=yes
11011 rm -f core conftest.err conftest.$ac_objext \
11012 conftest$ac_exeext conftest.$ac_ext
11013 if test "${xgnu_linux_second_failure}" = "yes"; then
11014 # If we get the same failure with -b, there is no use adding -b.
11015 # So take it out. This plays safe.
11016 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11017 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11018 CPPFLAGS="$OLD_CPPFLAGS"
11019 LIBS="$OLD_LIBS"
11020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11021 $as_echo "no" >&6; }
11022 else
11023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11024 $as_echo "yes" >&6; }
11026 else
11027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11028 $as_echo "no" >&6; }
11032 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11033 # header files included from there.
11034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11035 $as_echo_n "checking for Xkb... " >&6; }
11036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11037 /* end confdefs.h. */
11038 #include <X11/Xlib.h>
11039 #include <X11/XKBlib.h>
11041 main ()
11043 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11045 return 0;
11047 _ACEOF
11048 if ac_fn_c_try_link "$LINENO"; then :
11049 emacs_xkb=yes
11050 else
11051 emacs_xkb=no
11053 rm -f core conftest.err conftest.$ac_objext \
11054 conftest$ac_exeext conftest.$ac_ext
11055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11056 $as_echo "$emacs_xkb" >&6; }
11057 if test $emacs_xkb = yes; then
11059 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11063 for ac_func in XrmSetDatabase XScreenResourceString \
11064 XScreenNumberOfScreen
11065 do :
11066 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11067 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11068 eval as_val=\$$as_ac_var
11069 if test "x$as_val" = x""yes; then :
11070 cat >>confdefs.h <<_ACEOF
11071 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11072 _ACEOF
11075 done
11079 if test "${window_system}" = "x11"; then
11080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11081 $as_echo_n "checking X11 version 6... " >&6; }
11082 if test "${emacs_cv_x11_version_6+set}" = set; then :
11083 $as_echo_n "(cached) " >&6
11084 else
11085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11086 /* end confdefs.h. */
11087 #include <X11/Xlib.h>
11089 main ()
11091 #if XlibSpecificationRelease < 6
11092 fail;
11093 #endif
11096 return 0;
11098 _ACEOF
11099 if ac_fn_c_try_link "$LINENO"; then :
11100 emacs_cv_x11_version_6=yes
11101 else
11102 emacs_cv_x11_version_6=no
11104 rm -f core conftest.err conftest.$ac_objext \
11105 conftest$ac_exeext conftest.$ac_ext
11108 if test $emacs_cv_x11_version_6 = yes; then
11109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11110 $as_echo "6 or newer" >&6; }
11112 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11115 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11117 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11118 ## XIM support.
11119 case "$opsys" in
11120 sol2-*) : ;;
11122 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11125 esac
11126 else
11127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11128 $as_echo "before 6" >&6; }
11133 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11134 HAVE_RSVG=no
11135 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11136 if test "${with_rsvg}" != "no"; then
11137 RSVG_REQUIRED=2.11.0
11138 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11141 succeeded=no
11143 if test "$PKG_CONFIG" = "no" ; then
11145 else
11146 PKG_CONFIG_MIN_VERSION=0.9.0
11147 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11149 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11151 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11152 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11153 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11154 edit_cflags="
11155 s,///*,/,g
11156 s/^/ /
11157 s/ -I/ $isystem/g
11158 s/^ //
11160 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11161 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11163 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11164 succeeded=yes
11165 else
11166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11167 $as_echo "no" >&6; }
11168 RSVG_CFLAGS=""
11169 RSVG_LIBS=""
11170 ## If we have a custom action on failure, don't print errors, but
11171 ## do set a variable so people can do so. Do it in a subshell
11172 ## to capture any diagnostics in invoking pkg-config.
11173 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11179 else
11180 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11181 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11185 if test $succeeded = yes; then
11186 HAVE_RSVG=yes
11187 else
11194 if test $HAVE_RSVG = yes; then
11196 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11198 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11199 LIBS="$RSVG_LIBS $LIBS"
11204 HAVE_IMAGEMAGICK=no
11205 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
11206 if test "${with_imagemagick}" != "no"; then
11207 ## 6.2.8 is the earliest version known to work, but earlier versions
11208 ## might work - let us know if you find one.
11209 ## 6.0.7 does not work. See bug#7955.
11210 ## 6.8.2 makes Emacs crash; see Bug#13867.
11211 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11213 succeeded=no
11215 if test "$PKG_CONFIG" = "no" ; then
11217 else
11218 PKG_CONFIG_MIN_VERSION=0.9.0
11219 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11221 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11223 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11224 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11225 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11226 edit_cflags="
11227 s,///*,/,g
11228 s/^/ /
11229 s/ -I/ $isystem/g
11230 s/^ //
11232 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11233 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11235 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11236 succeeded=yes
11237 else
11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11239 $as_echo "no" >&6; }
11240 IMAGEMAGICK_CFLAGS=""
11241 IMAGEMAGICK_LIBS=""
11242 ## If we have a custom action on failure, don't print errors, but
11243 ## do set a variable so people can do so. Do it in a subshell
11244 ## to capture any diagnostics in invoking pkg-config.
11245 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11251 else
11252 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11253 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11257 if test $succeeded = yes; then
11258 HAVE_IMAGEMAGICK=yes
11259 else
11266 if test $HAVE_IMAGEMAGICK = yes; then
11268 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11270 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11271 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11272 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11273 do :
11274 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11275 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11276 eval as_val=\$$as_ac_var
11277 if test "x$as_val" = x""yes; then :
11278 cat >>confdefs.h <<_ACEOF
11279 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11280 _ACEOF
11283 done
11290 HAVE_GTK=no
11291 GTK_OBJ=
11292 gtk_term_header=$term_header
11293 check_gtk2=no
11294 gtk3_pkg_errors=
11295 if test "${opsys}" != "mingw32"; then
11296 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11297 GLIB_REQUIRED=2.28
11298 GTK_REQUIRED=3.0
11299 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11302 succeeded=no
11304 if test "$PKG_CONFIG" = "no" ; then
11305 pkg_check_gtk=no
11306 else
11307 PKG_CONFIG_MIN_VERSION=0.9.0
11308 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11310 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11312 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11313 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11314 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11315 edit_cflags="
11316 s,///*,/,g
11317 s/^/ /
11318 s/ -I/ $isystem/g
11319 s/^ //
11321 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11322 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11324 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11325 succeeded=yes
11326 else
11327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11328 $as_echo "no" >&6; }
11329 GTK_CFLAGS=""
11330 GTK_LIBS=""
11331 ## If we have a custom action on failure, don't print errors, but
11332 ## do set a variable so people can do so. Do it in a subshell
11333 ## to capture any diagnostics in invoking pkg-config.
11334 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11340 else
11341 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11342 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11346 if test $succeeded = yes; then
11347 pkg_check_gtk=yes
11348 else
11349 pkg_check_gtk=no
11352 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11353 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11355 if test "$pkg_check_gtk" = "yes"; then
11357 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11359 GTK_OBJ=emacsgtkfixed.o
11360 gtk_term_header=gtkutil.h
11361 USE_GTK_TOOLKIT="GTK3"
11362 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11363 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11364 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11366 else
11367 check_gtk2=yes
11368 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11372 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11373 GLIB_REQUIRED=2.10
11374 GTK_REQUIRED=2.10
11375 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11378 succeeded=no
11380 if test "$PKG_CONFIG" = "no" ; then
11381 pkg_check_gtk=no
11382 else
11383 PKG_CONFIG_MIN_VERSION=0.9.0
11384 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11386 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11388 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11389 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11390 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11391 edit_cflags="
11392 s,///*,/,g
11393 s/^/ /
11394 s/ -I/ $isystem/g
11395 s/^ //
11397 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11398 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11400 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11401 succeeded=yes
11402 else
11403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11404 $as_echo "no" >&6; }
11405 GTK_CFLAGS=""
11406 GTK_LIBS=""
11407 ## If we have a custom action on failure, don't print errors, but
11408 ## do set a variable so people can do so. Do it in a subshell
11409 ## to capture any diagnostics in invoking pkg-config.
11410 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11416 else
11417 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11418 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11422 if test $succeeded = yes; then
11423 pkg_check_gtk=yes
11424 else
11425 pkg_check_gtk=no
11428 if test "$pkg_check_gtk" = "no" &&
11429 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11430 then
11431 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11433 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11437 if test x"$pkg_check_gtk" = xyes; then
11441 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11442 CFLAGS="$CFLAGS $GTK_CFLAGS"
11443 LIBS="$GTK_LIBS $LIBS"
11444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GTK compiles" >&5
11445 $as_echo_n "checking whether GTK compiles... " >&6; }
11446 GTK_COMPILES=no
11447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11448 /* end confdefs.h. */
11449 /* Check the Gtk and Glib APIs. */
11450 #include <gtk/gtk.h>
11451 #include <glib-object.h>
11452 static void
11453 callback (GObject *go, GParamSpec *spec, gpointer user_data)
11457 main ()
11460 GtkSettings *gs = 0;
11461 /* Use G_CALLBACK to make sure function pointers can be cast to void *;
11462 strict C prohibits this. Use gtk_main_iteration to test that the
11463 libraries are there. */
11464 if (g_signal_handler_find (G_OBJECT (gs), G_SIGNAL_MATCH_FUNC,
11465 0, 0, 0, G_CALLBACK (callback), 0))
11466 gtk_main_iteration ();
11469 return 0;
11471 _ACEOF
11472 if ac_fn_c_try_link "$LINENO"; then :
11473 GTK_COMPILES=yes
11475 rm -f core conftest.err conftest.$ac_objext \
11476 conftest$ac_exeext conftest.$ac_ext
11477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_COMPILES" >&5
11478 $as_echo "$GTK_COMPILES" >&6; }
11479 if test "${GTK_COMPILES}" != "yes"; then
11480 GTK_OBJ=
11481 if test "$USE_X_TOOLKIT" != "maybe"; then
11482 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11484 else
11485 HAVE_GTK=yes
11487 $as_echo "#define USE_GTK 1" >>confdefs.h
11489 GTK_OBJ="gtkutil.o $GTK_OBJ"
11490 term_header=$gtk_term_header
11491 USE_X_TOOLKIT=none
11492 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11494 else
11495 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11496 closing open displays. This is no problem if you just use
11497 one display, but if you use more than one and close one of them
11498 Emacs may crash." >&5
11499 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11500 closing open displays. This is no problem if you just use
11501 one display, but if you use more than one and close one of them
11502 Emacs may crash." >&2;}
11503 sleep 3
11511 if test "${HAVE_GTK}" = "yes"; then
11513 if test "$with_toolkit_scroll_bars" != no; then
11514 with_toolkit_scroll_bars=yes
11517 HAVE_GTK_FILE_SELECTION=no
11518 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11519 #include <gtk/gtk.h>
11521 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11522 HAVE_GTK_FILE_SELECTION=yes
11523 else
11524 HAVE_GTK_FILE_SELECTION=no
11527 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11528 for ac_func in gtk_file_selection_new
11529 do :
11530 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11531 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11532 cat >>confdefs.h <<_ACEOF
11533 #define HAVE_GTK_FILE_SELECTION_NEW 1
11534 _ACEOF
11537 done
11541 HAVE_GTK_HANDLE_BOX=no
11542 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11543 #include <gtk/gtk.h>
11545 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11546 HAVE_GTK_HANDLE_BOX=yes
11547 else
11548 HAVE_GTK_HANDLE_BOX=no
11551 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11552 for ac_func in gtk_handle_box_new
11553 do :
11554 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11555 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11556 cat >>confdefs.h <<_ACEOF
11557 #define HAVE_GTK_HANDLE_BOX_NEW 1
11558 _ACEOF
11561 done
11565 HAVE_GTK_TEAROFF_MENU_ITEM=no
11566 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11567 #include <gtk/gtk.h>
11569 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11570 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11571 else
11572 HAVE_GTK_TEAROFF_MENU_ITEM=no
11575 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11576 for ac_func in gtk_tearoff_menu_item_new
11577 do :
11578 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11579 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11580 cat >>confdefs.h <<_ACEOF
11581 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11582 _ACEOF
11585 done
11589 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11590 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11591 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11592 gtk_orientable_set_orientation \
11593 gtk_window_set_has_resize_grip
11594 do :
11595 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11596 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11597 eval as_val=\$$as_ac_var
11598 if test "x$as_val" = x""yes; then :
11599 cat >>confdefs.h <<_ACEOF
11600 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11601 _ACEOF
11604 done
11607 term_header=gtkutil.h
11610 HAVE_DBUS=no
11611 DBUS_OBJ=
11612 if test "${with_dbus}" = "yes"; then
11614 succeeded=no
11616 if test "$PKG_CONFIG" = "no" ; then
11617 HAVE_DBUS=no
11618 else
11619 PKG_CONFIG_MIN_VERSION=0.9.0
11620 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11622 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11624 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11625 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11626 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11627 edit_cflags="
11628 s,///*,/,g
11629 s/^/ /
11630 s/ -I/ $isystem/g
11631 s/^ //
11633 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11634 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11636 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11637 succeeded=yes
11638 else
11639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11640 $as_echo "no" >&6; }
11641 DBUS_CFLAGS=""
11642 DBUS_LIBS=""
11643 ## If we have a custom action on failure, don't print errors, but
11644 ## do set a variable so people can do so. Do it in a subshell
11645 ## to capture any diagnostics in invoking pkg-config.
11646 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11652 else
11653 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11654 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11658 if test $succeeded = yes; then
11659 HAVE_DBUS=yes
11660 else
11661 HAVE_DBUS=no
11664 if test "$HAVE_DBUS" = yes; then
11665 LIBS="$LIBS $DBUS_LIBS"
11667 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11669 for ac_func in dbus_watch_get_unix_fd \
11670 dbus_type_is_valid \
11671 dbus_validate_bus_name \
11672 dbus_validate_path \
11673 dbus_validate_interface \
11674 dbus_validate_member
11675 do :
11676 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11677 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11678 eval as_val=\$$as_ac_var
11679 if test "x$as_val" = x""yes; then :
11680 cat >>confdefs.h <<_ACEOF
11681 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11682 _ACEOF
11685 done
11687 DBUS_OBJ=dbusbind.o
11692 HAVE_GSETTINGS=no
11693 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11695 succeeded=no
11697 if test "$PKG_CONFIG" = "no" ; then
11698 HAVE_GSETTINGS=no
11699 else
11700 PKG_CONFIG_MIN_VERSION=0.9.0
11701 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11703 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11705 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11706 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11707 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11708 edit_cflags="
11709 s,///*,/,g
11710 s/^/ /
11711 s/ -I/ $isystem/g
11712 s/^ //
11714 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11715 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11717 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11718 succeeded=yes
11719 else
11720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11721 $as_echo "no" >&6; }
11722 GSETTINGS_CFLAGS=""
11723 GSETTINGS_LIBS=""
11724 ## If we have a custom action on failure, don't print errors, but
11725 ## do set a variable so people can do so. Do it in a subshell
11726 ## to capture any diagnostics in invoking pkg-config.
11727 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11733 else
11734 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11735 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11739 if test $succeeded = yes; then
11740 HAVE_GSETTINGS=yes
11741 else
11742 HAVE_GSETTINGS=no
11745 if test "$HAVE_GSETTINGS" = "yes"; then
11747 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11749 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11750 SETTINGS_LIBS="$GSETTINGS_LIBS"
11754 HAVE_GCONF=no
11755 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11757 succeeded=no
11759 if test "$PKG_CONFIG" = "no" ; then
11760 HAVE_GCONF=no
11761 else
11762 PKG_CONFIG_MIN_VERSION=0.9.0
11763 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11765 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11767 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
11768 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11769 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
11770 edit_cflags="
11771 s,///*,/,g
11772 s/^/ /
11773 s/ -I/ $isystem/g
11774 s/^ //
11776 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11777 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11779 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11780 succeeded=yes
11781 else
11782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11783 $as_echo "no" >&6; }
11784 GCONF_CFLAGS=""
11785 GCONF_LIBS=""
11786 ## If we have a custom action on failure, don't print errors, but
11787 ## do set a variable so people can do so. Do it in a subshell
11788 ## to capture any diagnostics in invoking pkg-config.
11789 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
11795 else
11796 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11797 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11801 if test $succeeded = yes; then
11802 HAVE_GCONF=yes
11803 else
11804 HAVE_GCONF=no
11807 if test "$HAVE_GCONF" = yes; then
11809 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11811 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11812 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11816 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11818 succeeded=no
11820 if test "$PKG_CONFIG" = "no" ; then
11821 HAVE_GOBJECT=no
11822 else
11823 PKG_CONFIG_MIN_VERSION=0.9.0
11824 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11826 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11828 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
11829 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11830 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
11831 edit_cflags="
11832 s,///*,/,g
11833 s/^/ /
11834 s/ -I/ $isystem/g
11835 s/^ //
11837 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11838 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11840 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11841 succeeded=yes
11842 else
11843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11844 $as_echo "no" >&6; }
11845 GOBJECT_CFLAGS=""
11846 GOBJECT_LIBS=""
11847 ## If we have a custom action on failure, don't print errors, but
11848 ## do set a variable so people can do so. Do it in a subshell
11849 ## to capture any diagnostics in invoking pkg-config.
11850 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
11856 else
11857 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11858 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11862 if test $succeeded = yes; then
11863 HAVE_GOBJECT=yes
11864 else
11865 HAVE_GOBJECT=no
11868 if test "$HAVE_GOBJECT" = "yes"; then
11869 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11870 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11872 SAVE_CFLAGS="$CFLAGS"
11873 SAVE_LIBS="$LIBS"
11874 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11875 LIBS="$SETTINGS_LIBS $LIBS"
11876 for ac_func in g_type_init
11877 do :
11878 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11879 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11880 cat >>confdefs.h <<_ACEOF
11881 #define HAVE_G_TYPE_INIT 1
11882 _ACEOF
11885 done
11887 CFLAGS="$SAVE_CFLAGS"
11888 LIBS="$SAVE_LIBS"
11894 HAVE_LIBSELINUX=no
11895 LIBSELINUX_LIBS=
11896 if test "${with_selinux}" = "yes"; then
11897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11898 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11899 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11900 $as_echo_n "(cached) " >&6
11901 else
11902 ac_check_lib_save_LIBS=$LIBS
11903 LIBS="-lselinux $LIBS"
11904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11905 /* end confdefs.h. */
11907 /* Override any GCC internal prototype to avoid an error.
11908 Use char because int might match the return type of a GCC
11909 builtin and then its argument prototype would still apply. */
11910 #ifdef __cplusplus
11911 extern "C"
11912 #endif
11913 char lgetfilecon ();
11915 main ()
11917 return lgetfilecon ();
11919 return 0;
11921 _ACEOF
11922 if ac_fn_c_try_link "$LINENO"; then :
11923 ac_cv_lib_selinux_lgetfilecon=yes
11924 else
11925 ac_cv_lib_selinux_lgetfilecon=no
11927 rm -f core conftest.err conftest.$ac_objext \
11928 conftest$ac_exeext conftest.$ac_ext
11929 LIBS=$ac_check_lib_save_LIBS
11931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11932 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11933 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11934 HAVE_LIBSELINUX=yes
11935 else
11936 HAVE_LIBSELINUX=no
11939 if test "$HAVE_LIBSELINUX" = yes; then
11941 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11943 LIBSELINUX_LIBS=-lselinux
11948 HAVE_GNUTLS=no
11949 if test "${with_gnutls}" = "yes" ; then
11951 succeeded=no
11953 if test "$PKG_CONFIG" = "no" ; then
11954 HAVE_GNUTLS=no
11955 else
11956 PKG_CONFIG_MIN_VERSION=0.9.0
11957 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11959 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11961 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
11962 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
11963 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
11964 edit_cflags="
11965 s,///*,/,g
11966 s/^/ /
11967 s/ -I/ $isystem/g
11968 s/^ //
11970 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11971 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11973 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11974 succeeded=yes
11975 else
11976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11977 $as_echo "no" >&6; }
11978 LIBGNUTLS_CFLAGS=""
11979 LIBGNUTLS_LIBS=""
11980 ## If we have a custom action on failure, don't print errors, but
11981 ## do set a variable so people can do so. Do it in a subshell
11982 ## to capture any diagnostics in invoking pkg-config.
11983 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
11989 else
11990 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11991 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11995 if test $succeeded = yes; then
11996 HAVE_GNUTLS=yes
11997 else
11998 HAVE_GNUTLS=no
12001 if test "${HAVE_GNUTLS}" = "yes"; then
12003 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
12007 # Windows loads GnuTLS dynamically
12008 if test "${opsys}" = "mingw32"; then
12009 LIBGNUTLS_LIBS=
12010 else
12011 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
12012 LIBS="$LIBGNUTLS_LIBS $LIBS"
12019 NOTIFY_OBJ=
12020 NOTIFY_SUMMARY=no
12022 if test "${with_ns}" = yes && test ${with_file_notification} = yes; then
12023 with_file_notification=no
12026 case $with_file_notification,$opsys in
12027 w32,* | yes,mingw32)
12028 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12029 if test "x$ac_cv_header_windows_h" = x""yes; then :
12034 if test "$ac_cv_header_windows_h" = yes ; then
12036 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12038 NOTIFY_OBJ=w32notify.o
12039 NOTIFY_SUMMARY="yes (w32)"
12040 fi ;;
12041 esac
12043 case $with_file_notification,$NOTIFY_OBJ in
12044 gfile, | yes,)
12046 succeeded=no
12048 if test "$PKG_CONFIG" = "no" ; then
12049 HAVE_GFILENOTIFY=no
12050 else
12051 PKG_CONFIG_MIN_VERSION=0.9.0
12052 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12054 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12056 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12057 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12058 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12059 edit_cflags="
12060 s,///*,/,g
12061 s/^/ /
12062 s/ -I/ $isystem/g
12063 s/^ //
12065 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12066 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12068 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12069 succeeded=yes
12070 else
12071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12072 $as_echo "no" >&6; }
12073 GFILENOTIFY_CFLAGS=""
12074 GFILENOTIFY_LIBS=""
12075 ## If we have a custom action on failure, don't print errors, but
12076 ## do set a variable so people can do so. Do it in a subshell
12077 ## to capture any diagnostics in invoking pkg-config.
12078 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12084 else
12085 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12086 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12090 if test $succeeded = yes; then
12091 HAVE_GFILENOTIFY=yes
12092 else
12093 HAVE_GFILENOTIFY=no
12096 if test "$HAVE_GFILENOTIFY" = "yes"; then
12098 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12100 NOTIFY_OBJ=gfilenotify.o
12101 NOTIFY_SUMMARY="yes -lgio (gfile)"
12102 fi ;;
12103 esac
12105 case $with_file_notification,$NOTIFY_OBJ in
12106 inotify, | yes,)
12107 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12108 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12113 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12114 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12115 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12119 if test "$ac_cv_func_inotify_init1" = yes; then
12121 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12123 NOTIFY_OBJ=inotify.o
12124 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12126 fi ;;
12127 esac
12129 case $with_file_notification,$NOTIFY_OBJ in
12130 yes,* | no,* | *,?*) ;;
12131 *) as_fn_error "File notification \`$with_file_notification' requested but requirements not found." "$LINENO" 5 ;;
12132 esac
12134 if test -n "$NOTIFY_OBJ"; then
12136 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12143 HAVE_XAW3D=no
12144 LUCID_LIBW=
12145 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12146 if test "$with_xaw3d" != no; then
12147 if test "${emacs_cv_xaw3d+set}" = set; then :
12148 $as_echo_n "(cached) " >&6
12149 else
12150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12151 /* end confdefs.h. */
12153 #include <X11/Intrinsic.h>
12154 #include <X11/Xaw3d/Simple.h>
12156 main ()
12160 return 0;
12162 _ACEOF
12163 if ac_fn_c_try_link "$LINENO"; then :
12164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12165 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12166 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12167 $as_echo_n "(cached) " >&6
12168 else
12169 ac_check_lib_save_LIBS=$LIBS
12170 LIBS="-lXaw3d $LIBS"
12171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12172 /* end confdefs.h. */
12174 /* Override any GCC internal prototype to avoid an error.
12175 Use char because int might match the return type of a GCC
12176 builtin and then its argument prototype would still apply. */
12177 #ifdef __cplusplus
12178 extern "C"
12179 #endif
12180 char XawScrollbarSetThumb ();
12182 main ()
12184 return XawScrollbarSetThumb ();
12186 return 0;
12188 _ACEOF
12189 if ac_fn_c_try_link "$LINENO"; then :
12190 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12191 else
12192 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12194 rm -f core conftest.err conftest.$ac_objext \
12195 conftest$ac_exeext conftest.$ac_ext
12196 LIBS=$ac_check_lib_save_LIBS
12198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12199 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12200 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12201 emacs_cv_xaw3d=yes
12202 else
12203 emacs_cv_xaw3d=no
12206 else
12207 emacs_cv_xaw3d=no
12209 rm -f core conftest.err conftest.$ac_objext \
12210 conftest$ac_exeext conftest.$ac_ext
12213 else
12214 emacs_cv_xaw3d=no
12216 if test $emacs_cv_xaw3d = yes; then
12217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12218 $as_echo_n "checking for xaw3d... " >&6; }
12219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12220 $as_echo "yes; using Lucid toolkit" >&6; }
12221 USE_X_TOOLKIT=LUCID
12222 HAVE_XAW3D=yes
12223 LUCID_LIBW=-lXaw3d
12225 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12227 else
12228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12229 $as_echo_n "checking for xaw3d... " >&6; }
12230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12231 $as_echo "no" >&6; }
12232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12233 $as_echo_n "checking for libXaw... " >&6; }
12234 if test "${emacs_cv_xaw+set}" = set; then :
12235 $as_echo_n "(cached) " >&6
12236 else
12237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12238 /* end confdefs.h. */
12240 #include <X11/Intrinsic.h>
12241 #include <X11/Xaw/Simple.h>
12243 main ()
12247 return 0;
12249 _ACEOF
12250 if ac_fn_c_try_link "$LINENO"; then :
12251 emacs_cv_xaw=yes
12252 else
12253 emacs_cv_xaw=no
12255 rm -f core conftest.err conftest.$ac_objext \
12256 conftest$ac_exeext conftest.$ac_ext
12259 if test $emacs_cv_xaw = yes; then
12260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12261 $as_echo "yes; using Lucid toolkit" >&6; }
12262 USE_X_TOOLKIT=LUCID
12263 LUCID_LIBW=-lXaw
12264 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12265 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12266 else
12267 as_fn_error "No X toolkit could be found.
12268 If you are sure you want Emacs compiled without an X toolkit, pass
12269 --with-x-toolkit=no
12270 to configure. Otherwise, install the development libraries for the toolkit
12271 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12276 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12278 LIBXTR6=
12279 if test "${USE_X_TOOLKIT}" != "none"; then
12280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12281 $as_echo_n "checking X11 toolkit version... " >&6; }
12282 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12283 $as_echo_n "(cached) " >&6
12284 else
12285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12286 /* end confdefs.h. */
12287 #include <X11/Intrinsic.h>
12289 main ()
12291 #if XtSpecificationRelease < 6
12292 fail;
12293 #endif
12296 return 0;
12298 _ACEOF
12299 if ac_fn_c_try_link "$LINENO"; then :
12300 emacs_cv_x11_toolkit_version_6=yes
12301 else
12302 emacs_cv_x11_toolkit_version_6=no
12304 rm -f core conftest.err conftest.$ac_objext \
12305 conftest$ac_exeext conftest.$ac_ext
12308 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12309 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12311 $as_echo "6 or newer" >&6; }
12313 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12315 LIBXTR6="-lSM -lICE"
12316 case "$opsys" in
12317 ## Use libw.a along with X11R6 Xt.
12318 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12319 esac
12320 else
12321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12322 $as_echo "before 6" >&6; }
12325 OLDLIBS="$LIBS"
12326 if test x$HAVE_X11XTR6 = xyes; then
12327 LIBS="-lXt -lSM -lICE $LIBS"
12328 else
12329 LIBS="-lXt $LIBS"
12331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12332 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12333 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12334 $as_echo_n "(cached) " >&6
12335 else
12336 ac_check_lib_save_LIBS=$LIBS
12337 LIBS="-lXmu $LIBS"
12338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12339 /* end confdefs.h. */
12341 /* Override any GCC internal prototype to avoid an error.
12342 Use char because int might match the return type of a GCC
12343 builtin and then its argument prototype would still apply. */
12344 #ifdef __cplusplus
12345 extern "C"
12346 #endif
12347 char XmuConvertStandardSelection ();
12349 main ()
12351 return XmuConvertStandardSelection ();
12353 return 0;
12355 _ACEOF
12356 if ac_fn_c_try_link "$LINENO"; then :
12357 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12358 else
12359 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12361 rm -f core conftest.err conftest.$ac_objext \
12362 conftest$ac_exeext conftest.$ac_ext
12363 LIBS=$ac_check_lib_save_LIBS
12365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12366 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12367 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12368 cat >>confdefs.h <<_ACEOF
12369 #define HAVE_LIBXMU 1
12370 _ACEOF
12372 LIBS="-lXmu $LIBS"
12376 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12380 LIBXMU=-lXmu
12381 case $opsys in
12382 ## These systems don't supply Xmu.
12383 hpux* | aix4-2 )
12384 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12386 mingw32 )
12387 LIBXMU=
12389 esac
12392 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12393 if test "${HAVE_X11}" = "yes"; then
12394 if test "${USE_X_TOOLKIT}" != "none"; then
12395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12396 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12397 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12398 $as_echo_n "(cached) " >&6
12399 else
12400 ac_check_lib_save_LIBS=$LIBS
12401 LIBS="-lXext $LIBS"
12402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12403 /* end confdefs.h. */
12405 /* Override any GCC internal prototype to avoid an error.
12406 Use char because int might match the return type of a GCC
12407 builtin and then its argument prototype would still apply. */
12408 #ifdef __cplusplus
12409 extern "C"
12410 #endif
12411 char XShapeQueryExtension ();
12413 main ()
12415 return XShapeQueryExtension ();
12417 return 0;
12419 _ACEOF
12420 if ac_fn_c_try_link "$LINENO"; then :
12421 ac_cv_lib_Xext_XShapeQueryExtension=yes
12422 else
12423 ac_cv_lib_Xext_XShapeQueryExtension=no
12425 rm -f core conftest.err conftest.$ac_objext \
12426 conftest$ac_exeext conftest.$ac_ext
12427 LIBS=$ac_check_lib_save_LIBS
12429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12430 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12431 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12432 cat >>confdefs.h <<_ACEOF
12433 #define HAVE_LIBXEXT 1
12434 _ACEOF
12436 LIBS="-lXext $LIBS"
12443 LIBXP=
12444 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12445 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12446 if test -d /usr/include/openmotif; then
12447 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12448 emacs_cv_openmotif=yes
12449 case "$canonical" in
12450 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12451 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12454 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12455 esac
12456 else
12457 emacs_cv_openmotif=no
12459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12460 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12461 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12462 $as_echo_n "(cached) " >&6
12463 else
12464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12465 /* end confdefs.h. */
12466 #include <Xm/Xm.h>
12468 main ()
12470 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12471 int x = 5;
12472 #else
12473 Motif version prior to 2.1.
12474 #endif
12476 return 0;
12478 _ACEOF
12479 if ac_fn_c_try_compile "$LINENO"; then :
12480 emacs_cv_motif_version_2_1=yes
12481 else
12482 emacs_cv_motif_version_2_1=no
12484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12487 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12488 if test $emacs_cv_motif_version_2_1 = yes; then
12489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12490 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12491 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12492 $as_echo_n "(cached) " >&6
12493 else
12494 ac_check_lib_save_LIBS=$LIBS
12495 LIBS="-lXp $LIBS"
12496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12497 /* end confdefs.h. */
12499 /* Override any GCC internal prototype to avoid an error.
12500 Use char because int might match the return type of a GCC
12501 builtin and then its argument prototype would still apply. */
12502 #ifdef __cplusplus
12503 extern "C"
12504 #endif
12505 char XpCreateContext ();
12507 main ()
12509 return XpCreateContext ();
12511 return 0;
12513 _ACEOF
12514 if ac_fn_c_try_link "$LINENO"; then :
12515 ac_cv_lib_Xp_XpCreateContext=yes
12516 else
12517 ac_cv_lib_Xp_XpCreateContext=no
12519 rm -f core conftest.err conftest.$ac_objext \
12520 conftest$ac_exeext conftest.$ac_ext
12521 LIBS=$ac_check_lib_save_LIBS
12523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12524 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12525 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12526 LIBXP=-lXp
12529 if test x$emacs_cv_openmotif = xyes; then
12530 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12532 else
12533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12534 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12535 if test "${emacs_cv_lesstif+set}" = set; then :
12536 $as_echo_n "(cached) " >&6
12537 else
12538 # We put this in CFLAGS temporarily to precede other -I options
12539 # that might be in CFLAGS temporarily.
12540 # We put this in CPPFLAGS where it precedes the other -I options.
12541 OLD_CPPFLAGS=$CPPFLAGS
12542 OLD_CFLAGS=$CFLAGS
12543 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12544 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12546 /* end confdefs.h. */
12547 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12549 main ()
12551 int x = 5;
12553 return 0;
12555 _ACEOF
12556 if ac_fn_c_try_compile "$LINENO"; then :
12557 emacs_cv_lesstif=yes
12558 else
12559 emacs_cv_lesstif=no
12561 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12564 $as_echo "$emacs_cv_lesstif" >&6; }
12565 if test $emacs_cv_lesstif = yes; then
12566 # Make sure this -I option remains in CPPFLAGS after it is set
12567 # back to REAL_CPPFLAGS.
12568 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12569 # have those other -I options anyway. Ultimately, having this
12570 # directory ultimately in CPPFLAGS will be enough.
12571 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12572 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12573 else
12574 CFLAGS=$OLD_CFLAGS
12575 CPPFLAGS=$OLD_CPPFLAGS
12578 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12579 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12581 else
12582 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12589 USE_TOOLKIT_SCROLL_BARS=no
12590 if test "${with_toolkit_scroll_bars}" != "no"; then
12591 if test "${USE_X_TOOLKIT}" != "none"; then
12592 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12593 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12595 HAVE_XAW3D=no
12596 USE_TOOLKIT_SCROLL_BARS=yes
12597 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12598 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12600 USE_TOOLKIT_SCROLL_BARS=yes
12602 elif test "${HAVE_GTK}" = "yes"; then
12603 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12605 USE_TOOLKIT_SCROLL_BARS=yes
12606 elif test "${HAVE_NS}" = "yes"; then
12607 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12609 USE_TOOLKIT_SCROLL_BARS=yes
12610 elif test "${HAVE_W32}" = "yes"; then
12611 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12613 USE_TOOLKIT_SCROLL_BARS=yes
12617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12618 /* end confdefs.h. */
12620 #include <X11/Xlib.h>
12621 #include <X11/Xresource.h>
12623 main ()
12625 XIMProc callback;
12627 return 0;
12629 _ACEOF
12630 if ac_fn_c_try_compile "$LINENO"; then :
12631 HAVE_XIM=yes
12633 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12635 else
12636 HAVE_XIM=no
12638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12641 if test "${with_xim}" != "no"; then
12643 $as_echo "#define USE_XIM 1" >>confdefs.h
12648 if test "${HAVE_XIM}" != "no"; then
12649 late_CFLAGS=$CFLAGS
12650 if test "$GCC" = yes; then
12651 CFLAGS="$CFLAGS --pedantic-errors"
12653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12654 /* end confdefs.h. */
12656 #include <X11/Xlib.h>
12657 #include <X11/Xresource.h>
12659 main ()
12661 Display *display;
12662 XrmDatabase db;
12663 char *res_name;
12664 char *res_class;
12665 XIMProc callback;
12666 XPointer *client_data;
12667 #ifndef __GNUC__
12668 /* If we're not using GCC, it's probably not XFree86, and this is
12669 probably right, but we can't use something like --pedantic-errors. */
12670 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12671 char*, XIMProc, XPointer*);
12672 #endif
12673 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12674 client_data);
12676 return 0;
12678 _ACEOF
12679 if ac_fn_c_try_compile "$LINENO"; then :
12680 emacs_cv_arg6_star=yes
12682 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12683 if test "$emacs_cv_arg6_star" = yes; then
12684 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12686 else
12687 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12690 CFLAGS=$late_CFLAGS
12693 ### Start of font-backend (under any platform) section.
12694 # (nothing here yet -- this is a placeholder)
12695 ### End of font-backend (under any platform) section.
12697 ### Start of font-backend (under X11) section.
12698 if test "${HAVE_X11}" = "yes"; then
12700 succeeded=no
12702 if test "$PKG_CONFIG" = "no" ; then
12703 HAVE_FC=no
12704 else
12705 PKG_CONFIG_MIN_VERSION=0.9.0
12706 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12708 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12710 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12711 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12712 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12713 edit_cflags="
12714 s,///*,/,g
12715 s/^/ /
12716 s/ -I/ $isystem/g
12717 s/^ //
12719 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12720 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12722 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12723 succeeded=yes
12724 else
12725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12726 $as_echo "no" >&6; }
12727 FONTCONFIG_CFLAGS=""
12728 FONTCONFIG_LIBS=""
12729 ## If we have a custom action on failure, don't print errors, but
12730 ## do set a variable so people can do so. Do it in a subshell
12731 ## to capture any diagnostics in invoking pkg-config.
12732 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12738 else
12739 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12740 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12744 if test $succeeded = yes; then
12745 HAVE_FC=yes
12746 else
12747 HAVE_FC=no
12751 ## Use -lXft if available, unless `--with-xft=no'.
12752 HAVE_XFT=maybe
12753 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12754 with_xft="no";
12756 if test "x${with_xft}" != "xno"; then
12759 succeeded=no
12761 if test "$PKG_CONFIG" = "no" ; then
12762 HAVE_XFT=no
12763 else
12764 PKG_CONFIG_MIN_VERSION=0.9.0
12765 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12767 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12769 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
12770 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
12771 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
12772 edit_cflags="
12773 s,///*,/,g
12774 s/^/ /
12775 s/ -I/ $isystem/g
12776 s/^ //
12778 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
12779 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12781 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12782 succeeded=yes
12783 else
12784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12785 $as_echo "no" >&6; }
12786 XFT_CFLAGS=""
12787 XFT_LIBS=""
12788 ## If we have a custom action on failure, don't print errors, but
12789 ## do set a variable so people can do so. Do it in a subshell
12790 ## to capture any diagnostics in invoking pkg-config.
12791 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
12797 else
12798 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12799 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12803 if test $succeeded = yes; then
12805 else
12806 HAVE_XFT=no
12809 ## Because xftfont.c uses XRenderQueryExtension, we also
12810 ## need to link to -lXrender.
12811 HAVE_XRENDER=no
12812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12813 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12814 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12815 $as_echo_n "(cached) " >&6
12816 else
12817 ac_check_lib_save_LIBS=$LIBS
12818 LIBS="-lXrender $LIBS"
12819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12820 /* end confdefs.h. */
12822 /* Override any GCC internal prototype to avoid an error.
12823 Use char because int might match the return type of a GCC
12824 builtin and then its argument prototype would still apply. */
12825 #ifdef __cplusplus
12826 extern "C"
12827 #endif
12828 char XRenderQueryExtension ();
12830 main ()
12832 return XRenderQueryExtension ();
12834 return 0;
12836 _ACEOF
12837 if ac_fn_c_try_link "$LINENO"; then :
12838 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12839 else
12840 ac_cv_lib_Xrender_XRenderQueryExtension=no
12842 rm -f core conftest.err conftest.$ac_objext \
12843 conftest$ac_exeext conftest.$ac_ext
12844 LIBS=$ac_check_lib_save_LIBS
12846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12847 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12848 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12849 HAVE_XRENDER=yes
12852 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12853 OLD_CPPFLAGS="$CPPFLAGS"
12854 OLD_CFLAGS="$CFLAGS"
12855 OLD_LIBS="$LIBS"
12856 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12857 CFLAGS="$CFLAGS $XFT_CFLAGS"
12858 XFT_LIBS="-lXrender $XFT_LIBS"
12859 LIBS="$XFT_LIBS $LIBS"
12860 ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/X.h>
12862 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12864 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12865 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12866 $as_echo_n "(cached) " >&6
12867 else
12868 ac_check_lib_save_LIBS=$LIBS
12869 LIBS="-lXft $XFT_LIBS $LIBS"
12870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12871 /* end confdefs.h. */
12873 /* Override any GCC internal prototype to avoid an error.
12874 Use char because int might match the return type of a GCC
12875 builtin and then its argument prototype would still apply. */
12876 #ifdef __cplusplus
12877 extern "C"
12878 #endif
12879 char XftFontOpen ();
12881 main ()
12883 return XftFontOpen ();
12885 return 0;
12887 _ACEOF
12888 if ac_fn_c_try_link "$LINENO"; then :
12889 ac_cv_lib_Xft_XftFontOpen=yes
12890 else
12891 ac_cv_lib_Xft_XftFontOpen=no
12893 rm -f core conftest.err conftest.$ac_objext \
12894 conftest$ac_exeext conftest.$ac_ext
12895 LIBS=$ac_check_lib_save_LIBS
12897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12898 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12899 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12900 HAVE_XFT=yes
12907 if test "${HAVE_XFT}" = "yes"; then
12909 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12912 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12913 else
12914 CPPFLAGS="$OLD_CPPFLAGS"
12915 CFLAGS="$OLD_CFLAGS"
12916 LIBS="$OLD_LIBS"
12917 fi # "${HAVE_XFT}" = "yes"
12918 fi # "$HAVE_XFT" != no
12919 fi # "x${with_xft}" != "xno"
12921 ## We used to allow building with FreeType and without Xft.
12922 ## However, the ftx font backend driver is not in good shape.
12923 if test "$HAVE_XFT" != "yes"; then
12924 HAVE_XFT=no
12925 HAVE_FREETYPE=no
12926 else
12928 succeeded=no
12930 if test "$PKG_CONFIG" = "no" ; then
12931 HAVE_FREETYPE=no
12932 else
12933 PKG_CONFIG_MIN_VERSION=0.9.0
12934 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12936 $as_echo_n "checking for freetype2... " >&6; }
12938 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
12939 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
12940 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
12941 edit_cflags="
12942 s,///*,/,g
12943 s/^/ /
12944 s/ -I/ $isystem/g
12945 s/^ //
12947 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12948 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12950 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12951 succeeded=yes
12952 else
12953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12954 $as_echo "no" >&6; }
12955 FREETYPE_CFLAGS=""
12956 FREETYPE_LIBS=""
12957 ## If we have a custom action on failure, don't print errors, but
12958 ## do set a variable so people can do so. Do it in a subshell
12959 ## to capture any diagnostics in invoking pkg-config.
12960 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
12966 else
12967 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12968 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12972 if test $succeeded = yes; then
12973 HAVE_FREETYPE=yes
12974 else
12975 HAVE_FREETYPE=no
12979 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12982 HAVE_LIBOTF=no
12983 if test "${HAVE_FREETYPE}" = "yes"; then
12985 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12987 if test "${with_libotf}" != "no"; then
12989 succeeded=no
12991 if test "$PKG_CONFIG" = "no" ; then
12992 HAVE_LIBOTF=no
12993 else
12994 PKG_CONFIG_MIN_VERSION=0.9.0
12995 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12997 $as_echo_n "checking for libotf... " >&6; }
12999 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13000 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13001 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13002 edit_cflags="
13003 s,///*,/,g
13004 s/^/ /
13005 s/ -I/ $isystem/g
13006 s/^ //
13008 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13009 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13011 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13012 succeeded=yes
13013 else
13014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13015 $as_echo "no" >&6; }
13016 LIBOTF_CFLAGS=""
13017 LIBOTF_LIBS=""
13018 ## If we have a custom action on failure, don't print errors, but
13019 ## do set a variable so people can do so. Do it in a subshell
13020 ## to capture any diagnostics in invoking pkg-config.
13021 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13027 else
13028 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13029 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13033 if test $succeeded = yes; then
13034 HAVE_LIBOTF=yes
13035 else
13036 HAVE_LIBOTF=no
13039 if test "$HAVE_LIBOTF" = "yes"; then
13041 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13044 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13045 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13046 $as_echo_n "(cached) " >&6
13047 else
13048 ac_check_lib_save_LIBS=$LIBS
13049 LIBS="-lotf $LIBS"
13050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13051 /* end confdefs.h. */
13053 /* Override any GCC internal prototype to avoid an error.
13054 Use char because int might match the return type of a GCC
13055 builtin and then its argument prototype would still apply. */
13056 #ifdef __cplusplus
13057 extern "C"
13058 #endif
13059 char OTF_get_variation_glyphs ();
13061 main ()
13063 return OTF_get_variation_glyphs ();
13065 return 0;
13067 _ACEOF
13068 if ac_fn_c_try_link "$LINENO"; then :
13069 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13070 else
13071 ac_cv_lib_otf_OTF_get_variation_glyphs=no
13073 rm -f core conftest.err conftest.$ac_objext \
13074 conftest$ac_exeext conftest.$ac_ext
13075 LIBS=$ac_check_lib_save_LIBS
13077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
13078 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13079 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13080 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13081 else
13082 HAVE_OTF_GET_VARIATION_GLYPHS=no
13085 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13087 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13094 HAVE_M17N_FLT=no
13095 if test "${HAVE_LIBOTF}" = yes; then
13096 if test "${with_m17n_flt}" != "no"; then
13098 succeeded=no
13100 if test "$PKG_CONFIG" = "no" ; then
13101 HAVE_M17N_FLT=no
13102 else
13103 PKG_CONFIG_MIN_VERSION=0.9.0
13104 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13106 $as_echo_n "checking for m17n-flt... " >&6; }
13108 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13109 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13110 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13111 edit_cflags="
13112 s,///*,/,g
13113 s/^/ /
13114 s/ -I/ $isystem/g
13115 s/^ //
13117 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13118 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13120 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13121 succeeded=yes
13122 else
13123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13124 $as_echo "no" >&6; }
13125 M17N_FLT_CFLAGS=""
13126 M17N_FLT_LIBS=""
13127 ## If we have a custom action on failure, don't print errors, but
13128 ## do set a variable so people can do so. Do it in a subshell
13129 ## to capture any diagnostics in invoking pkg-config.
13130 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13136 else
13137 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13138 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13142 if test $succeeded = yes; then
13143 HAVE_M17N_FLT=yes
13144 else
13145 HAVE_M17N_FLT=no
13148 if test "$HAVE_M17N_FLT" = "yes"; then
13150 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13155 else
13156 HAVE_XFT=no
13157 HAVE_FREETYPE=no
13158 HAVE_LIBOTF=no
13159 HAVE_M17N_FLT=no
13162 ### End of font-backend (under X11) section.
13173 ### Use -lXpm if available, unless `--with-xpm=no'.
13174 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13175 HAVE_XPM=no
13176 LIBXPM=
13177 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13178 if test "${with_xpm}" != "no"; then
13179 SAVE_CPPFLAGS="$CPPFLAGS"
13180 SAVE_LDFLAGS="$LDFLAGS"
13181 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13182 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13183 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13184 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13186 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13187 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13188 $as_echo_n "(cached) " >&6
13189 else
13190 ac_check_lib_save_LIBS=$LIBS
13191 LIBS="-lXpm $LIBS"
13192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13193 /* end confdefs.h. */
13195 /* Override any GCC internal prototype to avoid an error.
13196 Use char because int might match the return type of a GCC
13197 builtin and then its argument prototype would still apply. */
13198 #ifdef __cplusplus
13199 extern "C"
13200 #endif
13201 char XpmReadFileToImage ();
13203 main ()
13205 return XpmReadFileToImage ();
13207 return 0;
13209 _ACEOF
13210 if ac_fn_c_try_link "$LINENO"; then :
13211 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13212 else
13213 ac_cv_lib_Xpm_XpmReadFileToImage=no
13215 rm -f core conftest.err conftest.$ac_objext \
13216 conftest$ac_exeext conftest.$ac_ext
13217 LIBS=$ac_check_lib_save_LIBS
13219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13220 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13221 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13222 HAVE_XPM=yes
13228 if test "${HAVE_XPM}" = "yes"; then
13229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13230 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13232 /* end confdefs.h. */
13233 #include "X11/xpm.h"
13234 #ifndef XpmReturnAllocPixels
13235 no_return_alloc_pixels
13236 #endif
13238 _ACEOF
13239 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13240 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13241 HAVE_XPM=no
13242 else
13243 HAVE_XPM=yes
13245 rm -f conftest*
13248 if test "${HAVE_XPM}" = "yes"; then
13249 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13251 $as_echo "yes" >&6; }
13252 else
13253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13254 $as_echo "no" >&6; }
13255 CPPFLAGS="$SAVE_CPPFLAGS"
13256 LDFLAGS="$SAVE_LDFLAGS"
13261 if test "${HAVE_XPM}" = "yes"; then
13263 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13265 LIBXPM=-lXpm
13269 if test "${HAVE_X11}" = "yes"; then
13270 if test "${with_xpm}" != "no"; then
13271 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13272 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13274 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13275 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13276 $as_echo_n "(cached) " >&6
13277 else
13278 ac_check_lib_save_LIBS=$LIBS
13279 LIBS="-lXpm -lX11 $LIBS"
13280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13281 /* end confdefs.h. */
13283 /* Override any GCC internal prototype to avoid an error.
13284 Use char because int might match the return type of a GCC
13285 builtin and then its argument prototype would still apply. */
13286 #ifdef __cplusplus
13287 extern "C"
13288 #endif
13289 char XpmReadFileToPixmap ();
13291 main ()
13293 return XpmReadFileToPixmap ();
13295 return 0;
13297 _ACEOF
13298 if ac_fn_c_try_link "$LINENO"; then :
13299 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13300 else
13301 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13303 rm -f core conftest.err conftest.$ac_objext \
13304 conftest$ac_exeext conftest.$ac_ext
13305 LIBS=$ac_check_lib_save_LIBS
13307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13308 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13309 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13310 HAVE_XPM=yes
13316 if test "${HAVE_XPM}" = "yes"; then
13317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13318 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13320 /* end confdefs.h. */
13321 #include "X11/xpm.h"
13322 #ifndef XpmReturnAllocPixels
13323 no_return_alloc_pixels
13324 #endif
13326 _ACEOF
13327 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13328 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13329 HAVE_XPM=no
13330 else
13331 HAVE_XPM=yes
13333 rm -f conftest*
13336 if test "${HAVE_XPM}" = "yes"; then
13337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13338 $as_echo "yes" >&6; }
13339 else
13340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13341 $as_echo "no" >&6; }
13346 if test "${HAVE_XPM}" = "yes"; then
13348 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13350 LIBXPM=-lXpm
13354 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13355 ### slightly different requirements wrt image libraries (it doesn't
13356 ### use -lXpm because it loads the xpm shared library dynamically at
13357 ### run time).
13358 if test "${opsys}" = "mingw32"; then
13359 if test "${with_xpm}" != "no"; then
13360 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13361 #define FOR_MSW 1
13363 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13364 HAVE_XPM=yes
13365 else
13366 HAVE_XPM=no
13372 if test "${HAVE_XPM}" = "yes"; then
13374 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13381 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13382 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13383 HAVE_JPEG=no
13384 LIBJPEG=
13385 if test "${opsys}" = "mingw32"; then
13386 if test "${with_jpeg}" != "no"; then
13387 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13388 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13389 HAVE_JPEG=yes
13390 else
13391 HAVE_JPEG=no
13396 if test "${HAVE_JPEG}" = "yes"; then
13397 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13400 /* end confdefs.h. */
13401 #include <jpeglib.h>
13402 version=JPEG_LIB_VERSION
13404 _ACEOF
13405 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13406 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13407 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13409 else
13410 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13411 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13412 HAVE_JPEG=no
13414 rm -f conftest*
13417 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13418 if test "${with_jpeg}" != "no"; then
13419 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13420 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13422 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13423 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13424 $as_echo_n "(cached) " >&6
13425 else
13426 ac_check_lib_save_LIBS=$LIBS
13427 LIBS="-ljpeg $LIBS"
13428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13429 /* end confdefs.h. */
13431 /* Override any GCC internal prototype to avoid an error.
13432 Use char because int might match the return type of a GCC
13433 builtin and then its argument prototype would still apply. */
13434 #ifdef __cplusplus
13435 extern "C"
13436 #endif
13437 char jpeg_destroy_compress ();
13439 main ()
13441 return jpeg_destroy_compress ();
13443 return 0;
13445 _ACEOF
13446 if ac_fn_c_try_link "$LINENO"; then :
13447 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13448 else
13449 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13451 rm -f core conftest.err conftest.$ac_objext \
13452 conftest$ac_exeext conftest.$ac_ext
13453 LIBS=$ac_check_lib_save_LIBS
13455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13456 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13457 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13458 HAVE_JPEG=yes
13466 if test "${HAVE_JPEG}" = "yes"; then
13467 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13470 /* end confdefs.h. */
13471 #include <jpeglib.h>
13472 version=JPEG_LIB_VERSION
13474 _ACEOF
13475 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13476 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13477 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13479 else
13480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13481 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13482 HAVE_JPEG=no
13484 rm -f conftest*
13487 if test "${HAVE_JPEG}" = "yes"; then
13488 LIBJPEG=-ljpeg
13493 ### Use -lpng if available, unless `--with-png=no'.
13494 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13495 HAVE_PNG=no
13496 LIBPNG=
13497 if test "${opsys}" = "mingw32"; then
13498 if test "${with_png}" != "no"; then
13499 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13500 if test "x$ac_cv_header_png_h" = x""yes; then :
13501 HAVE_PNG=yes
13502 else
13503 HAVE_PNG=no
13508 if test "${HAVE_PNG}" = "yes"; then
13510 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13513 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13514 # include <libpng/png.h>
13515 #else
13516 # include <png.h>
13517 #endif
13520 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13522 else
13524 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13529 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13530 if test "${with_png}" != "no"; then
13531 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13532 # in /usr/include/libpng.
13533 for ac_header in png.h libpng/png.h
13534 do :
13535 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13536 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13537 eval as_val=\$$as_ac_Header
13538 if test "x$as_val" = x""yes; then :
13539 cat >>confdefs.h <<_ACEOF
13540 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13541 _ACEOF
13542 break
13545 done
13547 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13549 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13550 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13551 $as_echo_n "(cached) " >&6
13552 else
13553 ac_check_lib_save_LIBS=$LIBS
13554 LIBS="-lpng -lz -lm $LIBS"
13555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13556 /* end confdefs.h. */
13558 /* Override any GCC internal prototype to avoid an error.
13559 Use char because int might match the return type of a GCC
13560 builtin and then its argument prototype would still apply. */
13561 #ifdef __cplusplus
13562 extern "C"
13563 #endif
13564 char png_get_channels ();
13566 main ()
13568 return png_get_channels ();
13570 return 0;
13572 _ACEOF
13573 if ac_fn_c_try_link "$LINENO"; then :
13574 ac_cv_lib_png_png_get_channels=yes
13575 else
13576 ac_cv_lib_png_png_get_channels=no
13578 rm -f core conftest.err conftest.$ac_objext \
13579 conftest$ac_exeext conftest.$ac_ext
13580 LIBS=$ac_check_lib_save_LIBS
13582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13583 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13584 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13585 HAVE_PNG=yes
13591 if test "${HAVE_PNG}" = "yes"; then
13593 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13595 LIBPNG="-lpng -lz -lm"
13597 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13598 # include <libpng/png.h>
13599 #else
13600 # include <png.h>
13601 #endif
13604 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13606 else
13608 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13616 ### Use -ltiff if available, unless `--with-tiff=no'.
13617 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
13618 HAVE_TIFF=no
13619 LIBTIFF=
13620 if test "${opsys}" = "mingw32"; then
13621 if test "${with_tiff}" != "no"; then
13622 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13623 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13624 HAVE_TIFF=yes
13625 else
13626 HAVE_TIFF=no
13631 if test "${HAVE_TIFF}" = "yes"; then
13633 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13636 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13637 if test "${with_tiff}" != "no"; then
13638 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13639 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13640 tifflibs="-lz -lm"
13641 # At least one tiff package requires the jpeg library.
13642 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13644 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
13645 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
13646 $as_echo_n "(cached) " >&6
13647 else
13648 ac_check_lib_save_LIBS=$LIBS
13649 LIBS="-ltiff $tifflibs $LIBS"
13650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13651 /* end confdefs.h. */
13653 /* Override any GCC internal prototype to avoid an error.
13654 Use char because int might match the return type of a GCC
13655 builtin and then its argument prototype would still apply. */
13656 #ifdef __cplusplus
13657 extern "C"
13658 #endif
13659 char TIFFGetVersion ();
13661 main ()
13663 return TIFFGetVersion ();
13665 return 0;
13667 _ACEOF
13668 if ac_fn_c_try_link "$LINENO"; then :
13669 ac_cv_lib_tiff_TIFFGetVersion=yes
13670 else
13671 ac_cv_lib_tiff_TIFFGetVersion=no
13673 rm -f core conftest.err conftest.$ac_objext \
13674 conftest$ac_exeext conftest.$ac_ext
13675 LIBS=$ac_check_lib_save_LIBS
13677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13678 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13679 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13680 HAVE_TIFF=yes
13688 if test "${HAVE_TIFF}" = "yes"; then
13690 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13692 LIBTIFF=-ltiff
13697 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13698 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
13699 HAVE_GIF=no
13700 LIBGIF=
13701 if test "${opsys}" = "mingw32"; then
13702 if test "${with_gif}" != "no"; then
13703 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13704 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13705 HAVE_GIF=yes
13706 else
13707 HAVE_GIF=no
13712 if test "${HAVE_GIF}" = "yes"; then
13714 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13717 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
13718 || test "${HAVE_W32}" = "yes"; then
13719 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13720 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13721 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13722 # Earlier versions can crash Emacs.
13723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13724 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13725 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13726 $as_echo_n "(cached) " >&6
13727 else
13728 ac_check_lib_save_LIBS=$LIBS
13729 LIBS="-lgif $LIBS"
13730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13731 /* end confdefs.h. */
13733 /* Override any GCC internal prototype to avoid an error.
13734 Use char because int might match the return type of a GCC
13735 builtin and then its argument prototype would still apply. */
13736 #ifdef __cplusplus
13737 extern "C"
13738 #endif
13739 char EGifPutExtensionLast ();
13741 main ()
13743 return EGifPutExtensionLast ();
13745 return 0;
13747 _ACEOF
13748 if ac_fn_c_try_link "$LINENO"; then :
13749 ac_cv_lib_gif_EGifPutExtensionLast=yes
13750 else
13751 ac_cv_lib_gif_EGifPutExtensionLast=no
13753 rm -f core conftest.err conftest.$ac_objext \
13754 conftest$ac_exeext conftest.$ac_ext
13755 LIBS=$ac_check_lib_save_LIBS
13757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13758 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13759 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13760 HAVE_GIF=yes
13761 else
13762 HAVE_GIF=maybe
13769 if test "$HAVE_GIF" = yes; then
13770 LIBGIF=-lgif
13771 elif test "$HAVE_GIF" = maybe; then
13772 # If gif_lib.h but no libgif, try libungif.
13773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13774 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13775 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13776 $as_echo_n "(cached) " >&6
13777 else
13778 ac_check_lib_save_LIBS=$LIBS
13779 LIBS="-lungif $LIBS"
13780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13781 /* end confdefs.h. */
13783 /* Override any GCC internal prototype to avoid an error.
13784 Use char because int might match the return type of a GCC
13785 builtin and then its argument prototype would still apply. */
13786 #ifdef __cplusplus
13787 extern "C"
13788 #endif
13789 char EGifPutExtensionLast ();
13791 main ()
13793 return EGifPutExtensionLast ();
13795 return 0;
13797 _ACEOF
13798 if ac_fn_c_try_link "$LINENO"; then :
13799 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13800 else
13801 ac_cv_lib_ungif_EGifPutExtensionLast=no
13803 rm -f core conftest.err conftest.$ac_objext \
13804 conftest$ac_exeext conftest.$ac_ext
13805 LIBS=$ac_check_lib_save_LIBS
13807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13808 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13809 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13810 HAVE_GIF=yes
13811 else
13812 HAVE_GIF=no
13815 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13818 if test "${HAVE_GIF}" = "yes"; then
13820 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13826 if test "${HAVE_X11}" = "yes"; then
13827 MISSING=""
13828 WITH_NO=""
13829 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13830 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13831 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13832 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13833 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13834 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13835 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13836 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13837 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13838 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13840 if test "X${MISSING}" != X; then
13841 as_fn_error "The following required libraries were not found:
13842 $MISSING
13843 Maybe some development libraries/packages are missing?
13844 If you don't want to link with them give
13845 $WITH_NO
13846 as options to configure" "$LINENO" 5
13850 ### Use -lgpm if available, unless `--with-gpm=no'.
13851 HAVE_GPM=no
13852 LIBGPM=
13853 if test "${with_gpm}" != "no"; then
13854 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13855 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13857 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13858 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13859 $as_echo_n "(cached) " >&6
13860 else
13861 ac_check_lib_save_LIBS=$LIBS
13862 LIBS="-lgpm $LIBS"
13863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13864 /* end confdefs.h. */
13866 /* Override any GCC internal prototype to avoid an error.
13867 Use char because int might match the return type of a GCC
13868 builtin and then its argument prototype would still apply. */
13869 #ifdef __cplusplus
13870 extern "C"
13871 #endif
13872 char Gpm_Open ();
13874 main ()
13876 return Gpm_Open ();
13878 return 0;
13880 _ACEOF
13881 if ac_fn_c_try_link "$LINENO"; then :
13882 ac_cv_lib_gpm_Gpm_Open=yes
13883 else
13884 ac_cv_lib_gpm_Gpm_Open=no
13886 rm -f core conftest.err conftest.$ac_objext \
13887 conftest$ac_exeext conftest.$ac_ext
13888 LIBS=$ac_check_lib_save_LIBS
13890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13891 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13892 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13893 HAVE_GPM=yes
13900 if test "${HAVE_GPM}" = "yes"; then
13902 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13904 LIBGPM=-lgpm
13913 GNUSTEP_CFLAGS=
13914 ### Use NeXTstep API to implement GUI.
13915 if test "${HAVE_NS}" = "yes"; then
13917 $as_echo "#define HAVE_NS 1" >>confdefs.h
13919 if test "${NS_IMPL_COCOA}" = "yes"; then
13921 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13924 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13926 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13928 # See also .m.o rule in Makefile.in */
13929 # FIXME: are all these flags really needed? Document here why. */
13930 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
13931 ## Extra CFLAGS applied to src/*.m files.
13932 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"
13934 # We also have mouse menus.
13935 HAVE_MENUS=yes
13936 OTHER_FILES=ns-app
13939 if test "${HAVE_W32}" = "yes"; then
13940 HAVE_MENUS=yes
13943 ### Use session management (-lSM -lICE) if available
13944 HAVE_X_SM=no
13945 LIBXSM=
13946 if test "${HAVE_X11}" = "yes"; then
13947 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13948 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13950 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13951 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13952 $as_echo_n "(cached) " >&6
13953 else
13954 ac_check_lib_save_LIBS=$LIBS
13955 LIBS="-lSM -lICE $LIBS"
13956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13957 /* end confdefs.h. */
13959 /* Override any GCC internal prototype to avoid an error.
13960 Use char because int might match the return type of a GCC
13961 builtin and then its argument prototype would still apply. */
13962 #ifdef __cplusplus
13963 extern "C"
13964 #endif
13965 char SmcOpenConnection ();
13967 main ()
13969 return SmcOpenConnection ();
13971 return 0;
13973 _ACEOF
13974 if ac_fn_c_try_link "$LINENO"; then :
13975 ac_cv_lib_SM_SmcOpenConnection=yes
13976 else
13977 ac_cv_lib_SM_SmcOpenConnection=no
13979 rm -f core conftest.err conftest.$ac_objext \
13980 conftest$ac_exeext conftest.$ac_ext
13981 LIBS=$ac_check_lib_save_LIBS
13983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13984 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13985 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13986 HAVE_X_SM=yes
13993 if test "${HAVE_X_SM}" = "yes"; then
13995 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13997 LIBXSM="-lSM -lICE"
13998 case "$LIBS" in
13999 *-lSM*) ;;
14000 *) LIBS="$LIBXSM $LIBS" ;;
14001 esac
14006 ### Use XRandr (-lXrandr) if available
14007 HAVE_XRANDR=no
14008 if test "${HAVE_X11}" = "yes"; then
14009 XRANDR_REQUIRED=1.2.2
14010 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14012 succeeded=no
14014 if test "$PKG_CONFIG" = "no" ; then
14015 HAVE_XRANDR=no
14016 else
14017 PKG_CONFIG_MIN_VERSION=0.9.0
14018 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14020 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14022 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14023 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14024 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14025 edit_cflags="
14026 s,///*,/,g
14027 s/^/ /
14028 s/ -I/ $isystem/g
14029 s/^ //
14031 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14032 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14034 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14035 succeeded=yes
14036 else
14037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14038 $as_echo "no" >&6; }
14039 XRANDR_CFLAGS=""
14040 XRANDR_LIBS=""
14041 ## If we have a custom action on failure, don't print errors, but
14042 ## do set a variable so people can do so. Do it in a subshell
14043 ## to capture any diagnostics in invoking pkg-config.
14044 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14050 else
14051 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14052 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14056 if test $succeeded = yes; then
14057 HAVE_XRANDR=yes
14058 else
14059 HAVE_XRANDR=no
14062 if test $HAVE_XRANDR = no; then
14063 # Test old way in case pkg-config doesn't have it (older machines).
14064 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14065 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14067 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14068 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14069 $as_echo_n "(cached) " >&6
14070 else
14071 ac_check_lib_save_LIBS=$LIBS
14072 LIBS="-lXrandr $LIBS"
14073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14074 /* end confdefs.h. */
14076 /* Override any GCC internal prototype to avoid an error.
14077 Use char because int might match the return type of a GCC
14078 builtin and then its argument prototype would still apply. */
14079 #ifdef __cplusplus
14080 extern "C"
14081 #endif
14082 char XRRGetScreenResources ();
14084 main ()
14086 return XRRGetScreenResources ();
14088 return 0;
14090 _ACEOF
14091 if ac_fn_c_try_link "$LINENO"; then :
14092 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14093 else
14094 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14096 rm -f core conftest.err conftest.$ac_objext \
14097 conftest$ac_exeext conftest.$ac_ext
14098 LIBS=$ac_check_lib_save_LIBS
14100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14101 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14102 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14103 HAVE_XRANDR=yes
14109 if test $HAVE_XRANDR = yes; then
14110 XRANDR_LIBS=-lXrandr
14114 if test $HAVE_XRANDR = yes; then
14115 SAVE_CFLAGS="$CFLAGS"
14116 SAVE_LIBS="$LIBS"
14117 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14118 LIBS="$XRANDR_LIBS $LIBS"
14119 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14120 do :
14121 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14122 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14123 eval as_val=\$$as_ac_var
14124 if test "x$as_val" = x""yes; then :
14125 cat >>confdefs.h <<_ACEOF
14126 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14127 _ACEOF
14130 done
14132 CFLAGS="$SAVE_CFLAGS"
14133 LIBS="$SAVE_LIBS"
14136 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14141 ### Use Xinerama (-lXinerama) if available
14142 HAVE_XINERAMA=no
14143 if test "${HAVE_X11}" = "yes"; then
14144 XINERAMA_REQUIRED=1.0.2
14145 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14147 succeeded=no
14149 if test "$PKG_CONFIG" = "no" ; then
14150 HAVE_XINERAMA=no
14151 else
14152 PKG_CONFIG_MIN_VERSION=0.9.0
14153 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14155 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14157 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14158 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14159 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14160 edit_cflags="
14161 s,///*,/,g
14162 s/^/ /
14163 s/ -I/ $isystem/g
14164 s/^ //
14166 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14167 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14169 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14170 succeeded=yes
14171 else
14172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14173 $as_echo "no" >&6; }
14174 XINERAMA_CFLAGS=""
14175 XINERAMA_LIBS=""
14176 ## If we have a custom action on failure, don't print errors, but
14177 ## do set a variable so people can do so. Do it in a subshell
14178 ## to capture any diagnostics in invoking pkg-config.
14179 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14185 else
14186 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14187 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14191 if test $succeeded = yes; then
14192 HAVE_XINERAMA=yes
14193 else
14194 HAVE_XINERAMA=no
14197 if test $HAVE_XINERAMA = no; then
14198 # Test old way in case pkg-config doesn't have it (older machines).
14199 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14200 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14202 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14203 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14204 $as_echo_n "(cached) " >&6
14205 else
14206 ac_check_lib_save_LIBS=$LIBS
14207 LIBS="-lXinerama $LIBS"
14208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14209 /* end confdefs.h. */
14211 /* Override any GCC internal prototype to avoid an error.
14212 Use char because int might match the return type of a GCC
14213 builtin and then its argument prototype would still apply. */
14214 #ifdef __cplusplus
14215 extern "C"
14216 #endif
14217 char XineramaQueryExtension ();
14219 main ()
14221 return XineramaQueryExtension ();
14223 return 0;
14225 _ACEOF
14226 if ac_fn_c_try_link "$LINENO"; then :
14227 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14228 else
14229 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14231 rm -f core conftest.err conftest.$ac_objext \
14232 conftest$ac_exeext conftest.$ac_ext
14233 LIBS=$ac_check_lib_save_LIBS
14235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14236 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14237 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14238 HAVE_XINERAMA=yes
14244 if test $HAVE_XINERAMA = yes; then
14245 XINERAMA_LIBS=-lXinerama
14249 if test $HAVE_XINERAMA = yes; then
14251 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14257 ### Use libxml (-lxml2) if available
14258 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14259 HAVE_LIBXML2=no
14260 if test "${with_xml2}" != "no"; then
14261 ### I'm not sure what the version number should be, so I just guessed.
14263 succeeded=no
14265 if test "$PKG_CONFIG" = "no" ; then
14266 HAVE_LIBXML2=no
14267 else
14268 PKG_CONFIG_MIN_VERSION=0.9.0
14269 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14271 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14273 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14274 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14275 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14276 edit_cflags="
14277 s,///*,/,g
14278 s/^/ /
14279 s/ -I/ $isystem/g
14280 s/^ //
14282 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14283 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14285 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14286 succeeded=yes
14287 else
14288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14289 $as_echo "no" >&6; }
14290 LIBXML2_CFLAGS=""
14291 LIBXML2_LIBS=""
14292 ## If we have a custom action on failure, don't print errors, but
14293 ## do set a variable so people can do so. Do it in a subshell
14294 ## to capture any diagnostics in invoking pkg-config.
14295 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14301 else
14302 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14303 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14307 if test $succeeded = yes; then
14308 HAVE_LIBXML2=yes
14309 else
14310 HAVE_LIBXML2=no
14313 # Built-in libxml2 on OS X 10.8 lacks libxml-2.0.pc.
14314 if test "${HAVE_LIBXML2}" != "yes" -a "$opsys" = "darwin"; then
14315 SAVE_CPPFLAGS="$CPPFLAGS"
14316 CPPFLAGS="$CPPFLAGS -I/usr/include/libxml2"
14317 ac_fn_c_check_header_mongrel "$LINENO" "libxml/HTMLparser.h" "ac_cv_header_libxml_HTMLparser_h" "$ac_includes_default"
14318 if test "x$ac_cv_header_libxml_HTMLparser_h" = x""yes; then :
14319 ac_fn_c_check_decl "$LINENO" "HTML_PARSE_RECOVER" "ac_cv_have_decl_HTML_PARSE_RECOVER" "#include <libxml/HTMLparser.h>
14321 if test "x$ac_cv_have_decl_HTML_PARSE_RECOVER" = x""yes; then :
14322 HAVE_LIBXML2=yes
14328 CPPFLAGS="$SAVE_CPPFLAGS"
14329 if test "${HAVE_LIBXML2}" = "yes"; then
14330 LIBXML2_LIBS="-lxml2"
14331 LIBXML2_CFLAGS="-I/usr/include/libxml2"
14334 if test "${HAVE_LIBXML2}" = "yes"; then
14335 if test "${opsys}" != "mingw32"; then
14336 LIBS="$LIBXML2_LIBS $LIBS"
14337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14338 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14339 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14340 $as_echo_n "(cached) " >&6
14341 else
14342 ac_check_lib_save_LIBS=$LIBS
14343 LIBS="-lxml2 $LIBS"
14344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14345 /* end confdefs.h. */
14347 /* Override any GCC internal prototype to avoid an error.
14348 Use char because int might match the return type of a GCC
14349 builtin and then its argument prototype would still apply. */
14350 #ifdef __cplusplus
14351 extern "C"
14352 #endif
14353 char htmlReadMemory ();
14355 main ()
14357 return htmlReadMemory ();
14359 return 0;
14361 _ACEOF
14362 if ac_fn_c_try_link "$LINENO"; then :
14363 ac_cv_lib_xml2_htmlReadMemory=yes
14364 else
14365 ac_cv_lib_xml2_htmlReadMemory=no
14367 rm -f core conftest.err conftest.$ac_objext \
14368 conftest$ac_exeext conftest.$ac_ext
14369 LIBS=$ac_check_lib_save_LIBS
14371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14372 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14373 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14374 HAVE_LIBXML2=yes
14375 else
14376 HAVE_LIBXML2=no
14379 else
14380 LIBXML2_LIBS=""
14382 if test "${HAVE_LIBXML2}" = "yes"; then
14384 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14386 else
14387 LIBXML2_LIBS=""
14388 LIBXML2_CFLAGS=""
14395 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14396 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14397 if test "${opsys}" = "mingw32"; then
14398 emacs_cv_netdb_declares_h_errno=yes
14400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14401 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14402 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14403 $as_echo_n "(cached) " >&6
14404 else
14405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14406 /* end confdefs.h. */
14407 #include <netdb.h>
14409 main ()
14411 return h_errno;
14413 return 0;
14415 _ACEOF
14416 if ac_fn_c_try_link "$LINENO"; then :
14417 emacs_cv_netdb_declares_h_errno=yes
14418 else
14419 emacs_cv_netdb_declares_h_errno=no
14421 rm -f core conftest.err conftest.$ac_objext \
14422 conftest$ac_exeext conftest.$ac_ext
14424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14425 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14426 if test $emacs_cv_netdb_declares_h_errno = yes; then
14428 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14432 # sqrt and other floating-point functions such as fmod and frexp
14433 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14434 if test "${opsys}" != "mingw32"; then
14435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14436 $as_echo_n "checking for sqrt in -lm... " >&6; }
14437 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14438 $as_echo_n "(cached) " >&6
14439 else
14440 ac_check_lib_save_LIBS=$LIBS
14441 LIBS="-lm $LIBS"
14442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14443 /* end confdefs.h. */
14445 /* Override any GCC internal prototype to avoid an error.
14446 Use char because int might match the return type of a GCC
14447 builtin and then its argument prototype would still apply. */
14448 #ifdef __cplusplus
14449 extern "C"
14450 #endif
14451 char sqrt ();
14453 main ()
14455 return sqrt ();
14457 return 0;
14459 _ACEOF
14460 if ac_fn_c_try_link "$LINENO"; then :
14461 ac_cv_lib_m_sqrt=yes
14462 else
14463 ac_cv_lib_m_sqrt=no
14465 rm -f core conftest.err conftest.$ac_objext \
14466 conftest$ac_exeext conftest.$ac_ext
14467 LIBS=$ac_check_lib_save_LIBS
14469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14470 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14471 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14472 cat >>confdefs.h <<_ACEOF
14473 #define HAVE_LIBM 1
14474 _ACEOF
14476 LIBS="-lm $LIBS"
14482 # Check for mail-locking functions in a "mail" library. Probably this should
14483 # have the same check as for liblockfile below.
14484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14485 $as_echo_n "checking for maillock in -lmail... " >&6; }
14486 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14487 $as_echo_n "(cached) " >&6
14488 else
14489 ac_check_lib_save_LIBS=$LIBS
14490 LIBS="-lmail $LIBS"
14491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14492 /* end confdefs.h. */
14494 /* Override any GCC internal prototype to avoid an error.
14495 Use char because int might match the return type of a GCC
14496 builtin and then its argument prototype would still apply. */
14497 #ifdef __cplusplus
14498 extern "C"
14499 #endif
14500 char maillock ();
14502 main ()
14504 return maillock ();
14506 return 0;
14508 _ACEOF
14509 if ac_fn_c_try_link "$LINENO"; then :
14510 ac_cv_lib_mail_maillock=yes
14511 else
14512 ac_cv_lib_mail_maillock=no
14514 rm -f core conftest.err conftest.$ac_objext \
14515 conftest$ac_exeext conftest.$ac_ext
14516 LIBS=$ac_check_lib_save_LIBS
14518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14519 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14520 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14521 have_mail=yes
14522 else
14523 have_mail=no
14526 if test $have_mail = yes; then
14527 LIBS_MAIL=-lmail
14528 LIBS="$LIBS_MAIL $LIBS"
14530 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14532 else
14533 LIBS_MAIL=
14535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14536 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14537 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14538 $as_echo_n "(cached) " >&6
14539 else
14540 ac_check_lib_save_LIBS=$LIBS
14541 LIBS="-llockfile $LIBS"
14542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14543 /* end confdefs.h. */
14545 /* Override any GCC internal prototype to avoid an error.
14546 Use char because int might match the return type of a GCC
14547 builtin and then its argument prototype would still apply. */
14548 #ifdef __cplusplus
14549 extern "C"
14550 #endif
14551 char maillock ();
14553 main ()
14555 return maillock ();
14557 return 0;
14559 _ACEOF
14560 if ac_fn_c_try_link "$LINENO"; then :
14561 ac_cv_lib_lockfile_maillock=yes
14562 else
14563 ac_cv_lib_lockfile_maillock=no
14565 rm -f core conftest.err conftest.$ac_objext \
14566 conftest$ac_exeext conftest.$ac_ext
14567 LIBS=$ac_check_lib_save_LIBS
14569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
14570 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
14571 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
14572 have_lockfile=yes
14573 else
14574 have_lockfile=no
14577 if test $have_lockfile = yes; then
14578 LIBS_MAIL=-llockfile
14579 LIBS="$LIBS_MAIL $LIBS"
14581 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
14583 else
14584 # If we have the shared liblockfile, assume we must use it for mail
14585 # locking (e.g. Debian). If we couldn't link against liblockfile
14586 # (no liblockfile.a installed), ensure that we don't need to.
14587 # Extract the first word of "liblockfile.so", so it can be a program name with args.
14588 set dummy liblockfile.so; ac_word=$2
14589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14590 $as_echo_n "checking for $ac_word... " >&6; }
14591 if test "${ac_cv_prog_liblockfile+set}" = set; then :
14592 $as_echo_n "(cached) " >&6
14593 else
14594 if test -n "$liblockfile"; then
14595 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
14596 else
14597 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14598 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
14599 for as_dir in $as_dummy
14601 IFS=$as_save_IFS
14602 test -z "$as_dir" && as_dir=.
14603 for ac_exec_ext in '' $ac_executable_extensions; do
14604 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14605 ac_cv_prog_liblockfile="yes"
14606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14607 break 2
14609 done
14610 done
14611 IFS=$as_save_IFS
14613 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
14616 liblockfile=$ac_cv_prog_liblockfile
14617 if test -n "$liblockfile"; then
14618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
14619 $as_echo "$liblockfile" >&6; }
14620 else
14621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14622 $as_echo "no" >&6; }
14626 if test $ac_cv_prog_liblockfile = yes; then
14627 as_fn_error "Shared liblockfile found but can't link against it.
14628 This probably means that movemail could lose mail.
14629 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
14637 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
14638 ## interlock access to the mail spool. The alternative is a lock file named
14639 ## /usr/spool/mail/$USER.lock.
14640 mail_lock=no
14641 case "$opsys" in
14642 aix4-2) mail_lock="lockf" ;;
14644 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
14646 ## On GNU/Linux systems, both methods are used by various mail programs.
14647 ## I assume most people are using newer mailers that have heard of flock.
14648 ## Change this if you need to.
14649 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
14650 ## configure gets the right answers, and that means *NOT* using flock.
14651 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
14652 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
14653 ## Debian maintainer hasn't provided a clean fix for Emacs.
14654 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
14655 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
14656 ## correct logic. -- fx
14657 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
14658 ## liblockfile is a Free Software replacement for libmail, used on
14659 ## Debian systems and elsewhere. -rfr.
14660 gnu-*)
14661 mail_lock="flock"
14662 if test $have_mail = yes || test $have_lockfile = yes; then
14663 test $ac_cv_header_maillock_h = yes && mail_lock=no
14667 mingw32)
14668 mail_lock="none-needed" ;;
14669 esac
14671 BLESSMAIL_TARGET=
14672 case "$mail_lock" in
14673 flock)
14674 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
14677 lockf)
14678 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
14681 none-needed) ;;
14683 *) BLESSMAIL_TARGET="need-blessmail" ;;
14684 esac
14688 for ac_func in accept4 gethostname \
14689 getrusage get_current_dir_name \
14690 lrand48 \
14691 select getpagesize setlocale \
14692 getrlimit setrlimit shutdown getaddrinfo \
14693 strsignal setitimer \
14694 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
14695 gai_strerror mkostemp mkstemp getline getdelim sync \
14696 difftime posix_memalign \
14697 getpwent endpwent getgrent endgrent \
14698 touchlock \
14699 cfmakeraw cfsetspeed copysign __executable_start log2
14700 do :
14701 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14702 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14703 eval as_val=\$$as_ac_var
14704 if test "x$as_val" = x""yes; then :
14705 cat >>confdefs.h <<_ACEOF
14706 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14707 _ACEOF
14710 done
14713 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
14714 ## has a broken `rint' in some library versions including math library
14715 ## version number A.09.05.
14716 ## You can fix the math library by installing patch number PHSS_4630.
14717 ## But we can fix it more reliably for Emacs by just not using rint.
14718 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
14719 case $opsys in
14720 hpux*) : ;;
14721 *) for ac_func in random rint
14722 do :
14723 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14724 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14725 eval as_val=\$$as_ac_var
14726 if test "x$as_val" = x""yes; then :
14727 cat >>confdefs.h <<_ACEOF
14728 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14729 _ACEOF
14732 done
14734 esac
14736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
14737 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
14738 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
14739 $as_echo_n "(cached) " >&6
14740 else
14741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14742 /* end confdefs.h. */
14745 main ()
14747 __builtin_unwind_init ();
14749 return 0;
14751 _ACEOF
14752 if ac_fn_c_try_link "$LINENO"; then :
14753 emacs_cv_func___builtin_unwind_init=yes
14754 else
14755 emacs_cv_func___builtin_unwind_init=no
14757 rm -f core conftest.err conftest.$ac_objext \
14758 conftest$ac_exeext conftest.$ac_ext
14760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
14761 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
14762 if test $emacs_cv_func___builtin_unwind_init = yes; then
14764 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
14772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14773 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
14774 if test "${ac_cv_sys_largefile_source+set}" = set; then :
14775 $as_echo_n "(cached) " >&6
14776 else
14777 while :; do
14778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14779 /* end confdefs.h. */
14780 #include <sys/types.h> /* for off_t */
14781 #include <stdio.h>
14783 main ()
14785 int (*fp) (FILE *, off_t, int) = fseeko;
14786 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14788 return 0;
14790 _ACEOF
14791 if ac_fn_c_try_link "$LINENO"; then :
14792 ac_cv_sys_largefile_source=no; break
14794 rm -f core conftest.err conftest.$ac_objext \
14795 conftest$ac_exeext conftest.$ac_ext
14796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14797 /* end confdefs.h. */
14798 #define _LARGEFILE_SOURCE 1
14799 #include <sys/types.h> /* for off_t */
14800 #include <stdio.h>
14802 main ()
14804 int (*fp) (FILE *, off_t, int) = fseeko;
14805 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14807 return 0;
14809 _ACEOF
14810 if ac_fn_c_try_link "$LINENO"; then :
14811 ac_cv_sys_largefile_source=1; break
14813 rm -f core conftest.err conftest.$ac_objext \
14814 conftest$ac_exeext conftest.$ac_ext
14815 ac_cv_sys_largefile_source=unknown
14816 break
14817 done
14819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14820 $as_echo "$ac_cv_sys_largefile_source" >&6; }
14821 case $ac_cv_sys_largefile_source in #(
14822 no | unknown) ;;
14824 cat >>confdefs.h <<_ACEOF
14825 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14826 _ACEOF
14828 esac
14829 rm -rf conftest*
14831 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14832 # in glibc 2.1.3, but that breaks too many other things.
14833 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14834 if test $ac_cv_sys_largefile_source != unknown; then
14836 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14841 # UNIX98 PTYs.
14842 for ac_func in grantpt
14843 do :
14844 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
14845 if test "x$ac_cv_func_grantpt" = x""yes; then :
14846 cat >>confdefs.h <<_ACEOF
14847 #define HAVE_GRANTPT 1
14848 _ACEOF
14851 done
14854 # PTY-related GNU extensions.
14855 for ac_func in getpt posix_openpt
14856 do :
14857 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14858 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14859 eval as_val=\$$as_ac_var
14860 if test "x$as_val" = x""yes; then :
14861 cat >>confdefs.h <<_ACEOF
14862 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14863 _ACEOF
14866 done
14869 # Check this now, so that we will NOT find the above functions in ncurses.
14870 # That is because we have not set up to link ncurses in lib-src.
14871 # It's better to believe a function is not available
14872 # than to expect to find it in ncurses.
14873 # Also we need tputs and friends to be able to build at all.
14874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
14875 $as_echo_n "checking for library containing tputs... " >&6; }
14876 # Run a test program that contains a call to tputs, a call that is
14877 # never executed. This tests whether a pre-'main' dynamic linker
14878 # works with the library. It's too much trouble to actually call
14879 # tputs in the test program, due to portability hassles. When
14880 # cross-compiling, assume the test program will run if it links.
14882 if test "${opsys}" = "mingw32"; then
14883 msg='none required'
14884 else
14885 # Maybe curses should be tried earlier?
14886 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
14887 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
14888 OLIBS=$LIBS
14889 if test -z "$tputs_library"; then
14890 LIBS_TERMCAP=
14891 msg='none required'
14892 else
14893 LIBS_TERMCAP=-l$tputs_library
14894 msg=$LIBS_TERMCAP
14895 LIBS="$LIBS_TERMCAP $LIBS"
14897 if test "$cross_compiling" = yes; then :
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_link "$LINENO"; then :
14912 else
14913 msg=no
14915 rm -f core conftest.err conftest.$ac_objext \
14916 conftest$ac_exeext conftest.$ac_ext
14917 else
14918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14919 /* end confdefs.h. */
14921 extern void tputs (const char *, int, int (*)(int));
14922 int main (int argc, char **argv)
14924 if (argc == 10000)
14925 tputs (argv[0], 0, 0);
14926 return 0;
14929 _ACEOF
14930 if ac_fn_c_try_run "$LINENO"; then :
14932 else
14933 msg=no
14935 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14936 conftest.$ac_objext conftest.beam conftest.$ac_ext
14939 LIBS=$OLIBS
14940 if test "X$msg" != Xno; then
14941 break
14943 done
14945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
14946 $as_echo "$msg" >&6; }
14947 if test "X$msg" = Xno; then
14948 as_fn_error "The required function \`tputs' was not found in any library.
14949 The following libraries were tried (in order):
14950 libtinfo, libncurses, libterminfo, libtermcap, libcurses
14951 Please try installing whichever of these libraries is most appropriate
14952 for your system, together with its header files.
14953 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
14956 ## Use termcap instead of terminfo?
14957 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
14958 TERMINFO=yes
14959 ## FIXME? In the cases below where we unconditionally set
14960 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
14961 ## if that was found above to have tputs.
14962 ## Should we use the gnu* logic everywhere?
14963 case "$opsys" in
14964 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
14965 ## The ncurses library has been moved out of the System framework in
14966 ## Mac OS X 10.2. So if configure detects it, set the command-line
14967 ## option to use it.
14968 darwin) LIBS_TERMCAP="-lncurses" ;;
14970 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
14972 freebsd)
14973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
14974 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
14975 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
14976 $as_echo_n "(cached) " >&6
14977 else
14978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14979 /* end confdefs.h. */
14980 #include <osreldate.h>
14982 main ()
14984 #if __FreeBSD_version < 400000
14985 fail;
14986 #endif
14989 return 0;
14991 _ACEOF
14992 if ac_fn_c_try_link "$LINENO"; then :
14993 emacs_cv_freebsd_terminfo=yes
14994 else
14995 emacs_cv_freebsd_terminfo=no
14997 rm -f core conftest.err conftest.$ac_objext \
14998 conftest$ac_exeext conftest.$ac_ext
15002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
15003 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
15005 if test $emacs_cv_freebsd_terminfo = yes; then
15006 LIBS_TERMCAP="-lncurses"
15007 else
15008 TERMINFO=no
15009 LIBS_TERMCAP="-ltermcap"
15013 mingw32)
15014 TERMINFO=no
15015 LIBS_TERMCAP=
15018 netbsd)
15019 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15020 TERMINFO=no
15021 LIBS_TERMCAP="-ltermcap"
15025 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15027 ## hpux: Make sure we get select from libc rather than from libcurses
15028 ## because libcurses on HPUX 10.10 has a broken version of select.
15029 ## We used to use -lc -lcurses, but this may be cleaner.
15030 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15031 # set that way, now it uses the default). Isn't this a contradiction?
15032 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15034 esac
15036 TERMCAP_OBJ=tparam.o
15037 if test $TERMINFO = yes; then
15039 $as_echo "#define TERMINFO 1" >>confdefs.h
15041 TERMCAP_OBJ=terminfo.o
15043 if test "X$LIBS_TERMCAP" = "X-lncurses"; then
15045 $as_echo "#define USE_NCURSES 1" >>confdefs.h
15052 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15053 # On Darwin, res_init appears not to be useful: see bug#562 and
15054 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15055 resolv=no
15057 if test $opsys != darwin; then
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 if test "$have_res_init" = no; then
15080 OLIBS="$LIBS"
15081 LIBS="$LIBS -lresolv"
15082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15083 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15085 /* end confdefs.h. */
15086 #include <netinet/in.h>
15087 #include <arpa/nameser.h>
15088 #include <resolv.h>
15090 main ()
15092 return res_init();
15094 return 0;
15096 _ACEOF
15097 if ac_fn_c_try_link "$LINENO"; then :
15098 have_res_init=yes
15099 else
15100 have_res_init=no
15102 rm -f core conftest.err conftest.$ac_objext \
15103 conftest$ac_exeext conftest.$ac_ext
15104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15105 $as_echo "$have_res_init" >&6; }
15106 if test "$have_res_init" = yes ; then
15107 resolv=yes
15109 LIBS="$OLIBS"
15112 if test "$have_res_init" = yes; then
15114 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15118 # Do we need the Hesiod library to provide the support routines?
15119 LIBHESIOD=
15120 if test "$with_hesiod" != no ; then
15121 # Don't set $LIBS here -- see comments above. FIXME which comments?
15122 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15123 if test "x$ac_cv_func_res_send" = x""yes; then :
15125 else
15126 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15127 if test "x$ac_cv_func___res_send" = x""yes; then :
15129 else
15130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15131 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15132 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15133 $as_echo_n "(cached) " >&6
15134 else
15135 ac_check_lib_save_LIBS=$LIBS
15136 LIBS="-lresolv $LIBS"
15137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15138 /* end confdefs.h. */
15140 /* Override any GCC internal prototype to avoid an error.
15141 Use char because int might match the return type of a GCC
15142 builtin and then its argument prototype would still apply. */
15143 #ifdef __cplusplus
15144 extern "C"
15145 #endif
15146 char res_send ();
15148 main ()
15150 return res_send ();
15152 return 0;
15154 _ACEOF
15155 if ac_fn_c_try_link "$LINENO"; then :
15156 ac_cv_lib_resolv_res_send=yes
15157 else
15158 ac_cv_lib_resolv_res_send=no
15160 rm -f core conftest.err conftest.$ac_objext \
15161 conftest$ac_exeext conftest.$ac_ext
15162 LIBS=$ac_check_lib_save_LIBS
15164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15165 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15166 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15167 resolv=yes
15168 else
15169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15170 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15171 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15172 $as_echo_n "(cached) " >&6
15173 else
15174 ac_check_lib_save_LIBS=$LIBS
15175 LIBS="-lresolv $LIBS"
15176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15177 /* end confdefs.h. */
15179 /* Override any GCC internal prototype to avoid an error.
15180 Use char because int might match the return type of a GCC
15181 builtin and then its argument prototype would still apply. */
15182 #ifdef __cplusplus
15183 extern "C"
15184 #endif
15185 char __res_send ();
15187 main ()
15189 return __res_send ();
15191 return 0;
15193 _ACEOF
15194 if ac_fn_c_try_link "$LINENO"; then :
15195 ac_cv_lib_resolv___res_send=yes
15196 else
15197 ac_cv_lib_resolv___res_send=no
15199 rm -f core conftest.err conftest.$ac_objext \
15200 conftest$ac_exeext conftest.$ac_ext
15201 LIBS=$ac_check_lib_save_LIBS
15203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15204 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15205 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15206 resolv=yes
15215 if test "$resolv" = yes ; then
15216 RESOLVLIB=-lresolv
15217 else
15218 RESOLVLIB=
15220 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15221 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15223 else
15224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15225 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15226 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15227 $as_echo_n "(cached) " >&6
15228 else
15229 ac_check_lib_save_LIBS=$LIBS
15230 LIBS="-lhesiod $RESOLVLIB $LIBS"
15231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15232 /* end confdefs.h. */
15234 /* Override any GCC internal prototype to avoid an error.
15235 Use char because int might match the return type of a GCC
15236 builtin and then its argument prototype would still apply. */
15237 #ifdef __cplusplus
15238 extern "C"
15239 #endif
15240 char hes_getmailhost ();
15242 main ()
15244 return hes_getmailhost ();
15246 return 0;
15248 _ACEOF
15249 if ac_fn_c_try_link "$LINENO"; then :
15250 ac_cv_lib_hesiod_hes_getmailhost=yes
15251 else
15252 ac_cv_lib_hesiod_hes_getmailhost=no
15254 rm -f core conftest.err conftest.$ac_objext \
15255 conftest$ac_exeext conftest.$ac_ext
15256 LIBS=$ac_check_lib_save_LIBS
15258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15259 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15260 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15261 hesiod=yes
15262 else
15269 if test x"$hesiod" = xyes; then
15270 LIBHESIOD=-lhesiod
15275 # Do we need libresolv (due to res_init or Hesiod)?
15276 if test "$resolv" = yes && test $opsys != darwin; then
15277 LIBRESOLV=-lresolv
15278 else
15279 LIBRESOLV=
15283 # These tell us which Kerberos-related libraries to use.
15284 COM_ERRLIB=
15285 CRYPTOLIB=
15286 KRB5LIB=
15287 DESLIB=
15288 KRB4LIB=
15290 if test "${with_kerberos}" != no; then
15291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15292 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15293 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15294 $as_echo_n "(cached) " >&6
15295 else
15296 ac_check_lib_save_LIBS=$LIBS
15297 LIBS="-lcom_err $LIBS"
15298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15299 /* end confdefs.h. */
15301 /* Override any GCC internal prototype to avoid an error.
15302 Use char because int might match the return type of a GCC
15303 builtin and then its argument prototype would still apply. */
15304 #ifdef __cplusplus
15305 extern "C"
15306 #endif
15307 char com_err ();
15309 main ()
15311 return com_err ();
15313 return 0;
15315 _ACEOF
15316 if ac_fn_c_try_link "$LINENO"; then :
15317 ac_cv_lib_com_err_com_err=yes
15318 else
15319 ac_cv_lib_com_err_com_err=no
15321 rm -f core conftest.err conftest.$ac_objext \
15322 conftest$ac_exeext conftest.$ac_ext
15323 LIBS=$ac_check_lib_save_LIBS
15325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15326 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15327 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15328 have_com_err=yes
15329 else
15330 have_com_err=no
15333 if test $have_com_err = yes; then
15334 COM_ERRLIB=-lcom_err
15335 LIBS="$COM_ERRLIB $LIBS"
15337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15338 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15339 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15340 $as_echo_n "(cached) " >&6
15341 else
15342 ac_check_lib_save_LIBS=$LIBS
15343 LIBS="-lcrypto $LIBS"
15344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15345 /* end confdefs.h. */
15347 /* Override any GCC internal prototype to avoid an error.
15348 Use char because int might match the return type of a GCC
15349 builtin and then its argument prototype would still apply. */
15350 #ifdef __cplusplus
15351 extern "C"
15352 #endif
15353 char mit_des_cbc_encrypt ();
15355 main ()
15357 return mit_des_cbc_encrypt ();
15359 return 0;
15361 _ACEOF
15362 if ac_fn_c_try_link "$LINENO"; then :
15363 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15364 else
15365 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15367 rm -f core conftest.err conftest.$ac_objext \
15368 conftest$ac_exeext conftest.$ac_ext
15369 LIBS=$ac_check_lib_save_LIBS
15371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15372 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15373 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15374 have_crypto=yes
15375 else
15376 have_crypto=no
15379 if test $have_crypto = yes; then
15380 CRYPTOLIB=-lcrypto
15381 LIBS="$CRYPTOLIB $LIBS"
15383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15384 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15385 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15386 $as_echo_n "(cached) " >&6
15387 else
15388 ac_check_lib_save_LIBS=$LIBS
15389 LIBS="-lk5crypto $LIBS"
15390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15391 /* end confdefs.h. */
15393 /* Override any GCC internal prototype to avoid an error.
15394 Use char because int might match the return type of a GCC
15395 builtin and then its argument prototype would still apply. */
15396 #ifdef __cplusplus
15397 extern "C"
15398 #endif
15399 char mit_des_cbc_encrypt ();
15401 main ()
15403 return mit_des_cbc_encrypt ();
15405 return 0;
15407 _ACEOF
15408 if ac_fn_c_try_link "$LINENO"; then :
15409 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15410 else
15411 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15413 rm -f core conftest.err conftest.$ac_objext \
15414 conftest$ac_exeext conftest.$ac_ext
15415 LIBS=$ac_check_lib_save_LIBS
15417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15418 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15419 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15420 have_k5crypto=yes
15421 else
15422 have_k5crypto=no
15425 if test $have_k5crypto = yes; then
15426 CRYPTOLIB=-lk5crypto
15427 LIBS="$CRYPTOLIB $LIBS"
15429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15430 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15431 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15432 $as_echo_n "(cached) " >&6
15433 else
15434 ac_check_lib_save_LIBS=$LIBS
15435 LIBS="-lkrb5 $LIBS"
15436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15437 /* end confdefs.h. */
15439 /* Override any GCC internal prototype to avoid an error.
15440 Use char because int might match the return type of a GCC
15441 builtin and then its argument prototype would still apply. */
15442 #ifdef __cplusplus
15443 extern "C"
15444 #endif
15445 char krb5_init_context ();
15447 main ()
15449 return krb5_init_context ();
15451 return 0;
15453 _ACEOF
15454 if ac_fn_c_try_link "$LINENO"; then :
15455 ac_cv_lib_krb5_krb5_init_context=yes
15456 else
15457 ac_cv_lib_krb5_krb5_init_context=no
15459 rm -f core conftest.err conftest.$ac_objext \
15460 conftest$ac_exeext conftest.$ac_ext
15461 LIBS=$ac_check_lib_save_LIBS
15463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15464 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15465 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15466 have_krb5=yes
15467 else
15468 have_krb5=no
15471 if test $have_krb5=yes; then
15472 KRB5LIB=-lkrb5
15473 LIBS="$KRB5LIB $LIBS"
15475 if test "${with_kerberos5}" = no; then
15476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15477 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15478 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15479 $as_echo_n "(cached) " >&6
15480 else
15481 ac_check_lib_save_LIBS=$LIBS
15482 LIBS="-ldes425 $LIBS"
15483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15484 /* end confdefs.h. */
15486 /* Override any GCC internal prototype to avoid an error.
15487 Use char because int might match the return type of a GCC
15488 builtin and then its argument prototype would still apply. */
15489 #ifdef __cplusplus
15490 extern "C"
15491 #endif
15492 char des_cbc_encrypt ();
15494 main ()
15496 return des_cbc_encrypt ();
15498 return 0;
15500 _ACEOF
15501 if ac_fn_c_try_link "$LINENO"; then :
15502 ac_cv_lib_des425_des_cbc_encrypt=yes
15503 else
15504 ac_cv_lib_des425_des_cbc_encrypt=no
15506 rm -f core conftest.err conftest.$ac_objext \
15507 conftest$ac_exeext conftest.$ac_ext
15508 LIBS=$ac_check_lib_save_LIBS
15510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15511 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15512 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15513 have_des425=yes
15514 else
15515 have_des425=no
15518 if test $have_des425 = yes; then
15519 DESLIB=-ldes425
15520 LIBS="$DESLIB $LIBS"
15521 else
15522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15523 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15524 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15525 $as_echo_n "(cached) " >&6
15526 else
15527 ac_check_lib_save_LIBS=$LIBS
15528 LIBS="-ldes $LIBS"
15529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15530 /* end confdefs.h. */
15532 /* Override any GCC internal prototype to avoid an error.
15533 Use char because int might match the return type of a GCC
15534 builtin and then its argument prototype would still apply. */
15535 #ifdef __cplusplus
15536 extern "C"
15537 #endif
15538 char des_cbc_encrypt ();
15540 main ()
15542 return des_cbc_encrypt ();
15544 return 0;
15546 _ACEOF
15547 if ac_fn_c_try_link "$LINENO"; then :
15548 ac_cv_lib_des_des_cbc_encrypt=yes
15549 else
15550 ac_cv_lib_des_des_cbc_encrypt=no
15552 rm -f core conftest.err conftest.$ac_objext \
15553 conftest$ac_exeext conftest.$ac_ext
15554 LIBS=$ac_check_lib_save_LIBS
15556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
15557 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
15558 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
15559 have_des=yes
15560 else
15561 have_des=no
15564 if test $have_des = yes; then
15565 DESLIB=-ldes
15566 LIBS="$DESLIB $LIBS"
15569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
15570 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
15571 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
15572 $as_echo_n "(cached) " >&6
15573 else
15574 ac_check_lib_save_LIBS=$LIBS
15575 LIBS="-lkrb4 $LIBS"
15576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15577 /* end confdefs.h. */
15579 /* Override any GCC internal prototype to avoid an error.
15580 Use char because int might match the return type of a GCC
15581 builtin and then its argument prototype would still apply. */
15582 #ifdef __cplusplus
15583 extern "C"
15584 #endif
15585 char krb_get_cred ();
15587 main ()
15589 return krb_get_cred ();
15591 return 0;
15593 _ACEOF
15594 if ac_fn_c_try_link "$LINENO"; then :
15595 ac_cv_lib_krb4_krb_get_cred=yes
15596 else
15597 ac_cv_lib_krb4_krb_get_cred=no
15599 rm -f core conftest.err conftest.$ac_objext \
15600 conftest$ac_exeext conftest.$ac_ext
15601 LIBS=$ac_check_lib_save_LIBS
15603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
15604 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
15605 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
15606 have_krb4=yes
15607 else
15608 have_krb4=no
15611 if test $have_krb4 = yes; then
15612 KRB4LIB=-lkrb4
15613 LIBS="$KRB4LIB $LIBS"
15614 else
15615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
15616 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
15617 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
15618 $as_echo_n "(cached) " >&6
15619 else
15620 ac_check_lib_save_LIBS=$LIBS
15621 LIBS="-lkrb $LIBS"
15622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15623 /* end confdefs.h. */
15625 /* Override any GCC internal prototype to avoid an error.
15626 Use char because int might match the return type of a GCC
15627 builtin and then its argument prototype would still apply. */
15628 #ifdef __cplusplus
15629 extern "C"
15630 #endif
15631 char krb_get_cred ();
15633 main ()
15635 return krb_get_cred ();
15637 return 0;
15639 _ACEOF
15640 if ac_fn_c_try_link "$LINENO"; then :
15641 ac_cv_lib_krb_krb_get_cred=yes
15642 else
15643 ac_cv_lib_krb_krb_get_cred=no
15645 rm -f core conftest.err conftest.$ac_objext \
15646 conftest$ac_exeext conftest.$ac_ext
15647 LIBS=$ac_check_lib_save_LIBS
15649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
15650 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
15651 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
15652 have_krb=yes
15653 else
15654 have_krb=no
15657 if test $have_krb = yes; then
15658 KRB4LIB=-lkrb
15659 LIBS="$KRB4LIB $LIBS"
15664 if test "${with_kerberos5}" != no; then
15665 for ac_header in krb5.h
15666 do :
15667 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
15668 if test "x$ac_cv_header_krb5_h" = x""yes; then :
15669 cat >>confdefs.h <<_ACEOF
15670 #define HAVE_KRB5_H 1
15671 _ACEOF
15672 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
15674 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
15676 cat >>confdefs.h <<_ACEOF
15677 #define HAVE_KRB5_ERROR_TEXT 1
15678 _ACEOF
15682 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
15684 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
15686 cat >>confdefs.h <<_ACEOF
15687 #define HAVE_KRB5_ERROR_E_TEXT 1
15688 _ACEOF
15695 done
15697 else
15698 for ac_header in krb.h
15699 do :
15700 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
15701 if test "x$ac_cv_header_krb_h" = x""yes; then :
15702 cat >>confdefs.h <<_ACEOF
15703 #define HAVE_KRB_H 1
15704 _ACEOF
15706 else
15707 for ac_header in kerberosIV/krb.h
15708 do :
15709 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
15710 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
15711 cat >>confdefs.h <<_ACEOF
15712 #define HAVE_KERBEROSIV_KRB_H 1
15713 _ACEOF
15715 else
15716 for ac_header in kerberos/krb.h
15717 do :
15718 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
15719 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
15720 cat >>confdefs.h <<_ACEOF
15721 #define HAVE_KERBEROS_KRB_H 1
15722 _ACEOF
15726 done
15730 done
15734 done
15737 for ac_header in com_err.h
15738 do :
15739 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
15740 if test "x$ac_cv_header_com_err_h" = x""yes; then :
15741 cat >>confdefs.h <<_ACEOF
15742 #define HAVE_COM_ERR_H 1
15743 _ACEOF
15747 done
15760 for ac_func in $ac_func_list
15761 do :
15762 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15763 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15764 eval as_val=\$$as_ac_var
15765 if test "x$as_val" = x""yes; then :
15766 cat >>confdefs.h <<_ACEOF
15767 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15768 _ACEOF
15771 done
15776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
15777 $as_echo_n "checking whether localtime caches TZ... " >&6; }
15778 if test "${emacs_cv_localtime_cache+set}" = set; then :
15779 $as_echo_n "(cached) " >&6
15780 else
15781 if test x$ac_cv_func_tzset = xyes; then
15782 if test "$cross_compiling" = yes; then :
15783 # If we have tzset, assume the worst when cross-compiling.
15784 emacs_cv_localtime_cache=yes
15785 else
15786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15787 /* end confdefs.h. */
15788 #include <time.h>
15789 char TZ_GMT0[] = "TZ=GMT0";
15790 char TZ_PST8[] = "TZ=PST8";
15791 main()
15793 time_t now = time ((time_t *) 0);
15794 int hour_GMT0, hour_unset;
15795 if (putenv (TZ_GMT0) != 0)
15796 exit (1);
15797 hour_GMT0 = localtime (&now)->tm_hour;
15798 unsetenv("TZ");
15799 hour_unset = localtime (&now)->tm_hour;
15800 if (putenv (TZ_PST8) != 0)
15801 exit (1);
15802 if (localtime (&now)->tm_hour == hour_GMT0)
15803 exit (1);
15804 unsetenv("TZ");
15805 if (localtime (&now)->tm_hour != hour_unset)
15806 exit (1);
15807 exit (0);
15809 _ACEOF
15810 if ac_fn_c_try_run "$LINENO"; then :
15811 emacs_cv_localtime_cache=no
15812 else
15813 emacs_cv_localtime_cache=yes
15815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15816 conftest.$ac_objext conftest.beam conftest.$ac_ext
15819 else
15820 # If we lack tzset, report that localtime does not cache TZ,
15821 # since we can't invalidate the cache if we don't have tzset.
15822 emacs_cv_localtime_cache=no
15825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
15826 $as_echo "$emacs_cv_localtime_cache" >&6; }
15827 if test $emacs_cv_localtime_cache = yes; then
15829 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
15833 ok_so_far=yes
15834 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
15835 if test "x$ac_cv_func_socket" = x""yes; then :
15837 else
15838 ok_so_far=no
15841 if test $ok_so_far = yes; then
15842 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
15843 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
15845 else
15846 ok_so_far=no
15851 if test $ok_so_far = yes; then
15852 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
15853 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
15855 else
15856 ok_so_far=no
15861 if test $ok_so_far = yes; then
15863 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
15867 case $canonical in
15868 *-solaris2.4 | *-solaris2.4.*)
15869 : ${ac_cv_func_vfork_works=no};;
15870 esac
15872 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15873 if test "x$ac_cv_type_pid_t" = x""yes; then :
15875 else
15877 cat >>confdefs.h <<_ACEOF
15878 #define pid_t int
15879 _ACEOF
15883 for ac_header in vfork.h
15884 do :
15885 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15886 if test "x$ac_cv_header_vfork_h" = x""yes; then :
15887 cat >>confdefs.h <<_ACEOF
15888 #define HAVE_VFORK_H 1
15889 _ACEOF
15893 done
15895 for ac_func in fork vfork
15896 do :
15897 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15898 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15899 eval as_val=\$$as_ac_var
15900 if test "x$as_val" = x""yes; then :
15901 cat >>confdefs.h <<_ACEOF
15902 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15903 _ACEOF
15906 done
15908 if test "x$ac_cv_func_fork" = xyes; then
15909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15910 $as_echo_n "checking for working fork... " >&6; }
15911 if test "${ac_cv_func_fork_works+set}" = set; then :
15912 $as_echo_n "(cached) " >&6
15913 else
15914 if test "$cross_compiling" = yes; then :
15915 ac_cv_func_fork_works=cross
15916 else
15917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15918 /* end confdefs.h. */
15919 $ac_includes_default
15921 main ()
15924 /* By Ruediger Kuhlmann. */
15925 return fork () < 0;
15928 return 0;
15930 _ACEOF
15931 if ac_fn_c_try_run "$LINENO"; then :
15932 ac_cv_func_fork_works=yes
15933 else
15934 ac_cv_func_fork_works=no
15936 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15937 conftest.$ac_objext conftest.beam conftest.$ac_ext
15941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15942 $as_echo "$ac_cv_func_fork_works" >&6; }
15944 else
15945 ac_cv_func_fork_works=$ac_cv_func_fork
15947 if test "x$ac_cv_func_fork_works" = xcross; then
15948 case $host in
15949 *-*-amigaos* | *-*-msdosdjgpp*)
15950 # Override, as these systems have only a dummy fork() stub
15951 ac_cv_func_fork_works=no
15954 ac_cv_func_fork_works=yes
15956 esac
15957 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15958 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15960 ac_cv_func_vfork_works=$ac_cv_func_vfork
15961 if test "x$ac_cv_func_vfork" = xyes; then
15962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15963 $as_echo_n "checking for working vfork... " >&6; }
15964 if test "${ac_cv_func_vfork_works+set}" = set; then :
15965 $as_echo_n "(cached) " >&6
15966 else
15967 if test "$cross_compiling" = yes; then :
15968 ac_cv_func_vfork_works=cross
15969 else
15970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15971 /* end confdefs.h. */
15972 /* Thanks to Paul Eggert for this test. */
15973 $ac_includes_default
15974 #include <sys/wait.h>
15975 #ifdef HAVE_VFORK_H
15976 # include <vfork.h>
15977 #endif
15978 /* On some sparc systems, changes by the child to local and incoming
15979 argument registers are propagated back to the parent. The compiler
15980 is told about this with #include <vfork.h>, but some compilers
15981 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15982 static variable whose address is put into a register that is
15983 clobbered by the vfork. */
15984 static void
15985 #ifdef __cplusplus
15986 sparc_address_test (int arg)
15987 # else
15988 sparc_address_test (arg) int arg;
15989 #endif
15991 static pid_t child;
15992 if (!child) {
15993 child = vfork ();
15994 if (child < 0) {
15995 perror ("vfork");
15996 _exit(2);
15998 if (!child) {
15999 arg = getpid();
16000 write(-1, "", 0);
16001 _exit (arg);
16007 main ()
16009 pid_t parent = getpid ();
16010 pid_t child;
16012 sparc_address_test (0);
16014 child = vfork ();
16016 if (child == 0) {
16017 /* Here is another test for sparc vfork register problems. This
16018 test uses lots of local variables, at least as many local
16019 variables as main has allocated so far including compiler
16020 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16021 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16022 reuse the register of parent for one of the local variables,
16023 since it will think that parent can't possibly be used any more
16024 in this routine. Assigning to the local variable will thus
16025 munge parent in the parent process. */
16026 pid_t
16027 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16028 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16029 /* Convince the compiler that p..p7 are live; otherwise, it might
16030 use the same hardware register for all 8 local variables. */
16031 if (p != p1 || p != p2 || p != p3 || p != p4
16032 || p != p5 || p != p6 || p != p7)
16033 _exit(1);
16035 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16036 from child file descriptors. If the child closes a descriptor
16037 before it execs or exits, this munges the parent's descriptor
16038 as well. Test for this by closing stdout in the child. */
16039 _exit(close(fileno(stdout)) != 0);
16040 } else {
16041 int status;
16042 struct stat st;
16044 while (wait(&status) != child)
16046 return (
16047 /* Was there some problem with vforking? */
16048 child < 0
16050 /* Did the child fail? (This shouldn't happen.) */
16051 || status
16053 /* Did the vfork/compiler bug occur? */
16054 || parent != getpid()
16056 /* Did the file descriptor bug occur? */
16057 || fstat(fileno(stdout), &st) != 0
16061 _ACEOF
16062 if ac_fn_c_try_run "$LINENO"; then :
16063 ac_cv_func_vfork_works=yes
16064 else
16065 ac_cv_func_vfork_works=no
16067 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16068 conftest.$ac_objext conftest.beam conftest.$ac_ext
16072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16073 $as_echo "$ac_cv_func_vfork_works" >&6; }
16076 if test "x$ac_cv_func_fork_works" = xcross; then
16077 ac_cv_func_vfork_works=$ac_cv_func_vfork
16078 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16079 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16082 if test "x$ac_cv_func_vfork_works" = xyes; then
16084 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16086 else
16088 $as_echo "#define vfork fork" >>confdefs.h
16091 if test "x$ac_cv_func_fork_works" = xyes; then
16093 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16098 for ac_func in snprintf
16099 do :
16100 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16101 if test "x$ac_cv_func_snprintf" = x""yes; then :
16102 cat >>confdefs.h <<_ACEOF
16103 #define HAVE_SNPRINTF 1
16104 _ACEOF
16107 done
16110 XGSELOBJ=
16111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16112 $as_echo_n "checking whether GLib is linked in... " >&6; }
16113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16114 /* end confdefs.h. */
16115 #include <glib.h>
16118 main ()
16120 g_print ("Hello world");
16122 return 0;
16124 _ACEOF
16125 if ac_fn_c_try_link "$LINENO"; then :
16126 links_glib=yes
16127 else
16128 links_glib=no
16130 rm -f core conftest.err conftest.$ac_objext \
16131 conftest$ac_exeext conftest.$ac_ext
16132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16133 $as_echo "$links_glib" >&6; }
16134 if test "${links_glib}" = "yes"; then
16136 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16138 if test "$HAVE_NS" = no;then
16139 XGSELOBJ=xgselect.o
16144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16145 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16146 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16147 $as_echo_n "(cached) " >&6
16148 else
16149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16150 /* end confdefs.h. */
16151 #include <langinfo.h>
16153 main ()
16155 char* cs = nl_langinfo(CODESET);
16157 return 0;
16159 _ACEOF
16160 if ac_fn_c_try_link "$LINENO"; then :
16161 emacs_cv_langinfo_codeset=yes
16162 else
16163 emacs_cv_langinfo_codeset=no
16165 rm -f core conftest.err conftest.$ac_objext \
16166 conftest$ac_exeext conftest.$ac_ext
16169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16170 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16171 if test $emacs_cv_langinfo_codeset = yes; then
16173 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16178 $as_echo_n "checking for mbstate_t... " >&6; }
16179 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16180 $as_echo_n "(cached) " >&6
16181 else
16182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16183 /* end confdefs.h. */
16184 $ac_includes_default
16185 # include <wchar.h>
16187 main ()
16189 mbstate_t x; return sizeof x;
16191 return 0;
16193 _ACEOF
16194 if ac_fn_c_try_compile "$LINENO"; then :
16195 ac_cv_type_mbstate_t=yes
16196 else
16197 ac_cv_type_mbstate_t=no
16199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16202 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16203 if test $ac_cv_type_mbstate_t = yes; then
16205 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16207 else
16209 $as_echo "#define mbstate_t int" >>confdefs.h
16213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16214 $as_echo_n "checking for C restricted array declarations... " >&6; }
16215 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16216 $as_echo_n "(cached) " >&6
16217 else
16218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16219 /* end confdefs.h. */
16220 void fred (int x[__restrict]);
16222 main ()
16226 return 0;
16228 _ACEOF
16229 if ac_fn_c_try_compile "$LINENO"; then :
16230 emacs_cv_c_restrict_arr=yes
16231 else
16232 emacs_cv_c_restrict_arr=no
16234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16237 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16238 if test "$emacs_cv_c_restrict_arr" = yes; then
16240 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16245 if test "${opsys}" != "mingw32"; then
16247 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16252 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16255 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16256 if test "${opsys}" != "mingw32"; then
16258 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16263 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16269 if test "${opsys}" = "mingw32"; then
16270 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16272 else
16273 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16278 if test "${opsys}" = "mingw32"; then
16279 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16281 else
16282 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16287 $as_echo "#define subprocesses 1" >>confdefs.h
16291 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16296 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16299 if test "${opsys}" = "mingw32"; then
16301 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == ':')" >>confdefs.h
16305 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16309 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16311 else
16313 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16317 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16321 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16327 case $opsys in
16328 aix4-2)
16329 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16330 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16335 hpux*)
16336 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16339 esac
16342 case $opsys in
16343 irix6-5 | sol2* | unixware )
16345 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16348 esac
16350 emacs_broken_SIGIO=no
16352 case $opsys in
16353 hpux* | irix6-5 | openbsd | sol2* | unixware | gnu-kfreebsd )
16354 emacs_broken_SIGIO=yes
16357 aix4-2)
16359 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16363 freebsd)
16365 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16368 esac
16370 case $opsys in
16371 gnu-* | sol2-10 )
16373 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16376 esac
16378 case $opsys in
16379 darwin | dragonfly | freebsd | netbsd | openbsd )
16381 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16384 esac
16386 case $opsys in
16387 netbsd | openbsd) sound_device="/dev/audio" ;;
16388 *) sound_device="/dev/dsp" ;;
16389 esac
16392 cat >>confdefs.h <<_ACEOF
16393 #define DEFAULT_SOUND_DEVICE "$sound_device"
16394 _ACEOF
16398 case $opsys in
16399 darwin | gnu-linux | gnu-kfreebsd )
16401 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16404 esac
16407 case $opsys in
16408 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16410 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16413 esac
16422 case $opsys in
16423 aix4-2 )
16424 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16426 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16428 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16432 cygwin )
16433 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16435 $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
16437 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16439 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16443 darwin )
16444 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16446 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16448 $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
16450 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16452 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16456 gnu | openbsd )
16457 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16461 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16462 if test "x$ac_cv_func_grantpt" = xyes; then
16464 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16466 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16468 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16470 if test "x$ac_cv_func_posix_openpt" = xyes; then
16471 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_CLOEXEC | O_NOCTTY)" >>confdefs.h
16473 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16475 elif test "x$ac_cv_func_getpt" = xyes; then
16476 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16478 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16480 else
16481 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16484 else
16485 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16490 hpux*)
16491 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16493 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16495 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16499 irix6-5 )
16500 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16502 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16504 $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
16506 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16508 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16512 sol2* )
16513 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16517 unixware )
16518 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16521 esac
16524 case $opsys in
16525 sol2* | unixware )
16526 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16528 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16531 $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
16534 esac
16539 case $opsys in
16540 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
16541 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16545 gnu-linux | gnu-kfreebsd )
16547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
16548 $as_echo_n "checking for signals via characters... " >&6; }
16549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16550 /* end confdefs.h. */
16552 #include <linux/version.h>
16553 #if LINUX_VERSION_CODE < 0x20400
16554 # error "Linux version too old"
16555 #endif
16558 main ()
16562 return 0;
16564 _ACEOF
16565 if ac_fn_c_try_cpp "$LINENO"; then :
16566 emacs_signals_via_chars=yes
16567 else
16568 emacs_signals_via_chars=no
16570 rm -f conftest.err conftest.$ac_ext
16572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
16573 $as_echo "$emacs_signals_via_chars" >&6; }
16574 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16577 esac
16582 case $opsys in
16583 aix*)
16584 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
16587 hpux*)
16588 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
16591 irix6-5)
16592 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
16595 esac
16600 case $opsys in
16601 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
16604 gnu | dragonfly | freebsd | netbsd | openbsd )
16606 $as_echo "#define TABDLY OXTABS" >>confdefs.h
16608 $as_echo "#define TAB3 OXTABS" >>confdefs.h
16612 gnu-linux | gnu-kfreebsd )
16613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16614 /* end confdefs.h. */
16616 #ifndef __ia64__
16617 # error "not ia64"
16618 #endif
16621 main ()
16625 return 0;
16627 _ACEOF
16628 if ac_fn_c_try_cpp "$LINENO"; then :
16630 $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
16633 rm -f conftest.err conftest.$ac_ext
16636 hpux*)
16638 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
16641 esac
16647 case $opsys in
16648 gnu-linux | gnu-kfreebsd )
16649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16650 /* end confdefs.h. */
16652 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
16653 || defined __alpha__ || defined __mips__ || defined __s390__ \
16654 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
16655 || defined __ia64__ || defined __sh__
16656 /* ok */
16657 #else
16658 # error "setjmp not known to work on this arch"
16659 #endif
16662 main ()
16666 return 0;
16668 _ACEOF
16669 if ac_fn_c_try_cpp "$LINENO"; then :
16670 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16673 rm -f conftest.err conftest.$ac_ext
16675 esac
16678 if test x$GCC = xyes; then
16679 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16681 else
16682 case $opsys in
16683 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
16684 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16687 esac
16689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
16690 $as_echo_n "checking for _setjmp... " >&6; }
16691 if test "${emacs_cv_func__setjmp+set}" = set; then :
16692 $as_echo_n "(cached) " >&6
16693 else
16694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16695 /* end confdefs.h. */
16696 #include <setjmp.h>
16697 #ifdef __MINGW32__
16698 # define _longjmp longjmp
16699 #endif
16702 main ()
16704 jmp_buf j;
16705 if (! _setjmp (j))
16706 _longjmp (j, 1);
16708 return 0;
16710 _ACEOF
16711 if ac_fn_c_try_link "$LINENO"; then :
16712 emacs_cv_func__setjmp=yes
16713 else
16714 emacs_cv_func__setjmp=no
16716 rm -f core conftest.err conftest.$ac_objext \
16717 conftest$ac_exeext conftest.$ac_ext
16719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
16720 $as_echo "$emacs_cv_func__setjmp" >&6; }
16721 if test $emacs_cv_func__setjmp = yes; then
16723 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
16725 else
16726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
16727 $as_echo_n "checking for sigsetjmp... " >&6; }
16728 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
16729 $as_echo_n "(cached) " >&6
16730 else
16731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16732 /* end confdefs.h. */
16733 #include <setjmp.h>
16736 main ()
16738 sigjmp_buf j;
16739 if (! sigsetjmp (j, 1))
16740 siglongjmp (j, 1);
16742 return 0;
16744 _ACEOF
16745 if ac_fn_c_try_link "$LINENO"; then :
16746 emacs_cv_func_sigsetjmp=yes
16747 else
16748 emacs_cv_func_sigsetjmp=no
16750 rm -f core conftest.err conftest.$ac_objext \
16751 conftest$ac_exeext conftest.$ac_ext
16753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
16754 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
16755 if test $emacs_cv_func_sigsetjmp = yes; then
16757 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
16762 case $opsys in
16763 sol2* | unixware )
16765 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
16768 esac
16771 case $opsys in
16772 hpux* | sol2* )
16774 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
16777 esac
16785 case $opsys in
16786 aix4-2)
16787 $as_echo "#define USG /**/" >>confdefs.h
16789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16790 /* end confdefs.h. */
16792 #ifndef _AIX
16793 # error "_AIX not defined"
16794 #endif
16797 main ()
16801 return 0;
16803 _ACEOF
16804 if ac_fn_c_try_cpp "$LINENO"; then :
16806 else
16808 $as_echo "#define _AIX /**/" >>confdefs.h
16811 rm -f conftest.err conftest.$ac_ext
16814 cygwin)
16816 $as_echo "#define CYGWIN 1" >>confdefs.h
16820 darwin)
16822 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
16826 gnu-linux | gnu-kfreebsd )
16827 $as_echo "#define USG /**/" >>confdefs.h
16830 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
16834 hpux*)
16835 $as_echo "#define USG /**/" >>confdefs.h
16838 $as_echo "#define HPUX /**/" >>confdefs.h
16842 irix6-5)
16843 $as_echo "#define USG /**/" >>confdefs.h
16845 $as_echo "#define USG5_4 /**/" >>confdefs.h
16848 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
16852 mingw32)
16853 $as_echo "#define DOS_NT /**/" >>confdefs.h
16856 $as_echo "#define WINDOWSNT 1" >>confdefs.h
16858 if test "x$ac_enable_checking" != "x" ; then
16860 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
16865 sol2*)
16866 $as_echo "#define USG /**/" >>confdefs.h
16868 $as_echo "#define USG5_4 /**/" >>confdefs.h
16871 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
16875 unixware)
16876 $as_echo "#define USG /**/" >>confdefs.h
16878 $as_echo "#define USG5_4 /**/" >>confdefs.h
16881 esac
16883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
16884 $as_echo_n "checking for usable FIONREAD... " >&6; }
16885 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
16886 $as_echo_n "(cached) " >&6
16887 else
16888 case $opsys in
16889 aix4-2)
16890 emacs_cv_usable_FIONREAD=no
16893 mingw32)
16894 emacs_cv_usable_FIONREAD=yes
16898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16899 /* end confdefs.h. */
16900 #include <sys/types.h>
16901 #include <sys/ioctl.h>
16902 #ifdef USG5_4
16903 # include <sys/filio.h>
16904 #endif
16907 main ()
16909 int foo = ioctl (0, FIONREAD, &foo);
16911 return 0;
16913 _ACEOF
16914 if ac_fn_c_try_compile "$LINENO"; then :
16915 emacs_cv_usable_FIONREAD=yes
16916 else
16917 emacs_cv_usable_FIONREAD=no
16919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16921 esac
16923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
16924 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
16925 if test $emacs_cv_usable_FIONREAD = yes; then
16927 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
16930 if test $emacs_broken_SIGIO = no; then
16931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
16932 $as_echo_n "checking for usable SIGIO... " >&6; }
16933 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
16934 $as_echo_n "(cached) " >&6
16935 else
16936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16937 /* end confdefs.h. */
16938 #include <fcntl.h>
16939 #include <signal.h>
16942 main ()
16944 int foo = SIGIO | F_SETFL | FASYNC;
16946 return 0;
16948 _ACEOF
16949 if ac_fn_c_try_compile "$LINENO"; then :
16950 emacs_cv_usable_SIGIO=yes
16951 else
16952 emacs_cv_usable_SIGIO=no
16954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
16957 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
16958 if test $emacs_cv_usable_SIGIO = yes; then
16960 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
16967 case $opsys in
16968 cygwin)
16970 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
16974 hpux11)
16976 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
16980 irix6-5)
16982 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
16986 sol2-10)
16988 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
16991 esac
16993 # Set up the CFLAGS for real compilation, so we can substitute it.
16994 CFLAGS="$REAL_CFLAGS"
16995 CPPFLAGS="$REAL_CPPFLAGS"
16997 ## Hack to detect a buggy GCC version.
16998 if test "x$GCC" = xyes \
16999 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17000 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17001 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17002 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17005 version=$PACKAGE_VERSION
17007 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17009 cat >>confdefs.h <<_ACEOF
17010 #define COPYRIGHT "$copyright"
17011 _ACEOF
17015 ### Specify what sort of things we'll be editing into Makefile and config.h.
17016 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17019 ## Unused?
17042 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17043 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17044 ## end of LIBX_BASE, but nothing ever set it.
17049 ## Used in lwlib/Makefile.in.
17058 if test -n "${term_header}"; then
17060 cat >>confdefs.h <<_ACEOF
17061 #define TERM_HEADER "${term_header}"
17062 _ACEOF
17067 cat >>confdefs.h <<_ACEOF
17068 #define EMACS_CONFIGURATION "${canonical}"
17069 _ACEOF
17071 emacs_config_options=`echo "$emacs_config_options " | sed -e 's/--no-create //' -e 's/--no-recursion //' -e 's/ *$//' -e "s/\"/'/g"`
17073 cat >>confdefs.h <<_ACEOF
17074 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17075 _ACEOF
17079 case $opsys in
17080 mingw32)
17081 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17084 esac
17086 XMENU_OBJ=
17087 XOBJ=
17088 FONT_OBJ=
17089 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17091 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17093 XMENU_OBJ=xmenu.o
17094 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17095 FONT_OBJ=xfont.o
17096 if test "$HAVE_XFT" = "yes"; then
17097 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17098 elif test "$HAVE_FREETYPE" = "yes"; then
17099 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17107 WIDGET_OBJ=
17108 MOTIF_LIBW=
17109 if test "${USE_X_TOOLKIT}" != "none" ; then
17110 WIDGET_OBJ=widget.o
17112 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17114 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17116 $as_echo "#define USE_LUCID 1" >>confdefs.h
17118 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17120 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17122 MOTIF_LIBW=-lXm
17123 case "$opsys" in
17124 gnu-linux)
17125 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17126 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17129 unixware)
17130 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17131 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17132 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17135 aix4-2)
17136 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17137 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17139 esac
17140 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17145 TOOLKIT_LIBW=
17146 case "$USE_X_TOOLKIT" in
17147 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17148 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17149 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17150 esac
17153 if test "${opsys}" != "mingw32"; then
17154 if test "$USE_X_TOOLKIT" = "none"; then
17155 LIBXT_OTHER="\$(LIBXSM)"
17156 OLDXMENU_TARGET="really-oldXMenu"
17157 else
17158 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17159 OLDXMENU_TARGET="really-lwlib"
17164 ## The X Menu stuff is present in the X10 distribution, but missing
17165 ## from X11. If we have X10, just use the installed library;
17166 ## otherwise, use our own copy.
17167 if test "${HAVE_X11}" = "yes" ; then
17169 $as_echo "#define HAVE_X11 1" >>confdefs.h
17172 if test "$USE_X_TOOLKIT" = "none"; then
17173 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17174 else
17175 OLDXMENU="\${lwlibdir}/liblw.a"
17177 LIBXMENU="\$(OLDXMENU)"
17178 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17179 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17180 else
17181 ## For a syntactically valid Makefile; not actually used for anything.
17182 ## See comments in src/Makefile.in.
17183 OLDXMENU=nothing
17184 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17185 if test "${HAVE_X_WINDOWS}" = "yes"; then
17186 LIBXMENU="-lXMenu"
17187 else
17188 LIBXMENU=
17190 LIBX_OTHER=
17191 OLDXMENU_DEPS=
17194 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17195 OLDXMENU_TARGET=
17196 OLDXMENU=nothing
17197 LIBXMENU=
17198 OLDXMENU_DEPS=
17207 if test "${HAVE_MENUS}" = "yes" ; then
17209 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17213 if test "${GNU_MALLOC}" = "yes" ; then
17215 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17219 RALLOC_OBJ=
17220 if test "${REL_ALLOC}" = "yes" ; then
17222 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17225 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17229 if test "$opsys" = "cygwin"; then
17230 CYGWIN_OBJ="sheap.o cygw32.o"
17231 ## Cygwin differs because of its unexec().
17232 PRE_ALLOC_OBJ=
17233 POST_ALLOC_OBJ=lastfile.o
17234 elif test "$opsys" = "mingw32"; then
17235 CYGWIN_OBJ=
17236 PRE_ALLOC_OBJ=
17237 POST_ALLOC_OBJ=lastfile.o
17238 else
17239 CYGWIN_OBJ=
17240 PRE_ALLOC_OBJ=lastfile.o
17241 POST_ALLOC_OBJ=
17247 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17248 # it temporarily reverts them to their pre-pkg-config values,
17249 # because gnulib needs to work with both src (which uses the
17250 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17251 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17252 # and it therefore needs to run in an environment where LIBS does not
17253 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17254 # for some package unrelated to lib-src.
17255 SAVE_CFLAGS=$CFLAGS
17256 SAVE_LIBS=$LIBS
17257 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17258 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17270 LIBC_FATAL_STDERR_=1
17271 export LIBC_FATAL_STDERR_
17273 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17274 # for constant arguments. Useless!
17275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17276 $as_echo_n "checking for working alloca.h... " >&6; }
17277 if test "${ac_cv_working_alloca_h+set}" = set; then :
17278 $as_echo_n "(cached) " >&6
17279 else
17280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17281 /* end confdefs.h. */
17282 #include <alloca.h>
17284 main ()
17286 char *p = (char *) alloca (2 * sizeof (int));
17287 if (p) return 0;
17289 return 0;
17291 _ACEOF
17292 if ac_fn_c_try_link "$LINENO"; then :
17293 ac_cv_working_alloca_h=yes
17294 else
17295 ac_cv_working_alloca_h=no
17297 rm -f core conftest.err conftest.$ac_objext \
17298 conftest$ac_exeext conftest.$ac_ext
17300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17301 $as_echo "$ac_cv_working_alloca_h" >&6; }
17302 if test $ac_cv_working_alloca_h = yes; then
17304 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17309 $as_echo_n "checking for alloca... " >&6; }
17310 if test "${ac_cv_func_alloca_works+set}" = set; then :
17311 $as_echo_n "(cached) " >&6
17312 else
17313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17314 /* end confdefs.h. */
17315 #ifdef __GNUC__
17316 # define alloca __builtin_alloca
17317 #else
17318 # ifdef _MSC_VER
17319 # include <malloc.h>
17320 # define alloca _alloca
17321 # else
17322 # ifdef HAVE_ALLOCA_H
17323 # include <alloca.h>
17324 # else
17325 # ifdef _AIX
17326 #pragma alloca
17327 # else
17328 # ifndef alloca /* predefined by HP cc +Olibcalls */
17329 char *alloca ();
17330 # endif
17331 # endif
17332 # endif
17333 # endif
17334 #endif
17337 main ()
17339 char *p = (char *) alloca (1);
17340 if (p) return 0;
17342 return 0;
17344 _ACEOF
17345 if ac_fn_c_try_link "$LINENO"; then :
17346 ac_cv_func_alloca_works=yes
17347 else
17348 ac_cv_func_alloca_works=no
17350 rm -f core conftest.err conftest.$ac_objext \
17351 conftest$ac_exeext conftest.$ac_ext
17353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17354 $as_echo "$ac_cv_func_alloca_works" >&6; }
17356 if test $ac_cv_func_alloca_works = yes; then
17358 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17360 else
17361 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17362 # that cause trouble. Some versions do not even contain alloca or
17363 # contain a buggy version. If you still want to use their alloca,
17364 # use ar to extract alloca.o from them instead of compiling alloca.c.
17370 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17372 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17376 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17377 if test "${ac_cv_os_cray+set}" = set; then :
17378 $as_echo_n "(cached) " >&6
17379 else
17380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17381 /* end confdefs.h. */
17382 #if defined CRAY && ! defined CRAY2
17383 webecray
17384 #else
17385 wenotbecray
17386 #endif
17388 _ACEOF
17389 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17390 $EGREP "webecray" >/dev/null 2>&1; then :
17391 ac_cv_os_cray=yes
17392 else
17393 ac_cv_os_cray=no
17395 rm -f conftest*
17398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17399 $as_echo "$ac_cv_os_cray" >&6; }
17400 if test $ac_cv_os_cray = yes; then
17401 for ac_func in _getb67 GETB67 getb67; do
17402 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17403 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17404 eval as_val=\$$as_ac_var
17405 if test "x$as_val" = x""yes; then :
17407 cat >>confdefs.h <<_ACEOF
17408 #define CRAY_STACKSEG_END $ac_func
17409 _ACEOF
17411 break
17414 done
17417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17418 $as_echo_n "checking stack direction for C alloca... " >&6; }
17419 if test "${ac_cv_c_stack_direction+set}" = set; then :
17420 $as_echo_n "(cached) " >&6
17421 else
17422 if test "$cross_compiling" = yes; then :
17423 ac_cv_c_stack_direction=0
17424 else
17425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17426 /* end confdefs.h. */
17427 $ac_includes_default
17429 find_stack_direction (int *addr, int depth)
17431 int dir, dummy = 0;
17432 if (! addr)
17433 addr = &dummy;
17434 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17435 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17436 return dir + dummy;
17440 main (int argc, char **argv)
17442 return find_stack_direction (0, argc + !argv + 20) < 0;
17444 _ACEOF
17445 if ac_fn_c_try_run "$LINENO"; then :
17446 ac_cv_c_stack_direction=1
17447 else
17448 ac_cv_c_stack_direction=-1
17450 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17451 conftest.$ac_objext conftest.beam conftest.$ac_ext
17455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17456 $as_echo "$ac_cv_c_stack_direction" >&6; }
17457 cat >>confdefs.h <<_ACEOF
17458 #define STACK_DIRECTION $ac_cv_c_stack_direction
17459 _ACEOF
17467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17468 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17469 if test "${ac_cv_c_bigendian+set}" = set; then :
17470 $as_echo_n "(cached) " >&6
17471 else
17472 ac_cv_c_bigendian=unknown
17473 # See if we're dealing with a universal compiler.
17474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17475 /* end confdefs.h. */
17476 #ifndef __APPLE_CC__
17477 not a universal capable compiler
17478 #endif
17479 typedef int dummy;
17481 _ACEOF
17482 if ac_fn_c_try_compile "$LINENO"; then :
17484 # Check for potential -arch flags. It is not universal unless
17485 # there are at least two -arch flags with different values.
17486 ac_arch=
17487 ac_prev=
17488 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17489 if test -n "$ac_prev"; then
17490 case $ac_word in
17491 i?86 | x86_64 | ppc | ppc64)
17492 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17493 ac_arch=$ac_word
17494 else
17495 ac_cv_c_bigendian=universal
17496 break
17499 esac
17500 ac_prev=
17501 elif test "x$ac_word" = "x-arch"; then
17502 ac_prev=arch
17504 done
17506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17507 if test $ac_cv_c_bigendian = unknown; then
17508 # See if sys/param.h defines the BYTE_ORDER macro.
17509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17510 /* end confdefs.h. */
17511 #include <sys/types.h>
17512 #include <sys/param.h>
17515 main ()
17517 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17518 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17519 && LITTLE_ENDIAN)
17520 bogus endian macros
17521 #endif
17524 return 0;
17526 _ACEOF
17527 if ac_fn_c_try_compile "$LINENO"; then :
17528 # It does; now see whether it defined to BIG_ENDIAN or not.
17529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17530 /* end confdefs.h. */
17531 #include <sys/types.h>
17532 #include <sys/param.h>
17535 main ()
17537 #if BYTE_ORDER != BIG_ENDIAN
17538 not big endian
17539 #endif
17542 return 0;
17544 _ACEOF
17545 if ac_fn_c_try_compile "$LINENO"; then :
17546 ac_cv_c_bigendian=yes
17547 else
17548 ac_cv_c_bigendian=no
17550 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17554 if test $ac_cv_c_bigendian = unknown; then
17555 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
17556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17557 /* end confdefs.h. */
17558 #include <limits.h>
17561 main ()
17563 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
17564 bogus endian macros
17565 #endif
17568 return 0;
17570 _ACEOF
17571 if ac_fn_c_try_compile "$LINENO"; then :
17572 # It does; now see whether it defined to _BIG_ENDIAN or not.
17573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17574 /* end confdefs.h. */
17575 #include <limits.h>
17578 main ()
17580 #ifndef _BIG_ENDIAN
17581 not big endian
17582 #endif
17585 return 0;
17587 _ACEOF
17588 if ac_fn_c_try_compile "$LINENO"; then :
17589 ac_cv_c_bigendian=yes
17590 else
17591 ac_cv_c_bigendian=no
17593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17597 if test $ac_cv_c_bigendian = unknown; then
17598 # Compile a test program.
17599 if test "$cross_compiling" = yes; then :
17600 # Try to guess by grepping values from an object file.
17601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17602 /* end confdefs.h. */
17603 short int ascii_mm[] =
17604 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
17605 short int ascii_ii[] =
17606 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17607 int use_ascii (int i) {
17608 return ascii_mm[i] + ascii_ii[i];
17610 short int ebcdic_ii[] =
17611 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
17612 short int ebcdic_mm[] =
17613 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17614 int use_ebcdic (int i) {
17615 return ebcdic_mm[i] + ebcdic_ii[i];
17617 extern int foo;
17620 main ()
17622 return use_ascii (foo) == use_ebcdic (foo);
17624 return 0;
17626 _ACEOF
17627 if ac_fn_c_try_compile "$LINENO"; then :
17628 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
17629 ac_cv_c_bigendian=yes
17631 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
17632 if test "$ac_cv_c_bigendian" = unknown; then
17633 ac_cv_c_bigendian=no
17634 else
17635 # finding both strings is unlikely to happen, but who knows?
17636 ac_cv_c_bigendian=unknown
17640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17641 else
17642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17643 /* end confdefs.h. */
17644 $ac_includes_default
17646 main ()
17649 /* Are we little or big endian? From Harbison&Steele. */
17650 union
17652 long int l;
17653 char c[sizeof (long int)];
17654 } u;
17655 u.l = 1;
17656 return u.c[sizeof (long int) - 1] == 1;
17659 return 0;
17661 _ACEOF
17662 if ac_fn_c_try_run "$LINENO"; then :
17663 ac_cv_c_bigendian=no
17664 else
17665 ac_cv_c_bigendian=yes
17667 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17668 conftest.$ac_objext conftest.beam conftest.$ac_ext
17673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
17674 $as_echo "$ac_cv_c_bigendian" >&6; }
17675 case $ac_cv_c_bigendian in #(
17676 yes)
17677 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
17678 ;; #(
17680 ;; #(
17681 universal)
17683 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
17685 ;; #(
17687 as_fn_error "unknown endianness
17688 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
17689 esac
17693 GNULIB_CHDIR=0;
17694 GNULIB_CHOWN=0;
17695 GNULIB_CLOSE=0;
17696 GNULIB_DUP=0;
17697 GNULIB_DUP2=0;
17698 GNULIB_DUP3=0;
17699 GNULIB_ENVIRON=0;
17700 GNULIB_EUIDACCESS=0;
17701 GNULIB_FACCESSAT=0;
17702 GNULIB_FCHDIR=0;
17703 GNULIB_FCHOWNAT=0;
17704 GNULIB_FDATASYNC=0;
17705 GNULIB_FSYNC=0;
17706 GNULIB_FTRUNCATE=0;
17707 GNULIB_GETCWD=0;
17708 GNULIB_GETDOMAINNAME=0;
17709 GNULIB_GETDTABLESIZE=0;
17710 GNULIB_GETGROUPS=0;
17711 GNULIB_GETHOSTNAME=0;
17712 GNULIB_GETLOGIN=0;
17713 GNULIB_GETLOGIN_R=0;
17714 GNULIB_GETPAGESIZE=0;
17715 GNULIB_GETUSERSHELL=0;
17716 GNULIB_GROUP_MEMBER=0;
17717 GNULIB_ISATTY=0;
17718 GNULIB_LCHOWN=0;
17719 GNULIB_LINK=0;
17720 GNULIB_LINKAT=0;
17721 GNULIB_LSEEK=0;
17722 GNULIB_PIPE=0;
17723 GNULIB_PIPE2=0;
17724 GNULIB_PREAD=0;
17725 GNULIB_PWRITE=0;
17726 GNULIB_READ=0;
17727 GNULIB_READLINK=0;
17728 GNULIB_READLINKAT=0;
17729 GNULIB_RMDIR=0;
17730 GNULIB_SETHOSTNAME=0;
17731 GNULIB_SLEEP=0;
17732 GNULIB_SYMLINK=0;
17733 GNULIB_SYMLINKAT=0;
17734 GNULIB_TTYNAME_R=0;
17735 GNULIB_UNISTD_H_NONBLOCKING=0;
17736 GNULIB_UNISTD_H_SIGPIPE=0;
17737 GNULIB_UNLINK=0;
17738 GNULIB_UNLINKAT=0;
17739 GNULIB_USLEEP=0;
17740 GNULIB_WRITE=0;
17741 HAVE_CHOWN=1;
17742 HAVE_DUP2=1;
17743 HAVE_DUP3=1;
17744 HAVE_EUIDACCESS=1;
17745 HAVE_FACCESSAT=1;
17746 HAVE_FCHDIR=1;
17747 HAVE_FCHOWNAT=1;
17748 HAVE_FDATASYNC=1;
17749 HAVE_FSYNC=1;
17750 HAVE_FTRUNCATE=1;
17751 HAVE_GETDTABLESIZE=1;
17752 HAVE_GETGROUPS=1;
17753 HAVE_GETHOSTNAME=1;
17754 HAVE_GETLOGIN=1;
17755 HAVE_GETPAGESIZE=1;
17756 HAVE_GROUP_MEMBER=1;
17757 HAVE_LCHOWN=1;
17758 HAVE_LINK=1;
17759 HAVE_LINKAT=1;
17760 HAVE_PIPE=1;
17761 HAVE_PIPE2=1;
17762 HAVE_PREAD=1;
17763 HAVE_PWRITE=1;
17764 HAVE_READLINK=1;
17765 HAVE_READLINKAT=1;
17766 HAVE_SETHOSTNAME=1;
17767 HAVE_SLEEP=1;
17768 HAVE_SYMLINK=1;
17769 HAVE_SYMLINKAT=1;
17770 HAVE_UNLINKAT=1;
17771 HAVE_USLEEP=1;
17772 HAVE_DECL_ENVIRON=1;
17773 HAVE_DECL_FCHDIR=1;
17774 HAVE_DECL_FDATASYNC=1;
17775 HAVE_DECL_GETDOMAINNAME=1;
17776 HAVE_DECL_GETLOGIN_R=1;
17777 HAVE_DECL_GETPAGESIZE=1;
17778 HAVE_DECL_GETUSERSHELL=1;
17779 HAVE_DECL_SETHOSTNAME=1;
17780 HAVE_DECL_TTYNAME_R=1;
17781 HAVE_OS_H=0;
17782 HAVE_SYS_PARAM_H=0;
17783 REPLACE_CHOWN=0;
17784 REPLACE_CLOSE=0;
17785 REPLACE_DUP=0;
17786 REPLACE_DUP2=0;
17787 REPLACE_FCHOWNAT=0;
17788 REPLACE_FTRUNCATE=0;
17789 REPLACE_GETCWD=0;
17790 REPLACE_GETDOMAINNAME=0;
17791 REPLACE_GETLOGIN_R=0;
17792 REPLACE_GETGROUPS=0;
17793 REPLACE_GETPAGESIZE=0;
17794 REPLACE_ISATTY=0;
17795 REPLACE_LCHOWN=0;
17796 REPLACE_LINK=0;
17797 REPLACE_LINKAT=0;
17798 REPLACE_LSEEK=0;
17799 REPLACE_PREAD=0;
17800 REPLACE_PWRITE=0;
17801 REPLACE_READ=0;
17802 REPLACE_READLINK=0;
17803 REPLACE_RMDIR=0;
17804 REPLACE_SLEEP=0;
17805 REPLACE_SYMLINK=0;
17806 REPLACE_TTYNAME_R=0;
17807 REPLACE_UNLINK=0;
17808 REPLACE_UNLINKAT=0;
17809 REPLACE_USLEEP=0;
17810 REPLACE_WRITE=0;
17811 UNISTD_H_HAVE_WINSOCK2_H=0;
17812 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
17816 GNULIB_OPENDIR=0;
17817 GNULIB_READDIR=0;
17818 GNULIB_REWINDDIR=0;
17819 GNULIB_CLOSEDIR=0;
17820 GNULIB_DIRFD=0;
17821 GNULIB_FDOPENDIR=0;
17822 GNULIB_SCANDIR=0;
17823 GNULIB_ALPHASORT=0;
17824 HAVE_OPENDIR=1;
17825 HAVE_READDIR=1;
17826 HAVE_REWINDDIR=1;
17827 HAVE_CLOSEDIR=1;
17828 HAVE_DECL_DIRFD=1;
17829 HAVE_DECL_FDOPENDIR=1;
17830 HAVE_FDOPENDIR=1;
17831 HAVE_SCANDIR=1;
17832 HAVE_ALPHASORT=1;
17833 REPLACE_OPENDIR=0;
17834 REPLACE_CLOSEDIR=0;
17835 REPLACE_DIRFD=0;
17836 REPLACE_FDOPENDIR=0;
17840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
17841 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
17842 if test "${gl_cv_have_include_next+set}" = set; then :
17843 $as_echo_n "(cached) " >&6
17844 else
17845 rm -rf conftestd1a conftestd1b conftestd2
17846 mkdir conftestd1a conftestd1b conftestd2
17847 cat <<EOF > conftestd1a/conftest.h
17848 #define DEFINED_IN_CONFTESTD1
17849 #include_next <conftest.h>
17850 #ifdef DEFINED_IN_CONFTESTD2
17851 int foo;
17852 #else
17853 #error "include_next doesn't work"
17854 #endif
17856 cat <<EOF > conftestd1b/conftest.h
17857 #define DEFINED_IN_CONFTESTD1
17858 #include <stdio.h>
17859 #include_next <conftest.h>
17860 #ifdef DEFINED_IN_CONFTESTD2
17861 int foo;
17862 #else
17863 #error "include_next doesn't work"
17864 #endif
17866 cat <<EOF > conftestd2/conftest.h
17867 #ifndef DEFINED_IN_CONFTESTD1
17868 #error "include_next test doesn't work"
17869 #endif
17870 #define DEFINED_IN_CONFTESTD2
17872 gl_save_CPPFLAGS="$CPPFLAGS"
17873 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17875 /* end confdefs.h. */
17876 #include <conftest.h>
17877 _ACEOF
17878 if ac_fn_c_try_compile "$LINENO"; then :
17879 gl_cv_have_include_next=yes
17880 else
17881 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
17882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17883 /* end confdefs.h. */
17884 #include <conftest.h>
17885 _ACEOF
17886 if ac_fn_c_try_compile "$LINENO"; then :
17887 gl_cv_have_include_next=buggy
17888 else
17889 gl_cv_have_include_next=no
17891 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17895 CPPFLAGS="$gl_save_CPPFLAGS"
17896 rm -rf conftestd1a conftestd1b conftestd2
17899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
17900 $as_echo "$gl_cv_have_include_next" >&6; }
17901 PRAGMA_SYSTEM_HEADER=
17902 if test $gl_cv_have_include_next = yes; then
17903 INCLUDE_NEXT=include_next
17904 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17905 if test -n "$GCC"; then
17906 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
17908 else
17909 if test $gl_cv_have_include_next = buggy; then
17910 INCLUDE_NEXT=include
17911 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17912 else
17913 INCLUDE_NEXT=include
17914 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
17920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
17921 $as_echo_n "checking whether system header files limit the line length... " >&6; }
17922 if test "${gl_cv_pragma_columns+set}" = set; then :
17923 $as_echo_n "(cached) " >&6
17924 else
17925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17926 /* end confdefs.h. */
17928 #ifdef __TANDEM
17929 choke me
17930 #endif
17932 _ACEOF
17933 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17934 $EGREP "choke me" >/dev/null 2>&1; then :
17935 gl_cv_pragma_columns=yes
17936 else
17937 gl_cv_pragma_columns=no
17939 rm -f conftest*
17943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
17944 $as_echo "$gl_cv_pragma_columns" >&6; }
17945 if test $gl_cv_pragma_columns = yes; then
17946 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
17947 else
17948 PRAGMA_COLUMNS=
17955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
17956 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
17957 if test "${gl_cv_func_c99_strtold+set}" = set; then :
17958 $as_echo_n "(cached) " >&6
17959 else
17960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17961 /* end confdefs.h. */
17962 /* On HP-UX before 11.23, strtold returns a struct instead of
17963 long double. Reject implementations like that, by requiring
17964 compatibility with the C99 prototype. */
17965 #include <stdlib.h>
17966 static long double (*p) (char const *, char **) = strtold;
17967 static long double
17968 test (char const *nptr, char **endptr)
17970 long double r;
17971 r = strtold (nptr, endptr);
17972 return r;
17975 main ()
17977 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
17979 return 0;
17981 _ACEOF
17982 if ac_fn_c_try_link "$LINENO"; then :
17983 gl_cv_func_c99_strtold=yes
17984 else
17985 gl_cv_func_c99_strtold=no
17987 rm -f core conftest.err conftest.$ac_objext \
17988 conftest$ac_exeext conftest.$ac_ext
17990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
17991 $as_echo "$gl_cv_func_c99_strtold" >&6; }
17992 if test $gl_cv_func_c99_strtold = yes; then
17994 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18006 $as_echo_n "checking if environ is properly declared... " >&6; }
18007 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18008 $as_echo_n "(cached) " >&6
18009 else
18011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18012 /* end confdefs.h. */
18013 #if HAVE_UNISTD_H
18014 #include <unistd.h>
18015 #endif
18016 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18017 #include <stdlib.h>
18019 extern struct { int foo; } environ;
18021 main ()
18023 environ.foo = 1;
18025 return 0;
18027 _ACEOF
18028 if ac_fn_c_try_compile "$LINENO"; then :
18029 gt_cv_var_environ_declaration=no
18030 else
18031 gt_cv_var_environ_declaration=yes
18033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18037 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18038 if test $gt_cv_var_environ_declaration = yes; then
18040 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18045 if test $gt_cv_var_environ_declaration != yes; then
18046 HAVE_DECL_ENVIRON=0
18051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18052 $as_echo_n "checking for complete errno.h... " >&6; }
18053 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18054 $as_echo_n "(cached) " >&6
18055 else
18057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18058 /* end confdefs.h. */
18060 #include <errno.h>
18061 #if !defined ETXTBSY
18062 booboo
18063 #endif
18064 #if !defined ENOMSG
18065 booboo
18066 #endif
18067 #if !defined EIDRM
18068 booboo
18069 #endif
18070 #if !defined ENOLINK
18071 booboo
18072 #endif
18073 #if !defined EPROTO
18074 booboo
18075 #endif
18076 #if !defined EMULTIHOP
18077 booboo
18078 #endif
18079 #if !defined EBADMSG
18080 booboo
18081 #endif
18082 #if !defined EOVERFLOW
18083 booboo
18084 #endif
18085 #if !defined ENOTSUP
18086 booboo
18087 #endif
18088 #if !defined ENETRESET
18089 booboo
18090 #endif
18091 #if !defined ECONNABORTED
18092 booboo
18093 #endif
18094 #if !defined ESTALE
18095 booboo
18096 #endif
18097 #if !defined EDQUOT
18098 booboo
18099 #endif
18100 #if !defined ECANCELED
18101 booboo
18102 #endif
18103 #if !defined EOWNERDEAD
18104 booboo
18105 #endif
18106 #if !defined ENOTRECOVERABLE
18107 booboo
18108 #endif
18109 #if !defined EILSEQ
18110 booboo
18111 #endif
18113 _ACEOF
18114 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18115 $EGREP "booboo" >/dev/null 2>&1; then :
18116 gl_cv_header_errno_h_complete=no
18117 else
18118 gl_cv_header_errno_h_complete=yes
18120 rm -f conftest*
18124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18125 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18126 if test $gl_cv_header_errno_h_complete = yes; then
18127 ERRNO_H=''
18128 else
18137 if test $gl_cv_have_include_next = yes; then
18138 gl_cv_next_errno_h='<'errno.h'>'
18139 else
18140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18141 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18142 if test "${gl_cv_next_errno_h+set}" = set; then :
18143 $as_echo_n "(cached) " >&6
18144 else
18146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18147 /* end confdefs.h. */
18148 #include <errno.h>
18150 _ACEOF
18151 case "$host_os" in
18152 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18153 *) gl_absname_cpp="$ac_cpp" ;;
18154 esac
18156 case "$host_os" in
18157 mingw*)
18158 gl_dirsep_regex='[/\\]'
18161 gl_dirsep_regex='\/'
18163 esac
18164 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18166 gl_header_literal_regex=`echo 'errno.h' \
18167 | sed -e "$gl_make_literal_regex_sed"`
18168 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18169 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18170 s|^/[^/]|//&|
18174 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18175 sed -n "$gl_absolute_header_sed"`'"'
18179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18180 $as_echo "$gl_cv_next_errno_h" >&6; }
18182 NEXT_ERRNO_H=$gl_cv_next_errno_h
18184 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18185 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18186 gl_next_as_first_directive='<'errno.h'>'
18187 else
18188 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18189 gl_next_as_first_directive=$gl_cv_next_errno_h
18191 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18196 ERRNO_H='errno.h'
18199 if test -n "$ERRNO_H"; then
18200 GL_GENERATE_ERRNO_H_TRUE=
18201 GL_GENERATE_ERRNO_H_FALSE='#'
18202 else
18203 GL_GENERATE_ERRNO_H_TRUE='#'
18204 GL_GENERATE_ERRNO_H_FALSE=
18208 if test -n "$ERRNO_H"; then
18209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18210 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18211 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18212 $as_echo_n "(cached) " >&6
18213 else
18215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18216 /* end confdefs.h. */
18218 #include <errno.h>
18219 #ifdef EMULTIHOP
18221 #endif
18223 _ACEOF
18224 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18225 $EGREP "yes" >/dev/null 2>&1; then :
18226 gl_cv_header_errno_h_EMULTIHOP=yes
18227 else
18228 gl_cv_header_errno_h_EMULTIHOP=no
18230 rm -f conftest*
18232 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18234 /* end confdefs.h. */
18236 #define _XOPEN_SOURCE_EXTENDED 1
18237 #include <errno.h>
18238 #ifdef EMULTIHOP
18240 #endif
18242 _ACEOF
18243 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18244 $EGREP "yes" >/dev/null 2>&1; then :
18245 gl_cv_header_errno_h_EMULTIHOP=hidden
18247 rm -f conftest*
18249 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18250 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18251 #define _XOPEN_SOURCE_EXTENDED 1
18252 #include <errno.h>
18253 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18254 #include <stdio.h>
18255 #include <stdlib.h>
18256 "; then :
18264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18265 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18266 case $gl_cv_header_errno_h_EMULTIHOP in
18267 yes | no)
18268 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18271 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18273 esac
18279 if test -n "$ERRNO_H"; then
18280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18281 $as_echo_n "checking for ENOLINK value... " >&6; }
18282 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18283 $as_echo_n "(cached) " >&6
18284 else
18286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18287 /* end confdefs.h. */
18289 #include <errno.h>
18290 #ifdef ENOLINK
18292 #endif
18294 _ACEOF
18295 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18296 $EGREP "yes" >/dev/null 2>&1; then :
18297 gl_cv_header_errno_h_ENOLINK=yes
18298 else
18299 gl_cv_header_errno_h_ENOLINK=no
18301 rm -f conftest*
18303 if test $gl_cv_header_errno_h_ENOLINK = no; then
18304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18305 /* end confdefs.h. */
18307 #define _XOPEN_SOURCE_EXTENDED 1
18308 #include <errno.h>
18309 #ifdef ENOLINK
18311 #endif
18313 _ACEOF
18314 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18315 $EGREP "yes" >/dev/null 2>&1; then :
18316 gl_cv_header_errno_h_ENOLINK=hidden
18318 rm -f conftest*
18320 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18321 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18322 #define _XOPEN_SOURCE_EXTENDED 1
18323 #include <errno.h>
18324 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18325 #include <stdio.h>
18326 #include <stdlib.h>
18327 "; then :
18335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18336 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18337 case $gl_cv_header_errno_h_ENOLINK in
18338 yes | no)
18339 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18342 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18344 esac
18350 if test -n "$ERRNO_H"; then
18351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18352 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18353 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18354 $as_echo_n "(cached) " >&6
18355 else
18357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18358 /* end confdefs.h. */
18360 #include <errno.h>
18361 #ifdef EOVERFLOW
18363 #endif
18365 _ACEOF
18366 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18367 $EGREP "yes" >/dev/null 2>&1; then :
18368 gl_cv_header_errno_h_EOVERFLOW=yes
18369 else
18370 gl_cv_header_errno_h_EOVERFLOW=no
18372 rm -f conftest*
18374 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18376 /* end confdefs.h. */
18378 #define _XOPEN_SOURCE_EXTENDED 1
18379 #include <errno.h>
18380 #ifdef EOVERFLOW
18382 #endif
18384 _ACEOF
18385 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18386 $EGREP "yes" >/dev/null 2>&1; then :
18387 gl_cv_header_errno_h_EOVERFLOW=hidden
18389 rm -f conftest*
18391 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18392 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18393 #define _XOPEN_SOURCE_EXTENDED 1
18394 #include <errno.h>
18395 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18396 #include <stdio.h>
18397 #include <stdlib.h>
18398 "; then :
18406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18407 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18408 case $gl_cv_header_errno_h_EOVERFLOW in
18409 yes | no)
18410 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18413 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18415 esac
18429 GNULIB_FCNTL=0;
18430 GNULIB_NONBLOCKING=0;
18431 GNULIB_OPEN=0;
18432 GNULIB_OPENAT=0;
18433 HAVE_FCNTL=1;
18434 HAVE_OPENAT=1;
18435 REPLACE_FCNTL=0;
18436 REPLACE_OPEN=0;
18437 REPLACE_OPENAT=0;
18442 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18443 if test "x$ac_cv_type_mode_t" = x""yes; then :
18445 else
18447 cat >>confdefs.h <<_ACEOF
18448 #define mode_t int
18449 _ACEOF
18453 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18454 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18455 ac_have_decl=1
18456 else
18457 ac_have_decl=0
18460 cat >>confdefs.h <<_ACEOF
18461 #define HAVE_DECL_FDATASYNC $ac_have_decl
18462 _ACEOF
18466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18467 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18468 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18469 $as_echo_n "(cached) " >&6
18470 else
18471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18472 /* end confdefs.h. */
18474 #include <sys/types.h>
18475 #include <sys/stat.h>
18477 main ()
18479 struct stat s; s.st_dm_mode;
18481 return 0;
18483 _ACEOF
18484 if ac_fn_c_try_compile "$LINENO"; then :
18485 ac_cv_struct_st_dm_mode=yes
18486 else
18487 ac_cv_struct_st_dm_mode=no
18489 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
18492 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
18494 if test $ac_cv_struct_st_dm_mode = yes; then
18496 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
18501 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
18502 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
18503 ac_have_decl=1
18504 else
18505 ac_have_decl=0
18508 cat >>confdefs.h <<_ACEOF
18509 #define HAVE_DECL_STRMODE $ac_have_decl
18510 _ACEOF
18517 GNULIB_FCHMODAT=0;
18518 GNULIB_FSTAT=0;
18519 GNULIB_FSTATAT=0;
18520 GNULIB_FUTIMENS=0;
18521 GNULIB_LCHMOD=0;
18522 GNULIB_LSTAT=0;
18523 GNULIB_MKDIRAT=0;
18524 GNULIB_MKFIFO=0;
18525 GNULIB_MKFIFOAT=0;
18526 GNULIB_MKNOD=0;
18527 GNULIB_MKNODAT=0;
18528 GNULIB_STAT=0;
18529 GNULIB_UTIMENSAT=0;
18530 HAVE_FCHMODAT=1;
18531 HAVE_FSTATAT=1;
18532 HAVE_FUTIMENS=1;
18533 HAVE_LCHMOD=1;
18534 HAVE_LSTAT=1;
18535 HAVE_MKDIRAT=1;
18536 HAVE_MKFIFO=1;
18537 HAVE_MKFIFOAT=1;
18538 HAVE_MKNOD=1;
18539 HAVE_MKNODAT=1;
18540 HAVE_UTIMENSAT=1;
18541 REPLACE_FSTAT=0;
18542 REPLACE_FSTATAT=0;
18543 REPLACE_FUTIMENS=0;
18544 REPLACE_LSTAT=0;
18545 REPLACE_MKDIR=0;
18546 REPLACE_MKFIFO=0;
18547 REPLACE_MKNOD=0;
18548 REPLACE_STAT=0;
18549 REPLACE_UTIMENSAT=0;
18552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18553 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18554 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18555 $as_echo_n "(cached) " >&6
18556 else
18557 rm -f conftest.sym conftest.file
18558 echo >conftest.file
18559 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18560 if test "$cross_compiling" = yes; then :
18561 case "$host_os" in
18562 # Guess yes on glibc systems.
18563 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18564 # If we don't know, assume the worst.
18565 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18566 esac
18568 else
18569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18570 /* end confdefs.h. */
18571 $ac_includes_default
18573 main ()
18575 struct stat sbuf;
18576 /* Linux will dereference the symlink and fail, as required by
18577 POSIX. That is better in the sense that it means we will not
18578 have to compile and use the lstat wrapper. */
18579 return lstat ("conftest.sym/", &sbuf) == 0;
18582 return 0;
18584 _ACEOF
18585 if ac_fn_c_try_run "$LINENO"; then :
18586 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18587 else
18588 gl_cv_func_lstat_dereferences_slashed_symlink=no
18590 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18591 conftest.$ac_objext conftest.beam conftest.$ac_ext
18594 else
18595 # If the 'ln -s' command failed, then we probably don't even
18596 # have an lstat function.
18597 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18599 rm -f conftest.sym conftest.file
18602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18603 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18604 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18605 *yes)
18607 cat >>confdefs.h <<_ACEOF
18608 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18609 _ACEOF
18612 esac
18619 GNULIB__EXIT=0;
18620 GNULIB_ATOLL=0;
18621 GNULIB_CALLOC_POSIX=0;
18622 GNULIB_CANONICALIZE_FILE_NAME=0;
18623 GNULIB_GETLOADAVG=0;
18624 GNULIB_GETSUBOPT=0;
18625 GNULIB_GRANTPT=0;
18626 GNULIB_MALLOC_POSIX=0;
18627 GNULIB_MBTOWC=0;
18628 GNULIB_MKDTEMP=0;
18629 GNULIB_MKOSTEMP=0;
18630 GNULIB_MKOSTEMPS=0;
18631 GNULIB_MKSTEMP=0;
18632 GNULIB_MKSTEMPS=0;
18633 GNULIB_POSIX_OPENPT=0;
18634 GNULIB_PTSNAME=0;
18635 GNULIB_PTSNAME_R=0;
18636 GNULIB_PUTENV=0;
18637 GNULIB_RANDOM=0;
18638 GNULIB_RANDOM_R=0;
18639 GNULIB_REALLOC_POSIX=0;
18640 GNULIB_REALPATH=0;
18641 GNULIB_RPMATCH=0;
18642 GNULIB_SECURE_GETENV=0;
18643 GNULIB_SETENV=0;
18644 GNULIB_STRTOD=0;
18645 GNULIB_STRTOLL=0;
18646 GNULIB_STRTOULL=0;
18647 GNULIB_SYSTEM_POSIX=0;
18648 GNULIB_UNLOCKPT=0;
18649 GNULIB_UNSETENV=0;
18650 GNULIB_WCTOMB=0;
18651 HAVE__EXIT=1;
18652 HAVE_ATOLL=1;
18653 HAVE_CANONICALIZE_FILE_NAME=1;
18654 HAVE_DECL_GETLOADAVG=1;
18655 HAVE_GETSUBOPT=1;
18656 HAVE_GRANTPT=1;
18657 HAVE_MKDTEMP=1;
18658 HAVE_MKOSTEMP=1;
18659 HAVE_MKOSTEMPS=1;
18660 HAVE_MKSTEMP=1;
18661 HAVE_MKSTEMPS=1;
18662 HAVE_POSIX_OPENPT=1;
18663 HAVE_PTSNAME=1;
18664 HAVE_PTSNAME_R=1;
18665 HAVE_RANDOM=1;
18666 HAVE_RANDOM_H=1;
18667 HAVE_RANDOM_R=1;
18668 HAVE_REALPATH=1;
18669 HAVE_RPMATCH=1;
18670 HAVE_SECURE_GETENV=1;
18671 HAVE_SETENV=1;
18672 HAVE_DECL_SETENV=1;
18673 HAVE_STRTOD=1;
18674 HAVE_STRTOLL=1;
18675 HAVE_STRTOULL=1;
18676 HAVE_STRUCT_RANDOM_DATA=1;
18677 HAVE_SYS_LOADAVG_H=0;
18678 HAVE_UNLOCKPT=1;
18679 HAVE_DECL_UNSETENV=1;
18680 REPLACE_CALLOC=0;
18681 REPLACE_CANONICALIZE_FILE_NAME=0;
18682 REPLACE_MALLOC=0;
18683 REPLACE_MBTOWC=0;
18684 REPLACE_MKSTEMP=0;
18685 REPLACE_PTSNAME=0;
18686 REPLACE_PTSNAME_R=0;
18687 REPLACE_PUTENV=0;
18688 REPLACE_RANDOM_R=0;
18689 REPLACE_REALLOC=0;
18690 REPLACE_REALPATH=0;
18691 REPLACE_SETENV=0;
18692 REPLACE_STRTOD=0;
18693 REPLACE_UNSETENV=0;
18694 REPLACE_WCTOMB=0;
18711 if test $gl_cv_have_include_next = yes; then
18712 gl_cv_next_getopt_h='<'getopt.h'>'
18713 else
18714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
18715 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
18716 if test "${gl_cv_next_getopt_h+set}" = set; then :
18717 $as_echo_n "(cached) " >&6
18718 else
18720 if test $ac_cv_header_getopt_h = yes; then
18723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18724 /* end confdefs.h. */
18725 #include <getopt.h>
18727 _ACEOF
18728 case "$host_os" in
18729 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18730 *) gl_absname_cpp="$ac_cpp" ;;
18731 esac
18733 case "$host_os" in
18734 mingw*)
18735 gl_dirsep_regex='[/\\]'
18738 gl_dirsep_regex='\/'
18740 esac
18741 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18743 gl_header_literal_regex=`echo 'getopt.h' \
18744 | sed -e "$gl_make_literal_regex_sed"`
18745 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18746 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18747 s|^/[^/]|//&|
18751 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18752 sed -n "$gl_absolute_header_sed"`'"'
18753 else
18754 gl_cv_next_getopt_h='<'getopt.h'>'
18759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
18760 $as_echo "$gl_cv_next_getopt_h" >&6; }
18762 NEXT_GETOPT_H=$gl_cv_next_getopt_h
18764 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18765 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18766 gl_next_as_first_directive='<'getopt.h'>'
18767 else
18768 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18769 gl_next_as_first_directive=$gl_cv_next_getopt_h
18771 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
18776 if test $ac_cv_header_getopt_h = yes; then
18777 HAVE_GETOPT_H=1
18778 else
18779 HAVE_GETOPT_H=0
18783 gl_replace_getopt=
18785 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18786 for ac_header in getopt.h
18787 do :
18788 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
18789 if test "x$ac_cv_header_getopt_h" = x""yes; then :
18790 cat >>confdefs.h <<_ACEOF
18791 #define HAVE_GETOPT_H 1
18792 _ACEOF
18794 else
18795 gl_replace_getopt=yes
18798 done
18802 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18803 for ac_func in getopt_long_only
18804 do :
18805 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
18806 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
18807 cat >>confdefs.h <<_ACEOF
18808 #define HAVE_GETOPT_LONG_ONLY 1
18809 _ACEOF
18811 else
18812 gl_replace_getopt=yes
18814 done
18818 if test -z "$gl_replace_getopt"; then
18819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
18820 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
18821 if test "${gl_cv_func_getopt_posix+set}" = set; then :
18822 $as_echo_n "(cached) " >&6
18823 else
18825 if test $cross_compiling = no; then
18826 if test "$cross_compiling" = yes; then :
18827 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18828 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18829 as_fn_error "cannot run test program while cross compiling
18830 See \`config.log' for more details." "$LINENO" 5; }
18831 else
18832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18833 /* end confdefs.h. */
18835 #include <unistd.h>
18836 #include <stdlib.h>
18837 #include <string.h>
18840 main ()
18842 static char program[] = "program";
18843 static char a[] = "-a";
18844 static char foo[] = "foo";
18845 static char bar[] = "bar";
18846 char *argv[] = { program, a, foo, bar, NULL };
18847 int c;
18849 c = getopt (4, argv, "ab");
18850 if (!(c == 'a'))
18851 return 1;
18852 c = getopt (4, argv, "ab");
18853 if (!(c == -1))
18854 return 2;
18855 if (!(optind == 2))
18856 return 3;
18857 return 0;
18860 _ACEOF
18861 if ac_fn_c_try_run "$LINENO"; then :
18862 gl_cv_func_getopt_posix=maybe
18863 else
18864 gl_cv_func_getopt_posix=no
18866 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18867 conftest.$ac_objext conftest.beam conftest.$ac_ext
18870 if test $gl_cv_func_getopt_posix = maybe; then
18871 if test "$cross_compiling" = yes; then :
18872 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18873 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18874 as_fn_error "cannot run test program while cross compiling
18875 See \`config.log' for more details." "$LINENO" 5; }
18876 else
18877 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18878 /* end confdefs.h. */
18880 #include <unistd.h>
18881 #include <stdlib.h>
18882 #include <string.h>
18885 main ()
18887 static char program[] = "program";
18888 static char donald[] = "donald";
18889 static char p[] = "-p";
18890 static char billy[] = "billy";
18891 static char duck[] = "duck";
18892 static char a[] = "-a";
18893 static char bar[] = "bar";
18894 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
18895 int c;
18897 c = getopt (7, argv, "+abp:q:");
18898 if (!(c == -1))
18899 return 4;
18900 if (!(strcmp (argv[0], "program") == 0))
18901 return 5;
18902 if (!(strcmp (argv[1], "donald") == 0))
18903 return 6;
18904 if (!(strcmp (argv[2], "-p") == 0))
18905 return 7;
18906 if (!(strcmp (argv[3], "billy") == 0))
18907 return 8;
18908 if (!(strcmp (argv[4], "duck") == 0))
18909 return 9;
18910 if (!(strcmp (argv[5], "-a") == 0))
18911 return 10;
18912 if (!(strcmp (argv[6], "bar") == 0))
18913 return 11;
18914 if (!(optind == 1))
18915 return 12;
18916 return 0;
18919 _ACEOF
18920 if ac_fn_c_try_run "$LINENO"; then :
18921 gl_cv_func_getopt_posix=maybe
18922 else
18923 gl_cv_func_getopt_posix=no
18925 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18926 conftest.$ac_objext conftest.beam conftest.$ac_ext
18930 if test $gl_cv_func_getopt_posix = maybe; then
18931 if test "$cross_compiling" = yes; then :
18932 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18933 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18934 as_fn_error "cannot run test program while cross compiling
18935 See \`config.log' for more details." "$LINENO" 5; }
18936 else
18937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18938 /* end confdefs.h. */
18940 #include <unistd.h>
18941 #include <stdlib.h>
18942 #include <string.h>
18945 main ()
18947 static char program[] = "program";
18948 static char ab[] = "-ab";
18949 char *argv[3] = { program, ab, NULL };
18950 if (getopt (2, argv, "ab:") != 'a')
18951 return 13;
18952 if (getopt (2, argv, "ab:") != '?')
18953 return 14;
18954 if (optopt != 'b')
18955 return 15;
18956 if (optind != 2)
18957 return 16;
18958 return 0;
18961 _ACEOF
18962 if ac_fn_c_try_run "$LINENO"; then :
18963 gl_cv_func_getopt_posix=yes
18964 else
18965 gl_cv_func_getopt_posix=no
18967 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18968 conftest.$ac_objext conftest.beam conftest.$ac_ext
18972 else
18973 case "$host_os" in
18974 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
18975 *) gl_cv_func_getopt_posix="guessing yes";;
18976 esac
18980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
18981 $as_echo "$gl_cv_func_getopt_posix" >&6; }
18982 case "$gl_cv_func_getopt_posix" in
18983 *no) gl_replace_getopt=yes ;;
18984 esac
18987 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
18989 $as_echo_n "checking for working GNU getopt function... " >&6; }
18990 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
18991 $as_echo_n "(cached) " >&6
18992 else
18993 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
18994 # optstring is necessary for programs like m4 that have POSIX-mandated
18995 # semantics for supporting options interspersed with files.
18996 # Also, since getopt_long is a GNU extension, we require optind=0.
18997 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
18998 # so take care to revert to the correct (non-)export state.
18999 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19000 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19001 xx) gl_had_POSIXLY_CORRECT=exported ;;
19002 x) gl_had_POSIXLY_CORRECT=yes ;;
19003 *) gl_had_POSIXLY_CORRECT= ;;
19004 esac
19005 POSIXLY_CORRECT=1
19006 export POSIXLY_CORRECT
19007 if test "$cross_compiling" = yes; then :
19008 gl_cv_func_getopt_gnu="guessing no"
19010 else
19011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19012 /* end confdefs.h. */
19013 #include <getopt.h>
19014 #include <stddef.h>
19015 #include <string.h>
19017 #include <stdlib.h>
19018 #if defined __MACH__ && defined __APPLE__
19019 /* Avoid a crash on Mac OS X. */
19020 #include <mach/mach.h>
19021 #include <mach/mach_error.h>
19022 #include <mach/thread_status.h>
19023 #include <mach/exception.h>
19024 #include <mach/task.h>
19025 #include <pthread.h>
19026 /* The exception port on which our thread listens. */
19027 static mach_port_t our_exception_port;
19028 /* The main function of the thread listening for exceptions of type
19029 EXC_BAD_ACCESS. */
19030 static void *
19031 mach_exception_thread (void *arg)
19033 /* Buffer for a message to be received. */
19034 struct {
19035 mach_msg_header_t head;
19036 mach_msg_body_t msgh_body;
19037 char data[1024];
19038 } msg;
19039 mach_msg_return_t retval;
19040 /* Wait for a message on the exception port. */
19041 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19042 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19043 if (retval != MACH_MSG_SUCCESS)
19044 abort ();
19045 exit (1);
19047 static void
19048 nocrash_init (void)
19050 mach_port_t self = mach_task_self ();
19051 /* Allocate a port on which the thread shall listen for exceptions. */
19052 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19053 == KERN_SUCCESS) {
19054 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19055 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19056 MACH_MSG_TYPE_MAKE_SEND)
19057 == KERN_SUCCESS) {
19058 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19059 for us. */
19060 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19061 /* Create the thread listening on the exception port. */
19062 pthread_attr_t attr;
19063 pthread_t thread;
19064 if (pthread_attr_init (&attr) == 0
19065 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19066 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19067 pthread_attr_destroy (&attr);
19068 /* Replace the exception port info for these exceptions with our own.
19069 Note that we replace the exception port for the entire task, not only
19070 for a particular thread. This has the effect that when our exception
19071 port gets the message, the thread specific exception port has already
19072 been asked, and we don't need to bother about it.
19073 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19074 task_set_exception_ports (self, mask, our_exception_port,
19075 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19080 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19081 /* Avoid a crash on native Windows. */
19082 #define WIN32_LEAN_AND_MEAN
19083 #include <windows.h>
19084 #include <winerror.h>
19085 static LONG WINAPI
19086 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19088 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19090 case EXCEPTION_ACCESS_VIOLATION:
19091 case EXCEPTION_IN_PAGE_ERROR:
19092 case EXCEPTION_STACK_OVERFLOW:
19093 case EXCEPTION_GUARD_PAGE:
19094 case EXCEPTION_PRIV_INSTRUCTION:
19095 case EXCEPTION_ILLEGAL_INSTRUCTION:
19096 case EXCEPTION_DATATYPE_MISALIGNMENT:
19097 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19098 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19099 exit (1);
19101 return EXCEPTION_CONTINUE_SEARCH;
19103 static void
19104 nocrash_init (void)
19106 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19108 #else
19109 /* Avoid a crash on POSIX systems. */
19110 #include <signal.h>
19111 /* A POSIX signal handler. */
19112 static void
19113 exception_handler (int sig)
19115 exit (1);
19117 static void
19118 nocrash_init (void)
19120 #ifdef SIGSEGV
19121 signal (SIGSEGV, exception_handler);
19122 #endif
19123 #ifdef SIGBUS
19124 signal (SIGBUS, exception_handler);
19125 #endif
19127 #endif
19131 main ()
19134 int result = 0;
19136 nocrash_init();
19138 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19139 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19140 OSF/1 5.1, Solaris 10. */
19142 static char conftest[] = "conftest";
19143 static char plus[] = "-+";
19144 char *argv[3] = { conftest, plus, NULL };
19145 opterr = 0;
19146 if (getopt (2, argv, "+a") != '?')
19147 result |= 1;
19149 /* This code succeeds on glibc 2.8, mingw,
19150 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19151 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19153 static char program[] = "program";
19154 static char p[] = "-p";
19155 static char foo[] = "foo";
19156 static char bar[] = "bar";
19157 char *argv[] = { program, p, foo, bar, NULL };
19159 optind = 1;
19160 if (getopt (4, argv, "p::") != 'p')
19161 result |= 2;
19162 else if (optarg != NULL)
19163 result |= 4;
19164 else if (getopt (4, argv, "p::") != -1)
19165 result |= 6;
19166 else if (optind != 2)
19167 result |= 8;
19169 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19171 static char program[] = "program";
19172 static char foo[] = "foo";
19173 static char p[] = "-p";
19174 char *argv[] = { program, foo, p, NULL };
19175 optind = 0;
19176 if (getopt (3, argv, "-p") != 1)
19177 result |= 16;
19178 else if (getopt (3, argv, "-p") != 'p')
19179 result |= 16;
19181 /* This code fails on glibc 2.11. */
19183 static char program[] = "program";
19184 static char b[] = "-b";
19185 static char a[] = "-a";
19186 char *argv[] = { program, b, a, NULL };
19187 optind = opterr = 0;
19188 if (getopt (3, argv, "+:a:b") != 'b')
19189 result |= 32;
19190 else if (getopt (3, argv, "+:a:b") != ':')
19191 result |= 32;
19193 /* This code dumps core on glibc 2.14. */
19195 static char program[] = "program";
19196 static char w[] = "-W";
19197 static char dummy[] = "dummy";
19198 char *argv[] = { program, w, dummy, NULL };
19199 optind = opterr = 1;
19200 if (getopt (3, argv, "W;") != 'W')
19201 result |= 64;
19203 return result;
19206 return 0;
19208 _ACEOF
19209 if ac_fn_c_try_run "$LINENO"; then :
19210 gl_cv_func_getopt_gnu=yes
19211 else
19212 gl_cv_func_getopt_gnu=no
19214 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19215 conftest.$ac_objext conftest.beam conftest.$ac_ext
19218 case $gl_had_POSIXLY_CORRECT in
19219 exported) ;;
19220 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19221 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19222 esac
19225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19226 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19227 if test "$gl_cv_func_getopt_gnu" != yes; then
19228 gl_replace_getopt=yes
19229 else
19230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19231 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19232 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19233 $as_echo_n "(cached) " >&6
19234 else
19235 if test "$cross_compiling" = yes; then :
19236 case "$host_os" in
19237 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19238 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19239 esac
19241 else
19242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19243 /* end confdefs.h. */
19244 #include <getopt.h>
19245 #include <stddef.h>
19246 #include <string.h>
19249 main ()
19251 static const struct option long_options[] =
19253 { "xtremely-",no_argument, NULL, 1003 },
19254 { "xtra", no_argument, NULL, 1001 },
19255 { "xtreme", no_argument, NULL, 1002 },
19256 { "xtremely", no_argument, NULL, 1003 },
19257 { NULL, 0, NULL, 0 }
19259 /* This code fails on OpenBSD 5.0. */
19261 static char program[] = "program";
19262 static char xtremel[] = "--xtremel";
19263 char *argv[] = { program, xtremel, NULL };
19264 int option_index;
19265 optind = 1; opterr = 0;
19266 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19267 return 1;
19269 return 0;
19272 return 0;
19274 _ACEOF
19275 if ac_fn_c_try_run "$LINENO"; then :
19276 gl_cv_func_getopt_long_gnu=yes
19277 else
19278 gl_cv_func_getopt_long_gnu=no
19280 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19281 conftest.$ac_objext conftest.beam conftest.$ac_ext
19286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19287 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19288 case "$gl_cv_func_getopt_long_gnu" in
19289 *yes) ;;
19290 *) gl_replace_getopt=yes ;;
19291 esac
19300 REPLACE_GETOPT=0
19301 if test -n "$gl_replace_getopt"; then
19302 REPLACE_GETOPT=1
19305 if test $REPLACE_GETOPT = 1; then
19307 GETOPT_H=getopt.h
19309 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19315 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19316 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19317 ac_have_decl=1
19318 else
19319 ac_have_decl=0
19322 cat >>confdefs.h <<_ACEOF
19323 #define HAVE_DECL_GETENV $ac_have_decl
19324 _ACEOF
19331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19332 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19333 if test "${ac_cv_c_restrict+set}" = set; then :
19334 $as_echo_n "(cached) " >&6
19335 else
19336 ac_cv_c_restrict=no
19337 # The order here caters to the fact that C++ does not require restrict.
19338 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19340 /* end confdefs.h. */
19341 typedef int * int_ptr;
19342 int foo (int_ptr $ac_kw ip) {
19343 return ip[0];
19346 main ()
19348 int s[1];
19349 int * $ac_kw t = s;
19350 t[0] = 0;
19351 return foo(t)
19353 return 0;
19355 _ACEOF
19356 if ac_fn_c_try_compile "$LINENO"; then :
19357 ac_cv_c_restrict=$ac_kw
19359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19360 test "$ac_cv_c_restrict" != no && break
19361 done
19364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19365 $as_echo "$ac_cv_c_restrict" >&6; }
19367 case $ac_cv_c_restrict in
19368 restrict) ;;
19369 no) $as_echo "#define restrict /**/" >>confdefs.h
19371 *) cat >>confdefs.h <<_ACEOF
19372 #define restrict $ac_cv_c_restrict
19373 _ACEOF
19375 esac
19378 GNULIB_GETTIMEOFDAY=0;
19379 HAVE_GETTIMEOFDAY=1;
19380 HAVE_STRUCT_TIMEVAL=1;
19381 HAVE_SYS_TIME_H=1;
19382 REPLACE_GETTIMEOFDAY=0;
19383 REPLACE_STRUCT_TIMEVAL=0;
19400 if test $gl_cv_have_include_next = yes; then
19401 gl_cv_next_sys_time_h='<'sys/time.h'>'
19402 else
19403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19404 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19405 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19406 $as_echo_n "(cached) " >&6
19407 else
19409 if test $ac_cv_header_sys_time_h = yes; then
19412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19413 /* end confdefs.h. */
19414 #include <sys/time.h>
19416 _ACEOF
19417 case "$host_os" in
19418 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19419 *) gl_absname_cpp="$ac_cpp" ;;
19420 esac
19422 case "$host_os" in
19423 mingw*)
19424 gl_dirsep_regex='[/\\]'
19427 gl_dirsep_regex='\/'
19429 esac
19430 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19432 gl_header_literal_regex=`echo 'sys/time.h' \
19433 | sed -e "$gl_make_literal_regex_sed"`
19434 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19435 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19436 s|^/[^/]|//&|
19440 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19441 sed -n "$gl_absolute_header_sed"`'"'
19442 else
19443 gl_cv_next_sys_time_h='<'sys/time.h'>'
19448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19449 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19451 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19453 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19454 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19455 gl_next_as_first_directive='<'sys/time.h'>'
19456 else
19457 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19458 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19460 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19466 if test $ac_cv_header_sys_time_h != yes; then
19467 HAVE_SYS_TIME_H=0
19474 if test $ac_cv_header_sys_socket_h != yes; then
19475 for ac_header in winsock2.h
19476 do :
19477 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19478 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19479 cat >>confdefs.h <<_ACEOF
19480 #define HAVE_WINSOCK2_H 1
19481 _ACEOF
19485 done
19488 if test "$ac_cv_header_winsock2_h" = yes; then
19489 HAVE_WINSOCK2_H=1
19490 UNISTD_H_HAVE_WINSOCK2_H=1
19491 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19492 else
19493 HAVE_WINSOCK2_H=0
19497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
19498 $as_echo_n "checking for struct timeval... " >&6; }
19499 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
19500 $as_echo_n "(cached) " >&6
19501 else
19502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19503 /* end confdefs.h. */
19504 #if HAVE_SYS_TIME_H
19505 #include <sys/time.h>
19506 #endif
19507 #include <time.h>
19508 #if HAVE_WINSOCK2_H
19509 # include <winsock2.h>
19510 #endif
19513 main ()
19515 static struct timeval x; x.tv_sec = x.tv_usec;
19517 return 0;
19519 _ACEOF
19520 if ac_fn_c_try_compile "$LINENO"; then :
19521 gl_cv_sys_struct_timeval=yes
19522 else
19523 gl_cv_sys_struct_timeval=no
19525 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
19529 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
19530 if test $gl_cv_sys_struct_timeval != yes; then
19531 HAVE_STRUCT_TIMEVAL=0
19532 else
19533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
19534 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
19535 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
19536 $as_echo_n "(cached) " >&6
19537 else
19538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19539 /* end confdefs.h. */
19540 #if HAVE_SYS_TIME_H
19541 #include <sys/time.h>
19542 #endif
19543 #include <time.h>
19544 #if HAVE_WINSOCK2_H
19545 # include <winsock2.h>
19546 #endif
19549 main ()
19551 static struct timeval x;
19552 typedef int verify_tv_sec_type[
19553 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
19557 return 0;
19559 _ACEOF
19560 if ac_fn_c_try_compile "$LINENO"; then :
19561 gl_cv_sys_struct_timeval_tv_sec=yes
19562 else
19563 gl_cv_sys_struct_timeval_tv_sec=no
19565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
19569 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
19570 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
19571 REPLACE_STRUCT_TIMEVAL=1
19581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
19582 $as_echo_n "checking for unsigned long long int... " >&6; }
19583 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
19584 $as_echo_n "(cached) " >&6
19585 else
19586 ac_cv_type_unsigned_long_long_int=yes
19587 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19589 /* end confdefs.h. */
19591 /* For now, do not test the preprocessor; as of 2007 there are too many
19592 implementations with broken preprocessors. Perhaps this can
19593 be revisited in 2012. In the meantime, code should not expect
19594 #if to work with literals wider than 32 bits. */
19595 /* Test literals. */
19596 long long int ll = 9223372036854775807ll;
19597 long long int nll = -9223372036854775807LL;
19598 unsigned long long int ull = 18446744073709551615ULL;
19599 /* Test constant expressions. */
19600 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
19601 ? 1 : -1)];
19602 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
19603 ? 1 : -1)];
19604 int i = 63;
19606 main ()
19608 /* Test availability of runtime routines for shift and division. */
19609 long long int llmax = 9223372036854775807ll;
19610 unsigned long long int ullmax = 18446744073709551615ull;
19611 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
19612 | (llmax / ll) | (llmax % ll)
19613 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
19614 | (ullmax / ull) | (ullmax % ull));
19616 return 0;
19619 _ACEOF
19620 if ac_fn_c_try_link "$LINENO"; then :
19622 else
19623 ac_cv_type_unsigned_long_long_int=no
19625 rm -f core conftest.err conftest.$ac_objext \
19626 conftest$ac_exeext conftest.$ac_ext
19629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
19630 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
19631 if test $ac_cv_type_unsigned_long_long_int = yes; then
19633 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
19639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
19640 $as_echo_n "checking for long long int... " >&6; }
19641 if test "${ac_cv_type_long_long_int+set}" = set; then :
19642 $as_echo_n "(cached) " >&6
19643 else
19644 ac_cv_type_long_long_int=yes
19645 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19646 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
19647 if test $ac_cv_type_long_long_int = yes; then
19648 if test "$cross_compiling" = yes; then :
19650 else
19651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19652 /* end confdefs.h. */
19653 #include <limits.h>
19654 #ifndef LLONG_MAX
19655 # define HALF \
19656 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
19657 # define LLONG_MAX (HALF - 1 + HALF)
19658 #endif
19660 main ()
19662 long long int n = 1;
19663 int i;
19664 for (i = 0; ; i++)
19666 long long int m = n << i;
19667 if (m >> i != n)
19668 return 1;
19669 if (LLONG_MAX / 2 < m)
19670 break;
19672 return 0;
19674 return 0;
19676 _ACEOF
19677 if ac_fn_c_try_run "$LINENO"; then :
19679 else
19680 ac_cv_type_long_long_int=no
19682 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19683 conftest.$ac_objext conftest.beam conftest.$ac_ext
19689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
19690 $as_echo "$ac_cv_type_long_long_int" >&6; }
19691 if test $ac_cv_type_long_long_int = yes; then
19693 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
19702 gl_cv_c_multiarch=no
19703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19704 /* end confdefs.h. */
19705 #ifndef __APPLE_CC__
19706 not a universal capable compiler
19707 #endif
19708 typedef int dummy;
19710 _ACEOF
19711 if ac_fn_c_try_compile "$LINENO"; then :
19713 arch=
19714 prev=
19715 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
19716 if test -n "$prev"; then
19717 case $word in
19718 i?86 | x86_64 | ppc | ppc64)
19719 if test -z "$arch" || test "$arch" = "$word"; then
19720 arch="$word"
19721 else
19722 gl_cv_c_multiarch=yes
19725 esac
19726 prev=
19727 else
19728 if test "x$word" = "x-arch"; then
19729 prev=arch
19732 done
19735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19736 if test $gl_cv_c_multiarch = yes; then
19737 APPLE_UNIVERSAL_BUILD=1
19738 else
19739 APPLE_UNIVERSAL_BUILD=0
19746 if test $ac_cv_type_long_long_int = yes; then
19747 HAVE_LONG_LONG_INT=1
19748 else
19749 HAVE_LONG_LONG_INT=0
19753 if test $ac_cv_type_unsigned_long_long_int = yes; then
19754 HAVE_UNSIGNED_LONG_LONG_INT=1
19755 else
19756 HAVE_UNSIGNED_LONG_LONG_INT=0
19761 if test $ac_cv_header_wchar_h = yes; then
19762 HAVE_WCHAR_H=1
19763 else
19764 HAVE_WCHAR_H=0
19768 if test $ac_cv_header_inttypes_h = yes; then
19769 HAVE_INTTYPES_H=1
19770 else
19771 HAVE_INTTYPES_H=0
19775 if test $ac_cv_header_sys_types_h = yes; then
19776 HAVE_SYS_TYPES_H=1
19777 else
19778 HAVE_SYS_TYPES_H=0
19791 if test $gl_cv_have_include_next = yes; then
19792 gl_cv_next_stdint_h='<'stdint.h'>'
19793 else
19794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
19795 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
19796 if test "${gl_cv_next_stdint_h+set}" = set; then :
19797 $as_echo_n "(cached) " >&6
19798 else
19800 if test $ac_cv_header_stdint_h = yes; then
19803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19804 /* end confdefs.h. */
19805 #include <stdint.h>
19807 _ACEOF
19808 case "$host_os" in
19809 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19810 *) gl_absname_cpp="$ac_cpp" ;;
19811 esac
19813 case "$host_os" in
19814 mingw*)
19815 gl_dirsep_regex='[/\\]'
19818 gl_dirsep_regex='\/'
19820 esac
19821 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19823 gl_header_literal_regex=`echo 'stdint.h' \
19824 | sed -e "$gl_make_literal_regex_sed"`
19825 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19826 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19827 s|^/[^/]|//&|
19831 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19832 sed -n "$gl_absolute_header_sed"`'"'
19833 else
19834 gl_cv_next_stdint_h='<'stdint.h'>'
19839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
19840 $as_echo "$gl_cv_next_stdint_h" >&6; }
19842 NEXT_STDINT_H=$gl_cv_next_stdint_h
19844 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19845 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19846 gl_next_as_first_directive='<'stdint.h'>'
19847 else
19848 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19849 gl_next_as_first_directive=$gl_cv_next_stdint_h
19851 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
19856 if test $ac_cv_header_stdint_h = yes; then
19857 HAVE_STDINT_H=1
19858 else
19859 HAVE_STDINT_H=0
19863 if test $ac_cv_header_stdint_h = yes; then
19864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
19865 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
19866 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
19867 $as_echo_n "(cached) " >&6
19868 else
19869 gl_cv_header_working_stdint_h=no
19870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19871 /* end confdefs.h. */
19874 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
19875 #include <stdint.h>
19876 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
19877 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
19878 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
19879 #endif
19882 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19883 included before <wchar.h>. */
19884 #include <stddef.h>
19885 #include <signal.h>
19886 #if HAVE_WCHAR_H
19887 # include <stdio.h>
19888 # include <time.h>
19889 # include <wchar.h>
19890 #endif
19893 #ifdef INT8_MAX
19894 int8_t a1 = INT8_MAX;
19895 int8_t a1min = INT8_MIN;
19896 #endif
19897 #ifdef INT16_MAX
19898 int16_t a2 = INT16_MAX;
19899 int16_t a2min = INT16_MIN;
19900 #endif
19901 #ifdef INT32_MAX
19902 int32_t a3 = INT32_MAX;
19903 int32_t a3min = INT32_MIN;
19904 #endif
19905 #ifdef INT64_MAX
19906 int64_t a4 = INT64_MAX;
19907 int64_t a4min = INT64_MIN;
19908 #endif
19909 #ifdef UINT8_MAX
19910 uint8_t b1 = UINT8_MAX;
19911 #else
19912 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
19913 #endif
19914 #ifdef UINT16_MAX
19915 uint16_t b2 = UINT16_MAX;
19916 #endif
19917 #ifdef UINT32_MAX
19918 uint32_t b3 = UINT32_MAX;
19919 #endif
19920 #ifdef UINT64_MAX
19921 uint64_t b4 = UINT64_MAX;
19922 #endif
19923 int_least8_t c1 = INT8_C (0x7f);
19924 int_least8_t c1max = INT_LEAST8_MAX;
19925 int_least8_t c1min = INT_LEAST8_MIN;
19926 int_least16_t c2 = INT16_C (0x7fff);
19927 int_least16_t c2max = INT_LEAST16_MAX;
19928 int_least16_t c2min = INT_LEAST16_MIN;
19929 int_least32_t c3 = INT32_C (0x7fffffff);
19930 int_least32_t c3max = INT_LEAST32_MAX;
19931 int_least32_t c3min = INT_LEAST32_MIN;
19932 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
19933 int_least64_t c4max = INT_LEAST64_MAX;
19934 int_least64_t c4min = INT_LEAST64_MIN;
19935 uint_least8_t d1 = UINT8_C (0xff);
19936 uint_least8_t d1max = UINT_LEAST8_MAX;
19937 uint_least16_t d2 = UINT16_C (0xffff);
19938 uint_least16_t d2max = UINT_LEAST16_MAX;
19939 uint_least32_t d3 = UINT32_C (0xffffffff);
19940 uint_least32_t d3max = UINT_LEAST32_MAX;
19941 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
19942 uint_least64_t d4max = UINT_LEAST64_MAX;
19943 int_fast8_t e1 = INT_FAST8_MAX;
19944 int_fast8_t e1min = INT_FAST8_MIN;
19945 int_fast16_t e2 = INT_FAST16_MAX;
19946 int_fast16_t e2min = INT_FAST16_MIN;
19947 int_fast32_t e3 = INT_FAST32_MAX;
19948 int_fast32_t e3min = INT_FAST32_MIN;
19949 int_fast64_t e4 = INT_FAST64_MAX;
19950 int_fast64_t e4min = INT_FAST64_MIN;
19951 uint_fast8_t f1 = UINT_FAST8_MAX;
19952 uint_fast16_t f2 = UINT_FAST16_MAX;
19953 uint_fast32_t f3 = UINT_FAST32_MAX;
19954 uint_fast64_t f4 = UINT_FAST64_MAX;
19955 #ifdef INTPTR_MAX
19956 intptr_t g = INTPTR_MAX;
19957 intptr_t gmin = INTPTR_MIN;
19958 #endif
19959 #ifdef UINTPTR_MAX
19960 uintptr_t h = UINTPTR_MAX;
19961 #endif
19962 intmax_t i = INTMAX_MAX;
19963 uintmax_t j = UINTMAX_MAX;
19965 #include <limits.h> /* for CHAR_BIT */
19966 #define TYPE_MINIMUM(t) \
19967 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
19968 #define TYPE_MAXIMUM(t) \
19969 ((t) ((t) 0 < (t) -1 \
19970 ? (t) -1 \
19971 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
19972 struct s {
19973 int check_PTRDIFF:
19974 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
19975 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
19976 ? 1 : -1;
19977 /* Detect bug in FreeBSD 6.0 / ia64. */
19978 int check_SIG_ATOMIC:
19979 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
19980 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
19981 ? 1 : -1;
19982 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
19983 int check_WCHAR:
19984 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
19985 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
19986 ? 1 : -1;
19987 /* Detect bug in mingw. */
19988 int check_WINT:
19989 WINT_MIN == TYPE_MINIMUM (wint_t)
19990 && WINT_MAX == TYPE_MAXIMUM (wint_t)
19991 ? 1 : -1;
19993 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
19994 int check_UINT8_C:
19995 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
19996 int check_UINT16_C:
19997 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
19999 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20000 #ifdef UINT8_MAX
20001 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20002 #endif
20003 #ifdef UINT16_MAX
20004 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20005 #endif
20006 #ifdef UINT32_MAX
20007 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20008 #endif
20009 #ifdef UINT64_MAX
20010 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20011 #endif
20012 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20013 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20014 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20015 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20016 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20017 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20018 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20019 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20020 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20021 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20022 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20026 main ()
20030 return 0;
20032 _ACEOF
20033 if ac_fn_c_try_compile "$LINENO"; then :
20034 if test "$cross_compiling" = yes; then :
20035 gl_cv_header_working_stdint_h=yes
20037 else
20038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20039 /* end confdefs.h. */
20042 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20043 #include <stdint.h>
20046 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20047 included before <wchar.h>. */
20048 #include <stddef.h>
20049 #include <signal.h>
20050 #if HAVE_WCHAR_H
20051 # include <stdio.h>
20052 # include <time.h>
20053 # include <wchar.h>
20054 #endif
20057 #include <stdio.h>
20058 #include <string.h>
20059 #define MVAL(macro) MVAL1(macro)
20060 #define MVAL1(expression) #expression
20061 static const char *macro_values[] =
20063 #ifdef INT8_MAX
20064 MVAL (INT8_MAX),
20065 #endif
20066 #ifdef INT16_MAX
20067 MVAL (INT16_MAX),
20068 #endif
20069 #ifdef INT32_MAX
20070 MVAL (INT32_MAX),
20071 #endif
20072 #ifdef INT64_MAX
20073 MVAL (INT64_MAX),
20074 #endif
20075 #ifdef UINT8_MAX
20076 MVAL (UINT8_MAX),
20077 #endif
20078 #ifdef UINT16_MAX
20079 MVAL (UINT16_MAX),
20080 #endif
20081 #ifdef UINT32_MAX
20082 MVAL (UINT32_MAX),
20083 #endif
20084 #ifdef UINT64_MAX
20085 MVAL (UINT64_MAX),
20086 #endif
20087 NULL
20091 main ()
20094 const char **mv;
20095 for (mv = macro_values; *mv != NULL; mv++)
20097 const char *value = *mv;
20098 /* Test whether it looks like a cast expression. */
20099 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20100 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20101 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20102 || strncmp (value, "((int)"/*)*/, 6) == 0
20103 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20104 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20105 return mv - macro_values + 1;
20107 return 0;
20110 return 0;
20112 _ACEOF
20113 if ac_fn_c_try_run "$LINENO"; then :
20114 gl_cv_header_working_stdint_h=yes
20116 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20117 conftest.$ac_objext conftest.beam conftest.$ac_ext
20122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20126 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20128 if test "$gl_cv_header_working_stdint_h" = yes; then
20129 STDINT_H=
20130 else
20131 for ac_header in sys/inttypes.h sys/bitypes.h
20132 do :
20133 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20134 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20135 eval as_val=\$$as_ac_Header
20136 if test "x$as_val" = x""yes; then :
20137 cat >>confdefs.h <<_ACEOF
20138 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20139 _ACEOF
20143 done
20145 if test $ac_cv_header_sys_inttypes_h = yes; then
20146 HAVE_SYS_INTTYPES_H=1
20147 else
20148 HAVE_SYS_INTTYPES_H=0
20151 if test $ac_cv_header_sys_bitypes_h = yes; then
20152 HAVE_SYS_BITYPES_H=1
20153 else
20154 HAVE_SYS_BITYPES_H=0
20160 if test $APPLE_UNIVERSAL_BUILD = 0; then
20163 for gltype in ptrdiff_t size_t ; do
20164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20165 $as_echo_n "checking for bit size of $gltype... " >&6; }
20166 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20167 $as_echo_n "(cached) " >&6
20168 else
20169 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20170 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20171 included before <wchar.h>. */
20172 #include <stddef.h>
20173 #include <signal.h>
20174 #if HAVE_WCHAR_H
20175 # include <stdio.h>
20176 # include <time.h>
20177 # include <wchar.h>
20178 #endif
20180 #include <limits.h>"; then :
20182 else
20183 result=unknown
20186 eval gl_cv_bitsizeof_${gltype}=\$result
20189 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20191 $as_echo "$ac_res" >&6; }
20192 eval result=\$gl_cv_bitsizeof_${gltype}
20193 if test $result = unknown; then
20194 result=0
20196 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20197 cat >>confdefs.h <<_ACEOF
20198 #define BITSIZEOF_${GLTYPE} $result
20199 _ACEOF
20201 eval BITSIZEOF_${GLTYPE}=\$result
20202 done
20208 for gltype in sig_atomic_t wchar_t wint_t ; do
20209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20210 $as_echo_n "checking for bit size of $gltype... " >&6; }
20211 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20212 $as_echo_n "(cached) " >&6
20213 else
20214 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20215 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20216 included before <wchar.h>. */
20217 #include <stddef.h>
20218 #include <signal.h>
20219 #if HAVE_WCHAR_H
20220 # include <stdio.h>
20221 # include <time.h>
20222 # include <wchar.h>
20223 #endif
20225 #include <limits.h>"; then :
20227 else
20228 result=unknown
20231 eval gl_cv_bitsizeof_${gltype}=\$result
20234 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20236 $as_echo "$ac_res" >&6; }
20237 eval result=\$gl_cv_bitsizeof_${gltype}
20238 if test $result = unknown; then
20239 result=0
20241 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20242 cat >>confdefs.h <<_ACEOF
20243 #define BITSIZEOF_${GLTYPE} $result
20244 _ACEOF
20246 eval BITSIZEOF_${GLTYPE}=\$result
20247 done
20252 for gltype in sig_atomic_t wchar_t wint_t ; do
20253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20254 $as_echo_n "checking whether $gltype is signed... " >&6; }
20255 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20256 $as_echo_n "(cached) " >&6
20257 else
20258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20259 /* end confdefs.h. */
20261 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20262 included before <wchar.h>. */
20263 #include <stddef.h>
20264 #include <signal.h>
20265 #if HAVE_WCHAR_H
20266 # include <stdio.h>
20267 # include <time.h>
20268 # include <wchar.h>
20269 #endif
20271 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20273 main ()
20277 return 0;
20279 _ACEOF
20280 if ac_fn_c_try_compile "$LINENO"; then :
20281 result=yes
20282 else
20283 result=no
20285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20286 eval gl_cv_type_${gltype}_signed=\$result
20289 eval ac_res=\$gl_cv_type_${gltype}_signed
20290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20291 $as_echo "$ac_res" >&6; }
20292 eval result=\$gl_cv_type_${gltype}_signed
20293 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20294 if test "$result" = yes; then
20295 cat >>confdefs.h <<_ACEOF
20296 #define HAVE_SIGNED_${GLTYPE} 1
20297 _ACEOF
20299 eval HAVE_SIGNED_${GLTYPE}=1
20300 else
20301 eval HAVE_SIGNED_${GLTYPE}=0
20303 done
20306 gl_cv_type_ptrdiff_t_signed=yes
20307 gl_cv_type_size_t_signed=no
20308 if test $APPLE_UNIVERSAL_BUILD = 0; then
20311 for gltype in ptrdiff_t size_t ; do
20312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20313 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20314 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20315 $as_echo_n "(cached) " >&6
20316 else
20317 eval gl_cv_type_${gltype}_suffix=no
20318 eval result=\$gl_cv_type_${gltype}_signed
20319 if test "$result" = yes; then
20320 glsufu=
20321 else
20322 glsufu=u
20324 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20325 case $glsuf in
20326 '') gltype1='int';;
20327 l) gltype1='long int';;
20328 ll) gltype1='long long int';;
20329 i64) gltype1='__int64';;
20330 u) gltype1='unsigned int';;
20331 ul) gltype1='unsigned long int';;
20332 ull) gltype1='unsigned long long int';;
20333 ui64)gltype1='unsigned __int64';;
20334 esac
20335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20336 /* end confdefs.h. */
20338 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20339 included before <wchar.h>. */
20340 #include <stddef.h>
20341 #include <signal.h>
20342 #if HAVE_WCHAR_H
20343 # include <stdio.h>
20344 # include <time.h>
20345 # include <wchar.h>
20346 #endif
20348 extern $gltype foo;
20349 extern $gltype1 foo;
20351 main ()
20355 return 0;
20357 _ACEOF
20358 if ac_fn_c_try_compile "$LINENO"; then :
20359 eval gl_cv_type_${gltype}_suffix=\$glsuf
20361 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20362 eval result=\$gl_cv_type_${gltype}_suffix
20363 test "$result" != no && break
20364 done
20366 eval ac_res=\$gl_cv_type_${gltype}_suffix
20367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20368 $as_echo "$ac_res" >&6; }
20369 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20370 eval result=\$gl_cv_type_${gltype}_suffix
20371 test "$result" = no && result=
20372 eval ${GLTYPE}_SUFFIX=\$result
20373 cat >>confdefs.h <<_ACEOF
20374 #define ${GLTYPE}_SUFFIX $result
20375 _ACEOF
20377 done
20383 for gltype in sig_atomic_t wchar_t wint_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
20453 if test $BITSIZEOF_WINT_T -lt 32; then
20454 BITSIZEOF_WINT_T=32
20457 STDINT_H=stdint.h
20460 if test -n "$STDINT_H"; then
20461 GL_GENERATE_STDINT_H_TRUE=
20462 GL_GENERATE_STDINT_H_FALSE='#'
20463 else
20464 GL_GENERATE_STDINT_H_TRUE='#'
20465 GL_GENERATE_STDINT_H_FALSE=
20472 GNULIB_IMAXABS=0;
20473 GNULIB_IMAXDIV=0;
20474 GNULIB_STRTOIMAX=0;
20475 GNULIB_STRTOUMAX=0;
20476 HAVE_DECL_IMAXABS=1;
20477 HAVE_DECL_IMAXDIV=1;
20478 HAVE_DECL_STRTOIMAX=1;
20479 HAVE_DECL_STRTOUMAX=1;
20480 REPLACE_STRTOIMAX=0;
20481 INT32_MAX_LT_INTMAX_MAX=1;
20482 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20483 PRI_MACROS_BROKEN=0;
20484 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20485 UINT32_MAX_LT_UINTMAX_MAX=1;
20486 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20502 if test $gl_cv_have_include_next = yes; then
20503 gl_cv_next_inttypes_h='<'inttypes.h'>'
20504 else
20505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20506 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20507 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20508 $as_echo_n "(cached) " >&6
20509 else
20511 if test $ac_cv_header_inttypes_h = yes; then
20514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20515 /* end confdefs.h. */
20516 #include <inttypes.h>
20518 _ACEOF
20519 case "$host_os" in
20520 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20521 *) gl_absname_cpp="$ac_cpp" ;;
20522 esac
20524 case "$host_os" in
20525 mingw*)
20526 gl_dirsep_regex='[/\\]'
20529 gl_dirsep_regex='\/'
20531 esac
20532 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20534 gl_header_literal_regex=`echo 'inttypes.h' \
20535 | sed -e "$gl_make_literal_regex_sed"`
20536 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20537 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20538 s|^/[^/]|//&|
20542 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20543 sed -n "$gl_absolute_header_sed"`'"'
20544 else
20545 gl_cv_next_inttypes_h='<'inttypes.h'>'
20550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
20551 $as_echo "$gl_cv_next_inttypes_h" >&6; }
20553 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
20555 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20556 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20557 gl_next_as_first_directive='<'inttypes.h'>'
20558 else
20559 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20560 gl_next_as_first_directive=$gl_cv_next_inttypes_h
20562 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
20574 case "$host_os" in
20575 mingw*)
20576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
20577 $as_echo_n "checking for 64-bit off_t... " >&6; }
20578 if test "${gl_cv_type_off_t_64+set}" = set; then :
20579 $as_echo_n "(cached) " >&6
20580 else
20581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20582 /* end confdefs.h. */
20583 #include <sys/types.h>
20584 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
20587 main ()
20591 return 0;
20593 _ACEOF
20594 if ac_fn_c_try_compile "$LINENO"; then :
20595 gl_cv_type_off_t_64=yes
20596 else
20597 gl_cv_type_off_t_64=no
20599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
20603 $as_echo "$gl_cv_type_off_t_64" >&6; }
20604 if test $gl_cv_type_off_t_64 = no; then
20605 WINDOWS_64_BIT_OFF_T=1
20606 else
20607 WINDOWS_64_BIT_OFF_T=0
20609 WINDOWS_64_BIT_ST_SIZE=1
20612 WINDOWS_64_BIT_OFF_T=0
20613 WINDOWS_64_BIT_ST_SIZE=0
20615 esac
20620 GNULIB_FFSL=0;
20621 GNULIB_FFSLL=0;
20622 GNULIB_MEMCHR=0;
20623 GNULIB_MEMMEM=0;
20624 GNULIB_MEMPCPY=0;
20625 GNULIB_MEMRCHR=0;
20626 GNULIB_RAWMEMCHR=0;
20627 GNULIB_STPCPY=0;
20628 GNULIB_STPNCPY=0;
20629 GNULIB_STRCHRNUL=0;
20630 GNULIB_STRDUP=0;
20631 GNULIB_STRNCAT=0;
20632 GNULIB_STRNDUP=0;
20633 GNULIB_STRNLEN=0;
20634 GNULIB_STRPBRK=0;
20635 GNULIB_STRSEP=0;
20636 GNULIB_STRSTR=0;
20637 GNULIB_STRCASESTR=0;
20638 GNULIB_STRTOK_R=0;
20639 GNULIB_MBSLEN=0;
20640 GNULIB_MBSNLEN=0;
20641 GNULIB_MBSCHR=0;
20642 GNULIB_MBSRCHR=0;
20643 GNULIB_MBSSTR=0;
20644 GNULIB_MBSCASECMP=0;
20645 GNULIB_MBSNCASECMP=0;
20646 GNULIB_MBSPCASECMP=0;
20647 GNULIB_MBSCASESTR=0;
20648 GNULIB_MBSCSPN=0;
20649 GNULIB_MBSPBRK=0;
20650 GNULIB_MBSSPN=0;
20651 GNULIB_MBSSEP=0;
20652 GNULIB_MBSTOK_R=0;
20653 GNULIB_STRERROR=0;
20654 GNULIB_STRERROR_R=0;
20655 GNULIB_STRSIGNAL=0;
20656 GNULIB_STRVERSCMP=0;
20657 HAVE_MBSLEN=0;
20658 HAVE_FFSL=1;
20659 HAVE_FFSLL=1;
20660 HAVE_MEMCHR=1;
20661 HAVE_DECL_MEMMEM=1;
20662 HAVE_MEMPCPY=1;
20663 HAVE_DECL_MEMRCHR=1;
20664 HAVE_RAWMEMCHR=1;
20665 HAVE_STPCPY=1;
20666 HAVE_STPNCPY=1;
20667 HAVE_STRCHRNUL=1;
20668 HAVE_DECL_STRDUP=1;
20669 HAVE_DECL_STRNDUP=1;
20670 HAVE_DECL_STRNLEN=1;
20671 HAVE_STRPBRK=1;
20672 HAVE_STRSEP=1;
20673 HAVE_STRCASESTR=1;
20674 HAVE_DECL_STRTOK_R=1;
20675 HAVE_DECL_STRERROR_R=1;
20676 HAVE_DECL_STRSIGNAL=1;
20677 HAVE_STRVERSCMP=1;
20678 REPLACE_MEMCHR=0;
20679 REPLACE_MEMMEM=0;
20680 REPLACE_STPNCPY=0;
20681 REPLACE_STRDUP=0;
20682 REPLACE_STRSTR=0;
20683 REPLACE_STRCASESTR=0;
20684 REPLACE_STRCHRNUL=0;
20685 REPLACE_STRERROR=0;
20686 REPLACE_STRERROR_R=0;
20687 REPLACE_STRNCAT=0;
20688 REPLACE_STRNDUP=0;
20689 REPLACE_STRNLEN=0;
20690 REPLACE_STRSIGNAL=0;
20691 REPLACE_STRTOK_R=0;
20692 UNDEFINE_STRTOK_R=0;
20694 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
20695 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
20696 ac_have_decl=1
20697 else
20698 ac_have_decl=0
20701 cat >>confdefs.h <<_ACEOF
20702 #define HAVE_DECL_MEMRCHR $ac_have_decl
20703 _ACEOF
20706 GNULIB_MKTIME=0;
20707 GNULIB_NANOSLEEP=0;
20708 GNULIB_STRPTIME=0;
20709 GNULIB_TIMEGM=0;
20710 GNULIB_TIME_R=0;
20711 HAVE_DECL_LOCALTIME_R=1;
20712 HAVE_NANOSLEEP=1;
20713 HAVE_STRPTIME=1;
20714 HAVE_TIMEGM=1;
20715 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
20716 REPLACE_MKTIME=GNULIB_PORTCHECK;
20717 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
20718 REPLACE_TIMEGM=GNULIB_PORTCHECK;
20720 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
20721 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
20722 ac_have_decl=1
20723 else
20724 ac_have_decl=0
20727 cat >>confdefs.h <<_ACEOF
20728 #define HAVE_DECL_ALARM $ac_have_decl
20729 _ACEOF
20734 GNULIB_PSELECT=0;
20735 GNULIB_SELECT=0;
20736 HAVE_PSELECT=1;
20737 REPLACE_PSELECT=0;
20738 REPLACE_SELECT=0;
20745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
20746 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
20747 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
20748 $as_echo_n "(cached) " >&6
20749 else
20751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20752 /* end confdefs.h. */
20753 #include <sys/select.h>
20755 main ()
20757 struct timeval b;
20759 return 0;
20761 _ACEOF
20762 if ac_fn_c_try_compile "$LINENO"; then :
20763 gl_cv_header_sys_select_h_selfcontained=yes
20764 else
20765 gl_cv_header_sys_select_h_selfcontained=no
20767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20768 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
20769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20770 /* end confdefs.h. */
20771 #include <sys/select.h>
20773 main ()
20775 int memset; int bzero;
20777 return 0;
20780 _ACEOF
20781 if ac_fn_c_try_compile "$LINENO"; then :
20782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20783 /* end confdefs.h. */
20784 #include <sys/select.h>
20786 main ()
20789 #undef memset
20790 #define memset nonexistent_memset
20791 extern
20792 #ifdef __cplusplus
20794 #endif
20795 void *memset (void *, int, unsigned long);
20796 #undef bzero
20797 #define bzero nonexistent_bzero
20798 extern
20799 #ifdef __cplusplus
20801 #endif
20802 void bzero (void *, unsigned long);
20803 fd_set fds;
20804 FD_ZERO (&fds);
20807 return 0;
20810 _ACEOF
20811 if ac_fn_c_try_link "$LINENO"; then :
20813 else
20814 gl_cv_header_sys_select_h_selfcontained=no
20816 rm -f core conftest.err conftest.$ac_objext \
20817 conftest$ac_exeext conftest.$ac_ext
20820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
20825 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
20835 if test $gl_cv_have_include_next = yes; then
20836 gl_cv_next_sys_select_h='<'sys/select.h'>'
20837 else
20838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
20839 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
20840 if test "${gl_cv_next_sys_select_h+set}" = set; then :
20841 $as_echo_n "(cached) " >&6
20842 else
20844 if test $ac_cv_header_sys_select_h = yes; then
20847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20848 /* end confdefs.h. */
20849 #include <sys/select.h>
20851 _ACEOF
20852 case "$host_os" in
20853 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20854 *) gl_absname_cpp="$ac_cpp" ;;
20855 esac
20857 case "$host_os" in
20858 mingw*)
20859 gl_dirsep_regex='[/\\]'
20862 gl_dirsep_regex='\/'
20864 esac
20865 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20867 gl_header_literal_regex=`echo 'sys/select.h' \
20868 | sed -e "$gl_make_literal_regex_sed"`
20869 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20870 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20871 s|^/[^/]|//&|
20875 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20876 sed -n "$gl_absolute_header_sed"`'"'
20877 else
20878 gl_cv_next_sys_select_h='<'sys/select.h'>'
20883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
20884 $as_echo "$gl_cv_next_sys_select_h" >&6; }
20886 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
20888 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20889 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20890 gl_next_as_first_directive='<'sys/select.h'>'
20891 else
20892 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20893 gl_next_as_first_directive=$gl_cv_next_sys_select_h
20895 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
20900 if test $ac_cv_header_sys_select_h = yes; then
20901 HAVE_SYS_SELECT_H=1
20902 else
20903 HAVE_SYS_SELECT_H=0
20910 if test $ac_cv_header_sys_socket_h != yes; then
20911 for ac_header in winsock2.h
20912 do :
20913 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
20914 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
20915 cat >>confdefs.h <<_ACEOF
20916 #define HAVE_WINSOCK2_H 1
20917 _ACEOF
20921 done
20924 if test "$ac_cv_header_winsock2_h" = yes; then
20925 HAVE_WINSOCK2_H=1
20926 UNISTD_H_HAVE_WINSOCK2_H=1
20927 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
20928 else
20929 HAVE_WINSOCK2_H=0
20939 GNULIB_PTHREAD_SIGMASK=0;
20940 GNULIB_RAISE=0;
20941 GNULIB_SIGNAL_H_SIGPIPE=0;
20942 GNULIB_SIGPROCMASK=0;
20943 GNULIB_SIGACTION=0;
20944 HAVE_POSIX_SIGNALBLOCKING=1;
20945 HAVE_PTHREAD_SIGMASK=1;
20946 HAVE_RAISE=1;
20947 HAVE_SIGSET_T=1;
20948 HAVE_SIGINFO_T=1;
20949 HAVE_SIGACTION=1;
20950 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
20952 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
20954 HAVE_SIGHANDLER_T=1;
20955 REPLACE_PTHREAD_SIGMASK=0;
20956 REPLACE_RAISE=0;
20964 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
20965 #include <signal.h>
20966 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
20967 #include <sys/types.h>
20970 if test "x$ac_cv_type_sigset_t" = x""yes; then :
20972 cat >>confdefs.h <<_ACEOF
20973 #define HAVE_SIGSET_T 1
20974 _ACEOF
20976 gl_cv_type_sigset_t=yes
20977 else
20978 gl_cv_type_sigset_t=no
20981 if test $gl_cv_type_sigset_t != yes; then
20982 HAVE_SIGSET_T=0
20987 if test $ac_cv_header_sys_socket_h = no; then
20988 for ac_header in ws2tcpip.h
20989 do :
20990 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
20991 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
20992 cat >>confdefs.h <<_ACEOF
20993 #define HAVE_WS2TCPIP_H 1
20994 _ACEOF
20998 done
21002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21003 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21004 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21005 $as_echo_n "(cached) " >&6
21006 else
21007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21008 /* end confdefs.h. */
21010 #include <stdbool.h>
21011 #ifndef bool
21012 "error: bool is not defined"
21013 #endif
21014 #ifndef false
21015 "error: false is not defined"
21016 #endif
21017 #if false
21018 "error: false is not 0"
21019 #endif
21020 #ifndef true
21021 "error: true is not defined"
21022 #endif
21023 #if true != 1
21024 "error: true is not 1"
21025 #endif
21026 #ifndef __bool_true_false_are_defined
21027 "error: __bool_true_false_are_defined is not defined"
21028 #endif
21030 struct s { _Bool s: 1; _Bool t; } s;
21032 char a[true == 1 ? 1 : -1];
21033 char b[false == 0 ? 1 : -1];
21034 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21035 char d[(bool) 0.5 == true ? 1 : -1];
21036 /* See body of main program for 'e'. */
21037 char f[(_Bool) 0.0 == false ? 1 : -1];
21038 char g[true];
21039 char h[sizeof (_Bool)];
21040 char i[sizeof s.t];
21041 enum { j = false, k = true, l = false * true, m = true * 256 };
21042 /* The following fails for
21043 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21044 _Bool n[m];
21045 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21046 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21047 /* Catch a bug in an HP-UX C compiler. See
21048 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21049 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21051 _Bool q = true;
21052 _Bool *pq = &q;
21055 main ()
21058 bool e = &s;
21059 *pq |= q;
21060 *pq |= ! q;
21061 /* Refer to every declared value, to avoid compiler optimizations. */
21062 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21063 + !m + !n + !o + !p + !q + !pq);
21066 return 0;
21068 _ACEOF
21069 if ac_fn_c_try_compile "$LINENO"; then :
21070 ac_cv_header_stdbool_h=yes
21071 else
21072 ac_cv_header_stdbool_h=no
21074 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21077 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21078 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21079 if test "x$ac_cv_type__Bool" = x""yes; then :
21081 cat >>confdefs.h <<_ACEOF
21082 #define HAVE__BOOL 1
21083 _ACEOF
21090 REPLACE_NULL=0;
21091 HAVE_WCHAR_T=1;
21094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21095 $as_echo_n "checking for wchar_t... " >&6; }
21096 if test "${gt_cv_c_wchar_t+set}" = set; then :
21097 $as_echo_n "(cached) " >&6
21098 else
21099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21100 /* end confdefs.h. */
21101 #include <stddef.h>
21102 wchar_t foo = (wchar_t)'\0';
21104 main ()
21108 return 0;
21110 _ACEOF
21111 if ac_fn_c_try_compile "$LINENO"; then :
21112 gt_cv_c_wchar_t=yes
21113 else
21114 gt_cv_c_wchar_t=no
21116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21119 $as_echo "$gt_cv_c_wchar_t" >&6; }
21120 if test $gt_cv_c_wchar_t = yes; then
21122 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21127 GNULIB_DPRINTF=0;
21128 GNULIB_FCLOSE=0;
21129 GNULIB_FDOPEN=0;
21130 GNULIB_FFLUSH=0;
21131 GNULIB_FGETC=0;
21132 GNULIB_FGETS=0;
21133 GNULIB_FOPEN=0;
21134 GNULIB_FPRINTF=0;
21135 GNULIB_FPRINTF_POSIX=0;
21136 GNULIB_FPURGE=0;
21137 GNULIB_FPUTC=0;
21138 GNULIB_FPUTS=0;
21139 GNULIB_FREAD=0;
21140 GNULIB_FREOPEN=0;
21141 GNULIB_FSCANF=0;
21142 GNULIB_FSEEK=0;
21143 GNULIB_FSEEKO=0;
21144 GNULIB_FTELL=0;
21145 GNULIB_FTELLO=0;
21146 GNULIB_FWRITE=0;
21147 GNULIB_GETC=0;
21148 GNULIB_GETCHAR=0;
21149 GNULIB_GETDELIM=0;
21150 GNULIB_GETLINE=0;
21151 GNULIB_OBSTACK_PRINTF=0;
21152 GNULIB_OBSTACK_PRINTF_POSIX=0;
21153 GNULIB_PCLOSE=0;
21154 GNULIB_PERROR=0;
21155 GNULIB_POPEN=0;
21156 GNULIB_PRINTF=0;
21157 GNULIB_PRINTF_POSIX=0;
21158 GNULIB_PUTC=0;
21159 GNULIB_PUTCHAR=0;
21160 GNULIB_PUTS=0;
21161 GNULIB_REMOVE=0;
21162 GNULIB_RENAME=0;
21163 GNULIB_RENAMEAT=0;
21164 GNULIB_SCANF=0;
21165 GNULIB_SNPRINTF=0;
21166 GNULIB_SPRINTF_POSIX=0;
21167 GNULIB_STDIO_H_NONBLOCKING=0;
21168 GNULIB_STDIO_H_SIGPIPE=0;
21169 GNULIB_TMPFILE=0;
21170 GNULIB_VASPRINTF=0;
21171 GNULIB_VFSCANF=0;
21172 GNULIB_VSCANF=0;
21173 GNULIB_VDPRINTF=0;
21174 GNULIB_VFPRINTF=0;
21175 GNULIB_VFPRINTF_POSIX=0;
21176 GNULIB_VPRINTF=0;
21177 GNULIB_VPRINTF_POSIX=0;
21178 GNULIB_VSNPRINTF=0;
21179 GNULIB_VSPRINTF_POSIX=0;
21180 HAVE_DECL_FPURGE=1;
21181 HAVE_DECL_FSEEKO=1;
21182 HAVE_DECL_FTELLO=1;
21183 HAVE_DECL_GETDELIM=1;
21184 HAVE_DECL_GETLINE=1;
21185 HAVE_DECL_OBSTACK_PRINTF=1;
21186 HAVE_DECL_SNPRINTF=1;
21187 HAVE_DECL_VSNPRINTF=1;
21188 HAVE_DPRINTF=1;
21189 HAVE_FSEEKO=1;
21190 HAVE_FTELLO=1;
21191 HAVE_PCLOSE=1;
21192 HAVE_POPEN=1;
21193 HAVE_RENAMEAT=1;
21194 HAVE_VASPRINTF=1;
21195 HAVE_VDPRINTF=1;
21196 REPLACE_DPRINTF=0;
21197 REPLACE_FCLOSE=0;
21198 REPLACE_FDOPEN=0;
21199 REPLACE_FFLUSH=0;
21200 REPLACE_FOPEN=0;
21201 REPLACE_FPRINTF=0;
21202 REPLACE_FPURGE=0;
21203 REPLACE_FREOPEN=0;
21204 REPLACE_FSEEK=0;
21205 REPLACE_FSEEKO=0;
21206 REPLACE_FTELL=0;
21207 REPLACE_FTELLO=0;
21208 REPLACE_GETDELIM=0;
21209 REPLACE_GETLINE=0;
21210 REPLACE_OBSTACK_PRINTF=0;
21211 REPLACE_PERROR=0;
21212 REPLACE_POPEN=0;
21213 REPLACE_PRINTF=0;
21214 REPLACE_REMOVE=0;
21215 REPLACE_RENAME=0;
21216 REPLACE_RENAMEAT=0;
21217 REPLACE_SNPRINTF=0;
21218 REPLACE_SPRINTF=0;
21219 REPLACE_STDIO_READ_FUNCS=0;
21220 REPLACE_STDIO_WRITE_FUNCS=0;
21221 REPLACE_TMPFILE=0;
21222 REPLACE_VASPRINTF=0;
21223 REPLACE_VDPRINTF=0;
21224 REPLACE_VFPRINTF=0;
21225 REPLACE_VPRINTF=0;
21226 REPLACE_VSNPRINTF=0;
21227 REPLACE_VSPRINTF=0;
21229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21230 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21231 if test "${ac_cv_struct_tm+set}" = set; then :
21232 $as_echo_n "(cached) " >&6
21233 else
21234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21235 /* end confdefs.h. */
21236 #include <sys/types.h>
21237 #include <time.h>
21240 main ()
21242 struct tm tm;
21243 int *p = &tm.tm_sec;
21244 return !p;
21246 return 0;
21248 _ACEOF
21249 if ac_fn_c_try_compile "$LINENO"; then :
21250 ac_cv_struct_tm=time.h
21251 else
21252 ac_cv_struct_tm=sys/time.h
21254 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21257 $as_echo "$ac_cv_struct_tm" >&6; }
21258 if test $ac_cv_struct_tm = sys/time.h; then
21260 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21264 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21265 #include <$ac_cv_struct_tm>
21268 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21270 cat >>confdefs.h <<_ACEOF
21271 #define HAVE_STRUCT_TM_TM_ZONE 1
21272 _ACEOF
21277 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21279 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21281 else
21282 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21284 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21285 ac_have_decl=1
21286 else
21287 ac_have_decl=0
21290 cat >>confdefs.h <<_ACEOF
21291 #define HAVE_DECL_TZNAME $ac_have_decl
21292 _ACEOF
21294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21295 $as_echo_n "checking for tzname... " >&6; }
21296 if test "${ac_cv_var_tzname+set}" = set; then :
21297 $as_echo_n "(cached) " >&6
21298 else
21299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21300 /* end confdefs.h. */
21301 #include <time.h>
21302 #if !HAVE_DECL_TZNAME
21303 extern char *tzname[];
21304 #endif
21307 main ()
21309 return tzname[0][0];
21311 return 0;
21313 _ACEOF
21314 if ac_fn_c_try_link "$LINENO"; then :
21315 ac_cv_var_tzname=yes
21316 else
21317 ac_cv_var_tzname=no
21319 rm -f core conftest.err conftest.$ac_objext \
21320 conftest$ac_exeext conftest.$ac_ext
21322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21323 $as_echo "$ac_cv_var_tzname" >&6; }
21324 if test $ac_cv_var_tzname = yes; then
21326 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21332 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21334 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21336 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21352 if test $gl_cv_have_include_next = yes; then
21353 gl_cv_next_string_h='<'string.h'>'
21354 else
21355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21356 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21357 if test "${gl_cv_next_string_h+set}" = set; then :
21358 $as_echo_n "(cached) " >&6
21359 else
21361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21362 /* end confdefs.h. */
21363 #include <string.h>
21365 _ACEOF
21366 case "$host_os" in
21367 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21368 *) gl_absname_cpp="$ac_cpp" ;;
21369 esac
21371 case "$host_os" in
21372 mingw*)
21373 gl_dirsep_regex='[/\\]'
21376 gl_dirsep_regex='\/'
21378 esac
21379 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21381 gl_header_literal_regex=`echo 'string.h' \
21382 | sed -e "$gl_make_literal_regex_sed"`
21383 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21384 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21385 s|^/[^/]|//&|
21389 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21390 sed -n "$gl_absolute_header_sed"`'"'
21394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21395 $as_echo "$gl_cv_next_string_h" >&6; }
21397 NEXT_STRING_H=$gl_cv_next_string_h
21399 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21400 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21401 gl_next_as_first_directive='<'string.h'>'
21402 else
21403 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21404 gl_next_as_first_directive=$gl_cv_next_string_h
21406 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21416 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21417 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21418 ac_have_decl=1
21419 else
21420 ac_have_decl=0
21423 cat >>confdefs.h <<_ACEOF
21424 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21425 _ACEOF
21429 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21430 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21431 ac_have_decl=1
21432 else
21433 ac_have_decl=0
21436 cat >>confdefs.h <<_ACEOF
21437 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21438 _ACEOF
21442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21443 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21444 if test "${ac_cv_header_stat_broken+set}" = set; then :
21445 $as_echo_n "(cached) " >&6
21446 else
21447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21448 /* end confdefs.h. */
21449 #include <sys/types.h>
21450 #include <sys/stat.h>
21452 #if defined S_ISBLK && defined S_IFDIR
21453 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21454 #endif
21456 #if defined S_ISBLK && defined S_IFCHR
21457 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21458 #endif
21460 #if defined S_ISLNK && defined S_IFREG
21461 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21462 #endif
21464 #if defined S_ISSOCK && defined S_IFREG
21465 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21466 #endif
21468 _ACEOF
21469 if ac_fn_c_try_compile "$LINENO"; then :
21470 ac_cv_header_stat_broken=no
21471 else
21472 ac_cv_header_stat_broken=yes
21474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21477 $as_echo "$ac_cv_header_stat_broken" >&6; }
21478 if test $ac_cv_header_stat_broken = yes; then
21480 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21489 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21490 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21491 $as_echo_n "(cached) " >&6
21492 else
21493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21494 /* end confdefs.h. */
21495 #include <time.h>
21498 main ()
21500 static struct timespec x; x.tv_sec = x.tv_nsec;
21502 return 0;
21504 _ACEOF
21505 if ac_fn_c_try_compile "$LINENO"; then :
21506 gl_cv_sys_struct_timespec_in_time_h=yes
21507 else
21508 gl_cv_sys_struct_timespec_in_time_h=no
21510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21513 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21515 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21516 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21517 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21518 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21519 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21520 else
21521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21522 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21523 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21524 $as_echo_n "(cached) " >&6
21525 else
21526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21527 /* end confdefs.h. */
21528 #include <sys/time.h>
21531 main ()
21533 static struct timespec x; x.tv_sec = x.tv_nsec;
21535 return 0;
21537 _ACEOF
21538 if ac_fn_c_try_compile "$LINENO"; then :
21539 gl_cv_sys_struct_timespec_in_sys_time_h=yes
21540 else
21541 gl_cv_sys_struct_timespec_in_sys_time_h=no
21543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
21546 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
21547 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
21548 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
21549 else
21550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
21551 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
21552 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
21553 $as_echo_n "(cached) " >&6
21554 else
21555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21556 /* end confdefs.h. */
21557 #include <pthread.h>
21560 main ()
21562 static struct timespec x; x.tv_sec = x.tv_nsec;
21564 return 0;
21566 _ACEOF
21567 if ac_fn_c_try_compile "$LINENO"; then :
21568 gl_cv_sys_struct_timespec_in_pthread_h=yes
21569 else
21570 gl_cv_sys_struct_timespec_in_pthread_h=no
21572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
21575 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
21576 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
21577 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
21596 if test $gl_cv_have_include_next = yes; then
21597 gl_cv_next_time_h='<'time.h'>'
21598 else
21599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
21600 $as_echo_n "checking absolute name of <time.h>... " >&6; }
21601 if test "${gl_cv_next_time_h+set}" = set; then :
21602 $as_echo_n "(cached) " >&6
21603 else
21605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21606 /* end confdefs.h. */
21607 #include <time.h>
21609 _ACEOF
21610 case "$host_os" in
21611 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21612 *) gl_absname_cpp="$ac_cpp" ;;
21613 esac
21615 case "$host_os" in
21616 mingw*)
21617 gl_dirsep_regex='[/\\]'
21620 gl_dirsep_regex='\/'
21622 esac
21623 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21625 gl_header_literal_regex=`echo 'time.h' \
21626 | sed -e "$gl_make_literal_regex_sed"`
21627 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21628 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21629 s|^/[^/]|//&|
21633 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21634 sed -n "$gl_absolute_header_sed"`'"'
21638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
21639 $as_echo "$gl_cv_next_time_h" >&6; }
21641 NEXT_TIME_H=$gl_cv_next_time_h
21643 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21644 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21645 gl_next_as_first_directive='<'time.h'>'
21646 else
21647 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21648 gl_next_as_first_directive=$gl_cv_next_time_h
21650 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
21665 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
21666 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
21667 ac_have_decl=1
21668 else
21669 ac_have_decl=0
21672 cat >>confdefs.h <<_ACEOF
21673 #define HAVE_DECL_UNSETENV $ac_have_decl
21674 _ACEOF
21677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
21678 $as_echo_n "checking whether the utimes function works... " >&6; }
21679 if test "${gl_cv_func_working_utimes+set}" = set; then :
21680 $as_echo_n "(cached) " >&6
21681 else
21683 if test "$cross_compiling" = yes; then :
21684 gl_cv_func_working_utimes=no
21685 else
21686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21687 /* end confdefs.h. */
21689 #include <sys/types.h>
21690 #include <sys/stat.h>
21691 #include <fcntl.h>
21692 #include <sys/time.h>
21693 #include <time.h>
21694 #include <unistd.h>
21695 #include <stdlib.h>
21696 #include <stdio.h>
21697 #include <utime.h>
21699 static int
21700 inorder (time_t a, time_t b, time_t c)
21702 return a <= b && b <= c;
21706 main ()
21708 int result = 0;
21709 char const *file = "conftest.utimes";
21710 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
21712 /* Test whether utimes() essentially works. */
21714 struct stat sbuf;
21715 FILE *f = fopen (file, "w");
21716 if (f == NULL)
21717 result |= 1;
21718 else if (fclose (f) != 0)
21719 result |= 1;
21720 else if (utimes (file, timeval) != 0)
21721 result |= 2;
21722 else if (lstat (file, &sbuf) != 0)
21723 result |= 1;
21724 else if (!(sbuf.st_atime == timeval[0].tv_sec
21725 && sbuf.st_mtime == timeval[1].tv_sec))
21726 result |= 4;
21727 if (unlink (file) != 0)
21728 result |= 1;
21731 /* Test whether utimes() with a NULL argument sets the file's timestamp
21732 to the current time. Use 'fstat' as well as 'time' to
21733 determine the "current" time, to accommodate NFS file systems
21734 if there is a time skew between the host and the NFS server. */
21736 int fd = open (file, O_WRONLY|O_CREAT, 0644);
21737 if (fd < 0)
21738 result |= 1;
21739 else
21741 time_t t0, t2;
21742 struct stat st0, st1, st2;
21743 if (time (&t0) == (time_t) -1)
21744 result |= 1;
21745 else if (fstat (fd, &st0) != 0)
21746 result |= 1;
21747 else if (utimes (file, timeval) != 0)
21748 result |= 2;
21749 else if (utimes (file, NULL) != 0)
21750 result |= 8;
21751 else if (fstat (fd, &st1) != 0)
21752 result |= 1;
21753 else if (write (fd, "\n", 1) != 1)
21754 result |= 1;
21755 else if (fstat (fd, &st2) != 0)
21756 result |= 1;
21757 else if (time (&t2) == (time_t) -1)
21758 result |= 1;
21759 else
21761 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
21762 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
21763 if (! (st1.st_atime == st1.st_mtime))
21764 result |= 16;
21765 if (! (m_ok_POSIX || m_ok_NFS))
21766 result |= 32;
21768 if (close (fd) != 0)
21769 result |= 1;
21771 if (unlink (file) != 0)
21772 result |= 1;
21775 /* Test whether utimes() with a NULL argument works on read-only files. */
21777 int fd = open (file, O_WRONLY|O_CREAT, 0444);
21778 if (fd < 0)
21779 result |= 1;
21780 else if (close (fd) != 0)
21781 result |= 1;
21782 else if (utimes (file, NULL) != 0)
21783 result |= 64;
21784 if (unlink (file) != 0)
21785 result |= 1;
21788 return result;
21791 _ACEOF
21792 if ac_fn_c_try_run "$LINENO"; then :
21793 gl_cv_func_working_utimes=yes
21794 else
21795 gl_cv_func_working_utimes=no
21797 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21798 conftest.$ac_objext conftest.beam conftest.$ac_ext
21802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
21803 $as_echo "$gl_cv_func_working_utimes" >&6; }
21805 if test $gl_cv_func_working_utimes = yes; then
21807 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
21815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
21816 $as_echo_n "checking for struct utimbuf... " >&6; }
21817 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
21818 $as_echo_n "(cached) " >&6
21819 else
21820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21821 /* end confdefs.h. */
21822 #if HAVE_SYS_TIME_H
21823 #include <sys/time.h>
21824 #endif
21825 #include <time.h>
21826 #ifdef HAVE_UTIME_H
21827 #include <utime.h>
21828 #endif
21831 main ()
21833 static struct utimbuf x; x.actime = x.modtime;
21835 return 0;
21837 _ACEOF
21838 if ac_fn_c_try_compile "$LINENO"; then :
21839 gl_cv_sys_struct_utimbuf=yes
21840 else
21841 gl_cv_sys_struct_utimbuf=no
21843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
21846 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
21848 if test $gl_cv_sys_struct_utimbuf = yes; then
21850 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
21864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
21865 $as_echo_n "checking type of array argument to getgroups... " >&6; }
21866 if test "${ac_cv_type_getgroups+set}" = set; then :
21867 $as_echo_n "(cached) " >&6
21868 else
21869 if test "$cross_compiling" = yes; then :
21870 ac_cv_type_getgroups=cross
21871 else
21872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21873 /* end confdefs.h. */
21874 /* Thanks to Mike Rendell for this test. */
21875 $ac_includes_default
21876 #define NGID 256
21877 #undef MAX
21878 #define MAX(x, y) ((x) > (y) ? (x) : (y))
21881 main ()
21883 gid_t gidset[NGID];
21884 int i, n;
21885 union { gid_t gval; long int lval; } val;
21887 val.lval = -1;
21888 for (i = 0; i < NGID; i++)
21889 gidset[i] = val.gval;
21890 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
21891 gidset);
21892 /* Exit non-zero if getgroups seems to require an array of ints. This
21893 happens when gid_t is short int but getgroups modifies an array
21894 of ints. */
21895 return n > 0 && gidset[n] != val.gval;
21897 _ACEOF
21898 if ac_fn_c_try_run "$LINENO"; then :
21899 ac_cv_type_getgroups=gid_t
21900 else
21901 ac_cv_type_getgroups=int
21903 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21904 conftest.$ac_objext conftest.beam conftest.$ac_ext
21907 if test $ac_cv_type_getgroups = cross; then
21908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21909 /* end confdefs.h. */
21910 #include <unistd.h>
21912 _ACEOF
21913 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21914 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
21915 ac_cv_type_getgroups=gid_t
21916 else
21917 ac_cv_type_getgroups=int
21919 rm -f conftest*
21923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
21924 $as_echo "$ac_cv_type_getgroups" >&6; }
21926 cat >>confdefs.h <<_ACEOF
21927 #define GETGROUPS_T $ac_cv_type_getgroups
21928 _ACEOF
21935 if false; then
21936 GL_COND_LIBTOOL_TRUE=
21937 GL_COND_LIBTOOL_FALSE='#'
21938 else
21939 GL_COND_LIBTOOL_TRUE='#'
21940 GL_COND_LIBTOOL_FALSE=
21943 gl_cond_libtool=false
21944 gl_libdeps=
21945 gl_ltlibdeps=
21946 gl_m4_base='m4'
21956 gl_source_base='lib'
21959 if test $ac_cv_func_alloca_works = no; then
21963 # Define an additional variable used in the Makefile substitution.
21964 if test $ac_cv_working_alloca_h = yes; then
21965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
21966 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
21967 if test "${gl_cv_rpl_alloca+set}" = set; then :
21968 $as_echo_n "(cached) " >&6
21969 else
21971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21972 /* end confdefs.h. */
21974 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
21975 Need own alloca
21976 #endif
21978 _ACEOF
21979 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21980 $EGREP "Need own alloca" >/dev/null 2>&1; then :
21981 gl_cv_rpl_alloca=yes
21982 else
21983 gl_cv_rpl_alloca=no
21985 rm -f conftest*
21989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
21990 $as_echo "$gl_cv_rpl_alloca" >&6; }
21991 if test $gl_cv_rpl_alloca = yes; then
21993 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
21995 ALLOCA_H=alloca.h
21996 else
21997 ALLOCA_H=
21999 else
22000 ALLOCA_H=alloca.h
22003 if test -n "$ALLOCA_H"; then
22004 GL_GENERATE_ALLOCA_H_TRUE=
22005 GL_GENERATE_ALLOCA_H_FALSE='#'
22006 else
22007 GL_GENERATE_ALLOCA_H_TRUE='#'
22008 GL_GENERATE_ALLOCA_H_FALSE=
22016 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22017 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22019 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22020 # programs in the package would end up linked with that potentially-shared
22021 # library, inducing unnecessary run-time overhead.
22022 LIB_CLOCK_GETTIME=
22024 gl_saved_libs=$LIBS
22025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22026 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22027 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22028 $as_echo_n "(cached) " >&6
22029 else
22030 ac_func_search_save_LIBS=$LIBS
22031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22032 /* end confdefs.h. */
22034 /* Override any GCC internal prototype to avoid an error.
22035 Use char because int might match the return type of a GCC
22036 builtin and then its argument prototype would still apply. */
22037 #ifdef __cplusplus
22038 extern "C"
22039 #endif
22040 char clock_gettime ();
22042 main ()
22044 return clock_gettime ();
22046 return 0;
22048 _ACEOF
22049 for ac_lib in '' rt posix4; do
22050 if test -z "$ac_lib"; then
22051 ac_res="none required"
22052 else
22053 ac_res=-l$ac_lib
22054 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22056 if ac_fn_c_try_link "$LINENO"; then :
22057 ac_cv_search_clock_gettime=$ac_res
22059 rm -f core conftest.err conftest.$ac_objext \
22060 conftest$ac_exeext
22061 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22062 break
22064 done
22065 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22067 else
22068 ac_cv_search_clock_gettime=no
22070 rm conftest.$ac_ext
22071 LIBS=$ac_func_search_save_LIBS
22073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22074 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22075 ac_res=$ac_cv_search_clock_gettime
22076 if test "$ac_res" != no; then :
22077 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22078 test "$ac_cv_search_clock_gettime" = "none required" ||
22079 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22082 for ac_func in clock_gettime clock_settime
22083 do :
22084 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22085 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22086 eval as_val=\$$as_ac_var
22087 if test "x$as_val" = x""yes; then :
22088 cat >>confdefs.h <<_ACEOF
22089 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22090 _ACEOF
22093 done
22095 LIBS=$gl_saved_libs
22102 cat >>confdefs.h <<_ACEOF
22103 #define GNULIB_CLOSE_STREAM 1
22104 _ACEOF
22133 if test $gl_cv_have_include_next = yes; then
22134 gl_cv_next_dirent_h='<'dirent.h'>'
22135 else
22136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22137 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22138 if test "${gl_cv_next_dirent_h+set}" = set; then :
22139 $as_echo_n "(cached) " >&6
22140 else
22142 if test $ac_cv_header_dirent_h = yes; then
22145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22146 /* end confdefs.h. */
22147 #include <dirent.h>
22149 _ACEOF
22150 case "$host_os" in
22151 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22152 *) gl_absname_cpp="$ac_cpp" ;;
22153 esac
22155 case "$host_os" in
22156 mingw*)
22157 gl_dirsep_regex='[/\\]'
22160 gl_dirsep_regex='\/'
22162 esac
22163 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22165 gl_header_literal_regex=`echo 'dirent.h' \
22166 | sed -e "$gl_make_literal_regex_sed"`
22167 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22168 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22169 s|^/[^/]|//&|
22173 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22174 sed -n "$gl_absolute_header_sed"`'"'
22175 else
22176 gl_cv_next_dirent_h='<'dirent.h'>'
22181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22182 $as_echo "$gl_cv_next_dirent_h" >&6; }
22184 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22186 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22187 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22188 gl_next_as_first_directive='<'dirent.h'>'
22189 else
22190 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22191 gl_next_as_first_directive=$gl_cv_next_dirent_h
22193 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22198 if test $ac_cv_header_dirent_h = yes; then
22199 HAVE_DIRENT_H=1
22200 else
22201 HAVE_DIRENT_H=0
22213 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22216 if test $HAVE_DUP2 = 1; then
22217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22218 $as_echo_n "checking whether dup2 works... " >&6; }
22219 if test "${gl_cv_func_dup2_works+set}" = set; then :
22220 $as_echo_n "(cached) " >&6
22221 else
22222 if test "$cross_compiling" = yes; then :
22223 case "$host_os" in
22224 mingw*) # on this platform, dup2 always returns 0 for success
22225 gl_cv_func_dup2_works="guessing no" ;;
22226 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22227 gl_cv_func_dup2_works="guessing no" ;;
22228 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22229 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22230 gl_cv_func_dup2_works="guessing no" ;;
22231 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22232 gl_cv_func_dup2_works="guessing no" ;;
22233 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22234 gl_cv_func_dup2_works="guessing no" ;;
22235 *) gl_cv_func_dup2_works="guessing yes" ;;
22236 esac
22237 else
22238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22239 /* end confdefs.h. */
22241 #include <unistd.h>
22242 #include <fcntl.h>
22243 #include <errno.h>
22245 main ()
22247 int result = 0;
22248 #ifdef FD_CLOEXEC
22249 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22250 result |= 1;
22251 #endif
22252 if (dup2 (1, 1) == 0)
22253 result |= 2;
22254 #ifdef FD_CLOEXEC
22255 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22256 result |= 4;
22257 #endif
22258 close (0);
22259 if (dup2 (0, 0) != -1)
22260 result |= 8;
22261 /* Many gnulib modules require POSIX conformance of EBADF. */
22262 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22263 result |= 16;
22264 /* Flush out a cygwin core dump. */
22265 if (dup2 (2, -1) != -1 || errno != EBADF)
22266 result |= 32;
22267 return result;
22270 return 0;
22273 _ACEOF
22274 if ac_fn_c_try_run "$LINENO"; then :
22275 gl_cv_func_dup2_works=yes
22276 else
22277 gl_cv_func_dup2_works=no
22279 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22280 conftest.$ac_objext conftest.beam conftest.$ac_ext
22285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22286 $as_echo "$gl_cv_func_dup2_works" >&6; }
22287 case "$gl_cv_func_dup2_works" in
22288 *yes) ;;
22290 REPLACE_DUP2=1
22292 esac
22296 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22305 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22314 GNULIB_DUP2=1
22326 GNULIB_ENVIRON=1
22336 LIB_EXECINFO=''
22337 EXECINFO_H='execinfo.h'
22339 if test $ac_cv_header_execinfo_h = yes; then
22340 gl_saved_libs=$LIBS
22341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22342 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22343 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22344 $as_echo_n "(cached) " >&6
22345 else
22346 ac_func_search_save_LIBS=$LIBS
22347 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22348 /* end confdefs.h. */
22350 /* Override any GCC internal prototype to avoid an error.
22351 Use char because int might match the return type of a GCC
22352 builtin and then its argument prototype would still apply. */
22353 #ifdef __cplusplus
22354 extern "C"
22355 #endif
22356 char backtrace_symbols_fd ();
22358 main ()
22360 return backtrace_symbols_fd ();
22362 return 0;
22364 _ACEOF
22365 for ac_lib in '' execinfo; do
22366 if test -z "$ac_lib"; then
22367 ac_res="none required"
22368 else
22369 ac_res=-l$ac_lib
22370 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22372 if ac_fn_c_try_link "$LINENO"; then :
22373 ac_cv_search_backtrace_symbols_fd=$ac_res
22375 rm -f core conftest.err conftest.$ac_objext \
22376 conftest$ac_exeext
22377 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22378 break
22380 done
22381 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22383 else
22384 ac_cv_search_backtrace_symbols_fd=no
22386 rm conftest.$ac_ext
22387 LIBS=$ac_func_search_save_LIBS
22389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22390 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22391 ac_res=$ac_cv_search_backtrace_symbols_fd
22392 if test "$ac_res" != no; then :
22393 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22394 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22395 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22398 LIBS=$gl_saved_libs
22399 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22402 if test -n "$EXECINFO_H"; then
22411 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22417 if test -n "$EXECINFO_H"; then
22418 GL_GENERATE_EXECINFO_H_TRUE=
22419 GL_GENERATE_EXECINFO_H_FALSE='#'
22420 else
22421 GL_GENERATE_EXECINFO_H_TRUE='#'
22422 GL_GENERATE_EXECINFO_H_FALSE=
22433 if test $ac_cv_func_faccessat = no; then
22434 HAVE_FACCESSAT=0
22437 if test $HAVE_FACCESSAT = 0; then
22446 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22449 for ac_func in access
22450 do :
22451 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22452 if test "x$ac_cv_func_access" = x""yes; then :
22453 cat >>confdefs.h <<_ACEOF
22454 #define HAVE_ACCESS 1
22455 _ACEOF
22458 done
22464 cat >>confdefs.h <<_ACEOF
22465 #define GNULIB_FACCESSAT 1
22466 _ACEOF
22474 GNULIB_FACCESSAT=1
22485 if test $ac_cv_func_fcntl = no; then
22489 if test $ac_cv_func_fcntl = no; then
22490 HAVE_FCNTL=0
22491 else
22492 REPLACE_FCNTL=1
22495 else
22496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
22497 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
22498 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
22499 $as_echo_n "(cached) " >&6
22500 else
22501 if test "$cross_compiling" = yes; then :
22502 # Guess that it works on glibc systems
22503 case $host_os in #((
22504 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
22505 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
22506 esac
22507 else
22508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22509 /* end confdefs.h. */
22511 #include <fcntl.h>
22512 #include <errno.h>
22515 main ()
22517 int result = 0;
22518 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
22519 if (errno != EINVAL) result |= 2;
22520 return result;
22523 return 0;
22525 _ACEOF
22526 if ac_fn_c_try_run "$LINENO"; then :
22527 gl_cv_func_fcntl_f_dupfd_works=yes
22528 else
22529 gl_cv_func_fcntl_f_dupfd_works=no
22531 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22532 conftest.$ac_objext conftest.beam conftest.$ac_ext
22536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
22537 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
22538 case $gl_cv_func_fcntl_f_dupfd_works in
22539 *yes) ;;
22543 if test $ac_cv_func_fcntl = no; then
22544 HAVE_FCNTL=0
22545 else
22546 REPLACE_FCNTL=1
22550 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
22552 esac
22554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
22555 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
22556 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
22557 $as_echo_n "(cached) " >&6
22558 else
22559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22560 /* end confdefs.h. */
22562 #include <fcntl.h>
22563 #ifndef F_DUPFD_CLOEXEC
22564 choke me
22565 #endif
22568 main ()
22572 return 0;
22574 _ACEOF
22575 if ac_fn_c_try_compile "$LINENO"; then :
22576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22577 /* end confdefs.h. */
22579 #ifdef __linux__
22580 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
22581 it to support the semantics on older kernels that failed with EINVAL. */
22582 choke me
22583 #endif
22586 main ()
22590 return 0;
22592 _ACEOF
22593 if ac_fn_c_try_compile "$LINENO"; then :
22594 gl_cv_func_fcntl_f_dupfd_cloexec=yes
22595 else
22596 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
22598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22599 else
22600 gl_cv_func_fcntl_f_dupfd_cloexec=no
22602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
22605 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
22606 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
22610 if test $ac_cv_func_fcntl = no; then
22611 HAVE_FCNTL=0
22612 else
22613 REPLACE_FCNTL=1
22620 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
22629 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
22637 GNULIB_FCNTL=1
22654 if test $gl_cv_have_include_next = yes; then
22655 gl_cv_next_fcntl_h='<'fcntl.h'>'
22656 else
22657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
22658 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
22659 if test "${gl_cv_next_fcntl_h+set}" = set; then :
22660 $as_echo_n "(cached) " >&6
22661 else
22663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22664 /* end confdefs.h. */
22665 #include <fcntl.h>
22667 _ACEOF
22668 case "$host_os" in
22669 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22670 *) gl_absname_cpp="$ac_cpp" ;;
22671 esac
22673 case "$host_os" in
22674 mingw*)
22675 gl_dirsep_regex='[/\\]'
22678 gl_dirsep_regex='\/'
22680 esac
22681 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22683 gl_header_literal_regex=`echo 'fcntl.h' \
22684 | sed -e "$gl_make_literal_regex_sed"`
22685 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22686 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22687 s|^/[^/]|//&|
22691 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22692 sed -n "$gl_absolute_header_sed"`'"'
22696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
22697 $as_echo "$gl_cv_next_fcntl_h" >&6; }
22699 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
22701 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22702 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22703 gl_next_as_first_directive='<'fcntl.h'>'
22704 else
22705 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22706 gl_next_as_first_directive=$gl_cv_next_fcntl_h
22708 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
22724 LIB_FDATASYNC=
22727 if test $ac_cv_have_decl_fdatasync = no; then
22728 HAVE_DECL_FDATASYNC=0
22729 for ac_func in fdatasync
22730 do :
22731 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
22732 if test "x$ac_cv_func_fdatasync" = x""yes; then :
22733 cat >>confdefs.h <<_ACEOF
22734 #define HAVE_FDATASYNC 1
22735 _ACEOF
22738 done
22740 if test $ac_cv_func_fdatasync = no; then
22741 HAVE_FDATASYNC=0
22743 else
22744 gl_saved_libs=$LIBS
22745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
22746 $as_echo_n "checking for library containing fdatasync... " >&6; }
22747 if test "${ac_cv_search_fdatasync+set}" = set; then :
22748 $as_echo_n "(cached) " >&6
22749 else
22750 ac_func_search_save_LIBS=$LIBS
22751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22752 /* end confdefs.h. */
22754 /* Override any GCC internal prototype to avoid an error.
22755 Use char because int might match the return type of a GCC
22756 builtin and then its argument prototype would still apply. */
22757 #ifdef __cplusplus
22758 extern "C"
22759 #endif
22760 char fdatasync ();
22762 main ()
22764 return fdatasync ();
22766 return 0;
22768 _ACEOF
22769 for ac_lib in '' rt posix4; do
22770 if test -z "$ac_lib"; then
22771 ac_res="none required"
22772 else
22773 ac_res=-l$ac_lib
22774 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22776 if ac_fn_c_try_link "$LINENO"; then :
22777 ac_cv_search_fdatasync=$ac_res
22779 rm -f core conftest.err conftest.$ac_objext \
22780 conftest$ac_exeext
22781 if test "${ac_cv_search_fdatasync+set}" = set; then :
22782 break
22784 done
22785 if test "${ac_cv_search_fdatasync+set}" = set; then :
22787 else
22788 ac_cv_search_fdatasync=no
22790 rm conftest.$ac_ext
22791 LIBS=$ac_func_search_save_LIBS
22793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
22794 $as_echo "$ac_cv_search_fdatasync" >&6; }
22795 ac_res=$ac_cv_search_fdatasync
22796 if test "$ac_res" != no; then :
22797 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22798 test "$ac_cv_search_fdatasync" = "none required" ||
22799 LIB_FDATASYNC=$ac_cv_search_fdatasync
22802 LIBS=$gl_saved_libs
22805 if test $HAVE_FDATASYNC = 0; then
22814 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
22822 GNULIB_FDATASYNC=1
22833 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
22834 #include <dirent.h>
22837 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
22838 ac_have_decl=1
22839 else
22840 ac_have_decl=0
22843 cat >>confdefs.h <<_ACEOF
22844 #define HAVE_DECL_FDOPENDIR $ac_have_decl
22845 _ACEOF
22846 if test $ac_have_decl = 1; then :
22848 else
22849 HAVE_DECL_FDOPENDIR=0
22853 if test $ac_cv_func_fdopendir = no; then
22854 HAVE_FDOPENDIR=0
22855 else
22856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
22857 $as_echo_n "checking whether fdopendir works... " >&6; }
22858 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
22859 $as_echo_n "(cached) " >&6
22860 else
22861 if test "$cross_compiling" = yes; then :
22862 case "$host_os" in
22863 # Guess yes on glibc systems.
22864 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
22865 # If we don't know, assume the worst.
22866 *) gl_cv_func_fdopendir_works="guessing no" ;;
22867 esac
22869 else
22870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22871 /* end confdefs.h. */
22873 #include <dirent.h>
22874 #include <fcntl.h>
22875 #include <unistd.h>
22876 #if !HAVE_DECL_FDOPENDIR
22877 extern
22878 # ifdef __cplusplus
22880 # endif
22881 DIR *fdopendir (int);
22882 #endif
22885 main ()
22887 int result = 0;
22888 int fd = open ("conftest.c", O_RDONLY);
22889 if (fd < 0) result |= 1;
22890 if (fdopendir (fd)) result |= 2;
22891 if (close (fd)) result |= 4;
22892 return result;
22894 return 0;
22896 _ACEOF
22897 if ac_fn_c_try_run "$LINENO"; then :
22898 gl_cv_func_fdopendir_works=yes
22899 else
22900 gl_cv_func_fdopendir_works=no
22902 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22903 conftest.$ac_objext conftest.beam conftest.$ac_ext
22907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
22908 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
22909 case "$gl_cv_func_fdopendir_works" in
22910 *yes) ;;
22912 REPLACE_FDOPENDIR=1
22914 esac
22917 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
22926 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
22934 GNULIB_FDOPENDIR=1
22942 cat >>confdefs.h <<_ACEOF
22943 #define GNULIB_FDOPENDIR 1
22944 _ACEOF
22954 fp_headers='
22955 # include <stdio.h>
22956 # if HAVE_STDIO_EXT_H
22957 # include <stdio_ext.h>
22958 # endif
22960 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
22962 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
22963 ac_have_decl=1
22964 else
22965 ac_have_decl=0
22968 cat >>confdefs.h <<_ACEOF
22969 #define HAVE_DECL___FPENDING $ac_have_decl
22970 _ACEOF
22973 if test $ac_cv_func___fpending = no; then
22982 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
22985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
22986 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
22987 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
22988 $as_echo_n "(cached) " >&6
22989 else
22991 for ac_expr in \
22993 '# glibc2' \
22994 'fp->_IO_write_ptr - fp->_IO_write_base' \
22996 '# traditional Unix' \
22997 'fp->_ptr - fp->_base' \
22999 '# BSD' \
23000 'fp->_p - fp->_bf._base' \
23002 '# SCO, Unixware' \
23003 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
23005 '# QNX' \
23006 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
23008 '# old glibc?' \
23009 'fp->__bufp - fp->__buffer' \
23011 '# old glibc iostream?' \
23012 'fp->_pptr - fp->_pbase' \
23014 '# emx+gcc' \
23015 'fp->_ptr - fp->_buffer' \
23017 '# Minix' \
23018 'fp->_ptr - fp->_buf' \
23020 '# Plan9' \
23021 'fp->wp - fp->buf' \
23023 '# VMS' \
23024 '(*fp)->_ptr - (*fp)->_base' \
23026 '# e.g., DGUX R4.11; the info is not available' \
23028 ; do
23030 # Skip each embedded comment.
23031 case "$ac_expr" in '#'*) continue;; esac
23033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23034 /* end confdefs.h. */
23035 #include <stdio.h>
23037 main ()
23039 FILE *fp = stdin; (void) ($ac_expr);
23041 return 0;
23043 _ACEOF
23044 if ac_fn_c_try_compile "$LINENO"; then :
23045 fp_done=yes
23048 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23049 test "$fp_done" = yes && break
23050 done
23052 ac_cv_sys_pending_output_n_bytes=$ac_expr
23056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
23057 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
23059 cat >>confdefs.h <<_ACEOF
23060 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
23061 _ACEOF
23071 if test $ac_cv_func_fstatat = no; then
23072 HAVE_FSTATAT=0
23073 else
23074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
23075 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
23076 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
23077 $as_echo_n "(cached) " >&6
23078 else
23079 if test "$cross_compiling" = yes; then :
23080 case "$host_os" in
23081 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
23082 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
23083 esac
23085 else
23086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23087 /* end confdefs.h. */
23089 #include <fcntl.h>
23090 #include <sys/stat.h>
23092 main (void)
23094 struct stat a;
23095 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23098 _ACEOF
23099 if ac_fn_c_try_run "$LINENO"; then :
23100 gl_cv_func_fstatat_zero_flag=yes
23101 else
23102 gl_cv_func_fstatat_zero_flag=no
23104 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23105 conftest.$ac_objext conftest.beam conftest.$ac_ext
23110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23111 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23113 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23114 *yes+*yes) ;;
23115 *) REPLACE_FSTATAT=1
23116 case $gl_cv_func_fstatat_zero_flag in
23117 *yes)
23119 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23122 esac
23124 esac
23127 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23136 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23144 GNULIB_FSTATAT=1
23153 if test $ac_cv_func_fsync = no; then
23154 HAVE_FSYNC=0
23157 if test $HAVE_FSYNC = 0; then
23166 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23175 GNULIB_FSYNC=1
23183 # Persuade glibc <stdlib.h> to declare getloadavg().
23186 gl_save_LIBS=$LIBS
23188 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23189 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23190 HAVE_GETLOADAVG=1
23191 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23192 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23194 else
23195 gl_func_getloadavg_done=no
23197 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23198 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23199 # to get the right answer into the cache.
23200 # For kstat on solaris, we need to test for libelf and libkvm to force the
23201 # definition of SVR4 below.
23202 if test $gl_func_getloadavg_done = no; then
23203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23204 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23205 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23206 $as_echo_n "(cached) " >&6
23207 else
23208 ac_check_lib_save_LIBS=$LIBS
23209 LIBS="-lelf $LIBS"
23210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23211 /* end confdefs.h. */
23213 /* Override any GCC internal prototype to avoid an error.
23214 Use char because int might match the return type of a GCC
23215 builtin and then its argument prototype would still apply. */
23216 #ifdef __cplusplus
23217 extern "C"
23218 #endif
23219 char elf_begin ();
23221 main ()
23223 return elf_begin ();
23225 return 0;
23227 _ACEOF
23228 if ac_fn_c_try_link "$LINENO"; then :
23229 ac_cv_lib_elf_elf_begin=yes
23230 else
23231 ac_cv_lib_elf_elf_begin=no
23233 rm -f core conftest.err conftest.$ac_objext \
23234 conftest$ac_exeext conftest.$ac_ext
23235 LIBS=$ac_check_lib_save_LIBS
23237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23238 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23239 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23240 LIBS="-lelf $LIBS"
23243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23244 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23245 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23246 $as_echo_n "(cached) " >&6
23247 else
23248 ac_check_lib_save_LIBS=$LIBS
23249 LIBS="-lkvm $LIBS"
23250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23251 /* end confdefs.h. */
23253 /* Override any GCC internal prototype to avoid an error.
23254 Use char because int might match the return type of a GCC
23255 builtin and then its argument prototype would still apply. */
23256 #ifdef __cplusplus
23257 extern "C"
23258 #endif
23259 char kvm_open ();
23261 main ()
23263 return kvm_open ();
23265 return 0;
23267 _ACEOF
23268 if ac_fn_c_try_link "$LINENO"; then :
23269 ac_cv_lib_kvm_kvm_open=yes
23270 else
23271 ac_cv_lib_kvm_kvm_open=no
23273 rm -f core conftest.err conftest.$ac_objext \
23274 conftest$ac_exeext conftest.$ac_ext
23275 LIBS=$ac_check_lib_save_LIBS
23277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23278 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23279 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23280 LIBS="-lkvm $LIBS"
23283 # Check for the 4.4BSD definition of getloadavg.
23284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23285 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23286 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23287 $as_echo_n "(cached) " >&6
23288 else
23289 ac_check_lib_save_LIBS=$LIBS
23290 LIBS="-lutil $LIBS"
23291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23292 /* end confdefs.h. */
23294 /* Override any GCC internal prototype to avoid an error.
23295 Use char because int might match the return type of a GCC
23296 builtin and then its argument prototype would still apply. */
23297 #ifdef __cplusplus
23298 extern "C"
23299 #endif
23300 char getloadavg ();
23302 main ()
23304 return getloadavg ();
23306 return 0;
23308 _ACEOF
23309 if ac_fn_c_try_link "$LINENO"; then :
23310 ac_cv_lib_util_getloadavg=yes
23311 else
23312 ac_cv_lib_util_getloadavg=no
23314 rm -f core conftest.err conftest.$ac_objext \
23315 conftest$ac_exeext conftest.$ac_ext
23316 LIBS=$ac_check_lib_save_LIBS
23318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23319 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23320 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23321 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23326 if test $gl_func_getloadavg_done = no; then
23327 # There is a commonly available library for RS/6000 AIX.
23328 # Since it is not a standard part of AIX, it might be installed locally.
23329 gl_getloadavg_LIBS=$LIBS
23330 LIBS="-L/usr/local/lib $LIBS"
23331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23332 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23333 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23334 $as_echo_n "(cached) " >&6
23335 else
23336 ac_check_lib_save_LIBS=$LIBS
23337 LIBS="-lgetloadavg $LIBS"
23338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23339 /* end confdefs.h. */
23341 /* Override any GCC internal prototype to avoid an error.
23342 Use char because int might match the return type of a GCC
23343 builtin and then its argument prototype would still apply. */
23344 #ifdef __cplusplus
23345 extern "C"
23346 #endif
23347 char getloadavg ();
23349 main ()
23351 return getloadavg ();
23353 return 0;
23355 _ACEOF
23356 if ac_fn_c_try_link "$LINENO"; then :
23357 ac_cv_lib_getloadavg_getloadavg=yes
23358 else
23359 ac_cv_lib_getloadavg_getloadavg=no
23361 rm -f core conftest.err conftest.$ac_objext \
23362 conftest$ac_exeext conftest.$ac_ext
23363 LIBS=$ac_check_lib_save_LIBS
23365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23366 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23367 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23368 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23369 else
23370 LIBS=$gl_getloadavg_LIBS
23375 # Set up the replacement function if necessary.
23376 if test $gl_func_getloadavg_done = no; then
23377 HAVE_GETLOADAVG=0
23379 # Solaris has libkstat which does not require root.
23380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23381 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23382 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23383 $as_echo_n "(cached) " >&6
23384 else
23385 ac_check_lib_save_LIBS=$LIBS
23386 LIBS="-lkstat $LIBS"
23387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23388 /* end confdefs.h. */
23390 /* Override any GCC internal prototype to avoid an error.
23391 Use char because int might match the return type of a GCC
23392 builtin and then its argument prototype would still apply. */
23393 #ifdef __cplusplus
23394 extern "C"
23395 #endif
23396 char kstat_open ();
23398 main ()
23400 return kstat_open ();
23402 return 0;
23404 _ACEOF
23405 if ac_fn_c_try_link "$LINENO"; then :
23406 ac_cv_lib_kstat_kstat_open=yes
23407 else
23408 ac_cv_lib_kstat_kstat_open=no
23410 rm -f core conftest.err conftest.$ac_objext \
23411 conftest$ac_exeext conftest.$ac_ext
23412 LIBS=$ac_check_lib_save_LIBS
23414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23415 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23416 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23417 cat >>confdefs.h <<_ACEOF
23418 #define HAVE_LIBKSTAT 1
23419 _ACEOF
23421 LIBS="-lkstat $LIBS"
23425 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23427 # AIX has libperfstat which does not require root
23428 if test $gl_func_getloadavg_done = no; then
23429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23430 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23431 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23432 $as_echo_n "(cached) " >&6
23433 else
23434 ac_check_lib_save_LIBS=$LIBS
23435 LIBS="-lperfstat $LIBS"
23436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23437 /* end confdefs.h. */
23439 /* Override any GCC internal prototype to avoid an error.
23440 Use char because int might match the return type of a GCC
23441 builtin and then its argument prototype would still apply. */
23442 #ifdef __cplusplus
23443 extern "C"
23444 #endif
23445 char perfstat_cpu_total ();
23447 main ()
23449 return perfstat_cpu_total ();
23451 return 0;
23453 _ACEOF
23454 if ac_fn_c_try_link "$LINENO"; then :
23455 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23456 else
23457 ac_cv_lib_perfstat_perfstat_cpu_total=no
23459 rm -f core conftest.err conftest.$ac_objext \
23460 conftest$ac_exeext conftest.$ac_ext
23461 LIBS=$ac_check_lib_save_LIBS
23463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
23464 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
23465 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
23466 cat >>confdefs.h <<_ACEOF
23467 #define HAVE_LIBPERFSTAT 1
23468 _ACEOF
23470 LIBS="-lperfstat $LIBS"
23474 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
23477 if test $gl_func_getloadavg_done = no; then
23478 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
23479 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
23480 gl_func_getloadavg_done=yes
23482 $as_echo "#define DGUX 1" >>confdefs.h
23484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
23485 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
23486 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
23487 $as_echo_n "(cached) " >&6
23488 else
23489 ac_check_lib_save_LIBS=$LIBS
23490 LIBS="-ldgc $LIBS"
23491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23492 /* end confdefs.h. */
23494 /* Override any GCC internal prototype to avoid an error.
23495 Use char because int might match the return type of a GCC
23496 builtin and then its argument prototype would still apply. */
23497 #ifdef __cplusplus
23498 extern "C"
23499 #endif
23500 char dg_sys_info ();
23502 main ()
23504 return dg_sys_info ();
23506 return 0;
23508 _ACEOF
23509 if ac_fn_c_try_link "$LINENO"; then :
23510 ac_cv_lib_dgc_dg_sys_info=yes
23511 else
23512 ac_cv_lib_dgc_dg_sys_info=no
23514 rm -f core conftest.err conftest.$ac_objext \
23515 conftest$ac_exeext conftest.$ac_ext
23516 LIBS=$ac_check_lib_save_LIBS
23518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
23519 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
23520 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
23521 cat >>confdefs.h <<_ACEOF
23522 #define HAVE_LIBDGC 1
23523 _ACEOF
23525 LIBS="-ldgc $LIBS"
23537 if test "x$gl_save_LIBS" = x; then
23538 GETLOADAVG_LIBS=$LIBS
23539 else
23540 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
23542 LIBS=$gl_save_LIBS
23545 # Test whether the system declares getloadavg. Solaris has the function
23546 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
23547 for ac_header in sys/loadavg.h
23548 do :
23549 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
23550 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
23551 cat >>confdefs.h <<_ACEOF
23552 #define HAVE_SYS_LOADAVG_H 1
23553 _ACEOF
23557 done
23559 if test $ac_cv_header_sys_loadavg_h = yes; then
23560 HAVE_SYS_LOADAVG_H=1
23561 else
23562 HAVE_SYS_LOADAVG_H=0
23564 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
23565 # include <sys/loadavg.h>
23566 #endif
23567 #include <stdlib.h>
23569 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
23571 else
23572 HAVE_DECL_GETLOADAVG=0
23576 if test $HAVE_GETLOADAVG = 0; then
23585 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
23588 # Figure out what our getloadavg.c needs.
23592 # On HPUX9, an unprivileged user can get load averages this way.
23593 if test $gl_func_getloadavg_done = no; then
23594 for ac_func in pstat_getdynamic
23595 do :
23596 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
23597 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
23598 cat >>confdefs.h <<_ACEOF
23599 #define HAVE_PSTAT_GETDYNAMIC 1
23600 _ACEOF
23601 gl_func_getloadavg_done=yes
23603 done
23607 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
23608 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
23609 # Irix 4.0.5F has the header but not the library.
23610 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
23611 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
23612 gl_func_getloadavg_done=yes
23614 $as_echo "#define SVR4 1" >>confdefs.h
23618 if test $gl_func_getloadavg_done = no; then
23619 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
23620 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
23621 gl_func_getloadavg_done=yes
23623 $as_echo "#define UMAX 1" >>confdefs.h
23626 $as_echo "#define UMAX4_3 1" >>confdefs.h
23633 if test $gl_func_getloadavg_done = no; then
23634 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
23635 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
23636 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
23643 if test $gl_func_getloadavg_done = no; then
23644 for ac_header in mach/mach.h
23645 do :
23646 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
23647 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
23648 cat >>confdefs.h <<_ACEOF
23649 #define HAVE_MACH_MACH_H 1
23650 _ACEOF
23654 done
23658 for ac_header in nlist.h
23659 do :
23660 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
23661 if test "x$ac_cv_header_nlist_h" = x""yes; then :
23662 cat >>confdefs.h <<_ACEOF
23663 #define HAVE_NLIST_H 1
23664 _ACEOF
23665 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
23667 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
23669 cat >>confdefs.h <<_ACEOF
23670 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
23671 _ACEOF
23676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23677 /* end confdefs.h. */
23678 #include <nlist.h>
23680 main ()
23682 struct nlist x;
23683 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
23684 x.n_un.n_name = "";
23685 #else
23686 x.n_name = "";
23687 #endif
23689 return 0;
23691 _ACEOF
23692 if ac_fn_c_try_link "$LINENO"; then :
23694 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
23697 rm -f core conftest.err conftest.$ac_objext \
23698 conftest$ac_exeext conftest.$ac_ext
23702 done
23710 GNULIB_GETLOADAVG=1
23721 if test $REPLACE_GETOPT = 1; then
23730 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23740 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23745 GNULIB_GL_UNISTD_H_GETOPT=1
23754 REPLACE_GETOPT=0
23755 if test -n "$gl_replace_getopt"; then
23756 REPLACE_GETOPT=1
23759 if test $REPLACE_GETOPT = 1; then
23761 GETOPT_H=getopt.h
23763 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
23769 if test $REPLACE_GETOPT = 1; then
23778 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23788 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23793 GNULIB_GL_UNISTD_H_GETOPT=1
23807 gl_gettimeofday_timezone=void
23808 if test $ac_cv_func_gettimeofday != yes; then
23809 HAVE_GETTIMEOFDAY=0
23810 else
23814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
23815 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
23816 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
23817 $as_echo_n "(cached) " >&6
23818 else
23819 if test "$cross_compiling" = yes; then :
23820 # When cross-compiling:
23821 case "$host_os" in
23822 # Guess all is fine on glibc systems.
23823 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
23824 # If we don't know, assume the worst.
23825 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
23826 esac
23828 else
23829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23830 /* end confdefs.h. */
23831 #include <string.h>
23832 #include <sys/time.h>
23833 #include <time.h>
23834 #include <stdlib.h>
23837 main ()
23840 time_t t = 0;
23841 struct tm *lt;
23842 struct tm saved_lt;
23843 struct timeval tv;
23844 lt = localtime (&t);
23845 saved_lt = *lt;
23846 gettimeofday (&tv, NULL);
23847 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
23850 return 0;
23852 _ACEOF
23853 if ac_fn_c_try_run "$LINENO"; then :
23854 gl_cv_func_gettimeofday_clobber=no
23855 else
23856 gl_cv_func_gettimeofday_clobber=yes
23858 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23859 conftest.$ac_objext conftest.beam conftest.$ac_ext
23863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
23864 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
23866 case "$gl_cv_func_gettimeofday_clobber" in
23867 *yes)
23868 REPLACE_GETTIMEOFDAY=1
23871 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
23874 $as_echo "#define localtime rpl_localtime" >>confdefs.h
23878 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
23881 esac
23883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
23884 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
23885 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
23886 $as_echo_n "(cached) " >&6
23887 else
23888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23889 /* end confdefs.h. */
23890 #include <sys/time.h>
23891 struct timeval c;
23892 int gettimeofday (struct timeval *restrict, void *restrict);
23895 main ()
23897 /* glibc uses struct timezone * rather than the POSIX void *
23898 if _GNU_SOURCE is defined. However, since the only portable
23899 use of gettimeofday uses NULL as the second parameter, and
23900 since the glibc definition is actually more typesafe, it is
23901 not worth wrapping this to get a compliant signature. */
23902 int (*f) (struct timeval *restrict, void *restrict)
23903 = gettimeofday;
23904 int x = f (&c, 0);
23905 return !(x | c.tv_sec | c.tv_usec);
23908 return 0;
23910 _ACEOF
23911 if ac_fn_c_try_compile "$LINENO"; then :
23912 gl_cv_func_gettimeofday_posix_signature=yes
23913 else
23914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23915 /* end confdefs.h. */
23916 #include <sys/time.h>
23917 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
23920 main ()
23924 return 0;
23926 _ACEOF
23927 if ac_fn_c_try_compile "$LINENO"; then :
23928 gl_cv_func_gettimeofday_posix_signature=almost
23929 else
23930 gl_cv_func_gettimeofday_posix_signature=no
23932 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
23937 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
23938 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
23939 gl_gettimeofday_timezone='struct timezone'
23940 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
23941 REPLACE_GETTIMEOFDAY=1
23943 if test $REPLACE_STRUCT_TIMEVAL = 1; then
23944 REPLACE_GETTIMEOFDAY=1
23949 cat >>confdefs.h <<_ACEOF
23950 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
23951 _ACEOF
23954 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
23963 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
23966 for ac_header in sys/timeb.h
23967 do :
23968 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
23969 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
23970 cat >>confdefs.h <<_ACEOF
23971 #define HAVE_SYS_TIMEB_H 1
23972 _ACEOF
23976 done
23978 for ac_func in _ftime
23979 do :
23980 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
23981 if test "x$ac_cv_func__ftime" = x""yes; then :
23982 cat >>confdefs.h <<_ACEOF
23983 #define HAVE__FTIME 1
23984 _ACEOF
23987 done
23996 GNULIB_GETTIMEOFDAY=1
24007 if test $ac_cv_func_lstat = yes; then
24009 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
24010 *no)
24011 REPLACE_LSTAT=1
24013 esac
24014 else
24015 HAVE_LSTAT=0
24018 if test $REPLACE_LSTAT = 1; then
24027 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
24036 GNULIB_LSTAT=1
24047 if test $ac_cv_have_decl_memrchr = no; then
24048 HAVE_DECL_MEMRCHR=0
24051 for ac_func in memrchr
24052 do :
24053 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
24054 if test "x$ac_cv_func_memrchr" = x""yes; then :
24055 cat >>confdefs.h <<_ACEOF
24056 #define HAVE_MEMRCHR 1
24057 _ACEOF
24060 done
24063 if test $ac_cv_func_memrchr = no; then
24072 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24081 GNULIB_MEMRCHR=1
24093 if test $APPLE_UNIVERSAL_BUILD = 1; then
24094 # A universal build on Apple Mac OS X platforms.
24095 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24096 # But we need a configuration result that is valid in both modes.
24097 gl_cv_func_working_mktime=no
24099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24100 $as_echo_n "checking for working mktime... " >&6; }
24101 if test "${gl_cv_func_working_mktime+set}" = set; then :
24102 $as_echo_n "(cached) " >&6
24103 else
24104 if test "$cross_compiling" = yes; then :
24105 gl_cv_func_working_mktime=no
24106 else
24107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24108 /* end confdefs.h. */
24109 /* Test program from Paul Eggert and Tony Leneis. */
24110 #include <limits.h>
24111 #include <stdlib.h>
24112 #include <time.h>
24114 #ifdef HAVE_UNISTD_H
24115 # include <unistd.h>
24116 #endif
24118 #if HAVE_DECL_ALARM
24119 # include <signal.h>
24120 #endif
24122 /* Work around redefinition to rpl_putenv by other config tests. */
24123 #undef putenv
24125 static time_t time_t_max;
24126 static time_t time_t_min;
24128 /* Values we'll use to set the TZ environment variable. */
24129 static char *tz_strings[] = {
24130 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24131 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24133 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24135 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24136 Based on a problem report from Andreas Jaeger. */
24137 static int
24138 spring_forward_gap ()
24140 /* glibc (up to about 1998-10-07) failed this test. */
24141 struct tm tm;
24143 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24144 instead of "TZ=America/Vancouver" in order to detect the bug even
24145 on systems that don't support the Olson extension, or don't have the
24146 full zoneinfo tables installed. */
24147 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24149 tm.tm_year = 98;
24150 tm.tm_mon = 3;
24151 tm.tm_mday = 5;
24152 tm.tm_hour = 2;
24153 tm.tm_min = 0;
24154 tm.tm_sec = 0;
24155 tm.tm_isdst = -1;
24156 return mktime (&tm) != (time_t) -1;
24159 static int
24160 mktime_test1 (time_t now)
24162 struct tm *lt;
24163 return ! (lt = localtime (&now)) || mktime (lt) == now;
24166 static int
24167 mktime_test (time_t now)
24169 return (mktime_test1 (now)
24170 && mktime_test1 ((time_t) (time_t_max - now))
24171 && mktime_test1 ((time_t) (time_t_min + now)));
24174 static int
24175 irix_6_4_bug ()
24177 /* Based on code from Ariel Faigon. */
24178 struct tm tm;
24179 tm.tm_year = 96;
24180 tm.tm_mon = 3;
24181 tm.tm_mday = 0;
24182 tm.tm_hour = 0;
24183 tm.tm_min = 0;
24184 tm.tm_sec = 0;
24185 tm.tm_isdst = -1;
24186 mktime (&tm);
24187 return tm.tm_mon == 2 && tm.tm_mday == 31;
24190 static int
24191 bigtime_test (int j)
24193 struct tm tm;
24194 time_t now;
24195 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24196 now = mktime (&tm);
24197 if (now != (time_t) -1)
24199 struct tm *lt = localtime (&now);
24200 if (! (lt
24201 && lt->tm_year == tm.tm_year
24202 && lt->tm_mon == tm.tm_mon
24203 && lt->tm_mday == tm.tm_mday
24204 && lt->tm_hour == tm.tm_hour
24205 && lt->tm_min == tm.tm_min
24206 && lt->tm_sec == tm.tm_sec
24207 && lt->tm_yday == tm.tm_yday
24208 && lt->tm_wday == tm.tm_wday
24209 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24210 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24211 return 0;
24213 return 1;
24216 static int
24217 year_2050_test ()
24219 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24220 ignoring leap seconds. */
24221 unsigned long int answer = 2527315200UL;
24223 struct tm tm;
24224 time_t t;
24225 tm.tm_year = 2050 - 1900;
24226 tm.tm_mon = 2 - 1;
24227 tm.tm_mday = 1;
24228 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24229 tm.tm_isdst = -1;
24231 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24232 instead of "TZ=America/Vancouver" in order to detect the bug even
24233 on systems that don't support the Olson extension, or don't have the
24234 full zoneinfo tables installed. */
24235 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24237 t = mktime (&tm);
24239 /* Check that the result is either a failure, or close enough
24240 to the correct answer that we can assume the discrepancy is
24241 due to leap seconds. */
24242 return (t == (time_t) -1
24243 || (0 < t && answer - 120 <= t && t <= answer + 120));
24247 main ()
24249 int result = 0;
24250 time_t t, delta;
24251 int i, j;
24252 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24253 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24255 #if HAVE_DECL_ALARM
24256 /* This test makes some buggy mktime implementations loop.
24257 Give up after 60 seconds; a mktime slower than that
24258 isn't worth using anyway. */
24259 signal (SIGALRM, SIG_DFL);
24260 alarm (60);
24261 #endif
24263 time_t_max = (! time_t_signed
24264 ? (time_t) -1
24265 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24266 * 2 + 1));
24267 time_t_min = (! time_t_signed
24268 ? (time_t) 0
24269 : time_t_signed_magnitude
24270 ? ~ (time_t) 0
24271 : ~ time_t_max);
24273 delta = time_t_max / 997; /* a suitable prime number */
24274 for (i = 0; i < N_STRINGS; i++)
24276 if (tz_strings[i])
24277 putenv (tz_strings[i]);
24279 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24280 if (! mktime_test (t))
24281 result |= 1;
24282 if ((result & 2) == 0
24283 && ! (mktime_test ((time_t) 1)
24284 && mktime_test ((time_t) (60 * 60))
24285 && mktime_test ((time_t) (60 * 60 * 24))))
24286 result |= 2;
24288 for (j = 1; (result & 4) == 0; j <<= 1)
24290 if (! bigtime_test (j))
24291 result |= 4;
24292 if (INT_MAX / 2 < j)
24293 break;
24295 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24296 result |= 8;
24298 if (! irix_6_4_bug ())
24299 result |= 16;
24300 if (! spring_forward_gap ())
24301 result |= 32;
24302 if (! year_2050_test ())
24303 result |= 64;
24304 return result;
24306 _ACEOF
24307 if ac_fn_c_try_run "$LINENO"; then :
24308 gl_cv_func_working_mktime=yes
24309 else
24310 gl_cv_func_working_mktime=no
24312 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24313 conftest.$ac_objext conftest.beam conftest.$ac_ext
24318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24319 $as_echo "$gl_cv_func_working_mktime" >&6; }
24321 if test $gl_cv_func_working_mktime = no; then
24322 REPLACE_MKTIME=1
24323 else
24324 REPLACE_MKTIME=0
24327 if test $REPLACE_MKTIME = 1; then
24336 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24345 GNULIB_MKTIME=1
24358 if test $ac_cv_func_pipe2 != yes; then
24359 HAVE_PIPE2=0
24367 GNULIB_PIPE2=1
24378 if test $ac_cv_func_pselect = yes; then
24379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24380 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24381 if test "${gl_cv_sig_pselect+set}" = set; then :
24382 $as_echo_n "(cached) " >&6
24383 else
24384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24385 /* end confdefs.h. */
24386 #include <sys/select.h>
24389 main ()
24391 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24392 struct timespec const *restrict,
24393 sigset_t const *restrict) = pselect;
24394 return !p;
24396 return 0;
24398 _ACEOF
24399 if ac_fn_c_try_link "$LINENO"; then :
24400 gl_cv_sig_pselect=yes
24401 else
24402 gl_cv_sig_pselect=no
24404 rm -f core conftest.err conftest.$ac_objext \
24405 conftest$ac_exeext conftest.$ac_ext
24407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24408 $as_echo "$gl_cv_sig_pselect" >&6; }
24410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24411 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24412 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24413 $as_echo_n "(cached) " >&6
24414 else
24416 if test "$cross_compiling" = yes; then :
24418 case "$host_os" in
24419 # Guess yes on glibc systems.
24420 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24421 # If we don't know, assume the worst.
24422 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
24423 esac
24425 else
24426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24427 /* end confdefs.h. */
24429 #include <sys/types.h>
24430 #include <sys/time.h>
24431 #if HAVE_SYS_SELECT_H
24432 # include <sys/select.h>
24433 #endif
24434 #include <unistd.h>
24435 #include <errno.h>
24438 main ()
24441 fd_set set;
24442 dup2(0, 16);
24443 FD_ZERO(&set);
24444 FD_SET(16, &set);
24445 close(16);
24446 struct timespec timeout;
24447 timeout.tv_sec = 0;
24448 timeout.tv_nsec = 5000;
24449 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
24452 return 0;
24454 _ACEOF
24455 if ac_fn_c_try_run "$LINENO"; then :
24456 gl_cv_func_pselect_detects_ebadf=yes
24457 else
24458 gl_cv_func_pselect_detects_ebadf=no
24460 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24461 conftest.$ac_objext conftest.beam conftest.$ac_ext
24466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
24467 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
24468 case $gl_cv_func_pselect_detects_ebadf in
24469 *yes) ;;
24470 *) REPLACE_PSELECT=1 ;;
24471 esac
24474 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
24475 REPLACE_PSELECT=1
24478 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
24487 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
24495 GNULIB_PSELECT=1
24505 LIB_PTHREAD_SIGMASK=
24510 if test "$gl_threads_api" = posix; then
24511 if test $ac_cv_func_pthread_sigmask = yes; then
24513 else
24514 if test -n "$LIBMULTITHREAD"; then
24515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
24516 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
24517 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
24518 $as_echo_n "(cached) " >&6
24519 else
24520 gl_save_LIBS="$LIBS"
24521 LIBS="$LIBS $LIBMULTITHREAD"
24522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24523 /* end confdefs.h. */
24524 #include <pthread.h>
24525 #include <signal.h>
24528 main ()
24530 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
24532 return 0;
24535 _ACEOF
24536 if ac_fn_c_try_link "$LINENO"; then :
24537 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
24538 else
24539 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
24541 rm -f core conftest.err conftest.$ac_objext \
24542 conftest$ac_exeext conftest.$ac_ext
24543 LIBS="$gl_save_LIBS"
24546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
24547 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
24548 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
24549 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
24550 else
24551 HAVE_PTHREAD_SIGMASK=0
24553 else
24554 HAVE_PTHREAD_SIGMASK=0
24557 else
24558 if test $ac_cv_func_pthread_sigmask = yes; then
24559 REPLACE_PTHREAD_SIGMASK=1
24560 else
24561 HAVE_PTHREAD_SIGMASK=0
24568 if test $HAVE_PTHREAD_SIGMASK = 1; then
24571 if test -z "$LIB_PTHREAD_SIGMASK"; then
24572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
24573 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
24574 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
24575 $as_echo_n "(cached) " >&6
24576 else
24578 if test "$cross_compiling" = yes; then :
24580 case "$host_os" in
24581 freebsd* | hpux* | solaris | solaris2.[2-9]*)
24582 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
24584 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
24585 esac
24587 else
24588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24589 /* end confdefs.h. */
24591 #include <pthread.h>
24592 #include <signal.h>
24593 #include <stddef.h>
24594 int main ()
24596 sigset_t set;
24597 sigemptyset (&set);
24598 return pthread_sigmask (1729, &set, NULL) != 0;
24600 _ACEOF
24601 if ac_fn_c_try_run "$LINENO"; then :
24602 gl_cv_func_pthread_sigmask_in_libc_works=no
24603 else
24604 gl_cv_func_pthread_sigmask_in_libc_works=yes
24606 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24607 conftest.$ac_objext conftest.beam conftest.$ac_ext
24612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
24613 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
24614 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
24615 *no)
24616 REPLACE_PTHREAD_SIGMASK=1
24618 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
24621 esac
24624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
24625 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
24626 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
24627 $as_echo_n "(cached) " >&6
24628 else
24630 gl_save_LIBS="$LIBS"
24631 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
24632 if test "$cross_compiling" = yes; then :
24633 case "$host_os" in
24634 cygwin*)
24635 gl_cv_func_pthread_sigmask_return_works="guessing no";;
24637 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
24638 esac
24640 else
24641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24642 /* end confdefs.h. */
24644 #include <pthread.h>
24645 #include <signal.h>
24646 #include <stddef.h>
24647 int main ()
24649 sigset_t set;
24650 sigemptyset (&set);
24651 if (pthread_sigmask (1729, &set, NULL) == -1)
24652 return 1;
24653 return 0;
24655 _ACEOF
24656 if ac_fn_c_try_run "$LINENO"; then :
24657 gl_cv_func_pthread_sigmask_return_works=yes
24658 else
24659 gl_cv_func_pthread_sigmask_return_works=no
24661 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24662 conftest.$ac_objext conftest.beam conftest.$ac_ext
24665 LIBS="$gl_save_LIBS"
24668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
24669 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
24670 case "$gl_cv_func_pthread_sigmask_return_works" in
24671 *no)
24672 REPLACE_PTHREAD_SIGMASK=1
24674 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
24677 esac
24679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
24680 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
24681 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
24682 $as_echo_n "(cached) " >&6
24683 else
24685 case "$host_os" in
24686 irix*)
24687 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
24689 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
24690 esac
24691 gl_save_LIBS="$LIBS"
24692 LIBS="$LIBS $LIBMULTITHREAD"
24693 if test "$cross_compiling" = yes; then :
24695 else
24696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24697 /* end confdefs.h. */
24699 #include <pthread.h>
24700 #include <signal.h>
24701 #include <stdio.h>
24702 #include <stdlib.h>
24703 #include <unistd.h>
24704 static volatile int sigint_occurred;
24705 static void
24706 sigint_handler (int sig)
24708 sigint_occurred++;
24710 int main ()
24712 sigset_t set;
24713 int pid = getpid ();
24714 char command[80];
24715 signal (SIGINT, sigint_handler);
24716 sigemptyset (&set);
24717 sigaddset (&set, SIGINT);
24718 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
24719 return 1;
24720 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
24721 if (!(system (command) == 0))
24722 return 2;
24723 sleep (2);
24724 if (!(sigint_occurred == 0))
24725 return 3;
24726 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
24727 return 4;
24728 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
24729 return 5;
24730 return 0;
24732 _ACEOF
24733 if ac_fn_c_try_run "$LINENO"; then :
24735 else
24736 gl_cv_func_pthread_sigmask_unblock_works=no
24738 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24739 conftest.$ac_objext conftest.beam conftest.$ac_ext
24742 LIBS="$gl_save_LIBS"
24745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
24746 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
24747 case "$gl_cv_func_pthread_sigmask_unblock_works" in
24748 *no)
24749 REPLACE_PTHREAD_SIGMASK=1
24751 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
24754 esac
24757 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
24766 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
24769 if test $HAVE_PTHREAD_SIGMASK = 1; then
24771 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
24781 GNULIB_PTHREAD_SIGMASK=1
24789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
24790 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
24791 if test "${gl_cv_func_svid_putenv+set}" = set; then :
24792 $as_echo_n "(cached) " >&6
24793 else
24794 if test "$cross_compiling" = yes; then :
24795 case "$host_os" in
24796 # Guess yes on glibc systems.
24797 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
24798 # If we don't know, assume the worst.
24799 *) gl_cv_func_svid_putenv="guessing no" ;;
24800 esac
24802 else
24803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24804 /* end confdefs.h. */
24805 $ac_includes_default
24807 main ()
24810 /* Put it in env. */
24811 if (putenv ("CONFTEST_putenv=val"))
24812 return 1;
24814 /* Try to remove it. */
24815 if (putenv ("CONFTEST_putenv"))
24816 return 2;
24818 /* Make sure it was deleted. */
24819 if (getenv ("CONFTEST_putenv") != 0)
24820 return 3;
24822 return 0;
24825 return 0;
24827 _ACEOF
24828 if ac_fn_c_try_run "$LINENO"; then :
24829 gl_cv_func_svid_putenv=yes
24830 else
24831 gl_cv_func_svid_putenv=no
24833 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24834 conftest.$ac_objext conftest.beam conftest.$ac_ext
24839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
24840 $as_echo "$gl_cv_func_svid_putenv" >&6; }
24841 case "$gl_cv_func_svid_putenv" in
24842 *yes) ;;
24844 REPLACE_PUTENV=1
24846 esac
24848 if test $REPLACE_PUTENV = 1; then
24857 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
24860 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
24861 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
24862 ac_have_decl=1
24863 else
24864 ac_have_decl=0
24867 cat >>confdefs.h <<_ACEOF
24868 #define HAVE_DECL__PUTENV $ac_have_decl
24869 _ACEOF
24878 GNULIB_PUTENV=1
24885 # Check whether --enable-acl was given.
24886 if test "${enable_acl+set}" = set; then :
24887 enableval=$enable_acl;
24888 else
24889 enable_acl=auto
24893 LIB_ACL=
24894 use_acl=0
24895 if test "x$enable_acl" != "xno"; then
24896 for ac_header in sys/acl.h
24897 do :
24898 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
24899 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
24900 cat >>confdefs.h <<_ACEOF
24901 #define HAVE_SYS_ACL_H 1
24902 _ACEOF
24906 done
24908 if test $ac_cv_header_sys_acl_h = yes; then
24909 ac_save_LIBS=$LIBS
24911 if test $use_acl = 0; then
24912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
24913 $as_echo_n "checking for library containing acl_get_file... " >&6; }
24914 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24915 $as_echo_n "(cached) " >&6
24916 else
24917 ac_func_search_save_LIBS=$LIBS
24918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24919 /* end confdefs.h. */
24921 /* Override any GCC internal prototype to avoid an error.
24922 Use char because int might match the return type of a GCC
24923 builtin and then its argument prototype would still apply. */
24924 #ifdef __cplusplus
24925 extern "C"
24926 #endif
24927 char acl_get_file ();
24929 main ()
24931 return acl_get_file ();
24933 return 0;
24935 _ACEOF
24936 for ac_lib in '' acl pacl; do
24937 if test -z "$ac_lib"; then
24938 ac_res="none required"
24939 else
24940 ac_res=-l$ac_lib
24941 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
24943 if ac_fn_c_try_link "$LINENO"; then :
24944 ac_cv_search_acl_get_file=$ac_res
24946 rm -f core conftest.err conftest.$ac_objext \
24947 conftest$ac_exeext
24948 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24949 break
24951 done
24952 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24954 else
24955 ac_cv_search_acl_get_file=no
24957 rm conftest.$ac_ext
24958 LIBS=$ac_func_search_save_LIBS
24960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
24961 $as_echo "$ac_cv_search_acl_get_file" >&6; }
24962 ac_res=$ac_cv_search_acl_get_file
24963 if test "$ac_res" != no; then :
24964 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24965 if test "$ac_cv_search_acl_get_file" != "none required"; then
24966 LIB_ACL=$ac_cv_search_acl_get_file
24968 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
24969 acl_free acl_from_mode acl_from_text \
24970 acl_delete_def_file acl_extended_file \
24971 acl_delete_fd_np acl_delete_file_np \
24972 acl_copy_ext_native acl_create_entry_np \
24973 acl_to_short_text acl_free_text
24974 do :
24975 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24976 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24977 eval as_val=\$$as_ac_var
24978 if test "x$as_val" = x""yes; then :
24979 cat >>confdefs.h <<_ACEOF
24980 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24981 _ACEOF
24984 done
24986 # If the acl_get_file bug is detected, don't enable the ACL support.
24988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
24989 $as_echo_n "checking for working acl_get_file... " >&6; }
24990 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
24991 $as_echo_n "(cached) " >&6
24992 else
24993 if test "$cross_compiling" = yes; then :
24994 gl_cv_func_working_acl_get_file=cross-compiling
24995 else
24996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24997 /* end confdefs.h. */
24998 #include <sys/types.h>
24999 #include <sys/acl.h>
25000 #include <errno.h>
25003 main ()
25005 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25006 return 1;
25007 return 0;
25010 return 0;
25012 _ACEOF
25013 if ac_fn_c_try_run "$LINENO"; then :
25014 gl_cv_func_working_acl_get_file=yes
25015 else
25016 gl_cv_func_working_acl_get_file=no
25018 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25019 conftest.$ac_objext conftest.beam conftest.$ac_ext
25023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25024 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25026 if test $gl_cv_func_working_acl_get_file = yes; then :
25027 use_acl=1
25030 if test $use_acl = 1; then
25031 for ac_header in acl/libacl.h
25032 do :
25033 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25034 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
25035 cat >>confdefs.h <<_ACEOF
25036 #define HAVE_ACL_LIBACL_H 1
25037 _ACEOF
25041 done
25051 for ac_func in acl_entries
25052 do :
25053 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25054 if test "x$ac_cv_func_acl_entries" = x""yes; then :
25055 cat >>confdefs.h <<_ACEOF
25056 #define HAVE_ACL_ENTRIES 1
25057 _ACEOF
25059 else
25061 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25064 done
25067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25068 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25069 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
25070 $as_echo_n "(cached) " >&6
25071 else
25072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25073 /* end confdefs.h. */
25074 #include <sys/types.h>
25075 #include <sys/acl.h>
25076 int type = ACL_FIRST_ENTRY;
25078 main ()
25082 return 0;
25084 _ACEOF
25085 if ac_fn_c_try_compile "$LINENO"; then :
25086 gl_cv_acl_ACL_FIRST_ENTRY=yes
25087 else
25088 gl_cv_acl_ACL_FIRST_ENTRY=no
25090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25093 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25094 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25096 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25100 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25101 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
25102 $as_echo_n "(cached) " >&6
25103 else
25104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25105 /* end confdefs.h. */
25106 #include <sys/types.h>
25107 #include <sys/acl.h>
25108 int type = ACL_TYPE_EXTENDED;
25110 main ()
25114 return 0;
25116 _ACEOF
25117 if ac_fn_c_try_compile "$LINENO"; then :
25118 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25119 else
25120 gl_cv_acl_ACL_TYPE_EXTENDED=no
25122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25125 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25126 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25128 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25131 else
25132 LIB_ACL=
25139 if test $use_acl = 0; then
25140 for ac_func in facl
25141 do :
25142 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25143 if test "x$ac_cv_func_facl" = x""yes; then :
25144 cat >>confdefs.h <<_ACEOF
25145 #define HAVE_FACL 1
25146 _ACEOF
25149 done
25151 if test $ac_cv_func_facl = yes; then
25152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25153 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25154 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25155 $as_echo_n "(cached) " >&6
25156 else
25157 ac_func_search_save_LIBS=$LIBS
25158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25159 /* end confdefs.h. */
25161 /* Override any GCC internal prototype to avoid an error.
25162 Use char because int might match the return type of a GCC
25163 builtin and then its argument prototype would still apply. */
25164 #ifdef __cplusplus
25165 extern "C"
25166 #endif
25167 char acl_trivial ();
25169 main ()
25171 return acl_trivial ();
25173 return 0;
25175 _ACEOF
25176 for ac_lib in '' sec; do
25177 if test -z "$ac_lib"; then
25178 ac_res="none required"
25179 else
25180 ac_res=-l$ac_lib
25181 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25183 if ac_fn_c_try_link "$LINENO"; then :
25184 ac_cv_search_acl_trivial=$ac_res
25186 rm -f core conftest.err conftest.$ac_objext \
25187 conftest$ac_exeext
25188 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25189 break
25191 done
25192 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25194 else
25195 ac_cv_search_acl_trivial=no
25197 rm conftest.$ac_ext
25198 LIBS=$ac_func_search_save_LIBS
25200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25201 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25202 ac_res=$ac_cv_search_acl_trivial
25203 if test "$ac_res" != no; then :
25204 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25205 if test "$ac_cv_search_acl_trivial" != "none required"; then
25206 LIB_ACL=$ac_cv_search_acl_trivial
25211 for ac_func in acl_trivial
25212 do :
25213 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25214 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25215 cat >>confdefs.h <<_ACEOF
25216 #define HAVE_ACL_TRIVIAL 1
25217 _ACEOF
25220 done
25222 use_acl=1
25226 if test $use_acl = 0; then
25227 for ac_func in getacl
25228 do :
25229 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25230 if test "x$ac_cv_func_getacl" = x""yes; then :
25231 cat >>confdefs.h <<_ACEOF
25232 #define HAVE_GETACL 1
25233 _ACEOF
25236 done
25238 if test $ac_cv_func_getacl = yes; then
25239 use_acl=1
25241 for ac_header in aclv.h
25242 do :
25243 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25245 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25246 cat >>confdefs.h <<_ACEOF
25247 #define HAVE_ACLV_H 1
25248 _ACEOF
25252 done
25256 if test $use_acl = 0; then
25257 for ac_func in aclx_get
25258 do :
25259 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25260 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25261 cat >>confdefs.h <<_ACEOF
25262 #define HAVE_ACLX_GET 1
25263 _ACEOF
25266 done
25268 if test $ac_cv_func_aclx_get = yes; then
25269 use_acl=1
25273 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25274 for ac_func in statacl
25275 do :
25276 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25277 if test "x$ac_cv_func_statacl" = x""yes; then :
25278 cat >>confdefs.h <<_ACEOF
25279 #define HAVE_STATACL 1
25280 _ACEOF
25283 done
25285 if test $ac_cv_func_statacl = yes; then
25286 use_acl=1
25290 if test $use_acl = 0; then
25291 for ac_func in aclsort
25292 do :
25293 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25294 if test "x$ac_cv_func_aclsort" = x""yes; then :
25295 cat >>confdefs.h <<_ACEOF
25296 #define HAVE_ACLSORT 1
25297 _ACEOF
25300 done
25302 if test $ac_cv_func_aclsort = yes; then
25303 use_acl=1
25307 LIBS=$ac_save_LIBS
25309 if test "x$enable_acl$use_acl" = "xyes0"; then
25310 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25311 elif test "x$enable_acl$use_acl" = "xauto0"; then
25312 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25313 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25315 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25320 cat >>confdefs.h <<_ACEOF
25321 #define USE_ACL $use_acl
25322 _ACEOF
25324 USE_ACL=$use_acl
25330 if test $ac_cv_func_readlink = no; then
25331 HAVE_READLINK=0
25332 else
25333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25334 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25335 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25336 $as_echo_n "(cached) " >&6
25337 else
25338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25339 /* end confdefs.h. */
25340 #include <unistd.h>
25341 /* Cause compilation failure if original declaration has wrong type. */
25342 ssize_t readlink (const char *, char *, size_t);
25344 main ()
25348 return 0;
25350 _ACEOF
25351 if ac_fn_c_try_compile "$LINENO"; then :
25352 gl_cv_decl_readlink_works=yes
25353 else
25354 gl_cv_decl_readlink_works=no
25356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25359 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25361 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25362 if test "${gl_cv_func_readlink_works+set}" = set; then :
25363 $as_echo_n "(cached) " >&6
25364 else
25365 # We have readlink, so assume ln -s works.
25366 ln -s conftest.no-such conftest.link
25367 ln -s conftest.link conftest.lnk2
25368 if test "$cross_compiling" = yes; then :
25369 case "$host_os" in
25370 # Guess yes on glibc systems.
25371 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25372 # If we don't know, assume the worst.
25373 *) gl_cv_func_readlink_works="guessing no" ;;
25374 esac
25376 else
25377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25378 /* end confdefs.h. */
25379 #include <unistd.h>
25382 main ()
25384 char buf[20];
25385 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25387 return 0;
25389 _ACEOF
25390 if ac_fn_c_try_run "$LINENO"; then :
25391 gl_cv_func_readlink_works=yes
25392 else
25393 gl_cv_func_readlink_works=no
25395 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25396 conftest.$ac_objext conftest.beam conftest.$ac_ext
25399 rm -f conftest.link conftest.lnk2
25401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25402 $as_echo "$gl_cv_func_readlink_works" >&6; }
25403 case "$gl_cv_func_readlink_works" in
25404 *yes)
25405 if test "$gl_cv_decl_readlink_works" != yes; then
25406 REPLACE_READLINK=1
25411 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25413 REPLACE_READLINK=1
25415 esac
25418 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25427 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
25438 GNULIB_READLINK=1
25448 if test $ac_cv_func_readlinkat = no; then
25449 HAVE_READLINKAT=0
25452 if test $HAVE_READLINKAT = 0; then
25461 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
25469 GNULIB_READLINKAT=1
25476 for ac_func in sig2str
25477 do :
25478 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
25479 if test "x$ac_cv_func_sig2str" = x""yes; then :
25480 cat >>confdefs.h <<_ACEOF
25481 #define HAVE_SIG2STR 1
25482 _ACEOF
25485 done
25488 if test $ac_cv_func_sig2str = no; then
25497 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
25514 if test $gl_cv_have_include_next = yes; then
25515 gl_cv_next_signal_h='<'signal.h'>'
25516 else
25517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
25518 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
25519 if test "${gl_cv_next_signal_h+set}" = set; then :
25520 $as_echo_n "(cached) " >&6
25521 else
25523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25524 /* end confdefs.h. */
25525 #include <signal.h>
25527 _ACEOF
25528 case "$host_os" in
25529 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25530 *) gl_absname_cpp="$ac_cpp" ;;
25531 esac
25533 case "$host_os" in
25534 mingw*)
25535 gl_dirsep_regex='[/\\]'
25538 gl_dirsep_regex='\/'
25540 esac
25541 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25543 gl_header_literal_regex=`echo 'signal.h' \
25544 | sed -e "$gl_make_literal_regex_sed"`
25545 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25546 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25547 s|^/[^/]|//&|
25551 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25552 sed -n "$gl_absolute_header_sed"`'"'
25556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
25557 $as_echo "$gl_cv_next_signal_h" >&6; }
25559 NEXT_SIGNAL_H=$gl_cv_next_signal_h
25561 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25562 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25563 gl_next_as_first_directive='<'signal.h'>'
25564 else
25565 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25566 gl_next_as_first_directive=$gl_cv_next_signal_h
25568 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
25574 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
25575 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
25576 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
25577 #include <signal.h>
25580 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
25582 else
25583 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
25592 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
25593 #include <signal.h>
25596 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
25598 else
25599 HAVE_SIGHANDLER_T=0
25605 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
25606 /* <sys/types.h> is not needed according to POSIX, but the
25607 <sys/socket.h> in i386-unknown-freebsd4.10 and
25608 powerpc-apple-darwin5.5 required it. */
25609 #include <sys/types.h>
25610 #if HAVE_SYS_SOCKET_H
25611 # include <sys/socket.h>
25612 #elif HAVE_WS2TCPIP_H
25613 # include <ws2tcpip.h>
25614 #endif
25617 if test "x$ac_cv_type_socklen_t" = x""yes; then :
25619 else
25620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
25621 $as_echo_n "checking for socklen_t equivalent... " >&6; }
25622 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
25623 $as_echo_n "(cached) " >&6
25624 else
25625 # Systems have either "struct sockaddr *" or
25626 # "void *" as the second argument to getpeername
25627 gl_cv_socklen_t_equiv=
25628 for arg2 in "struct sockaddr" void; do
25629 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
25630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25631 /* end confdefs.h. */
25632 #include <sys/types.h>
25633 #include <sys/socket.h>
25635 int getpeername (int, $arg2 *, $t *);
25637 main ()
25639 $t len;
25640 getpeername (0, 0, &len);
25642 return 0;
25644 _ACEOF
25645 if ac_fn_c_try_compile "$LINENO"; then :
25646 gl_cv_socklen_t_equiv="$t"
25648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25649 test "$gl_cv_socklen_t_equiv" != "" && break
25650 done
25651 test "$gl_cv_socklen_t_equiv" != "" && break
25652 done
25656 if test "$gl_cv_socklen_t_equiv" = ""; then
25657 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
25659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
25660 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
25662 cat >>confdefs.h <<_ACEOF
25663 #define socklen_t $gl_cv_socklen_t_equiv
25664 _ACEOF
25669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
25670 $as_echo_n "checking for ssize_t... " >&6; }
25671 if test "${gt_cv_ssize_t+set}" = set; then :
25672 $as_echo_n "(cached) " >&6
25673 else
25674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25675 /* end confdefs.h. */
25676 #include <sys/types.h>
25678 main ()
25680 int x = sizeof (ssize_t *) + sizeof (ssize_t);
25681 return !x;
25683 return 0;
25685 _ACEOF
25686 if ac_fn_c_try_compile "$LINENO"; then :
25687 gt_cv_ssize_t=yes
25688 else
25689 gt_cv_ssize_t=no
25691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
25694 $as_echo "$gt_cv_ssize_t" >&6; }
25695 if test $gt_cv_ssize_t = no; then
25697 $as_echo "#define ssize_t int" >>confdefs.h
25705 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>
25706 #include <sys/stat.h>
25708 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
25710 cat >>confdefs.h <<_ACEOF
25711 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
25712 _ACEOF
25714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
25715 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
25716 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
25717 $as_echo_n "(cached) " >&6
25718 else
25719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25720 /* end confdefs.h. */
25722 #include <sys/types.h>
25723 #include <sys/stat.h>
25724 #if HAVE_SYS_TIME_H
25725 # include <sys/time.h>
25726 #endif
25727 #include <time.h>
25728 struct timespec ts;
25729 struct stat st;
25732 main ()
25735 st.st_atim = ts;
25738 return 0;
25740 _ACEOF
25741 if ac_fn_c_try_compile "$LINENO"; then :
25742 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
25743 else
25744 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
25746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
25749 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
25750 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
25752 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
25755 else
25756 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>
25757 #include <sys/stat.h>
25759 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
25761 cat >>confdefs.h <<_ACEOF
25762 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
25763 _ACEOF
25766 else
25767 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
25768 #include <sys/stat.h>
25770 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
25772 cat >>confdefs.h <<_ACEOF
25773 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
25774 _ACEOF
25777 else
25778 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>
25779 #include <sys/stat.h>
25781 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
25783 cat >>confdefs.h <<_ACEOF
25784 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
25785 _ACEOF
25800 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>
25801 #include <sys/stat.h>
25803 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
25805 cat >>confdefs.h <<_ACEOF
25806 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
25807 _ACEOF
25810 else
25811 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
25812 #include <sys/stat.h>
25814 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
25816 cat >>confdefs.h <<_ACEOF
25817 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
25818 _ACEOF
25821 else
25822 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>
25823 #include <sys/stat.h>
25825 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
25827 cat >>confdefs.h <<_ACEOF
25828 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
25829 _ACEOF
25840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
25841 $as_echo_n "checking for working stdalign.h... " >&6; }
25842 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
25843 $as_echo_n "(cached) " >&6
25844 else
25845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25846 /* end confdefs.h. */
25847 #include <stdalign.h>
25848 #include <stddef.h>
25850 /* Test that alignof yields a result consistent with offsetof.
25851 This catches GCC bug 52023
25852 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
25853 #ifdef __cplusplus
25854 template <class t> struct alignof_helper { char a; t b; };
25855 # define ao(type) offsetof (alignof_helper<type>, b)
25856 #else
25857 # define ao(type) offsetof (struct { char a; type b; }, b)
25858 #endif
25859 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
25860 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
25861 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
25863 /* Test _Alignas only on platforms where gnulib can help. */
25864 #if \
25865 ((defined __cplusplus && 201103 <= __cplusplus) \
25866 || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
25867 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
25868 struct alignas_test { char c; char alignas (8) alignas_8; };
25869 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
25870 ? 1 : -1];
25871 #endif
25874 main ()
25878 return 0;
25880 _ACEOF
25881 if ac_fn_c_try_compile "$LINENO"; then :
25882 gl_cv_header_working_stdalign_h=yes
25883 else
25884 gl_cv_header_working_stdalign_h=no
25886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
25889 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
25891 if test $gl_cv_header_working_stdalign_h = yes; then
25892 STDALIGN_H=''
25893 else
25894 STDALIGN_H='stdalign.h'
25898 if test -n "$STDALIGN_H"; then
25899 GL_GENERATE_STDALIGN_H_TRUE=
25900 GL_GENERATE_STDALIGN_H_FALSE='#'
25901 else
25902 GL_GENERATE_STDALIGN_H_TRUE='#'
25903 GL_GENERATE_STDALIGN_H_FALSE=
25908 STDARG_H=''
25909 NEXT_STDARG_H='<stdarg.h>'
25910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
25911 $as_echo_n "checking for va_copy... " >&6; }
25912 if test "${gl_cv_func_va_copy+set}" = set; then :
25913 $as_echo_n "(cached) " >&6
25914 else
25916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25917 /* end confdefs.h. */
25918 #include <stdarg.h>
25920 main ()
25923 #ifndef va_copy
25924 void (*func) (va_list, va_list) = va_copy;
25925 #endif
25928 return 0;
25930 _ACEOF
25931 if ac_fn_c_try_compile "$LINENO"; then :
25932 gl_cv_func_va_copy=yes
25933 else
25934 gl_cv_func_va_copy=no
25936 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
25940 $as_echo "$gl_cv_func_va_copy" >&6; }
25941 if test $gl_cv_func_va_copy = no; then
25942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25943 /* end confdefs.h. */
25944 #if defined _AIX && !defined __GNUC__
25945 AIX vaccine
25946 #endif
25948 _ACEOF
25949 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25950 $EGREP "vaccine" >/dev/null 2>&1; then :
25951 gl_aixcc=yes
25952 else
25953 gl_aixcc=no
25955 rm -f conftest*
25957 if test $gl_aixcc = yes; then
25958 STDARG_H=stdarg.h
25967 if test $gl_cv_have_include_next = yes; then
25968 gl_cv_next_stdarg_h='<'stdarg.h'>'
25969 else
25970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
25971 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
25972 if test "${gl_cv_next_stdarg_h+set}" = set; then :
25973 $as_echo_n "(cached) " >&6
25974 else
25976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25977 /* end confdefs.h. */
25978 #include <stdarg.h>
25980 _ACEOF
25981 case "$host_os" in
25982 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25983 *) gl_absname_cpp="$ac_cpp" ;;
25984 esac
25986 case "$host_os" in
25987 mingw*)
25988 gl_dirsep_regex='[/\\]'
25991 gl_dirsep_regex='\/'
25993 esac
25994 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25996 gl_header_literal_regex=`echo 'stdarg.h' \
25997 | sed -e "$gl_make_literal_regex_sed"`
25998 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25999 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26000 s|^/[^/]|//&|
26004 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26005 sed -n "$gl_absolute_header_sed"`'"'
26009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
26010 $as_echo "$gl_cv_next_stdarg_h" >&6; }
26012 NEXT_STDARG_H=$gl_cv_next_stdarg_h
26014 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26015 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26016 gl_next_as_first_directive='<'stdarg.h'>'
26017 else
26018 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26019 gl_next_as_first_directive=$gl_cv_next_stdarg_h
26021 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
26026 if test "$gl_cv_next_stdarg_h" = '""'; then
26027 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
26028 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
26030 else
26032 saved_as_echo_n="$as_echo_n"
26033 as_echo_n=':'
26034 if test "${gl_cv_func___va_copy+set}" = set; then :
26035 $as_echo_n "(cached) " >&6
26036 else
26038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26039 /* end confdefs.h. */
26040 #include <stdarg.h>
26042 main ()
26045 #ifndef __va_copy
26046 error, bail out
26047 #endif
26050 return 0;
26052 _ACEOF
26053 if ac_fn_c_try_compile "$LINENO"; then :
26054 gl_cv_func___va_copy=yes
26055 else
26056 gl_cv_func___va_copy=no
26058 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26061 as_echo_n="$saved_as_echo_n"
26063 if test $gl_cv_func___va_copy = yes; then
26065 $as_echo "#define va_copy __va_copy" >>confdefs.h
26067 else
26070 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
26076 if test -n "$STDARG_H"; then
26077 GL_GENERATE_STDARG_H_TRUE=
26078 GL_GENERATE_STDARG_H_FALSE='#'
26079 else
26080 GL_GENERATE_STDARG_H_TRUE='#'
26081 GL_GENERATE_STDARG_H_FALSE=
26089 # Define two additional variables used in the Makefile substitution.
26091 if test "$ac_cv_header_stdbool_h" = yes; then
26092 STDBOOL_H=''
26093 else
26094 STDBOOL_H='stdbool.h'
26097 if test -n "$STDBOOL_H"; then
26098 GL_GENERATE_STDBOOL_H_TRUE=
26099 GL_GENERATE_STDBOOL_H_FALSE='#'
26100 else
26101 GL_GENERATE_STDBOOL_H_TRUE='#'
26102 GL_GENERATE_STDBOOL_H_FALSE=
26106 if test "$ac_cv_type__Bool" = yes; then
26107 HAVE__BOOL=1
26108 else
26109 HAVE__BOOL=0
26116 STDDEF_H=
26117 if test $gt_cv_c_wchar_t = no; then
26118 HAVE_WCHAR_T=0
26119 STDDEF_H=stddef.h
26121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26122 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26123 if test "${gl_cv_decl_null_works+set}" = set; then :
26124 $as_echo_n "(cached) " >&6
26125 else
26126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26127 /* end confdefs.h. */
26128 #include <stddef.h>
26129 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26132 main ()
26136 return 0;
26138 _ACEOF
26139 if ac_fn_c_try_compile "$LINENO"; then :
26140 gl_cv_decl_null_works=yes
26141 else
26142 gl_cv_decl_null_works=no
26144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26147 $as_echo "$gl_cv_decl_null_works" >&6; }
26148 if test $gl_cv_decl_null_works = no; then
26149 REPLACE_NULL=1
26150 STDDEF_H=stddef.h
26153 if test -n "$STDDEF_H"; then
26154 GL_GENERATE_STDDEF_H_TRUE=
26155 GL_GENERATE_STDDEF_H_FALSE='#'
26156 else
26157 GL_GENERATE_STDDEF_H_TRUE='#'
26158 GL_GENERATE_STDDEF_H_FALSE=
26161 if test -n "$STDDEF_H"; then
26170 if test $gl_cv_have_include_next = yes; then
26171 gl_cv_next_stddef_h='<'stddef.h'>'
26172 else
26173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26174 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26175 if test "${gl_cv_next_stddef_h+set}" = set; then :
26176 $as_echo_n "(cached) " >&6
26177 else
26179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26180 /* end confdefs.h. */
26181 #include <stddef.h>
26183 _ACEOF
26184 case "$host_os" in
26185 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26186 *) gl_absname_cpp="$ac_cpp" ;;
26187 esac
26189 case "$host_os" in
26190 mingw*)
26191 gl_dirsep_regex='[/\\]'
26194 gl_dirsep_regex='\/'
26196 esac
26197 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26199 gl_header_literal_regex=`echo 'stddef.h' \
26200 | sed -e "$gl_make_literal_regex_sed"`
26201 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26202 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26203 s|^/[^/]|//&|
26207 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26208 sed -n "$gl_absolute_header_sed"`'"'
26212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26213 $as_echo "$gl_cv_next_stddef_h" >&6; }
26215 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26217 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26218 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26219 gl_next_as_first_directive='<'stddef.h'>'
26220 else
26221 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26222 gl_next_as_first_directive=$gl_cv_next_stddef_h
26224 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26242 if test $gl_cv_have_include_next = yes; then
26243 gl_cv_next_stdio_h='<'stdio.h'>'
26244 else
26245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26246 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26247 if test "${gl_cv_next_stdio_h+set}" = set; then :
26248 $as_echo_n "(cached) " >&6
26249 else
26251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26252 /* end confdefs.h. */
26253 #include <stdio.h>
26255 _ACEOF
26256 case "$host_os" in
26257 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26258 *) gl_absname_cpp="$ac_cpp" ;;
26259 esac
26261 case "$host_os" in
26262 mingw*)
26263 gl_dirsep_regex='[/\\]'
26266 gl_dirsep_regex='\/'
26268 esac
26269 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26271 gl_header_literal_regex=`echo 'stdio.h' \
26272 | sed -e "$gl_make_literal_regex_sed"`
26273 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26274 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26275 s|^/[^/]|//&|
26279 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26280 sed -n "$gl_absolute_header_sed"`'"'
26284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26285 $as_echo "$gl_cv_next_stdio_h" >&6; }
26287 NEXT_STDIO_H=$gl_cv_next_stdio_h
26289 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26290 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26291 gl_next_as_first_directive='<'stdio.h'>'
26292 else
26293 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26294 gl_next_as_first_directive=$gl_cv_next_stdio_h
26296 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26302 GNULIB_FSCANF=1
26305 cat >>confdefs.h <<_ACEOF
26306 #define GNULIB_FSCANF 1
26307 _ACEOF
26310 GNULIB_SCANF=1
26313 cat >>confdefs.h <<_ACEOF
26314 #define GNULIB_SCANF 1
26315 _ACEOF
26318 GNULIB_FGETC=1
26319 GNULIB_GETC=1
26320 GNULIB_GETCHAR=1
26321 GNULIB_FGETS=1
26322 GNULIB_FREAD=1
26325 GNULIB_FPRINTF=1
26326 GNULIB_PRINTF=1
26327 GNULIB_VFPRINTF=1
26328 GNULIB_VPRINTF=1
26329 GNULIB_FPUTC=1
26330 GNULIB_PUTC=1
26331 GNULIB_PUTCHAR=1
26332 GNULIB_FPUTS=1
26333 GNULIB_PUTS=1
26334 GNULIB_FWRITE=1
26350 if test $gl_cv_have_include_next = yes; then
26351 gl_cv_next_stdlib_h='<'stdlib.h'>'
26352 else
26353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26354 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26355 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26356 $as_echo_n "(cached) " >&6
26357 else
26359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26360 /* end confdefs.h. */
26361 #include <stdlib.h>
26363 _ACEOF
26364 case "$host_os" in
26365 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26366 *) gl_absname_cpp="$ac_cpp" ;;
26367 esac
26369 case "$host_os" in
26370 mingw*)
26371 gl_dirsep_regex='[/\\]'
26374 gl_dirsep_regex='\/'
26376 esac
26377 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26379 gl_header_literal_regex=`echo 'stdlib.h' \
26380 | sed -e "$gl_make_literal_regex_sed"`
26381 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26382 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26383 s|^/[^/]|//&|
26387 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26388 sed -n "$gl_absolute_header_sed"`'"'
26392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26393 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26395 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26397 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26398 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26399 gl_next_as_first_directive='<'stdlib.h'>'
26400 else
26401 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26402 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26404 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26414 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26422 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26434 if test "$ac_cv_have_decl_strtoimax" != yes; then
26435 HAVE_DECL_STRTOIMAX=0
26438 if test $ac_cv_func_strtoimax = yes; then
26439 HAVE_STRTOIMAX=1
26440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
26441 $as_echo_n "checking whether strtoimax works... " >&6; }
26442 if test "${gl_cv_func_strtoimax+set}" = set; then :
26443 $as_echo_n "(cached) " >&6
26444 else
26445 if test "$cross_compiling" = yes; then :
26446 case "$host_os" in
26447 # Guess no on AIX 5.
26448 aix5*) gl_cv_func_strtoimax="guessing no" ;;
26449 # Guess yes otherwise.
26450 *) gl_cv_func_strtoimax="guessing yes" ;;
26451 esac
26453 else
26454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26455 /* end confdefs.h. */
26457 #include <errno.h>
26458 #include <string.h>
26459 #include <inttypes.h>
26460 int main ()
26462 if (sizeof (intmax_t) > sizeof (int))
26464 const char *s = "4294967295";
26465 char *p;
26466 intmax_t res;
26467 errno = 0;
26468 res = strtoimax (s, &p, 10);
26469 if (p != s + strlen (s))
26470 return 1;
26471 if (errno != 0)
26472 return 2;
26473 if (res != (intmax_t) 65535 * (intmax_t) 65537)
26474 return 3;
26476 else
26478 const char *s = "2147483647";
26479 char *p;
26480 intmax_t res;
26481 errno = 0;
26482 res = strtoimax (s, &p, 10);
26483 if (p != s + strlen (s))
26484 return 1;
26485 if (errno != 0)
26486 return 2;
26487 if (res != 2147483647)
26488 return 3;
26490 return 0;
26493 _ACEOF
26494 if ac_fn_c_try_run "$LINENO"; then :
26495 gl_cv_func_strtoimax=yes
26496 else
26497 gl_cv_func_strtoimax=no
26499 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26500 conftest.$ac_objext conftest.beam conftest.$ac_ext
26505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
26506 $as_echo "$gl_cv_func_strtoimax" >&6; }
26507 case "$gl_cv_func_strtoimax" in
26508 *no) REPLACE_STRTOIMAX=1 ;;
26509 esac
26510 else
26511 HAVE_STRTOIMAX=0
26514 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
26523 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
26526 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
26527 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
26528 ac_have_decl=1
26529 else
26530 ac_have_decl=0
26533 cat >>confdefs.h <<_ACEOF
26534 #define HAVE_DECL_STRTOLL $ac_have_decl
26535 _ACEOF
26545 GNULIB_STRTOIMAX=1
26555 if test "$ac_cv_have_decl_strtoumax" != yes; then
26556 HAVE_DECL_STRTOUMAX=0
26559 if test $ac_cv_func_strtoumax = no; then
26568 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
26571 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
26572 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
26573 ac_have_decl=1
26574 else
26575 ac_have_decl=0
26578 cat >>confdefs.h <<_ACEOF
26579 #define HAVE_DECL_STRTOULL $ac_have_decl
26580 _ACEOF
26590 GNULIB_STRTOUMAX=1
26598 if test $ac_cv_func_symlink = no; then
26599 HAVE_SYMLINK=0
26600 else
26601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
26602 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
26603 if test "${gl_cv_func_symlink_works+set}" = set; then :
26604 $as_echo_n "(cached) " >&6
26605 else
26606 if test "$cross_compiling" = yes; then :
26607 case "$host_os" in
26608 # Guess yes on glibc systems.
26609 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
26610 # If we don't know, assume the worst.
26611 *) gl_cv_func_symlink_works="guessing no" ;;
26612 esac
26614 else
26615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26616 /* end confdefs.h. */
26617 #include <unistd.h>
26620 main ()
26622 int result = 0;
26623 if (!symlink ("a", "conftest.link/"))
26624 result |= 1;
26625 if (symlink ("conftest.f", "conftest.lnk2"))
26626 result |= 2;
26627 else if (!symlink ("a", "conftest.lnk2/"))
26628 result |= 4;
26629 return result;
26632 return 0;
26634 _ACEOF
26635 if ac_fn_c_try_run "$LINENO"; then :
26636 gl_cv_func_symlink_works=yes
26637 else
26638 gl_cv_func_symlink_works=no
26640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26641 conftest.$ac_objext conftest.beam conftest.$ac_ext
26644 rm -f conftest.f conftest.link conftest.lnk2
26646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
26647 $as_echo "$gl_cv_func_symlink_works" >&6; }
26648 case "$gl_cv_func_symlink_works" in
26649 *yes) ;;
26651 REPLACE_SYMLINK=1
26653 esac
26656 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
26665 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
26673 GNULIB_SYMLINK=1
26682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
26683 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
26684 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
26685 $as_echo_n "(cached) " >&6
26686 else
26688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26689 /* end confdefs.h. */
26690 #include <sys/select.h>
26692 main ()
26694 struct timeval b;
26696 return 0;
26698 _ACEOF
26699 if ac_fn_c_try_compile "$LINENO"; then :
26700 gl_cv_header_sys_select_h_selfcontained=yes
26701 else
26702 gl_cv_header_sys_select_h_selfcontained=no
26704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26705 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
26706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26707 /* end confdefs.h. */
26708 #include <sys/select.h>
26710 main ()
26712 int memset; int bzero;
26714 return 0;
26717 _ACEOF
26718 if ac_fn_c_try_compile "$LINENO"; then :
26719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26720 /* end confdefs.h. */
26721 #include <sys/select.h>
26723 main ()
26726 #undef memset
26727 #define memset nonexistent_memset
26728 extern
26729 #ifdef __cplusplus
26731 #endif
26732 void *memset (void *, int, unsigned long);
26733 #undef bzero
26734 #define bzero nonexistent_bzero
26735 extern
26736 #ifdef __cplusplus
26738 #endif
26739 void bzero (void *, unsigned long);
26740 fd_set fds;
26741 FD_ZERO (&fds);
26744 return 0;
26747 _ACEOF
26748 if ac_fn_c_try_link "$LINENO"; then :
26750 else
26751 gl_cv_header_sys_select_h_selfcontained=no
26753 rm -f core conftest.err conftest.$ac_objext \
26754 conftest$ac_exeext conftest.$ac_ext
26757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
26762 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
26772 if test $gl_cv_have_include_next = yes; then
26773 gl_cv_next_sys_select_h='<'sys/select.h'>'
26774 else
26775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
26776 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
26777 if test "${gl_cv_next_sys_select_h+set}" = set; then :
26778 $as_echo_n "(cached) " >&6
26779 else
26781 if test $ac_cv_header_sys_select_h = yes; then
26784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26785 /* end confdefs.h. */
26786 #include <sys/select.h>
26788 _ACEOF
26789 case "$host_os" in
26790 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26791 *) gl_absname_cpp="$ac_cpp" ;;
26792 esac
26794 case "$host_os" in
26795 mingw*)
26796 gl_dirsep_regex='[/\\]'
26799 gl_dirsep_regex='\/'
26801 esac
26802 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26804 gl_header_literal_regex=`echo 'sys/select.h' \
26805 | sed -e "$gl_make_literal_regex_sed"`
26806 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26807 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26808 s|^/[^/]|//&|
26812 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26813 sed -n "$gl_absolute_header_sed"`'"'
26814 else
26815 gl_cv_next_sys_select_h='<'sys/select.h'>'
26820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
26821 $as_echo "$gl_cv_next_sys_select_h" >&6; }
26823 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
26825 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26826 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26827 gl_next_as_first_directive='<'sys/select.h'>'
26828 else
26829 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26830 gl_next_as_first_directive=$gl_cv_next_sys_select_h
26832 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
26837 if test $ac_cv_header_sys_select_h = yes; then
26838 HAVE_SYS_SELECT_H=1
26839 else
26840 HAVE_SYS_SELECT_H=0
26847 if test $ac_cv_header_sys_socket_h != yes; then
26848 for ac_header in winsock2.h
26849 do :
26850 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
26851 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
26852 cat >>confdefs.h <<_ACEOF
26853 #define HAVE_WINSOCK2_H 1
26854 _ACEOF
26858 done
26861 if test "$ac_cv_header_winsock2_h" = yes; then
26862 HAVE_WINSOCK2_H=1
26863 UNISTD_H_HAVE_WINSOCK2_H=1
26864 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
26865 else
26866 HAVE_WINSOCK2_H=0
26888 if test $gl_cv_have_include_next = yes; then
26889 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
26890 else
26891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
26892 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
26893 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
26894 $as_echo_n "(cached) " >&6
26895 else
26897 if test $ac_cv_header_sys_stat_h = yes; then
26900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26901 /* end confdefs.h. */
26902 #include <sys/stat.h>
26904 _ACEOF
26905 case "$host_os" in
26906 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26907 *) gl_absname_cpp="$ac_cpp" ;;
26908 esac
26910 case "$host_os" in
26911 mingw*)
26912 gl_dirsep_regex='[/\\]'
26915 gl_dirsep_regex='\/'
26917 esac
26918 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26920 gl_header_literal_regex=`echo 'sys/stat.h' \
26921 | sed -e "$gl_make_literal_regex_sed"`
26922 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26923 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26924 s|^/[^/]|//&|
26928 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26929 sed -n "$gl_absolute_header_sed"`'"'
26930 else
26931 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
26936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
26937 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
26939 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
26941 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26942 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26943 gl_next_as_first_directive='<'sys/stat.h'>'
26944 else
26945 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26946 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
26948 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
26960 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
26962 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
26966 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
26967 #include <sys/stat.h>
26969 if test "x$ac_cv_type_nlink_t" = x""yes; then :
26971 else
26973 $as_echo "#define nlink_t int" >>confdefs.h
26994 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
26996 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
26997 ac_have_decl=1
26998 else
26999 ac_have_decl=0
27002 cat >>confdefs.h <<_ACEOF
27003 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
27004 _ACEOF
27006 if test $ac_cv_have_decl_localtime_r = no; then
27007 HAVE_DECL_LOCALTIME_R=0
27011 if test $ac_cv_func_localtime_r = yes; then
27012 HAVE_LOCALTIME_R=1
27013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
27014 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
27015 if test "${gl_cv_time_r_posix+set}" = set; then :
27016 $as_echo_n "(cached) " >&6
27017 else
27018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27019 /* end confdefs.h. */
27020 #include <time.h>
27022 main ()
27024 /* We don't need to append 'restrict's to the argument types,
27025 even though the POSIX signature has the 'restrict's,
27026 since C99 says they can't affect type compatibility. */
27027 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
27028 if (ptr) return 0;
27029 /* Check the return type is a pointer.
27030 On HP-UX 10 it is 'int'. */
27031 *localtime_r (0, 0);
27033 return 0;
27036 _ACEOF
27037 if ac_fn_c_try_compile "$LINENO"; then :
27038 gl_cv_time_r_posix=yes
27039 else
27040 gl_cv_time_r_posix=no
27042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
27046 $as_echo "$gl_cv_time_r_posix" >&6; }
27047 if test $gl_cv_time_r_posix = yes; then
27048 REPLACE_LOCALTIME_R=0
27049 else
27050 REPLACE_LOCALTIME_R=1
27052 else
27053 HAVE_LOCALTIME_R=0
27056 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
27065 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
27076 GNULIB_TIME_R=1
27087 LIB_TIMER_TIME=
27089 gl_saved_libs=$LIBS
27090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
27091 $as_echo_n "checking for library containing timer_settime... " >&6; }
27092 if test "${ac_cv_search_timer_settime+set}" = set; then :
27093 $as_echo_n "(cached) " >&6
27094 else
27095 ac_func_search_save_LIBS=$LIBS
27096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27097 /* end confdefs.h. */
27099 /* Override any GCC internal prototype to avoid an error.
27100 Use char because int might match the return type of a GCC
27101 builtin and then its argument prototype would still apply. */
27102 #ifdef __cplusplus
27103 extern "C"
27104 #endif
27105 char timer_settime ();
27107 main ()
27109 return timer_settime ();
27111 return 0;
27113 _ACEOF
27114 for ac_lib in '' rt posix4; do
27115 if test -z "$ac_lib"; then
27116 ac_res="none required"
27117 else
27118 ac_res=-l$ac_lib
27119 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27121 if ac_fn_c_try_link "$LINENO"; then :
27122 ac_cv_search_timer_settime=$ac_res
27124 rm -f core conftest.err conftest.$ac_objext \
27125 conftest$ac_exeext
27126 if test "${ac_cv_search_timer_settime+set}" = set; then :
27127 break
27129 done
27130 if test "${ac_cv_search_timer_settime+set}" = set; then :
27132 else
27133 ac_cv_search_timer_settime=no
27135 rm conftest.$ac_ext
27136 LIBS=$ac_func_search_save_LIBS
27138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27139 $as_echo "$ac_cv_search_timer_settime" >&6; }
27140 ac_res=$ac_cv_search_timer_settime
27141 if test "$ac_res" != no; then :
27142 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27143 test "$ac_cv_search_timer_settime" = "none required" ||
27144 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27148 /* end confdefs.h. */
27150 #include <features.h>
27151 #ifdef __GNU_LIBRARY__
27152 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27153 && !defined __UCLIBC__
27154 Thread emulation available
27155 #endif
27156 #endif
27158 _ACEOF
27159 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27160 $EGREP "Thread" >/dev/null 2>&1; then :
27161 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27163 rm -f conftest*
27165 for ac_func in timer_settime
27166 do :
27167 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27168 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27169 cat >>confdefs.h <<_ACEOF
27170 #define HAVE_TIMER_SETTIME 1
27171 _ACEOF
27174 done
27176 LIBS=$gl_saved_libs
27191 if test $gl_cv_have_include_next = yes; then
27192 gl_cv_next_unistd_h='<'unistd.h'>'
27193 else
27194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27195 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27196 if test "${gl_cv_next_unistd_h+set}" = set; then :
27197 $as_echo_n "(cached) " >&6
27198 else
27200 if test $ac_cv_header_unistd_h = yes; then
27203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27204 /* end confdefs.h. */
27205 #include <unistd.h>
27207 _ACEOF
27208 case "$host_os" in
27209 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27210 *) gl_absname_cpp="$ac_cpp" ;;
27211 esac
27213 case "$host_os" in
27214 mingw*)
27215 gl_dirsep_regex='[/\\]'
27218 gl_dirsep_regex='\/'
27220 esac
27221 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27223 gl_header_literal_regex=`echo 'unistd.h' \
27224 | sed -e "$gl_make_literal_regex_sed"`
27225 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27226 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27227 s|^/[^/]|//&|
27231 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27232 sed -n "$gl_absolute_header_sed"`'"'
27233 else
27234 gl_cv_next_unistd_h='<'unistd.h'>'
27239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27240 $as_echo "$gl_cv_next_unistd_h" >&6; }
27242 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27244 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27245 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27246 gl_next_as_first_directive='<'unistd.h'>'
27247 else
27248 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27249 gl_next_as_first_directive=$gl_cv_next_unistd_h
27251 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27256 if test $ac_cv_header_unistd_h = yes; then
27257 HAVE_UNISTD_H=1
27258 else
27259 HAVE_UNISTD_H=0
27272 if test $ac_cv_have_decl_unsetenv = no; then
27273 HAVE_DECL_UNSETENV=0
27275 for ac_func in unsetenv
27276 do :
27277 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27278 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27279 cat >>confdefs.h <<_ACEOF
27280 #define HAVE_UNSETENV 1
27281 _ACEOF
27284 done
27286 if test $ac_cv_func_unsetenv = no; then
27287 HAVE_UNSETENV=0
27288 else
27289 HAVE_UNSETENV=1
27290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27291 $as_echo_n "checking for unsetenv() return type... " >&6; }
27292 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27293 $as_echo_n "(cached) " >&6
27294 else
27295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27296 /* end confdefs.h. */
27298 #undef _BSD
27299 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27300 #include <stdlib.h>
27301 extern
27302 #ifdef __cplusplus
27304 #endif
27305 int unsetenv (const char *name);
27308 main ()
27312 return 0;
27314 _ACEOF
27315 if ac_fn_c_try_compile "$LINENO"; then :
27316 gt_cv_func_unsetenv_ret='int'
27317 else
27318 gt_cv_func_unsetenv_ret='void'
27320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27323 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27324 if test $gt_cv_func_unsetenv_ret = 'void'; then
27326 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27328 REPLACE_UNSETENV=1
27331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27332 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27333 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27334 $as_echo_n "(cached) " >&6
27335 else
27336 if test "$cross_compiling" = yes; then :
27337 case "$host_os" in
27338 # Guess yes on glibc systems.
27339 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27340 # If we don't know, assume the worst.
27341 *) gl_cv_func_unsetenv_works="guessing no" ;;
27342 esac
27344 else
27345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27346 /* end confdefs.h. */
27348 #include <stdlib.h>
27349 #include <errno.h>
27350 extern char **environ;
27353 main ()
27356 char entry1[] = "a=1";
27357 char entry2[] = "b=2";
27358 char *env[] = { entry1, entry2, NULL };
27359 if (putenv ((char *) "a=1")) return 1;
27360 if (putenv (entry2)) return 2;
27361 entry2[0] = 'a';
27362 unsetenv ("a");
27363 if (getenv ("a")) return 3;
27364 if (!unsetenv ("") || errno != EINVAL) return 4;
27365 entry2[0] = 'b';
27366 environ = env;
27367 if (!getenv ("a")) return 5;
27368 entry2[0] = 'a';
27369 unsetenv ("a");
27370 if (getenv ("a")) return 6;
27373 return 0;
27375 _ACEOF
27376 if ac_fn_c_try_run "$LINENO"; then :
27377 gl_cv_func_unsetenv_works=yes
27378 else
27379 gl_cv_func_unsetenv_works=no
27381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27382 conftest.$ac_objext conftest.beam conftest.$ac_ext
27386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27387 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27388 case "$gl_cv_func_unsetenv_works" in
27389 *yes) ;;
27391 REPLACE_UNSETENV=1
27393 esac
27396 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27405 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27417 GNULIB_UNSETENV=1
27429 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
27430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
27431 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
27432 if test "${gl_cv_func_futimesat_works+set}" = set; then :
27433 $as_echo_n "(cached) " >&6
27434 else
27435 touch conftest.file
27436 if test "$cross_compiling" = yes; then :
27437 case "$host_os" in
27438 # Guess yes on glibc systems.
27439 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
27440 # If we don't know, assume the worst.
27441 *) gl_cv_func_futimesat_works="guessing no" ;;
27442 esac
27444 else
27445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27446 /* end confdefs.h. */
27448 #include <stddef.h>
27449 #include <sys/times.h>
27450 #include <fcntl.h>
27453 main ()
27455 int fd = open ("conftest.file", O_RDWR);
27456 if (fd < 0) return 1;
27457 if (futimesat (fd, NULL, NULL)) return 2;
27460 return 0;
27462 _ACEOF
27463 if ac_fn_c_try_run "$LINENO"; then :
27464 gl_cv_func_futimesat_works=yes
27465 else
27466 gl_cv_func_futimesat_works=no
27468 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27469 conftest.$ac_objext conftest.beam conftest.$ac_ext
27472 rm -f conftest.file
27474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
27475 $as_echo "$gl_cv_func_futimesat_works" >&6; }
27476 case "$gl_cv_func_futimesat_works" in
27477 *yes) ;;
27480 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
27483 esac
27486 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
27487 gl_gnulib_enabled_dosname=false
27488 gl_gnulib_enabled_euidaccess=false
27489 gl_gnulib_enabled_getdtablesize=false
27490 gl_gnulib_enabled_getgroups=false
27491 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
27492 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
27493 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
27494 gl_gnulib_enabled_pathmax=false
27495 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
27496 gl_gnulib_enabled_stat=false
27497 gl_gnulib_enabled_strtoll=false
27498 gl_gnulib_enabled_strtoull=false
27499 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
27500 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
27502 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
27511 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
27513 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
27516 func_gl_gnulib_m4code_dosname ()
27518 if ! $gl_gnulib_enabled_dosname; then
27519 gl_gnulib_enabled_dosname=true
27522 func_gl_gnulib_m4code_euidaccess ()
27524 if ! $gl_gnulib_enabled_euidaccess; then
27530 for ac_func in euidaccess
27531 do :
27532 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
27533 if test "x$ac_cv_func_euidaccess" = x""yes; then :
27534 cat >>confdefs.h <<_ACEOF
27535 #define HAVE_EUIDACCESS 1
27536 _ACEOF
27539 done
27541 if test $ac_cv_func_euidaccess = no; then
27542 HAVE_EUIDACCESS=0
27545 if test $HAVE_EUIDACCESS = 0; then
27554 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
27558 for ac_header in libgen.h
27559 do :
27560 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
27561 if test "x$ac_cv_header_libgen_h" = x""yes; then :
27562 cat >>confdefs.h <<_ACEOF
27563 #define HAVE_LIBGEN_H 1
27564 _ACEOF
27568 done
27571 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27572 if test "x$ac_cv_func_getgroups" = x""yes; then :
27577 # If we don't yet have getgroups, see if it's in -lbsd.
27578 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27579 ac_save_LIBS=$LIBS
27580 if test $ac_cv_func_getgroups = no; then
27581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27582 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27583 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27584 $as_echo_n "(cached) " >&6
27585 else
27586 ac_check_lib_save_LIBS=$LIBS
27587 LIBS="-lbsd $LIBS"
27588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27589 /* end confdefs.h. */
27591 /* Override any GCC internal prototype to avoid an error.
27592 Use char because int might match the return type of a GCC
27593 builtin and then its argument prototype would still apply. */
27594 #ifdef __cplusplus
27595 extern "C"
27596 #endif
27597 char getgroups ();
27599 main ()
27601 return getgroups ();
27603 return 0;
27605 _ACEOF
27606 if ac_fn_c_try_link "$LINENO"; then :
27607 ac_cv_lib_bsd_getgroups=yes
27608 else
27609 ac_cv_lib_bsd_getgroups=no
27611 rm -f core conftest.err conftest.$ac_objext \
27612 conftest$ac_exeext conftest.$ac_ext
27613 LIBS=$ac_check_lib_save_LIBS
27615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27616 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27617 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27618 GETGROUPS_LIB=-lbsd
27623 # Run the program to test the functionality of the system-supplied
27624 # getgroups function only if there is such a function.
27625 if test $ac_cv_func_getgroups = yes; then
27626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
27627 $as_echo_n "checking for working getgroups... " >&6; }
27628 if test "${ac_cv_func_getgroups_works+set}" = set; then :
27629 $as_echo_n "(cached) " >&6
27630 else
27631 if test "$cross_compiling" = yes; then :
27632 case "$host_os" in # ((
27633 # Guess yes on glibc systems.
27634 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
27635 # If we don't know, assume the worst.
27636 *) ac_cv_func_getgroups_works="guessing no" ;;
27637 esac
27639 else
27640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27641 /* end confdefs.h. */
27642 $ac_includes_default
27644 main ()
27646 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
27647 return getgroups (0, 0) == -1;
27649 return 0;
27652 _ACEOF
27653 if ac_fn_c_try_run "$LINENO"; then :
27654 ac_cv_func_getgroups_works=yes
27655 else
27656 ac_cv_func_getgroups_works=no
27658 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27659 conftest.$ac_objext conftest.beam conftest.$ac_ext
27664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
27665 $as_echo "$ac_cv_func_getgroups_works" >&6; }
27666 else
27667 ac_cv_func_getgroups_works=no
27669 case "$ac_cv_func_getgroups_works" in
27670 *yes)
27672 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
27675 esac
27676 LIBS=$ac_save_LIBS
27679 # Solaris 9 and 10 need -lgen to get the eaccess function.
27680 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
27681 # programs in the package would end up linked with that potentially-shared
27682 # library, inducing unnecessary run-time overhead.
27683 LIB_EACCESS=
27685 gl_saved_libs=$LIBS
27686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
27687 $as_echo_n "checking for library containing eaccess... " >&6; }
27688 if test "${ac_cv_search_eaccess+set}" = set; then :
27689 $as_echo_n "(cached) " >&6
27690 else
27691 ac_func_search_save_LIBS=$LIBS
27692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27693 /* end confdefs.h. */
27695 /* Override any GCC internal prototype to avoid an error.
27696 Use char because int might match the return type of a GCC
27697 builtin and then its argument prototype would still apply. */
27698 #ifdef __cplusplus
27699 extern "C"
27700 #endif
27701 char eaccess ();
27703 main ()
27705 return eaccess ();
27707 return 0;
27709 _ACEOF
27710 for ac_lib in '' gen; do
27711 if test -z "$ac_lib"; then
27712 ac_res="none required"
27713 else
27714 ac_res=-l$ac_lib
27715 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27717 if ac_fn_c_try_link "$LINENO"; then :
27718 ac_cv_search_eaccess=$ac_res
27720 rm -f core conftest.err conftest.$ac_objext \
27721 conftest$ac_exeext
27722 if test "${ac_cv_search_eaccess+set}" = set; then :
27723 break
27725 done
27726 if test "${ac_cv_search_eaccess+set}" = set; then :
27728 else
27729 ac_cv_search_eaccess=no
27731 rm conftest.$ac_ext
27732 LIBS=$ac_func_search_save_LIBS
27734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
27735 $as_echo "$ac_cv_search_eaccess" >&6; }
27736 ac_res=$ac_cv_search_eaccess
27737 if test "$ac_res" != no; then :
27738 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27739 test "$ac_cv_search_eaccess" = "none required" ||
27740 LIB_EACCESS=$ac_cv_search_eaccess
27743 for ac_func in eaccess
27744 do :
27745 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
27746 if test "x$ac_cv_func_eaccess" = x""yes; then :
27747 cat >>confdefs.h <<_ACEOF
27748 #define HAVE_EACCESS 1
27749 _ACEOF
27752 done
27754 LIBS=$gl_saved_libs
27762 GNULIB_EUIDACCESS=1
27768 gl_gnulib_enabled_euidaccess=true
27769 if test $HAVE_EUIDACCESS = 0; then
27770 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
27772 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
27773 if test $HAVE_EUIDACCESS = 0; then
27774 func_gl_gnulib_m4code_stat
27778 func_gl_gnulib_m4code_getdtablesize ()
27780 if ! $gl_gnulib_enabled_getdtablesize; then
27784 if test $ac_cv_func_getdtablesize != yes; then
27785 HAVE_GETDTABLESIZE=0
27788 if test $HAVE_GETDTABLESIZE = 0; then
27797 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
27806 GNULIB_GETDTABLESIZE=1
27812 gl_gnulib_enabled_getdtablesize=true
27815 func_gl_gnulib_m4code_getgroups ()
27817 if ! $gl_gnulib_enabled_getgroups; then
27823 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27824 if test "x$ac_cv_func_getgroups" = x""yes; then :
27829 # If we don't yet have getgroups, see if it's in -lbsd.
27830 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27831 ac_save_LIBS=$LIBS
27832 if test $ac_cv_func_getgroups = no; then
27833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27834 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27835 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27836 $as_echo_n "(cached) " >&6
27837 else
27838 ac_check_lib_save_LIBS=$LIBS
27839 LIBS="-lbsd $LIBS"
27840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27841 /* end confdefs.h. */
27843 /* Override any GCC internal prototype to avoid an error.
27844 Use char because int might match the return type of a GCC
27845 builtin and then its argument prototype would still apply. */
27846 #ifdef __cplusplus
27847 extern "C"
27848 #endif
27849 char getgroups ();
27851 main ()
27853 return getgroups ();
27855 return 0;
27857 _ACEOF
27858 if ac_fn_c_try_link "$LINENO"; then :
27859 ac_cv_lib_bsd_getgroups=yes
27860 else
27861 ac_cv_lib_bsd_getgroups=no
27863 rm -f core conftest.err conftest.$ac_objext \
27864 conftest$ac_exeext conftest.$ac_ext
27865 LIBS=$ac_check_lib_save_LIBS
27867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27868 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27869 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27870 GETGROUPS_LIB=-lbsd
27875 # Run the program to test the functionality of the system-supplied
27876 # getgroups function only if there is such a function.
27877 if test $ac_cv_func_getgroups = yes; then
27878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
27879 $as_echo_n "checking for working getgroups... " >&6; }
27880 if test "${ac_cv_func_getgroups_works+set}" = set; then :
27881 $as_echo_n "(cached) " >&6
27882 else
27883 if test "$cross_compiling" = yes; then :
27884 case "$host_os" in # ((
27885 # Guess yes on glibc systems.
27886 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
27887 # If we don't know, assume the worst.
27888 *) ac_cv_func_getgroups_works="guessing no" ;;
27889 esac
27891 else
27892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27893 /* end confdefs.h. */
27894 $ac_includes_default
27896 main ()
27898 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
27899 return getgroups (0, 0) == -1;
27901 return 0;
27904 _ACEOF
27905 if ac_fn_c_try_run "$LINENO"; then :
27906 ac_cv_func_getgroups_works=yes
27907 else
27908 ac_cv_func_getgroups_works=no
27910 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27911 conftest.$ac_objext conftest.beam conftest.$ac_ext
27916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
27917 $as_echo "$ac_cv_func_getgroups_works" >&6; }
27918 else
27919 ac_cv_func_getgroups_works=no
27921 case "$ac_cv_func_getgroups_works" in
27922 *yes)
27924 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
27927 esac
27928 LIBS=$ac_save_LIBS
27930 if test $ac_cv_func_getgroups != yes; then
27931 HAVE_GETGROUPS=0
27932 else
27933 if test "$ac_cv_type_getgroups" != gid_t \
27934 || { case "$ac_cv_func_getgroups_works" in
27935 *yes) false;;
27936 *) true;;
27937 esac
27938 }; then
27939 REPLACE_GETGROUPS=1
27941 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
27943 else
27944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
27945 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
27946 if test "${gl_cv_func_getgroups_works+set}" = set; then :
27947 $as_echo_n "(cached) " >&6
27948 else
27949 if test "$cross_compiling" = yes; then :
27950 case "$host_os" in
27951 # Guess yes on glibc systems.
27952 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
27953 # If we don't know, assume the worst.
27954 *) gl_cv_func_getgroups_works="guessing no" ;;
27955 esac
27957 else
27958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27959 /* end confdefs.h. */
27960 $ac_includes_default
27962 main ()
27964 int size = getgroups (0, 0);
27965 gid_t *list = malloc (size * sizeof *list);
27966 return getgroups (-1, list) != -1;
27968 return 0;
27970 _ACEOF
27971 if ac_fn_c_try_run "$LINENO"; then :
27972 gl_cv_func_getgroups_works=yes
27973 else
27974 gl_cv_func_getgroups_works=no
27976 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27977 conftest.$ac_objext conftest.beam conftest.$ac_ext
27981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
27982 $as_echo "$gl_cv_func_getgroups_works" >&6; }
27983 case "$gl_cv_func_getgroups_works" in
27984 *yes) ;;
27985 *) REPLACE_GETGROUPS=1 ;;
27986 esac
27989 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
27991 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
28000 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
28008 GNULIB_GETGROUPS=1
28014 gl_gnulib_enabled_getgroups=true
28017 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
28019 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28022 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
28025 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
28027 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28033 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
28034 if test "x$ac_cv_func_group_member" = x""yes; then :
28036 else
28038 HAVE_GROUP_MEMBER=0
28043 if test $HAVE_GROUP_MEMBER = 0; then
28052 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
28063 GNULIB_GROUP_MEMBER=1
28069 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
28070 if test $HAVE_GROUP_MEMBER = 0; then
28071 func_gl_gnulib_m4code_getgroups
28073 if test $HAVE_GROUP_MEMBER = 0; then
28074 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
28078 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
28080 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28081 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
28084 func_gl_gnulib_m4code_pathmax ()
28086 if ! $gl_gnulib_enabled_pathmax; then
28090 gl_gnulib_enabled_pathmax=true
28093 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
28095 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28096 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
28099 func_gl_gnulib_m4code_stat ()
28101 if ! $gl_gnulib_enabled_stat; then
28105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
28106 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
28107 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
28108 $as_echo_n "(cached) " >&6
28109 else
28110 if test "$cross_compiling" = yes; then :
28111 case $host_os in
28112 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
28113 *) gl_cv_func_stat_dir_slash="guessing yes";;
28114 esac
28115 else
28116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28117 /* end confdefs.h. */
28118 #include <sys/stat.h>
28121 main ()
28123 struct stat st; return stat (".", &st) != stat ("./", &st);
28125 return 0;
28127 _ACEOF
28128 if ac_fn_c_try_run "$LINENO"; then :
28129 gl_cv_func_stat_dir_slash=yes
28130 else
28131 gl_cv_func_stat_dir_slash=no
28133 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28134 conftest.$ac_objext conftest.beam conftest.$ac_ext
28138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
28139 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
28140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28141 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28142 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
28143 $as_echo_n "(cached) " >&6
28144 else
28145 touch conftest.tmp
28146 # Assume that if we have lstat, we can also check symlinks.
28147 if test $ac_cv_func_lstat = yes; then
28148 ln -s conftest.tmp conftest.lnk
28150 if test "$cross_compiling" = yes; then :
28151 case "$host_os" in
28152 # Guess yes on glibc systems.
28153 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28154 # If we don't know, assume the worst.
28155 *) gl_cv_func_stat_file_slash="guessing no" ;;
28156 esac
28158 else
28159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28160 /* end confdefs.h. */
28161 #include <sys/stat.h>
28164 main ()
28166 int result = 0;
28167 struct stat st;
28168 if (!stat ("conftest.tmp/", &st))
28169 result |= 1;
28170 #if HAVE_LSTAT
28171 if (!stat ("conftest.lnk/", &st))
28172 result |= 2;
28173 #endif
28174 return result;
28177 return 0;
28179 _ACEOF
28180 if ac_fn_c_try_run "$LINENO"; then :
28181 gl_cv_func_stat_file_slash=yes
28182 else
28183 gl_cv_func_stat_file_slash=no
28185 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28186 conftest.$ac_objext conftest.beam conftest.$ac_ext
28189 rm -f conftest.tmp conftest.lnk
28191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28192 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28193 case $gl_cv_func_stat_dir_slash in
28194 *no) REPLACE_STAT=1
28196 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28198 esac
28199 case $gl_cv_func_stat_file_slash in
28200 *no) REPLACE_STAT=1
28202 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28204 esac
28206 if test $REPLACE_STAT = 1; then
28215 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28224 GNULIB_STAT=1
28230 gl_gnulib_enabled_stat=true
28231 if test $REPLACE_STAT = 1; then
28232 func_gl_gnulib_m4code_dosname
28234 if test $REPLACE_STAT = 1; then
28235 func_gl_gnulib_m4code_pathmax
28239 func_gl_gnulib_m4code_strtoll ()
28241 if ! $gl_gnulib_enabled_strtoll; then
28245 if test "$ac_cv_type_long_long_int" = yes; then
28246 for ac_func in strtoll
28247 do :
28248 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28249 if test "x$ac_cv_func_strtoll" = x""yes; then :
28250 cat >>confdefs.h <<_ACEOF
28251 #define HAVE_STRTOLL 1
28252 _ACEOF
28255 done
28257 if test $ac_cv_func_strtoll = no; then
28258 HAVE_STRTOLL=0
28262 if test $HAVE_STRTOLL = 0; then
28271 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28282 GNULIB_STRTOLL=1
28288 gl_gnulib_enabled_strtoll=true
28291 func_gl_gnulib_m4code_strtoull ()
28293 if ! $gl_gnulib_enabled_strtoull; then
28297 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28298 for ac_func in strtoull
28299 do :
28300 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
28301 if test "x$ac_cv_func_strtoull" = x""yes; then :
28302 cat >>confdefs.h <<_ACEOF
28303 #define HAVE_STRTOULL 1
28304 _ACEOF
28307 done
28309 if test $ac_cv_func_strtoull = no; then
28310 HAVE_STRTOULL=0
28314 if test $HAVE_STRTOULL = 0; then
28323 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
28334 GNULIB_STRTOULL=1
28340 gl_gnulib_enabled_strtoull=true
28343 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
28345 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28346 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
28349 if test $HAVE_FACCESSAT = 0; then
28350 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28352 if test $HAVE_FACCESSAT = 0; then
28353 func_gl_gnulib_m4code_dosname
28355 if test $HAVE_FACCESSAT = 0; then
28356 func_gl_gnulib_m4code_euidaccess
28358 if test $HAVE_FACCESSAT = 0; then
28359 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28361 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
28362 func_gl_gnulib_m4code_getdtablesize
28364 if test $HAVE_FDOPENDIR = 0; then
28365 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28367 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28368 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28370 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28371 func_gl_gnulib_m4code_dosname
28373 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28374 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28376 if test $REPLACE_GETOPT = 1; then
28377 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
28379 if test $REPLACE_LSTAT = 1; then
28380 func_gl_gnulib_m4code_dosname
28382 if test $REPLACE_LSTAT = 1; then
28383 func_gl_gnulib_m4code_stat
28385 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
28386 func_gl_gnulib_m4code_stat
28388 if test $HAVE_READLINKAT = 0; then
28389 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28391 if test $HAVE_READLINKAT = 0; then
28392 func_gl_gnulib_m4code_dosname
28394 if test $HAVE_READLINKAT = 0; then
28395 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28397 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
28398 func_gl_gnulib_m4code_strtoll
28400 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
28401 func_gl_gnulib_m4code_strtoull
28404 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28405 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
28406 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
28407 else
28408 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
28409 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
28412 if $gl_gnulib_enabled_dosname; then
28413 gl_GNULIB_ENABLED_dosname_TRUE=
28414 gl_GNULIB_ENABLED_dosname_FALSE='#'
28415 else
28416 gl_GNULIB_ENABLED_dosname_TRUE='#'
28417 gl_GNULIB_ENABLED_dosname_FALSE=
28420 if $gl_gnulib_enabled_euidaccess; then
28421 gl_GNULIB_ENABLED_euidaccess_TRUE=
28422 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
28423 else
28424 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
28425 gl_GNULIB_ENABLED_euidaccess_FALSE=
28428 if $gl_gnulib_enabled_getdtablesize; then
28429 gl_GNULIB_ENABLED_getdtablesize_TRUE=
28430 gl_GNULIB_ENABLED_getdtablesize_FALSE='#'
28431 else
28432 gl_GNULIB_ENABLED_getdtablesize_TRUE='#'
28433 gl_GNULIB_ENABLED_getdtablesize_FALSE=
28436 if $gl_gnulib_enabled_getgroups; then
28437 gl_GNULIB_ENABLED_getgroups_TRUE=
28438 gl_GNULIB_ENABLED_getgroups_FALSE='#'
28439 else
28440 gl_GNULIB_ENABLED_getgroups_TRUE='#'
28441 gl_GNULIB_ENABLED_getgroups_FALSE=
28444 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28445 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
28446 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
28447 else
28448 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
28449 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
28452 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28453 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
28454 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
28455 else
28456 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
28457 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
28460 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28461 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
28462 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
28463 else
28464 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
28465 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
28468 if $gl_gnulib_enabled_pathmax; then
28469 gl_GNULIB_ENABLED_pathmax_TRUE=
28470 gl_GNULIB_ENABLED_pathmax_FALSE='#'
28471 else
28472 gl_GNULIB_ENABLED_pathmax_TRUE='#'
28473 gl_GNULIB_ENABLED_pathmax_FALSE=
28476 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28477 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
28478 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
28479 else
28480 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
28481 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
28484 if $gl_gnulib_enabled_stat; then
28485 gl_GNULIB_ENABLED_stat_TRUE=
28486 gl_GNULIB_ENABLED_stat_FALSE='#'
28487 else
28488 gl_GNULIB_ENABLED_stat_TRUE='#'
28489 gl_GNULIB_ENABLED_stat_FALSE=
28492 if $gl_gnulib_enabled_strtoll; then
28493 gl_GNULIB_ENABLED_strtoll_TRUE=
28494 gl_GNULIB_ENABLED_strtoll_FALSE='#'
28495 else
28496 gl_GNULIB_ENABLED_strtoll_TRUE='#'
28497 gl_GNULIB_ENABLED_strtoll_FALSE=
28500 if $gl_gnulib_enabled_strtoull; then
28501 gl_GNULIB_ENABLED_strtoull_TRUE=
28502 gl_GNULIB_ENABLED_strtoull_FALSE='#'
28503 else
28504 gl_GNULIB_ENABLED_strtoull_TRUE='#'
28505 gl_GNULIB_ENABLED_strtoull_FALSE=
28508 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28509 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
28510 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
28511 else
28512 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
28513 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
28516 # End of code from modules
28526 gltests_libdeps=
28527 gltests_ltlibdeps=
28537 gl_source_base='tests'
28538 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
28540 gl_module_indicator_condition=$gltests_WITNESS
28551 LIBGNU_LIBDEPS="$gl_libdeps"
28553 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
28556 CFLAGS=$SAVE_CFLAGS
28557 LIBS=$SAVE_LIBS
28559 if test "${opsys}" = "mingw32"; then
28560 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
28561 # Remove unneeded switches from the value of CC that goes to Makefiles
28562 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
28565 case "$opsys" in
28566 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
28568 darwin)
28569 ## The -headerpad option tells ld (see man page) to leave room at the
28570 ## end of the header for adding load commands. Needed for dumping.
28571 ## 0x690 is the total size of 30 segment load commands (at 56
28572 ## each); under Cocoa 31 commands are required.
28573 if test "$HAVE_NS" = "yes"; then
28574 libs_nsgui="-framework AppKit"
28575 if test "$NS_IMPL_COCOA" = "yes"; then
28576 libs_nsgui="$libs_nsgui -framework IOKit"
28578 headerpad_extra=6C8
28579 else
28580 libs_nsgui=
28581 headerpad_extra=690
28583 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
28585 ## This is here because src/Makefile.in did some extra fiddling around
28586 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
28587 ## LD_SWITCH_SYSTEM_TEMACS instead,
28588 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
28589 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
28592 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
28593 ## find X at run-time.
28594 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
28595 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
28596 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
28597 ## had different values in configure (in ac_link) and src/Makefile.in.
28598 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
28599 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
28601 mingw32)
28602 ## MinGW64 does not prepend an underscore to symbols, so we must
28603 ## pass a different -entry switch to linker. FIXME: It is better
28604 ## to make the entry points the same by changing unexw32.c.
28605 case "$canonical" in
28606 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
28607 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
28608 esac
28611 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
28613 *) LD_SWITCH_SYSTEM_TEMACS= ;;
28614 esac
28616 if test x$ac_enable_profiling != x ; then
28617 case $opsys in
28618 *freebsd | gnu-linux) ;;
28619 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
28620 esac
28625 ## MinGW-specific post-link processing of temacs.
28626 TEMACS_POST_LINK=":"
28627 ADDSECTION=
28628 EMACS_HEAPSIZE=
28629 if test "${opsys}" = "mingw32"; then
28630 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
28631 ADDSECTION="../nt/addsection\$(EXEEXT)"
28632 ## Preload heap size of temacs.exe in MB.
28633 case "$canonical" in
28634 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
28635 *) EMACS_HEAPSIZE=27 ;;
28636 esac
28643 ## Common for all window systems
28644 if test "$window_system" != "none"; then
28646 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
28648 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
28655 #### Report on what we decided to do.
28656 #### Report GTK as a toolkit, even if it doesn't use Xt.
28657 #### It makes printing result more understandable as using GTK sets
28658 #### toolkit_scroll_bars to yes by default.
28659 if test "${HAVE_GTK}" = "yes"; then
28660 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
28663 if test $USE_ACL -ne 0; then
28664 acl_summary="yes $LIB_ACL"
28665 else
28666 acl_summary=no
28669 echo "
28670 Configured for \`${canonical}'.
28672 Where should the build process find the source code? ${srcdir}
28673 What compiler should emacs be built with? ${CC} ${CFLAGS}
28674 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
28675 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
28676 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
28677 What window system should Emacs use? ${window_system}
28678 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
28680 if test -n "${x_includes}"; then
28681 echo " Where do we find X Windows header files? ${x_includes}"
28682 else
28683 echo " Where do we find X Windows header files? Standard dirs"
28685 if test -n "${x_libraries}"; then
28686 echo " Where do we find X Windows libraries? ${x_libraries}"
28687 else
28688 echo " Where do we find X Windows libraries? Standard dirs"
28691 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
28692 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
28693 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
28694 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
28695 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
28696 echo " Does Emacs use -lpng? ${HAVE_PNG}"
28697 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
28698 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
28700 echo " Does Emacs support sound? ${HAVE_SOUND}"
28702 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
28703 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
28704 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
28705 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
28706 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
28707 echo " Does Emacs use access control lists? ${acl_summary}"
28708 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
28709 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
28710 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
28712 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
28713 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
28714 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
28715 echo " Does Emacs use -lxft? ${HAVE_XFT}"
28717 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
28718 echo
28720 if test -n "${EMACSDATA}"; then
28721 echo " Environment variable EMACSDATA set to: $EMACSDATA"
28723 if test -n "${EMACSDOC}"; then
28724 echo " Environment variable EMACSDOC set to: $EMACSDOC"
28727 echo
28729 if test "$HAVE_NS" = "yes"; then
28730 echo
28731 echo "You must run \"${MAKE-make} install\" in order to test the built application.
28732 The installed application will go to nextstep/Emacs.app and can be
28733 run or moved from there."
28734 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
28735 echo "The application will be fully self-contained."
28736 else
28737 echo "The lisp resources for the application will be installed under ${prefix}.
28738 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
28739 to run if these resources are not installed."
28741 echo
28744 if test "${opsys}" = "cygwin"; then
28745 case `uname -r` in
28746 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
28747 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
28748 echo
28750 esac
28753 # Remove any trailing slashes in these variables.
28754 test "${prefix}" != NONE &&
28755 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
28756 test "${exec_prefix}" != NONE &&
28757 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
28759 if test "$HAVE_NS" = "yes"; then
28760 if test "$NS_IMPL_GNUSTEP" = yes; then
28761 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"
28763 else
28764 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"
28769 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"
28771 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"
28774 opt_makefile=test/automated/Makefile
28776 if test -f "$srcdir/$opt_makefile.in"; then
28777 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
28778 ac_config_files="$ac_config_files test/automated/Makefile"
28783 opt_makefile=admin/unidata/Makefile
28785 if test -f "$srcdir/$opt_makefile.in"; then
28786 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
28787 ac_config_files="$ac_config_files admin/unidata/Makefile"
28792 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
28796 ac_config_commands="$ac_config_commands src/epaths.h"
28799 ac_config_commands="$ac_config_commands src/.gdbinit"
28802 cat >confcache <<\_ACEOF
28803 # This file is a shell script that caches the results of configure
28804 # tests run on this system so they can be shared between configure
28805 # scripts and configure runs, see configure's option --config-cache.
28806 # It is not useful on other systems. If it contains results you don't
28807 # want to keep, you may remove or edit it.
28809 # config.status only pays attention to the cache file if you give it
28810 # the --recheck option to rerun configure.
28812 # `ac_cv_env_foo' variables (set or unset) will be overridden when
28813 # loading this file, other *unset* `ac_cv_foo' will be assigned the
28814 # following values.
28816 _ACEOF
28818 # The following way of writing the cache mishandles newlines in values,
28819 # but we know of no workaround that is simple, portable, and efficient.
28820 # So, we kill variables containing newlines.
28821 # Ultrix sh set writes to stderr and can't be redirected directly,
28822 # and sets the high bit in the cache file unless we assign to the vars.
28824 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
28825 eval ac_val=\$$ac_var
28826 case $ac_val in #(
28827 *${as_nl}*)
28828 case $ac_var in #(
28829 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
28830 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
28831 esac
28832 case $ac_var in #(
28833 _ | IFS | as_nl) ;; #(
28834 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
28835 *) { eval $ac_var=; unset $ac_var;} ;;
28836 esac ;;
28837 esac
28838 done
28840 (set) 2>&1 |
28841 case $as_nl`(ac_space=' '; set) 2>&1` in #(
28842 *${as_nl}ac_space=\ *)
28843 # `set' does not quote correctly, so add quotes: double-quote
28844 # substitution turns \\\\ into \\, and sed turns \\ into \.
28845 sed -n \
28846 "s/'/'\\\\''/g;
28847 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
28848 ;; #(
28850 # `set' quotes correctly as required by POSIX, so do not add quotes.
28851 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
28853 esac |
28854 sort
28856 sed '
28857 /^ac_cv_env_/b end
28858 t clear
28859 :clear
28860 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
28861 t end
28862 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
28863 :end' >>confcache
28864 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
28865 if test -w "$cache_file"; then
28866 test "x$cache_file" != "x/dev/null" &&
28867 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
28868 $as_echo "$as_me: updating cache $cache_file" >&6;}
28869 cat confcache >$cache_file
28870 else
28871 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
28872 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
28875 rm -f confcache
28877 test "x$prefix" = xNONE && prefix=$ac_default_prefix
28878 # Let make expand exec_prefix.
28879 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
28881 DEFS=-DHAVE_CONFIG_H
28883 ac_libobjs=
28884 ac_ltlibobjs=
28885 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
28886 # 1. Remove the extension, and $U if already installed.
28887 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
28888 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
28889 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
28890 # will be set to the directory where LIBOBJS objects are built.
28891 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
28892 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
28893 done
28894 LIBOBJS=$ac_libobjs
28896 LTLIBOBJS=$ac_ltlibobjs
28899 if test -n "$EXEEXT"; then
28900 am__EXEEXT_TRUE=
28901 am__EXEEXT_FALSE='#'
28902 else
28903 am__EXEEXT_TRUE='#'
28904 am__EXEEXT_FALSE=
28907 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
28908 as_fn_error "conditional \"AMDEP\" was never defined.
28909 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28911 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
28912 as_fn_error "conditional \"am__fastdepCC\" was never defined.
28913 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28915 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
28916 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
28917 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28919 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
28920 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
28921 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28923 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
28924 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
28925 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28928 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
28929 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
28930 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28932 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
28933 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
28934 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28936 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
28937 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
28938 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28940 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
28941 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
28942 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28944 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
28945 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
28946 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28948 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
28949 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
28950 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28952 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
28953 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
28954 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28956 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
28957 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
28958 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28960 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
28961 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
28962 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28964 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
28965 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
28966 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28968 if test -z "${gl_GNULIB_ENABLED_getdtablesize_TRUE}" && test -z "${gl_GNULIB_ENABLED_getdtablesize_FALSE}"; then
28969 as_fn_error "conditional \"gl_GNULIB_ENABLED_getdtablesize\" was never defined.
28970 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28972 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
28973 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
28974 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28976 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
28977 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
28978 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28980 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
28981 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
28982 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28984 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
28985 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
28986 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28988 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
28989 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
28990 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28992 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
28993 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
28994 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28996 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
28997 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
28998 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29000 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
29001 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
29002 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29004 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
29005 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
29006 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29008 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
29009 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
29010 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29013 gl_libobjs=
29014 gl_ltlibobjs=
29015 if test -n "$gl_LIBOBJS"; then
29016 # Remove the extension.
29017 sed_drop_objext='s/\.o$//;s/\.obj$//'
29018 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29019 gl_libobjs="$gl_libobjs $i.$ac_objext"
29020 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
29021 done
29023 gl_LIBOBJS=$gl_libobjs
29025 gl_LTLIBOBJS=$gl_ltlibobjs
29029 gltests_libobjs=
29030 gltests_ltlibobjs=
29031 if test -n "$gltests_LIBOBJS"; then
29032 # Remove the extension.
29033 sed_drop_objext='s/\.o$//;s/\.obj$//'
29034 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29035 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
29036 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
29037 done
29039 gltests_LIBOBJS=$gltests_libobjs
29041 gltests_LTLIBOBJS=$gltests_ltlibobjs
29045 : ${CONFIG_STATUS=./config.status}
29046 ac_write_fail=0
29047 ac_clean_files_save=$ac_clean_files
29048 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29049 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29050 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29051 as_write_fail=0
29052 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29053 #! $SHELL
29054 # Generated by $as_me.
29055 # Run this file to recreate the current configuration.
29056 # Compiler output produced by configure, useful for debugging
29057 # configure, is in config.log if it exists.
29059 debug=false
29060 ac_cs_recheck=false
29061 ac_cs_silent=false
29063 SHELL=\${CONFIG_SHELL-$SHELL}
29064 export SHELL
29065 _ASEOF
29066 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29067 ## -------------------- ##
29068 ## M4sh Initialization. ##
29069 ## -------------------- ##
29071 # Be more Bourne compatible
29072 DUALCASE=1; export DUALCASE # for MKS sh
29073 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29074 emulate sh
29075 NULLCMD=:
29076 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29077 # is contrary to our usage. Disable this feature.
29078 alias -g '${1+"$@"}'='"$@"'
29079 setopt NO_GLOB_SUBST
29080 else
29081 case `(set -o) 2>/dev/null` in #(
29082 *posix*) :
29083 set -o posix ;; #(
29084 *) :
29086 esac
29090 as_nl='
29092 export as_nl
29093 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29094 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29095 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29096 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29097 # Prefer a ksh shell builtin over an external printf program on Solaris,
29098 # but without wasting forks for bash or zsh.
29099 if test -z "$BASH_VERSION$ZSH_VERSION" \
29100 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29101 as_echo='print -r --'
29102 as_echo_n='print -rn --'
29103 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29104 as_echo='printf %s\n'
29105 as_echo_n='printf %s'
29106 else
29107 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29108 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29109 as_echo_n='/usr/ucb/echo -n'
29110 else
29111 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29112 as_echo_n_body='eval
29113 arg=$1;
29114 case $arg in #(
29115 *"$as_nl"*)
29116 expr "X$arg" : "X\\(.*\\)$as_nl";
29117 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29118 esac;
29119 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29121 export as_echo_n_body
29122 as_echo_n='sh -c $as_echo_n_body as_echo'
29124 export as_echo_body
29125 as_echo='sh -c $as_echo_body as_echo'
29128 # The user is always right.
29129 if test "${PATH_SEPARATOR+set}" != set; then
29130 PATH_SEPARATOR=:
29131 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29132 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29133 PATH_SEPARATOR=';'
29138 # IFS
29139 # We need space, tab and new line, in precisely that order. Quoting is
29140 # there to prevent editors from complaining about space-tab.
29141 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29142 # splitting by setting IFS to empty value.)
29143 IFS=" "" $as_nl"
29145 # Find who we are. Look in the path if we contain no directory separator.
29146 case $0 in #((
29147 *[\\/]* ) as_myself=$0 ;;
29148 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29149 for as_dir in $PATH
29151 IFS=$as_save_IFS
29152 test -z "$as_dir" && as_dir=.
29153 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29154 done
29155 IFS=$as_save_IFS
29158 esac
29159 # We did not find ourselves, most probably we were run as `sh COMMAND'
29160 # in which case we are not to be found in the path.
29161 if test "x$as_myself" = x; then
29162 as_myself=$0
29164 if test ! -f "$as_myself"; then
29165 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29166 exit 1
29169 # Unset variables that we do not need and which cause bugs (e.g. in
29170 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29171 # suppresses any "Segmentation fault" message there. '((' could
29172 # trigger a bug in pdksh 5.2.14.
29173 for as_var in BASH_ENV ENV MAIL MAILPATH
29174 do eval test x\${$as_var+set} = xset \
29175 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29176 done
29177 PS1='$ '
29178 PS2='> '
29179 PS4='+ '
29181 # NLS nuisances.
29182 LC_ALL=C
29183 export LC_ALL
29184 LANGUAGE=C
29185 export LANGUAGE
29187 # CDPATH.
29188 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29191 # as_fn_error ERROR [LINENO LOG_FD]
29192 # ---------------------------------
29193 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29194 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29195 # script with status $?, using 1 if that was 0.
29196 as_fn_error ()
29198 as_status=$?; test $as_status -eq 0 && as_status=1
29199 if test "$3"; then
29200 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29201 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29203 $as_echo "$as_me: error: $1" >&2
29204 as_fn_exit $as_status
29205 } # as_fn_error
29208 # as_fn_set_status STATUS
29209 # -----------------------
29210 # Set $? to STATUS, without forking.
29211 as_fn_set_status ()
29213 return $1
29214 } # as_fn_set_status
29216 # as_fn_exit STATUS
29217 # -----------------
29218 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29219 as_fn_exit ()
29221 set +e
29222 as_fn_set_status $1
29223 exit $1
29224 } # as_fn_exit
29226 # as_fn_unset VAR
29227 # ---------------
29228 # Portably unset VAR.
29229 as_fn_unset ()
29231 { eval $1=; unset $1;}
29233 as_unset=as_fn_unset
29234 # as_fn_append VAR VALUE
29235 # ----------------------
29236 # Append the text in VALUE to the end of the definition contained in VAR. Take
29237 # advantage of any shell optimizations that allow amortized linear growth over
29238 # repeated appends, instead of the typical quadratic growth present in naive
29239 # implementations.
29240 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29241 eval 'as_fn_append ()
29243 eval $1+=\$2
29245 else
29246 as_fn_append ()
29248 eval $1=\$$1\$2
29250 fi # as_fn_append
29252 # as_fn_arith ARG...
29253 # ------------------
29254 # Perform arithmetic evaluation on the ARGs, and store the result in the
29255 # global $as_val. Take advantage of shells that can avoid forks. The arguments
29256 # must be portable across $(()) and expr.
29257 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29258 eval 'as_fn_arith ()
29260 as_val=$(( $* ))
29262 else
29263 as_fn_arith ()
29265 as_val=`expr "$@" || test $? -eq 1`
29267 fi # as_fn_arith
29270 if expr a : '\(a\)' >/dev/null 2>&1 &&
29271 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29272 as_expr=expr
29273 else
29274 as_expr=false
29277 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29278 as_basename=basename
29279 else
29280 as_basename=false
29283 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29284 as_dirname=dirname
29285 else
29286 as_dirname=false
29289 as_me=`$as_basename -- "$0" ||
29290 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29291 X"$0" : 'X\(//\)$' \| \
29292 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29293 $as_echo X/"$0" |
29294 sed '/^.*\/\([^/][^/]*\)\/*$/{
29295 s//\1/
29298 /^X\/\(\/\/\)$/{
29299 s//\1/
29302 /^X\/\(\/\).*/{
29303 s//\1/
29306 s/.*/./; q'`
29308 # Avoid depending upon Character Ranges.
29309 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29310 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29311 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29312 as_cr_digits='0123456789'
29313 as_cr_alnum=$as_cr_Letters$as_cr_digits
29315 ECHO_C= ECHO_N= ECHO_T=
29316 case `echo -n x` in #(((((
29317 -n*)
29318 case `echo 'xy\c'` in
29319 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29320 xy) ECHO_C='\c';;
29321 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29322 ECHO_T=' ';;
29323 esac;;
29325 ECHO_N='-n';;
29326 esac
29328 rm -f conf$$ conf$$.exe conf$$.file
29329 if test -d conf$$.dir; then
29330 rm -f conf$$.dir/conf$$.file
29331 else
29332 rm -f conf$$.dir
29333 mkdir conf$$.dir 2>/dev/null
29335 if (echo >conf$$.file) 2>/dev/null; then
29336 if ln -s conf$$.file conf$$ 2>/dev/null; then
29337 as_ln_s='ln -s'
29338 # ... but there are two gotchas:
29339 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29340 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29341 # In both cases, we have to default to `cp -p'.
29342 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29343 as_ln_s='cp -p'
29344 elif ln conf$$.file conf$$ 2>/dev/null; then
29345 as_ln_s=ln
29346 else
29347 as_ln_s='cp -p'
29349 else
29350 as_ln_s='cp -p'
29352 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29353 rmdir conf$$.dir 2>/dev/null
29356 # as_fn_mkdir_p
29357 # -------------
29358 # Create "$as_dir" as a directory, including parents if necessary.
29359 as_fn_mkdir_p ()
29362 case $as_dir in #(
29363 -*) as_dir=./$as_dir;;
29364 esac
29365 test -d "$as_dir" || eval $as_mkdir_p || {
29366 as_dirs=
29367 while :; do
29368 case $as_dir in #(
29369 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29370 *) as_qdir=$as_dir;;
29371 esac
29372 as_dirs="'$as_qdir' $as_dirs"
29373 as_dir=`$as_dirname -- "$as_dir" ||
29374 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29375 X"$as_dir" : 'X\(//\)[^/]' \| \
29376 X"$as_dir" : 'X\(//\)$' \| \
29377 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29378 $as_echo X"$as_dir" |
29379 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29380 s//\1/
29383 /^X\(\/\/\)[^/].*/{
29384 s//\1/
29387 /^X\(\/\/\)$/{
29388 s//\1/
29391 /^X\(\/\).*/{
29392 s//\1/
29395 s/.*/./; q'`
29396 test -d "$as_dir" && break
29397 done
29398 test -z "$as_dirs" || eval "mkdir $as_dirs"
29399 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
29402 } # as_fn_mkdir_p
29403 if mkdir -p . 2>/dev/null; then
29404 as_mkdir_p='mkdir -p "$as_dir"'
29405 else
29406 test -d ./-p && rmdir ./-p
29407 as_mkdir_p=false
29410 if test -x / >/dev/null 2>&1; then
29411 as_test_x='test -x'
29412 else
29413 if ls -dL / >/dev/null 2>&1; then
29414 as_ls_L_option=L
29415 else
29416 as_ls_L_option=
29418 as_test_x='
29419 eval sh -c '\''
29420 if test -d "$1"; then
29421 test -d "$1/.";
29422 else
29423 case $1 in #(
29424 -*)set "./$1";;
29425 esac;
29426 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
29427 ???[sx]*):;;*)false;;esac;fi
29428 '\'' sh
29431 as_executable_p=$as_test_x
29433 # Sed expression to map a string onto a valid CPP name.
29434 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29436 # Sed expression to map a string onto a valid variable name.
29437 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29440 exec 6>&1
29441 ## ----------------------------------- ##
29442 ## Main body of $CONFIG_STATUS script. ##
29443 ## ----------------------------------- ##
29444 _ASEOF
29445 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
29447 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29448 # Save the log message, to keep $0 and so on meaningful, and to
29449 # report actual input values of CONFIG_FILES etc. instead of their
29450 # values after options handling.
29451 ac_log="
29452 This file was extended by emacs $as_me 24.3.50, which was
29453 generated by GNU Autoconf 2.65. Invocation command line was
29455 CONFIG_FILES = $CONFIG_FILES
29456 CONFIG_HEADERS = $CONFIG_HEADERS
29457 CONFIG_LINKS = $CONFIG_LINKS
29458 CONFIG_COMMANDS = $CONFIG_COMMANDS
29459 $ $0 $@
29461 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29464 _ACEOF
29466 case $ac_config_files in *"
29467 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29468 esac
29470 case $ac_config_headers in *"
29471 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29472 esac
29475 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29476 # Files that config.status was made for.
29477 config_files="$ac_config_files"
29478 config_headers="$ac_config_headers"
29479 config_commands="$ac_config_commands"
29481 _ACEOF
29483 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29484 ac_cs_usage="\
29485 \`$as_me' instantiates files and other configuration actions
29486 from templates according to the current configuration. Unless the files
29487 and actions are specified as TAGs, all are instantiated by default.
29489 Usage: $0 [OPTION]... [TAG]...
29491 -h, --help print this help, then exit
29492 -V, --version print version number and configuration settings, then exit
29493 --config print configuration, then exit
29494 -q, --quiet, --silent
29495 do not print progress messages
29496 -d, --debug don't remove temporary files
29497 --recheck update $as_me by reconfiguring in the same conditions
29498 --file=FILE[:TEMPLATE]
29499 instantiate the configuration file FILE
29500 --header=FILE[:TEMPLATE]
29501 instantiate the configuration header FILE
29503 Configuration files:
29504 $config_files
29506 Configuration headers:
29507 $config_headers
29509 Configuration commands:
29510 $config_commands
29512 Report bugs to the package provider."
29514 _ACEOF
29515 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29516 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
29517 ac_cs_version="\\
29518 emacs config.status 24.3.50
29519 configured by $0, generated by GNU Autoconf 2.65,
29520 with options \\"\$ac_cs_config\\"
29522 Copyright (C) 2009 Free Software Foundation, Inc.
29523 This config.status script is free software; the Free Software Foundation
29524 gives unlimited permission to copy, distribute and modify it."
29526 ac_pwd='$ac_pwd'
29527 srcdir='$srcdir'
29528 INSTALL='$INSTALL'
29529 MKDIR_P='$MKDIR_P'
29530 AWK='$AWK'
29531 test -n "\$AWK" || AWK=awk
29532 _ACEOF
29534 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29535 # The default lists apply if the user does not specify any file.
29536 ac_need_defaults=:
29537 while test $# != 0
29539 case $1 in
29540 --*=*)
29541 ac_option=`expr "X$1" : 'X\([^=]*\)='`
29542 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29543 ac_shift=:
29546 ac_option=$1
29547 ac_optarg=$2
29548 ac_shift=shift
29550 esac
29552 case $ac_option in
29553 # Handling of the options.
29554 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29555 ac_cs_recheck=: ;;
29556 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29557 $as_echo "$ac_cs_version"; exit ;;
29558 --config | --confi | --conf | --con | --co | --c )
29559 $as_echo "$ac_cs_config"; exit ;;
29560 --debug | --debu | --deb | --de | --d | -d )
29561 debug=: ;;
29562 --file | --fil | --fi | --f )
29563 $ac_shift
29564 case $ac_optarg in
29565 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29566 esac
29567 as_fn_append CONFIG_FILES " '$ac_optarg'"
29568 ac_need_defaults=false;;
29569 --header | --heade | --head | --hea )
29570 $ac_shift
29571 case $ac_optarg in
29572 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29573 esac
29574 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
29575 ac_need_defaults=false;;
29576 --he | --h)
29577 # Conflict between --help and --header
29578 as_fn_error "ambiguous option: \`$1'
29579 Try \`$0 --help' for more information.";;
29580 --help | --hel | -h )
29581 $as_echo "$ac_cs_usage"; exit ;;
29582 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29583 | -silent | --silent | --silen | --sile | --sil | --si | --s)
29584 ac_cs_silent=: ;;
29586 # This is an error.
29587 -*) as_fn_error "unrecognized option: \`$1'
29588 Try \`$0 --help' for more information." ;;
29590 *) as_fn_append ac_config_targets " $1"
29591 ac_need_defaults=false ;;
29593 esac
29594 shift
29595 done
29597 ac_configure_extra_args=
29599 if $ac_cs_silent; then
29600 exec 6>/dev/null
29601 ac_configure_extra_args="$ac_configure_extra_args --silent"
29604 _ACEOF
29605 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29606 if \$ac_cs_recheck; then
29607 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29608 shift
29609 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29610 CONFIG_SHELL='$SHELL'
29611 export CONFIG_SHELL
29612 exec "\$@"
29615 _ACEOF
29616 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29617 exec 5>>config.log
29619 echo
29620 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29621 ## Running $as_me. ##
29622 _ASBOX
29623 $as_echo "$ac_log"
29624 } >&5
29626 _ACEOF
29627 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29629 # INIT-COMMANDS
29631 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
29632 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
29634 _ACEOF
29636 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29638 # Handling of arguments.
29639 for ac_config_target in $ac_config_targets
29641 case $ac_config_target in
29642 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
29643 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
29644 "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" ;;
29645 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
29646 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
29647 "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" ;;
29648 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
29649 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
29650 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
29651 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
29652 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
29653 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
29654 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
29655 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
29656 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
29657 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
29658 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
29659 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
29660 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
29661 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
29662 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
29663 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
29664 "src/epaths.h") CONFIG_COMMANDS="$CONFIG_COMMANDS src/epaths.h" ;;
29665 "src/.gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS src/.gdbinit" ;;
29667 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
29668 esac
29669 done
29672 # If the user did not use the arguments to specify the items to instantiate,
29673 # then the envvar interface is used. Set only those that are not.
29674 # We use the long form for the default assignment because of an extremely
29675 # bizarre bug on SunOS 4.1.3.
29676 if $ac_need_defaults; then
29677 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29678 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29679 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29682 # Have a temporary directory for convenience. Make it in the build tree
29683 # simply because there is no reason against having it here, and in addition,
29684 # creating and moving files from /tmp can sometimes cause problems.
29685 # Hook for its removal unless debugging.
29686 # Note that there is a small window in which the directory will not be cleaned:
29687 # after its creation but before its name has been assigned to `$tmp'.
29688 $debug ||
29690 tmp=
29691 trap 'exit_status=$?
29692 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29694 trap 'as_fn_exit 1' 1 2 13 15
29696 # Create a (secure) tmp directory for tmp files.
29699 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29700 test -n "$tmp" && test -d "$tmp"
29701 } ||
29703 tmp=./conf$$-$RANDOM
29704 (umask 077 && mkdir "$tmp")
29705 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
29707 # Set up the scripts for CONFIG_FILES section.
29708 # No need to generate them if there are no CONFIG_FILES.
29709 # This happens for instance with `./config.status config.h'.
29710 if test -n "$CONFIG_FILES"; then
29712 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
29713 ac_cs_awk_getline=:
29714 ac_cs_awk_pipe_init=
29715 ac_cs_awk_read_file='
29716 while ((getline aline < (F[key])) > 0)
29717 print(aline)
29718 close(F[key])'
29719 ac_cs_awk_pipe_fini=
29720 else
29721 ac_cs_awk_getline=false
29722 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
29723 ac_cs_awk_read_file='
29724 print "|#_!!_#|"
29725 print "cat " F[key] " &&"
29726 '$ac_cs_awk_pipe_init
29727 # The final `:' finishes the AND list.
29728 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
29730 ac_cr=`echo X | tr X '\015'`
29731 # On cygwin, bash can eat \r inside `` if the user requested igncr.
29732 # But we know of no other shell where ac_cr would be empty at this
29733 # point, so we can use a bashism as a fallback.
29734 if test "x$ac_cr" = x; then
29735 eval ac_cr=\$\'\\r\'
29737 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
29738 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
29739 ac_cs_awk_cr='\r'
29740 else
29741 ac_cs_awk_cr=$ac_cr
29744 echo 'BEGIN {' >"$tmp/subs1.awk" &&
29745 _ACEOF
29747 # Create commands to substitute file output variables.
29749 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
29750 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
29751 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
29752 echo "_ACAWK" &&
29753 echo "_ACEOF"
29754 } >conf$$files.sh &&
29755 . ./conf$$files.sh ||
29756 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29757 rm -f conf$$files.sh
29760 echo "cat >conf$$subs.awk <<_ACEOF" &&
29761 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
29762 echo "_ACEOF"
29763 } >conf$$subs.sh ||
29764 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29765 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
29766 ac_delim='%!_!# '
29767 for ac_last_try in false false false false false :; do
29768 . ./conf$$subs.sh ||
29769 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29771 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
29772 if test $ac_delim_n = $ac_delim_num; then
29773 break
29774 elif $ac_last_try; then
29775 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29776 else
29777 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29779 done
29780 rm -f conf$$subs.sh
29782 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29783 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
29784 _ACEOF
29785 sed -n '
29787 s/^/S["/; s/!.*/"]=/
29790 s/^[^!]*!//
29791 :repl
29792 t repl
29793 s/'"$ac_delim"'$//
29794 t delim
29797 s/\(.\{148\}\)..*/\1/
29798 t more1
29799 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
29802 b repl
29803 :more1
29804 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29807 s/.\{148\}//
29808 t nl
29809 :delim
29811 s/\(.\{148\}\)..*/\1/
29812 t more2
29813 s/["\\]/\\&/g; s/^/"/; s/$/"/
29816 :more2
29817 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29820 s/.\{148\}//
29821 t delim
29822 ' <conf$$subs.awk | sed '
29823 /^[^""]/{
29825 s/\n//
29827 ' >>$CONFIG_STATUS || ac_write_fail=1
29828 rm -f conf$$subs.awk
29829 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29830 _ACAWK
29831 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
29832 for (key in S) S_is_set[key] = 1
29833 FS = "\a"
29834 \$ac_cs_awk_pipe_init
29837 line = $ 0
29838 nfields = split(line, field, "@")
29839 substed = 0
29840 len = length(field[1])
29841 for (i = 2; i < nfields; i++) {
29842 key = field[i]
29843 keylen = length(key)
29844 if (S_is_set[key]) {
29845 value = S[key]
29846 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
29847 len += length(value) + length(field[++i])
29848 substed = 1
29849 } else
29850 len += 1 + keylen
29852 if (nfields == 3 && !substed) {
29853 key = field[2]
29854 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
29855 \$ac_cs_awk_read_file
29856 next
29859 print line
29861 \$ac_cs_awk_pipe_fini
29862 _ACAWK
29863 _ACEOF
29864 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29865 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
29866 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
29867 else
29869 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
29870 || as_fn_error "could not setup config files machinery" "$LINENO" 5
29871 _ACEOF
29873 # VPATH may cause trouble with some makes, so we remove $(srcdir),
29874 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
29875 # trailing colons and then remove the whole line if VPATH becomes empty
29876 # (actually we leave an empty line to preserve line numbers).
29877 if test "x$srcdir" = x.; then
29878 ac_vpsub='/^[ ]*VPATH[ ]*=/{
29879 s/:*\$(srcdir):*/:/
29880 s/:*\${srcdir}:*/:/
29881 s/:*@srcdir@:*/:/
29882 s/^\([^=]*=[ ]*\):*/\1/
29883 s/:*$//
29884 s/^[^=]*=[ ]*$//
29888 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29889 fi # test -n "$CONFIG_FILES"
29891 # Set up the scripts for CONFIG_HEADERS section.
29892 # No need to generate them if there are no CONFIG_HEADERS.
29893 # This happens for instance with `./config.status Makefile'.
29894 if test -n "$CONFIG_HEADERS"; then
29895 cat >"$tmp/defines.awk" <<\_ACAWK ||
29896 BEGIN {
29897 _ACEOF
29899 # Transform confdefs.h into an awk script `defines.awk', embedded as
29900 # here-document in config.status, that substitutes the proper values into
29901 # config.h.in to produce config.h.
29903 # Create a delimiter string that does not exist in confdefs.h, to ease
29904 # handling of long lines.
29905 ac_delim='%!_!# '
29906 for ac_last_try in false false :; do
29907 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
29908 if test -z "$ac_t"; then
29909 break
29910 elif $ac_last_try; then
29911 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
29912 else
29913 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29915 done
29917 # For the awk script, D is an array of macro values keyed by name,
29918 # likewise P contains macro parameters if any. Preserve backslash
29919 # newline sequences.
29921 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
29922 sed -n '
29923 s/.\{148\}/&'"$ac_delim"'/g
29924 t rset
29925 :rset
29926 s/^[ ]*#[ ]*define[ ][ ]*/ /
29927 t def
29929 :def
29930 s/\\$//
29931 t bsnl
29932 s/["\\]/\\&/g
29933 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
29934 D["\1"]=" \3"/p
29935 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
29937 :bsnl
29938 s/["\\]/\\&/g
29939 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
29940 D["\1"]=" \3\\\\\\n"\\/p
29941 t cont
29942 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
29943 t cont
29945 :cont
29947 s/.\{148\}/&'"$ac_delim"'/g
29948 t clear
29949 :clear
29950 s/\\$//
29951 t bsnlc
29952 s/["\\]/\\&/g; s/^/"/; s/$/"/p
29954 :bsnlc
29955 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
29956 b cont
29957 ' <confdefs.h | sed '
29958 s/'"$ac_delim"'/"\\\
29959 "/g' >>$CONFIG_STATUS || ac_write_fail=1
29961 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29962 for (key in D) D_is_set[key] = 1
29963 FS = "\a"
29965 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
29966 line = \$ 0
29967 split(line, arg, " ")
29968 if (arg[1] == "#") {
29969 defundef = arg[2]
29970 mac1 = arg[3]
29971 } else {
29972 defundef = substr(arg[1], 2)
29973 mac1 = arg[2]
29975 split(mac1, mac2, "(") #)
29976 macro = mac2[1]
29977 prefix = substr(line, 1, index(line, defundef) - 1)
29978 if (D_is_set[macro]) {
29979 # Preserve the white space surrounding the "#".
29980 print prefix "define", macro P[macro] D[macro]
29981 next
29982 } else {
29983 # Replace #undef with comments. This is necessary, for example,
29984 # in the case of _POSIX_SOURCE, which is predefined and required
29985 # on some systems where configure will not decide to define it.
29986 if (defundef == "undef") {
29987 print "/*", prefix defundef, macro, "*/"
29988 next
29992 { print }
29993 _ACAWK
29994 _ACEOF
29995 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29996 as_fn_error "could not setup config headers machinery" "$LINENO" 5
29997 fi # test -n "$CONFIG_HEADERS"
30000 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
30001 shift
30002 for ac_tag
30004 case $ac_tag in
30005 :[FHLC]) ac_mode=$ac_tag; continue;;
30006 esac
30007 case $ac_mode$ac_tag in
30008 :[FHL]*:*);;
30009 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
30010 :[FH]-) ac_tag=-:-;;
30011 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30012 esac
30013 ac_save_IFS=$IFS
30014 IFS=:
30015 set x $ac_tag
30016 IFS=$ac_save_IFS
30017 shift
30018 ac_file=$1
30019 shift
30021 case $ac_mode in
30022 :L) ac_source=$1;;
30023 :[FH])
30024 ac_file_inputs=
30025 for ac_f
30027 case $ac_f in
30028 -) ac_f="$tmp/stdin";;
30029 *) # Look for the file first in the build tree, then in the source tree
30030 # (if the path is not absolute). The absolute path cannot be DOS-style,
30031 # because $ac_f cannot contain `:'.
30032 test -f "$ac_f" ||
30033 case $ac_f in
30034 [\\/$]*) false;;
30035 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30036 esac ||
30037 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30038 esac
30039 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30040 as_fn_append ac_file_inputs " '$ac_f'"
30041 done
30043 # Let's still pretend it is `configure' which instantiates (i.e., don't
30044 # use $as_me), people would be surprised to read:
30045 # /* config.h. Generated by config.status. */
30046 configure_input='Generated from '`
30047 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30048 `' by configure.'
30049 if test x"$ac_file" != x-; then
30050 configure_input="$ac_file. $configure_input"
30051 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30052 $as_echo "$as_me: creating $ac_file" >&6;}
30054 # Neutralize special characters interpreted by sed in replacement strings.
30055 case $configure_input in #(
30056 *\&* | *\|* | *\\* )
30057 ac_sed_conf_input=`$as_echo "$configure_input" |
30058 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30059 *) ac_sed_conf_input=$configure_input;;
30060 esac
30062 case $ac_tag in
30063 *:-:* | *:-) cat >"$tmp/stdin" \
30064 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
30065 esac
30067 esac
30069 ac_dir=`$as_dirname -- "$ac_file" ||
30070 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30071 X"$ac_file" : 'X\(//\)[^/]' \| \
30072 X"$ac_file" : 'X\(//\)$' \| \
30073 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30074 $as_echo X"$ac_file" |
30075 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30076 s//\1/
30079 /^X\(\/\/\)[^/].*/{
30080 s//\1/
30083 /^X\(\/\/\)$/{
30084 s//\1/
30087 /^X\(\/\).*/{
30088 s//\1/
30091 s/.*/./; q'`
30092 as_dir="$ac_dir"; as_fn_mkdir_p
30093 ac_builddir=.
30095 case "$ac_dir" in
30096 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30098 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30099 # A ".." for each directory in $ac_dir_suffix.
30100 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30101 case $ac_top_builddir_sub in
30102 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30103 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30104 esac ;;
30105 esac
30106 ac_abs_top_builddir=$ac_pwd
30107 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30108 # for backward compatibility:
30109 ac_top_builddir=$ac_top_build_prefix
30111 case $srcdir in
30112 .) # We are building in place.
30113 ac_srcdir=.
30114 ac_top_srcdir=$ac_top_builddir_sub
30115 ac_abs_top_srcdir=$ac_pwd ;;
30116 [\\/]* | ?:[\\/]* ) # Absolute name.
30117 ac_srcdir=$srcdir$ac_dir_suffix;
30118 ac_top_srcdir=$srcdir
30119 ac_abs_top_srcdir=$srcdir ;;
30120 *) # Relative name.
30121 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30122 ac_top_srcdir=$ac_top_build_prefix$srcdir
30123 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30124 esac
30125 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30128 case $ac_mode in
30131 # CONFIG_FILE
30134 case $INSTALL in
30135 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30136 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30137 esac
30138 ac_MKDIR_P=$MKDIR_P
30139 case $MKDIR_P in
30140 [\\/$]* | ?:[\\/]* ) ;;
30141 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30142 esac
30143 _ACEOF
30145 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30146 # If the template does not know about datarootdir, expand it.
30147 # FIXME: This hack should be removed a few years after 2.60.
30148 ac_datarootdir_hack=; ac_datarootdir_seen=
30149 ac_sed_dataroot='
30150 /datarootdir/ {
30154 /@datadir@/p
30155 /@docdir@/p
30156 /@infodir@/p
30157 /@localedir@/p
30158 /@mandir@/p'
30159 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30160 *datarootdir*) ac_datarootdir_seen=yes;;
30161 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30162 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30163 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30164 _ACEOF
30165 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30166 ac_datarootdir_hack='
30167 s&@datadir@&$datadir&g
30168 s&@docdir@&$docdir&g
30169 s&@infodir@&$infodir&g
30170 s&@localedir@&$localedir&g
30171 s&@mandir@&$mandir&g
30172 s&\\\${datarootdir}&$datarootdir&g' ;;
30173 esac
30174 _ACEOF
30176 # Neutralize VPATH when `$srcdir' = `.'.
30177 # Shell code in configure.ac might set extrasub.
30178 # FIXME: do we really want to maintain this feature?
30179 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30180 ac_sed_extra="$ac_vpsub
30181 $extrasub
30182 _ACEOF
30183 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30185 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30186 s|@configure_input@|$ac_sed_conf_input|;t t
30187 s&@top_builddir@&$ac_top_builddir_sub&;t t
30188 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30189 s&@srcdir@&$ac_srcdir&;t t
30190 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30191 s&@top_srcdir@&$ac_top_srcdir&;t t
30192 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30193 s&@builddir@&$ac_builddir&;t t
30194 s&@abs_builddir@&$ac_abs_builddir&;t t
30195 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30196 s&@INSTALL@&$ac_INSTALL&;t t
30197 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30198 $ac_datarootdir_hack
30200 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30201 if $ac_cs_awk_getline; then
30202 $AWK -f "$tmp/subs.awk"
30203 else
30204 $AWK -f "$tmp/subs.awk" | $SHELL
30205 fi >$tmp/out \
30206 || as_fn_error "could not create $ac_file" "$LINENO" 5
30208 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30209 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30210 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30211 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30212 which seems to be undefined. Please make sure it is defined." >&5
30213 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30214 which seems to be undefined. Please make sure it is defined." >&2;}
30216 rm -f "$tmp/stdin"
30217 case $ac_file in
30218 -) cat "$tmp/out" && rm -f "$tmp/out";;
30219 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30220 esac \
30221 || as_fn_error "could not create $ac_file" "$LINENO" 5
30225 # CONFIG_HEADER
30227 if test x"$ac_file" != x-; then
30229 $as_echo "/* $configure_input */" \
30230 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30231 } >"$tmp/config.h" \
30232 || as_fn_error "could not create $ac_file" "$LINENO" 5
30233 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30234 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30235 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30236 else
30237 rm -f "$ac_file"
30238 mv "$tmp/config.h" "$ac_file" \
30239 || as_fn_error "could not create $ac_file" "$LINENO" 5
30241 else
30242 $as_echo "/* $configure_input */" \
30243 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30244 || as_fn_error "could not create -" "$LINENO" 5
30246 # Compute "$ac_file"'s index in $config_headers.
30247 _am_arg="$ac_file"
30248 _am_stamp_count=1
30249 for _am_header in $config_headers :; do
30250 case $_am_header in
30251 $_am_arg | $_am_arg:* )
30252 break ;;
30254 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30255 esac
30256 done
30257 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30258 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30259 X"$_am_arg" : 'X\(//\)[^/]' \| \
30260 X"$_am_arg" : 'X\(//\)$' \| \
30261 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30262 $as_echo X"$_am_arg" |
30263 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30264 s//\1/
30267 /^X\(\/\/\)[^/].*/{
30268 s//\1/
30271 /^X\(\/\/\)$/{
30272 s//\1/
30275 /^X\(\/\).*/{
30276 s//\1/
30279 s/.*/./; q'`/stamp-h$_am_stamp_count
30282 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30283 $as_echo "$as_me: executing $ac_file commands" >&6;}
30285 esac
30288 case $ac_file$ac_mode in
30289 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30290 # Autoconf 2.62 quotes --file arguments for eval, but not when files
30291 # are listed without --file. Let's play safe and only enable the eval
30292 # if we detect the quoting.
30293 case $CONFIG_FILES in
30294 *\'*) eval set x "$CONFIG_FILES" ;;
30295 *) set x $CONFIG_FILES ;;
30296 esac
30297 shift
30298 for mf
30300 # Strip MF so we end up with the name of the file.
30301 mf=`echo "$mf" | sed -e 's/:.*$//'`
30302 # Check whether this is an Automake generated Makefile or not.
30303 # We used to match only the files named `Makefile.in', but
30304 # some people rename them; so instead we look at the file content.
30305 # Grep'ing the first line is not enough: some people post-process
30306 # each Makefile.in and add a new line on top of each file to say so.
30307 # Grep'ing the whole file is not good either: AIX grep has a line
30308 # limit of 2048, but all sed's we know have understand at least 4000.
30309 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30310 dirpart=`$as_dirname -- "$mf" ||
30311 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30312 X"$mf" : 'X\(//\)[^/]' \| \
30313 X"$mf" : 'X\(//\)$' \| \
30314 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30315 $as_echo X"$mf" |
30316 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30317 s//\1/
30320 /^X\(\/\/\)[^/].*/{
30321 s//\1/
30324 /^X\(\/\/\)$/{
30325 s//\1/
30328 /^X\(\/\).*/{
30329 s//\1/
30332 s/.*/./; q'`
30333 else
30334 continue
30336 # Extract the definition of DEPDIR, am__include, and am__quote
30337 # from the Makefile without running `make'.
30338 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30339 test -z "$DEPDIR" && continue
30340 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30341 test -z "am__include" && continue
30342 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30343 # When using ansi2knr, U may be empty or an underscore; expand it
30344 U=`sed -n 's/^U = //p' < "$mf"`
30345 # Find all dependency output files, they are included files with
30346 # $(DEPDIR) in their names. We invoke sed twice because it is the
30347 # simplest approach to changing $(DEPDIR) to its actual value in the
30348 # expansion.
30349 for file in `sed -n "
30350 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30351 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
30352 # Make sure the directory exists.
30353 test -f "$dirpart/$file" && continue
30354 fdir=`$as_dirname -- "$file" ||
30355 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30356 X"$file" : 'X\(//\)[^/]' \| \
30357 X"$file" : 'X\(//\)$' \| \
30358 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30359 $as_echo X"$file" |
30360 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30361 s//\1/
30364 /^X\(\/\/\)[^/].*/{
30365 s//\1/
30368 /^X\(\/\/\)$/{
30369 s//\1/
30372 /^X\(\/\).*/{
30373 s//\1/
30376 s/.*/./; q'`
30377 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30378 # echo "creating $dirpart/$file"
30379 echo '# dummy' > "$dirpart/$file"
30380 done
30381 done
30384 "src/epaths.h":C)
30385 if test "${opsys}" = "mingw32"; then
30386 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
30387 else
30388 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
30391 "src/.gdbinit":C)
30392 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
30393 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
30397 esac
30398 done # for ac_tag
30401 as_fn_exit 0
30402 _ACEOF
30403 ac_clean_files=$ac_clean_files_save
30405 test $ac_write_fail = 0 ||
30406 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
30409 # configure is writing to config.log, and then calls config.status.
30410 # config.status does its own redirection, appending to config.log.
30411 # Unfortunately, on DOS this fails, as config.log is still kept open
30412 # by configure, so config.status won't be able to write to it; its
30413 # output is simply discarded. So we exec the FD to /dev/null,
30414 # effectively closing config.log, so it can be properly (re)opened and
30415 # appended to by config.status. When coming back to configure, we
30416 # need to make the FD available again.
30417 if test "$no_create" != yes; then
30418 ac_cs_success=:
30419 ac_config_status_args=
30420 test "$silent" = yes &&
30421 ac_config_status_args="$ac_config_status_args --quiet"
30422 exec 5>/dev/null
30423 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30424 exec 5>>config.log
30425 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30426 # would make configure fail if this is the last instruction.
30427 $ac_cs_success || as_fn_exit $?
30429 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30430 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30431 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}