Auto-commit of generated files.
[emacs.git] / autogen / configure
blobc5ee6973db8504ff392aa30e0081e3bff60321e2
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 ns_check_file
608 WINDOW_SYSTEM_OBJ
609 EMACS_HEAPSIZE
610 TEMACS_POST_LINK
611 ADDSECTION
612 LD_SWITCH_SYSTEM_TEMACS
613 LIBGNU_LTLIBDEPS
614 LIBGNU_LIBDEPS
615 gltests_WITNESS
616 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE
617 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE
618 gl_GNULIB_ENABLED_tempname_FALSE
619 gl_GNULIB_ENABLED_tempname_TRUE
620 gl_GNULIB_ENABLED_strtoull_FALSE
621 gl_GNULIB_ENABLED_strtoull_TRUE
622 gl_GNULIB_ENABLED_strtoll_FALSE
623 gl_GNULIB_ENABLED_strtoll_TRUE
624 gl_GNULIB_ENABLED_stat_FALSE
625 gl_GNULIB_ENABLED_stat_TRUE
626 gl_GNULIB_ENABLED_secure_getenv_FALSE
627 gl_GNULIB_ENABLED_secure_getenv_TRUE
628 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
629 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
630 gl_GNULIB_ENABLED_pathmax_FALSE
631 gl_GNULIB_ENABLED_pathmax_TRUE
632 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
633 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
634 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
635 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
636 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
637 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
638 gl_GNULIB_ENABLED_getgroups_FALSE
639 gl_GNULIB_ENABLED_getgroups_TRUE
640 gl_GNULIB_ENABLED_getdtablesize_FALSE
641 gl_GNULIB_ENABLED_getdtablesize_TRUE
642 gl_GNULIB_ENABLED_euidaccess_FALSE
643 gl_GNULIB_ENABLED_euidaccess_TRUE
644 gl_GNULIB_ENABLED_dosname_FALSE
645 gl_GNULIB_ENABLED_dosname_TRUE
646 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE
647 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE
648 LTLIBINTL
649 LIBINTL
650 LIB_EACCESS
651 WINDOWS_64_BIT_OFF_T
652 HAVE_UNISTD_H
653 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
654 NEXT_UNISTD_H
655 LIB_TIMER_TIME
656 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
657 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
658 TIME_H_DEFINES_STRUCT_TIMESPEC
659 NEXT_AS_FIRST_DIRECTIVE_TIME_H
660 NEXT_TIME_H
661 WINDOWS_64_BIT_ST_SIZE
662 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
663 NEXT_SYS_STAT_H
664 NEXT_AS_FIRST_DIRECTIVE_STRING_H
665 NEXT_STRING_H
666 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
667 NEXT_STDLIB_H
668 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
669 NEXT_STDIO_H
670 REPLACE_VSPRINTF
671 REPLACE_VSNPRINTF
672 REPLACE_VPRINTF
673 REPLACE_VFPRINTF
674 REPLACE_VDPRINTF
675 REPLACE_VASPRINTF
676 REPLACE_TMPFILE
677 REPLACE_STDIO_WRITE_FUNCS
678 REPLACE_STDIO_READ_FUNCS
679 REPLACE_SPRINTF
680 REPLACE_SNPRINTF
681 REPLACE_RENAMEAT
682 REPLACE_RENAME
683 REPLACE_REMOVE
684 REPLACE_PRINTF
685 REPLACE_POPEN
686 REPLACE_PERROR
687 REPLACE_OBSTACK_PRINTF
688 REPLACE_GETLINE
689 REPLACE_GETDELIM
690 REPLACE_FTELLO
691 REPLACE_FTELL
692 REPLACE_FSEEKO
693 REPLACE_FSEEK
694 REPLACE_FREOPEN
695 REPLACE_FPURGE
696 REPLACE_FPRINTF
697 REPLACE_FOPEN
698 REPLACE_FFLUSH
699 REPLACE_FDOPEN
700 REPLACE_FCLOSE
701 REPLACE_DPRINTF
702 HAVE_VDPRINTF
703 HAVE_VASPRINTF
704 HAVE_RENAMEAT
705 HAVE_POPEN
706 HAVE_PCLOSE
707 HAVE_FTELLO
708 HAVE_FSEEKO
709 HAVE_DPRINTF
710 HAVE_DECL_VSNPRINTF
711 HAVE_DECL_SNPRINTF
712 HAVE_DECL_OBSTACK_PRINTF
713 HAVE_DECL_GETLINE
714 HAVE_DECL_GETDELIM
715 HAVE_DECL_FTELLO
716 HAVE_DECL_FSEEKO
717 HAVE_DECL_FPURGE
718 GNULIB_VSPRINTF_POSIX
719 GNULIB_VSNPRINTF
720 GNULIB_VPRINTF_POSIX
721 GNULIB_VPRINTF
722 GNULIB_VFPRINTF_POSIX
723 GNULIB_VFPRINTF
724 GNULIB_VDPRINTF
725 GNULIB_VSCANF
726 GNULIB_VFSCANF
727 GNULIB_VASPRINTF
728 GNULIB_TMPFILE
729 GNULIB_STDIO_H_SIGPIPE
730 GNULIB_STDIO_H_NONBLOCKING
731 GNULIB_SPRINTF_POSIX
732 GNULIB_SNPRINTF
733 GNULIB_SCANF
734 GNULIB_RENAMEAT
735 GNULIB_RENAME
736 GNULIB_REMOVE
737 GNULIB_PUTS
738 GNULIB_PUTCHAR
739 GNULIB_PUTC
740 GNULIB_PRINTF_POSIX
741 GNULIB_PRINTF
742 GNULIB_POPEN
743 GNULIB_PERROR
744 GNULIB_PCLOSE
745 GNULIB_OBSTACK_PRINTF_POSIX
746 GNULIB_OBSTACK_PRINTF
747 GNULIB_GETLINE
748 GNULIB_GETDELIM
749 GNULIB_GETCHAR
750 GNULIB_GETC
751 GNULIB_FWRITE
752 GNULIB_FTELLO
753 GNULIB_FTELL
754 GNULIB_FSEEKO
755 GNULIB_FSEEK
756 GNULIB_FSCANF
757 GNULIB_FREOPEN
758 GNULIB_FREAD
759 GNULIB_FPUTS
760 GNULIB_FPUTC
761 GNULIB_FPURGE
762 GNULIB_FPRINTF_POSIX
763 GNULIB_FPRINTF
764 GNULIB_FOPEN
765 GNULIB_FGETS
766 GNULIB_FGETC
767 GNULIB_FFLUSH
768 GNULIB_FDOPEN
769 GNULIB_FCLOSE
770 GNULIB_DPRINTF
771 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
772 NEXT_STDDEF_H
773 GL_GENERATE_STDDEF_H_FALSE
774 GL_GENERATE_STDDEF_H_TRUE
775 STDDEF_H
776 HAVE_WCHAR_T
777 REPLACE_NULL
778 HAVE__BOOL
779 GL_GENERATE_STDBOOL_H_FALSE
780 GL_GENERATE_STDBOOL_H_TRUE
781 STDBOOL_H
782 GL_GENERATE_STDARG_H_FALSE
783 GL_GENERATE_STDARG_H_TRUE
784 STDARG_H
785 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
786 NEXT_STDARG_H
787 GL_GENERATE_STDALIGN_H_FALSE
788 GL_GENERATE_STDALIGN_H_TRUE
789 STDALIGN_H
790 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
791 NEXT_SIGNAL_H
792 USE_ACL
793 LIB_ACL
794 LIB_PTHREAD_SIGMASK
795 REPLACE_RAISE
796 REPLACE_PTHREAD_SIGMASK
797 HAVE_SIGHANDLER_T
798 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
799 HAVE_STRUCT_SIGACTION_SA_SIGACTION
800 HAVE_SIGACTION
801 HAVE_SIGINFO_T
802 HAVE_SIGSET_T
803 HAVE_RAISE
804 HAVE_PTHREAD_SIGMASK
805 HAVE_POSIX_SIGNALBLOCKING
806 GNULIB_SIGACTION
807 GNULIB_SIGPROCMASK
808 GNULIB_SIGNAL_H_SIGPIPE
809 GNULIB_RAISE
810 GNULIB_PTHREAD_SIGMASK
811 HAVE_SYS_SELECT_H
812 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
813 NEXT_SYS_SELECT_H
814 REPLACE_SELECT
815 REPLACE_PSELECT
816 HAVE_PSELECT
817 GNULIB_SELECT
818 GNULIB_PSELECT
819 REPLACE_TIMEGM
820 REPLACE_NANOSLEEP
821 REPLACE_MKTIME
822 REPLACE_LOCALTIME_R
823 HAVE_TIMEGM
824 HAVE_STRPTIME
825 HAVE_NANOSLEEP
826 HAVE_DECL_LOCALTIME_R
827 GNULIB_TIME_R
828 GNULIB_TIMEGM
829 GNULIB_STRPTIME
830 GNULIB_NANOSLEEP
831 GNULIB_MKTIME
832 UNDEFINE_STRTOK_R
833 REPLACE_STRTOK_R
834 REPLACE_STRSIGNAL
835 REPLACE_STRNLEN
836 REPLACE_STRNDUP
837 REPLACE_STRNCAT
838 REPLACE_STRERROR_R
839 REPLACE_STRERROR
840 REPLACE_STRCHRNUL
841 REPLACE_STRCASESTR
842 REPLACE_STRSTR
843 REPLACE_STRDUP
844 REPLACE_STPNCPY
845 REPLACE_MEMMEM
846 REPLACE_MEMCHR
847 HAVE_STRVERSCMP
848 HAVE_DECL_STRSIGNAL
849 HAVE_DECL_STRERROR_R
850 HAVE_DECL_STRTOK_R
851 HAVE_STRCASESTR
852 HAVE_STRSEP
853 HAVE_STRPBRK
854 HAVE_DECL_STRNLEN
855 HAVE_DECL_STRNDUP
856 HAVE_DECL_STRDUP
857 HAVE_STRCHRNUL
858 HAVE_STPNCPY
859 HAVE_STPCPY
860 HAVE_RAWMEMCHR
861 HAVE_DECL_MEMRCHR
862 HAVE_MEMPCPY
863 HAVE_DECL_MEMMEM
864 HAVE_MEMCHR
865 HAVE_FFSLL
866 HAVE_FFSL
867 HAVE_MBSLEN
868 GNULIB_STRVERSCMP
869 GNULIB_STRSIGNAL
870 GNULIB_STRERROR_R
871 GNULIB_STRERROR
872 GNULIB_MBSTOK_R
873 GNULIB_MBSSEP
874 GNULIB_MBSSPN
875 GNULIB_MBSPBRK
876 GNULIB_MBSCSPN
877 GNULIB_MBSCASESTR
878 GNULIB_MBSPCASECMP
879 GNULIB_MBSNCASECMP
880 GNULIB_MBSCASECMP
881 GNULIB_MBSSTR
882 GNULIB_MBSRCHR
883 GNULIB_MBSCHR
884 GNULIB_MBSNLEN
885 GNULIB_MBSLEN
886 GNULIB_STRTOK_R
887 GNULIB_STRCASESTR
888 GNULIB_STRSTR
889 GNULIB_STRSEP
890 GNULIB_STRPBRK
891 GNULIB_STRNLEN
892 GNULIB_STRNDUP
893 GNULIB_STRNCAT
894 GNULIB_STRDUP
895 GNULIB_STRCHRNUL
896 GNULIB_STPNCPY
897 GNULIB_STPCPY
898 GNULIB_RAWMEMCHR
899 GNULIB_MEMRCHR
900 GNULIB_MEMPCPY
901 GNULIB_MEMMEM
902 GNULIB_MEMCHR
903 GNULIB_FFSLL
904 GNULIB_FFSL
905 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
906 NEXT_INTTYPES_H
907 UINT64_MAX_EQ_ULONG_MAX
908 UINT32_MAX_LT_UINTMAX_MAX
909 PRIPTR_PREFIX
910 PRI_MACROS_BROKEN
911 INT64_MAX_EQ_LONG_MAX
912 INT32_MAX_LT_INTMAX_MAX
913 REPLACE_STRTOIMAX
914 HAVE_DECL_STRTOUMAX
915 HAVE_DECL_STRTOIMAX
916 HAVE_DECL_IMAXDIV
917 HAVE_DECL_IMAXABS
918 GNULIB_STRTOUMAX
919 GNULIB_STRTOIMAX
920 GNULIB_IMAXDIV
921 GNULIB_IMAXABS
922 GL_GENERATE_STDINT_H_FALSE
923 GL_GENERATE_STDINT_H_TRUE
924 STDINT_H
925 WINT_T_SUFFIX
926 WCHAR_T_SUFFIX
927 SIG_ATOMIC_T_SUFFIX
928 SIZE_T_SUFFIX
929 PTRDIFF_T_SUFFIX
930 HAVE_SIGNED_WINT_T
931 HAVE_SIGNED_WCHAR_T
932 HAVE_SIGNED_SIG_ATOMIC_T
933 BITSIZEOF_WINT_T
934 BITSIZEOF_WCHAR_T
935 BITSIZEOF_SIG_ATOMIC_T
936 BITSIZEOF_SIZE_T
937 BITSIZEOF_PTRDIFF_T
938 APPLE_UNIVERSAL_BUILD
939 HAVE_SYS_BITYPES_H
940 HAVE_SYS_INTTYPES_H
941 HAVE_STDINT_H
942 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
943 NEXT_STDINT_H
944 HAVE_SYS_TYPES_H
945 HAVE_INTTYPES_H
946 HAVE_WCHAR_H
947 HAVE_UNSIGNED_LONG_LONG_INT
948 HAVE_LONG_LONG_INT
949 HAVE_WINSOCK2_H
950 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
951 NEXT_SYS_TIME_H
952 REPLACE_STRUCT_TIMEVAL
953 REPLACE_GETTIMEOFDAY
954 HAVE_SYS_TIME_H
955 HAVE_STRUCT_TIMEVAL
956 HAVE_GETTIMEOFDAY
957 GNULIB_GETTIMEOFDAY
958 GNULIB_GL_UNISTD_H_GETOPT
959 GETOPT_H
960 HAVE_GETOPT_H
961 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
962 NEXT_GETOPT_H
963 GETLOADAVG_LIBS
964 REPLACE_WCTOMB
965 REPLACE_UNSETENV
966 REPLACE_STRTOD
967 REPLACE_SETENV
968 REPLACE_REALPATH
969 REPLACE_REALLOC
970 REPLACE_RANDOM_R
971 REPLACE_PUTENV
972 REPLACE_PTSNAME_R
973 REPLACE_PTSNAME
974 REPLACE_MKSTEMP
975 REPLACE_MBTOWC
976 REPLACE_MALLOC
977 REPLACE_CANONICALIZE_FILE_NAME
978 REPLACE_CALLOC
979 HAVE_DECL_UNSETENV
980 HAVE_UNLOCKPT
981 HAVE_SYS_LOADAVG_H
982 HAVE_STRUCT_RANDOM_DATA
983 HAVE_STRTOULL
984 HAVE_STRTOLL
985 HAVE_STRTOD
986 HAVE_DECL_SETENV
987 HAVE_SETENV
988 HAVE_SECURE_GETENV
989 HAVE_RPMATCH
990 HAVE_REALPATH
991 HAVE_RANDOM_R
992 HAVE_RANDOM_H
993 HAVE_RANDOM
994 HAVE_PTSNAME_R
995 HAVE_PTSNAME
996 HAVE_POSIX_OPENPT
997 HAVE_MKSTEMPS
998 HAVE_MKSTEMP
999 HAVE_MKOSTEMPS
1000 HAVE_MKOSTEMP
1001 HAVE_MKDTEMP
1002 HAVE_GRANTPT
1003 HAVE_GETSUBOPT
1004 HAVE_DECL_GETLOADAVG
1005 HAVE_CANONICALIZE_FILE_NAME
1006 HAVE_ATOLL
1007 HAVE__EXIT
1008 GNULIB_WCTOMB
1009 GNULIB_UNSETENV
1010 GNULIB_UNLOCKPT
1011 GNULIB_SYSTEM_POSIX
1012 GNULIB_STRTOULL
1013 GNULIB_STRTOLL
1014 GNULIB_STRTOD
1015 GNULIB_SETENV
1016 GNULIB_SECURE_GETENV
1017 GNULIB_RPMATCH
1018 GNULIB_REALPATH
1019 GNULIB_REALLOC_POSIX
1020 GNULIB_RANDOM_R
1021 GNULIB_RANDOM
1022 GNULIB_PUTENV
1023 GNULIB_PTSNAME_R
1024 GNULIB_PTSNAME
1025 GNULIB_POSIX_OPENPT
1026 GNULIB_MKSTEMPS
1027 GNULIB_MKSTEMP
1028 GNULIB_MKOSTEMPS
1029 GNULIB_MKOSTEMP
1030 GNULIB_MKDTEMP
1031 GNULIB_MBTOWC
1032 GNULIB_MALLOC_POSIX
1033 GNULIB_GRANTPT
1034 GNULIB_GETSUBOPT
1035 GNULIB_GETLOADAVG
1036 GNULIB_CANONICALIZE_FILE_NAME
1037 GNULIB_CALLOC_POSIX
1038 GNULIB_ATOLL
1039 GNULIB__EXIT
1040 REPLACE_UTIMENSAT
1041 REPLACE_STAT
1042 REPLACE_MKNOD
1043 REPLACE_MKFIFO
1044 REPLACE_MKDIR
1045 REPLACE_LSTAT
1046 REPLACE_FUTIMENS
1047 REPLACE_FSTATAT
1048 REPLACE_FSTAT
1049 HAVE_UTIMENSAT
1050 HAVE_MKNODAT
1051 HAVE_MKNOD
1052 HAVE_MKFIFOAT
1053 HAVE_MKFIFO
1054 HAVE_MKDIRAT
1055 HAVE_LSTAT
1056 HAVE_LCHMOD
1057 HAVE_FUTIMENS
1058 HAVE_FSTATAT
1059 HAVE_FCHMODAT
1060 GNULIB_UTIMENSAT
1061 GNULIB_STAT
1062 GNULIB_MKNODAT
1063 GNULIB_MKNOD
1064 GNULIB_MKFIFOAT
1065 GNULIB_MKFIFO
1066 GNULIB_MKDIRAT
1067 GNULIB_LSTAT
1068 GNULIB_LCHMOD
1069 GNULIB_FUTIMENS
1070 GNULIB_FSTATAT
1071 GNULIB_FSTAT
1072 GNULIB_FCHMODAT
1073 LIB_FDATASYNC
1074 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1075 NEXT_FCNTL_H
1076 REPLACE_OPENAT
1077 REPLACE_OPEN
1078 REPLACE_FCNTL
1079 HAVE_OPENAT
1080 HAVE_FCNTL
1081 GNULIB_OPENAT
1082 GNULIB_OPEN
1083 GNULIB_NONBLOCKING
1084 GNULIB_FCNTL
1085 GL_GENERATE_EXECINFO_H_FALSE
1086 GL_GENERATE_EXECINFO_H_TRUE
1087 LIB_EXECINFO
1088 EXECINFO_H
1089 EOVERFLOW_VALUE
1090 EOVERFLOW_HIDDEN
1091 ENOLINK_VALUE
1092 ENOLINK_HIDDEN
1093 EMULTIHOP_VALUE
1094 EMULTIHOP_HIDDEN
1095 GL_GENERATE_ERRNO_H_FALSE
1096 GL_GENERATE_ERRNO_H_TRUE
1097 ERRNO_H
1098 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1099 NEXT_ERRNO_H
1100 HAVE_DIRENT_H
1101 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1102 NEXT_DIRENT_H
1103 PRAGMA_COLUMNS
1104 PRAGMA_SYSTEM_HEADER
1105 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1106 INCLUDE_NEXT
1107 REPLACE_FDOPENDIR
1108 REPLACE_DIRFD
1109 REPLACE_CLOSEDIR
1110 REPLACE_OPENDIR
1111 HAVE_ALPHASORT
1112 HAVE_SCANDIR
1113 HAVE_FDOPENDIR
1114 HAVE_DECL_FDOPENDIR
1115 HAVE_DECL_DIRFD
1116 HAVE_CLOSEDIR
1117 HAVE_REWINDDIR
1118 HAVE_READDIR
1119 HAVE_OPENDIR
1120 GNULIB_ALPHASORT
1121 GNULIB_SCANDIR
1122 GNULIB_FDOPENDIR
1123 GNULIB_DIRFD
1124 GNULIB_CLOSEDIR
1125 GNULIB_REWINDDIR
1126 GNULIB_READDIR
1127 GNULIB_OPENDIR
1128 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1129 UNISTD_H_HAVE_WINSOCK2_H
1130 REPLACE_WRITE
1131 REPLACE_USLEEP
1132 REPLACE_UNLINKAT
1133 REPLACE_UNLINK
1134 REPLACE_TTYNAME_R
1135 REPLACE_SYMLINK
1136 REPLACE_SLEEP
1137 REPLACE_RMDIR
1138 REPLACE_READLINK
1139 REPLACE_READ
1140 REPLACE_PWRITE
1141 REPLACE_PREAD
1142 REPLACE_LSEEK
1143 REPLACE_LINKAT
1144 REPLACE_LINK
1145 REPLACE_LCHOWN
1146 REPLACE_ISATTY
1147 REPLACE_GETPAGESIZE
1148 REPLACE_GETGROUPS
1149 REPLACE_GETLOGIN_R
1150 REPLACE_GETDOMAINNAME
1151 REPLACE_GETCWD
1152 REPLACE_FTRUNCATE
1153 REPLACE_FCHOWNAT
1154 REPLACE_DUP2
1155 REPLACE_DUP
1156 REPLACE_CLOSE
1157 REPLACE_CHOWN
1158 HAVE_SYS_PARAM_H
1159 HAVE_OS_H
1160 HAVE_DECL_TTYNAME_R
1161 HAVE_DECL_SETHOSTNAME
1162 HAVE_DECL_GETUSERSHELL
1163 HAVE_DECL_GETPAGESIZE
1164 HAVE_DECL_GETLOGIN_R
1165 HAVE_DECL_GETDOMAINNAME
1166 HAVE_DECL_FDATASYNC
1167 HAVE_DECL_FCHDIR
1168 HAVE_DECL_ENVIRON
1169 HAVE_USLEEP
1170 HAVE_UNLINKAT
1171 HAVE_SYMLINKAT
1172 HAVE_SYMLINK
1173 HAVE_SLEEP
1174 HAVE_SETHOSTNAME
1175 HAVE_READLINKAT
1176 HAVE_READLINK
1177 HAVE_PWRITE
1178 HAVE_PREAD
1179 HAVE_PIPE2
1180 HAVE_PIPE
1181 HAVE_LINKAT
1182 HAVE_LINK
1183 HAVE_LCHOWN
1184 HAVE_GROUP_MEMBER
1185 HAVE_GETPAGESIZE
1186 HAVE_GETLOGIN
1187 HAVE_GETHOSTNAME
1188 HAVE_GETGROUPS
1189 HAVE_GETDTABLESIZE
1190 HAVE_FTRUNCATE
1191 HAVE_FSYNC
1192 HAVE_FDATASYNC
1193 HAVE_FCHOWNAT
1194 HAVE_FCHDIR
1195 HAVE_FACCESSAT
1196 HAVE_EUIDACCESS
1197 HAVE_DUP3
1198 HAVE_DUP2
1199 HAVE_CHOWN
1200 GNULIB_WRITE
1201 GNULIB_USLEEP
1202 GNULIB_UNLINKAT
1203 GNULIB_UNLINK
1204 GNULIB_UNISTD_H_SIGPIPE
1205 GNULIB_UNISTD_H_NONBLOCKING
1206 GNULIB_TTYNAME_R
1207 GNULIB_SYMLINKAT
1208 GNULIB_SYMLINK
1209 GNULIB_SLEEP
1210 GNULIB_SETHOSTNAME
1211 GNULIB_RMDIR
1212 GNULIB_READLINKAT
1213 GNULIB_READLINK
1214 GNULIB_READ
1215 GNULIB_PWRITE
1216 GNULIB_PREAD
1217 GNULIB_PIPE2
1218 GNULIB_PIPE
1219 GNULIB_LSEEK
1220 GNULIB_LINKAT
1221 GNULIB_LINK
1222 GNULIB_LCHOWN
1223 GNULIB_ISATTY
1224 GNULIB_GROUP_MEMBER
1225 GNULIB_GETUSERSHELL
1226 GNULIB_GETPAGESIZE
1227 GNULIB_GETLOGIN_R
1228 GNULIB_GETLOGIN
1229 GNULIB_GETHOSTNAME
1230 GNULIB_GETGROUPS
1231 GNULIB_GETDTABLESIZE
1232 GNULIB_GETDOMAINNAME
1233 GNULIB_GETCWD
1234 GNULIB_FTRUNCATE
1235 GNULIB_FSYNC
1236 GNULIB_FDATASYNC
1237 GNULIB_FCHOWNAT
1238 GNULIB_FCHDIR
1239 GNULIB_FACCESSAT
1240 GNULIB_EUIDACCESS
1241 GNULIB_ENVIRON
1242 GNULIB_DUP3
1243 GNULIB_DUP2
1244 GNULIB_DUP
1245 GNULIB_CLOSE
1246 GNULIB_CHOWN
1247 GNULIB_CHDIR
1248 LIB_CLOCK_GETTIME
1249 GL_GENERATE_ALLOCA_H_FALSE
1250 GL_GENERATE_ALLOCA_H_TRUE
1251 ALLOCA_H
1252 ALLOCA
1253 GL_COND_LIBTOOL_FALSE
1254 GL_COND_LIBTOOL_TRUE
1255 POST_ALLOC_OBJ
1256 PRE_ALLOC_OBJ
1257 CYGWIN_OBJ
1258 RALLOC_OBJ
1259 OLDXMENU_DEPS
1260 LIBX_OTHER
1261 LIBXMENU
1262 OLDXMENU
1263 OLDXMENU_TARGET
1264 LIBXT_OTHER
1265 TOOLKIT_LIBW
1266 WIDGET_OBJ
1267 XOBJ
1268 XMENU_OBJ
1269 FONT_OBJ
1270 OTHER_FILES
1271 GNU_OBJC_CFLAGS
1272 ns_appsrc
1273 ns_appresdir
1274 ns_appbindir
1275 ns_appdir
1276 X_TOOLKIT_TYPE
1277 GNUSTEP_CFLAGS
1278 C_SWITCH_X_SITE
1279 LD_SWITCH_X_SITE
1280 gameuser
1281 gamedir
1282 bitmapdir
1283 etcdocdir
1284 archlibdir
1285 etcdir
1286 x_default_search_path
1287 lisppath
1288 locallisppath
1289 standardlisppath
1290 leimdir
1291 lispdir
1292 srcdir
1293 canonical
1294 configuration
1295 version
1296 copyright
1297 XGSELOBJ
1298 KRB4LIB
1299 DESLIB
1300 KRB5LIB
1301 CRYPTOLIB
1302 COM_ERRLIB
1303 LIBRESOLV
1304 LIBHESIOD
1305 TERMCAP_OBJ
1306 LIBS_TERMCAP
1307 BLESSMAIL_TARGET
1308 LIBS_MAIL
1309 liblockfile
1310 LIBXML2_LIBS
1311 LIBXML2_CFLAGS
1312 XINERAMA_LIBS
1313 XINERAMA_CFLAGS
1314 XRANDR_LIBS
1315 XRANDR_CFLAGS
1316 LIBXSM
1317 LIBGPM
1318 LIBGIF
1319 LIBTIFF
1320 LIBZ
1321 LIBPNG
1322 LIBJPEG
1323 LIBXPM
1324 M17N_FLT_LIBS
1325 M17N_FLT_CFLAGS
1326 LIBOTF_LIBS
1327 LIBOTF_CFLAGS
1328 FREETYPE_LIBS
1329 FREETYPE_CFLAGS
1330 XFT_LIBS
1331 XFT_CFLAGS
1332 FONTCONFIG_LIBS
1333 FONTCONFIG_CFLAGS
1334 LIBXMU
1335 LIBXTR6
1336 NOTIFY_OBJ
1337 GFILENOTIFY_LIBS
1338 GFILENOTIFY_CFLAGS
1339 LIBGNUTLS_LIBS
1340 LIBGNUTLS_CFLAGS
1341 LIBSELINUX_LIBS
1342 SETTINGS_LIBS
1343 SETTINGS_CFLAGS
1344 GOBJECT_LIBS
1345 GOBJECT_CFLAGS
1346 GCONF_LIBS
1347 GCONF_CFLAGS
1348 GSETTINGS_LIBS
1349 GSETTINGS_CFLAGS
1350 DBUS_OBJ
1351 DBUS_LIBS
1352 DBUS_CFLAGS
1353 GTK_OBJ
1354 GTK_LIBS
1355 GTK_CFLAGS
1356 IMAGEMAGICK_LIBS
1357 IMAGEMAGICK_CFLAGS
1358 RSVG_LIBS
1359 RSVG_CFLAGS
1360 LIB_PTHREAD
1361 VMLIMIT_OBJ
1362 GMALLOC_OBJ
1363 HAVE_XSERVER
1364 XARGS_LIMIT
1365 NTLIB
1366 LIB_WSOCK32
1367 LIBS_ECLIENT
1368 CM_OBJ
1369 NTDIR
1370 FIRSTFILE_OBJ
1371 W32_RES_LINK
1372 CLIENTW
1373 CLIENTRES
1374 UPDATE_MANIFEST
1375 EMACS_MANIFEST
1376 EMACSRES
1377 W32_LIBS
1378 W32_OBJ
1379 WINDRES
1380 NS_OBJC_OBJ
1381 NS_OBJ
1382 ns_self_contained
1383 INSTALL_ARCH_INDEP_EXTRA
1384 LIBS_GNUSTEP
1385 LD_SWITCH_X_SITE_RPATH
1386 XMKMF
1387 DEPFLAGS
1388 MKDEPDIR
1389 CFLAGS_SOUND
1390 ALSA_LIBS
1391 ALSA_CFLAGS
1392 LIBSOUND
1393 PKG_CONFIG
1394 LIB_MATH
1395 LIBS_SYSTEM
1396 C_SWITCH_SYSTEM
1397 UNEXEC_OBJ
1398 C_SWITCH_MACHINE
1399 LD_SWITCH_SYSTEM
1400 CANNOT_DUMP
1401 DOCMISC_W32
1402 INFO_OPTS
1403 INFO_EXT
1404 HAVE_MAKEINFO
1405 PAXCTL
1406 GZIP_PROG
1407 INSTALL_INFO
1408 LN_S_FILEONLY
1409 GNULIB_WARN_CFLAGS
1410 WARN_CFLAGS
1411 WERROR_CFLAGS
1412 RANLIB
1413 ARFLAGS
1415 EGREP
1416 GREP
1418 BUILDING_FOR_WINDOWSNT_FALSE
1419 BUILDING_FOR_WINDOWSNT_TRUE
1420 am__fastdepCC_FALSE
1421 am__fastdepCC_TRUE
1422 CCDEPMODE
1423 AMDEPBACKSLASH
1424 AMDEP_FALSE
1425 AMDEP_TRUE
1426 am__quote
1427 am__include
1428 DEPDIR
1429 OBJEXT
1430 EXEEXT
1431 ac_ct_CC
1432 CPPFLAGS
1433 LDFLAGS
1434 CFLAGS
1436 host_os
1437 host_vendor
1438 host_cpu
1439 host
1440 build_os
1441 build_vendor
1442 build_cpu
1443 build
1444 PROFILING_CFLAGS
1445 cache_file
1446 am__untar
1447 am__tar
1448 AMTAR
1449 am__leading_dot
1450 SET_MAKE
1452 mkdir_p
1453 MKDIR_P
1454 INSTALL_STRIP_PROGRAM
1455 STRIP
1456 install_sh
1457 MAKEINFO
1458 AUTOHEADER
1459 AUTOMAKE
1460 AUTOCONF
1461 ACLOCAL
1462 VERSION
1463 PACKAGE
1464 CYGPATH_W
1465 am__isrc
1466 INSTALL_DATA
1467 INSTALL_SCRIPT
1468 INSTALL_PROGRAM
1469 target_alias
1470 host_alias
1471 build_alias
1472 LIBS
1473 ECHO_T
1474 ECHO_N
1475 ECHO_C
1476 DEFS
1477 mandir
1478 localedir
1479 libdir
1480 psdir
1481 pdfdir
1482 dvidir
1483 htmldir
1484 infodir
1485 docdir
1486 oldincludedir
1487 includedir
1488 localstatedir
1489 sharedstatedir
1490 sysconfdir
1491 datadir
1492 datarootdir
1493 libexecdir
1494 sbindir
1495 bindir
1496 program_transform_name
1497 prefix
1498 exec_prefix
1499 PACKAGE_URL
1500 PACKAGE_BUGREPORT
1501 PACKAGE_STRING
1502 PACKAGE_VERSION
1503 PACKAGE_TARNAME
1504 PACKAGE_NAME
1505 PATH_SEPARATOR
1506 SHELL'
1507 ac_subst_files='deps_frag
1508 lisp_frag'
1509 ac_user_opts='
1510 enable_option_checking
1511 with_all
1512 with_pop
1513 with_kerberos
1514 with_kerberos5
1515 with_hesiod
1516 with_mmdf
1517 with_mail_unlink
1518 with_mailhost
1519 with_sound
1520 with_x_toolkit
1521 with_wide_int
1522 with_xpm
1523 with_jpeg
1524 with_tiff
1525 with_gif
1526 with_png
1527 with_rsvg
1528 with_xml2
1529 with_imagemagick
1530 with_xft
1531 with_libotf
1532 with_m17n_flt
1533 with_toolkit_scroll_bars
1534 with_xaw3d
1535 with_xim
1536 with_ns
1537 with_w32
1538 with_gpm
1539 with_dbus
1540 with_gconf
1541 with_gsettings
1542 with_selinux
1543 with_gnutls
1544 with_zlib
1545 with_file_notification
1546 with_makeinfo
1547 with_compress_install
1548 with_pkg_config_prog
1549 with_gameuser
1550 with_gnustep_conf
1551 enable_ns_self_contained
1552 enable_locallisppath
1553 enable_checking
1554 enable_check_lisp_object_type
1555 enable_profiling
1556 enable_autodepend
1557 enable_gtk_deprecation_warnings
1558 enable_dependency_tracking
1559 enable_largefile
1560 enable_gcc_warnings
1561 enable_link_time_optimization
1562 with_x
1563 enable_acl
1565 ac_precious_vars='build_alias
1566 host_alias
1567 target_alias
1569 CFLAGS
1570 LDFLAGS
1571 LIBS
1572 CPPFLAGS
1574 XMKMF'
1577 # Initialize some variables set by options.
1578 ac_init_help=
1579 ac_init_version=false
1580 ac_unrecognized_opts=
1581 ac_unrecognized_sep=
1582 # The variables have the same names as the options, with
1583 # dashes changed to underlines.
1584 cache_file=/dev/null
1585 exec_prefix=NONE
1586 no_create=
1587 no_recursion=
1588 prefix=NONE
1589 program_prefix=NONE
1590 program_suffix=NONE
1591 program_transform_name=s,x,x,
1592 silent=
1593 site=
1594 srcdir=
1595 verbose=
1596 x_includes=NONE
1597 x_libraries=NONE
1599 # Installation directory options.
1600 # These are left unexpanded so users can "make install exec_prefix=/foo"
1601 # and all the variables that are supposed to be based on exec_prefix
1602 # by default will actually change.
1603 # Use braces instead of parens because sh, perl, etc. also accept them.
1604 # (The list follows the same order as the GNU Coding Standards.)
1605 bindir='${exec_prefix}/bin'
1606 sbindir='${exec_prefix}/sbin'
1607 libexecdir='${exec_prefix}/libexec'
1608 datarootdir='${prefix}/share'
1609 datadir='${datarootdir}'
1610 sysconfdir='${prefix}/etc'
1611 sharedstatedir='${prefix}/com'
1612 localstatedir='${prefix}/var'
1613 includedir='${prefix}/include'
1614 oldincludedir='/usr/include'
1615 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1616 infodir='${datarootdir}/info'
1617 htmldir='${docdir}'
1618 dvidir='${docdir}'
1619 pdfdir='${docdir}'
1620 psdir='${docdir}'
1621 libdir='${exec_prefix}/lib'
1622 localedir='${datarootdir}/locale'
1623 mandir='${datarootdir}/man'
1625 ac_prev=
1626 ac_dashdash=
1627 for ac_option
1629 # If the previous option needs an argument, assign it.
1630 if test -n "$ac_prev"; then
1631 eval $ac_prev=\$ac_option
1632 ac_prev=
1633 continue
1636 case $ac_option in
1637 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1638 *) ac_optarg=yes ;;
1639 esac
1641 # Accept the important Cygnus configure options, so we can diagnose typos.
1643 case $ac_dashdash$ac_option in
1645 ac_dashdash=yes ;;
1647 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1648 ac_prev=bindir ;;
1649 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1650 bindir=$ac_optarg ;;
1652 -build | --build | --buil | --bui | --bu)
1653 ac_prev=build_alias ;;
1654 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1655 build_alias=$ac_optarg ;;
1657 -cache-file | --cache-file | --cache-fil | --cache-fi \
1658 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1659 ac_prev=cache_file ;;
1660 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1661 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1662 cache_file=$ac_optarg ;;
1664 --config-cache | -C)
1665 cache_file=config.cache ;;
1667 -datadir | --datadir | --datadi | --datad)
1668 ac_prev=datadir ;;
1669 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1670 datadir=$ac_optarg ;;
1672 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1673 | --dataroo | --dataro | --datar)
1674 ac_prev=datarootdir ;;
1675 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1676 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1677 datarootdir=$ac_optarg ;;
1679 -disable-* | --disable-*)
1680 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1681 # Reject names that are not valid shell variable names.
1682 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1683 as_fn_error "invalid feature name: $ac_useropt"
1684 ac_useropt_orig=$ac_useropt
1685 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1686 case $ac_user_opts in
1688 "enable_$ac_useropt"
1689 "*) ;;
1690 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1691 ac_unrecognized_sep=', ';;
1692 esac
1693 eval enable_$ac_useropt=no ;;
1695 -docdir | --docdir | --docdi | --doc | --do)
1696 ac_prev=docdir ;;
1697 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1698 docdir=$ac_optarg ;;
1700 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1701 ac_prev=dvidir ;;
1702 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1703 dvidir=$ac_optarg ;;
1705 -enable-* | --enable-*)
1706 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1707 # Reject names that are not valid shell variable names.
1708 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1709 as_fn_error "invalid feature name: $ac_useropt"
1710 ac_useropt_orig=$ac_useropt
1711 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1712 case $ac_user_opts in
1714 "enable_$ac_useropt"
1715 "*) ;;
1716 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1717 ac_unrecognized_sep=', ';;
1718 esac
1719 eval enable_$ac_useropt=\$ac_optarg ;;
1721 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1722 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1723 | --exec | --exe | --ex)
1724 ac_prev=exec_prefix ;;
1725 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1726 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1727 | --exec=* | --exe=* | --ex=*)
1728 exec_prefix=$ac_optarg ;;
1730 -gas | --gas | --ga | --g)
1731 # Obsolete; use --with-gas.
1732 with_gas=yes ;;
1734 -help | --help | --hel | --he | -h)
1735 ac_init_help=long ;;
1736 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1737 ac_init_help=recursive ;;
1738 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1739 ac_init_help=short ;;
1741 -host | --host | --hos | --ho)
1742 ac_prev=host_alias ;;
1743 -host=* | --host=* | --hos=* | --ho=*)
1744 host_alias=$ac_optarg ;;
1746 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1747 ac_prev=htmldir ;;
1748 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1749 | --ht=*)
1750 htmldir=$ac_optarg ;;
1752 -includedir | --includedir | --includedi | --included | --include \
1753 | --includ | --inclu | --incl | --inc)
1754 ac_prev=includedir ;;
1755 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1756 | --includ=* | --inclu=* | --incl=* | --inc=*)
1757 includedir=$ac_optarg ;;
1759 -infodir | --infodir | --infodi | --infod | --info | --inf)
1760 ac_prev=infodir ;;
1761 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1762 infodir=$ac_optarg ;;
1764 -libdir | --libdir | --libdi | --libd)
1765 ac_prev=libdir ;;
1766 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1767 libdir=$ac_optarg ;;
1769 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1770 | --libexe | --libex | --libe)
1771 ac_prev=libexecdir ;;
1772 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1773 | --libexe=* | --libex=* | --libe=*)
1774 libexecdir=$ac_optarg ;;
1776 -localedir | --localedir | --localedi | --localed | --locale)
1777 ac_prev=localedir ;;
1778 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1779 localedir=$ac_optarg ;;
1781 -localstatedir | --localstatedir | --localstatedi | --localstated \
1782 | --localstate | --localstat | --localsta | --localst | --locals)
1783 ac_prev=localstatedir ;;
1784 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1785 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1786 localstatedir=$ac_optarg ;;
1788 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1789 ac_prev=mandir ;;
1790 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1791 mandir=$ac_optarg ;;
1793 -nfp | --nfp | --nf)
1794 # Obsolete; use --without-fp.
1795 with_fp=no ;;
1797 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1798 | --no-cr | --no-c | -n)
1799 no_create=yes ;;
1801 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1802 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1803 no_recursion=yes ;;
1805 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1806 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1807 | --oldin | --oldi | --old | --ol | --o)
1808 ac_prev=oldincludedir ;;
1809 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1810 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1811 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1812 oldincludedir=$ac_optarg ;;
1814 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1815 ac_prev=prefix ;;
1816 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1817 prefix=$ac_optarg ;;
1819 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1820 | --program-pre | --program-pr | --program-p)
1821 ac_prev=program_prefix ;;
1822 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1823 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1824 program_prefix=$ac_optarg ;;
1826 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1827 | --program-suf | --program-su | --program-s)
1828 ac_prev=program_suffix ;;
1829 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1830 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1831 program_suffix=$ac_optarg ;;
1833 -program-transform-name | --program-transform-name \
1834 | --program-transform-nam | --program-transform-na \
1835 | --program-transform-n | --program-transform- \
1836 | --program-transform | --program-transfor \
1837 | --program-transfo | --program-transf \
1838 | --program-trans | --program-tran \
1839 | --progr-tra | --program-tr | --program-t)
1840 ac_prev=program_transform_name ;;
1841 -program-transform-name=* | --program-transform-name=* \
1842 | --program-transform-nam=* | --program-transform-na=* \
1843 | --program-transform-n=* | --program-transform-=* \
1844 | --program-transform=* | --program-transfor=* \
1845 | --program-transfo=* | --program-transf=* \
1846 | --program-trans=* | --program-tran=* \
1847 | --progr-tra=* | --program-tr=* | --program-t=*)
1848 program_transform_name=$ac_optarg ;;
1850 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1851 ac_prev=pdfdir ;;
1852 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1853 pdfdir=$ac_optarg ;;
1855 -psdir | --psdir | --psdi | --psd | --ps)
1856 ac_prev=psdir ;;
1857 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1858 psdir=$ac_optarg ;;
1860 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1861 | -silent | --silent | --silen | --sile | --sil)
1862 silent=yes ;;
1864 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1865 ac_prev=sbindir ;;
1866 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1867 | --sbi=* | --sb=*)
1868 sbindir=$ac_optarg ;;
1870 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1871 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1872 | --sharedst | --shareds | --shared | --share | --shar \
1873 | --sha | --sh)
1874 ac_prev=sharedstatedir ;;
1875 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1876 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1877 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1878 | --sha=* | --sh=*)
1879 sharedstatedir=$ac_optarg ;;
1881 -site | --site | --sit)
1882 ac_prev=site ;;
1883 -site=* | --site=* | --sit=*)
1884 site=$ac_optarg ;;
1886 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1887 ac_prev=srcdir ;;
1888 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1889 srcdir=$ac_optarg ;;
1891 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1892 | --syscon | --sysco | --sysc | --sys | --sy)
1893 ac_prev=sysconfdir ;;
1894 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1895 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1896 sysconfdir=$ac_optarg ;;
1898 -target | --target | --targe | --targ | --tar | --ta | --t)
1899 ac_prev=target_alias ;;
1900 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1901 target_alias=$ac_optarg ;;
1903 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1904 verbose=yes ;;
1906 -version | --version | --versio | --versi | --vers | -V)
1907 ac_init_version=: ;;
1909 -with-* | --with-*)
1910 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1911 # Reject names that are not valid shell variable names.
1912 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1913 as_fn_error "invalid package name: $ac_useropt"
1914 ac_useropt_orig=$ac_useropt
1915 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1916 case $ac_user_opts in
1918 "with_$ac_useropt"
1919 "*) ;;
1920 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1921 ac_unrecognized_sep=', ';;
1922 esac
1923 eval with_$ac_useropt=\$ac_optarg ;;
1925 -without-* | --without-*)
1926 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1927 # Reject names that are not valid shell variable names.
1928 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1929 as_fn_error "invalid package name: $ac_useropt"
1930 ac_useropt_orig=$ac_useropt
1931 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1932 case $ac_user_opts in
1934 "with_$ac_useropt"
1935 "*) ;;
1936 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1937 ac_unrecognized_sep=', ';;
1938 esac
1939 eval with_$ac_useropt=no ;;
1941 --x)
1942 # Obsolete; use --with-x.
1943 with_x=yes ;;
1945 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1946 | --x-incl | --x-inc | --x-in | --x-i)
1947 ac_prev=x_includes ;;
1948 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1949 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1950 x_includes=$ac_optarg ;;
1952 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1953 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1954 ac_prev=x_libraries ;;
1955 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1956 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1957 x_libraries=$ac_optarg ;;
1959 -*) as_fn_error "unrecognized option: \`$ac_option'
1960 Try \`$0 --help' for more information."
1963 *=*)
1964 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1965 # Reject names that are not valid shell variable names.
1966 case $ac_envvar in #(
1967 '' | [0-9]* | *[!_$as_cr_alnum]* )
1968 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1969 esac
1970 eval $ac_envvar=\$ac_optarg
1971 export $ac_envvar ;;
1974 # FIXME: should be removed in autoconf 3.0.
1975 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1976 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1977 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1978 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1981 esac
1982 done
1984 if test -n "$ac_prev"; then
1985 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1986 as_fn_error "missing argument to $ac_option"
1989 if test -n "$ac_unrecognized_opts"; then
1990 case $enable_option_checking in
1991 no) ;;
1992 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1993 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1994 esac
1997 # Check all directory arguments for consistency.
1998 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1999 datadir sysconfdir sharedstatedir localstatedir includedir \
2000 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2001 libdir localedir mandir
2003 eval ac_val=\$$ac_var
2004 # Remove trailing slashes.
2005 case $ac_val in
2006 */ )
2007 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2008 eval $ac_var=\$ac_val;;
2009 esac
2010 # Be sure to have absolute directory names.
2011 case $ac_val in
2012 [\\/$]* | ?:[\\/]* ) continue;;
2013 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2014 esac
2015 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2016 done
2018 # There might be people who depend on the old broken behavior: `$host'
2019 # used to hold the argument of --host etc.
2020 # FIXME: To remove some day.
2021 build=$build_alias
2022 host=$host_alias
2023 target=$target_alias
2025 # FIXME: To remove some day.
2026 if test "x$host_alias" != x; then
2027 if test "x$build_alias" = x; then
2028 cross_compiling=maybe
2029 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2030 If a cross compiler is detected then cross compile mode will be used." >&2
2031 elif test "x$build_alias" != "x$host_alias"; then
2032 cross_compiling=yes
2036 ac_tool_prefix=
2037 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2039 test "$silent" = yes && exec 6>/dev/null
2042 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2043 ac_ls_di=`ls -di .` &&
2044 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2045 as_fn_error "working directory cannot be determined"
2046 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2047 as_fn_error "pwd does not report name of working directory"
2050 # Find the source files, if location was not specified.
2051 if test -z "$srcdir"; then
2052 ac_srcdir_defaulted=yes
2053 # Try the directory containing this script, then the parent directory.
2054 ac_confdir=`$as_dirname -- "$as_myself" ||
2055 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2056 X"$as_myself" : 'X\(//\)[^/]' \| \
2057 X"$as_myself" : 'X\(//\)$' \| \
2058 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2059 $as_echo X"$as_myself" |
2060 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2061 s//\1/
2064 /^X\(\/\/\)[^/].*/{
2065 s//\1/
2068 /^X\(\/\/\)$/{
2069 s//\1/
2072 /^X\(\/\).*/{
2073 s//\1/
2076 s/.*/./; q'`
2077 srcdir=$ac_confdir
2078 if test ! -r "$srcdir/$ac_unique_file"; then
2079 srcdir=..
2081 else
2082 ac_srcdir_defaulted=no
2084 if test ! -r "$srcdir/$ac_unique_file"; then
2085 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2086 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2088 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2089 ac_abs_confdir=`(
2090 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2091 pwd)`
2092 # When building in place, set srcdir=.
2093 if test "$ac_abs_confdir" = "$ac_pwd"; then
2094 srcdir=.
2096 # Remove unnecessary trailing slashes from srcdir.
2097 # Double slashes in file names in object file debugging info
2098 # mess up M-x gdb in Emacs.
2099 case $srcdir in
2100 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2101 esac
2102 for ac_var in $ac_precious_vars; do
2103 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2104 eval ac_env_${ac_var}_value=\$${ac_var}
2105 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2106 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2107 done
2110 # Report the --help message.
2112 if test "$ac_init_help" = "long"; then
2113 # Omit some internal or obsolete options to make the list less imposing.
2114 # This message is too long to be a string in the A/UX 3.1 sh.
2115 cat <<_ACEOF
2116 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
2118 Usage: $0 [OPTION]... [VAR=VALUE]...
2120 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2121 VAR=VALUE. See below for descriptions of some of the useful variables.
2123 Defaults for the options are specified in brackets.
2125 Configuration:
2126 -h, --help display this help and exit
2127 --help=short display options specific to this package
2128 --help=recursive display the short help of all the included packages
2129 -V, --version display version information and exit
2130 -q, --quiet, --silent do not print \`checking...' messages
2131 --cache-file=FILE cache test results in FILE [disabled]
2132 -C, --config-cache alias for \`--cache-file=config.cache'
2133 -n, --no-create do not create output files
2134 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2136 Installation directories:
2137 --prefix=PREFIX install architecture-independent files in PREFIX
2138 [$ac_default_prefix]
2139 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2140 [PREFIX]
2142 By default, \`make install' will install all the files in
2143 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2144 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2145 for instance \`--prefix=\$HOME'.
2147 For better control, use the options below.
2149 Fine tuning of the installation directories:
2150 --bindir=DIR user executables [EPREFIX/bin]
2151 --sbindir=DIR system admin executables [EPREFIX/sbin]
2152 --libexecdir=DIR program executables [EPREFIX/libexec]
2153 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2154 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2155 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2156 --libdir=DIR object code libraries [EPREFIX/lib]
2157 --includedir=DIR C header files [PREFIX/include]
2158 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2159 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2160 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2161 --infodir=DIR info documentation [DATAROOTDIR/info]
2162 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2163 --mandir=DIR man documentation [DATAROOTDIR/man]
2164 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2165 --htmldir=DIR html documentation [DOCDIR]
2166 --dvidir=DIR dvi documentation [DOCDIR]
2167 --pdfdir=DIR pdf documentation [DOCDIR]
2168 --psdir=DIR ps documentation [DOCDIR]
2169 _ACEOF
2171 cat <<\_ACEOF
2173 Program names:
2174 --program-prefix=PREFIX prepend PREFIX to installed program names
2175 --program-suffix=SUFFIX append SUFFIX to installed program names
2176 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2178 X features:
2179 --x-includes=DIR X include files are in DIR
2180 --x-libraries=DIR X library files are in DIR
2182 System types:
2183 --build=BUILD configure for building on BUILD [guessed]
2184 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2185 _ACEOF
2188 if test -n "$ac_init_help"; then
2189 case $ac_init_help in
2190 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2191 esac
2192 cat <<\_ACEOF
2194 Optional Features:
2195 --disable-option-checking ignore unrecognized --enable/--with options
2196 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2197 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2198 --disable-ns-self-contained
2199 disable self contained build under NeXTstep
2200 --enable-locallisppath=PATH
2201 directories Emacs should search for lisp files
2202 specific to this site
2203 --enable-checking[=LIST]
2204 enable expensive run-time checks. With LIST, enable
2205 only specific categories of checks. Categories are:
2206 all,yes,no. Flags are: stringbytes, stringoverrun,
2207 stringfreelist, xmallocoverrun, conslist, glyphs
2208 --enable-check-lisp-object-type
2209 enable compile time checks for the Lisp_Object data
2210 type. This is useful for development for catching
2211 certain types of bugs.
2212 --enable-profiling build emacs with low-level, gprof profiling support.
2213 Mainly useful for debugging Emacs itself. May not
2214 work on all platforms. Stops profiler.el working.
2215 --enable-autodepend automatically generate dependencies to .h-files.
2216 Requires GNU Make and Gcc. Enabled if GNU Make and
2217 Gcc is found
2218 --enable-gtk-deprecation-warnings
2219 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2220 --disable-dependency-tracking speeds up one-time build
2221 --enable-dependency-tracking do not reject slow dependency extractors
2222 --disable-largefile omit support for large files
2223 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2224 intended for developers, and may generate false
2225 alarms when used with older or non-GNU development
2226 tools.
2227 --enable-link-time-optimization
2228 build emacs with link-time optimization. This is
2229 supported only for GCC since 4.5.0.
2230 --disable-acl do not support ACLs
2232 Optional Packages:
2233 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2234 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2235 --without-all omit almost all features and build small executable
2236 with minimal dependencies
2237 --without-pop don't support POP mail retrieval with movemail
2238 --with-kerberos support Kerberos-authenticated POP
2239 --with-kerberos5 support Kerberos version 5 authenticated POP
2240 --with-hesiod support Hesiod to get the POP server host
2241 --with-mmdf support MMDF mailboxes
2242 --with-mail-unlink unlink, rather than empty, mail spool after reading
2243 --with-mailhost=HOSTNAME
2244 string giving default POP mail host
2245 --with-sound=VALUE compile with sound support (VALUE one of: yes, alsa,
2246 oss, bsd-ossaudio, no; default yes). Only for
2247 GNU/Linux, FreeBSD, NetBSD, MinGW.
2248 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2249 gtk3, lucid or athena, motif, no)
2250 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2251 --without-xpm don't compile with XPM image support
2252 --without-jpeg don't compile with JPEG image support
2253 --without-tiff don't compile with TIFF image support
2254 --without-gif don't compile with GIF image support
2255 --without-png don't compile with PNG image support
2256 --without-rsvg don't compile with SVG image support
2257 --without-xml2 don't compile with XML parsing support
2258 --without-imagemagick don't compile with ImageMagick image support
2259 --without-xft don't use XFT for anti aliased fonts
2260 --without-libotf don't use libotf for OpenType font support
2261 --without-m17n-flt don't use m17n-flt for text shaping
2262 --without-toolkit-scroll-bars
2263 don't use Motif or Xaw3d scroll bars
2264 --without-xaw3d don't use Xaw3d
2265 --without-xim don't use X11 XIM
2266 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2267 --with-w32 use native MS Windows GUI in a Cygwin build
2268 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2269 console
2270 --without-dbus don't compile with D-Bus support
2271 --without-gconf don't compile with GConf support
2272 --without-gsettings don't compile with GSettings support
2273 --without-selinux don't compile with SELinux support
2274 --without-gnutls don't use -lgnutls for SSL/TLS support
2275 --without-zlib don't compile with zlib decompression support
2276 --with-file-notification=LIB
2277 use a file notification library (LIB one of: yes,
2278 gfile, inotify, w32, no)
2279 --without-makeinfo don't require makeinfo for building manuals
2280 --without-compress-install
2281 don't compress some files (.el, .info, etc.) when
2282 installing. Equivalent to: make GZIP_PROG= install
2283 --with-pkg-config-prog=FILENAME
2284 file name of pkg-config for finding GTK and librsvg
2285 --with-gameuser=USER user for shared game score files
2286 --with-gnustep-conf=FILENAME
2287 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2288 or /etc/GNUstep/GNUstep.conf
2289 --with-x use the X Window System
2291 Some influential environment variables:
2292 CC C compiler command
2293 CFLAGS C compiler flags
2294 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2295 nonstandard directory <lib dir>
2296 LIBS libraries to pass to the linker, e.g. -l<library>
2297 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2298 you have headers in a nonstandard directory <include dir>
2299 CPP C preprocessor
2300 XMKMF Path to xmkmf, Makefile generator for X Window System
2302 Use these variables to override the choices made by `configure' or to help
2303 it to find libraries and programs with nonstandard names/locations.
2305 Report bugs to the package provider.
2306 _ACEOF
2307 ac_status=$?
2310 if test "$ac_init_help" = "recursive"; then
2311 # If there are subdirs, report their specific --help.
2312 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2313 test -d "$ac_dir" ||
2314 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2315 continue
2316 ac_builddir=.
2318 case "$ac_dir" in
2319 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2321 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2322 # A ".." for each directory in $ac_dir_suffix.
2323 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2324 case $ac_top_builddir_sub in
2325 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2326 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2327 esac ;;
2328 esac
2329 ac_abs_top_builddir=$ac_pwd
2330 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2331 # for backward compatibility:
2332 ac_top_builddir=$ac_top_build_prefix
2334 case $srcdir in
2335 .) # We are building in place.
2336 ac_srcdir=.
2337 ac_top_srcdir=$ac_top_builddir_sub
2338 ac_abs_top_srcdir=$ac_pwd ;;
2339 [\\/]* | ?:[\\/]* ) # Absolute name.
2340 ac_srcdir=$srcdir$ac_dir_suffix;
2341 ac_top_srcdir=$srcdir
2342 ac_abs_top_srcdir=$srcdir ;;
2343 *) # Relative name.
2344 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2345 ac_top_srcdir=$ac_top_build_prefix$srcdir
2346 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2347 esac
2348 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2350 cd "$ac_dir" || { ac_status=$?; continue; }
2351 # Check for guested configure.
2352 if test -f "$ac_srcdir/configure.gnu"; then
2353 echo &&
2354 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2355 elif test -f "$ac_srcdir/configure"; then
2356 echo &&
2357 $SHELL "$ac_srcdir/configure" --help=recursive
2358 else
2359 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2360 fi || ac_status=$?
2361 cd "$ac_pwd" || { ac_status=$?; break; }
2362 done
2365 test -n "$ac_init_help" && exit $ac_status
2366 if $ac_init_version; then
2367 cat <<\_ACEOF
2368 emacs configure 24.3.50
2369 generated by GNU Autoconf 2.65
2371 Copyright (C) 2009 Free Software Foundation, Inc.
2372 This configure script is free software; the Free Software Foundation
2373 gives unlimited permission to copy, distribute and modify it.
2374 _ACEOF
2375 exit
2378 ## ------------------------ ##
2379 ## Autoconf initialization. ##
2380 ## ------------------------ ##
2382 # ac_fn_c_try_compile LINENO
2383 # --------------------------
2384 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2385 ac_fn_c_try_compile ()
2387 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2388 rm -f conftest.$ac_objext
2389 if { { ac_try="$ac_compile"
2390 case "(($ac_try" in
2391 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2392 *) ac_try_echo=$ac_try;;
2393 esac
2394 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2395 $as_echo "$ac_try_echo"; } >&5
2396 (eval "$ac_compile") 2>conftest.err
2397 ac_status=$?
2398 if test -s conftest.err; then
2399 grep -v '^ *+' conftest.err >conftest.er1
2400 cat conftest.er1 >&5
2401 mv -f conftest.er1 conftest.err
2403 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2404 test $ac_status = 0; } && {
2405 test -z "$ac_c_werror_flag" ||
2406 test ! -s conftest.err
2407 } && test -s conftest.$ac_objext; then :
2408 ac_retval=0
2409 else
2410 $as_echo "$as_me: failed program was:" >&5
2411 sed 's/^/| /' conftest.$ac_ext >&5
2413 ac_retval=1
2415 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2416 as_fn_set_status $ac_retval
2418 } # ac_fn_c_try_compile
2420 # ac_fn_c_try_cpp LINENO
2421 # ----------------------
2422 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2423 ac_fn_c_try_cpp ()
2425 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2426 if { { ac_try="$ac_cpp conftest.$ac_ext"
2427 case "(($ac_try" in
2428 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2429 *) ac_try_echo=$ac_try;;
2430 esac
2431 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2432 $as_echo "$ac_try_echo"; } >&5
2433 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2434 ac_status=$?
2435 if test -s conftest.err; then
2436 grep -v '^ *+' conftest.err >conftest.er1
2437 cat conftest.er1 >&5
2438 mv -f conftest.er1 conftest.err
2440 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2441 test $ac_status = 0; } >/dev/null && {
2442 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2443 test ! -s conftest.err
2444 }; then :
2445 ac_retval=0
2446 else
2447 $as_echo "$as_me: failed program was:" >&5
2448 sed 's/^/| /' conftest.$ac_ext >&5
2450 ac_retval=1
2452 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2453 as_fn_set_status $ac_retval
2455 } # ac_fn_c_try_cpp
2457 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2458 # -------------------------------------------------------
2459 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2460 # the include files in INCLUDES and setting the cache variable VAR
2461 # accordingly.
2462 ac_fn_c_check_header_mongrel ()
2464 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2465 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2467 $as_echo_n "checking for $2... " >&6; }
2468 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2469 $as_echo_n "(cached) " >&6
2471 eval ac_res=\$$3
2472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2473 $as_echo "$ac_res" >&6; }
2474 else
2475 # Is the header compilable?
2476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2477 $as_echo_n "checking $2 usability... " >&6; }
2478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2479 /* end confdefs.h. */
2481 #include <$2>
2482 _ACEOF
2483 if ac_fn_c_try_compile "$LINENO"; then :
2484 ac_header_compiler=yes
2485 else
2486 ac_header_compiler=no
2488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2490 $as_echo "$ac_header_compiler" >&6; }
2492 # Is the header present?
2493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2494 $as_echo_n "checking $2 presence... " >&6; }
2495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2496 /* end confdefs.h. */
2497 #include <$2>
2498 _ACEOF
2499 if ac_fn_c_try_cpp "$LINENO"; then :
2500 ac_header_preproc=yes
2501 else
2502 ac_header_preproc=no
2504 rm -f conftest.err conftest.$ac_ext
2505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2506 $as_echo "$ac_header_preproc" >&6; }
2508 # So? What about this header?
2509 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2510 yes:no: )
2511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2512 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&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 no:yes:* )
2517 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2518 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2520 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2522 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2523 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2524 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2526 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2528 esac
2529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2530 $as_echo_n "checking for $2... " >&6; }
2531 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2532 $as_echo_n "(cached) " >&6
2533 else
2534 eval "$3=\$ac_header_compiler"
2536 eval ac_res=\$$3
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2538 $as_echo "$ac_res" >&6; }
2540 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2542 } # ac_fn_c_check_header_mongrel
2544 # ac_fn_c_try_run LINENO
2545 # ----------------------
2546 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2547 # that executables *can* be run.
2548 ac_fn_c_try_run ()
2550 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2551 if { { ac_try="$ac_link"
2552 case "(($ac_try" in
2553 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2554 *) ac_try_echo=$ac_try;;
2555 esac
2556 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2557 $as_echo "$ac_try_echo"; } >&5
2558 (eval "$ac_link") 2>&5
2559 ac_status=$?
2560 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2561 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2562 { { case "(($ac_try" in
2563 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2564 *) ac_try_echo=$ac_try;;
2565 esac
2566 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2567 $as_echo "$ac_try_echo"; } >&5
2568 (eval "$ac_try") 2>&5
2569 ac_status=$?
2570 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2571 test $ac_status = 0; }; }; then :
2572 ac_retval=0
2573 else
2574 $as_echo "$as_me: program exited with status $ac_status" >&5
2575 $as_echo "$as_me: failed program was:" >&5
2576 sed 's/^/| /' conftest.$ac_ext >&5
2578 ac_retval=$ac_status
2580 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2581 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2582 as_fn_set_status $ac_retval
2584 } # ac_fn_c_try_run
2586 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2587 # -------------------------------------------------------
2588 # Tests whether HEADER exists and can be compiled using the include files in
2589 # INCLUDES, setting the cache variable VAR accordingly.
2590 ac_fn_c_check_header_compile ()
2592 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2594 $as_echo_n "checking for $2... " >&6; }
2595 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2596 $as_echo_n "(cached) " >&6
2597 else
2598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2599 /* end confdefs.h. */
2601 #include <$2>
2602 _ACEOF
2603 if ac_fn_c_try_compile "$LINENO"; then :
2604 eval "$3=yes"
2605 else
2606 eval "$3=no"
2608 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2610 eval ac_res=\$$3
2611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2612 $as_echo "$ac_res" >&6; }
2613 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2615 } # ac_fn_c_check_header_compile
2617 # ac_fn_c_try_link LINENO
2618 # -----------------------
2619 # Try to link conftest.$ac_ext, and return whether this succeeded.
2620 ac_fn_c_try_link ()
2622 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2623 rm -f conftest.$ac_objext conftest$ac_exeext
2624 if { { ac_try="$ac_link"
2625 case "(($ac_try" in
2626 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2627 *) ac_try_echo=$ac_try;;
2628 esac
2629 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2630 $as_echo "$ac_try_echo"; } >&5
2631 (eval "$ac_link") 2>conftest.err
2632 ac_status=$?
2633 if test -s conftest.err; then
2634 grep -v '^ *+' conftest.err >conftest.er1
2635 cat conftest.er1 >&5
2636 mv -f conftest.er1 conftest.err
2638 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2639 test $ac_status = 0; } && {
2640 test -z "$ac_c_werror_flag" ||
2641 test ! -s conftest.err
2642 } && test -s conftest$ac_exeext && {
2643 test "$cross_compiling" = yes ||
2644 $as_test_x conftest$ac_exeext
2645 }; then :
2646 ac_retval=0
2647 else
2648 $as_echo "$as_me: failed program was:" >&5
2649 sed 's/^/| /' conftest.$ac_ext >&5
2651 ac_retval=1
2653 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2654 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2655 # interfere with the next link command; also delete a directory that is
2656 # left behind by Apple's compiler. We do this before executing the actions.
2657 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2658 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2659 as_fn_set_status $ac_retval
2661 } # ac_fn_c_try_link
2663 # ac_fn_c_check_decl LINENO SYMBOL VAR
2664 # ------------------------------------
2665 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2666 ac_fn_c_check_decl ()
2668 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2670 $as_echo_n "checking whether $2 is declared... " >&6; }
2671 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2672 $as_echo_n "(cached) " >&6
2673 else
2674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2675 /* end confdefs.h. */
2678 main ()
2680 #ifndef $2
2681 (void) $2;
2682 #endif
2685 return 0;
2687 _ACEOF
2688 if ac_fn_c_try_compile "$LINENO"; then :
2689 eval "$3=yes"
2690 else
2691 eval "$3=no"
2693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2695 eval ac_res=\$$3
2696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2697 $as_echo "$ac_res" >&6; }
2698 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2700 } # ac_fn_c_check_decl
2702 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2703 # ----------------------------------------------
2704 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2705 ac_fn_c_check_header_preproc ()
2707 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2709 $as_echo_n "checking for $2... " >&6; }
2710 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2711 $as_echo_n "(cached) " >&6
2712 else
2713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2714 /* end confdefs.h. */
2715 #include <$2>
2716 _ACEOF
2717 if ac_fn_c_try_cpp "$LINENO"; then :
2718 eval "$3=yes"
2719 else
2720 eval "$3=no"
2722 rm -f conftest.err conftest.$ac_ext
2724 eval ac_res=\$$3
2725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2726 $as_echo "$ac_res" >&6; }
2727 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2729 } # ac_fn_c_check_header_preproc
2731 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2732 # ----------------------------------------------------
2733 # Tries to find if the field MEMBER exists in type AGGR, after including
2734 # INCLUDES, setting cache variable VAR accordingly.
2735 ac_fn_c_check_member ()
2737 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2739 $as_echo_n "checking for $2.$3... " >&6; }
2740 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2741 $as_echo_n "(cached) " >&6
2742 else
2743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2744 /* end confdefs.h. */
2747 main ()
2749 static $2 ac_aggr;
2750 if (ac_aggr.$3)
2751 return 0;
2753 return 0;
2755 _ACEOF
2756 if ac_fn_c_try_compile "$LINENO"; then :
2757 eval "$4=yes"
2758 else
2759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2760 /* end confdefs.h. */
2763 main ()
2765 static $2 ac_aggr;
2766 if (sizeof ac_aggr.$3)
2767 return 0;
2769 return 0;
2771 _ACEOF
2772 if ac_fn_c_try_compile "$LINENO"; then :
2773 eval "$4=yes"
2774 else
2775 eval "$4=no"
2777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2779 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2781 eval ac_res=\$$4
2782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2783 $as_echo "$ac_res" >&6; }
2784 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2786 } # ac_fn_c_check_member
2788 # ac_fn_c_check_func LINENO FUNC VAR
2789 # ----------------------------------
2790 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2791 ac_fn_c_check_func ()
2793 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2795 $as_echo_n "checking for $2... " >&6; }
2796 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2797 $as_echo_n "(cached) " >&6
2798 else
2799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2800 /* end confdefs.h. */
2801 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2802 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2803 #define $2 innocuous_$2
2805 /* System header to define __stub macros and hopefully few prototypes,
2806 which can conflict with char $2 (); below.
2807 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2808 <limits.h> exists even on freestanding compilers. */
2810 #ifdef __STDC__
2811 # include <limits.h>
2812 #else
2813 # include <assert.h>
2814 #endif
2816 #undef $2
2818 /* Override any GCC internal prototype to avoid an error.
2819 Use char because int might match the return type of a GCC
2820 builtin and then its argument prototype would still apply. */
2821 #ifdef __cplusplus
2822 extern "C"
2823 #endif
2824 char $2 ();
2825 /* The GNU C library defines this for functions which it implements
2826 to always fail with ENOSYS. Some functions are actually named
2827 something starting with __ and the normal name is an alias. */
2828 #if defined __stub_$2 || defined __stub___$2
2829 choke me
2830 #endif
2833 main ()
2835 return $2 ();
2837 return 0;
2839 _ACEOF
2840 if ac_fn_c_try_link "$LINENO"; then :
2841 eval "$3=yes"
2842 else
2843 eval "$3=no"
2845 rm -f core conftest.err conftest.$ac_objext \
2846 conftest$ac_exeext conftest.$ac_ext
2848 eval ac_res=\$$3
2849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2850 $as_echo "$ac_res" >&6; }
2851 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2853 } # ac_fn_c_check_func
2855 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2856 # -------------------------------------------
2857 # Tests whether TYPE exists after having included INCLUDES, setting cache
2858 # variable VAR accordingly.
2859 ac_fn_c_check_type ()
2861 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2863 $as_echo_n "checking for $2... " >&6; }
2864 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2865 $as_echo_n "(cached) " >&6
2866 else
2867 eval "$3=no"
2868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2869 /* end confdefs.h. */
2872 main ()
2874 if (sizeof ($2))
2875 return 0;
2877 return 0;
2879 _ACEOF
2880 if ac_fn_c_try_compile "$LINENO"; then :
2881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2882 /* end confdefs.h. */
2885 main ()
2887 if (sizeof (($2)))
2888 return 0;
2890 return 0;
2892 _ACEOF
2893 if ac_fn_c_try_compile "$LINENO"; then :
2895 else
2896 eval "$3=yes"
2898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2902 eval ac_res=\$$3
2903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2904 $as_echo "$ac_res" >&6; }
2905 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2907 } # ac_fn_c_check_type
2909 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2910 # --------------------------------------------
2911 # Tries to find the compile-time value of EXPR in a program that includes
2912 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2913 # computed
2914 ac_fn_c_compute_int ()
2916 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2917 if test "$cross_compiling" = yes; then
2918 # Depending upon the size, compute the lo and hi bounds.
2919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2920 /* end confdefs.h. */
2923 main ()
2925 static int test_array [1 - 2 * !(($2) >= 0)];
2926 test_array [0] = 0
2929 return 0;
2931 _ACEOF
2932 if ac_fn_c_try_compile "$LINENO"; then :
2933 ac_lo=0 ac_mid=0
2934 while :; do
2935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2936 /* end confdefs.h. */
2939 main ()
2941 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2942 test_array [0] = 0
2945 return 0;
2947 _ACEOF
2948 if ac_fn_c_try_compile "$LINENO"; then :
2949 ac_hi=$ac_mid; break
2950 else
2951 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2952 if test $ac_lo -le $ac_mid; then
2953 ac_lo= ac_hi=
2954 break
2956 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2959 done
2960 else
2961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2962 /* end confdefs.h. */
2965 main ()
2967 static int test_array [1 - 2 * !(($2) < 0)];
2968 test_array [0] = 0
2971 return 0;
2973 _ACEOF
2974 if ac_fn_c_try_compile "$LINENO"; then :
2975 ac_hi=-1 ac_mid=-1
2976 while :; do
2977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2978 /* end confdefs.h. */
2981 main ()
2983 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2984 test_array [0] = 0
2987 return 0;
2989 _ACEOF
2990 if ac_fn_c_try_compile "$LINENO"; then :
2991 ac_lo=$ac_mid; break
2992 else
2993 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2994 if test $ac_mid -le $ac_hi; then
2995 ac_lo= ac_hi=
2996 break
2998 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
3000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3001 done
3002 else
3003 ac_lo= ac_hi=
3005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3008 # Binary search between lo and hi bounds.
3009 while test "x$ac_lo" != "x$ac_hi"; do
3010 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
3011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3012 /* end confdefs.h. */
3015 main ()
3017 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3018 test_array [0] = 0
3021 return 0;
3023 _ACEOF
3024 if ac_fn_c_try_compile "$LINENO"; then :
3025 ac_hi=$ac_mid
3026 else
3027 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3030 done
3031 case $ac_lo in #((
3032 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3033 '') ac_retval=1 ;;
3034 esac
3035 else
3036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3037 /* end confdefs.h. */
3039 static long int longval () { return $2; }
3040 static unsigned long int ulongval () { return $2; }
3041 #include <stdio.h>
3042 #include <stdlib.h>
3044 main ()
3047 FILE *f = fopen ("conftest.val", "w");
3048 if (! f)
3049 return 1;
3050 if (($2) < 0)
3052 long int i = longval ();
3053 if (i != ($2))
3054 return 1;
3055 fprintf (f, "%ld", i);
3057 else
3059 unsigned long int i = ulongval ();
3060 if (i != ($2))
3061 return 1;
3062 fprintf (f, "%lu", i);
3064 /* Do not output a trailing newline, as this causes \r\n confusion
3065 on some platforms. */
3066 return ferror (f) || fclose (f) != 0;
3069 return 0;
3071 _ACEOF
3072 if ac_fn_c_try_run "$LINENO"; then :
3073 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3074 else
3075 ac_retval=1
3077 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3078 conftest.$ac_objext conftest.beam conftest.$ac_ext
3079 rm -f conftest.val
3082 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3083 as_fn_set_status $ac_retval
3085 } # ac_fn_c_compute_int
3086 cat >config.log <<_ACEOF
3087 This file contains any messages produced by compilers while
3088 running configure, to aid debugging if configure makes a mistake.
3090 It was created by emacs $as_me 24.3.50, which was
3091 generated by GNU Autoconf 2.65. Invocation command line was
3093 $ $0 $@
3095 _ACEOF
3096 exec 5>>config.log
3098 cat <<_ASUNAME
3099 ## --------- ##
3100 ## Platform. ##
3101 ## --------- ##
3103 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3104 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3105 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3106 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3107 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3109 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3110 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3112 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3113 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3114 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3115 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3116 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3117 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3118 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3120 _ASUNAME
3122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3123 for as_dir in $PATH
3125 IFS=$as_save_IFS
3126 test -z "$as_dir" && as_dir=.
3127 $as_echo "PATH: $as_dir"
3128 done
3129 IFS=$as_save_IFS
3131 } >&5
3133 cat >&5 <<_ACEOF
3136 ## ----------- ##
3137 ## Core tests. ##
3138 ## ----------- ##
3140 _ACEOF
3143 # Keep a trace of the command line.
3144 # Strip out --no-create and --no-recursion so they do not pile up.
3145 # Strip out --silent because we don't want to record it for future runs.
3146 # Also quote any args containing shell meta-characters.
3147 # Make two passes to allow for proper duplicate-argument suppression.
3148 ac_configure_args=
3149 ac_configure_args0=
3150 ac_configure_args1=
3151 ac_must_keep_next=false
3152 for ac_pass in 1 2
3154 for ac_arg
3156 case $ac_arg in
3157 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3158 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3159 | -silent | --silent | --silen | --sile | --sil)
3160 continue ;;
3161 *\'*)
3162 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3163 esac
3164 case $ac_pass in
3165 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3167 as_fn_append ac_configure_args1 " '$ac_arg'"
3168 if test $ac_must_keep_next = true; then
3169 ac_must_keep_next=false # Got value, back to normal.
3170 else
3171 case $ac_arg in
3172 *=* | --config-cache | -C | -disable-* | --disable-* \
3173 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3174 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3175 | -with-* | --with-* | -without-* | --without-* | --x)
3176 case "$ac_configure_args0 " in
3177 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3178 esac
3180 -* ) ac_must_keep_next=true ;;
3181 esac
3183 as_fn_append ac_configure_args " '$ac_arg'"
3185 esac
3186 done
3187 done
3188 { ac_configure_args0=; unset ac_configure_args0;}
3189 { ac_configure_args1=; unset ac_configure_args1;}
3191 # When interrupted or exit'd, cleanup temporary files, and complete
3192 # config.log. We remove comments because anyway the quotes in there
3193 # would cause problems or look ugly.
3194 # WARNING: Use '\'' to represent an apostrophe within the trap.
3195 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3196 trap 'exit_status=$?
3197 # Save into config.log some information that might help in debugging.
3199 echo
3201 cat <<\_ASBOX
3202 ## ---------------- ##
3203 ## Cache variables. ##
3204 ## ---------------- ##
3205 _ASBOX
3206 echo
3207 # The following way of writing the cache mishandles newlines in values,
3209 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3210 eval ac_val=\$$ac_var
3211 case $ac_val in #(
3212 *${as_nl}*)
3213 case $ac_var in #(
3214 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3215 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3216 esac
3217 case $ac_var in #(
3218 _ | IFS | as_nl) ;; #(
3219 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3220 *) { eval $ac_var=; unset $ac_var;} ;;
3221 esac ;;
3222 esac
3223 done
3224 (set) 2>&1 |
3225 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3226 *${as_nl}ac_space=\ *)
3227 sed -n \
3228 "s/'\''/'\''\\\\'\'''\''/g;
3229 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3230 ;; #(
3232 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3234 esac |
3235 sort
3237 echo
3239 cat <<\_ASBOX
3240 ## ----------------- ##
3241 ## Output variables. ##
3242 ## ----------------- ##
3243 _ASBOX
3244 echo
3245 for ac_var in $ac_subst_vars
3247 eval ac_val=\$$ac_var
3248 case $ac_val in
3249 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3250 esac
3251 $as_echo "$ac_var='\''$ac_val'\''"
3252 done | sort
3253 echo
3255 if test -n "$ac_subst_files"; then
3256 cat <<\_ASBOX
3257 ## ------------------- ##
3258 ## File substitutions. ##
3259 ## ------------------- ##
3260 _ASBOX
3261 echo
3262 for ac_var in $ac_subst_files
3264 eval ac_val=\$$ac_var
3265 case $ac_val in
3266 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3267 esac
3268 $as_echo "$ac_var='\''$ac_val'\''"
3269 done | sort
3270 echo
3273 if test -s confdefs.h; then
3274 cat <<\_ASBOX
3275 ## ----------- ##
3276 ## confdefs.h. ##
3277 ## ----------- ##
3278 _ASBOX
3279 echo
3280 cat confdefs.h
3281 echo
3283 test "$ac_signal" != 0 &&
3284 $as_echo "$as_me: caught signal $ac_signal"
3285 $as_echo "$as_me: exit $exit_status"
3286 } >&5
3287 rm -f core *.core core.conftest.* &&
3288 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3289 exit $exit_status
3291 for ac_signal in 1 2 13 15; do
3292 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3293 done
3294 ac_signal=0
3296 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3297 rm -f -r conftest* confdefs.h
3299 $as_echo "/* confdefs.h */" > confdefs.h
3301 # Predefined preprocessor variables.
3303 cat >>confdefs.h <<_ACEOF
3304 #define PACKAGE_NAME "$PACKAGE_NAME"
3305 _ACEOF
3307 cat >>confdefs.h <<_ACEOF
3308 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3309 _ACEOF
3311 cat >>confdefs.h <<_ACEOF
3312 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3313 _ACEOF
3315 cat >>confdefs.h <<_ACEOF
3316 #define PACKAGE_STRING "$PACKAGE_STRING"
3317 _ACEOF
3319 cat >>confdefs.h <<_ACEOF
3320 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3321 _ACEOF
3323 cat >>confdefs.h <<_ACEOF
3324 #define PACKAGE_URL "$PACKAGE_URL"
3325 _ACEOF
3328 # Let the site file select an alternate cache file if it wants to.
3329 # Prefer an explicitly selected file to automatically selected ones.
3330 ac_site_file1=NONE
3331 ac_site_file2=NONE
3332 if test -n "$CONFIG_SITE"; then
3333 ac_site_file1=$CONFIG_SITE
3334 elif test "x$prefix" != xNONE; then
3335 ac_site_file1=$prefix/share/config.site
3336 ac_site_file2=$prefix/etc/config.site
3337 else
3338 ac_site_file1=$ac_default_prefix/share/config.site
3339 ac_site_file2=$ac_default_prefix/etc/config.site
3341 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3343 test "x$ac_site_file" = xNONE && continue
3344 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3346 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3347 sed 's/^/| /' "$ac_site_file" >&5
3348 . "$ac_site_file"
3350 done
3352 if test -r "$cache_file"; then
3353 # Some versions of bash will fail to source /dev/null (special files
3354 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3355 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3356 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3357 $as_echo "$as_me: loading cache $cache_file" >&6;}
3358 case $cache_file in
3359 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3360 *) . "./$cache_file";;
3361 esac
3363 else
3364 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3365 $as_echo "$as_me: creating cache $cache_file" >&6;}
3366 >$cache_file
3369 as_fn_append ac_header_list " sys/systeminfo.h"
3370 as_fn_append ac_header_list " coff.h"
3371 as_fn_append ac_header_list " pty.h"
3372 as_fn_append ac_header_list " sys/resource.h"
3373 as_fn_append ac_header_list " sys/utsname.h"
3374 as_fn_append ac_header_list " pwd.h"
3375 as_fn_append ac_header_list " utmp.h"
3376 as_fn_append ac_header_list " util.h"
3377 as_fn_append ac_header_list " sys/socket.h"
3378 as_fn_append ac_header_list " stdlib.h"
3379 as_fn_append ac_header_list " unistd.h"
3380 as_fn_append ac_header_list " sys/param.h"
3381 as_fn_append ac_header_list " pthread.h"
3382 as_fn_append ac_header_list " malloc/malloc.h"
3383 as_fn_append ac_header_list " maillock.h"
3384 as_fn_append ac_header_list " sys/un.h"
3385 as_fn_append ac_func_list " tzset"
3386 as_fn_append ac_func_list " readlinkat"
3387 as_fn_append ac_header_list " dirent.h"
3388 as_fn_append ac_header_list " execinfo.h"
3389 as_fn_append ac_func_list " faccessat"
3390 as_fn_append ac_func_list " fcntl"
3391 as_fn_append ac_func_list " fdopendir"
3392 as_fn_append ac_header_list " stdio_ext.h"
3393 as_fn_append ac_func_list " fstatat"
3394 as_fn_append ac_func_list " fsync"
3395 gl_getopt_required=GNU
3396 as_fn_append ac_header_list " getopt.h"
3397 as_fn_append ac_func_list " gettimeofday"
3398 as_fn_append ac_func_list " nanotime"
3399 as_fn_append ac_header_list " sys/time.h"
3400 as_fn_append ac_header_list " wchar.h"
3401 as_fn_append ac_header_list " stdint.h"
3402 as_fn_append ac_header_list " inttypes.h"
3403 as_fn_append ac_func_list " lstat"
3404 as_fn_append ac_func_list " mkostemp"
3405 as_fn_append ac_func_list " pipe2"
3406 as_fn_append ac_header_list " sys/select.h"
3407 as_fn_append ac_func_list " pselect"
3408 as_fn_append ac_func_list " pthread_sigmask"
3409 as_fn_append ac_func_list " readlink"
3410 as_fn_append ac_func_list " strtoimax"
3411 as_fn_append ac_func_list " strtoumax"
3412 as_fn_append ac_func_list " symlink"
3413 as_fn_append ac_header_list " sys/stat.h"
3414 as_fn_append ac_func_list " localtime_r"
3415 as_fn_append ac_header_list " utime.h"
3416 as_fn_append ac_func_list " futimes"
3417 as_fn_append ac_func_list " futimesat"
3418 as_fn_append ac_func_list " futimens"
3419 as_fn_append ac_func_list " utimensat"
3420 as_fn_append ac_func_list " lutimes"
3421 as_fn_append ac_func_list " getdtablesize"
3422 as_fn_append ac_func_list " secure_getenv"
3423 # Check that the precious variables saved in the cache have kept the same
3424 # value.
3425 ac_cache_corrupted=false
3426 for ac_var in $ac_precious_vars; do
3427 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3428 eval ac_new_set=\$ac_env_${ac_var}_set
3429 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3430 eval ac_new_val=\$ac_env_${ac_var}_value
3431 case $ac_old_set,$ac_new_set in
3432 set,)
3433 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3434 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3435 ac_cache_corrupted=: ;;
3436 ,set)
3437 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3438 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3439 ac_cache_corrupted=: ;;
3440 ,);;
3442 if test "x$ac_old_val" != "x$ac_new_val"; then
3443 # differences in whitespace do not lead to failure.
3444 ac_old_val_w=`echo x $ac_old_val`
3445 ac_new_val_w=`echo x $ac_new_val`
3446 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3447 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3448 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3449 ac_cache_corrupted=:
3450 else
3451 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3452 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3453 eval $ac_var=\$ac_old_val
3455 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3456 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3458 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3459 fi;;
3460 esac
3461 # Pass precious variables to config.status.
3462 if test "$ac_new_set" = set; then
3463 case $ac_new_val in
3464 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3465 *) ac_arg=$ac_var=$ac_new_val ;;
3466 esac
3467 case " $ac_configure_args " in
3468 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3469 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3470 esac
3472 done
3473 if $ac_cache_corrupted; then
3474 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3475 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3476 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3477 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3478 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3480 ## -------------------- ##
3481 ## Main body of script. ##
3482 ## -------------------- ##
3484 ac_ext=c
3485 ac_cpp='$CPP $CPPFLAGS'
3486 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3487 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3488 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3492 emacs_config_options=
3493 optsep=
3494 for opt in ${1+"$@"} CFLAGS CPPFLAGS LDFLAGS; do
3495 case $opt in
3496 -n | --no-create | --no-recursion)
3497 continue ;;
3498 CFLAGS | CPPFLAGS | LDFLAGS)
3499 eval 'test "${'$opt'+set}" = set' || continue
3500 case " $*" in
3501 *" $opt="*) continue ;;
3502 esac
3503 eval opt=$opt=\$$opt ;;
3504 esac
3506 emacs_shell_specials=$IFS\''"#$&()*;<>?[\\`{|~'
3507 case $opt in
3508 *["$emacs_shell_specials"]*)
3509 case $opt in
3510 *\'*)
3511 emacs_quote_apostrophes="s/'/'\\\\''/g"
3512 opt=`$as_echo "$opt" | sed "$emacs_quote_apostrophes"` ;;
3513 esac
3514 opt="'$opt'"
3515 case $opt in
3516 *['"\\']*)
3517 emacs_quote_for_c='s/["\\]/\\&/g; $!s/$/\\n\\/'
3518 opt=`$as_echo "$opt" | sed "$emacs_quote_for_c"` ;;
3519 esac ;;
3520 esac
3521 as_fn_append emacs_config_options "$optsep$opt"
3522 optsep=' '
3523 done
3525 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3528 ac_aux_dir=
3529 for ac_dir in build-aux "$srcdir"/build-aux; do
3530 for ac_t in install-sh install.sh shtool; do
3531 if test -f "$ac_dir/$ac_t"; then
3532 ac_aux_dir=$ac_dir
3533 ac_install_sh="$ac_aux_dir/$ac_t -c"
3534 break 2
3536 done
3537 done
3538 if test -z "$ac_aux_dir"; then
3539 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3542 # These three variables are undocumented and unsupported,
3543 # and are intended to be withdrawn in a future Autoconf release.
3544 # They can cause serious problems if a builder's source tree is in a directory
3545 # whose full name contains unusual characters.
3546 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3547 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3548 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3551 am__api_version='1.11'
3553 # Find a good install program. We prefer a C program (faster),
3554 # so one script is as good as another. But avoid the broken or
3555 # incompatible versions:
3556 # SysV /etc/install, /usr/sbin/install
3557 # SunOS /usr/etc/install
3558 # IRIX /sbin/install
3559 # AIX /bin/install
3560 # AmigaOS /C/install, which installs bootblocks on floppy discs
3561 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3562 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3563 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3564 # OS/2's system install, which has a completely different semantic
3565 # ./install, which can be erroneously created by make from ./install.sh.
3566 # Reject install programs that cannot install multiple files.
3567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3568 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3569 if test -z "$INSTALL"; then
3570 if test "${ac_cv_path_install+set}" = set; then :
3571 $as_echo_n "(cached) " >&6
3572 else
3573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3574 for as_dir in $PATH
3576 IFS=$as_save_IFS
3577 test -z "$as_dir" && as_dir=.
3578 # Account for people who put trailing slashes in PATH elements.
3579 case $as_dir/ in #((
3580 ./ | .// | /[cC]/* | \
3581 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3582 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3583 /usr/ucb/* ) ;;
3585 # OSF1 and SCO ODT 3.0 have their own names for install.
3586 # Don't use installbsd from OSF since it installs stuff as root
3587 # by default.
3588 for ac_prog in ginstall scoinst install; do
3589 for ac_exec_ext in '' $ac_executable_extensions; do
3590 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3591 if test $ac_prog = install &&
3592 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3593 # AIX install. It has an incompatible calling convention.
3595 elif test $ac_prog = install &&
3596 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3597 # program-specific install script used by HP pwplus--don't use.
3599 else
3600 rm -rf conftest.one conftest.two conftest.dir
3601 echo one > conftest.one
3602 echo two > conftest.two
3603 mkdir conftest.dir
3604 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3605 test -s conftest.one && test -s conftest.two &&
3606 test -s conftest.dir/conftest.one &&
3607 test -s conftest.dir/conftest.two
3608 then
3609 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3610 break 3
3614 done
3615 done
3617 esac
3619 done
3620 IFS=$as_save_IFS
3622 rm -rf conftest.one conftest.two conftest.dir
3625 if test "${ac_cv_path_install+set}" = set; then
3626 INSTALL=$ac_cv_path_install
3627 else
3628 # As a last resort, use the slow shell script. Don't cache a
3629 # value for INSTALL within a source directory, because that will
3630 # break other packages using the cache if that directory is
3631 # removed, or if the value is a relative name.
3632 INSTALL=$ac_install_sh
3635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3636 $as_echo "$INSTALL" >&6; }
3638 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3639 # It thinks the first close brace ends the variable substitution.
3640 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3642 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3644 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3647 $as_echo_n "checking whether build environment is sane... " >&6; }
3648 # Just in case
3649 sleep 1
3650 echo timestamp > conftest.file
3651 # Reject unsafe characters in $srcdir or the absolute working directory
3652 # name. Accept space and tab only in the latter.
3653 am_lf='
3655 case `pwd` in
3656 *[\\\"\#\$\&\'\`$am_lf]*)
3657 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3658 esac
3659 case $srcdir in
3660 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3661 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3662 esac
3664 # Do `set' in a subshell so we don't clobber the current shell's
3665 # arguments. Must try -L first in case configure is actually a
3666 # symlink; some systems play weird games with the mod time of symlinks
3667 # (eg FreeBSD returns the mod time of the symlink's containing
3668 # directory).
3669 if (
3670 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3671 if test "$*" = "X"; then
3672 # -L didn't work.
3673 set X `ls -t "$srcdir/configure" conftest.file`
3675 rm -f conftest.file
3676 if test "$*" != "X $srcdir/configure conftest.file" \
3677 && test "$*" != "X conftest.file $srcdir/configure"; then
3679 # If neither matched, then we have a broken ls. This can happen
3680 # if, for instance, CONFIG_SHELL is bash and it inherits a
3681 # broken ls alias from the environment. This has actually
3682 # happened. Such a system could not be considered "sane".
3683 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3684 alias in your environment" "$LINENO" 5
3687 test "$2" = conftest.file
3689 then
3690 # Ok.
3692 else
3693 as_fn_error "newly created file is older than distributed files!
3694 Check your system clock" "$LINENO" 5
3696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3697 $as_echo "yes" >&6; }
3698 test "$program_prefix" != NONE &&
3699 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3700 # Use a double $ so make ignores it.
3701 test "$program_suffix" != NONE &&
3702 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3703 # Double any \ or $.
3704 # By default was `s,x,x', remove it if useless.
3705 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3706 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3708 # expand $ac_aux_dir to an absolute path
3709 am_aux_dir=`cd $ac_aux_dir && pwd`
3711 if test x"${MISSING+set}" != xset; then
3712 case $am_aux_dir in
3713 *\ * | *\ *)
3714 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3716 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3717 esac
3719 # Use eval to expand $SHELL
3720 if eval "$MISSING --run true"; then
3721 am_missing_run="$MISSING --run "
3722 else
3723 am_missing_run=
3724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3725 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3728 if test x"${install_sh}" != xset; then
3729 case $am_aux_dir in
3730 *\ * | *\ *)
3731 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3733 install_sh="\${SHELL} $am_aux_dir/install-sh"
3734 esac
3737 # Installed binaries are usually stripped using `strip' when the user
3738 # run `make install-strip'. However `strip' might not be the right
3739 # tool to use in cross-compilation environments, therefore Automake
3740 # will honor the `STRIP' environment variable to overrule this program.
3741 if test "$cross_compiling" != no; then
3742 if test -n "$ac_tool_prefix"; then
3743 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3744 set dummy ${ac_tool_prefix}strip; ac_word=$2
3745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3746 $as_echo_n "checking for $ac_word... " >&6; }
3747 if test "${ac_cv_prog_STRIP+set}" = set; then :
3748 $as_echo_n "(cached) " >&6
3749 else
3750 if test -n "$STRIP"; then
3751 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3752 else
3753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3754 for as_dir in $PATH
3756 IFS=$as_save_IFS
3757 test -z "$as_dir" && as_dir=.
3758 for ac_exec_ext in '' $ac_executable_extensions; do
3759 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3760 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3762 break 2
3764 done
3765 done
3766 IFS=$as_save_IFS
3770 STRIP=$ac_cv_prog_STRIP
3771 if test -n "$STRIP"; then
3772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3773 $as_echo "$STRIP" >&6; }
3774 else
3775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3776 $as_echo "no" >&6; }
3781 if test -z "$ac_cv_prog_STRIP"; then
3782 ac_ct_STRIP=$STRIP
3783 # Extract the first word of "strip", so it can be a program name with args.
3784 set dummy strip; ac_word=$2
3785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3786 $as_echo_n "checking for $ac_word... " >&6; }
3787 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3788 $as_echo_n "(cached) " >&6
3789 else
3790 if test -n "$ac_ct_STRIP"; then
3791 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3792 else
3793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3794 for as_dir in $PATH
3796 IFS=$as_save_IFS
3797 test -z "$as_dir" && as_dir=.
3798 for ac_exec_ext in '' $ac_executable_extensions; do
3799 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3800 ac_cv_prog_ac_ct_STRIP="strip"
3801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3802 break 2
3804 done
3805 done
3806 IFS=$as_save_IFS
3810 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3811 if test -n "$ac_ct_STRIP"; then
3812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3813 $as_echo "$ac_ct_STRIP" >&6; }
3814 else
3815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3816 $as_echo "no" >&6; }
3819 if test "x$ac_ct_STRIP" = x; then
3820 STRIP=":"
3821 else
3822 case $cross_compiling:$ac_tool_warned in
3823 yes:)
3824 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3825 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3826 ac_tool_warned=yes ;;
3827 esac
3828 STRIP=$ac_ct_STRIP
3830 else
3831 STRIP="$ac_cv_prog_STRIP"
3835 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3838 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3839 if test -z "$MKDIR_P"; then
3840 if test "${ac_cv_path_mkdir+set}" = set; then :
3841 $as_echo_n "(cached) " >&6
3842 else
3843 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3844 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3846 IFS=$as_save_IFS
3847 test -z "$as_dir" && as_dir=.
3848 for ac_prog in mkdir gmkdir; do
3849 for ac_exec_ext in '' $ac_executable_extensions; do
3850 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3851 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3852 'mkdir (GNU coreutils) '* | \
3853 'mkdir (coreutils) '* | \
3854 'mkdir (fileutils) '4.1*)
3855 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3856 break 3;;
3857 esac
3858 done
3859 done
3860 done
3861 IFS=$as_save_IFS
3865 test -d ./--version && rmdir ./--version
3866 if test "${ac_cv_path_mkdir+set}" = set; then
3867 MKDIR_P="$ac_cv_path_mkdir -p"
3868 else
3869 # As a last resort, use the slow shell script. Don't cache a
3870 # value for MKDIR_P within a source directory, because that will
3871 # break other packages using the cache if that directory is
3872 # removed, or if the value is a relative name.
3873 MKDIR_P="$ac_install_sh -d"
3876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3877 $as_echo "$MKDIR_P" >&6; }
3879 mkdir_p="$MKDIR_P"
3880 case $mkdir_p in
3881 [\\/$]* | ?:[\\/]*) ;;
3882 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3883 esac
3885 for ac_prog in gawk mawk nawk awk
3887 # Extract the first word of "$ac_prog", so it can be a program name with args.
3888 set dummy $ac_prog; ac_word=$2
3889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3890 $as_echo_n "checking for $ac_word... " >&6; }
3891 if test "${ac_cv_prog_AWK+set}" = set; then :
3892 $as_echo_n "(cached) " >&6
3893 else
3894 if test -n "$AWK"; then
3895 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3896 else
3897 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3898 for as_dir in $PATH
3900 IFS=$as_save_IFS
3901 test -z "$as_dir" && as_dir=.
3902 for ac_exec_ext in '' $ac_executable_extensions; do
3903 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3904 ac_cv_prog_AWK="$ac_prog"
3905 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3906 break 2
3908 done
3909 done
3910 IFS=$as_save_IFS
3914 AWK=$ac_cv_prog_AWK
3915 if test -n "$AWK"; then
3916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3917 $as_echo "$AWK" >&6; }
3918 else
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3920 $as_echo "no" >&6; }
3924 test -n "$AWK" && break
3925 done
3927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3928 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3929 set x ${MAKE-make}
3930 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3931 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3932 $as_echo_n "(cached) " >&6
3933 else
3934 cat >conftest.make <<\_ACEOF
3935 SHELL = /bin/sh
3936 all:
3937 @echo '@@@%%%=$(MAKE)=@@@%%%'
3938 _ACEOF
3939 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3940 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3941 *@@@%%%=?*=@@@%%%*)
3942 eval ac_cv_prog_make_${ac_make}_set=yes;;
3944 eval ac_cv_prog_make_${ac_make}_set=no;;
3945 esac
3946 rm -f conftest.make
3948 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3950 $as_echo "yes" >&6; }
3951 SET_MAKE=
3952 else
3953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3954 $as_echo "no" >&6; }
3955 SET_MAKE="MAKE=${MAKE-make}"
3958 rm -rf .tst 2>/dev/null
3959 mkdir .tst 2>/dev/null
3960 if test -d .tst; then
3961 am__leading_dot=.
3962 else
3963 am__leading_dot=_
3965 rmdir .tst 2>/dev/null
3967 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3968 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3969 # is not polluted with repeated "-I."
3970 am__isrc=' -I$(srcdir)'
3971 # test to see if srcdir already configured
3972 if test -f $srcdir/config.status; then
3973 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3977 # test whether we have cygpath
3978 if test -z "$CYGPATH_W"; then
3979 if (cygpath --version) >/dev/null 2>/dev/null; then
3980 CYGPATH_W='cygpath -w'
3981 else
3982 CYGPATH_W=echo
3987 # Define the identity of the package.
3988 PACKAGE='emacs'
3989 VERSION='24.3.50'
3992 cat >>confdefs.h <<_ACEOF
3993 #define PACKAGE "$PACKAGE"
3994 _ACEOF
3997 cat >>confdefs.h <<_ACEOF
3998 #define VERSION "$VERSION"
3999 _ACEOF
4001 # Some tools Automake needs.
4003 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4006 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4009 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4012 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4015 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4017 # We need awk for the "check" target. The system "awk" is bad on
4018 # some platforms.
4019 # Always define AMTAR for backward compatibility.
4021 AMTAR=${AMTAR-"${am_missing_run}tar"}
4023 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
4032 lispdir='${datadir}/emacs/${version}/lisp'
4033 leimdir='${datadir}/emacs/${version}/leim'
4034 standardlisppath='${lispdir}:${leimdir}'
4035 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
4036 '${datadir}/emacs/site-lisp'
4037 lisppath='${locallisppath}:${standardlisppath}'
4038 etcdir='${datadir}/emacs/${version}/etc'
4039 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4040 etcdocdir='${datadir}/emacs/${version}/etc'
4041 gamedir='${localstatedir}/games/emacs'
4044 # Check whether --with-all was given.
4045 if test "${with_all+set}" = set; then :
4046 withval=$with_all; with_features=$withval
4047 else
4048 with_features=yes
4055 # Check whether --with-pop was given.
4056 if test "${with_pop+set}" = set; then :
4057 withval=$with_pop;
4058 else
4059 with_pop=$with_features
4062 if test "$with_pop" = yes; then
4063 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4068 # Check whether --with-kerberos was given.
4069 if test "${with_kerberos+set}" = set; then :
4070 withval=$with_kerberos;
4071 else
4072 with_kerberos=no
4075 if test "$with_kerberos" != no; then
4076 $as_echo "#define KERBEROS 1" >>confdefs.h
4081 # Check whether --with-kerberos5 was given.
4082 if test "${with_kerberos5+set}" = set; then :
4083 withval=$with_kerberos5;
4084 else
4085 with_kerberos5=no
4088 if test "${with_kerberos5}" != no; then
4089 if test "${with_kerberos}" = no; then
4090 with_kerberos=yes
4091 $as_echo "#define KERBEROS 1" >>confdefs.h
4095 $as_echo "#define KERBEROS5 1" >>confdefs.h
4100 # Check whether --with-hesiod was given.
4101 if test "${with_hesiod+set}" = set; then :
4102 withval=$with_hesiod;
4103 else
4104 with_hesiod=no
4107 if test "$with_hesiod" != no; then
4109 $as_echo "#define HESIOD 1" >>confdefs.h
4114 # Check whether --with-mmdf was given.
4115 if test "${with_mmdf+set}" = set; then :
4116 withval=$with_mmdf;
4117 else
4118 with_mmdf=no
4121 if test "$with_mmdf" != no; then
4123 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4128 # Check whether --with-mail-unlink was given.
4129 if test "${with_mail_unlink+set}" = set; then :
4130 withval=$with_mail_unlink;
4131 else
4132 with_mail_unlink=no
4135 if test "$with_mail_unlink" != no; then
4137 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4142 # Check whether --with-mailhost was given.
4143 if test "${with_mailhost+set}" = set; then :
4144 withval=$with_mailhost;
4145 cat >>confdefs.h <<_ACEOF
4146 #define MAILHOST "$withval"
4147 _ACEOF
4153 # Check whether --with-sound was given.
4154 if test "${with_sound+set}" = set; then :
4155 withval=$with_sound; case "${withval}" in
4156 yes|no|alsa|oss|bsd-ossaudio) val=$withval ;;
4157 *) as_fn_error "\`--with-sound=$withval' is invalid;
4158 this option's value should be \`yes', \`no', \`alsa', \`oss', or \`bsd-ossaudio'." "$LINENO" 5
4160 esac
4161 with_sound=$val
4163 else
4164 with_sound=$with_features
4169 # Check whether --with-x-toolkit was given.
4170 if test "${with_x_toolkit+set}" = set; then :
4171 withval=$with_x_toolkit; case "${withval}" in
4172 y | ye | yes ) val=gtk ;;
4173 n | no ) val=no ;;
4174 l | lu | luc | luci | lucid ) val=lucid ;;
4175 a | at | ath | athe | athen | athena ) val=athena ;;
4176 m | mo | mot | moti | motif ) val=motif ;;
4177 g | gt | gtk ) val=gtk ;;
4178 gtk2 ) val=gtk2 ;;
4179 gtk3 ) val=gtk3 ;;
4181 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4182 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4183 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4184 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4186 esac
4187 with_x_toolkit=$val
4193 # Check whether --with-wide-int was given.
4194 if test "${with_wide_int+set}" = set; then :
4195 withval=$with_wide_int;
4196 else
4197 with_wide_int=no
4200 if test "$with_wide_int" = yes; then
4202 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4207 # Check whether --with-xpm was given.
4208 if test "${with_xpm+set}" = set; then :
4209 withval=$with_xpm;
4210 else
4211 with_xpm=$with_features
4215 # Check whether --with-jpeg was given.
4216 if test "${with_jpeg+set}" = set; then :
4217 withval=$with_jpeg;
4218 else
4219 with_jpeg=$with_features
4223 # Check whether --with-tiff was given.
4224 if test "${with_tiff+set}" = set; then :
4225 withval=$with_tiff;
4226 else
4227 with_tiff=$with_features
4231 # Check whether --with-gif was given.
4232 if test "${with_gif+set}" = set; then :
4233 withval=$with_gif;
4234 else
4235 with_gif=$with_features
4239 # Check whether --with-png was given.
4240 if test "${with_png+set}" = set; then :
4241 withval=$with_png;
4242 else
4243 with_png=$with_features
4247 # Check whether --with-rsvg was given.
4248 if test "${with_rsvg+set}" = set; then :
4249 withval=$with_rsvg;
4250 else
4251 with_rsvg=$with_features
4255 # Check whether --with-xml2 was given.
4256 if test "${with_xml2+set}" = set; then :
4257 withval=$with_xml2;
4258 else
4259 with_xml2=$with_features
4263 # Check whether --with-imagemagick was given.
4264 if test "${with_imagemagick+set}" = set; then :
4265 withval=$with_imagemagick;
4266 else
4267 with_imagemagick=$with_features
4272 # Check whether --with-xft was given.
4273 if test "${with_xft+set}" = set; then :
4274 withval=$with_xft;
4275 else
4276 with_xft=$with_features
4280 # Check whether --with-libotf was given.
4281 if test "${with_libotf+set}" = set; then :
4282 withval=$with_libotf;
4283 else
4284 with_libotf=$with_features
4288 # Check whether --with-m17n-flt was given.
4289 if test "${with_m17n_flt+set}" = set; then :
4290 withval=$with_m17n_flt;
4291 else
4292 with_m17n_flt=$with_features
4297 # Check whether --with-toolkit-scroll-bars was given.
4298 if test "${with_toolkit_scroll_bars+set}" = set; then :
4299 withval=$with_toolkit_scroll_bars;
4300 else
4301 with_toolkit_scroll_bars=$with_features
4305 # Check whether --with-xaw3d was given.
4306 if test "${with_xaw3d+set}" = set; then :
4307 withval=$with_xaw3d;
4308 else
4309 with_xaw3d=$with_features
4313 # Check whether --with-xim was given.
4314 if test "${with_xim+set}" = set; then :
4315 withval=$with_xim;
4316 else
4317 with_xim=$with_features
4321 # Check whether --with-ns was given.
4322 if test "${with_ns+set}" = set; then :
4323 withval=$with_ns;
4324 else
4325 with_ns=no
4329 # Check whether --with-w32 was given.
4330 if test "${with_w32+set}" = set; then :
4331 withval=$with_w32;
4332 else
4333 with_w32=no
4338 # Check whether --with-gpm was given.
4339 if test "${with_gpm+set}" = set; then :
4340 withval=$with_gpm;
4341 else
4342 with_gpm=$with_features
4346 # Check whether --with-dbus was given.
4347 if test "${with_dbus+set}" = set; then :
4348 withval=$with_dbus;
4349 else
4350 with_dbus=$with_features
4354 # Check whether --with-gconf was given.
4355 if test "${with_gconf+set}" = set; then :
4356 withval=$with_gconf;
4357 else
4358 with_gconf=$with_features
4362 # Check whether --with-gsettings was given.
4363 if test "${with_gsettings+set}" = set; then :
4364 withval=$with_gsettings;
4365 else
4366 with_gsettings=$with_features
4370 # Check whether --with-selinux was given.
4371 if test "${with_selinux+set}" = set; then :
4372 withval=$with_selinux;
4373 else
4374 with_selinux=$with_features
4378 # Check whether --with-gnutls was given.
4379 if test "${with_gnutls+set}" = set; then :
4380 withval=$with_gnutls;
4381 else
4382 with_gnutls=$with_features
4386 # Check whether --with-zlib was given.
4387 if test "${with_zlib+set}" = set; then :
4388 withval=$with_zlib;
4389 else
4390 with_zlib=$with_features
4395 # Check whether --with-file-notification was given.
4396 if test "${with_file_notification+set}" = set; then :
4397 withval=$with_file_notification; case "${withval}" in
4398 y | ye | yes ) val=yes ;;
4399 n | no ) val=no ;;
4400 g | gf | gfi | gfil | gfile ) val=gfile ;;
4401 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4402 w | w3 | w32 ) val=w32 ;;
4403 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4404 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4405 \`yes' is a synonym for \`w32' on MS-Windows, for \`no' on Nextstep,
4406 otherwise for the first of \`gfile' or \`inotify' that is usable." "$LINENO" 5
4408 esac
4409 with_file_notification=$val
4411 else
4412 with_file_notification=$with_features
4416 ## For the times when you want to build Emacs but don't have
4417 ## a suitable makeinfo, and can live without the manuals.
4419 # Check whether --with-makeinfo was given.
4420 if test "${with_makeinfo+set}" = set; then :
4421 withval=$with_makeinfo;
4422 else
4423 with_makeinfo=$with_features
4427 ## Makefile.in needs the cache file name.
4430 ## This is an option because I do not know if all info/man support
4431 ## compressed files, nor how to test if they do so.
4433 # Check whether --with-compress-install was given.
4434 if test "${with_compress_install+set}" = set; then :
4435 withval=$with_compress_install;
4436 else
4437 with_compress_install=$with_features
4442 # Check whether --with-pkg-config-prog was given.
4443 if test "${with_pkg_config_prog+set}" = set; then :
4444 withval=$with_pkg_config_prog;
4447 if test "X${with_pkg_config_prog}" != X; then
4448 if test "${with_pkg_config_prog}" != yes; then
4449 PKG_CONFIG="${with_pkg_config_prog}"
4454 # Check whether --with-gameuser was given.
4455 if test "${with_gameuser+set}" = set; then :
4456 withval=$with_gameuser;
4459 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4460 && gameuser="${with_gameuser}"
4461 test "X$gameuser" = X && gameuser=games
4464 # Check whether --with-gnustep-conf was given.
4465 if test "${with_gnustep_conf+set}" = set; then :
4466 withval=$with_gnustep_conf;
4469 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4470 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4471 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4472 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4474 # Check whether --enable-ns-self-contained was given.
4475 if test "${enable_ns_self_contained+set}" = set; then :
4476 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4477 else
4478 EN_NS_SELF_CONTAINED=yes
4482 # Check whether --enable-locallisppath was given.
4483 if test "${enable_locallisppath+set}" = set; then :
4484 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4485 locallisppath=
4486 elif test "${enableval}" != "yes"; then
4487 locallisppath=${enableval}
4492 # Check whether --enable-checking was given.
4493 if test "${enable_checking+set}" = set; then :
4494 enableval=$enable_checking; ac_checking_flags="${enableval}"
4497 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4498 for check in $ac_checking_flags
4500 case $check in
4501 # these set all the flags to specific states
4502 yes) ac_enable_checking=1 ;;
4503 no) ac_enable_checking= ;
4504 ac_gc_check_stringbytes= ;
4505 ac_gc_check_string_overrun= ;
4506 ac_gc_check_string_free_list= ;
4507 ac_xmalloc_overrun= ;
4508 ac_gc_check_cons_list= ;
4509 ac_glyphs_debug= ;;
4510 all) ac_enable_checking=1 ;
4511 ac_gc_check_stringbytes=1 ;
4512 ac_gc_check_string_overrun=1 ;
4513 ac_gc_check_string_free_list=1 ;
4514 ac_xmalloc_overrun=1 ;
4515 ac_gc_check_cons_list=1 ;
4516 ac_glyphs_debug=1 ;;
4517 # these enable particular checks
4518 stringbytes) ac_gc_check_stringbytes=1 ;;
4519 stringoverrun) ac_gc_check_string_overrun=1 ;;
4520 stringfreelist) ac_gc_check_string_free_list=1 ;;
4521 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4522 conslist) ac_gc_check_cons_list=1 ;;
4523 glyphs) ac_glyphs_debug=1 ;;
4524 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4525 esac
4526 done
4527 IFS="$ac_save_IFS"
4529 if test x$ac_enable_checking != x ; then
4531 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4534 if test x$ac_gc_check_stringbytes != x ; then
4536 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4539 if test x$ac_gc_check_string_overrun != x ; then
4541 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4544 if test x$ac_gc_check_string_free_list != x ; then
4546 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4549 if test x$ac_xmalloc_overrun != x ; then
4551 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4554 if test x$ac_gc_check_cons_list != x ; then
4556 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4559 if test x$ac_glyphs_debug != x ; then
4561 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4565 # Check whether --enable-check-lisp-object-type was given.
4566 if test "${enable_check_lisp_object_type+set}" = set; then :
4567 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4569 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4576 # Check whether --enable-profiling was given.
4577 if test "${enable_profiling+set}" = set; then :
4578 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4581 if test x$ac_enable_profiling != x ; then
4582 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4583 else
4584 PROFILING_CFLAGS=
4588 # Check whether --enable-autodepend was given.
4589 if test "${enable_autodepend+set}" = set; then :
4590 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4591 else
4592 ac_enable_autodepend=yes
4596 # Check whether --enable-gtk-deprecation-warnings was given.
4597 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4598 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4602 #### Make srcdir absolute, if it isn't already. It's important to
4603 #### avoid running the file name through pwd unnecessarily, since pwd can
4604 #### give you automounter prefixes, which can go away. We do all this
4605 #### so Emacs can find its files when run uninstalled.
4606 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4607 unset CDPATH
4608 case "${srcdir}" in
4609 [\\/]* | ?:[\\/]*) ;;
4611 ## We may be able to use the $PWD environment variable to make this
4612 ## absolute. But sometimes PWD is inaccurate.
4613 ## Note: we used to use $PWD at the end instead of `pwd`,
4614 ## but that tested only for a well-formed and valid PWD,
4615 ## it did not object when PWD was well-formed and valid but just wrong.
4616 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4617 then
4618 srcdir="$PWD"
4619 else
4620 srcdir=`(cd "$srcdir"; pwd)`
4623 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4624 esac
4626 #### When building with MinGW inside the MSYS tree, 'pwd' produces
4627 #### directories relative to the root of the MSYS tree,
4628 #### e.g. '/home/user/foo' instead of '/d/MSYS/home/user/foo'. When
4629 #### such a value of srcdir is written to the top-level Makefile, it
4630 #### gets propagated to src/epaths.h, and that causes temacs to fail,
4631 #### because, being a MinGW program that knows nothing of MSYS root
4632 #### substitution, it cannot find the data directory. "pwd -W"
4633 #### produces Windows-style 'd:/foo/bar' absolute directory names, so
4634 #### we use it here to countermand that lossage.
4635 test "$MSYSTEM" = "MINGW32" && srcdir=`(cd "$srcdir"; pwd -W | sed -e 's,^\([A-Za-z]\):,/\1,')`
4637 ### Canonicalize the configuration name.
4639 # Make sure we can run config.sub.
4640 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4641 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4644 $as_echo_n "checking build system type... " >&6; }
4645 if test "${ac_cv_build+set}" = set; then :
4646 $as_echo_n "(cached) " >&6
4647 else
4648 ac_build_alias=$build_alias
4649 test "x$ac_build_alias" = x &&
4650 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4651 test "x$ac_build_alias" = x &&
4652 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4653 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4654 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4658 $as_echo "$ac_cv_build" >&6; }
4659 case $ac_cv_build in
4660 *-*-*) ;;
4661 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4662 esac
4663 build=$ac_cv_build
4664 ac_save_IFS=$IFS; IFS='-'
4665 set x $ac_cv_build
4666 shift
4667 build_cpu=$1
4668 build_vendor=$2
4669 shift; shift
4670 # Remember, the first character of IFS is used to create $*,
4671 # except with old shells:
4672 build_os=$*
4673 IFS=$ac_save_IFS
4674 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4678 $as_echo_n "checking host system type... " >&6; }
4679 if test "${ac_cv_host+set}" = set; then :
4680 $as_echo_n "(cached) " >&6
4681 else
4682 if test "x$host_alias" = x; then
4683 ac_cv_host=$ac_cv_build
4684 else
4685 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4686 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4691 $as_echo "$ac_cv_host" >&6; }
4692 case $ac_cv_host in
4693 *-*-*) ;;
4694 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4695 esac
4696 host=$ac_cv_host
4697 ac_save_IFS=$IFS; IFS='-'
4698 set x $ac_cv_host
4699 shift
4700 host_cpu=$1
4701 host_vendor=$2
4702 shift; shift
4703 # Remember, the first character of IFS is used to create $*,
4704 # except with old shells:
4705 host_os=$*
4706 IFS=$ac_save_IFS
4707 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4710 canonical=$host
4711 configuration=${host_alias-${build_alias-$host}}
4715 ### If you add support for a new configuration, add code to this
4716 ### switch statement to recognize your configuration name and select
4717 ### the appropriate operating system file.
4719 ### You would hope that you could choose an s/*.h
4720 ### file based on the operating system portion. However, it turns out
4721 ### that each s/*.h file is pretty manufacturer-specific.
4722 ### So we basically have to have a special case for each
4723 ### configuration name.
4725 ### As far as handling version numbers on operating systems is
4726 ### concerned, make sure things will fail in a fixable way. If
4727 ### /etc/MACHINES doesn't say anything about version numbers, be
4728 ### prepared to handle anything reasonably. If version numbers
4729 ### matter, be sure /etc/MACHINES says something about it.
4731 opsys='' unported=no
4732 case "${canonical}" in
4734 ## GNU/Linux and similar ports
4735 *-*-linux* )
4736 opsys=gnu-linux
4739 ## FreeBSD ports
4740 *-*-freebsd* )
4741 opsys=freebsd
4744 ## DragonFly ports
4745 *-*-dragonfly* )
4746 opsys=dragonfly
4749 ## FreeBSD kernel + glibc based userland
4750 *-*-kfreebsd*gnu* )
4751 opsys=gnu-kfreebsd
4754 ## NetBSD ports
4755 *-*-netbsd* )
4756 opsys=netbsd
4759 ## OpenBSD ports
4760 *-*-openbsd* )
4761 opsys=openbsd
4764 ## Apple Darwin / Mac OS X
4765 *-apple-darwin* )
4766 case "${canonical}" in
4767 i[3456]86-* ) ;;
4768 powerpc-* ) ;;
4769 x86_64-* ) ;;
4770 * ) unported=yes ;;
4771 esac
4772 opsys=darwin
4773 ## Use fink packages if available.
4774 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4775 ## if test -d /sw/include && test -d /sw/lib; then
4776 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4777 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4778 ## fi
4781 ## Cygwin ports
4782 *-*-cygwin )
4783 opsys=cygwin
4786 ## HP 9000 series 700 and 800, running HP/UX
4787 hppa*-hp-hpux10.2* )
4788 opsys=hpux10-20
4790 hppa*-hp-hpux1[1-9]* )
4791 opsys=hpux11
4792 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4795 ## IBM machines
4796 rs6000-ibm-aix4.[23]* )
4797 opsys=aix4-2
4799 powerpc-ibm-aix4.[23]* )
4800 opsys=aix4-2
4802 rs6000-ibm-aix[56]* )
4803 opsys=aix4-2
4805 powerpc-ibm-aix[56]* )
4806 opsys=aix4-2
4809 ## Silicon Graphics machines
4810 ## Iris 4D
4811 mips-sgi-irix6.5 )
4812 opsys=irix6-5
4813 # Without defining _LANGUAGE_C, things get masked out in the headers
4814 # so that, for instance, grepping for `free' in stdlib.h fails and
4815 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4816 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4819 ## Suns
4820 *-sun-solaris* \
4821 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4822 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4823 case "${canonical}" in
4824 i[3456]86-*-* ) ;;
4825 amd64-*-*|x86_64-*-*) ;;
4826 sparc* ) ;;
4827 * ) unported=yes ;;
4828 esac
4829 case "${canonical}" in
4830 *-sunos5.6* | *-solaris2.6* )
4831 opsys=sol2-6
4832 RANLIB="ar -ts"
4834 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4835 opsys=sol2-6
4836 emacs_check_sunpro_c=yes
4838 *-sunos5* | *-solaris* )
4839 opsys=sol2-10
4840 emacs_check_sunpro_c=yes
4842 esac
4843 ## Watch out for a compiler that we know will not work.
4844 case "${canonical}" in
4845 *-solaris* | *-sunos5* )
4846 if [ "x$CC" = x/usr/ucb/cc ]; then
4847 ## /usr/ucb/cc doesn't work;
4848 ## we should find some other compiler that does work.
4849 unset CC
4852 *) ;;
4853 esac
4856 ## Intel 386 machines where we don't care about the manufacturer.
4857 i[3456]86-*-* )
4858 case "${canonical}" in
4859 *-darwin* ) opsys=darwin ;;
4860 *-mingw32 )
4861 opsys=mingw32
4862 # MinGW overrides and adds some system headers in nt/inc.
4863 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4865 *-sysv4.2uw* ) opsys=unixware ;;
4866 *-sysv5uw* ) opsys=unixware ;;
4867 *-sysv5OpenUNIX* ) opsys=unixware ;;
4868 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4869 esac
4873 unported=yes
4875 esac
4877 ### If the code above didn't choose an operating system, just choose
4878 ### an operating system based on the configuration name. You really
4879 ### only want to use this when you have no idea what the right
4880 ### operating system is; if you know what operating systems a machine
4881 ### runs, it's cleaner to make it explicit in the case statement
4882 ### above.
4883 if test x"${opsys}" = x; then
4884 case "${canonical}" in
4885 *-gnu* ) opsys=gnu ;;
4887 unported=yes
4889 esac
4894 if test $unported = yes; then
4895 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4896 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4900 #### Choose a compiler.
4902 ac_ext=c
4903 ac_cpp='$CPP $CPPFLAGS'
4904 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4905 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4906 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4907 if test -n "$ac_tool_prefix"; then
4908 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4909 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4911 $as_echo_n "checking for $ac_word... " >&6; }
4912 if test "${ac_cv_prog_CC+set}" = set; then :
4913 $as_echo_n "(cached) " >&6
4914 else
4915 if test -n "$CC"; then
4916 ac_cv_prog_CC="$CC" # Let the user override the test.
4917 else
4918 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4919 for as_dir in $PATH
4921 IFS=$as_save_IFS
4922 test -z "$as_dir" && as_dir=.
4923 for ac_exec_ext in '' $ac_executable_extensions; do
4924 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4925 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4926 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4927 break 2
4929 done
4930 done
4931 IFS=$as_save_IFS
4935 CC=$ac_cv_prog_CC
4936 if test -n "$CC"; then
4937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4938 $as_echo "$CC" >&6; }
4939 else
4940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4941 $as_echo "no" >&6; }
4946 if test -z "$ac_cv_prog_CC"; then
4947 ac_ct_CC=$CC
4948 # Extract the first word of "gcc", so it can be a program name with args.
4949 set dummy gcc; ac_word=$2
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4951 $as_echo_n "checking for $ac_word... " >&6; }
4952 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4953 $as_echo_n "(cached) " >&6
4954 else
4955 if test -n "$ac_ct_CC"; then
4956 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4957 else
4958 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4959 for as_dir in $PATH
4961 IFS=$as_save_IFS
4962 test -z "$as_dir" && as_dir=.
4963 for ac_exec_ext in '' $ac_executable_extensions; do
4964 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4965 ac_cv_prog_ac_ct_CC="gcc"
4966 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4967 break 2
4969 done
4970 done
4971 IFS=$as_save_IFS
4975 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4976 if test -n "$ac_ct_CC"; then
4977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4978 $as_echo "$ac_ct_CC" >&6; }
4979 else
4980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4981 $as_echo "no" >&6; }
4984 if test "x$ac_ct_CC" = x; then
4985 CC=""
4986 else
4987 case $cross_compiling:$ac_tool_warned in
4988 yes:)
4989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4990 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4991 ac_tool_warned=yes ;;
4992 esac
4993 CC=$ac_ct_CC
4995 else
4996 CC="$ac_cv_prog_CC"
4999 if test -z "$CC"; then
5000 if test -n "$ac_tool_prefix"; then
5001 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5002 set dummy ${ac_tool_prefix}cc; ac_word=$2
5003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5004 $as_echo_n "checking for $ac_word... " >&6; }
5005 if test "${ac_cv_prog_CC+set}" = set; then :
5006 $as_echo_n "(cached) " >&6
5007 else
5008 if test -n "$CC"; then
5009 ac_cv_prog_CC="$CC" # Let the user override the test.
5010 else
5011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5012 for as_dir in $PATH
5014 IFS=$as_save_IFS
5015 test -z "$as_dir" && as_dir=.
5016 for ac_exec_ext in '' $ac_executable_extensions; do
5017 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5018 ac_cv_prog_CC="${ac_tool_prefix}cc"
5019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5020 break 2
5022 done
5023 done
5024 IFS=$as_save_IFS
5028 CC=$ac_cv_prog_CC
5029 if test -n "$CC"; then
5030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5031 $as_echo "$CC" >&6; }
5032 else
5033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5034 $as_echo "no" >&6; }
5040 if test -z "$CC"; then
5041 # Extract the first word of "cc", so it can be a program name with args.
5042 set dummy cc; ac_word=$2
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5044 $as_echo_n "checking for $ac_word... " >&6; }
5045 if test "${ac_cv_prog_CC+set}" = set; then :
5046 $as_echo_n "(cached) " >&6
5047 else
5048 if test -n "$CC"; then
5049 ac_cv_prog_CC="$CC" # Let the user override the test.
5050 else
5051 ac_prog_rejected=no
5052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5053 for as_dir in $PATH
5055 IFS=$as_save_IFS
5056 test -z "$as_dir" && as_dir=.
5057 for ac_exec_ext in '' $ac_executable_extensions; do
5058 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5059 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5060 ac_prog_rejected=yes
5061 continue
5063 ac_cv_prog_CC="cc"
5064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5065 break 2
5067 done
5068 done
5069 IFS=$as_save_IFS
5071 if test $ac_prog_rejected = yes; then
5072 # We found a bogon in the path, so make sure we never use it.
5073 set dummy $ac_cv_prog_CC
5074 shift
5075 if test $# != 0; then
5076 # We chose a different compiler from the bogus one.
5077 # However, it has the same basename, so the bogon will be chosen
5078 # first if we set CC to just the basename; use the full file name.
5079 shift
5080 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5085 CC=$ac_cv_prog_CC
5086 if test -n "$CC"; then
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5088 $as_echo "$CC" >&6; }
5089 else
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5091 $as_echo "no" >&6; }
5096 if test -z "$CC"; then
5097 if test -n "$ac_tool_prefix"; then
5098 for ac_prog in cl.exe
5100 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5101 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5103 $as_echo_n "checking for $ac_word... " >&6; }
5104 if test "${ac_cv_prog_CC+set}" = set; then :
5105 $as_echo_n "(cached) " >&6
5106 else
5107 if test -n "$CC"; then
5108 ac_cv_prog_CC="$CC" # Let the user override the test.
5109 else
5110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5111 for as_dir in $PATH
5113 IFS=$as_save_IFS
5114 test -z "$as_dir" && as_dir=.
5115 for ac_exec_ext in '' $ac_executable_extensions; do
5116 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5117 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5118 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5119 break 2
5121 done
5122 done
5123 IFS=$as_save_IFS
5127 CC=$ac_cv_prog_CC
5128 if test -n "$CC"; then
5129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5130 $as_echo "$CC" >&6; }
5131 else
5132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5133 $as_echo "no" >&6; }
5137 test -n "$CC" && break
5138 done
5140 if test -z "$CC"; then
5141 ac_ct_CC=$CC
5142 for ac_prog in cl.exe
5144 # Extract the first word of "$ac_prog", so it can be a program name with args.
5145 set dummy $ac_prog; ac_word=$2
5146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5147 $as_echo_n "checking for $ac_word... " >&6; }
5148 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5149 $as_echo_n "(cached) " >&6
5150 else
5151 if test -n "$ac_ct_CC"; then
5152 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5153 else
5154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5155 for as_dir in $PATH
5157 IFS=$as_save_IFS
5158 test -z "$as_dir" && as_dir=.
5159 for ac_exec_ext in '' $ac_executable_extensions; do
5160 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5161 ac_cv_prog_ac_ct_CC="$ac_prog"
5162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5163 break 2
5165 done
5166 done
5167 IFS=$as_save_IFS
5171 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5172 if test -n "$ac_ct_CC"; then
5173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5174 $as_echo "$ac_ct_CC" >&6; }
5175 else
5176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5177 $as_echo "no" >&6; }
5181 test -n "$ac_ct_CC" && break
5182 done
5184 if test "x$ac_ct_CC" = x; then
5185 CC=""
5186 else
5187 case $cross_compiling:$ac_tool_warned in
5188 yes:)
5189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5190 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5191 ac_tool_warned=yes ;;
5192 esac
5193 CC=$ac_ct_CC
5200 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5201 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5202 as_fn_error "no acceptable C compiler found in \$PATH
5203 See \`config.log' for more details." "$LINENO" 5; }
5205 # Provide some information about the compiler.
5206 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5207 set X $ac_compile
5208 ac_compiler=$2
5209 for ac_option in --version -v -V -qversion; do
5210 { { ac_try="$ac_compiler $ac_option >&5"
5211 case "(($ac_try" in
5212 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5213 *) ac_try_echo=$ac_try;;
5214 esac
5215 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5216 $as_echo "$ac_try_echo"; } >&5
5217 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5218 ac_status=$?
5219 if test -s conftest.err; then
5220 sed '10a\
5221 ... rest of stderr output deleted ...
5222 10q' conftest.err >conftest.er1
5223 cat conftest.er1 >&5
5225 rm -f conftest.er1 conftest.err
5226 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5227 test $ac_status = 0; }
5228 done
5230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5231 /* end confdefs.h. */
5234 main ()
5238 return 0;
5240 _ACEOF
5241 ac_clean_files_save=$ac_clean_files
5242 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5243 # Try to create an executable without -o first, disregard a.out.
5244 # It will help us diagnose broken compilers, and finding out an intuition
5245 # of exeext.
5246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5247 $as_echo_n "checking whether the C compiler works... " >&6; }
5248 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5250 # The possible output files:
5251 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5253 ac_rmfiles=
5254 for ac_file in $ac_files
5256 case $ac_file in
5257 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5258 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5259 esac
5260 done
5261 rm -f $ac_rmfiles
5263 if { { ac_try="$ac_link_default"
5264 case "(($ac_try" in
5265 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5266 *) ac_try_echo=$ac_try;;
5267 esac
5268 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5269 $as_echo "$ac_try_echo"; } >&5
5270 (eval "$ac_link_default") 2>&5
5271 ac_status=$?
5272 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5273 test $ac_status = 0; }; then :
5274 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5275 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5276 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5277 # so that the user can short-circuit this test for compilers unknown to
5278 # Autoconf.
5279 for ac_file in $ac_files ''
5281 test -f "$ac_file" || continue
5282 case $ac_file in
5283 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5285 [ab].out )
5286 # We found the default executable, but exeext='' is most
5287 # certainly right.
5288 break;;
5289 *.* )
5290 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5291 then :; else
5292 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5294 # We set ac_cv_exeext here because the later test for it is not
5295 # safe: cross compilers may not add the suffix if given an `-o'
5296 # argument, so we may need to know it at that point already.
5297 # Even if this section looks crufty: it has the advantage of
5298 # actually working.
5299 break;;
5301 break;;
5302 esac
5303 done
5304 test "$ac_cv_exeext" = no && ac_cv_exeext=
5306 else
5307 ac_file=''
5309 if test -z "$ac_file"; then :
5310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5311 $as_echo "no" >&6; }
5312 $as_echo "$as_me: failed program was:" >&5
5313 sed 's/^/| /' conftest.$ac_ext >&5
5315 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5316 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5317 { as_fn_set_status 77
5318 as_fn_error "C compiler cannot create executables
5319 See \`config.log' for more details." "$LINENO" 5; }; }
5320 else
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5322 $as_echo "yes" >&6; }
5324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5325 $as_echo_n "checking for C compiler default output file name... " >&6; }
5326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5327 $as_echo "$ac_file" >&6; }
5328 ac_exeext=$ac_cv_exeext
5330 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5331 ac_clean_files=$ac_clean_files_save
5332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5333 $as_echo_n "checking for suffix of executables... " >&6; }
5334 if { { ac_try="$ac_link"
5335 case "(($ac_try" in
5336 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5337 *) ac_try_echo=$ac_try;;
5338 esac
5339 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5340 $as_echo "$ac_try_echo"; } >&5
5341 (eval "$ac_link") 2>&5
5342 ac_status=$?
5343 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5344 test $ac_status = 0; }; then :
5345 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5346 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5347 # work properly (i.e., refer to `conftest.exe'), while it won't with
5348 # `rm'.
5349 for ac_file in conftest.exe conftest conftest.*; do
5350 test -f "$ac_file" || continue
5351 case $ac_file in
5352 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5353 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5354 break;;
5355 * ) break;;
5356 esac
5357 done
5358 else
5359 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5360 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5361 as_fn_error "cannot compute suffix of executables: cannot compile and link
5362 See \`config.log' for more details." "$LINENO" 5; }
5364 rm -f conftest conftest$ac_cv_exeext
5365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5366 $as_echo "$ac_cv_exeext" >&6; }
5368 rm -f conftest.$ac_ext
5369 EXEEXT=$ac_cv_exeext
5370 ac_exeext=$EXEEXT
5371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5372 /* end confdefs.h. */
5373 #include <stdio.h>
5375 main ()
5377 FILE *f = fopen ("conftest.out", "w");
5378 return ferror (f) || fclose (f) != 0;
5381 return 0;
5383 _ACEOF
5384 ac_clean_files="$ac_clean_files conftest.out"
5385 # Check that the compiler produces executables we can run. If not, either
5386 # the compiler is broken, or we cross compile.
5387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5388 $as_echo_n "checking whether we are cross compiling... " >&6; }
5389 if test "$cross_compiling" != yes; then
5390 { { ac_try="$ac_link"
5391 case "(($ac_try" in
5392 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5393 *) ac_try_echo=$ac_try;;
5394 esac
5395 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5396 $as_echo "$ac_try_echo"; } >&5
5397 (eval "$ac_link") 2>&5
5398 ac_status=$?
5399 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5400 test $ac_status = 0; }
5401 if { ac_try='./conftest$ac_cv_exeext'
5402 { { case "(($ac_try" in
5403 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5404 *) ac_try_echo=$ac_try;;
5405 esac
5406 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5407 $as_echo "$ac_try_echo"; } >&5
5408 (eval "$ac_try") 2>&5
5409 ac_status=$?
5410 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5411 test $ac_status = 0; }; }; then
5412 cross_compiling=no
5413 else
5414 if test "$cross_compiling" = maybe; then
5415 cross_compiling=yes
5416 else
5417 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5418 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5419 as_fn_error "cannot run C compiled programs.
5420 If you meant to cross compile, use \`--host'.
5421 See \`config.log' for more details." "$LINENO" 5; }
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5426 $as_echo "$cross_compiling" >&6; }
5428 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5429 ac_clean_files=$ac_clean_files_save
5430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5431 $as_echo_n "checking for suffix of object files... " >&6; }
5432 if test "${ac_cv_objext+set}" = set; then :
5433 $as_echo_n "(cached) " >&6
5434 else
5435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5436 /* end confdefs.h. */
5439 main ()
5443 return 0;
5445 _ACEOF
5446 rm -f conftest.o conftest.obj
5447 if { { ac_try="$ac_compile"
5448 case "(($ac_try" in
5449 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5450 *) ac_try_echo=$ac_try;;
5451 esac
5452 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5453 $as_echo "$ac_try_echo"; } >&5
5454 (eval "$ac_compile") 2>&5
5455 ac_status=$?
5456 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5457 test $ac_status = 0; }; then :
5458 for ac_file in conftest.o conftest.obj conftest.*; do
5459 test -f "$ac_file" || continue;
5460 case $ac_file in
5461 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5462 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5463 break;;
5464 esac
5465 done
5466 else
5467 $as_echo "$as_me: failed program was:" >&5
5468 sed 's/^/| /' conftest.$ac_ext >&5
5470 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5471 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5472 as_fn_error "cannot compute suffix of object files: cannot compile
5473 See \`config.log' for more details." "$LINENO" 5; }
5475 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5478 $as_echo "$ac_cv_objext" >&6; }
5479 OBJEXT=$ac_cv_objext
5480 ac_objext=$OBJEXT
5481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5482 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5483 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5484 $as_echo_n "(cached) " >&6
5485 else
5486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5487 /* end confdefs.h. */
5490 main ()
5492 #ifndef __GNUC__
5493 choke me
5494 #endif
5497 return 0;
5499 _ACEOF
5500 if ac_fn_c_try_compile "$LINENO"; then :
5501 ac_compiler_gnu=yes
5502 else
5503 ac_compiler_gnu=no
5505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5506 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5510 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5511 if test $ac_compiler_gnu = yes; then
5512 GCC=yes
5513 else
5514 GCC=
5516 ac_test_CFLAGS=${CFLAGS+set}
5517 ac_save_CFLAGS=$CFLAGS
5518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5519 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5520 if test "${ac_cv_prog_cc_g+set}" = set; then :
5521 $as_echo_n "(cached) " >&6
5522 else
5523 ac_save_c_werror_flag=$ac_c_werror_flag
5524 ac_c_werror_flag=yes
5525 ac_cv_prog_cc_g=no
5526 CFLAGS="-g"
5527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5528 /* end confdefs.h. */
5531 main ()
5535 return 0;
5537 _ACEOF
5538 if ac_fn_c_try_compile "$LINENO"; then :
5539 ac_cv_prog_cc_g=yes
5540 else
5541 CFLAGS=""
5542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5543 /* end confdefs.h. */
5546 main ()
5550 return 0;
5552 _ACEOF
5553 if ac_fn_c_try_compile "$LINENO"; then :
5555 else
5556 ac_c_werror_flag=$ac_save_c_werror_flag
5557 CFLAGS="-g"
5558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5559 /* end confdefs.h. */
5562 main ()
5566 return 0;
5568 _ACEOF
5569 if ac_fn_c_try_compile "$LINENO"; then :
5570 ac_cv_prog_cc_g=yes
5572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5576 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5577 ac_c_werror_flag=$ac_save_c_werror_flag
5579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5580 $as_echo "$ac_cv_prog_cc_g" >&6; }
5581 if test "$ac_test_CFLAGS" = set; then
5582 CFLAGS=$ac_save_CFLAGS
5583 elif test $ac_cv_prog_cc_g = yes; then
5584 if test "$GCC" = yes; then
5585 CFLAGS="-g -O2"
5586 else
5587 CFLAGS="-g"
5589 else
5590 if test "$GCC" = yes; then
5591 CFLAGS="-O2"
5592 else
5593 CFLAGS=
5596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5597 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5598 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5599 $as_echo_n "(cached) " >&6
5600 else
5601 ac_cv_prog_cc_c89=no
5602 ac_save_CC=$CC
5603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5604 /* end confdefs.h. */
5605 #include <stdarg.h>
5606 #include <stdio.h>
5607 #include <sys/types.h>
5608 #include <sys/stat.h>
5609 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5610 struct buf { int x; };
5611 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5612 static char *e (p, i)
5613 char **p;
5614 int i;
5616 return p[i];
5618 static char *f (char * (*g) (char **, int), char **p, ...)
5620 char *s;
5621 va_list v;
5622 va_start (v,p);
5623 s = g (p, va_arg (v,int));
5624 va_end (v);
5625 return s;
5628 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5629 function prototypes and stuff, but not '\xHH' hex character constants.
5630 These don't provoke an error unfortunately, instead are silently treated
5631 as 'x'. The following induces an error, until -std is added to get
5632 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5633 array size at least. It's necessary to write '\x00'==0 to get something
5634 that's true only with -std. */
5635 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5637 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5638 inside strings and character constants. */
5639 #define FOO(x) 'x'
5640 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5642 int test (int i, double x);
5643 struct s1 {int (*f) (int a);};
5644 struct s2 {int (*f) (double a);};
5645 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5646 int argc;
5647 char **argv;
5649 main ()
5651 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5653 return 0;
5655 _ACEOF
5656 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5657 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5659 CC="$ac_save_CC $ac_arg"
5660 if ac_fn_c_try_compile "$LINENO"; then :
5661 ac_cv_prog_cc_c89=$ac_arg
5663 rm -f core conftest.err conftest.$ac_objext
5664 test "x$ac_cv_prog_cc_c89" != "xno" && break
5665 done
5666 rm -f conftest.$ac_ext
5667 CC=$ac_save_CC
5670 # AC_CACHE_VAL
5671 case "x$ac_cv_prog_cc_c89" in
5673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5674 $as_echo "none needed" >&6; } ;;
5675 xno)
5676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5677 $as_echo "unsupported" >&6; } ;;
5679 CC="$CC $ac_cv_prog_cc_c89"
5680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5681 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5682 esac
5683 if test "x$ac_cv_prog_cc_c89" != xno; then :
5687 ac_ext=c
5688 ac_cpp='$CPP $CPPFLAGS'
5689 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5690 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5691 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5692 DEPDIR="${am__leading_dot}deps"
5694 ac_config_commands="$ac_config_commands depfiles"
5697 am_make=${MAKE-make}
5698 cat > confinc << 'END'
5699 am__doit:
5700 @echo this is the am__doit target
5701 .PHONY: am__doit
5703 # If we don't find an include directive, just comment out the code.
5704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5705 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5706 am__include="#"
5707 am__quote=
5708 _am_result=none
5709 # First try GNU make style include.
5710 echo "include confinc" > confmf
5711 # Ignore all kinds of additional output from `make'.
5712 case `$am_make -s -f confmf 2> /dev/null` in #(
5713 *the\ am__doit\ target*)
5714 am__include=include
5715 am__quote=
5716 _am_result=GNU
5718 esac
5719 # Now try BSD make style include.
5720 if test "$am__include" = "#"; then
5721 echo '.include "confinc"' > confmf
5722 case `$am_make -s -f confmf 2> /dev/null` in #(
5723 *the\ am__doit\ target*)
5724 am__include=.include
5725 am__quote="\""
5726 _am_result=BSD
5728 esac
5732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5733 $as_echo "$_am_result" >&6; }
5734 rm -f confinc confmf
5736 # Check whether --enable-dependency-tracking was given.
5737 if test "${enable_dependency_tracking+set}" = set; then :
5738 enableval=$enable_dependency_tracking;
5741 if test "x$enable_dependency_tracking" != xno; then
5742 am_depcomp="$ac_aux_dir/depcomp"
5743 AMDEPBACKSLASH='\'
5745 if test "x$enable_dependency_tracking" != xno; then
5746 AMDEP_TRUE=
5747 AMDEP_FALSE='#'
5748 else
5749 AMDEP_TRUE='#'
5750 AMDEP_FALSE=
5755 depcc="$CC" am_compiler_list=
5757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5758 $as_echo_n "checking dependency style of $depcc... " >&6; }
5759 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5760 $as_echo_n "(cached) " >&6
5761 else
5762 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5763 # We make a subdir and do the tests there. Otherwise we can end up
5764 # making bogus files that we don't know about and never remove. For
5765 # instance it was reported that on HP-UX the gcc test will end up
5766 # making a dummy file named `D' -- because `-MD' means `put the output
5767 # in D'.
5768 mkdir conftest.dir
5769 # Copy depcomp to subdir because otherwise we won't find it if we're
5770 # using a relative directory.
5771 cp "$am_depcomp" conftest.dir
5772 cd conftest.dir
5773 # We will build objects and dependencies in a subdirectory because
5774 # it helps to detect inapplicable dependency modes. For instance
5775 # both Tru64's cc and ICC support -MD to output dependencies as a
5776 # side effect of compilation, but ICC will put the dependencies in
5777 # the current directory while Tru64 will put them in the object
5778 # directory.
5779 mkdir sub
5781 am_cv_CC_dependencies_compiler_type=none
5782 if test "$am_compiler_list" = ""; then
5783 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5785 am__universal=false
5786 case " $depcc " in #(
5787 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5788 esac
5790 for depmode in $am_compiler_list; do
5791 # Setup a source with many dependencies, because some compilers
5792 # like to wrap large dependency lists on column 80 (with \), and
5793 # we should not choose a depcomp mode which is confused by this.
5795 # We need to recreate these files for each test, as the compiler may
5796 # overwrite some of them when testing with obscure command lines.
5797 # This happens at least with the AIX C compiler.
5798 : > sub/conftest.c
5799 for i in 1 2 3 4 5 6; do
5800 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5801 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5802 # Solaris 8's {/usr,}/bin/sh.
5803 touch sub/conftst$i.h
5804 done
5805 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5807 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5808 # mode. It turns out that the SunPro C++ compiler does not properly
5809 # handle `-M -o', and we need to detect this. Also, some Intel
5810 # versions had trouble with output in subdirs
5811 am__obj=sub/conftest.${OBJEXT-o}
5812 am__minus_obj="-o $am__obj"
5813 case $depmode in
5814 gcc)
5815 # This depmode causes a compiler race in universal mode.
5816 test "$am__universal" = false || continue
5818 nosideeffect)
5819 # after this tag, mechanisms are not by side-effect, so they'll
5820 # only be used when explicitly requested
5821 if test "x$enable_dependency_tracking" = xyes; then
5822 continue
5823 else
5824 break
5827 msvisualcpp | msvcmsys)
5828 # This compiler won't grok `-c -o', but also, the minuso test has
5829 # not run yet. These depmodes are late enough in the game, and
5830 # so weak that their functioning should not be impacted.
5831 am__obj=conftest.${OBJEXT-o}
5832 am__minus_obj=
5834 none) break ;;
5835 esac
5836 if depmode=$depmode \
5837 source=sub/conftest.c object=$am__obj \
5838 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5839 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5840 >/dev/null 2>conftest.err &&
5841 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5842 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5843 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5844 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5845 # icc doesn't choke on unknown options, it will just issue warnings
5846 # or remarks (even with -Werror). So we grep stderr for any message
5847 # that says an option was ignored or not supported.
5848 # When given -MP, icc 7.0 and 7.1 complain thusly:
5849 # icc: Command line warning: ignoring option '-M'; no argument required
5850 # The diagnosis changed in icc 8.0:
5851 # icc: Command line remark: option '-MP' not supported
5852 if (grep 'ignoring option' conftest.err ||
5853 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5854 am_cv_CC_dependencies_compiler_type=$depmode
5855 break
5858 done
5860 cd ..
5861 rm -rf conftest.dir
5862 else
5863 am_cv_CC_dependencies_compiler_type=none
5867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5868 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5869 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5872 test "x$enable_dependency_tracking" != xno \
5873 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5874 am__fastdepCC_TRUE=
5875 am__fastdepCC_FALSE='#'
5876 else
5877 am__fastdepCC_TRUE='#'
5878 am__fastdepCC_FALSE=
5882 if test "x$CC" != xcc; then
5883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5884 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5885 else
5886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5887 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5889 set dummy $CC; ac_cc=`$as_echo "$2" |
5890 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5891 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5892 $as_echo_n "(cached) " >&6
5893 else
5894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5895 /* end confdefs.h. */
5898 main ()
5902 return 0;
5904 _ACEOF
5905 # Make sure it works both with $CC and with simple cc.
5906 # We do the test twice because some compilers refuse to overwrite an
5907 # existing .o file with -o, though they will create one.
5908 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5909 rm -f conftest2.*
5910 if { { 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 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5921 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5922 *) ac_try_echo=$ac_try;;
5923 esac
5924 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5925 $as_echo "$ac_try_echo"; } >&5
5926 (eval "$ac_try") 2>&5
5927 ac_status=$?
5928 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5929 test $ac_status = 0; };
5930 then
5931 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5932 if test "x$CC" != xcc; then
5933 # Test first that cc exists at all.
5934 if { ac_try='cc -c conftest.$ac_ext >&5'
5935 { { case "(($ac_try" in
5936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5937 *) ac_try_echo=$ac_try;;
5938 esac
5939 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5940 $as_echo "$ac_try_echo"; } >&5
5941 (eval "$ac_try") 2>&5
5942 ac_status=$?
5943 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5944 test $ac_status = 0; }; }; then
5945 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5946 rm -f conftest2.*
5947 if { { case "(($ac_try" in
5948 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5949 *) ac_try_echo=$ac_try;;
5950 esac
5951 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5952 $as_echo "$ac_try_echo"; } >&5
5953 (eval "$ac_try") 2>&5
5954 ac_status=$?
5955 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5956 test $ac_status = 0; } &&
5957 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5958 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5959 *) ac_try_echo=$ac_try;;
5960 esac
5961 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5962 $as_echo "$ac_try_echo"; } >&5
5963 (eval "$ac_try") 2>&5
5964 ac_status=$?
5965 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5966 test $ac_status = 0; };
5967 then
5968 # cc works too.
5970 else
5971 # cc exists but doesn't like -o.
5972 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5976 else
5977 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5979 rm -f core conftest*
5982 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5984 $as_echo "yes" >&6; }
5985 else
5986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5987 $as_echo "no" >&6; }
5989 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5993 # FIXME: we rely on the cache variable name because
5994 # there is no other way.
5995 set dummy $CC
5996 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5997 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5998 if test "$am_t" != yes; then
5999 # Losing compiler, so override with the script.
6000 # FIXME: It is wrong to rewrite CC.
6001 # But if we don't then we get into trouble of one sort or another.
6002 # A longer-term fix would be to have automake use am__CC in this case,
6003 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
6004 CC="$am_aux_dir/compile $CC"
6009 if test x$GCC = xyes; then
6010 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
6011 else
6012 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
6015 if test "x$opsys" = "xmingw32"; then
6016 BUILDING_FOR_WINDOWSNT_TRUE=
6017 BUILDING_FOR_WINDOWSNT_FALSE='#'
6018 else
6019 BUILDING_FOR_WINDOWSNT_TRUE='#'
6020 BUILDING_FOR_WINDOWSNT_FALSE=
6024 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
6025 # as we don't use them.
6027 # Avoid gnulib's threadlib module, as we do threads our own way.
6030 # Initialize gnulib right after choosing the compiler.
6032 ac_ext=c
6033 ac_cpp='$CPP $CPPFLAGS'
6034 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6035 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6036 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6038 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6039 # On Suns, sometimes $CPP names a directory.
6040 if test -n "$CPP" && test -d "$CPP"; then
6041 CPP=
6043 if test -z "$CPP"; then
6044 if test "${ac_cv_prog_CPP+set}" = set; then :
6045 $as_echo_n "(cached) " >&6
6046 else
6047 # Double quotes because CPP needs to be expanded
6048 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6050 ac_preproc_ok=false
6051 for ac_c_preproc_warn_flag in '' yes
6053 # Use a header file that comes with gcc, so configuring glibc
6054 # with a fresh cross-compiler works.
6055 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6056 # <limits.h> exists even on freestanding compilers.
6057 # On the NeXT, cc -E runs the code through the compiler's parser,
6058 # not just through cpp. "Syntax error" is here to catch this case.
6059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h. */
6061 #ifdef __STDC__
6062 # include <limits.h>
6063 #else
6064 # include <assert.h>
6065 #endif
6066 Syntax error
6067 _ACEOF
6068 if ac_fn_c_try_cpp "$LINENO"; then :
6070 else
6071 # Broken: fails on valid input.
6072 continue
6074 rm -f conftest.err conftest.$ac_ext
6076 # OK, works on sane cases. Now check whether nonexistent headers
6077 # can be detected and how.
6078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6079 /* end confdefs.h. */
6080 #include <ac_nonexistent.h>
6081 _ACEOF
6082 if ac_fn_c_try_cpp "$LINENO"; then :
6083 # Broken: success on invalid input.
6084 continue
6085 else
6086 # Passes both tests.
6087 ac_preproc_ok=:
6088 break
6090 rm -f conftest.err conftest.$ac_ext
6092 done
6093 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6094 rm -f conftest.err conftest.$ac_ext
6095 if $ac_preproc_ok; then :
6096 break
6099 done
6100 ac_cv_prog_CPP=$CPP
6103 CPP=$ac_cv_prog_CPP
6104 else
6105 ac_cv_prog_CPP=$CPP
6107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6108 $as_echo "$CPP" >&6; }
6109 ac_preproc_ok=false
6110 for ac_c_preproc_warn_flag in '' yes
6112 # Use a header file that comes with gcc, so configuring glibc
6113 # with a fresh cross-compiler works.
6114 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6115 # <limits.h> exists even on freestanding compilers.
6116 # On the NeXT, cc -E runs the code through the compiler's parser,
6117 # not just through cpp. "Syntax error" is here to catch this case.
6118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6119 /* end confdefs.h. */
6120 #ifdef __STDC__
6121 # include <limits.h>
6122 #else
6123 # include <assert.h>
6124 #endif
6125 Syntax error
6126 _ACEOF
6127 if ac_fn_c_try_cpp "$LINENO"; then :
6129 else
6130 # Broken: fails on valid input.
6131 continue
6133 rm -f conftest.err conftest.$ac_ext
6135 # OK, works on sane cases. Now check whether nonexistent headers
6136 # can be detected and how.
6137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6138 /* end confdefs.h. */
6139 #include <ac_nonexistent.h>
6140 _ACEOF
6141 if ac_fn_c_try_cpp "$LINENO"; then :
6142 # Broken: success on invalid input.
6143 continue
6144 else
6145 # Passes both tests.
6146 ac_preproc_ok=:
6147 break
6149 rm -f conftest.err conftest.$ac_ext
6151 done
6152 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6153 rm -f conftest.err conftest.$ac_ext
6154 if $ac_preproc_ok; then :
6156 else
6157 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6158 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6159 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6160 See \`config.log' for more details." "$LINENO" 5; }
6163 ac_ext=c
6164 ac_cpp='$CPP $CPPFLAGS'
6165 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6166 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6167 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6171 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6172 if test "${ac_cv_path_GREP+set}" = set; then :
6173 $as_echo_n "(cached) " >&6
6174 else
6175 if test -z "$GREP"; then
6176 ac_path_GREP_found=false
6177 # Loop through the user's path and test for each of PROGNAME-LIST
6178 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6179 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6181 IFS=$as_save_IFS
6182 test -z "$as_dir" && as_dir=.
6183 for ac_prog in grep ggrep; do
6184 for ac_exec_ext in '' $ac_executable_extensions; do
6185 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6186 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6187 # Check for GNU ac_path_GREP and select it if it is found.
6188 # Check for GNU $ac_path_GREP
6189 case `"$ac_path_GREP" --version 2>&1` in
6190 *GNU*)
6191 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6193 ac_count=0
6194 $as_echo_n 0123456789 >"conftest.in"
6195 while :
6197 cat "conftest.in" "conftest.in" >"conftest.tmp"
6198 mv "conftest.tmp" "conftest.in"
6199 cp "conftest.in" "conftest.nl"
6200 $as_echo 'GREP' >> "conftest.nl"
6201 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6202 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6203 as_fn_arith $ac_count + 1 && ac_count=$as_val
6204 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6205 # Best one so far, save it but keep looking for a better one
6206 ac_cv_path_GREP="$ac_path_GREP"
6207 ac_path_GREP_max=$ac_count
6209 # 10*(2^10) chars as input seems more than enough
6210 test $ac_count -gt 10 && break
6211 done
6212 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6213 esac
6215 $ac_path_GREP_found && break 3
6216 done
6217 done
6218 done
6219 IFS=$as_save_IFS
6220 if test -z "$ac_cv_path_GREP"; then
6221 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6223 else
6224 ac_cv_path_GREP=$GREP
6228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6229 $as_echo "$ac_cv_path_GREP" >&6; }
6230 GREP="$ac_cv_path_GREP"
6233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6234 $as_echo_n "checking for egrep... " >&6; }
6235 if test "${ac_cv_path_EGREP+set}" = set; then :
6236 $as_echo_n "(cached) " >&6
6237 else
6238 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6239 then ac_cv_path_EGREP="$GREP -E"
6240 else
6241 if test -z "$EGREP"; then
6242 ac_path_EGREP_found=false
6243 # Loop through the user's path and test for each of PROGNAME-LIST
6244 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6245 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6247 IFS=$as_save_IFS
6248 test -z "$as_dir" && as_dir=.
6249 for ac_prog in egrep; do
6250 for ac_exec_ext in '' $ac_executable_extensions; do
6251 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6252 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6253 # Check for GNU ac_path_EGREP and select it if it is found.
6254 # Check for GNU $ac_path_EGREP
6255 case `"$ac_path_EGREP" --version 2>&1` in
6256 *GNU*)
6257 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6259 ac_count=0
6260 $as_echo_n 0123456789 >"conftest.in"
6261 while :
6263 cat "conftest.in" "conftest.in" >"conftest.tmp"
6264 mv "conftest.tmp" "conftest.in"
6265 cp "conftest.in" "conftest.nl"
6266 $as_echo 'EGREP' >> "conftest.nl"
6267 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6268 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6269 as_fn_arith $ac_count + 1 && ac_count=$as_val
6270 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6271 # Best one so far, save it but keep looking for a better one
6272 ac_cv_path_EGREP="$ac_path_EGREP"
6273 ac_path_EGREP_max=$ac_count
6275 # 10*(2^10) chars as input seems more than enough
6276 test $ac_count -gt 10 && break
6277 done
6278 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6279 esac
6281 $ac_path_EGREP_found && break 3
6282 done
6283 done
6284 done
6285 IFS=$as_save_IFS
6286 if test -z "$ac_cv_path_EGREP"; then
6287 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6289 else
6290 ac_cv_path_EGREP=$EGREP
6295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6296 $as_echo "$ac_cv_path_EGREP" >&6; }
6297 EGREP="$ac_cv_path_EGREP"
6302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6303 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6304 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6305 $as_echo_n "(cached) " >&6
6306 else
6308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6309 /* end confdefs.h. */
6311 #ifdef __ACK__
6312 Amsterdam
6313 #endif
6315 _ACEOF
6316 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6317 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6318 gl_cv_c_amsterdam_compiler=yes
6319 else
6320 gl_cv_c_amsterdam_compiler=no
6322 rm -f conftest*
6326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6327 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6328 if test -z "$AR"; then
6329 if test $gl_cv_c_amsterdam_compiler = yes; then
6330 AR='cc -c.a'
6331 if test -z "$ARFLAGS"; then
6332 ARFLAGS='-o'
6334 else
6335 if test -n "$ac_tool_prefix"; then
6336 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6337 set dummy ${ac_tool_prefix}ar; ac_word=$2
6338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6339 $as_echo_n "checking for $ac_word... " >&6; }
6340 if test "${ac_cv_prog_AR+set}" = set; then :
6341 $as_echo_n "(cached) " >&6
6342 else
6343 if test -n "$AR"; then
6344 ac_cv_prog_AR="$AR" # Let the user override the test.
6345 else
6346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6347 for as_dir in $PATH
6349 IFS=$as_save_IFS
6350 test -z "$as_dir" && as_dir=.
6351 for ac_exec_ext in '' $ac_executable_extensions; do
6352 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6353 ac_cv_prog_AR="${ac_tool_prefix}ar"
6354 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6355 break 2
6357 done
6358 done
6359 IFS=$as_save_IFS
6363 AR=$ac_cv_prog_AR
6364 if test -n "$AR"; then
6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6366 $as_echo "$AR" >&6; }
6367 else
6368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6369 $as_echo "no" >&6; }
6374 if test -z "$ac_cv_prog_AR"; then
6375 ac_ct_AR=$AR
6376 # Extract the first word of "ar", so it can be a program name with args.
6377 set dummy ar; ac_word=$2
6378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6379 $as_echo_n "checking for $ac_word... " >&6; }
6380 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6381 $as_echo_n "(cached) " >&6
6382 else
6383 if test -n "$ac_ct_AR"; then
6384 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6385 else
6386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6387 for as_dir in $PATH
6389 IFS=$as_save_IFS
6390 test -z "$as_dir" && as_dir=.
6391 for ac_exec_ext in '' $ac_executable_extensions; do
6392 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6393 ac_cv_prog_ac_ct_AR="ar"
6394 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6395 break 2
6397 done
6398 done
6399 IFS=$as_save_IFS
6403 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6404 if test -n "$ac_ct_AR"; then
6405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6406 $as_echo "$ac_ct_AR" >&6; }
6407 else
6408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6409 $as_echo "no" >&6; }
6412 if test "x$ac_ct_AR" = x; then
6413 AR="ar"
6414 else
6415 case $cross_compiling:$ac_tool_warned in
6416 yes:)
6417 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6418 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6419 ac_tool_warned=yes ;;
6420 esac
6421 AR=$ac_ct_AR
6423 else
6424 AR="$ac_cv_prog_AR"
6427 if test -z "$ARFLAGS"; then
6428 ARFLAGS='cru'
6431 else
6432 if test -z "$ARFLAGS"; then
6433 ARFLAGS='cru'
6438 if test -z "$RANLIB"; then
6439 if test $gl_cv_c_amsterdam_compiler = yes; then
6440 RANLIB=':'
6441 else
6442 if test -n "$ac_tool_prefix"; then
6443 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6444 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6446 $as_echo_n "checking for $ac_word... " >&6; }
6447 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6448 $as_echo_n "(cached) " >&6
6449 else
6450 if test -n "$RANLIB"; then
6451 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6452 else
6453 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6454 for as_dir in $PATH
6456 IFS=$as_save_IFS
6457 test -z "$as_dir" && as_dir=.
6458 for ac_exec_ext in '' $ac_executable_extensions; do
6459 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6460 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6461 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6462 break 2
6464 done
6465 done
6466 IFS=$as_save_IFS
6470 RANLIB=$ac_cv_prog_RANLIB
6471 if test -n "$RANLIB"; then
6472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6473 $as_echo "$RANLIB" >&6; }
6474 else
6475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6476 $as_echo "no" >&6; }
6481 if test -z "$ac_cv_prog_RANLIB"; then
6482 ac_ct_RANLIB=$RANLIB
6483 # Extract the first word of "ranlib", so it can be a program name with args.
6484 set dummy ranlib; ac_word=$2
6485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6486 $as_echo_n "checking for $ac_word... " >&6; }
6487 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6488 $as_echo_n "(cached) " >&6
6489 else
6490 if test -n "$ac_ct_RANLIB"; then
6491 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6492 else
6493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6494 for as_dir in $PATH
6496 IFS=$as_save_IFS
6497 test -z "$as_dir" && as_dir=.
6498 for ac_exec_ext in '' $ac_executable_extensions; do
6499 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6500 ac_cv_prog_ac_ct_RANLIB="ranlib"
6501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6502 break 2
6504 done
6505 done
6506 IFS=$as_save_IFS
6510 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6511 if test -n "$ac_ct_RANLIB"; then
6512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6513 $as_echo "$ac_ct_RANLIB" >&6; }
6514 else
6515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6516 $as_echo "no" >&6; }
6519 if test "x$ac_ct_RANLIB" = x; then
6520 RANLIB=":"
6521 else
6522 case $cross_compiling:$ac_tool_warned in
6523 yes:)
6524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6525 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6526 ac_tool_warned=yes ;;
6527 esac
6528 RANLIB=$ac_ct_RANLIB
6530 else
6531 RANLIB="$ac_cv_prog_RANLIB"
6538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6539 $as_echo_n "checking for ANSI C header files... " >&6; }
6540 if test "${ac_cv_header_stdc+set}" = set; then :
6541 $as_echo_n "(cached) " >&6
6542 else
6543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6544 /* end confdefs.h. */
6545 #include <stdlib.h>
6546 #include <stdarg.h>
6547 #include <string.h>
6548 #include <float.h>
6551 main ()
6555 return 0;
6557 _ACEOF
6558 if ac_fn_c_try_compile "$LINENO"; then :
6559 ac_cv_header_stdc=yes
6560 else
6561 ac_cv_header_stdc=no
6563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6565 if test $ac_cv_header_stdc = yes; then
6566 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6568 /* end confdefs.h. */
6569 #include <string.h>
6571 _ACEOF
6572 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6573 $EGREP "memchr" >/dev/null 2>&1; then :
6575 else
6576 ac_cv_header_stdc=no
6578 rm -f conftest*
6582 if test $ac_cv_header_stdc = yes; then
6583 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6585 /* end confdefs.h. */
6586 #include <stdlib.h>
6588 _ACEOF
6589 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6590 $EGREP "free" >/dev/null 2>&1; then :
6592 else
6593 ac_cv_header_stdc=no
6595 rm -f conftest*
6599 if test $ac_cv_header_stdc = yes; then
6600 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6601 if test "$cross_compiling" = yes; then :
6603 else
6604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6605 /* end confdefs.h. */
6606 #include <ctype.h>
6607 #include <stdlib.h>
6608 #if ((' ' & 0x0FF) == 0x020)
6609 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6610 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6611 #else
6612 # define ISLOWER(c) \
6613 (('a' <= (c) && (c) <= 'i') \
6614 || ('j' <= (c) && (c) <= 'r') \
6615 || ('s' <= (c) && (c) <= 'z'))
6616 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6617 #endif
6619 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6621 main ()
6623 int i;
6624 for (i = 0; i < 256; i++)
6625 if (XOR (islower (i), ISLOWER (i))
6626 || toupper (i) != TOUPPER (i))
6627 return 2;
6628 return 0;
6630 _ACEOF
6631 if ac_fn_c_try_run "$LINENO"; then :
6633 else
6634 ac_cv_header_stdc=no
6636 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6637 conftest.$ac_objext conftest.beam conftest.$ac_ext
6642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6643 $as_echo "$ac_cv_header_stdc" >&6; }
6644 if test $ac_cv_header_stdc = yes; then
6646 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6650 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6651 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6652 inttypes.h stdint.h unistd.h
6653 do :
6654 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6655 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6657 eval as_val=\$$as_ac_Header
6658 if test "x$as_val" = x""yes; then :
6659 cat >>confdefs.h <<_ACEOF
6660 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6661 _ACEOF
6665 done
6669 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6670 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6671 MINIX=yes
6672 else
6673 MINIX=
6677 if test "$MINIX" = yes; then
6679 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6682 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6685 $as_echo "#define _MINIX 1" >>confdefs.h
6688 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6694 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6695 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6696 $as_echo_n "(cached) " >&6
6697 else
6698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6699 /* end confdefs.h. */
6701 # define __EXTENSIONS__ 1
6702 $ac_includes_default
6704 main ()
6708 return 0;
6710 _ACEOF
6711 if ac_fn_c_try_compile "$LINENO"; then :
6712 ac_cv_safe_to_define___extensions__=yes
6713 else
6714 ac_cv_safe_to_define___extensions__=no
6716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6719 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6720 test $ac_cv_safe_to_define___extensions__ = yes &&
6721 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6723 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6725 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6727 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6729 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6731 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6734 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6735 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6736 $as_echo_n "(cached) " >&6
6737 else
6738 ac_cv_should_define__xopen_source=no
6739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6740 /* end confdefs.h. */
6742 #include <wchar.h>
6743 mbstate_t x;
6745 main ()
6749 return 0;
6751 _ACEOF
6752 if ac_fn_c_try_compile "$LINENO"; then :
6754 else
6755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6756 /* end confdefs.h. */
6758 #define _XOPEN_SOURCE 500
6759 #include <wchar.h>
6760 mbstate_t x;
6762 main ()
6766 return 0;
6768 _ACEOF
6769 if ac_fn_c_try_compile "$LINENO"; then :
6770 ac_cv_should_define__xopen_source=yes
6772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6777 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6778 test $ac_cv_should_define__xopen_source = yes &&
6779 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6788 # Check whether --enable-largefile was given.
6789 if test "${enable_largefile+set}" = set; then :
6790 enableval=$enable_largefile;
6793 if test "$enable_largefile" != no; then
6795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6796 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6797 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6798 $as_echo_n "(cached) " >&6
6799 else
6800 ac_cv_sys_largefile_CC=no
6801 if test "$GCC" != yes; then
6802 ac_save_CC=$CC
6803 while :; do
6804 # IRIX 6.2 and later do not support large files by default,
6805 # so use the C compiler's -n32 option if that helps.
6806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6807 /* end confdefs.h. */
6808 #include <sys/types.h>
6809 /* Check that off_t can represent 2**63 - 1 correctly.
6810 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6811 since some C++ compilers masquerading as C compilers
6812 incorrectly reject 9223372036854775807. */
6813 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6814 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6815 && LARGE_OFF_T % 2147483647 == 1)
6816 ? 1 : -1];
6818 main ()
6822 return 0;
6824 _ACEOF
6825 if ac_fn_c_try_compile "$LINENO"; then :
6826 break
6828 rm -f core conftest.err conftest.$ac_objext
6829 CC="$CC -n32"
6830 if ac_fn_c_try_compile "$LINENO"; then :
6831 ac_cv_sys_largefile_CC=' -n32'; break
6833 rm -f core conftest.err conftest.$ac_objext
6834 break
6835 done
6836 CC=$ac_save_CC
6837 rm -f conftest.$ac_ext
6840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6841 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6842 if test "$ac_cv_sys_largefile_CC" != no; then
6843 CC=$CC$ac_cv_sys_largefile_CC
6846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6847 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6848 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6849 $as_echo_n "(cached) " >&6
6850 else
6851 while :; do
6852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6853 /* end confdefs.h. */
6854 #include <sys/types.h>
6855 /* Check that off_t can represent 2**63 - 1 correctly.
6856 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6857 since some C++ compilers masquerading as C compilers
6858 incorrectly reject 9223372036854775807. */
6859 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6860 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6861 && LARGE_OFF_T % 2147483647 == 1)
6862 ? 1 : -1];
6864 main ()
6868 return 0;
6870 _ACEOF
6871 if ac_fn_c_try_compile "$LINENO"; then :
6872 ac_cv_sys_file_offset_bits=no; break
6874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6876 /* end confdefs.h. */
6877 #define _FILE_OFFSET_BITS 64
6878 #include <sys/types.h>
6879 /* Check that off_t can represent 2**63 - 1 correctly.
6880 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6881 since some C++ compilers masquerading as C compilers
6882 incorrectly reject 9223372036854775807. */
6883 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6884 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6885 && LARGE_OFF_T % 2147483647 == 1)
6886 ? 1 : -1];
6888 main ()
6892 return 0;
6894 _ACEOF
6895 if ac_fn_c_try_compile "$LINENO"; then :
6896 ac_cv_sys_file_offset_bits=64; break
6898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6899 ac_cv_sys_file_offset_bits=unknown
6900 break
6901 done
6903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6904 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6905 case $ac_cv_sys_file_offset_bits in #(
6906 no | unknown) ;;
6908 cat >>confdefs.h <<_ACEOF
6909 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6910 _ACEOF
6912 esac
6913 rm -rf conftest*
6914 if test $ac_cv_sys_file_offset_bits = unknown; then
6915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6916 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6917 if test "${ac_cv_sys_large_files+set}" = set; then :
6918 $as_echo_n "(cached) " >&6
6919 else
6920 while :; do
6921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6922 /* end confdefs.h. */
6923 #include <sys/types.h>
6924 /* Check that off_t can represent 2**63 - 1 correctly.
6925 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6926 since some C++ compilers masquerading as C compilers
6927 incorrectly reject 9223372036854775807. */
6928 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6929 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6930 && LARGE_OFF_T % 2147483647 == 1)
6931 ? 1 : -1];
6933 main ()
6937 return 0;
6939 _ACEOF
6940 if ac_fn_c_try_compile "$LINENO"; then :
6941 ac_cv_sys_large_files=no; break
6943 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6945 /* end confdefs.h. */
6946 #define _LARGE_FILES 1
6947 #include <sys/types.h>
6948 /* Check that off_t can represent 2**63 - 1 correctly.
6949 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6950 since some C++ compilers masquerading as C compilers
6951 incorrectly reject 9223372036854775807. */
6952 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6953 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6954 && LARGE_OFF_T % 2147483647 == 1)
6955 ? 1 : -1];
6957 main ()
6961 return 0;
6963 _ACEOF
6964 if ac_fn_c_try_compile "$LINENO"; then :
6965 ac_cv_sys_large_files=1; break
6967 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6968 ac_cv_sys_large_files=unknown
6969 break
6970 done
6972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6973 $as_echo "$ac_cv_sys_large_files" >&6; }
6974 case $ac_cv_sys_large_files in #(
6975 no | unknown) ;;
6977 cat >>confdefs.h <<_ACEOF
6978 #define _LARGE_FILES $ac_cv_sys_large_files
6979 _ACEOF
6981 esac
6982 rm -rf conftest*
6986 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6990 case $ac_cv_prog_cc_stdc in #(
6991 no) :
6992 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6993 *) :
6994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6995 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6996 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6997 $as_echo_n "(cached) " >&6
6998 else
6999 ac_cv_prog_cc_c99=no
7000 ac_save_CC=$CC
7001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7002 /* end confdefs.h. */
7003 #include <stdarg.h>
7004 #include <stdbool.h>
7005 #include <stdlib.h>
7006 #include <wchar.h>
7007 #include <stdio.h>
7009 // Check varargs macros. These examples are taken from C99 6.10.3.5.
7010 #define debug(...) fprintf (stderr, __VA_ARGS__)
7011 #define showlist(...) puts (#__VA_ARGS__)
7012 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
7013 static void
7014 test_varargs_macros (void)
7016 int x = 1234;
7017 int y = 5678;
7018 debug ("Flag");
7019 debug ("X = %d\n", x);
7020 showlist (The first, second, and third items.);
7021 report (x>y, "x is %d but y is %d", x, y);
7024 // Check long long types.
7025 #define BIG64 18446744073709551615ull
7026 #define BIG32 4294967295ul
7027 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
7028 #if !BIG_OK
7029 your preprocessor is broken;
7030 #endif
7031 #if BIG_OK
7032 #else
7033 your preprocessor is broken;
7034 #endif
7035 static long long int bignum = -9223372036854775807LL;
7036 static unsigned long long int ubignum = BIG64;
7038 struct incomplete_array
7040 int datasize;
7041 double data[];
7044 struct named_init {
7045 int number;
7046 const wchar_t *name;
7047 double average;
7050 typedef const char *ccp;
7052 static inline int
7053 test_restrict (ccp restrict text)
7055 // See if C++-style comments work.
7056 // Iterate through items via the restricted pointer.
7057 // Also check for declarations in for loops.
7058 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7059 continue;
7060 return 0;
7063 // Check varargs and va_copy.
7064 static void
7065 test_varargs (const char *format, ...)
7067 va_list args;
7068 va_start (args, format);
7069 va_list args_copy;
7070 va_copy (args_copy, args);
7072 const char *str;
7073 int number;
7074 float fnumber;
7076 while (*format)
7078 switch (*format++)
7080 case 's': // string
7081 str = va_arg (args_copy, const char *);
7082 break;
7083 case 'd': // int
7084 number = va_arg (args_copy, int);
7085 break;
7086 case 'f': // float
7087 fnumber = va_arg (args_copy, double);
7088 break;
7089 default:
7090 break;
7093 va_end (args_copy);
7094 va_end (args);
7098 main ()
7101 // Check bool.
7102 _Bool success = false;
7104 // Check restrict.
7105 if (test_restrict ("String literal") == 0)
7106 success = true;
7107 char *restrict newvar = "Another string";
7109 // Check varargs.
7110 test_varargs ("s, d' f .", "string", 65, 34.234);
7111 test_varargs_macros ();
7113 // Check flexible array members.
7114 struct incomplete_array *ia =
7115 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7116 ia->datasize = 10;
7117 for (int i = 0; i < ia->datasize; ++i)
7118 ia->data[i] = i * 1.234;
7120 // Check named initializers.
7121 struct named_init ni = {
7122 .number = 34,
7123 .name = L"Test wide string",
7124 .average = 543.34343,
7127 ni.number = 58;
7129 int dynamic_array[ni.number];
7130 dynamic_array[ni.number - 1] = 543;
7132 // work around unused variable warnings
7133 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7134 || dynamic_array[ni.number - 1] != 543);
7137 return 0;
7139 _ACEOF
7140 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7142 CC="$ac_save_CC $ac_arg"
7143 if ac_fn_c_try_compile "$LINENO"; then :
7144 ac_cv_prog_cc_c99=$ac_arg
7146 rm -f core conftest.err conftest.$ac_objext
7147 test "x$ac_cv_prog_cc_c99" != "xno" && break
7148 done
7149 rm -f conftest.$ac_ext
7150 CC=$ac_save_CC
7153 # AC_CACHE_VAL
7154 case "x$ac_cv_prog_cc_c99" in
7156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7157 $as_echo "none needed" >&6; } ;;
7158 xno)
7159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7160 $as_echo "unsupported" >&6; } ;;
7162 CC="$CC $ac_cv_prog_cc_c99"
7163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7164 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7165 esac
7166 if test "x$ac_cv_prog_cc_c99" != xno; then :
7167 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7168 else
7169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7170 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7171 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7172 $as_echo_n "(cached) " >&6
7173 else
7174 ac_cv_prog_cc_c89=no
7175 ac_save_CC=$CC
7176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7177 /* end confdefs.h. */
7178 #include <stdarg.h>
7179 #include <stdio.h>
7180 #include <sys/types.h>
7181 #include <sys/stat.h>
7182 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7183 struct buf { int x; };
7184 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7185 static char *e (p, i)
7186 char **p;
7187 int i;
7189 return p[i];
7191 static char *f (char * (*g) (char **, int), char **p, ...)
7193 char *s;
7194 va_list v;
7195 va_start (v,p);
7196 s = g (p, va_arg (v,int));
7197 va_end (v);
7198 return s;
7201 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7202 function prototypes and stuff, but not '\xHH' hex character constants.
7203 These don't provoke an error unfortunately, instead are silently treated
7204 as 'x'. The following induces an error, until -std is added to get
7205 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7206 array size at least. It's necessary to write '\x00'==0 to get something
7207 that's true only with -std. */
7208 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7210 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7211 inside strings and character constants. */
7212 #define FOO(x) 'x'
7213 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7215 int test (int i, double x);
7216 struct s1 {int (*f) (int a);};
7217 struct s2 {int (*f) (double a);};
7218 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7219 int argc;
7220 char **argv;
7222 main ()
7224 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7226 return 0;
7228 _ACEOF
7229 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7230 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7232 CC="$ac_save_CC $ac_arg"
7233 if ac_fn_c_try_compile "$LINENO"; then :
7234 ac_cv_prog_cc_c89=$ac_arg
7236 rm -f core conftest.err conftest.$ac_objext
7237 test "x$ac_cv_prog_cc_c89" != "xno" && break
7238 done
7239 rm -f conftest.$ac_ext
7240 CC=$ac_save_CC
7243 # AC_CACHE_VAL
7244 case "x$ac_cv_prog_cc_c89" in
7246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7247 $as_echo "none needed" >&6; } ;;
7248 xno)
7249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7250 $as_echo "unsupported" >&6; } ;;
7252 CC="$CC $ac_cv_prog_cc_c89"
7253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7254 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7255 esac
7256 if test "x$ac_cv_prog_cc_c89" != xno; then :
7257 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7258 else
7259 ac_cv_prog_cc_stdc=no
7264 esac
7265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7266 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7267 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7268 $as_echo_n "(cached) " >&6
7271 case $ac_cv_prog_cc_stdc in #(
7272 no) :
7273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7274 $as_echo "unsupported" >&6; } ;; #(
7275 '') :
7276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7277 $as_echo "none needed" >&6; } ;; #(
7278 *) :
7279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7280 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7281 esac
7285 # Code from module alloca-opt:
7286 # Code from module allocator:
7287 # Code from module at-internal:
7288 # Code from module binary-io:
7289 # Code from module c-ctype:
7290 # Code from module c-strcase:
7291 # Code from module careadlinkat:
7292 # Code from module clock-time:
7293 # Code from module close-stream:
7294 # Code from module crypto/md5:
7295 # Code from module crypto/sha1:
7296 # Code from module crypto/sha256:
7297 # Code from module crypto/sha512:
7298 # Code from module dirent:
7299 # Code from module dosname:
7300 # Code from module dtoastr:
7301 # Code from module dtotimespec:
7302 # Code from module dup2:
7303 # Code from module environ:
7304 # Code from module errno:
7305 # Code from module euidaccess:
7306 # Code from module execinfo:
7307 # Code from module extensions:
7309 # Code from module extern-inline:
7310 # Code from module faccessat:
7311 # Code from module fcntl:
7312 # Code from module fcntl-h:
7313 # Code from module fdatasync:
7314 # Code from module fdopendir:
7315 # Code from module filemode:
7316 # Code from module fpending:
7317 # Code from module fstatat:
7318 # Code from module fsync:
7319 # Code from module getdtablesize:
7320 # Code from module getgroups:
7321 # Code from module getloadavg:
7322 # Code from module getopt-gnu:
7323 # Code from module getopt-posix:
7324 # Code from module gettext-h:
7325 # Code from module gettime:
7326 # Code from module gettimeofday:
7327 # Code from module group-member:
7328 # Code from module include_next:
7329 # Code from module intprops:
7330 # Code from module inttypes-incomplete:
7331 # Code from module largefile:
7333 # Code from module lstat:
7334 # Code from module manywarnings:
7335 # Code from module memrchr:
7336 # Code from module mkostemp:
7337 # Code from module mktime:
7338 # Code from module multiarch:
7339 # Code from module nocrash:
7340 # Code from module openat-h:
7341 # Code from module pathmax:
7342 # Code from module pipe2:
7343 # Code from module pselect:
7344 # Code from module pthread_sigmask:
7345 # Code from module putenv:
7346 # Code from module qacl:
7347 # Code from module readlink:
7348 # Code from module readlinkat:
7349 # Code from module root-uid:
7350 # Code from module secure_getenv:
7351 # Code from module sig2str:
7352 # Code from module signal-h:
7353 # Code from module snippet/_Noreturn:
7354 # Code from module snippet/arg-nonnull:
7355 # Code from module snippet/c++defs:
7356 # Code from module snippet/warn-on-use:
7357 # Code from module socklen:
7358 # Code from module ssize_t:
7359 # Code from module stat:
7360 # Code from module stat-time:
7361 # Code from module stdalign:
7362 # Code from module stdarg:
7366 # Code from module stdbool:
7367 # Code from module stddef:
7368 # Code from module stdint:
7369 # Code from module stdio:
7370 # Code from module stdlib:
7371 # Code from module strftime:
7372 # Code from module string:
7373 # Code from module strtoimax:
7374 # Code from module strtoll:
7375 # Code from module strtoull:
7376 # Code from module strtoumax:
7377 # Code from module symlink:
7378 # Code from module sys_select:
7379 # Code from module sys_stat:
7380 # Code from module sys_time:
7381 # Code from module tempname:
7382 # Code from module time:
7383 # Code from module time_r:
7384 # Code from module timer-time:
7385 # Code from module timespec:
7386 # Code from module timespec-add:
7387 # Code from module timespec-sub:
7388 # Code from module u64:
7389 # Code from module unistd:
7390 # Code from module unsetenv:
7391 # Code from module utimens:
7392 # Code from module verify:
7393 # Code from module warnings:
7394 # Code from module xalloc-oversized:
7397 if test "$ac_test_CFLAGS" != set; then
7398 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7399 # if -g3 works and the user does not specify CFLAGS.
7400 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7401 case $CFLAGS in
7402 '-g')
7403 emacs_g3_CFLAGS='-g3';;
7404 '-g -O2')
7405 emacs_g3_CFLAGS='-g3 -O2';;
7407 emacs_g3_CFLAGS='';;
7408 esac
7409 if test -n "$emacs_g3_CFLAGS"; then
7410 emacs_save_CFLAGS=$CFLAGS
7411 CFLAGS=$emacs_g3_CFLAGS
7412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7413 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7414 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7415 $as_echo_n "(cached) " >&6
7416 else
7417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7418 /* end confdefs.h. */
7421 main ()
7425 return 0;
7427 _ACEOF
7428 if ac_fn_c_try_link "$LINENO"; then :
7429 emacs_cv_prog_cc_g3=yes
7430 else
7431 emacs_cv_prog_cc_g3=no
7433 rm -f core conftest.err conftest.$ac_objext \
7434 conftest$ac_exeext conftest.$ac_ext
7436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7437 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7438 if test $emacs_cv_prog_cc_g3 != yes; then
7439 CFLAGS=$emacs_save_CFLAGS
7441 if test $opsys = mingw32; then
7442 CFLAGS="$CFLAGS -gdwarf-2"
7446 case $CFLAGS in
7447 *-O*) ;;
7449 # No optimization flag was inferred for this non-GCC compiler.
7450 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7451 emacs_save_CFLAGS=$CFLAGS
7452 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7453 CFLAGS=${CFLAGS}-O
7454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7455 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7456 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7457 $as_echo_n "(cached) " >&6
7458 else
7459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7460 /* end confdefs.h. */
7463 main ()
7467 return 0;
7469 _ACEOF
7470 if ac_fn_c_try_link "$LINENO"; then :
7471 emacs_cv_prog_cc_o=yes
7472 else
7473 emacs_cv_prog_cc_o=no
7475 rm -f core conftest.err conftest.$ac_objext \
7476 conftest$ac_exeext conftest.$ac_ext
7478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7479 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7480 if test $emacs_cv_prog_cc_o != yes; then
7481 CFLAGS=$emacs_save_CFLAGS
7482 fi ;;
7483 esac
7486 # Check whether --enable-gcc-warnings was given.
7487 if test "${enable_gcc_warnings+set}" = set; then :
7488 enableval=$enable_gcc_warnings; case $enableval in
7489 yes|no) ;;
7490 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7491 esac
7492 gl_gcc_warnings=$enableval
7493 else
7494 gl_gcc_warnings=no
7499 # Check whether --enable-link-time-optimization was given.
7500 if test "${enable_link_time_optimization+set}" = set; then :
7501 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7503 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7504 ac_lto_supported=no
7505 if test x$GCC = xyes; then
7506 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7507 if test x$CPUS != x; then
7508 LTO="-flto=$CPUS"
7509 else
7510 LTO="-flto"
7512 old_CFLAGS=$CFLAGS
7513 CFLAGS="$CFLAGS $LTO"
7514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7515 /* end confdefs.h. */
7518 main ()
7522 return 0;
7524 _ACEOF
7525 if ac_fn_c_try_compile "$LINENO"; then :
7526 ac_lto_supported=yes
7527 else
7528 ac_lto_supported=no
7530 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7531 CFLAGS="$old_CFLAGS"
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7534 $as_echo "$ac_lto_supported" >&6; }
7535 if test "$ac_lto_supported" = "yes"; then
7536 CFLAGS="$CFLAGS $LTO"
7542 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7543 # ------------------------------------------------
7544 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7545 # Otherwise, run RUN-IF-NOT-FOUND.
7548 # When compiling with GCC, prefer -isystem to -I when including system
7549 # include files, to avoid generating useless diagnostics for the files.
7550 if test "$gl_gcc_warnings" != yes; then
7551 isystem='-I'
7552 else
7553 isystem='-isystem '
7555 # This, $nw, is the list of warnings we disable.
7558 case $with_x_toolkit in
7559 lucid | athena | motif)
7560 # Old toolkits mishandle 'const'.
7561 nw="$nw -Wwrite-strings"
7564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7565 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7566 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7567 $as_echo_n "(cached) " >&6
7568 else
7570 gl_save_compiler_FLAGS="$CFLAGS"
7571 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7573 /* end confdefs.h. */
7576 main ()
7580 return 0;
7582 _ACEOF
7583 if ac_fn_c_try_compile "$LINENO"; then :
7584 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7585 else
7586 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7589 CFLAGS="$gl_save_compiler_FLAGS"
7592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7593 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7594 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7595 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7596 else
7597 gl_unknown_warnings_are_errors=
7601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7602 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7603 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7604 $as_echo_n "(cached) " >&6
7605 else
7607 gl_save_compiler_FLAGS="$CFLAGS"
7608 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7610 /* end confdefs.h. */
7613 main ()
7617 return 0;
7619 _ACEOF
7620 if ac_fn_c_try_compile "$LINENO"; then :
7621 gl_cv_warn_c__Werror=yes
7622 else
7623 gl_cv_warn_c__Werror=no
7625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7626 CFLAGS="$gl_save_compiler_FLAGS"
7629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7630 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7631 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7632 as_fn_append WERROR_CFLAGS " -Werror"
7637 esac
7640 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7641 nw="$nw -Woverlength-strings" # Not a problem these days
7642 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7643 nw="$nw -Wformat-nonliteral" # we do this a lot
7644 nw="$nw -Wvla" # warnings in gettext.h
7645 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7646 nw="$nw -Wswitch-default" # Too many warnings for now
7647 nw="$nw -Winline" # OK to ignore 'inline'
7648 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7649 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7650 # signed overflow has undefined behavior
7651 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7652 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7653 nw="$nw -Wbad-function-cast" # These casts are no worse than others.
7655 # Emacs doesn't care about shadowing; see
7656 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7657 nw="$nw -Wshadow"
7659 # Emacs's use of alloca inhibits protecting the stack.
7660 nw="$nw -Wstack-protector"
7662 # The following line should be removable at some point.
7663 nw="$nw -Wsuggest-attribute=pure"
7665 # This part is merely for shortening the command line,
7666 # since -Wno-FOO needs to be added below regardless.
7667 nw="$nw -Wmissing-field-initializers"
7668 nw="$nw -Wswitch"
7669 nw="$nw -Wtype-limits"
7670 nw="$nw -Wunused-parameter"
7672 # clang is unduly picky about some things.
7673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7674 $as_echo_n "checking whether the compiler is clang... " >&6; }
7675 if test "${emacs_cv_clang+set}" = set; then :
7676 $as_echo_n "(cached) " >&6
7677 else
7678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7679 /* end confdefs.h. */
7681 #ifndef __clang__
7682 #error "not clang"
7683 #endif
7686 main ()
7690 return 0;
7692 _ACEOF
7693 if ac_fn_c_try_compile "$LINENO"; then :
7694 emacs_cv_clang=yes
7695 else
7696 emacs_cv_clang=no
7698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7701 $as_echo "$emacs_cv_clang" >&6; }
7702 if test $emacs_cv_clang = yes; then
7703 nw="$nw -Wcast-align"
7708 if test -n "$GCC"; then
7710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7711 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7712 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7713 $as_echo_n "(cached) " >&6
7714 else
7716 gl_save_CFLAGS="$CFLAGS"
7717 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7719 /* end confdefs.h. */
7722 main ()
7726 return 0;
7728 _ACEOF
7729 if ac_fn_c_try_compile "$LINENO"; then :
7730 gl_cv_cc_nomfi_supported=yes
7731 else
7732 gl_cv_cc_nomfi_supported=no
7734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7735 CFLAGS="$gl_save_CFLAGS"
7738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7739 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7741 if test "$gl_cv_cc_nomfi_supported" = yes; then
7742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7743 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7744 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7745 $as_echo_n "(cached) " >&6
7746 else
7748 gl_save_CFLAGS="$CFLAGS"
7749 CFLAGS="$CFLAGS -W -Werror"
7750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7751 /* end confdefs.h. */
7752 void f (void)
7754 typedef struct { int a; int b; } s_t;
7755 s_t s1 = { 0, };
7759 main ()
7763 return 0;
7765 _ACEOF
7766 if ac_fn_c_try_compile "$LINENO"; then :
7767 gl_cv_cc_nomfi_needed=no
7768 else
7769 gl_cv_cc_nomfi_needed=yes
7771 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7772 CFLAGS="$gl_save_CFLAGS"
7776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7777 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7781 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7782 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7783 $as_echo_n "(cached) " >&6
7784 else
7786 gl_save_CFLAGS="$CFLAGS"
7787 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7789 /* end confdefs.h. */
7792 main ()
7796 return 0;
7798 _ACEOF
7799 if ac_fn_c_try_compile "$LINENO"; then :
7800 gl_cv_cc_uninitialized_supported=yes
7801 else
7802 gl_cv_cc_uninitialized_supported=no
7804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7805 CFLAGS="$gl_save_CFLAGS"
7808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7809 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7813 # List all gcc warning categories.
7814 gl_manywarn_set=
7815 for gl_manywarn_item in \
7816 -W \
7817 -Wabi \
7818 -Waddress \
7819 -Waggressive-loop-optimizations \
7820 -Wall \
7821 -Warray-bounds \
7822 -Wattributes \
7823 -Wbad-function-cast \
7824 -Wbuiltin-macro-redefined \
7825 -Wcast-align \
7826 -Wchar-subscripts \
7827 -Wclobbered \
7828 -Wcomment \
7829 -Wcomments \
7830 -Wcoverage-mismatch \
7831 -Wcpp \
7832 -Wdeprecated \
7833 -Wdeprecated-declarations \
7834 -Wdisabled-optimization \
7835 -Wdiv-by-zero \
7836 -Wdouble-promotion \
7837 -Wempty-body \
7838 -Wendif-labels \
7839 -Wenum-compare \
7840 -Wextra \
7841 -Wformat-contains-nul \
7842 -Wformat-extra-args \
7843 -Wformat-nonliteral \
7844 -Wformat-security \
7845 -Wformat-y2k \
7846 -Wformat-zero-length \
7847 -Wfree-nonheap-object \
7848 -Wignored-qualifiers \
7849 -Wimplicit \
7850 -Wimplicit-function-declaration \
7851 -Wimplicit-int \
7852 -Winit-self \
7853 -Winline \
7854 -Wint-to-pointer-cast \
7855 -Winvalid-memory-model \
7856 -Winvalid-pch \
7857 -Wjump-misses-init \
7858 -Wlogical-op \
7859 -Wmain \
7860 -Wmaybe-uninitialized \
7861 -Wmissing-braces \
7862 -Wmissing-declarations \
7863 -Wmissing-field-initializers \
7864 -Wmissing-include-dirs \
7865 -Wmissing-parameter-type \
7866 -Wmissing-prototypes \
7867 -Wmudflap \
7868 -Wmultichar \
7869 -Wnarrowing \
7870 -Wnested-externs \
7871 -Wnonnull \
7872 -Wnormalized=nfc \
7873 -Wold-style-declaration \
7874 -Wold-style-definition \
7875 -Woverflow \
7876 -Woverlength-strings \
7877 -Woverride-init \
7878 -Wpacked \
7879 -Wpacked-bitfield-compat \
7880 -Wparentheses \
7881 -Wpointer-arith \
7882 -Wpointer-sign \
7883 -Wpointer-to-int-cast \
7884 -Wpragmas \
7885 -Wreturn-local-addr \
7886 -Wreturn-type \
7887 -Wsequence-point \
7888 -Wshadow \
7889 -Wsizeof-pointer-memaccess \
7890 -Wstack-protector \
7891 -Wstrict-aliasing \
7892 -Wstrict-overflow \
7893 -Wstrict-prototypes \
7894 -Wsuggest-attribute=const \
7895 -Wsuggest-attribute=format \
7896 -Wsuggest-attribute=noreturn \
7897 -Wsuggest-attribute=pure \
7898 -Wswitch \
7899 -Wswitch-default \
7900 -Wsync-nand \
7901 -Wsystem-headers \
7902 -Wtrampolines \
7903 -Wtrigraphs \
7904 -Wtype-limits \
7905 -Wuninitialized \
7906 -Wunknown-pragmas \
7907 -Wunsafe-loop-optimizations \
7908 -Wunused \
7909 -Wunused-but-set-parameter \
7910 -Wunused-but-set-variable \
7911 -Wunused-function \
7912 -Wunused-label \
7913 -Wunused-local-typedefs \
7914 -Wunused-macros \
7915 -Wunused-parameter \
7916 -Wunused-result \
7917 -Wunused-value \
7918 -Wunused-variable \
7919 -Wvarargs \
7920 -Wvariadic-macros \
7921 -Wvector-operation-performance \
7922 -Wvla \
7923 -Wvolatile-register-var \
7924 -Wwrite-strings \
7926 ; do
7927 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7928 done
7930 # Disable specific options as needed.
7931 if test "$gl_cv_cc_nomfi_needed" = yes; then
7932 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7935 if test "$gl_cv_cc_uninitialized_supported" = no; then
7936 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7939 ws=$gl_manywarn_set
7942 gl_warn_set=
7943 set x $ws; shift
7944 for gl_warn_item
7946 case " $nw " in
7947 *" $gl_warn_item "*)
7950 gl_warn_set="$gl_warn_set $gl_warn_item"
7952 esac
7953 done
7954 ws=$gl_warn_set
7956 for w in $ws; do
7958 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7959 gl_positive="$w"
7960 case $gl_positive in
7961 -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
7962 esac
7963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7964 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7965 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7966 $as_echo_n "(cached) " >&6
7967 else
7969 gl_save_compiler_FLAGS="$CFLAGS"
7970 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive"
7971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7972 /* end confdefs.h. */
7975 main ()
7979 return 0;
7981 _ACEOF
7982 if ac_fn_c_try_compile "$LINENO"; then :
7983 eval "$as_gl_Warn=yes"
7984 else
7985 eval "$as_gl_Warn=no"
7987 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7988 CFLAGS="$gl_save_compiler_FLAGS"
7991 eval ac_res=\$$as_gl_Warn
7992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7993 $as_echo "$ac_res" >&6; }
7994 eval as_val=\$$as_gl_Warn
7995 if test "x$as_val" = x""yes; then :
7996 as_fn_append WARN_CFLAGS " $w"
8000 done
8002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
8003 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
8004 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
8005 $as_echo_n "(cached) " >&6
8006 else
8008 gl_save_compiler_FLAGS="$CFLAGS"
8009 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wmissing-field-initializers"
8010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8011 /* end confdefs.h. */
8014 main ()
8018 return 0;
8020 _ACEOF
8021 if ac_fn_c_try_compile "$LINENO"; then :
8022 gl_cv_warn_c__Wno_missing_field_initializers=yes
8023 else
8024 gl_cv_warn_c__Wno_missing_field_initializers=no
8026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8027 CFLAGS="$gl_save_compiler_FLAGS"
8030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
8031 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
8032 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
8033 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
8036 # We need this one
8038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
8039 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
8040 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
8041 $as_echo_n "(cached) " >&6
8042 else
8044 gl_save_compiler_FLAGS="$CFLAGS"
8045 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wsign-compare"
8046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8047 /* end confdefs.h. */
8050 main ()
8054 return 0;
8056 _ACEOF
8057 if ac_fn_c_try_compile "$LINENO"; then :
8058 gl_cv_warn_c__Wno_sign_compare=yes
8059 else
8060 gl_cv_warn_c__Wno_sign_compare=no
8062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8063 CFLAGS="$gl_save_compiler_FLAGS"
8066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
8067 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
8068 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
8069 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
8072 # Too many warnings for now
8074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
8075 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
8076 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8077 $as_echo_n "(cached) " >&6
8078 else
8080 gl_save_compiler_FLAGS="$CFLAGS"
8081 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtype-limits"
8082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8083 /* end confdefs.h. */
8086 main ()
8090 return 0;
8092 _ACEOF
8093 if ac_fn_c_try_compile "$LINENO"; then :
8094 gl_cv_warn_c__Wno_type_limits=yes
8095 else
8096 gl_cv_warn_c__Wno_type_limits=no
8098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8099 CFLAGS="$gl_save_compiler_FLAGS"
8102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8103 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8104 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8105 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8108 # Too many warnings for now
8110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8111 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8112 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8113 $as_echo_n "(cached) " >&6
8114 else
8116 gl_save_compiler_FLAGS="$CFLAGS"
8117 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
8118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8119 /* end confdefs.h. */
8122 main ()
8126 return 0;
8128 _ACEOF
8129 if ac_fn_c_try_compile "$LINENO"; then :
8130 gl_cv_warn_c__Wno_switch=yes
8131 else
8132 gl_cv_warn_c__Wno_switch=no
8134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8135 CFLAGS="$gl_save_compiler_FLAGS"
8138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8139 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8140 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8141 as_fn_append WARN_CFLAGS " -Wno-switch"
8144 # Too many warnings for now
8146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8147 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8148 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8149 $as_echo_n "(cached) " >&6
8150 else
8152 gl_save_compiler_FLAGS="$CFLAGS"
8153 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-parameter"
8154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8155 /* end confdefs.h. */
8158 main ()
8162 return 0;
8164 _ACEOF
8165 if ac_fn_c_try_compile "$LINENO"; then :
8166 gl_cv_warn_c__Wno_unused_parameter=yes
8167 else
8168 gl_cv_warn_c__Wno_unused_parameter=no
8170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8171 CFLAGS="$gl_save_compiler_FLAGS"
8174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8175 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8176 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8177 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8180 # Too many warnings for now
8182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8183 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8184 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8185 $as_echo_n "(cached) " >&6
8186 else
8188 gl_save_compiler_FLAGS="$CFLAGS"
8189 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-nonliteral"
8190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8191 /* end confdefs.h. */
8194 main ()
8198 return 0;
8200 _ACEOF
8201 if ac_fn_c_try_compile "$LINENO"; then :
8202 gl_cv_warn_c__Wno_format_nonliteral=yes
8203 else
8204 gl_cv_warn_c__Wno_format_nonliteral=no
8206 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8207 CFLAGS="$gl_save_compiler_FLAGS"
8210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8211 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8212 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8213 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8218 # In spite of excluding -Wlogical-op above, it is enabled, as of
8219 # gcc 4.5.0 20090517.
8221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8222 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8223 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8224 $as_echo_n "(cached) " >&6
8225 else
8227 gl_save_compiler_FLAGS="$CFLAGS"
8228 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wlogical-op"
8229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8230 /* end confdefs.h. */
8233 main ()
8237 return 0;
8239 _ACEOF
8240 if ac_fn_c_try_compile "$LINENO"; then :
8241 gl_cv_warn_c__Wno_logical_op=yes
8242 else
8243 gl_cv_warn_c__Wno_logical_op=no
8245 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8246 CFLAGS="$gl_save_compiler_FLAGS"
8249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8250 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8251 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8252 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8257 # More things that clang is unduly picky about.
8258 if test $emacs_cv_clang = yes; then
8260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8261 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8262 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8263 $as_echo_n "(cached) " >&6
8264 else
8266 gl_save_compiler_FLAGS="$CFLAGS"
8267 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-extra-args"
8268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8269 /* end confdefs.h. */
8272 main ()
8276 return 0;
8278 _ACEOF
8279 if ac_fn_c_try_compile "$LINENO"; then :
8280 gl_cv_warn_c__Wno_format_extra_args=yes
8281 else
8282 gl_cv_warn_c__Wno_format_extra_args=no
8284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8285 CFLAGS="$gl_save_compiler_FLAGS"
8288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8289 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8290 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8291 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8297 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8298 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8299 $as_echo_n "(cached) " >&6
8300 else
8302 gl_save_compiler_FLAGS="$CFLAGS"
8303 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
8304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8305 /* end confdefs.h. */
8308 main ()
8312 return 0;
8314 _ACEOF
8315 if ac_fn_c_try_compile "$LINENO"; then :
8316 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8317 else
8318 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8321 CFLAGS="$gl_save_compiler_FLAGS"
8324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8325 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8326 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8327 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8333 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8334 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8335 $as_echo_n "(cached) " >&6
8336 else
8338 gl_save_compiler_FLAGS="$CFLAGS"
8339 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-command-line-argument"
8340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8341 /* end confdefs.h. */
8344 main ()
8348 return 0;
8350 _ACEOF
8351 if ac_fn_c_try_compile "$LINENO"; then :
8352 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8353 else
8354 gl_cv_warn_c__Wno_unused_command_line_argument=no
8356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8357 CFLAGS="$gl_save_compiler_FLAGS"
8360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8361 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8362 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8363 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8369 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8370 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8371 $as_echo_n "(cached) " >&6
8372 else
8374 gl_save_compiler_FLAGS="$CFLAGS"
8375 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-value"
8376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8377 /* end confdefs.h. */
8380 main ()
8384 return 0;
8386 _ACEOF
8387 if ac_fn_c_try_compile "$LINENO"; then :
8388 gl_cv_warn_c__Wno_unused_value=yes
8389 else
8390 gl_cv_warn_c__Wno_unused_value=no
8392 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8393 CFLAGS="$gl_save_compiler_FLAGS"
8396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8397 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8398 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8399 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
8407 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
8408 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
8409 $as_echo_n "(cached) " >&6
8410 else
8412 gl_save_compiler_FLAGS="$CFLAGS"
8413 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
8414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8415 /* end confdefs.h. */
8418 main ()
8422 return 0;
8424 _ACEOF
8425 if ac_fn_c_try_compile "$LINENO"; then :
8426 gl_cv_warn_c__fdiagnostics_show_option=yes
8427 else
8428 gl_cv_warn_c__fdiagnostics_show_option=no
8430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8431 CFLAGS="$gl_save_compiler_FLAGS"
8434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
8435 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
8436 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
8437 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
8442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
8443 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
8444 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
8445 $as_echo_n "(cached) " >&6
8446 else
8448 gl_save_compiler_FLAGS="$CFLAGS"
8449 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
8450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8451 /* end confdefs.h. */
8454 main ()
8458 return 0;
8460 _ACEOF
8461 if ac_fn_c_try_compile "$LINENO"; then :
8462 gl_cv_warn_c__funit_at_a_time=yes
8463 else
8464 gl_cv_warn_c__funit_at_a_time=no
8466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8467 CFLAGS="$gl_save_compiler_FLAGS"
8470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
8471 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
8472 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
8473 as_fn_append WARN_CFLAGS " -funit-at-a-time"
8479 $as_echo "#define lint 1" >>confdefs.h
8483 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8486 # We use a slightly smaller set of warning options for lib/.
8487 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8489 nw="$nw -Wunused-macros"
8492 gl_warn_set=
8493 set x $WARN_CFLAGS; shift
8494 for gl_warn_item
8496 case " $nw " in
8497 *" $gl_warn_item "*)
8500 gl_warn_set="$gl_warn_set $gl_warn_item"
8502 esac
8503 done
8504 GNULIB_WARN_CFLAGS=$gl_warn_set
8514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8515 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8516 rm -f conf$$ conf$$.file
8518 LN_S_FILEONLY='cp -p'
8520 if (echo >conf$$.file) 2>/dev/null; then
8521 if ln -s conf$$.file conf$$ 2>/dev/null; then
8522 LN_S_FILEONLY='ln -s'
8523 elif ln conf$$.file conf$$ 2>/dev/null; then
8524 LN_S_FILEONLY=ln
8528 rm -f conf$$ conf$$.file
8530 if test "$LN_S_FILEONLY" = "ln -s"; then
8531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8532 $as_echo "yes" >&6; }
8533 else
8534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8535 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8541 if test "$opsys" = "mingw32"; then
8542 LN_S="ln"
8545 # Extract the first word of "install-info", so it can be a program name with args.
8546 set dummy install-info; ac_word=$2
8547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8548 $as_echo_n "checking for $ac_word... " >&6; }
8549 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8550 $as_echo_n "(cached) " >&6
8551 else
8552 case $INSTALL_INFO in
8553 [\\/]* | ?:[\\/]*)
8554 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8558 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8560 IFS=$as_save_IFS
8561 test -z "$as_dir" && as_dir=.
8562 for ac_exec_ext in '' $ac_executable_extensions; do
8563 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8564 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8566 break 2
8568 done
8569 done
8570 IFS=$as_save_IFS
8572 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8574 esac
8576 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8577 if test -n "$INSTALL_INFO"; then
8578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8579 $as_echo "$INSTALL_INFO" >&6; }
8580 else
8581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8582 $as_echo "no" >&6; }
8586 # Extract the first word of "gzip", so it can be a program name with args.
8587 set dummy gzip; ac_word=$2
8588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8589 $as_echo_n "checking for $ac_word... " >&6; }
8590 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8591 $as_echo_n "(cached) " >&6
8592 else
8593 case $GZIP_PROG in
8594 [\\/]* | ?:[\\/]*)
8595 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8599 for as_dir in $PATH
8601 IFS=$as_save_IFS
8602 test -z "$as_dir" && as_dir=.
8603 for ac_exec_ext in '' $ac_executable_extensions; do
8604 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8605 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8607 break 2
8609 done
8610 done
8611 IFS=$as_save_IFS
8614 esac
8616 GZIP_PROG=$ac_cv_path_GZIP_PROG
8617 if test -n "$GZIP_PROG"; then
8618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8619 $as_echo "$GZIP_PROG" >&6; }
8620 else
8621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8622 $as_echo "no" >&6; }
8627 test $with_compress_install != yes && test -n "$GZIP_PROG" && \
8628 GZIP_PROG=" # $GZIP_PROG # (disabled by configure --without-compress-install)"
8630 if test $opsys = gnu-linux; then
8631 # Extract the first word of "paxctl", so it can be a program name with args.
8632 set dummy paxctl; ac_word=$2
8633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8634 $as_echo_n "checking for $ac_word... " >&6; }
8635 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8636 $as_echo_n "(cached) " >&6
8637 else
8638 case $PAXCTL in
8639 [\\/]* | ?:[\\/]*)
8640 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8644 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8646 IFS=$as_save_IFS
8647 test -z "$as_dir" && as_dir=.
8648 for ac_exec_ext in '' $ac_executable_extensions; do
8649 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8650 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8652 break 2
8654 done
8655 done
8656 IFS=$as_save_IFS
8659 esac
8661 PAXCTL=$ac_cv_path_PAXCTL
8662 if test -n "$PAXCTL"; then
8663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8664 $as_echo "$PAXCTL" >&6; }
8665 else
8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8667 $as_echo "no" >&6; }
8671 if test "X$PAXCTL" != X; then
8672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8673 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8675 /* end confdefs.h. */
8678 main ()
8682 return 0;
8684 _ACEOF
8685 if ac_fn_c_try_link "$LINENO"; then :
8686 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8687 $as_echo "yes" >&6; }
8688 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8689 $as_echo "no" >&6; }; PAXCTL=""; fi
8691 rm -f core conftest.err conftest.$ac_objext \
8692 conftest$ac_exeext conftest.$ac_ext
8696 ## Need makeinfo >= 4.7 (?) to build the manuals.
8697 # Extract the first word of "makeinfo", so it can be a program name with args.
8698 set dummy makeinfo; ac_word=$2
8699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8700 $as_echo_n "checking for $ac_word... " >&6; }
8701 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8702 $as_echo_n "(cached) " >&6
8703 else
8704 case $MAKEINFO in
8705 [\\/]* | ?:[\\/]*)
8706 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8709 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8710 for as_dir in $PATH
8712 IFS=$as_save_IFS
8713 test -z "$as_dir" && as_dir=.
8714 for ac_exec_ext in '' $ac_executable_extensions; do
8715 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8716 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8717 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8718 break 2
8720 done
8721 done
8722 IFS=$as_save_IFS
8724 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8726 esac
8728 MAKEINFO=$ac_cv_path_MAKEINFO
8729 if test -n "$MAKEINFO"; then
8730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8731 $as_echo "$MAKEINFO" >&6; }
8732 else
8733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8734 $as_echo "no" >&6; }
8738 if test "$MAKEINFO" != "no"; then
8739 case `
8740 $MAKEINFO --version 2> /dev/null |
8741 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8742 ` in
8743 '') MAKEINFO=no;;
8744 esac
8747 ## Makeinfo is unusual. For a released Emacs, the manuals are
8748 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8749 ## therefore in the category of "special tools" not normally required, which
8750 ## configure does not have to check for (eg autoconf itself).
8751 ## In a Bazaar checkout on the other hand, the manuals are not included.
8752 ## So makeinfo is a requirement to build from Bazaar, and configure
8753 ## should test for it as it does for any other build requirement.
8754 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8755 ## with pre-built manuals, from a Bazaar checkout.
8756 HAVE_MAKEINFO=yes
8758 if test "$MAKEINFO" = "no"; then
8759 MAKEINFO=makeinfo
8760 if test "x${with_makeinfo}" = "xno"; then
8761 HAVE_MAKEINFO=no
8762 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8763 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8764 source tree does not seem to have pre-built manuals in the \`info' directory.
8765 Either install a suitable version of makeinfo, or re-run configure
8766 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8771 INFO_EXT=.info
8772 INFO_OPTS=--no-split
8776 if test $opsys = mingw32; then
8777 DOCMISC_W32=efaq-w32
8778 else
8779 DOCMISC_W32=
8784 if test x$GCC = xyes; then
8785 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8786 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8787 else
8788 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8789 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8793 late_LDFLAGS="$LDFLAGS"
8794 if test x$GCC = xyes; then
8795 LDFLAGS_NOCOMBRELOC="-Wl,-znocombreloc"
8796 else
8797 LDFLAGS_NOCOMBRELOC="-znocombreloc"
8800 LDFLAGS="$LDFLAGS $LDFLAGS_NOCOMBRELOC"
8802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8803 $as_echo_n "checking for -znocombreloc... " >&6; }
8804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8805 /* end confdefs.h. */
8808 main ()
8812 return 0;
8814 _ACEOF
8815 if ac_fn_c_try_link "$LINENO"; then :
8816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8817 $as_echo "yes" >&6; }
8818 else
8819 LDFLAGS_NOCOMBRELOC=
8820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8821 $as_echo "no" >&6; }
8823 rm -f core conftest.err conftest.$ac_objext \
8824 conftest$ac_exeext conftest.$ac_ext
8826 LDFLAGS="$late_LDFLAGS"
8828 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8829 case "$opsys" in
8830 your-opsys-here) CANNOT_DUMP=yes ;;
8831 esac
8833 test "$CANNOT_DUMP" = "yes" && \
8835 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8841 UNEXEC_OBJ=unexelf.o
8842 case "$opsys" in
8843 # MSDOS uses unexcoff.o
8844 aix4-2)
8845 UNEXEC_OBJ=unexaix.o
8847 cygwin)
8848 UNEXEC_OBJ=unexcw.o
8850 darwin)
8851 UNEXEC_OBJ=unexmacosx.o
8853 hpux10-20 | hpux11)
8854 UNEXEC_OBJ=unexhp9k800.o
8856 mingw32)
8857 UNEXEC_OBJ=unexw32.o
8859 sol2-10)
8860 # Use the Solaris dldump() function, called from unexsol.c, to dump
8861 # emacs, instead of the generic ELF dump code found in unexelf.c.
8862 # The resulting binary has a complete symbol table, and is better
8863 # for debugging and other observability tools (debuggers, pstack, etc).
8865 # If you encounter a problem using dldump(), please consider sending
8866 # a message to the OpenSolaris tools-linking mailing list:
8867 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8869 # It is likely that dldump() works with older Solaris too, but this has
8870 # not been tested, so for now this change is for Solaris 10 or newer.
8871 UNEXEC_OBJ=unexsol.o
8873 esac
8875 LD_SWITCH_SYSTEM=
8876 case "$opsys" in
8877 freebsd|dragonfly)
8878 ## Let `ld' find image libs and similar things in /usr/local/lib.
8879 ## The system compiler, GCC, has apparently been modified to not
8880 ## look there, contrary to what a stock GCC would do.
8881 ### It's not our place to do this. See bug#10313#17.
8882 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8886 gnu-linux)
8887 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8888 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8891 netbsd)
8892 ### It's not our place to do this. See bug#10313#17.
8893 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8897 openbsd)
8898 ## Han Boetes <han@boetes.org> says this is necessary,
8899 ## otherwise Emacs dumps core on elf systems.
8900 LD_SWITCH_SYSTEM="-Z"
8902 esac
8905 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8907 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8908 ## which has not been defined yet. When this was handled with cpp,
8909 ## it was expanded to null when configure sourced the s/*.h file.
8910 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8911 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8912 ## (or somesuch), but because it is supposed to go at the _front_
8913 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8914 ## Compare with the gnu-linux case below, which added to the end
8915 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8916 ## LD_SWITCH_SYSTEM_TEMACS.
8917 case "$opsys" in
8918 netbsd|openbsd)
8919 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8920 esac
8923 C_SWITCH_MACHINE=
8924 case $canonical in
8925 alpha*)
8926 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8927 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8931 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8932 ## With ELF, make sure that all common symbols get allocated to in the
8933 ## data section. Otherwise, the dump of temacs may miss variables in
8934 ## the shared library that have been initialized. For example, with
8935 ## GNU libc, __malloc_initialized would normally be resolved to the
8936 ## shared library's .bss section, which is fatal.
8937 if test "x$GCC" = "xyes"; then
8938 C_SWITCH_MACHINE="-fno-common"
8939 else
8940 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8942 else
8943 UNEXEC_OBJ=unexalpha.o
8946 esac
8951 C_SWITCH_SYSTEM=
8952 ## Some programs in src produce warnings saying certain subprograms
8953 ## are too complex and need a MAXMEM value greater than 2000 for
8954 ## additional optimization. --nils@exp-math.uni-essen.de
8955 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8956 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8957 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
8958 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8959 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8963 LIBS_SYSTEM=
8964 case "$opsys" in
8965 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8966 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8968 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
8970 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8972 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8974 ## Motif needs -lgen.
8975 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8976 esac
8980 ### Make sure subsequent tests use flags consistent with the build flags.
8982 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8983 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8984 else
8985 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8988 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8990 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8994 LIB_MATH=-lm
8995 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8997 case $opsys in
8998 cygwin )
8999 LIB_MATH=
9001 darwin )
9002 ## Adding -lm confuses the dynamic linker, so omit it.
9003 LIB_MATH=
9005 freebsd | dragonfly )
9006 SYSTEM_TYPE=berkeley-unix
9008 gnu-linux | gnu-kfreebsd )
9010 hpux10-20 | hpux11 )
9012 mingw32 )
9013 LIB_MATH=
9014 SYSTEM_TYPE=windows-nt
9016 netbsd | openbsd )
9017 SYSTEM_TYPE=berkeley-unix
9020 sol2* | unixware )
9021 SYSTEM_TYPE=usg-unix-v
9024 esac
9028 cat >>confdefs.h <<_ACEOF
9029 #define SYSTEM_TYPE "$SYSTEM_TYPE"
9030 _ACEOF
9034 pre_PKG_CONFIG_CFLAGS=$CFLAGS
9035 pre_PKG_CONFIG_LIBS=$LIBS
9037 # Extract the first word of "pkg-config", so it can be a program name with args.
9038 set dummy pkg-config; ac_word=$2
9039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9040 $as_echo_n "checking for $ac_word... " >&6; }
9041 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9042 $as_echo_n "(cached) " >&6
9043 else
9044 case $PKG_CONFIG in
9045 [\\/]* | ?:[\\/]*)
9046 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9050 for as_dir in $PATH
9052 IFS=$as_save_IFS
9053 test -z "$as_dir" && as_dir=.
9054 for ac_exec_ext in '' $ac_executable_extensions; do
9055 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9056 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9058 break 2
9060 done
9061 done
9062 IFS=$as_save_IFS
9064 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9066 esac
9068 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9069 if test -n "$PKG_CONFIG"; then
9070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9071 $as_echo "$PKG_CONFIG" >&6; }
9072 else
9073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9074 $as_echo "no" >&6; }
9081 HAVE_SOUND=no
9082 if test "${with_sound}" != "no"; then
9083 # Sound support for GNU/Linux, the free BSDs, and MinGW.
9084 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
9085 do :
9086 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9087 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9088 #ifdef __MINGW32__
9089 #define WIN32_LEAN_AND_MEAN
9090 #include <windows.h>
9091 #endif
9094 eval as_val=\$$as_ac_Header
9095 if test "x$as_val" = x""yes; then :
9096 cat >>confdefs.h <<_ACEOF
9097 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9098 _ACEOF
9099 have_sound_header=yes
9102 done
9104 test "${with_sound}" = "oss" && test "${have_sound_header}" != "yes" && \
9105 as_fn_error "OSS sound support requested but not found." "$LINENO" 5
9107 if test "${with_sound}" = "bsd-ossaudio" || test "${with_sound}" = "yes"; then
9108 # Emulation library used on NetBSD.
9109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9110 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9111 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9112 $as_echo_n "(cached) " >&6
9113 else
9114 ac_check_lib_save_LIBS=$LIBS
9115 LIBS="-lossaudio $LIBS"
9116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9117 /* end confdefs.h. */
9119 /* Override any GCC internal prototype to avoid an error.
9120 Use char because int might match the return type of a GCC
9121 builtin and then its argument prototype would still apply. */
9122 #ifdef __cplusplus
9123 extern "C"
9124 #endif
9125 char _oss_ioctl ();
9127 main ()
9129 return _oss_ioctl ();
9131 return 0;
9133 _ACEOF
9134 if ac_fn_c_try_link "$LINENO"; then :
9135 ac_cv_lib_ossaudio__oss_ioctl=yes
9136 else
9137 ac_cv_lib_ossaudio__oss_ioctl=no
9139 rm -f core conftest.err conftest.$ac_objext \
9140 conftest$ac_exeext conftest.$ac_ext
9141 LIBS=$ac_check_lib_save_LIBS
9143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9144 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9145 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9146 LIBSOUND=-lossaudio
9147 else
9148 LIBSOUND=
9151 test "${with_sound}" = "bsd-ossaudio" && test -z "$LIBSOUND" && \
9152 as_fn_error "bsd-ossaudio sound support requested but not found." "$LINENO" 5
9156 if test "${with_sound}" = "alsa" || test "${with_sound}" = "yes"; then
9157 ALSA_REQUIRED=1.0.0
9158 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9160 succeeded=no
9162 if test "$PKG_CONFIG" = "no" ; then
9163 HAVE_ALSA=no
9164 else
9165 PKG_CONFIG_MIN_VERSION=0.9.0
9166 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9168 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9170 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9171 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9172 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9173 edit_cflags="
9174 s,///*,/,g
9175 s/^/ /
9176 s/ -I/ $isystem/g
9177 s/^ //
9179 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9180 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9182 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9183 succeeded=yes
9184 else
9185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9186 $as_echo "no" >&6; }
9187 ALSA_CFLAGS=""
9188 ALSA_LIBS=""
9189 ## If we have a custom action on failure, don't print errors, but
9190 ## do set a variable so people can do so. Do it in a subshell
9191 ## to capture any diagnostics in invoking pkg-config.
9192 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9198 else
9199 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9200 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9204 if test $succeeded = yes; then
9205 HAVE_ALSA=yes
9206 else
9207 HAVE_ALSA=no
9210 if test $HAVE_ALSA = yes; then
9211 SAVE_CFLAGS="$CFLAGS"
9212 SAVE_LIBS="$LIBS"
9213 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9214 LIBS="$ALSA_LIBS $LIBS"
9215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9216 /* end confdefs.h. */
9217 #include <asoundlib.h>
9219 main ()
9221 snd_lib_error_set_handler (0);
9223 return 0;
9225 _ACEOF
9226 if ac_fn_c_try_compile "$LINENO"; then :
9227 emacs_alsa_normal=yes
9228 else
9229 emacs_alsa_normal=no
9231 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9232 if test "$emacs_alsa_normal" != yes; then
9233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9234 /* end confdefs.h. */
9235 #include <alsa/asoundlib.h>
9237 main ()
9239 snd_lib_error_set_handler (0);
9241 return 0;
9243 _ACEOF
9244 if ac_fn_c_try_compile "$LINENO"; then :
9245 emacs_alsa_subdir=yes
9246 else
9247 emacs_alsa_subdir=no
9249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9250 if test "$emacs_alsa_subdir" != yes; then
9251 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9253 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9256 CFLAGS="$SAVE_CFLAGS"
9257 LIBS="$SAVE_LIBS"
9258 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9259 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9261 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9263 elif test "${with_sound}" = "alsa"; then
9264 as_fn_error "ALSA sound support requested but not found." "$LINENO" 5
9267 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9268 case "$opsys" in
9269 gnu-linux|freebsd|netbsd|mingw32)
9271 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9273 HAVE_SOUND=yes
9275 esac
9284 for ac_header in $ac_header_list
9285 do :
9286 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9287 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9289 eval as_val=\$$as_ac_Header
9290 if test "x$as_val" = x""yes; then :
9291 cat >>confdefs.h <<_ACEOF
9292 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9293 _ACEOF
9297 done
9317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9318 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9320 /* end confdefs.h. */
9321 #include <sys/personality.h>
9323 main ()
9325 personality (PER_LINUX32)
9327 return 0;
9329 _ACEOF
9330 if ac_fn_c_try_compile "$LINENO"; then :
9331 emacs_cv_personality_linux32=yes
9332 else
9333 emacs_cv_personality_linux32=no
9335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9337 $as_echo "$emacs_cv_personality_linux32" >&6; }
9339 if test $emacs_cv_personality_linux32 = yes; then
9341 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9345 for ac_header in term.h
9346 do :
9347 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9348 if test "x$ac_cv_header_term_h" = x""yes; then :
9349 cat >>confdefs.h <<_ACEOF
9350 #define HAVE_TERM_H 1
9351 _ACEOF
9355 done
9357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9358 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9359 if test "${ac_cv_header_time+set}" = set; then :
9360 $as_echo_n "(cached) " >&6
9361 else
9362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9363 /* end confdefs.h. */
9364 #include <sys/types.h>
9365 #include <sys/time.h>
9366 #include <time.h>
9369 main ()
9371 if ((struct tm *) 0)
9372 return 0;
9374 return 0;
9376 _ACEOF
9377 if ac_fn_c_try_compile "$LINENO"; then :
9378 ac_cv_header_time=yes
9379 else
9380 ac_cv_header_time=no
9382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9385 $as_echo "$ac_cv_header_time" >&6; }
9386 if test $ac_cv_header_time = yes; then
9388 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9392 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9395 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9396 ac_have_decl=1
9397 else
9398 ac_have_decl=0
9401 cat >>confdefs.h <<_ACEOF
9402 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9403 _ACEOF
9405 if test $ac_cv_have_decl_sys_siglist != yes; then
9406 # For Tru64, at least:
9407 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9410 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9411 ac_have_decl=1
9412 else
9413 ac_have_decl=0
9416 cat >>confdefs.h <<_ACEOF
9417 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9418 _ACEOF
9421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9422 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9423 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
9424 $as_echo_n "(cached) " >&6
9425 else
9426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9427 /* end confdefs.h. */
9428 #include <sys/types.h>
9429 #include <sys/wait.h>
9430 #ifndef WEXITSTATUS
9431 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9432 #endif
9433 #ifndef WIFEXITED
9434 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9435 #endif
9438 main ()
9440 int s;
9441 wait (&s);
9442 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9444 return 0;
9446 _ACEOF
9447 if ac_fn_c_try_compile "$LINENO"; then :
9448 ac_cv_header_sys_wait_h=yes
9449 else
9450 ac_cv_header_sys_wait_h=no
9452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9455 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9456 if test $ac_cv_header_sys_wait_h = yes; then
9458 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9466 for ac_header in net/if.h
9467 do :
9468 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9469 #if HAVE_SYS_SOCKET_H
9470 #include <sys/socket.h>
9471 #endif
9473 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9474 cat >>confdefs.h <<_ACEOF
9475 #define HAVE_NET_IF_H 1
9476 _ACEOF
9480 done
9482 for ac_header in ifaddrs.h
9483 do :
9484 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9485 #if HAVE_SYS_SOCKET_H
9486 #include <sys/socket.h>
9487 #endif
9489 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9490 cat >>confdefs.h <<_ACEOF
9491 #define HAVE_IFADDRS_H 1
9492 _ACEOF
9496 done
9498 for ac_header in net/if_dl.h
9499 do :
9500 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9501 #if HAVE_SYS_SOCKET_H
9502 #include <sys/socket.h>
9503 #endif
9505 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9506 cat >>confdefs.h <<_ACEOF
9507 #define HAVE_NET_IF_DL_H 1
9508 _ACEOF
9512 done
9515 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9516 #if HAVE_SYS_SOCKET_H
9517 #include <sys/socket.h>
9518 #endif
9519 #if HAVE_NET_IF_H
9520 #include <net/if.h>
9521 #endif
9523 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9525 cat >>confdefs.h <<_ACEOF
9526 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9527 _ACEOF
9531 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9532 #if HAVE_SYS_SOCKET_H
9533 #include <sys/socket.h>
9534 #endif
9535 #if HAVE_NET_IF_H
9536 #include <net/if.h>
9537 #endif
9539 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9541 cat >>confdefs.h <<_ACEOF
9542 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9543 _ACEOF
9547 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9548 #if HAVE_SYS_SOCKET_H
9549 #include <sys/socket.h>
9550 #endif
9551 #if HAVE_NET_IF_H
9552 #include <net/if.h>
9553 #endif
9555 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9557 cat >>confdefs.h <<_ACEOF
9558 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9559 _ACEOF
9563 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9564 #if HAVE_SYS_SOCKET_H
9565 #include <sys/socket.h>
9566 #endif
9567 #if HAVE_NET_IF_H
9568 #include <net/if.h>
9569 #endif
9571 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9573 cat >>confdefs.h <<_ACEOF
9574 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9575 _ACEOF
9579 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9580 #if HAVE_SYS_SOCKET_H
9581 #include <sys/socket.h>
9582 #endif
9583 #if HAVE_NET_IF_H
9584 #include <net/if.h>
9585 #endif
9587 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9589 cat >>confdefs.h <<_ACEOF
9590 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9591 _ACEOF
9595 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9596 #if HAVE_SYS_SOCKET_H
9597 #include <sys/socket.h>
9598 #endif
9599 #if HAVE_NET_IF_H
9600 #include <net/if.h>
9601 #endif
9603 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9605 cat >>confdefs.h <<_ACEOF
9606 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9607 _ACEOF
9615 DEPFLAGS=
9616 MKDEPDIR=":"
9617 deps_frag=deps.mk
9618 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9620 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9621 HAVE_GNU_MAKE=no
9622 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9623 if test "x$testval" != x; then
9624 HAVE_GNU_MAKE=yes
9625 else
9626 ac_enable_autodepend=no
9628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9629 $as_echo "$HAVE_GNU_MAKE" >&6; }
9630 if test $HAVE_GNU_MAKE = yes; then
9631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9632 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9633 SAVE_CFLAGS="$CFLAGS"
9634 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9636 /* end confdefs.h. */
9639 main ()
9643 return 0;
9645 _ACEOF
9646 if ac_fn_c_try_compile "$LINENO"; then :
9648 else
9649 ac_enable_autodepend=no
9651 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9652 CFLAGS="$SAVE_CFLAGS"
9653 test -f deps.d || ac_enable_autodepend=no
9654 rm -rf deps.d
9655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9656 $as_echo "$ac_enable_autodepend" >&6; }
9658 if test $ac_enable_autodepend = yes; then
9659 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9660 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9661 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9662 deps_frag=autodeps.mk
9665 deps_frag=$srcdir/src/$deps_frag
9671 lisp_frag=$srcdir/src/lisp.mk
9675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9676 $as_echo_n "checking for long file names... " >&6; }
9677 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9678 $as_echo_n "(cached) " >&6
9679 else
9680 ac_cv_sys_long_file_names=yes
9681 # Test for long file names in all the places we know might matter:
9682 # . the current directory, where building will happen
9683 # $prefix/lib where we will be installing things
9684 # $exec_prefix/lib likewise
9685 # $TMPDIR if set, where it might want to write temporary files
9686 # /tmp where it might want to write temporary files
9687 # /var/tmp likewise
9688 # /usr/tmp likewise
9689 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9690 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9691 # in the usual case where exec_prefix is '${prefix}'.
9692 case $ac_dir in #(
9693 . | /* | ?:[\\/]*) ;; #(
9694 *) continue;;
9695 esac
9696 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9697 ac_xdir=$ac_dir/cf$$
9698 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9699 ac_tf1=$ac_xdir/conftest9012345
9700 ac_tf2=$ac_xdir/conftest9012346
9701 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9702 ac_cv_sys_long_file_names=no
9703 rm -f -r "$ac_xdir" 2>/dev/null
9704 test $ac_cv_sys_long_file_names = no && break
9705 done
9707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9708 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9709 if test $ac_cv_sys_long_file_names = yes; then
9711 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9716 #### Choose a window system.
9718 ## We leave window_system equal to none if
9719 ## we end up building without one. Any new window system should
9720 ## set window_system to an appropriate value and add objects to
9721 ## window-system-specific substs.
9723 window_system=none
9724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9725 $as_echo_n "checking for X... " >&6; }
9728 # Check whether --with-x was given.
9729 if test "${with_x+set}" = set; then :
9730 withval=$with_x;
9733 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9734 if test "x$with_x" = xno; then
9735 # The user explicitly disabled X.
9736 have_x=disabled
9737 else
9738 case $x_includes,$x_libraries in #(
9739 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9740 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9741 $as_echo_n "(cached) " >&6
9742 else
9743 # One or both of the vars are not set, and there is no cached value.
9744 ac_x_includes=no ac_x_libraries=no
9745 rm -f -r conftest.dir
9746 if mkdir conftest.dir; then
9747 cd conftest.dir
9748 cat >Imakefile <<'_ACEOF'
9749 incroot:
9750 @echo incroot='${INCROOT}'
9751 usrlibdir:
9752 @echo usrlibdir='${USRLIBDIR}'
9753 libdir:
9754 @echo libdir='${LIBDIR}'
9755 _ACEOF
9756 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9757 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9758 for ac_var in incroot usrlibdir libdir; do
9759 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9760 done
9761 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9762 for ac_extension in a so sl dylib la dll; do
9763 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9764 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9765 ac_im_usrlibdir=$ac_im_libdir; break
9767 done
9768 # Screen out bogus values from the imake configuration. They are
9769 # bogus both because they are the default anyway, and because
9770 # using them would break gcc on systems where it needs fixed includes.
9771 case $ac_im_incroot in
9772 /usr/include) ac_x_includes= ;;
9773 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9774 esac
9775 case $ac_im_usrlibdir in
9776 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9777 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9778 esac
9780 cd ..
9781 rm -f -r conftest.dir
9784 # Standard set of common directories for X headers.
9785 # Check X11 before X11Rn because it is often a symlink to the current release.
9786 ac_x_header_dirs='
9787 /usr/X11/include
9788 /usr/X11R7/include
9789 /usr/X11R6/include
9790 /usr/X11R5/include
9791 /usr/X11R4/include
9793 /usr/include/X11
9794 /usr/include/X11R7
9795 /usr/include/X11R6
9796 /usr/include/X11R5
9797 /usr/include/X11R4
9799 /usr/local/X11/include
9800 /usr/local/X11R7/include
9801 /usr/local/X11R6/include
9802 /usr/local/X11R5/include
9803 /usr/local/X11R4/include
9805 /usr/local/include/X11
9806 /usr/local/include/X11R7
9807 /usr/local/include/X11R6
9808 /usr/local/include/X11R5
9809 /usr/local/include/X11R4
9811 /usr/X386/include
9812 /usr/x386/include
9813 /usr/XFree86/include/X11
9815 /usr/include
9816 /usr/local/include
9817 /usr/unsupported/include
9818 /usr/athena/include
9819 /usr/local/x11r5/include
9820 /usr/lpp/Xamples/include
9822 /usr/openwin/include
9823 /usr/openwin/share/include'
9825 if test "$ac_x_includes" = no; then
9826 # Guess where to find include files, by looking for Xlib.h.
9827 # First, try using that file with no special directory specified.
9828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9829 /* end confdefs.h. */
9830 #include <X11/Xlib.h>
9831 _ACEOF
9832 if ac_fn_c_try_cpp "$LINENO"; then :
9833 # We can compile using X headers with no special include directory.
9834 ac_x_includes=
9835 else
9836 for ac_dir in $ac_x_header_dirs; do
9837 if test -r "$ac_dir/X11/Xlib.h"; then
9838 ac_x_includes=$ac_dir
9839 break
9841 done
9843 rm -f conftest.err conftest.$ac_ext
9844 fi # $ac_x_includes = no
9846 if test "$ac_x_libraries" = no; then
9847 # Check for the libraries.
9848 # See if we find them without any special options.
9849 # Don't add to $LIBS permanently.
9850 ac_save_LIBS=$LIBS
9851 LIBS="-lX11 $LIBS"
9852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9853 /* end confdefs.h. */
9854 #include <X11/Xlib.h>
9856 main ()
9858 XrmInitialize ()
9860 return 0;
9862 _ACEOF
9863 if ac_fn_c_try_link "$LINENO"; then :
9864 LIBS=$ac_save_LIBS
9865 # We can link X programs with no special library path.
9866 ac_x_libraries=
9867 else
9868 LIBS=$ac_save_LIBS
9869 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9871 # Don't even attempt the hair of trying to link an X program!
9872 for ac_extension in a so sl dylib la dll; do
9873 if test -r "$ac_dir/libX11.$ac_extension"; then
9874 ac_x_libraries=$ac_dir
9875 break 2
9877 done
9878 done
9880 rm -f core conftest.err conftest.$ac_objext \
9881 conftest$ac_exeext conftest.$ac_ext
9882 fi # $ac_x_libraries = no
9884 case $ac_x_includes,$ac_x_libraries in #(
9885 no,* | *,no | *\'*)
9886 # Didn't find X, or a directory has "'" in its name.
9887 ac_cv_have_x="have_x=no";; #(
9889 # Record where we found X for the cache.
9890 ac_cv_have_x="have_x=yes\
9891 ac_x_includes='$ac_x_includes'\
9892 ac_x_libraries='$ac_x_libraries'"
9893 esac
9895 ;; #(
9896 *) have_x=yes;;
9897 esac
9898 eval "$ac_cv_have_x"
9899 fi # $with_x != no
9901 if test "$have_x" != yes; then
9902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9903 $as_echo "$have_x" >&6; }
9904 no_x=yes
9905 else
9906 # If each of the values was on the command line, it overrides each guess.
9907 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9908 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9909 # Update the cache value to reflect the command line values.
9910 ac_cv_have_x="have_x=yes\
9911 ac_x_includes='$x_includes'\
9912 ac_x_libraries='$x_libraries'"
9913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9914 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9917 if test "$no_x" != yes; then
9918 window_system=x11
9921 LD_SWITCH_X_SITE_RPATH=
9922 if test "${x_libraries}" != NONE; then
9923 if test -n "${x_libraries}"; then
9924 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9925 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9927 x_default_search_path=""
9928 x_search_path=${x_libraries}
9929 if test -z "${x_search_path}"; then
9930 x_search_path=/usr/lib
9932 for x_library in `echo ${x_search_path}: | \
9933 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9934 x_search_path="\
9935 ${x_library}/X11/%L/%T/%N%C%S:\
9936 ${x_library}/X11/%l/%T/%N%C%S:\
9937 ${x_library}/X11/%T/%N%C%S:\
9938 ${x_library}/X11/%L/%T/%N%S:\
9939 ${x_library}/X11/%l/%T/%N%S:\
9940 ${x_library}/X11/%T/%N%S"
9941 if test x"${x_default_search_path}" = x; then
9942 x_default_search_path=${x_search_path}
9943 else
9944 x_default_search_path="${x_search_path}:${x_default_search_path}"
9946 done
9950 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9951 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9954 if test x"${x_includes}" = x; then
9955 bitmapdir=/usr/include/X11/bitmaps
9956 else
9957 # accumulate include directories that have X11 bitmap subdirectories
9958 bmd_acc="dummyval"
9959 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9960 if test -d "${bmd}/X11/bitmaps"; then
9961 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9963 if test -d "${bmd}/bitmaps"; then
9964 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9966 done
9967 if test ${bmd_acc} != "dummyval"; then
9968 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9972 HAVE_NS=no
9973 NS_IMPL_COCOA=no
9974 NS_IMPL_GNUSTEP=no
9975 tmp_CPPFLAGS="$CPPFLAGS"
9976 tmp_CFLAGS="$CFLAGS"
9977 CPPFLAGS="$CPPFLAGS -x objective-c"
9978 CFLAGS="$CFLAGS -x objective-c"
9979 GNU_OBJC_CFLAGS=
9980 LIBS_GNUSTEP=
9981 if test "${with_ns}" != no; then
9982 if test "${opsys}" = darwin; then
9983 NS_IMPL_COCOA=yes
9984 ns_appdir=`pwd`/nextstep/Emacs.app
9985 ns_appbindir=${ns_appdir}/Contents/MacOS
9986 ns_appresdir=${ns_appdir}/Contents/Resources
9987 ns_appsrc=Cocoa/Emacs.base
9988 elif test -f $GNUSTEP_CONFIG_FILE; then
9989 NS_IMPL_GNUSTEP=yes
9990 ns_appdir=`pwd`/nextstep/Emacs.app
9991 ns_appbindir=${ns_appdir}
9992 ns_appresdir=${ns_appdir}/Resources
9993 ns_appsrc=GNUstep/Emacs.base
9994 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9995 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9996 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9997 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9998 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9999 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
10000 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
10001 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
10002 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10003 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10004 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
10005 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
10006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
10007 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
10008 if test "${emacs_cv_objc_exceptions+set}" = set; then :
10009 $as_echo_n "(cached) " >&6
10010 else
10011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10012 /* end confdefs.h. */
10013 #include <GNUstepBase/GSConfig.h>
10015 main ()
10017 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
10019 #else
10020 fail;
10021 #endif
10023 return 0;
10025 _ACEOF
10026 if ac_fn_c_try_compile "$LINENO"; then :
10027 emacs_cv_objc_exceptions=yes
10028 else
10029 emacs_cv_objc_exceptions=no
10031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
10034 $as_echo "$emacs_cv_objc_exceptions" >&6; }
10035 if test $emacs_cv_objc_exceptions = yes; then
10037 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
10039 GNU_OBJC_CFLAGS="-fobjc-exceptions"
10043 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
10045 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
10046 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
10047 HAVE_NS=yes
10048 else
10049 as_fn_error "\`--with-ns' was specified, but the include
10050 files are missing or cannot be compiled." "$LINENO" 5
10055 macfont_file=""
10056 if test "${NS_IMPL_COCOA}" = "yes"; then
10057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.4 or newer" >&5
10058 $as_echo_n "checking for OSX 10.4 or newer... " >&6; }
10059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10060 /* end confdefs.h. */
10061 #include <AppKit/AppKit.h>
10063 main ()
10066 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10067 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
10068 ; /* OK */
10069 #else
10070 #error "OSX 10.4 or newer required"
10071 #endif
10072 #endif
10075 return 0;
10077 _ACEOF
10078 if ac_fn_c_try_compile "$LINENO"; then :
10079 ns_osx_have_104=yes
10080 else
10081 ns_osx_have_104=no
10083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_104" >&5
10085 $as_echo "$ns_osx_have_104" >&6; }
10087 if test $ns_osx_have_104 = no; then
10088 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 or newer" >&5
10091 $as_echo_n "checking for OSX 10.5 or newer... " >&6; }
10092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10093 /* end confdefs.h. */
10094 #include <AppKit/AppKit.h>
10096 main ()
10099 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10100 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
10101 ; /* OK */
10102 #else
10103 #error "OSX 10.5 not found"
10104 #endif
10105 #endif
10108 return 0;
10110 _ACEOF
10111 if ac_fn_c_try_compile "$LINENO"; then :
10112 ns_osx_have_105=yes
10113 else
10114 ns_osx_have_105=no
10116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_105" >&5
10118 $as_echo "$ns_osx_have_105" >&6; }
10119 if test $ns_osx_have_105 = yes; then
10120 macfont_file="macfont.o"
10123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10124 /* end confdefs.h. */
10125 #include <Foundation/NSObjCRuntime.h>
10127 main ()
10129 NSInteger i;
10131 return 0;
10133 _ACEOF
10134 if ac_fn_c_try_compile "$LINENO"; then :
10135 ns_have_nsinteger=yes
10136 else
10137 ns_have_nsinteger=no
10139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10140 if test $ns_have_nsinteger = yes; then
10142 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10149 INSTALL_ARCH_INDEP_EXTRA=install-etc
10150 ns_self_contained=no
10151 NS_OBJ=
10152 NS_OBJC_OBJ=
10153 if test "${HAVE_NS}" = yes; then
10154 if test "$with_toolkit_scroll_bars" = "no"; then
10155 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10158 window_system=nextstep
10159 # set up packaging dirs
10160 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10161 ns_self_contained=yes
10162 prefix=${ns_appresdir}
10163 exec_prefix=${ns_appbindir}
10164 libexecdir="\${ns_appbindir}/libexec"
10165 archlibdir="\${ns_appbindir}/libexec"
10166 etcdocdir="\${ns_appresdir}/etc"
10167 etcdir="\${ns_appresdir}/etc"
10168 infodir="\${ns_appresdir}/info"
10169 mandir="\${ns_appresdir}/man"
10170 lispdir="\${ns_appresdir}/lisp"
10171 leimdir="\${ns_appresdir}/leim"
10172 INSTALL_ARCH_INDEP_EXTRA=
10175 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o $macfont_file"
10177 CFLAGS="$tmp_CFLAGS"
10178 CPPFLAGS="$tmp_CPPFLAGS"
10184 HAVE_W32=no
10185 W32_OBJ=
10186 W32_LIBS=
10187 EMACSRES=
10188 CLIENTRES=
10189 CLIENTW=
10190 W32_RES_LINK=
10191 EMACS_MANIFEST=
10192 UPDATE_MANIFEST=
10193 if test "${with_w32}" != no; then
10194 case "${opsys}" in
10195 cygwin)
10196 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10197 if test "x$ac_cv_header_windows_h" = x""yes; then :
10198 HAVE_W32=yes
10199 else
10200 as_fn_error "\`--with-w32' was specified, but windows.h
10201 cannot be found." "$LINENO" 5
10206 mingw32)
10207 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10210 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10212 esac
10215 if test "${opsys}" = "mingw32"; then
10216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10217 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10219 /* end confdefs.h. */
10221 #include <windows.h>
10222 #include <usp10.h>
10224 main ()
10226 PIMAGE_NT_HEADERS pHeader;
10227 PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader)
10229 return 0;
10231 _ACEOF
10232 if ac_fn_c_try_compile "$LINENO"; then :
10233 emacs_cv_w32api=yes
10234 HAVE_W32=yes
10235 else
10236 emacs_cv_w32api=no
10238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10240 $as_echo "$emacs_cv_w32api" >&6; }
10241 if test "${emacs_cv_w32api}" = "no"; then
10242 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10246 FIRSTFILE_OBJ=
10247 NTDIR=
10248 LIBS_ECLIENT=
10249 LIB_WSOCK32=
10250 NTLIB=
10251 CM_OBJ="cm.o"
10252 XARGS_LIMIT=
10253 if test "${HAVE_W32}" = "yes"; then
10255 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10257 if test -n "$ac_tool_prefix"; then
10258 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10259 set dummy ${ac_tool_prefix}windres; ac_word=$2
10260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10261 $as_echo_n "checking for $ac_word... " >&6; }
10262 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10263 $as_echo_n "(cached) " >&6
10264 else
10265 if test -n "$WINDRES"; then
10266 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10267 else
10268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10269 for as_dir in $PATH
10271 IFS=$as_save_IFS
10272 test -z "$as_dir" && as_dir=.
10273 for ac_exec_ext in '' $ac_executable_extensions; do
10274 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10275 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10277 break 2
10279 done
10280 done
10281 IFS=$as_save_IFS
10285 WINDRES=$ac_cv_prog_WINDRES
10286 if test -n "$WINDRES"; then
10287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10288 $as_echo "$WINDRES" >&6; }
10289 else
10290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10291 $as_echo "no" >&6; }
10296 if test -z "$ac_cv_prog_WINDRES"; then
10297 ac_ct_WINDRES=$WINDRES
10298 # Extract the first word of "windres", so it can be a program name with args.
10299 set dummy windres; ac_word=$2
10300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10301 $as_echo_n "checking for $ac_word... " >&6; }
10302 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10303 $as_echo_n "(cached) " >&6
10304 else
10305 if test -n "$ac_ct_WINDRES"; then
10306 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10307 else
10308 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10309 for as_dir in $PATH
10311 IFS=$as_save_IFS
10312 test -z "$as_dir" && as_dir=.
10313 for ac_exec_ext in '' $ac_executable_extensions; do
10314 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10315 ac_cv_prog_ac_ct_WINDRES="windres"
10316 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10317 break 2
10319 done
10320 done
10321 IFS=$as_save_IFS
10325 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10326 if test -n "$ac_ct_WINDRES"; then
10327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10328 $as_echo "$ac_ct_WINDRES" >&6; }
10329 else
10330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10331 $as_echo "no" >&6; }
10334 if test "x$ac_ct_WINDRES" = x; then
10335 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10336 else
10337 case $cross_compiling:$ac_tool_warned in
10338 yes:)
10339 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10340 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10341 ac_tool_warned=yes ;;
10342 esac
10343 WINDRES=$ac_ct_WINDRES
10345 else
10346 WINDRES="$ac_cv_prog_WINDRES"
10349 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10350 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10351 EMACSRES="emacs.res"
10352 case "$canonical" in
10353 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10354 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10355 esac
10356 UPDATE_MANIFEST=update-game-score.exe.manifest
10357 if test "${opsys}" = "cygwin"; then
10358 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10359 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10360 # Tell the linker that emacs.res is an object (which we compile from
10361 # the rc file), not a linker script.
10362 W32_RES_LINK="-Wl,emacs.res"
10363 else
10364 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10365 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10366 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10367 W32_RES_LINK="\$(EMACSRES)"
10368 CLIENTRES="emacsclient.res"
10369 CLIENTW="emacsclientw\$(EXEEXT)"
10370 FIRSTFILE_OBJ=firstfile.o
10371 NTDIR=nt
10372 CM_OBJ=
10373 LIBS_ECLIENT="-lcomctl32"
10374 LIB_WSOCK32="-lwsock32"
10375 NTLIB="ntlib.$ac_objext"
10376 XARGS_LIMIT="-s 10000"
10395 if test "${HAVE_W32}" = "yes"; then
10396 window_system=w32
10397 with_xft=no
10400 ## $window_system is now set to the window system we will
10401 ## ultimately use.
10403 if test "$window_system" = none && test "$gl_gcc_warnings" = yes; then
10404 # Too many warnings for now.
10406 nw="$nw -Wsuggest-attribute=const"
10407 nw="$nw -Wsuggest-attribute=noreturn"
10409 gl_warn_set=
10410 set x $WARN_CFLAGS; shift
10411 for gl_warn_item
10413 case " $nw " in
10414 *" $gl_warn_item "*)
10417 gl_warn_set="$gl_warn_set $gl_warn_item"
10419 esac
10420 done
10421 WARN_CFLAGS=$gl_warn_set
10425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-variable" >&5
10426 $as_echo_n "checking whether C compiler handles -Wno-unused-variable... " >&6; }
10427 if test "${gl_cv_warn_c__Wno_unused_variable+set}" = set; then :
10428 $as_echo_n "(cached) " >&6
10429 else
10431 gl_save_compiler_FLAGS="$CFLAGS"
10432 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-variable"
10433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10434 /* end confdefs.h. */
10437 main ()
10441 return 0;
10443 _ACEOF
10444 if ac_fn_c_try_compile "$LINENO"; then :
10445 gl_cv_warn_c__Wno_unused_variable=yes
10446 else
10447 gl_cv_warn_c__Wno_unused_variable=no
10449 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10450 CFLAGS="$gl_save_compiler_FLAGS"
10453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_variable" >&5
10454 $as_echo "$gl_cv_warn_c__Wno_unused_variable" >&6; }
10455 if test "x$gl_cv_warn_c__Wno_unused_variable" = x""yes; then :
10456 as_fn_append WARN_CFLAGS " -Wno-unused-variable"
10461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-variable" >&5
10462 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-variable... " >&6; }
10463 if test "${gl_cv_warn_c__Wno_unused_but_set_variable+set}" = set; then :
10464 $as_echo_n "(cached) " >&6
10465 else
10467 gl_save_compiler_FLAGS="$CFLAGS"
10468 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-variable"
10469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10470 /* end confdefs.h. */
10473 main ()
10477 return 0;
10479 _ACEOF
10480 if ac_fn_c_try_compile "$LINENO"; then :
10481 gl_cv_warn_c__Wno_unused_but_set_variable=yes
10482 else
10483 gl_cv_warn_c__Wno_unused_but_set_variable=no
10485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10486 CFLAGS="$gl_save_compiler_FLAGS"
10489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_variable" >&5
10490 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_variable" >&6; }
10491 if test "x$gl_cv_warn_c__Wno_unused_but_set_variable" = x""yes; then :
10492 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-variable"
10497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-parameter" >&5
10498 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-parameter... " >&6; }
10499 if test "${gl_cv_warn_c__Wno_unused_but_set_parameter+set}" = set; then :
10500 $as_echo_n "(cached) " >&6
10501 else
10503 gl_save_compiler_FLAGS="$CFLAGS"
10504 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-parameter"
10505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10506 /* end confdefs.h. */
10509 main ()
10513 return 0;
10515 _ACEOF
10516 if ac_fn_c_try_compile "$LINENO"; then :
10517 gl_cv_warn_c__Wno_unused_but_set_parameter=yes
10518 else
10519 gl_cv_warn_c__Wno_unused_but_set_parameter=no
10521 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10522 CFLAGS="$gl_save_compiler_FLAGS"
10525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_parameter" >&5
10526 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_parameter" >&6; }
10527 if test "x$gl_cv_warn_c__Wno_unused_but_set_parameter" = x""yes; then :
10528 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-parameter"
10534 term_header=
10535 HAVE_X_WINDOWS=no
10536 HAVE_X11=no
10537 USE_X_TOOLKIT=none
10539 case "${window_system}" in
10540 x11 )
10541 HAVE_X_WINDOWS=yes
10542 HAVE_X11=yes
10543 term_header=xterm.h
10544 case "${with_x_toolkit}" in
10545 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10546 motif ) USE_X_TOOLKIT=MOTIF ;;
10547 gtk ) with_gtk=yes
10548 term_header=gtkutil.h
10549 USE_X_TOOLKIT=none ;;
10550 gtk2 ) with_gtk2=yes
10551 term_header=gtkutil.h
10552 USE_X_TOOLKIT=none ;;
10553 gtk3 ) with_gtk3=yes
10554 term_header=gtkutil.h
10555 USE_X_TOOLKIT=none ;;
10556 no ) USE_X_TOOLKIT=none ;;
10557 * ) USE_X_TOOLKIT=maybe ;;
10558 esac
10560 nextstep )
10561 term_header=nsterm.h
10563 w32 )
10564 term_header=w32term.h
10566 esac
10568 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10569 # Extract the first word of "X", so it can be a program name with args.
10570 set dummy X; ac_word=$2
10571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10572 $as_echo_n "checking for $ac_word... " >&6; }
10573 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10574 $as_echo_n "(cached) " >&6
10575 else
10576 if test -n "$HAVE_XSERVER"; then
10577 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10578 else
10579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10580 for as_dir in $PATH
10582 IFS=$as_save_IFS
10583 test -z "$as_dir" && as_dir=.
10584 for ac_exec_ext in '' $ac_executable_extensions; do
10585 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10586 ac_cv_prog_HAVE_XSERVER="true"
10587 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10588 break 2
10590 done
10591 done
10592 IFS=$as_save_IFS
10594 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10597 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10598 if test -n "$HAVE_XSERVER"; then
10599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10600 $as_echo "$HAVE_XSERVER" >&6; }
10601 else
10602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10603 $as_echo "no" >&6; }
10607 if test "$HAVE_XSERVER" = true ||
10608 test -n "$DISPLAY" ||
10609 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10610 as_fn_error "You seem to be running X, but no X development libraries
10611 were found. You should install the relevant development files for X
10612 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10613 sure you have development files for image handling, i.e.
10614 tiff, gif, jpeg, png and xpm.
10615 If you are sure you want Emacs compiled without X window support, pass
10616 --without-x
10617 to configure." "$LINENO" 5
10621 ### If we're using X11, we should use the X menu package.
10622 HAVE_MENUS=no
10623 case ${HAVE_X11} in
10624 yes ) HAVE_MENUS=yes ;;
10625 esac
10627 # Does the opsystem file prohibit the use of the GNU malloc?
10628 # Assume not, until told otherwise.
10629 GNU_MALLOC=yes
10631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10632 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10633 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10634 $as_echo_n "(cached) " >&6
10635 else
10636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10637 /* end confdefs.h. */
10638 #include <malloc.h>
10639 static void hook (void) {}
10641 main ()
10643 malloc_set_state (malloc_get_state ());
10644 __after_morecore_hook = hook;
10645 __malloc_initialize_hook = hook;
10647 return 0;
10649 _ACEOF
10650 if ac_fn_c_try_link "$LINENO"; then :
10651 emacs_cv_var_doug_lea_malloc=yes
10652 else
10653 emacs_cv_var_doug_lea_malloc=no
10655 rm -f core conftest.err conftest.$ac_objext \
10656 conftest$ac_exeext conftest.$ac_ext
10658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10659 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10660 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10663 system_malloc=no
10664 case "$opsys" in
10665 ## darwin ld insists on the use of malloc routines in the System framework.
10666 darwin|sol2-10) system_malloc=yes ;;
10667 esac
10669 if test "${system_malloc}" = "yes"; then
10671 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10673 GNU_MALLOC=no
10674 GNU_MALLOC_reason="
10675 (The GNU allocators don't work with this system configuration.)"
10676 GMALLOC_OBJ=
10677 VMLIMIT_OBJ=
10678 else
10679 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10680 VMLIMIT_OBJ=vm-limit.o
10682 for ac_header in sys/vlimit.h
10683 do :
10684 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10685 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10686 cat >>confdefs.h <<_ACEOF
10687 #define HAVE_SYS_VLIMIT_H 1
10688 _ACEOF
10692 done
10694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10695 $as_echo_n "checking for data_start... " >&6; }
10696 if test "${emacs_cv_data_start+set}" = set; then :
10697 $as_echo_n "(cached) " >&6
10698 else
10699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10700 /* end confdefs.h. */
10701 extern char data_start[]; char ch;
10703 main ()
10705 return data_start < &ch;
10707 return 0;
10709 _ACEOF
10710 if ac_fn_c_try_link "$LINENO"; then :
10711 emacs_cv_data_start=yes
10712 else
10713 emacs_cv_data_start=no
10715 rm -f core conftest.err conftest.$ac_objext \
10716 conftest$ac_exeext conftest.$ac_ext
10718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10719 $as_echo "$emacs_cv_data_start" >&6; }
10720 if test $emacs_cv_data_start = yes; then
10722 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10729 if test "$doug_lea_malloc" = "yes" ; then
10730 if test "$GNU_MALLOC" = yes ; then
10731 GNU_MALLOC_reason="
10732 (Using Doug Lea's new malloc from the GNU C Library.)"
10735 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10738 ## Use mmap directly for allocating larger buffers.
10739 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10740 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10741 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10742 case "$opsys" in
10743 gnu*) REL_ALLOC=no ;;
10744 esac
10747 if test x"${REL_ALLOC}" = x; then
10748 REL_ALLOC=${GNU_MALLOC}
10751 use_mmap_for_buffers=no
10752 case "$opsys" in
10753 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10754 esac
10763 for ac_func in getpagesize
10764 do :
10765 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10766 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10767 cat >>confdefs.h <<_ACEOF
10768 #define HAVE_GETPAGESIZE 1
10769 _ACEOF
10772 done
10774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10775 $as_echo_n "checking for working mmap... " >&6; }
10776 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10777 $as_echo_n "(cached) " >&6
10778 else
10779 if test "$cross_compiling" = yes; then :
10780 ac_cv_func_mmap_fixed_mapped=no
10781 else
10782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10783 /* end confdefs.h. */
10784 $ac_includes_default
10785 /* malloc might have been renamed as rpl_malloc. */
10786 #undef malloc
10788 /* Thanks to Mike Haertel and Jim Avera for this test.
10789 Here is a matrix of mmap possibilities:
10790 mmap private not fixed
10791 mmap private fixed at somewhere currently unmapped
10792 mmap private fixed at somewhere already mapped
10793 mmap shared not fixed
10794 mmap shared fixed at somewhere currently unmapped
10795 mmap shared fixed at somewhere already mapped
10796 For private mappings, we should verify that changes cannot be read()
10797 back from the file, nor mmap's back from the file at a different
10798 address. (There have been systems where private was not correctly
10799 implemented like the infamous i386 svr4.0, and systems where the
10800 VM page cache was not coherent with the file system buffer cache
10801 like early versions of FreeBSD and possibly contemporary NetBSD.)
10802 For shared mappings, we should conversely verify that changes get
10803 propagated back to all the places they're supposed to be.
10805 Grep wants private fixed already mapped.
10806 The main things grep needs to know about mmap are:
10807 * does it exist and is it safe to write into the mmap'd area
10808 * how to use it (BSD variants) */
10810 #include <fcntl.h>
10811 #include <sys/mman.h>
10813 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10814 char *malloc ();
10815 #endif
10817 /* This mess was copied from the GNU getpagesize.h. */
10818 #ifndef HAVE_GETPAGESIZE
10819 # ifdef _SC_PAGESIZE
10820 # define getpagesize() sysconf(_SC_PAGESIZE)
10821 # else /* no _SC_PAGESIZE */
10822 # ifdef HAVE_SYS_PARAM_H
10823 # include <sys/param.h>
10824 # ifdef EXEC_PAGESIZE
10825 # define getpagesize() EXEC_PAGESIZE
10826 # else /* no EXEC_PAGESIZE */
10827 # ifdef NBPG
10828 # define getpagesize() NBPG * CLSIZE
10829 # ifndef CLSIZE
10830 # define CLSIZE 1
10831 # endif /* no CLSIZE */
10832 # else /* no NBPG */
10833 # ifdef NBPC
10834 # define getpagesize() NBPC
10835 # else /* no NBPC */
10836 # ifdef PAGESIZE
10837 # define getpagesize() PAGESIZE
10838 # endif /* PAGESIZE */
10839 # endif /* no NBPC */
10840 # endif /* no NBPG */
10841 # endif /* no EXEC_PAGESIZE */
10842 # else /* no HAVE_SYS_PARAM_H */
10843 # define getpagesize() 8192 /* punt totally */
10844 # endif /* no HAVE_SYS_PARAM_H */
10845 # endif /* no _SC_PAGESIZE */
10847 #endif /* no HAVE_GETPAGESIZE */
10850 main ()
10852 char *data, *data2, *data3;
10853 const char *cdata2;
10854 int i, pagesize;
10855 int fd, fd2;
10857 pagesize = getpagesize ();
10859 /* First, make a file with some known garbage in it. */
10860 data = (char *) malloc (pagesize);
10861 if (!data)
10862 return 1;
10863 for (i = 0; i < pagesize; ++i)
10864 *(data + i) = rand ();
10865 umask (0);
10866 fd = creat ("conftest.mmap", 0600);
10867 if (fd < 0)
10868 return 2;
10869 if (write (fd, data, pagesize) != pagesize)
10870 return 3;
10871 close (fd);
10873 /* Next, check that the tail of a page is zero-filled. File must have
10874 non-zero length, otherwise we risk SIGBUS for entire page. */
10875 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10876 if (fd2 < 0)
10877 return 4;
10878 cdata2 = "";
10879 if (write (fd2, cdata2, 1) != 1)
10880 return 5;
10881 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10882 if (data2 == MAP_FAILED)
10883 return 6;
10884 for (i = 0; i < pagesize; ++i)
10885 if (*(data2 + i))
10886 return 7;
10887 close (fd2);
10888 if (munmap (data2, pagesize))
10889 return 8;
10891 /* Next, try to mmap the file at a fixed address which already has
10892 something else allocated at it. If we can, also make sure that
10893 we see the same garbage. */
10894 fd = open ("conftest.mmap", O_RDWR);
10895 if (fd < 0)
10896 return 9;
10897 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10898 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10899 return 10;
10900 for (i = 0; i < pagesize; ++i)
10901 if (*(data + i) != *(data2 + i))
10902 return 11;
10904 /* Finally, make sure that changes to the mapped area do not
10905 percolate back to the file as seen by read(). (This is a bug on
10906 some variants of i386 svr4.0.) */
10907 for (i = 0; i < pagesize; ++i)
10908 *(data2 + i) = *(data2 + i) + 1;
10909 data3 = (char *) malloc (pagesize);
10910 if (!data3)
10911 return 12;
10912 if (read (fd, data3, pagesize) != pagesize)
10913 return 13;
10914 for (i = 0; i < pagesize; ++i)
10915 if (*(data + i) != *(data3 + i))
10916 return 14;
10917 close (fd);
10918 return 0;
10920 _ACEOF
10921 if ac_fn_c_try_run "$LINENO"; then :
10922 ac_cv_func_mmap_fixed_mapped=yes
10923 else
10924 ac_cv_func_mmap_fixed_mapped=no
10926 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10927 conftest.$ac_objext conftest.beam conftest.$ac_ext
10931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10932 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10933 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10935 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10938 rm -f conftest.mmap conftest.txt
10940 if test $use_mmap_for_buffers = yes; then
10942 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10944 REL_ALLOC=no
10947 LIBS="$LIBS_SYSTEM $LIBS"
10949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10950 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10951 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10952 $as_echo_n "(cached) " >&6
10953 else
10954 ac_check_lib_save_LIBS=$LIBS
10955 LIBS="-ldnet $LIBS"
10956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10957 /* end confdefs.h. */
10959 /* Override any GCC internal prototype to avoid an error.
10960 Use char because int might match the return type of a GCC
10961 builtin and then its argument prototype would still apply. */
10962 #ifdef __cplusplus
10963 extern "C"
10964 #endif
10965 char dnet_ntoa ();
10967 main ()
10969 return dnet_ntoa ();
10971 return 0;
10973 _ACEOF
10974 if ac_fn_c_try_link "$LINENO"; then :
10975 ac_cv_lib_dnet_dnet_ntoa=yes
10976 else
10977 ac_cv_lib_dnet_dnet_ntoa=no
10979 rm -f core conftest.err conftest.$ac_objext \
10980 conftest$ac_exeext conftest.$ac_ext
10981 LIBS=$ac_check_lib_save_LIBS
10983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10984 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10985 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10986 cat >>confdefs.h <<_ACEOF
10987 #define HAVE_LIBDNET 1
10988 _ACEOF
10990 LIBS="-ldnet $LIBS"
10995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10996 $as_echo_n "checking for main in -lXbsd... " >&6; }
10997 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10998 $as_echo_n "(cached) " >&6
10999 else
11000 ac_check_lib_save_LIBS=$LIBS
11001 LIBS="-lXbsd $LIBS"
11002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11003 /* end confdefs.h. */
11007 main ()
11009 return main ();
11011 return 0;
11013 _ACEOF
11014 if ac_fn_c_try_link "$LINENO"; then :
11015 ac_cv_lib_Xbsd_main=yes
11016 else
11017 ac_cv_lib_Xbsd_main=no
11019 rm -f core conftest.err conftest.$ac_objext \
11020 conftest$ac_exeext conftest.$ac_ext
11021 LIBS=$ac_check_lib_save_LIBS
11023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
11024 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
11025 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
11026 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
11030 LIB_PTHREAD=
11034 if test "$ac_cv_header_pthread_h"; then
11035 if test "$GMALLOC_OBJ" = gmalloc.o; then
11036 emacs_pthread_function=pthread_atfork
11037 else
11038 emacs_pthread_function=pthread_self
11040 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
11041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
11042 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
11043 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
11044 $as_echo_n "(cached) " >&6
11045 else
11046 ac_check_lib_save_LIBS=$LIBS
11047 LIBS="-lpthread $LIBS"
11048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11049 /* end confdefs.h. */
11051 /* Override any GCC internal prototype to avoid an error.
11052 Use char because int might match the return type of a GCC
11053 builtin and then its argument prototype would still apply. */
11054 #ifdef __cplusplus
11055 extern "C"
11056 #endif
11057 char $emacs_pthread_function ();
11059 main ()
11061 return $emacs_pthread_function ();
11063 return 0;
11065 _ACEOF
11066 if ac_fn_c_try_link "$LINENO"; then :
11067 eval "$as_ac_Lib=yes"
11068 else
11069 eval "$as_ac_Lib=no"
11071 rm -f core conftest.err conftest.$ac_objext \
11072 conftest$ac_exeext conftest.$ac_ext
11073 LIBS=$ac_check_lib_save_LIBS
11075 eval ac_res=\$$as_ac_Lib
11076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11077 $as_echo "$ac_res" >&6; }
11078 eval as_val=\$$as_ac_Lib
11079 if test "x$as_val" = x""yes; then :
11080 HAVE_PTHREAD=yes
11084 if test "$HAVE_PTHREAD" = yes; then
11085 case "${canonical}" in
11086 *-hpux*) ;;
11087 *) LIB_PTHREAD="-lpthread"
11088 LIBS="$LIB_PTHREAD $LIBS" ;;
11089 esac
11091 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
11096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
11097 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
11098 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
11099 $as_echo_n "(cached) " >&6
11100 else
11101 ac_check_lib_save_LIBS=$LIBS
11102 LIBS="-lpthreads $LIBS"
11103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11104 /* end confdefs.h. */
11106 /* Override any GCC internal prototype to avoid an error.
11107 Use char because int might match the return type of a GCC
11108 builtin and then its argument prototype would still apply. */
11109 #ifdef __cplusplus
11110 extern "C"
11111 #endif
11112 char cma_open ();
11114 main ()
11116 return cma_open ();
11118 return 0;
11120 _ACEOF
11121 if ac_fn_c_try_link "$LINENO"; then :
11122 ac_cv_lib_pthreads_cma_open=yes
11123 else
11124 ac_cv_lib_pthreads_cma_open=no
11126 rm -f core conftest.err conftest.$ac_objext \
11127 conftest$ac_exeext conftest.$ac_ext
11128 LIBS=$ac_check_lib_save_LIBS
11130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
11131 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
11132 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
11133 cat >>confdefs.h <<_ACEOF
11134 #define HAVE_LIBPTHREADS 1
11135 _ACEOF
11137 LIBS="-lpthreads $LIBS"
11142 ## Note: when using cpp in s/aix4.2.h, this definition depended on
11143 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
11144 ## the system file was sourced. Hence the value of LIBS_SYSTEM
11145 ## added to LIBS in configure would never contain the pthreads part,
11146 ## but the value used in Makefiles might. FIXME?
11148 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
11149 ## be harmless on older versions of X where it happens to exist.
11150 test "$opsys" = "aix4-2" && \
11151 test $ac_cv_lib_pthreads_cma_open = yes && \
11152 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
11155 case ${host_os} in
11156 aix*)
11157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
11158 $as_echo_n "checking for -bbigtoc option... " >&6; }
11159 if test "${gdb_cv_bigtoc+set}" = set; then :
11160 $as_echo_n "(cached) " >&6
11161 else
11163 case $GCC in
11164 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
11165 *) gdb_cv_bigtoc=-bbigtoc ;;
11166 esac
11168 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
11169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11170 /* end confdefs.h. */
11173 main ()
11175 int i;
11177 return 0;
11179 _ACEOF
11180 if ac_fn_c_try_link "$LINENO"; then :
11182 else
11183 gdb_cv_bigtoc=
11185 rm -f core conftest.err conftest.$ac_objext \
11186 conftest$ac_exeext conftest.$ac_ext
11189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
11190 $as_echo "$gdb_cv_bigtoc" >&6; }
11192 esac
11194 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
11195 # used for the tests that follow. We set them back to REAL_CFLAGS and
11196 # REAL_CPPFLAGS later on.
11198 REAL_CFLAGS="$CFLAGS"
11199 REAL_CPPFLAGS="$CPPFLAGS"
11201 if test "${HAVE_X11}" = "yes"; then
11202 DEFS="$C_SWITCH_X_SITE $DEFS"
11203 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
11204 LIBS="-lX11 $LIBS"
11205 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
11206 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
11208 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
11209 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
11210 # but it's more convenient here to set LD_RUN_PATH since this
11211 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
11212 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
11213 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
11214 export LD_RUN_PATH
11217 if test "${opsys}" = "gnu-linux"; then
11218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
11219 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
11220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11221 /* end confdefs.h. */
11224 main ()
11226 XOpenDisplay ("foo");
11228 return 0;
11230 _ACEOF
11231 if ac_fn_c_try_link "$LINENO"; then :
11232 xgnu_linux_first_failure=no
11233 else
11234 xgnu_linux_first_failure=yes
11236 rm -f core conftest.err conftest.$ac_objext \
11237 conftest$ac_exeext conftest.$ac_ext
11238 if test "${xgnu_linux_first_failure}" = "yes"; then
11239 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
11240 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
11241 OLD_CPPFLAGS="$CPPFLAGS"
11242 OLD_LIBS="$LIBS"
11243 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
11244 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
11245 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
11246 LIBS="$LIBS -b i486-linuxaout"
11247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11248 /* end confdefs.h. */
11251 main ()
11253 XOpenDisplay ("foo");
11255 return 0;
11257 _ACEOF
11258 if ac_fn_c_try_link "$LINENO"; then :
11259 xgnu_linux_second_failure=no
11260 else
11261 xgnu_linux_second_failure=yes
11263 rm -f core conftest.err conftest.$ac_objext \
11264 conftest$ac_exeext conftest.$ac_ext
11265 if test "${xgnu_linux_second_failure}" = "yes"; then
11266 # If we get the same failure with -b, there is no use adding -b.
11267 # So take it out. This plays safe.
11268 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11269 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11270 CPPFLAGS="$OLD_CPPFLAGS"
11271 LIBS="$OLD_LIBS"
11272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11273 $as_echo "no" >&6; }
11274 else
11275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11276 $as_echo "yes" >&6; }
11278 else
11279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11280 $as_echo "no" >&6; }
11284 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11285 # header files included from there.
11286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11287 $as_echo_n "checking for Xkb... " >&6; }
11288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11289 /* end confdefs.h. */
11290 #include <X11/Xlib.h>
11291 #include <X11/XKBlib.h>
11293 main ()
11295 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11297 return 0;
11299 _ACEOF
11300 if ac_fn_c_try_link "$LINENO"; then :
11301 emacs_xkb=yes
11302 else
11303 emacs_xkb=no
11305 rm -f core conftest.err conftest.$ac_objext \
11306 conftest$ac_exeext conftest.$ac_ext
11307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11308 $as_echo "$emacs_xkb" >&6; }
11309 if test $emacs_xkb = yes; then
11311 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11315 for ac_func in XrmSetDatabase XScreenResourceString \
11316 XScreenNumberOfScreen
11317 do :
11318 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11319 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11320 eval as_val=\$$as_ac_var
11321 if test "x$as_val" = x""yes; then :
11322 cat >>confdefs.h <<_ACEOF
11323 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11324 _ACEOF
11327 done
11331 if test "${window_system}" = "x11"; then
11332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11333 $as_echo_n "checking X11 version 6... " >&6; }
11334 if test "${emacs_cv_x11_version_6+set}" = set; then :
11335 $as_echo_n "(cached) " >&6
11336 else
11337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11338 /* end confdefs.h. */
11339 #include <X11/Xlib.h>
11341 main ()
11343 #if XlibSpecificationRelease < 6
11344 fail;
11345 #endif
11348 return 0;
11350 _ACEOF
11351 if ac_fn_c_try_link "$LINENO"; then :
11352 emacs_cv_x11_version_6=yes
11353 else
11354 emacs_cv_x11_version_6=no
11356 rm -f core conftest.err conftest.$ac_objext \
11357 conftest$ac_exeext conftest.$ac_ext
11360 if test $emacs_cv_x11_version_6 = yes; then
11361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11362 $as_echo "6 or newer" >&6; }
11364 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11367 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11369 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11370 ## XIM support.
11371 case "$opsys" in
11372 sol2-*) : ;;
11374 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11377 esac
11378 else
11379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11380 $as_echo "before 6" >&6; }
11385 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11386 HAVE_RSVG=no
11387 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11388 if test "${with_rsvg}" != "no"; then
11389 RSVG_REQUIRED=2.11.0
11390 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11393 succeeded=no
11395 if test "$PKG_CONFIG" = "no" ; then
11397 else
11398 PKG_CONFIG_MIN_VERSION=0.9.0
11399 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11401 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11403 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11404 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11405 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11406 edit_cflags="
11407 s,///*,/,g
11408 s/^/ /
11409 s/ -I/ $isystem/g
11410 s/^ //
11412 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11413 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11415 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11416 succeeded=yes
11417 else
11418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11419 $as_echo "no" >&6; }
11420 RSVG_CFLAGS=""
11421 RSVG_LIBS=""
11422 ## If we have a custom action on failure, don't print errors, but
11423 ## do set a variable so people can do so. Do it in a subshell
11424 ## to capture any diagnostics in invoking pkg-config.
11425 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11431 else
11432 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11433 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11437 if test $succeeded = yes; then
11438 HAVE_RSVG=yes
11439 else
11446 if test $HAVE_RSVG = yes; then
11448 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11450 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11451 LIBS="$RSVG_LIBS $LIBS"
11456 HAVE_IMAGEMAGICK=no
11457 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
11458 if test "${with_imagemagick}" != "no"; then
11459 ## 6.2.8 is the earliest version known to work, but earlier versions
11460 ## might work - let us know if you find one.
11461 ## 6.0.7 does not work. See bug#7955.
11462 ## 6.8.2 makes Emacs crash; see Bug#13867.
11463 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11465 succeeded=no
11467 if test "$PKG_CONFIG" = "no" ; then
11469 else
11470 PKG_CONFIG_MIN_VERSION=0.9.0
11471 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11473 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11475 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11476 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11477 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11478 edit_cflags="
11479 s,///*,/,g
11480 s/^/ /
11481 s/ -I/ $isystem/g
11482 s/^ //
11484 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11485 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11487 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11488 succeeded=yes
11489 else
11490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11491 $as_echo "no" >&6; }
11492 IMAGEMAGICK_CFLAGS=""
11493 IMAGEMAGICK_LIBS=""
11494 ## If we have a custom action on failure, don't print errors, but
11495 ## do set a variable so people can do so. Do it in a subshell
11496 ## to capture any diagnostics in invoking pkg-config.
11497 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11503 else
11504 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11505 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11509 if test $succeeded = yes; then
11510 HAVE_IMAGEMAGICK=yes
11511 else
11518 if test $HAVE_IMAGEMAGICK = yes; then
11520 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11522 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11523 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11524 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11525 do :
11526 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11527 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11528 eval as_val=\$$as_ac_var
11529 if test "x$as_val" = x""yes; then :
11530 cat >>confdefs.h <<_ACEOF
11531 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11532 _ACEOF
11535 done
11542 HAVE_GTK=no
11543 GTK_OBJ=
11544 gtk_term_header=$term_header
11545 check_gtk2=no
11546 gtk3_pkg_errors=
11547 if test "${opsys}" != "mingw32"; then
11548 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11549 GLIB_REQUIRED=2.28
11550 GTK_REQUIRED=3.0
11551 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11554 succeeded=no
11556 if test "$PKG_CONFIG" = "no" ; then
11557 pkg_check_gtk=no
11558 else
11559 PKG_CONFIG_MIN_VERSION=0.9.0
11560 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11562 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11564 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11565 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11566 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11567 edit_cflags="
11568 s,///*,/,g
11569 s/^/ /
11570 s/ -I/ $isystem/g
11571 s/^ //
11573 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11574 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11576 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11577 succeeded=yes
11578 else
11579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11580 $as_echo "no" >&6; }
11581 GTK_CFLAGS=""
11582 GTK_LIBS=""
11583 ## If we have a custom action on failure, don't print errors, but
11584 ## do set a variable so people can do so. Do it in a subshell
11585 ## to capture any diagnostics in invoking pkg-config.
11586 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11592 else
11593 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11594 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11598 if test $succeeded = yes; then
11599 pkg_check_gtk=yes
11600 else
11601 pkg_check_gtk=no
11604 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11605 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11607 if test "$pkg_check_gtk" = "yes"; then
11609 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11611 GTK_OBJ=emacsgtkfixed.o
11612 gtk_term_header=gtkutil.h
11613 USE_GTK_TOOLKIT="GTK3"
11614 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11615 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11616 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11618 else
11619 check_gtk2=yes
11620 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11624 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11625 GLIB_REQUIRED=2.10
11626 GTK_REQUIRED=2.10
11627 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11630 succeeded=no
11632 if test "$PKG_CONFIG" = "no" ; then
11633 pkg_check_gtk=no
11634 else
11635 PKG_CONFIG_MIN_VERSION=0.9.0
11636 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11638 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11640 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11641 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11642 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11643 edit_cflags="
11644 s,///*,/,g
11645 s/^/ /
11646 s/ -I/ $isystem/g
11647 s/^ //
11649 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11650 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11652 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11653 succeeded=yes
11654 else
11655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11656 $as_echo "no" >&6; }
11657 GTK_CFLAGS=""
11658 GTK_LIBS=""
11659 ## If we have a custom action on failure, don't print errors, but
11660 ## do set a variable so people can do so. Do it in a subshell
11661 ## to capture any diagnostics in invoking pkg-config.
11662 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11668 else
11669 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11670 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11674 if test $succeeded = yes; then
11675 pkg_check_gtk=yes
11676 else
11677 pkg_check_gtk=no
11680 if test "$pkg_check_gtk" = "no" &&
11681 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11682 then
11683 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11685 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11689 if test x"$pkg_check_gtk" = xyes; then
11693 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11694 CFLAGS="$CFLAGS $GTK_CFLAGS"
11695 LIBS="$GTK_LIBS $LIBS"
11696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GTK compiles" >&5
11697 $as_echo_n "checking whether GTK compiles... " >&6; }
11698 GTK_COMPILES=no
11699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11700 /* end confdefs.h. */
11701 /* Check the Gtk and Glib APIs. */
11702 #include <gtk/gtk.h>
11703 #include <glib-object.h>
11704 static void
11705 callback (GObject *go, GParamSpec *spec, gpointer user_data)
11709 main ()
11712 GtkSettings *gs = 0;
11713 /* Use G_CALLBACK to make sure function pointers can be cast to void *;
11714 strict C prohibits this. Use gtk_main_iteration to test that the
11715 libraries are there. */
11716 if (g_signal_handler_find (G_OBJECT (gs), G_SIGNAL_MATCH_FUNC,
11717 0, 0, 0, G_CALLBACK (callback), 0))
11718 gtk_main_iteration ();
11721 return 0;
11723 _ACEOF
11724 if ac_fn_c_try_link "$LINENO"; then :
11725 GTK_COMPILES=yes
11727 rm -f core conftest.err conftest.$ac_objext \
11728 conftest$ac_exeext conftest.$ac_ext
11729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_COMPILES" >&5
11730 $as_echo "$GTK_COMPILES" >&6; }
11731 if test "${GTK_COMPILES}" != "yes"; then
11732 GTK_OBJ=
11733 if test "$USE_X_TOOLKIT" != "maybe"; then
11734 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11736 else
11737 HAVE_GTK=yes
11739 $as_echo "#define USE_GTK 1" >>confdefs.h
11741 GTK_OBJ="gtkutil.o $GTK_OBJ"
11742 term_header=$gtk_term_header
11743 USE_X_TOOLKIT=none
11744 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11746 else
11747 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11748 closing open displays. This is no problem if you just use
11749 one display, but if you use more than one and close one of them
11750 Emacs may crash." >&5
11751 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11752 closing open displays. This is no problem if you just use
11753 one display, but if you use more than one and close one of them
11754 Emacs may crash." >&2;}
11755 sleep 3
11763 if test "${HAVE_GTK}" = "yes"; then
11765 if test "$with_toolkit_scroll_bars" != no; then
11766 with_toolkit_scroll_bars=yes
11769 HAVE_GTK_FILE_SELECTION=no
11770 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11771 #include <gtk/gtk.h>
11773 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11774 HAVE_GTK_FILE_SELECTION=yes
11775 else
11776 HAVE_GTK_FILE_SELECTION=no
11779 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11780 for ac_func in gtk_file_selection_new
11781 do :
11782 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11783 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11784 cat >>confdefs.h <<_ACEOF
11785 #define HAVE_GTK_FILE_SELECTION_NEW 1
11786 _ACEOF
11789 done
11793 HAVE_GTK_HANDLE_BOX=no
11794 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11795 #include <gtk/gtk.h>
11797 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11798 HAVE_GTK_HANDLE_BOX=yes
11799 else
11800 HAVE_GTK_HANDLE_BOX=no
11803 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11804 for ac_func in gtk_handle_box_new
11805 do :
11806 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11807 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11808 cat >>confdefs.h <<_ACEOF
11809 #define HAVE_GTK_HANDLE_BOX_NEW 1
11810 _ACEOF
11813 done
11817 HAVE_GTK_TEAROFF_MENU_ITEM=no
11818 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11819 #include <gtk/gtk.h>
11821 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11822 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11823 else
11824 HAVE_GTK_TEAROFF_MENU_ITEM=no
11827 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11828 for ac_func in gtk_tearoff_menu_item_new
11829 do :
11830 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11831 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11832 cat >>confdefs.h <<_ACEOF
11833 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11834 _ACEOF
11837 done
11841 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11842 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11843 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11844 gtk_orientable_set_orientation \
11845 gtk_window_set_has_resize_grip
11846 do :
11847 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11848 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11849 eval as_val=\$$as_ac_var
11850 if test "x$as_val" = x""yes; then :
11851 cat >>confdefs.h <<_ACEOF
11852 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11853 _ACEOF
11856 done
11859 term_header=gtkutil.h
11862 HAVE_DBUS=no
11863 DBUS_OBJ=
11864 if test "${with_dbus}" = "yes"; then
11866 succeeded=no
11868 if test "$PKG_CONFIG" = "no" ; then
11869 HAVE_DBUS=no
11870 else
11871 PKG_CONFIG_MIN_VERSION=0.9.0
11872 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11874 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11876 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11877 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11878 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11879 edit_cflags="
11880 s,///*,/,g
11881 s/^/ /
11882 s/ -I/ $isystem/g
11883 s/^ //
11885 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11886 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11888 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11889 succeeded=yes
11890 else
11891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11892 $as_echo "no" >&6; }
11893 DBUS_CFLAGS=""
11894 DBUS_LIBS=""
11895 ## If we have a custom action on failure, don't print errors, but
11896 ## do set a variable so people can do so. Do it in a subshell
11897 ## to capture any diagnostics in invoking pkg-config.
11898 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11904 else
11905 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11906 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11910 if test $succeeded = yes; then
11911 HAVE_DBUS=yes
11912 else
11913 HAVE_DBUS=no
11916 if test "$HAVE_DBUS" = yes; then
11917 LIBS="$LIBS $DBUS_LIBS"
11919 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11921 for ac_func in dbus_watch_get_unix_fd \
11922 dbus_type_is_valid \
11923 dbus_validate_bus_name \
11924 dbus_validate_path \
11925 dbus_validate_interface \
11926 dbus_validate_member
11927 do :
11928 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11929 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11930 eval as_val=\$$as_ac_var
11931 if test "x$as_val" = x""yes; then :
11932 cat >>confdefs.h <<_ACEOF
11933 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11934 _ACEOF
11937 done
11939 DBUS_OBJ=dbusbind.o
11944 HAVE_GSETTINGS=no
11945 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11947 succeeded=no
11949 if test "$PKG_CONFIG" = "no" ; then
11950 HAVE_GSETTINGS=no
11951 else
11952 PKG_CONFIG_MIN_VERSION=0.9.0
11953 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11955 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11957 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11958 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11959 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11960 edit_cflags="
11961 s,///*,/,g
11962 s/^/ /
11963 s/ -I/ $isystem/g
11964 s/^ //
11966 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11967 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11969 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11970 succeeded=yes
11971 else
11972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11973 $as_echo "no" >&6; }
11974 GSETTINGS_CFLAGS=""
11975 GSETTINGS_LIBS=""
11976 ## If we have a custom action on failure, don't print errors, but
11977 ## do set a variable so people can do so. Do it in a subshell
11978 ## to capture any diagnostics in invoking pkg-config.
11979 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11985 else
11986 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11987 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11991 if test $succeeded = yes; then
11992 HAVE_GSETTINGS=yes
11993 else
11994 HAVE_GSETTINGS=no
11997 if test "$HAVE_GSETTINGS" = "yes"; then
11999 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
12001 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
12002 SETTINGS_LIBS="$GSETTINGS_LIBS"
12006 HAVE_GCONF=no
12007 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
12009 succeeded=no
12011 if test "$PKG_CONFIG" = "no" ; then
12012 HAVE_GCONF=no
12013 else
12014 PKG_CONFIG_MIN_VERSION=0.9.0
12015 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
12017 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
12019 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
12020 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
12021 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
12022 edit_cflags="
12023 s,///*,/,g
12024 s/^/ /
12025 s/ -I/ $isystem/g
12026 s/^ //
12028 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
12029 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
12030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
12031 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
12032 succeeded=yes
12033 else
12034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12035 $as_echo "no" >&6; }
12036 GCONF_CFLAGS=""
12037 GCONF_LIBS=""
12038 ## If we have a custom action on failure, don't print errors, but
12039 ## do set a variable so people can do so. Do it in a subshell
12040 ## to capture any diagnostics in invoking pkg-config.
12041 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
12047 else
12048 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12049 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12053 if test $succeeded = yes; then
12054 HAVE_GCONF=yes
12055 else
12056 HAVE_GCONF=no
12059 if test "$HAVE_GCONF" = yes; then
12061 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
12063 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
12064 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
12068 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
12070 succeeded=no
12072 if test "$PKG_CONFIG" = "no" ; then
12073 HAVE_GOBJECT=no
12074 else
12075 PKG_CONFIG_MIN_VERSION=0.9.0
12076 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
12078 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
12080 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
12081 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
12082 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
12083 edit_cflags="
12084 s,///*,/,g
12085 s/^/ /
12086 s/ -I/ $isystem/g
12087 s/^ //
12089 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
12090 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
12091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
12092 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
12093 succeeded=yes
12094 else
12095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12096 $as_echo "no" >&6; }
12097 GOBJECT_CFLAGS=""
12098 GOBJECT_LIBS=""
12099 ## If we have a custom action on failure, don't print errors, but
12100 ## do set a variable so people can do so. Do it in a subshell
12101 ## to capture any diagnostics in invoking pkg-config.
12102 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
12108 else
12109 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12110 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12114 if test $succeeded = yes; then
12115 HAVE_GOBJECT=yes
12116 else
12117 HAVE_GOBJECT=no
12120 if test "$HAVE_GOBJECT" = "yes"; then
12121 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
12122 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
12124 SAVE_CFLAGS="$CFLAGS"
12125 SAVE_LIBS="$LIBS"
12126 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
12127 LIBS="$SETTINGS_LIBS $LIBS"
12128 CFLAGS="$SAVE_CFLAGS"
12129 LIBS="$SAVE_LIBS"
12135 HAVE_LIBSELINUX=no
12136 LIBSELINUX_LIBS=
12137 if test "${with_selinux}" = "yes"; then
12138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
12139 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
12140 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
12141 $as_echo_n "(cached) " >&6
12142 else
12143 ac_check_lib_save_LIBS=$LIBS
12144 LIBS="-lselinux $LIBS"
12145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12146 /* end confdefs.h. */
12148 /* Override any GCC internal prototype to avoid an error.
12149 Use char because int might match the return type of a GCC
12150 builtin and then its argument prototype would still apply. */
12151 #ifdef __cplusplus
12152 extern "C"
12153 #endif
12154 char lgetfilecon ();
12156 main ()
12158 return lgetfilecon ();
12160 return 0;
12162 _ACEOF
12163 if ac_fn_c_try_link "$LINENO"; then :
12164 ac_cv_lib_selinux_lgetfilecon=yes
12165 else
12166 ac_cv_lib_selinux_lgetfilecon=no
12168 rm -f core conftest.err conftest.$ac_objext \
12169 conftest$ac_exeext conftest.$ac_ext
12170 LIBS=$ac_check_lib_save_LIBS
12172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
12173 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
12174 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
12175 HAVE_LIBSELINUX=yes
12176 else
12177 HAVE_LIBSELINUX=no
12180 if test "$HAVE_LIBSELINUX" = yes; then
12182 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
12184 LIBSELINUX_LIBS=-lselinux
12189 HAVE_GNUTLS=no
12190 if test "${with_gnutls}" = "yes" ; then
12192 succeeded=no
12194 if test "$PKG_CONFIG" = "no" ; then
12195 HAVE_GNUTLS=no
12196 else
12197 PKG_CONFIG_MIN_VERSION=0.9.0
12198 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
12200 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
12202 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
12203 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
12204 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
12205 edit_cflags="
12206 s,///*,/,g
12207 s/^/ /
12208 s/ -I/ $isystem/g
12209 s/^ //
12211 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
12212 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
12213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
12214 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
12215 succeeded=yes
12216 else
12217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12218 $as_echo "no" >&6; }
12219 LIBGNUTLS_CFLAGS=""
12220 LIBGNUTLS_LIBS=""
12221 ## If we have a custom action on failure, don't print errors, but
12222 ## do set a variable so people can do so. Do it in a subshell
12223 ## to capture any diagnostics in invoking pkg-config.
12224 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
12230 else
12231 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12232 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12236 if test $succeeded = yes; then
12237 HAVE_GNUTLS=yes
12238 else
12239 HAVE_GNUTLS=no
12242 if test "${HAVE_GNUTLS}" = "yes"; then
12244 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
12248 # Windows loads GnuTLS dynamically
12249 if test "${opsys}" = "mingw32"; then
12250 LIBGNUTLS_LIBS=
12251 else
12252 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
12253 LIBS="$LIBGNUTLS_LIBS $LIBS"
12260 NOTIFY_OBJ=
12261 NOTIFY_SUMMARY=no
12263 if test "${with_ns}" = yes && test ${with_file_notification} = yes; then
12264 with_file_notification=no
12267 case $with_file_notification,$opsys in
12268 w32,* | yes,mingw32)
12269 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12270 if test "x$ac_cv_header_windows_h" = x""yes; then :
12275 if test "$ac_cv_header_windows_h" = yes ; then
12277 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12279 NOTIFY_OBJ=w32notify.o
12280 NOTIFY_SUMMARY="yes (w32)"
12281 fi ;;
12282 esac
12284 case $with_file_notification,$NOTIFY_OBJ in
12285 gfile, | yes,)
12287 succeeded=no
12289 if test "$PKG_CONFIG" = "no" ; then
12290 HAVE_GFILENOTIFY=no
12291 else
12292 PKG_CONFIG_MIN_VERSION=0.9.0
12293 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12295 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12297 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12298 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12299 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12300 edit_cflags="
12301 s,///*,/,g
12302 s/^/ /
12303 s/ -I/ $isystem/g
12304 s/^ //
12306 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12307 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12309 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12310 succeeded=yes
12311 else
12312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12313 $as_echo "no" >&6; }
12314 GFILENOTIFY_CFLAGS=""
12315 GFILENOTIFY_LIBS=""
12316 ## If we have a custom action on failure, don't print errors, but
12317 ## do set a variable so people can do so. Do it in a subshell
12318 ## to capture any diagnostics in invoking pkg-config.
12319 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12325 else
12326 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12327 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12331 if test $succeeded = yes; then
12332 HAVE_GFILENOTIFY=yes
12333 else
12334 HAVE_GFILENOTIFY=no
12337 if test "$HAVE_GFILENOTIFY" = "yes"; then
12339 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12341 NOTIFY_OBJ=gfilenotify.o
12342 NOTIFY_SUMMARY="yes -lgio (gfile)"
12343 fi ;;
12344 esac
12346 case $with_file_notification,$NOTIFY_OBJ in
12347 inotify, | yes,)
12348 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12349 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12354 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12355 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12356 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12360 if test "$ac_cv_func_inotify_init1" = yes; then
12362 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12364 NOTIFY_OBJ=inotify.o
12365 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12367 fi ;;
12368 esac
12370 case $with_file_notification,$NOTIFY_OBJ in
12371 yes,* | no,* | *,?*) ;;
12372 *) as_fn_error "File notification \`$with_file_notification' requested but requirements not found." "$LINENO" 5 ;;
12373 esac
12375 if test -n "$NOTIFY_OBJ"; then
12377 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12384 HAVE_XAW3D=no
12385 LUCID_LIBW=
12386 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12387 if test "$with_xaw3d" != no; then
12388 if test "${emacs_cv_xaw3d+set}" = set; then :
12389 $as_echo_n "(cached) " >&6
12390 else
12391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12392 /* end confdefs.h. */
12394 #include <X11/Intrinsic.h>
12395 #include <X11/Xaw3d/Simple.h>
12397 main ()
12401 return 0;
12403 _ACEOF
12404 if ac_fn_c_try_link "$LINENO"; then :
12405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12406 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12407 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12408 $as_echo_n "(cached) " >&6
12409 else
12410 ac_check_lib_save_LIBS=$LIBS
12411 LIBS="-lXaw3d $LIBS"
12412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12413 /* end confdefs.h. */
12415 /* Override any GCC internal prototype to avoid an error.
12416 Use char because int might match the return type of a GCC
12417 builtin and then its argument prototype would still apply. */
12418 #ifdef __cplusplus
12419 extern "C"
12420 #endif
12421 char XawScrollbarSetThumb ();
12423 main ()
12425 return XawScrollbarSetThumb ();
12427 return 0;
12429 _ACEOF
12430 if ac_fn_c_try_link "$LINENO"; then :
12431 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12432 else
12433 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12435 rm -f core conftest.err conftest.$ac_objext \
12436 conftest$ac_exeext conftest.$ac_ext
12437 LIBS=$ac_check_lib_save_LIBS
12439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12440 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12441 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12442 emacs_cv_xaw3d=yes
12443 else
12444 emacs_cv_xaw3d=no
12447 else
12448 emacs_cv_xaw3d=no
12450 rm -f core conftest.err conftest.$ac_objext \
12451 conftest$ac_exeext conftest.$ac_ext
12454 else
12455 emacs_cv_xaw3d=no
12457 if test $emacs_cv_xaw3d = yes; then
12458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12459 $as_echo_n "checking for xaw3d... " >&6; }
12460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12461 $as_echo "yes; using Lucid toolkit" >&6; }
12462 USE_X_TOOLKIT=LUCID
12463 HAVE_XAW3D=yes
12464 LUCID_LIBW=-lXaw3d
12466 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12468 else
12469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12470 $as_echo_n "checking for xaw3d... " >&6; }
12471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12472 $as_echo "no" >&6; }
12473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12474 $as_echo_n "checking for libXaw... " >&6; }
12475 if test "${emacs_cv_xaw+set}" = set; then :
12476 $as_echo_n "(cached) " >&6
12477 else
12478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12479 /* end confdefs.h. */
12481 #include <X11/Intrinsic.h>
12482 #include <X11/Xaw/Simple.h>
12484 main ()
12488 return 0;
12490 _ACEOF
12491 if ac_fn_c_try_link "$LINENO"; then :
12492 emacs_cv_xaw=yes
12493 else
12494 emacs_cv_xaw=no
12496 rm -f core conftest.err conftest.$ac_objext \
12497 conftest$ac_exeext conftest.$ac_ext
12500 if test $emacs_cv_xaw = yes; then
12501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12502 $as_echo "yes; using Lucid toolkit" >&6; }
12503 USE_X_TOOLKIT=LUCID
12504 LUCID_LIBW=-lXaw
12505 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12506 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12507 else
12508 as_fn_error "No X toolkit could be found.
12509 If you are sure you want Emacs compiled without an X toolkit, pass
12510 --with-x-toolkit=no
12511 to configure. Otherwise, install the development libraries for the toolkit
12512 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12517 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12519 LIBXTR6=
12520 if test "${USE_X_TOOLKIT}" != "none"; then
12521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12522 $as_echo_n "checking X11 toolkit version... " >&6; }
12523 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12524 $as_echo_n "(cached) " >&6
12525 else
12526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12527 /* end confdefs.h. */
12528 #include <X11/Intrinsic.h>
12530 main ()
12532 #if XtSpecificationRelease < 6
12533 fail;
12534 #endif
12537 return 0;
12539 _ACEOF
12540 if ac_fn_c_try_link "$LINENO"; then :
12541 emacs_cv_x11_toolkit_version_6=yes
12542 else
12543 emacs_cv_x11_toolkit_version_6=no
12545 rm -f core conftest.err conftest.$ac_objext \
12546 conftest$ac_exeext conftest.$ac_ext
12549 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12550 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12552 $as_echo "6 or newer" >&6; }
12554 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12556 LIBXTR6="-lSM -lICE"
12557 case "$opsys" in
12558 ## Use libw.a along with X11R6 Xt.
12559 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12560 esac
12561 else
12562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12563 $as_echo "before 6" >&6; }
12566 OLDLIBS="$LIBS"
12567 if test x$HAVE_X11XTR6 = xyes; then
12568 LIBS="-lXt -lSM -lICE $LIBS"
12569 else
12570 LIBS="-lXt $LIBS"
12572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12573 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12574 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12575 $as_echo_n "(cached) " >&6
12576 else
12577 ac_check_lib_save_LIBS=$LIBS
12578 LIBS="-lXmu $LIBS"
12579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12580 /* end confdefs.h. */
12582 /* Override any GCC internal prototype to avoid an error.
12583 Use char because int might match the return type of a GCC
12584 builtin and then its argument prototype would still apply. */
12585 #ifdef __cplusplus
12586 extern "C"
12587 #endif
12588 char XmuConvertStandardSelection ();
12590 main ()
12592 return XmuConvertStandardSelection ();
12594 return 0;
12596 _ACEOF
12597 if ac_fn_c_try_link "$LINENO"; then :
12598 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12599 else
12600 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12602 rm -f core conftest.err conftest.$ac_objext \
12603 conftest$ac_exeext conftest.$ac_ext
12604 LIBS=$ac_check_lib_save_LIBS
12606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12607 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12608 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12609 cat >>confdefs.h <<_ACEOF
12610 #define HAVE_LIBXMU 1
12611 _ACEOF
12613 LIBS="-lXmu $LIBS"
12617 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12621 LIBXMU=-lXmu
12622 case $opsys in
12623 ## These systems don't supply Xmu.
12624 hpux* | aix4-2 )
12625 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12627 mingw32 )
12628 LIBXMU=
12630 esac
12633 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12634 if test "${HAVE_X11}" = "yes"; then
12635 if test "${USE_X_TOOLKIT}" != "none"; then
12636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12637 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12638 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12639 $as_echo_n "(cached) " >&6
12640 else
12641 ac_check_lib_save_LIBS=$LIBS
12642 LIBS="-lXext $LIBS"
12643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12644 /* end confdefs.h. */
12646 /* Override any GCC internal prototype to avoid an error.
12647 Use char because int might match the return type of a GCC
12648 builtin and then its argument prototype would still apply. */
12649 #ifdef __cplusplus
12650 extern "C"
12651 #endif
12652 char XShapeQueryExtension ();
12654 main ()
12656 return XShapeQueryExtension ();
12658 return 0;
12660 _ACEOF
12661 if ac_fn_c_try_link "$LINENO"; then :
12662 ac_cv_lib_Xext_XShapeQueryExtension=yes
12663 else
12664 ac_cv_lib_Xext_XShapeQueryExtension=no
12666 rm -f core conftest.err conftest.$ac_objext \
12667 conftest$ac_exeext conftest.$ac_ext
12668 LIBS=$ac_check_lib_save_LIBS
12670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12671 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12672 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12673 cat >>confdefs.h <<_ACEOF
12674 #define HAVE_LIBXEXT 1
12675 _ACEOF
12677 LIBS="-lXext $LIBS"
12684 LIBXP=
12685 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12686 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12687 if test -d /usr/include/openmotif; then
12688 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12689 emacs_cv_openmotif=yes
12690 case "$canonical" in
12691 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12692 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12695 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12696 esac
12697 else
12698 emacs_cv_openmotif=no
12700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12701 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12702 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12703 $as_echo_n "(cached) " >&6
12704 else
12705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12706 /* end confdefs.h. */
12707 #include <Xm/Xm.h>
12709 main ()
12711 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12712 int x = 5;
12713 #else
12714 Motif version prior to 2.1.
12715 #endif
12717 return 0;
12719 _ACEOF
12720 if ac_fn_c_try_compile "$LINENO"; then :
12721 emacs_cv_motif_version_2_1=yes
12722 else
12723 emacs_cv_motif_version_2_1=no
12725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12728 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12729 if test $emacs_cv_motif_version_2_1 = yes; then
12730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12731 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12732 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12733 $as_echo_n "(cached) " >&6
12734 else
12735 ac_check_lib_save_LIBS=$LIBS
12736 LIBS="-lXp $LIBS"
12737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12738 /* end confdefs.h. */
12740 /* Override any GCC internal prototype to avoid an error.
12741 Use char because int might match the return type of a GCC
12742 builtin and then its argument prototype would still apply. */
12743 #ifdef __cplusplus
12744 extern "C"
12745 #endif
12746 char XpCreateContext ();
12748 main ()
12750 return XpCreateContext ();
12752 return 0;
12754 _ACEOF
12755 if ac_fn_c_try_link "$LINENO"; then :
12756 ac_cv_lib_Xp_XpCreateContext=yes
12757 else
12758 ac_cv_lib_Xp_XpCreateContext=no
12760 rm -f core conftest.err conftest.$ac_objext \
12761 conftest$ac_exeext conftest.$ac_ext
12762 LIBS=$ac_check_lib_save_LIBS
12764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12765 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12766 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12767 LIBXP=-lXp
12770 if test x$emacs_cv_openmotif = xyes; then
12771 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12773 else
12774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12775 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12776 if test "${emacs_cv_lesstif+set}" = set; then :
12777 $as_echo_n "(cached) " >&6
12778 else
12779 # We put this in CFLAGS temporarily to precede other -I options
12780 # that might be in CFLAGS temporarily.
12781 # We put this in CPPFLAGS where it precedes the other -I options.
12782 OLD_CPPFLAGS=$CPPFLAGS
12783 OLD_CFLAGS=$CFLAGS
12784 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12785 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12787 /* end confdefs.h. */
12788 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12790 main ()
12792 int x = 5;
12794 return 0;
12796 _ACEOF
12797 if ac_fn_c_try_compile "$LINENO"; then :
12798 emacs_cv_lesstif=yes
12799 else
12800 emacs_cv_lesstif=no
12802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12805 $as_echo "$emacs_cv_lesstif" >&6; }
12806 if test $emacs_cv_lesstif = yes; then
12807 # Make sure this -I option remains in CPPFLAGS after it is set
12808 # back to REAL_CPPFLAGS.
12809 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12810 # have those other -I options anyway. Ultimately, having this
12811 # directory ultimately in CPPFLAGS will be enough.
12812 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12813 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12814 else
12815 CFLAGS=$OLD_CFLAGS
12816 CPPFLAGS=$OLD_CPPFLAGS
12819 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12820 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12822 else
12823 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12830 USE_TOOLKIT_SCROLL_BARS=no
12831 if test "${with_toolkit_scroll_bars}" != "no"; then
12832 if test "${USE_X_TOOLKIT}" != "none"; then
12833 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12834 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12836 HAVE_XAW3D=no
12837 USE_TOOLKIT_SCROLL_BARS=yes
12838 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12839 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12841 USE_TOOLKIT_SCROLL_BARS=yes
12843 elif test "${HAVE_GTK}" = "yes"; then
12844 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12846 USE_TOOLKIT_SCROLL_BARS=yes
12847 elif test "${HAVE_NS}" = "yes"; then
12848 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12850 USE_TOOLKIT_SCROLL_BARS=yes
12851 elif test "${HAVE_W32}" = "yes"; then
12852 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12854 USE_TOOLKIT_SCROLL_BARS=yes
12858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12859 /* end confdefs.h. */
12861 #include <X11/Xlib.h>
12862 #include <X11/Xresource.h>
12864 main ()
12866 XIMProc callback;
12868 return 0;
12870 _ACEOF
12871 if ac_fn_c_try_compile "$LINENO"; then :
12872 HAVE_XIM=yes
12874 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12876 else
12877 HAVE_XIM=no
12879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12882 if test "${with_xim}" != "no"; then
12884 $as_echo "#define USE_XIM 1" >>confdefs.h
12889 if test "${HAVE_XIM}" != "no"; then
12890 late_CFLAGS=$CFLAGS
12891 if test "$GCC" = yes; then
12892 CFLAGS="$CFLAGS --pedantic-errors"
12894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12895 /* end confdefs.h. */
12897 #include <X11/Xlib.h>
12898 #include <X11/Xresource.h>
12900 main ()
12902 Display *display;
12903 XrmDatabase db;
12904 char *res_name;
12905 char *res_class;
12906 XIMProc callback;
12907 XPointer *client_data;
12908 #ifndef __GNUC__
12909 /* If we're not using GCC, it's probably not XFree86, and this is
12910 probably right, but we can't use something like --pedantic-errors. */
12911 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12912 char*, XIMProc, XPointer*);
12913 #endif
12914 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12915 client_data);
12917 return 0;
12919 _ACEOF
12920 if ac_fn_c_try_compile "$LINENO"; then :
12921 emacs_cv_arg6_star=yes
12923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12924 if test "$emacs_cv_arg6_star" = yes; then
12925 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12927 else
12928 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12931 CFLAGS=$late_CFLAGS
12934 ### Start of font-backend (under any platform) section.
12935 # (nothing here yet -- this is a placeholder)
12936 ### End of font-backend (under any platform) section.
12938 ### Start of font-backend (under X11) section.
12939 if test "${HAVE_X11}" = "yes"; then
12941 succeeded=no
12943 if test "$PKG_CONFIG" = "no" ; then
12944 HAVE_FC=no
12945 else
12946 PKG_CONFIG_MIN_VERSION=0.9.0
12947 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12949 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12951 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12952 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12953 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12954 edit_cflags="
12955 s,///*,/,g
12956 s/^/ /
12957 s/ -I/ $isystem/g
12958 s/^ //
12960 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12961 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12963 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12964 succeeded=yes
12965 else
12966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12967 $as_echo "no" >&6; }
12968 FONTCONFIG_CFLAGS=""
12969 FONTCONFIG_LIBS=""
12970 ## If we have a custom action on failure, don't print errors, but
12971 ## do set a variable so people can do so. Do it in a subshell
12972 ## to capture any diagnostics in invoking pkg-config.
12973 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12979 else
12980 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12981 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12985 if test $succeeded = yes; then
12986 HAVE_FC=yes
12987 else
12988 HAVE_FC=no
12992 ## Use -lXft if available, unless `--with-xft=no'.
12993 HAVE_XFT=maybe
12994 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12995 with_xft="no";
12997 if test "x${with_xft}" != "xno"; then
13000 succeeded=no
13002 if test "$PKG_CONFIG" = "no" ; then
13003 HAVE_XFT=no
13004 else
13005 PKG_CONFIG_MIN_VERSION=0.9.0
13006 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
13008 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
13010 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
13011 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
13012 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
13013 edit_cflags="
13014 s,///*,/,g
13015 s/^/ /
13016 s/ -I/ $isystem/g
13017 s/^ //
13019 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
13020 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
13021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
13022 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
13023 succeeded=yes
13024 else
13025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13026 $as_echo "no" >&6; }
13027 XFT_CFLAGS=""
13028 XFT_LIBS=""
13029 ## If we have a custom action on failure, don't print errors, but
13030 ## do set a variable so people can do so. Do it in a subshell
13031 ## to capture any diagnostics in invoking pkg-config.
13032 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
13038 else
13039 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13040 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13044 if test $succeeded = yes; then
13046 else
13047 HAVE_XFT=no
13050 ## Because xftfont.c uses XRenderQueryExtension, we also
13051 ## need to link to -lXrender.
13052 HAVE_XRENDER=no
13053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
13054 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
13055 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
13056 $as_echo_n "(cached) " >&6
13057 else
13058 ac_check_lib_save_LIBS=$LIBS
13059 LIBS="-lXrender $LIBS"
13060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13061 /* end confdefs.h. */
13063 /* Override any GCC internal prototype to avoid an error.
13064 Use char because int might match the return type of a GCC
13065 builtin and then its argument prototype would still apply. */
13066 #ifdef __cplusplus
13067 extern "C"
13068 #endif
13069 char XRenderQueryExtension ();
13071 main ()
13073 return XRenderQueryExtension ();
13075 return 0;
13077 _ACEOF
13078 if ac_fn_c_try_link "$LINENO"; then :
13079 ac_cv_lib_Xrender_XRenderQueryExtension=yes
13080 else
13081 ac_cv_lib_Xrender_XRenderQueryExtension=no
13083 rm -f core conftest.err conftest.$ac_objext \
13084 conftest$ac_exeext conftest.$ac_ext
13085 LIBS=$ac_check_lib_save_LIBS
13087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
13088 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
13089 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
13090 HAVE_XRENDER=yes
13093 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
13094 OLD_CPPFLAGS="$CPPFLAGS"
13095 OLD_CFLAGS="$CFLAGS"
13096 OLD_LIBS="$LIBS"
13097 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
13098 CFLAGS="$CFLAGS $XFT_CFLAGS"
13099 XFT_LIBS="-lXrender $XFT_LIBS"
13100 LIBS="$XFT_LIBS $LIBS"
13101 ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/X.h>
13103 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
13104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
13105 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
13106 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
13107 $as_echo_n "(cached) " >&6
13108 else
13109 ac_check_lib_save_LIBS=$LIBS
13110 LIBS="-lXft $XFT_LIBS $LIBS"
13111 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13112 /* end confdefs.h. */
13114 /* Override any GCC internal prototype to avoid an error.
13115 Use char because int might match the return type of a GCC
13116 builtin and then its argument prototype would still apply. */
13117 #ifdef __cplusplus
13118 extern "C"
13119 #endif
13120 char XftFontOpen ();
13122 main ()
13124 return XftFontOpen ();
13126 return 0;
13128 _ACEOF
13129 if ac_fn_c_try_link "$LINENO"; then :
13130 ac_cv_lib_Xft_XftFontOpen=yes
13131 else
13132 ac_cv_lib_Xft_XftFontOpen=no
13134 rm -f core conftest.err conftest.$ac_objext \
13135 conftest$ac_exeext conftest.$ac_ext
13136 LIBS=$ac_check_lib_save_LIBS
13138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
13139 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
13140 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
13141 HAVE_XFT=yes
13148 if test "${HAVE_XFT}" = "yes"; then
13150 $as_echo "#define HAVE_XFT 1" >>confdefs.h
13153 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
13154 else
13155 CPPFLAGS="$OLD_CPPFLAGS"
13156 CFLAGS="$OLD_CFLAGS"
13157 LIBS="$OLD_LIBS"
13158 fi # "${HAVE_XFT}" = "yes"
13159 fi # "$HAVE_XFT" != no
13160 fi # "x${with_xft}" != "xno"
13162 ## We used to allow building with FreeType and without Xft.
13163 ## However, the ftx font backend driver is not in good shape.
13164 if test "$HAVE_XFT" != "yes"; then
13165 HAVE_XFT=no
13166 HAVE_FREETYPE=no
13167 else
13169 succeeded=no
13171 if test "$PKG_CONFIG" = "no" ; then
13172 HAVE_FREETYPE=no
13173 else
13174 PKG_CONFIG_MIN_VERSION=0.9.0
13175 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
13177 $as_echo_n "checking for freetype2... " >&6; }
13179 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
13180 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
13181 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
13182 edit_cflags="
13183 s,///*,/,g
13184 s/^/ /
13185 s/ -I/ $isystem/g
13186 s/^ //
13188 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
13189 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
13190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
13191 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
13192 succeeded=yes
13193 else
13194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13195 $as_echo "no" >&6; }
13196 FREETYPE_CFLAGS=""
13197 FREETYPE_LIBS=""
13198 ## If we have a custom action on failure, don't print errors, but
13199 ## do set a variable so people can do so. Do it in a subshell
13200 ## to capture any diagnostics in invoking pkg-config.
13201 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
13207 else
13208 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13209 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13213 if test $succeeded = yes; then
13214 HAVE_FREETYPE=yes
13215 else
13216 HAVE_FREETYPE=no
13220 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
13223 HAVE_LIBOTF=no
13224 if test "${HAVE_FREETYPE}" = "yes"; then
13226 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
13228 if test "${with_libotf}" != "no"; then
13230 succeeded=no
13232 if test "$PKG_CONFIG" = "no" ; then
13233 HAVE_LIBOTF=no
13234 else
13235 PKG_CONFIG_MIN_VERSION=0.9.0
13236 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
13238 $as_echo_n "checking for libotf... " >&6; }
13240 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13241 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13242 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13243 edit_cflags="
13244 s,///*,/,g
13245 s/^/ /
13246 s/ -I/ $isystem/g
13247 s/^ //
13249 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13250 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13252 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13253 succeeded=yes
13254 else
13255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13256 $as_echo "no" >&6; }
13257 LIBOTF_CFLAGS=""
13258 LIBOTF_LIBS=""
13259 ## If we have a custom action on failure, don't print errors, but
13260 ## do set a variable so people can do so. Do it in a subshell
13261 ## to capture any diagnostics in invoking pkg-config.
13262 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13268 else
13269 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13270 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13274 if test $succeeded = yes; then
13275 HAVE_LIBOTF=yes
13276 else
13277 HAVE_LIBOTF=no
13280 if test "$HAVE_LIBOTF" = "yes"; then
13282 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13285 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13286 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13287 $as_echo_n "(cached) " >&6
13288 else
13289 ac_check_lib_save_LIBS=$LIBS
13290 LIBS="-lotf $LIBS"
13291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13292 /* end confdefs.h. */
13294 /* Override any GCC internal prototype to avoid an error.
13295 Use char because int might match the return type of a GCC
13296 builtin and then its argument prototype would still apply. */
13297 #ifdef __cplusplus
13298 extern "C"
13299 #endif
13300 char OTF_get_variation_glyphs ();
13302 main ()
13304 return OTF_get_variation_glyphs ();
13306 return 0;
13308 _ACEOF
13309 if ac_fn_c_try_link "$LINENO"; then :
13310 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13311 else
13312 ac_cv_lib_otf_OTF_get_variation_glyphs=no
13314 rm -f core conftest.err conftest.$ac_objext \
13315 conftest$ac_exeext conftest.$ac_ext
13316 LIBS=$ac_check_lib_save_LIBS
13318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
13319 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13320 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13321 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13322 else
13323 HAVE_OTF_GET_VARIATION_GLYPHS=no
13326 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13328 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13335 HAVE_M17N_FLT=no
13336 if test "${HAVE_LIBOTF}" = yes; then
13337 if test "${with_m17n_flt}" != "no"; then
13339 succeeded=no
13341 if test "$PKG_CONFIG" = "no" ; then
13342 HAVE_M17N_FLT=no
13343 else
13344 PKG_CONFIG_MIN_VERSION=0.9.0
13345 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13347 $as_echo_n "checking for m17n-flt... " >&6; }
13349 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13350 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13351 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13352 edit_cflags="
13353 s,///*,/,g
13354 s/^/ /
13355 s/ -I/ $isystem/g
13356 s/^ //
13358 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13359 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13361 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13362 succeeded=yes
13363 else
13364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13365 $as_echo "no" >&6; }
13366 M17N_FLT_CFLAGS=""
13367 M17N_FLT_LIBS=""
13368 ## If we have a custom action on failure, don't print errors, but
13369 ## do set a variable so people can do so. Do it in a subshell
13370 ## to capture any diagnostics in invoking pkg-config.
13371 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13377 else
13378 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13379 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13383 if test $succeeded = yes; then
13384 HAVE_M17N_FLT=yes
13385 else
13386 HAVE_M17N_FLT=no
13389 if test "$HAVE_M17N_FLT" = "yes"; then
13391 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13396 else
13397 HAVE_XFT=no
13398 HAVE_FREETYPE=no
13399 HAVE_LIBOTF=no
13400 HAVE_M17N_FLT=no
13403 ### End of font-backend (under X11) section.
13414 ### Use -lXpm if available, unless `--with-xpm=no'.
13415 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13416 HAVE_XPM=no
13417 LIBXPM=
13418 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13419 if test "${with_xpm}" != "no"; then
13420 SAVE_CPPFLAGS="$CPPFLAGS"
13421 SAVE_LDFLAGS="$LDFLAGS"
13422 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13423 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13424 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13425 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13427 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13428 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13429 $as_echo_n "(cached) " >&6
13430 else
13431 ac_check_lib_save_LIBS=$LIBS
13432 LIBS="-lXpm $LIBS"
13433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13434 /* end confdefs.h. */
13436 /* Override any GCC internal prototype to avoid an error.
13437 Use char because int might match the return type of a GCC
13438 builtin and then its argument prototype would still apply. */
13439 #ifdef __cplusplus
13440 extern "C"
13441 #endif
13442 char XpmReadFileToImage ();
13444 main ()
13446 return XpmReadFileToImage ();
13448 return 0;
13450 _ACEOF
13451 if ac_fn_c_try_link "$LINENO"; then :
13452 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13453 else
13454 ac_cv_lib_Xpm_XpmReadFileToImage=no
13456 rm -f core conftest.err conftest.$ac_objext \
13457 conftest$ac_exeext conftest.$ac_ext
13458 LIBS=$ac_check_lib_save_LIBS
13460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13461 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13462 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13463 HAVE_XPM=yes
13469 if test "${HAVE_XPM}" = "yes"; then
13470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13471 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13473 /* end confdefs.h. */
13474 #include "X11/xpm.h"
13475 #ifndef XpmReturnAllocPixels
13476 no_return_alloc_pixels
13477 #endif
13479 _ACEOF
13480 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13481 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13482 HAVE_XPM=no
13483 else
13484 HAVE_XPM=yes
13486 rm -f conftest*
13489 if test "${HAVE_XPM}" = "yes"; then
13490 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13492 $as_echo "yes" >&6; }
13493 else
13494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13495 $as_echo "no" >&6; }
13496 CPPFLAGS="$SAVE_CPPFLAGS"
13497 LDFLAGS="$SAVE_LDFLAGS"
13502 if test "${HAVE_XPM}" = "yes"; then
13504 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13506 LIBXPM=-lXpm
13510 if test "${HAVE_X11}" = "yes"; then
13511 if test "${with_xpm}" != "no"; then
13512 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13513 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13515 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13516 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13517 $as_echo_n "(cached) " >&6
13518 else
13519 ac_check_lib_save_LIBS=$LIBS
13520 LIBS="-lXpm -lX11 $LIBS"
13521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13522 /* end confdefs.h. */
13524 /* Override any GCC internal prototype to avoid an error.
13525 Use char because int might match the return type of a GCC
13526 builtin and then its argument prototype would still apply. */
13527 #ifdef __cplusplus
13528 extern "C"
13529 #endif
13530 char XpmReadFileToPixmap ();
13532 main ()
13534 return XpmReadFileToPixmap ();
13536 return 0;
13538 _ACEOF
13539 if ac_fn_c_try_link "$LINENO"; then :
13540 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13541 else
13542 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13544 rm -f core conftest.err conftest.$ac_objext \
13545 conftest$ac_exeext conftest.$ac_ext
13546 LIBS=$ac_check_lib_save_LIBS
13548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13549 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13550 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13551 HAVE_XPM=yes
13557 if test "${HAVE_XPM}" = "yes"; then
13558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13559 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13561 /* end confdefs.h. */
13562 #include "X11/xpm.h"
13563 #ifndef XpmReturnAllocPixels
13564 no_return_alloc_pixels
13565 #endif
13567 _ACEOF
13568 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13569 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13570 HAVE_XPM=no
13571 else
13572 HAVE_XPM=yes
13574 rm -f conftest*
13577 if test "${HAVE_XPM}" = "yes"; then
13578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13579 $as_echo "yes" >&6; }
13580 else
13581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13582 $as_echo "no" >&6; }
13587 if test "${HAVE_XPM}" = "yes"; then
13589 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13591 LIBXPM=-lXpm
13595 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13596 ### slightly different requirements wrt image libraries (it doesn't
13597 ### use -lXpm because it loads the xpm shared library dynamically at
13598 ### run time).
13599 if test "${opsys}" = "mingw32"; then
13600 if test "${with_xpm}" != "no"; then
13601 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13602 #define FOR_MSW 1
13604 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13605 HAVE_XPM=yes
13606 else
13607 HAVE_XPM=no
13613 if test "${HAVE_XPM}" = "yes"; then
13615 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13622 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13623 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13624 HAVE_JPEG=no
13625 LIBJPEG=
13626 if test "${opsys}" = "mingw32"; then
13627 if test "${with_jpeg}" != "no"; then
13628 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13629 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13630 HAVE_JPEG=yes
13631 else
13632 HAVE_JPEG=no
13637 if test "${HAVE_JPEG}" = "yes"; then
13638 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13641 /* end confdefs.h. */
13642 #include <jpeglib.h>
13643 version=JPEG_LIB_VERSION
13645 _ACEOF
13646 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13647 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13648 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13650 else
13651 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13652 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13653 HAVE_JPEG=no
13655 rm -f conftest*
13658 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13659 if test "${with_jpeg}" != "no"; then
13660 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13661 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13663 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13664 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13665 $as_echo_n "(cached) " >&6
13666 else
13667 ac_check_lib_save_LIBS=$LIBS
13668 LIBS="-ljpeg $LIBS"
13669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13670 /* end confdefs.h. */
13672 /* Override any GCC internal prototype to avoid an error.
13673 Use char because int might match the return type of a GCC
13674 builtin and then its argument prototype would still apply. */
13675 #ifdef __cplusplus
13676 extern "C"
13677 #endif
13678 char jpeg_destroy_compress ();
13680 main ()
13682 return jpeg_destroy_compress ();
13684 return 0;
13686 _ACEOF
13687 if ac_fn_c_try_link "$LINENO"; then :
13688 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13689 else
13690 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13692 rm -f core conftest.err conftest.$ac_objext \
13693 conftest$ac_exeext conftest.$ac_ext
13694 LIBS=$ac_check_lib_save_LIBS
13696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13697 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13698 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13699 HAVE_JPEG=yes
13707 if test "${HAVE_JPEG}" = "yes"; then
13708 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13711 /* end confdefs.h. */
13712 #include <jpeglib.h>
13713 version=JPEG_LIB_VERSION
13715 _ACEOF
13716 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13717 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13718 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13720 else
13721 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13722 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13723 HAVE_JPEG=no
13725 rm -f conftest*
13728 if test "${HAVE_JPEG}" = "yes"; then
13729 LIBJPEG=-ljpeg
13734 ### Use -lpng if available, unless `--with-png=no'.
13735 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13736 HAVE_PNG=no
13737 LIBPNG=
13738 if test "${opsys}" = "mingw32"; then
13739 if test "${with_png}" != "no"; then
13740 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13741 if test "x$ac_cv_header_png_h" = x""yes; then :
13742 HAVE_PNG=yes
13743 else
13744 HAVE_PNG=no
13749 if test "${HAVE_PNG}" = "yes"; then
13751 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13754 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13755 # include <libpng/png.h>
13756 #else
13757 # include <png.h>
13758 #endif
13761 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13763 else
13765 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13770 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13771 if test "${with_png}" != "no"; then
13772 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13773 # in /usr/include/libpng.
13774 for ac_header in png.h libpng/png.h
13775 do :
13776 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13777 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13778 eval as_val=\$$as_ac_Header
13779 if test "x$as_val" = x""yes; then :
13780 cat >>confdefs.h <<_ACEOF
13781 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13782 _ACEOF
13783 break
13786 done
13788 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13790 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13791 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13792 $as_echo_n "(cached) " >&6
13793 else
13794 ac_check_lib_save_LIBS=$LIBS
13795 LIBS="-lpng -lz -lm $LIBS"
13796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13797 /* end confdefs.h. */
13799 /* Override any GCC internal prototype to avoid an error.
13800 Use char because int might match the return type of a GCC
13801 builtin and then its argument prototype would still apply. */
13802 #ifdef __cplusplus
13803 extern "C"
13804 #endif
13805 char png_get_channels ();
13807 main ()
13809 return png_get_channels ();
13811 return 0;
13813 _ACEOF
13814 if ac_fn_c_try_link "$LINENO"; then :
13815 ac_cv_lib_png_png_get_channels=yes
13816 else
13817 ac_cv_lib_png_png_get_channels=no
13819 rm -f core conftest.err conftest.$ac_objext \
13820 conftest$ac_exeext conftest.$ac_ext
13821 LIBS=$ac_check_lib_save_LIBS
13823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13824 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13825 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13826 HAVE_PNG=yes
13832 if test "${HAVE_PNG}" = "yes"; then
13834 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13836 LIBPNG="-lpng -lz -lm"
13838 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13839 # include <libpng/png.h>
13840 #else
13841 # include <png.h>
13842 #endif
13845 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13847 else
13849 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13857 HAVE_ZLIB=no
13858 LIBZ=
13859 if test "${with_zlib}" != "no"; then
13860 OLIBS=$LIBS
13861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inflateEnd" >&5
13862 $as_echo_n "checking for library containing inflateEnd... " >&6; }
13863 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13864 $as_echo_n "(cached) " >&6
13865 else
13866 ac_func_search_save_LIBS=$LIBS
13867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13868 /* end confdefs.h. */
13870 /* Override any GCC internal prototype to avoid an error.
13871 Use char because int might match the return type of a GCC
13872 builtin and then its argument prototype would still apply. */
13873 #ifdef __cplusplus
13874 extern "C"
13875 #endif
13876 char inflateEnd ();
13878 main ()
13880 return inflateEnd ();
13882 return 0;
13884 _ACEOF
13885 for ac_lib in '' z; do
13886 if test -z "$ac_lib"; then
13887 ac_res="none required"
13888 else
13889 ac_res=-l$ac_lib
13890 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
13892 if ac_fn_c_try_link "$LINENO"; then :
13893 ac_cv_search_inflateEnd=$ac_res
13895 rm -f core conftest.err conftest.$ac_objext \
13896 conftest$ac_exeext
13897 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13898 break
13900 done
13901 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13903 else
13904 ac_cv_search_inflateEnd=no
13906 rm conftest.$ac_ext
13907 LIBS=$ac_func_search_save_LIBS
13909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inflateEnd" >&5
13910 $as_echo "$ac_cv_search_inflateEnd" >&6; }
13911 ac_res=$ac_cv_search_inflateEnd
13912 if test "$ac_res" != no; then :
13913 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13914 HAVE_ZLIB=yes
13917 LIBS=$OLIBS
13918 case $ac_cv_search_inflateEnd in
13919 -*) LIBZ=$ac_cv_search_inflateEnd ;;
13920 esac
13922 if test "${HAVE_ZLIB}" = "yes"; then
13924 $as_echo "#define HAVE_ZLIB 1" >>confdefs.h
13926 ### mingw32 doesn't use -lz, since it loads the library dynamically.
13927 if test "${opsys}" = "mingw32"; then
13928 LIBZ=
13934 ### Use -ltiff if available, unless `--with-tiff=no'.
13935 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
13936 HAVE_TIFF=no
13937 LIBTIFF=
13938 if test "${opsys}" = "mingw32"; then
13939 if test "${with_tiff}" != "no"; then
13940 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13941 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13942 HAVE_TIFF=yes
13943 else
13944 HAVE_TIFF=no
13949 if test "${HAVE_TIFF}" = "yes"; then
13951 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13954 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13955 if test "${with_tiff}" != "no"; then
13956 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13957 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13958 tifflibs="-lz -lm"
13959 # At least one tiff package requires the jpeg library.
13960 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13962 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
13963 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
13964 $as_echo_n "(cached) " >&6
13965 else
13966 ac_check_lib_save_LIBS=$LIBS
13967 LIBS="-ltiff $tifflibs $LIBS"
13968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13969 /* end confdefs.h. */
13971 /* Override any GCC internal prototype to avoid an error.
13972 Use char because int might match the return type of a GCC
13973 builtin and then its argument prototype would still apply. */
13974 #ifdef __cplusplus
13975 extern "C"
13976 #endif
13977 char TIFFGetVersion ();
13979 main ()
13981 return TIFFGetVersion ();
13983 return 0;
13985 _ACEOF
13986 if ac_fn_c_try_link "$LINENO"; then :
13987 ac_cv_lib_tiff_TIFFGetVersion=yes
13988 else
13989 ac_cv_lib_tiff_TIFFGetVersion=no
13991 rm -f core conftest.err conftest.$ac_objext \
13992 conftest$ac_exeext conftest.$ac_ext
13993 LIBS=$ac_check_lib_save_LIBS
13995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13996 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13997 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13998 HAVE_TIFF=yes
14006 if test "${HAVE_TIFF}" = "yes"; then
14008 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
14010 LIBTIFF=-ltiff
14015 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
14016 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
14017 HAVE_GIF=no
14018 LIBGIF=
14019 if test "${opsys}" = "mingw32"; then
14020 if test "${with_gif}" != "no"; then
14021 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14022 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14023 HAVE_GIF=yes
14024 else
14025 HAVE_GIF=no
14030 if test "${HAVE_GIF}" = "yes"; then
14032 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14035 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
14036 || test "${HAVE_W32}" = "yes"; then
14037 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14038 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14039 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
14040 # Earlier versions can crash Emacs.
14041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
14042 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
14043 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
14044 $as_echo_n "(cached) " >&6
14045 else
14046 ac_check_lib_save_LIBS=$LIBS
14047 LIBS="-lgif $LIBS"
14048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14049 /* end confdefs.h. */
14051 /* Override any GCC internal prototype to avoid an error.
14052 Use char because int might match the return type of a GCC
14053 builtin and then its argument prototype would still apply. */
14054 #ifdef __cplusplus
14055 extern "C"
14056 #endif
14057 char EGifPutExtensionLast ();
14059 main ()
14061 return EGifPutExtensionLast ();
14063 return 0;
14065 _ACEOF
14066 if ac_fn_c_try_link "$LINENO"; then :
14067 ac_cv_lib_gif_EGifPutExtensionLast=yes
14068 else
14069 ac_cv_lib_gif_EGifPutExtensionLast=no
14071 rm -f core conftest.err conftest.$ac_objext \
14072 conftest$ac_exeext conftest.$ac_ext
14073 LIBS=$ac_check_lib_save_LIBS
14075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
14076 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
14077 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
14078 HAVE_GIF=yes
14079 else
14080 HAVE_GIF=maybe
14087 if test "$HAVE_GIF" = yes; then
14088 LIBGIF=-lgif
14089 elif test "$HAVE_GIF" = maybe; then
14090 # If gif_lib.h but no libgif, try libungif.
14091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
14092 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
14093 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
14094 $as_echo_n "(cached) " >&6
14095 else
14096 ac_check_lib_save_LIBS=$LIBS
14097 LIBS="-lungif $LIBS"
14098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14099 /* end confdefs.h. */
14101 /* Override any GCC internal prototype to avoid an error.
14102 Use char because int might match the return type of a GCC
14103 builtin and then its argument prototype would still apply. */
14104 #ifdef __cplusplus
14105 extern "C"
14106 #endif
14107 char EGifPutExtensionLast ();
14109 main ()
14111 return EGifPutExtensionLast ();
14113 return 0;
14115 _ACEOF
14116 if ac_fn_c_try_link "$LINENO"; then :
14117 ac_cv_lib_ungif_EGifPutExtensionLast=yes
14118 else
14119 ac_cv_lib_ungif_EGifPutExtensionLast=no
14121 rm -f core conftest.err conftest.$ac_objext \
14122 conftest$ac_exeext conftest.$ac_ext
14123 LIBS=$ac_check_lib_save_LIBS
14125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
14126 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
14127 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
14128 HAVE_GIF=yes
14129 else
14130 HAVE_GIF=no
14133 test "$HAVE_GIF" = yes && LIBGIF=-lungif
14136 if test "${HAVE_GIF}" = "yes"; then
14138 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14144 if test "${HAVE_X11}" = "yes"; then
14145 MISSING=""
14146 WITH_NO=""
14147 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
14148 MISSING="libXpm" && WITH_NO="--with-xpm=no"
14149 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
14150 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
14151 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
14152 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
14153 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
14154 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
14155 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
14156 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
14158 if test "X${MISSING}" != X; then
14159 as_fn_error "The following required libraries were not found:
14160 $MISSING
14161 Maybe some development libraries/packages are missing?
14162 If you don't want to link with them give
14163 $WITH_NO
14164 as options to configure" "$LINENO" 5
14168 ### Use -lgpm if available, unless `--with-gpm=no'.
14169 HAVE_GPM=no
14170 LIBGPM=
14171 if test "${with_gpm}" != "no"; then
14172 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
14173 if test "x$ac_cv_header_gpm_h" = x""yes; then :
14174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
14175 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
14176 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
14177 $as_echo_n "(cached) " >&6
14178 else
14179 ac_check_lib_save_LIBS=$LIBS
14180 LIBS="-lgpm $LIBS"
14181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14182 /* end confdefs.h. */
14184 /* Override any GCC internal prototype to avoid an error.
14185 Use char because int might match the return type of a GCC
14186 builtin and then its argument prototype would still apply. */
14187 #ifdef __cplusplus
14188 extern "C"
14189 #endif
14190 char Gpm_Open ();
14192 main ()
14194 return Gpm_Open ();
14196 return 0;
14198 _ACEOF
14199 if ac_fn_c_try_link "$LINENO"; then :
14200 ac_cv_lib_gpm_Gpm_Open=yes
14201 else
14202 ac_cv_lib_gpm_Gpm_Open=no
14204 rm -f core conftest.err conftest.$ac_objext \
14205 conftest$ac_exeext conftest.$ac_ext
14206 LIBS=$ac_check_lib_save_LIBS
14208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
14209 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
14210 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
14211 HAVE_GPM=yes
14218 if test "${HAVE_GPM}" = "yes"; then
14220 $as_echo "#define HAVE_GPM 1" >>confdefs.h
14222 LIBGPM=-lgpm
14231 GNUSTEP_CFLAGS=
14232 ### Use NeXTstep API to implement GUI.
14233 if test "${HAVE_NS}" = "yes"; then
14235 $as_echo "#define HAVE_NS 1" >>confdefs.h
14237 if test "${NS_IMPL_COCOA}" = "yes"; then
14239 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
14242 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
14244 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
14246 # See also .m.o rule in Makefile.in */
14247 # FIXME: are all these flags really needed? Document here why. */
14248 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
14249 ## Extra CFLAGS applied to src/*.m files.
14250 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"
14252 # We also have mouse menus.
14253 HAVE_MENUS=yes
14254 OTHER_FILES=ns-app
14257 if test "${HAVE_W32}" = "yes"; then
14258 HAVE_MENUS=yes
14261 ### Use session management (-lSM -lICE) if available
14262 HAVE_X_SM=no
14263 LIBXSM=
14264 if test "${HAVE_X11}" = "yes"; then
14265 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
14266 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
14267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
14268 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
14269 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
14270 $as_echo_n "(cached) " >&6
14271 else
14272 ac_check_lib_save_LIBS=$LIBS
14273 LIBS="-lSM -lICE $LIBS"
14274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14275 /* end confdefs.h. */
14277 /* Override any GCC internal prototype to avoid an error.
14278 Use char because int might match the return type of a GCC
14279 builtin and then its argument prototype would still apply. */
14280 #ifdef __cplusplus
14281 extern "C"
14282 #endif
14283 char SmcOpenConnection ();
14285 main ()
14287 return SmcOpenConnection ();
14289 return 0;
14291 _ACEOF
14292 if ac_fn_c_try_link "$LINENO"; then :
14293 ac_cv_lib_SM_SmcOpenConnection=yes
14294 else
14295 ac_cv_lib_SM_SmcOpenConnection=no
14297 rm -f core conftest.err conftest.$ac_objext \
14298 conftest$ac_exeext conftest.$ac_ext
14299 LIBS=$ac_check_lib_save_LIBS
14301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
14302 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
14303 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
14304 HAVE_X_SM=yes
14311 if test "${HAVE_X_SM}" = "yes"; then
14313 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
14315 LIBXSM="-lSM -lICE"
14316 case "$LIBS" in
14317 *-lSM*) ;;
14318 *) LIBS="$LIBXSM $LIBS" ;;
14319 esac
14324 ### Use XRandr (-lXrandr) if available
14325 HAVE_XRANDR=no
14326 if test "${HAVE_X11}" = "yes"; then
14327 XRANDR_REQUIRED=1.2.2
14328 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14330 succeeded=no
14332 if test "$PKG_CONFIG" = "no" ; then
14333 HAVE_XRANDR=no
14334 else
14335 PKG_CONFIG_MIN_VERSION=0.9.0
14336 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14338 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14340 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14341 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14342 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14343 edit_cflags="
14344 s,///*,/,g
14345 s/^/ /
14346 s/ -I/ $isystem/g
14347 s/^ //
14349 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14350 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14352 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14353 succeeded=yes
14354 else
14355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14356 $as_echo "no" >&6; }
14357 XRANDR_CFLAGS=""
14358 XRANDR_LIBS=""
14359 ## If we have a custom action on failure, don't print errors, but
14360 ## do set a variable so people can do so. Do it in a subshell
14361 ## to capture any diagnostics in invoking pkg-config.
14362 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14368 else
14369 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14370 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14374 if test $succeeded = yes; then
14375 HAVE_XRANDR=yes
14376 else
14377 HAVE_XRANDR=no
14380 if test $HAVE_XRANDR = no; then
14381 # Test old way in case pkg-config doesn't have it (older machines).
14382 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14383 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14385 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14386 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14387 $as_echo_n "(cached) " >&6
14388 else
14389 ac_check_lib_save_LIBS=$LIBS
14390 LIBS="-lXrandr $LIBS"
14391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14392 /* end confdefs.h. */
14394 /* Override any GCC internal prototype to avoid an error.
14395 Use char because int might match the return type of a GCC
14396 builtin and then its argument prototype would still apply. */
14397 #ifdef __cplusplus
14398 extern "C"
14399 #endif
14400 char XRRGetScreenResources ();
14402 main ()
14404 return XRRGetScreenResources ();
14406 return 0;
14408 _ACEOF
14409 if ac_fn_c_try_link "$LINENO"; then :
14410 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14411 else
14412 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14414 rm -f core conftest.err conftest.$ac_objext \
14415 conftest$ac_exeext conftest.$ac_ext
14416 LIBS=$ac_check_lib_save_LIBS
14418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14419 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14420 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14421 HAVE_XRANDR=yes
14427 if test $HAVE_XRANDR = yes; then
14428 XRANDR_LIBS=-lXrandr
14432 if test $HAVE_XRANDR = yes; then
14433 SAVE_CFLAGS="$CFLAGS"
14434 SAVE_LIBS="$LIBS"
14435 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14436 LIBS="$XRANDR_LIBS $LIBS"
14437 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14438 do :
14439 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14440 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14441 eval as_val=\$$as_ac_var
14442 if test "x$as_val" = x""yes; then :
14443 cat >>confdefs.h <<_ACEOF
14444 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14445 _ACEOF
14448 done
14450 CFLAGS="$SAVE_CFLAGS"
14451 LIBS="$SAVE_LIBS"
14454 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14459 ### Use Xinerama (-lXinerama) if available
14460 HAVE_XINERAMA=no
14461 if test "${HAVE_X11}" = "yes"; then
14462 XINERAMA_REQUIRED=1.0.2
14463 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14465 succeeded=no
14467 if test "$PKG_CONFIG" = "no" ; then
14468 HAVE_XINERAMA=no
14469 else
14470 PKG_CONFIG_MIN_VERSION=0.9.0
14471 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14473 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14475 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14476 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14477 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14478 edit_cflags="
14479 s,///*,/,g
14480 s/^/ /
14481 s/ -I/ $isystem/g
14482 s/^ //
14484 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14485 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14487 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14488 succeeded=yes
14489 else
14490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14491 $as_echo "no" >&6; }
14492 XINERAMA_CFLAGS=""
14493 XINERAMA_LIBS=""
14494 ## If we have a custom action on failure, don't print errors, but
14495 ## do set a variable so people can do so. Do it in a subshell
14496 ## to capture any diagnostics in invoking pkg-config.
14497 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14503 else
14504 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14505 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14509 if test $succeeded = yes; then
14510 HAVE_XINERAMA=yes
14511 else
14512 HAVE_XINERAMA=no
14515 if test $HAVE_XINERAMA = no; then
14516 # Test old way in case pkg-config doesn't have it (older machines).
14517 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14518 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14520 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14521 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14522 $as_echo_n "(cached) " >&6
14523 else
14524 ac_check_lib_save_LIBS=$LIBS
14525 LIBS="-lXinerama $LIBS"
14526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14527 /* end confdefs.h. */
14529 /* Override any GCC internal prototype to avoid an error.
14530 Use char because int might match the return type of a GCC
14531 builtin and then its argument prototype would still apply. */
14532 #ifdef __cplusplus
14533 extern "C"
14534 #endif
14535 char XineramaQueryExtension ();
14537 main ()
14539 return XineramaQueryExtension ();
14541 return 0;
14543 _ACEOF
14544 if ac_fn_c_try_link "$LINENO"; then :
14545 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14546 else
14547 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14549 rm -f core conftest.err conftest.$ac_objext \
14550 conftest$ac_exeext conftest.$ac_ext
14551 LIBS=$ac_check_lib_save_LIBS
14553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14554 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14555 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14556 HAVE_XINERAMA=yes
14562 if test $HAVE_XINERAMA = yes; then
14563 XINERAMA_LIBS=-lXinerama
14567 if test $HAVE_XINERAMA = yes; then
14569 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14575 ### Use libxml (-lxml2) if available
14576 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14577 HAVE_LIBXML2=no
14578 if test "${with_xml2}" != "no"; then
14579 ### I'm not sure what the version number should be, so I just guessed.
14581 succeeded=no
14583 if test "$PKG_CONFIG" = "no" ; then
14584 HAVE_LIBXML2=no
14585 else
14586 PKG_CONFIG_MIN_VERSION=0.9.0
14587 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14589 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14591 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14592 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14593 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14594 edit_cflags="
14595 s,///*,/,g
14596 s/^/ /
14597 s/ -I/ $isystem/g
14598 s/^ //
14600 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14601 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14603 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14604 succeeded=yes
14605 else
14606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14607 $as_echo "no" >&6; }
14608 LIBXML2_CFLAGS=""
14609 LIBXML2_LIBS=""
14610 ## If we have a custom action on failure, don't print errors, but
14611 ## do set a variable so people can do so. Do it in a subshell
14612 ## to capture any diagnostics in invoking pkg-config.
14613 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14619 else
14620 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14621 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14625 if test $succeeded = yes; then
14626 HAVE_LIBXML2=yes
14627 else
14628 HAVE_LIBXML2=no
14631 # Built-in libxml2 on OS X 10.8 lacks libxml-2.0.pc.
14632 if test "${HAVE_LIBXML2}" != "yes" -a "$opsys" = "darwin"; then
14633 SAVE_CPPFLAGS="$CPPFLAGS"
14634 CPPFLAGS="$CPPFLAGS -I/usr/include/libxml2"
14635 ac_fn_c_check_header_mongrel "$LINENO" "libxml/HTMLparser.h" "ac_cv_header_libxml_HTMLparser_h" "$ac_includes_default"
14636 if test "x$ac_cv_header_libxml_HTMLparser_h" = x""yes; then :
14637 ac_fn_c_check_decl "$LINENO" "HTML_PARSE_RECOVER" "ac_cv_have_decl_HTML_PARSE_RECOVER" "#include <libxml/HTMLparser.h>
14639 if test "x$ac_cv_have_decl_HTML_PARSE_RECOVER" = x""yes; then :
14640 HAVE_LIBXML2=yes
14646 CPPFLAGS="$SAVE_CPPFLAGS"
14647 if test "${HAVE_LIBXML2}" = "yes"; then
14648 LIBXML2_LIBS="-lxml2"
14649 LIBXML2_CFLAGS="-I/usr/include/libxml2"
14652 if test "${HAVE_LIBXML2}" = "yes"; then
14653 if test "${opsys}" != "mingw32"; then
14654 LIBS="$LIBXML2_LIBS $LIBS"
14655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14656 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14657 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14658 $as_echo_n "(cached) " >&6
14659 else
14660 ac_check_lib_save_LIBS=$LIBS
14661 LIBS="-lxml2 $LIBS"
14662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14663 /* end confdefs.h. */
14665 /* Override any GCC internal prototype to avoid an error.
14666 Use char because int might match the return type of a GCC
14667 builtin and then its argument prototype would still apply. */
14668 #ifdef __cplusplus
14669 extern "C"
14670 #endif
14671 char htmlReadMemory ();
14673 main ()
14675 return htmlReadMemory ();
14677 return 0;
14679 _ACEOF
14680 if ac_fn_c_try_link "$LINENO"; then :
14681 ac_cv_lib_xml2_htmlReadMemory=yes
14682 else
14683 ac_cv_lib_xml2_htmlReadMemory=no
14685 rm -f core conftest.err conftest.$ac_objext \
14686 conftest$ac_exeext conftest.$ac_ext
14687 LIBS=$ac_check_lib_save_LIBS
14689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14690 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14691 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14692 HAVE_LIBXML2=yes
14693 else
14694 HAVE_LIBXML2=no
14697 else
14698 LIBXML2_LIBS=""
14700 if test "${HAVE_LIBXML2}" = "yes"; then
14702 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14704 else
14705 LIBXML2_LIBS=""
14706 LIBXML2_CFLAGS=""
14713 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14714 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14715 if test "${opsys}" = "mingw32"; then
14716 emacs_cv_netdb_declares_h_errno=yes
14718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14719 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14720 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14721 $as_echo_n "(cached) " >&6
14722 else
14723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14724 /* end confdefs.h. */
14725 #include <netdb.h>
14727 main ()
14729 return h_errno;
14731 return 0;
14733 _ACEOF
14734 if ac_fn_c_try_link "$LINENO"; then :
14735 emacs_cv_netdb_declares_h_errno=yes
14736 else
14737 emacs_cv_netdb_declares_h_errno=no
14739 rm -f core conftest.err conftest.$ac_objext \
14740 conftest$ac_exeext conftest.$ac_ext
14742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14743 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14744 if test $emacs_cv_netdb_declares_h_errno = yes; then
14746 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14750 # sqrt and other floating-point functions such as fmod and frexp
14751 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14752 if test "${opsys}" != "mingw32"; then
14753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14754 $as_echo_n "checking for sqrt in -lm... " >&6; }
14755 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14756 $as_echo_n "(cached) " >&6
14757 else
14758 ac_check_lib_save_LIBS=$LIBS
14759 LIBS="-lm $LIBS"
14760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14761 /* end confdefs.h. */
14763 /* Override any GCC internal prototype to avoid an error.
14764 Use char because int might match the return type of a GCC
14765 builtin and then its argument prototype would still apply. */
14766 #ifdef __cplusplus
14767 extern "C"
14768 #endif
14769 char sqrt ();
14771 main ()
14773 return sqrt ();
14775 return 0;
14777 _ACEOF
14778 if ac_fn_c_try_link "$LINENO"; then :
14779 ac_cv_lib_m_sqrt=yes
14780 else
14781 ac_cv_lib_m_sqrt=no
14783 rm -f core conftest.err conftest.$ac_objext \
14784 conftest$ac_exeext conftest.$ac_ext
14785 LIBS=$ac_check_lib_save_LIBS
14787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14788 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14789 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14790 cat >>confdefs.h <<_ACEOF
14791 #define HAVE_LIBM 1
14792 _ACEOF
14794 LIBS="-lm $LIBS"
14800 # Check for mail-locking functions in a "mail" library. Probably this should
14801 # have the same check as for liblockfile below.
14802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14803 $as_echo_n "checking for maillock in -lmail... " >&6; }
14804 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14805 $as_echo_n "(cached) " >&6
14806 else
14807 ac_check_lib_save_LIBS=$LIBS
14808 LIBS="-lmail $LIBS"
14809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14810 /* end confdefs.h. */
14812 /* Override any GCC internal prototype to avoid an error.
14813 Use char because int might match the return type of a GCC
14814 builtin and then its argument prototype would still apply. */
14815 #ifdef __cplusplus
14816 extern "C"
14817 #endif
14818 char maillock ();
14820 main ()
14822 return maillock ();
14824 return 0;
14826 _ACEOF
14827 if ac_fn_c_try_link "$LINENO"; then :
14828 ac_cv_lib_mail_maillock=yes
14829 else
14830 ac_cv_lib_mail_maillock=no
14832 rm -f core conftest.err conftest.$ac_objext \
14833 conftest$ac_exeext conftest.$ac_ext
14834 LIBS=$ac_check_lib_save_LIBS
14836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14837 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14838 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14839 have_mail=yes
14840 else
14841 have_mail=no
14844 if test $have_mail = yes; then
14845 LIBS_MAIL=-lmail
14846 LIBS="$LIBS_MAIL $LIBS"
14848 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14850 else
14851 LIBS_MAIL=
14853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14854 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14855 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14856 $as_echo_n "(cached) " >&6
14857 else
14858 ac_check_lib_save_LIBS=$LIBS
14859 LIBS="-llockfile $LIBS"
14860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14861 /* end confdefs.h. */
14863 /* Override any GCC internal prototype to avoid an error.
14864 Use char because int might match the return type of a GCC
14865 builtin and then its argument prototype would still apply. */
14866 #ifdef __cplusplus
14867 extern "C"
14868 #endif
14869 char maillock ();
14871 main ()
14873 return maillock ();
14875 return 0;
14877 _ACEOF
14878 if ac_fn_c_try_link "$LINENO"; then :
14879 ac_cv_lib_lockfile_maillock=yes
14880 else
14881 ac_cv_lib_lockfile_maillock=no
14883 rm -f core conftest.err conftest.$ac_objext \
14884 conftest$ac_exeext conftest.$ac_ext
14885 LIBS=$ac_check_lib_save_LIBS
14887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
14888 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
14889 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
14890 have_lockfile=yes
14891 else
14892 have_lockfile=no
14895 if test $have_lockfile = yes; then
14896 LIBS_MAIL=-llockfile
14897 LIBS="$LIBS_MAIL $LIBS"
14899 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
14901 else
14902 # If we have the shared liblockfile, assume we must use it for mail
14903 # locking (e.g. Debian). If we couldn't link against liblockfile
14904 # (no liblockfile.a installed), ensure that we don't need to.
14905 # Extract the first word of "liblockfile.so", so it can be a program name with args.
14906 set dummy liblockfile.so; ac_word=$2
14907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14908 $as_echo_n "checking for $ac_word... " >&6; }
14909 if test "${ac_cv_prog_liblockfile+set}" = set; then :
14910 $as_echo_n "(cached) " >&6
14911 else
14912 if test -n "$liblockfile"; then
14913 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
14914 else
14915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14916 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
14917 for as_dir in $as_dummy
14919 IFS=$as_save_IFS
14920 test -z "$as_dir" && as_dir=.
14921 for ac_exec_ext in '' $ac_executable_extensions; do
14922 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14923 ac_cv_prog_liblockfile="yes"
14924 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14925 break 2
14927 done
14928 done
14929 IFS=$as_save_IFS
14931 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
14934 liblockfile=$ac_cv_prog_liblockfile
14935 if test -n "$liblockfile"; then
14936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
14937 $as_echo "$liblockfile" >&6; }
14938 else
14939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14940 $as_echo "no" >&6; }
14944 if test $ac_cv_prog_liblockfile = yes; then
14945 as_fn_error "Shared liblockfile found but can't link against it.
14946 This probably means that movemail could lose mail.
14947 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
14955 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
14956 ## interlock access to the mail spool. The alternative is a lock file named
14957 ## /usr/spool/mail/$USER.lock.
14958 mail_lock=no
14959 case "$opsys" in
14960 aix4-2) mail_lock="lockf" ;;
14962 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
14964 ## On GNU/Linux systems, both methods are used by various mail programs.
14965 ## I assume most people are using newer mailers that have heard of flock.
14966 ## Change this if you need to.
14967 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
14968 ## configure gets the right answers, and that means *NOT* using flock.
14969 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
14970 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
14971 ## Debian maintainer hasn't provided a clean fix for Emacs.
14972 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
14973 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
14974 ## correct logic. -- fx
14975 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
14976 ## liblockfile is a Free Software replacement for libmail, used on
14977 ## Debian systems and elsewhere. -rfr.
14978 gnu-*)
14979 mail_lock="flock"
14980 if test $have_mail = yes || test $have_lockfile = yes; then
14981 test $ac_cv_header_maillock_h = yes && mail_lock=no
14985 mingw32)
14986 mail_lock="none-needed" ;;
14987 esac
14989 BLESSMAIL_TARGET=
14990 case "$mail_lock" in
14991 flock)
14992 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
14995 lockf)
14996 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
14999 none-needed) ;;
15001 *) BLESSMAIL_TARGET="need-blessmail" ;;
15002 esac
15006 for ac_func in accept4 gethostname \
15007 getrusage get_current_dir_name \
15008 lrand48 \
15009 select getpagesize setlocale \
15010 getrlimit setrlimit shutdown getaddrinfo \
15011 strsignal setitimer \
15012 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
15013 gai_strerror getline getdelim sync \
15014 difftime posix_memalign \
15015 getpwent endpwent getgrent endgrent \
15016 touchlock \
15017 cfmakeraw cfsetspeed copysign __executable_start log2
15018 do :
15019 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15020 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15021 eval as_val=\$$as_ac_var
15022 if test "x$as_val" = x""yes; then :
15023 cat >>confdefs.h <<_ACEOF
15024 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15025 _ACEOF
15028 done
15031 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
15032 ## has a broken `rint' in some library versions including math library
15033 ## version number A.09.05.
15034 ## You can fix the math library by installing patch number PHSS_4630.
15035 ## But we can fix it more reliably for Emacs by just not using rint.
15036 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
15037 case $opsys in
15038 hpux*) : ;;
15039 *) for ac_func in random rint
15040 do :
15041 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15042 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15043 eval as_val=\$$as_ac_var
15044 if test "x$as_val" = x""yes; then :
15045 cat >>confdefs.h <<_ACEOF
15046 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15047 _ACEOF
15050 done
15052 esac
15054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
15055 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
15056 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
15057 $as_echo_n "(cached) " >&6
15058 else
15059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15060 /* end confdefs.h. */
15063 main ()
15065 __builtin_unwind_init ();
15067 return 0;
15069 _ACEOF
15070 if ac_fn_c_try_link "$LINENO"; then :
15071 emacs_cv_func___builtin_unwind_init=yes
15072 else
15073 emacs_cv_func___builtin_unwind_init=no
15075 rm -f core conftest.err conftest.$ac_objext \
15076 conftest$ac_exeext conftest.$ac_ext
15078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
15079 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
15080 if test $emacs_cv_func___builtin_unwind_init = yes; then
15082 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
15090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15091 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15092 if test "${ac_cv_sys_largefile_source+set}" = set; then :
15093 $as_echo_n "(cached) " >&6
15094 else
15095 while :; do
15096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15097 /* end confdefs.h. */
15098 #include <sys/types.h> /* for off_t */
15099 #include <stdio.h>
15101 main ()
15103 int (*fp) (FILE *, off_t, int) = fseeko;
15104 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15106 return 0;
15108 _ACEOF
15109 if ac_fn_c_try_link "$LINENO"; then :
15110 ac_cv_sys_largefile_source=no; break
15112 rm -f core conftest.err conftest.$ac_objext \
15113 conftest$ac_exeext conftest.$ac_ext
15114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15115 /* end confdefs.h. */
15116 #define _LARGEFILE_SOURCE 1
15117 #include <sys/types.h> /* for off_t */
15118 #include <stdio.h>
15120 main ()
15122 int (*fp) (FILE *, off_t, int) = fseeko;
15123 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15125 return 0;
15127 _ACEOF
15128 if ac_fn_c_try_link "$LINENO"; then :
15129 ac_cv_sys_largefile_source=1; break
15131 rm -f core conftest.err conftest.$ac_objext \
15132 conftest$ac_exeext conftest.$ac_ext
15133 ac_cv_sys_largefile_source=unknown
15134 break
15135 done
15137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15138 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15139 case $ac_cv_sys_largefile_source in #(
15140 no | unknown) ;;
15142 cat >>confdefs.h <<_ACEOF
15143 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15144 _ACEOF
15146 esac
15147 rm -rf conftest*
15149 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15150 # in glibc 2.1.3, but that breaks too many other things.
15151 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15152 if test $ac_cv_sys_largefile_source != unknown; then
15154 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15159 # UNIX98 PTYs.
15160 for ac_func in grantpt
15161 do :
15162 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
15163 if test "x$ac_cv_func_grantpt" = x""yes; then :
15164 cat >>confdefs.h <<_ACEOF
15165 #define HAVE_GRANTPT 1
15166 _ACEOF
15169 done
15172 # PTY-related GNU extensions.
15173 for ac_func in getpt posix_openpt
15174 do :
15175 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15176 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15177 eval as_val=\$$as_ac_var
15178 if test "x$as_val" = x""yes; then :
15179 cat >>confdefs.h <<_ACEOF
15180 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15181 _ACEOF
15184 done
15187 # Check this now, so that we will NOT find the above functions in ncurses.
15188 # That is because we have not set up to link ncurses in lib-src.
15189 # It's better to believe a function is not available
15190 # than to expect to find it in ncurses.
15191 # Also we need tputs and friends to be able to build at all.
15192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
15193 $as_echo_n "checking for library containing tputs... " >&6; }
15194 # Run a test program that contains a call to tputs, a call that is
15195 # never executed. This tests whether a pre-'main' dynamic linker
15196 # works with the library. It's too much trouble to actually call
15197 # tputs in the test program, due to portability hassles. When
15198 # cross-compiling, assume the test program will run if it links.
15200 if test "${opsys}" = "mingw32"; then
15201 msg='none required'
15202 else
15203 # Maybe curses should be tried earlier?
15204 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
15205 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
15206 OLIBS=$LIBS
15207 if test -z "$tputs_library"; then
15208 LIBS_TERMCAP=
15209 msg='none required'
15210 else
15211 LIBS_TERMCAP=-l$tputs_library
15212 msg=$LIBS_TERMCAP
15213 LIBS="$LIBS_TERMCAP $LIBS"
15215 if test "$cross_compiling" = yes; then :
15216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15217 /* end confdefs.h. */
15219 extern void tputs (const char *, int, int (*)(int));
15220 int main (int argc, char **argv)
15222 if (argc == 10000)
15223 tputs (argv[0], 0, 0);
15224 return 0;
15227 _ACEOF
15228 if ac_fn_c_try_link "$LINENO"; then :
15230 else
15231 msg=no
15233 rm -f core conftest.err conftest.$ac_objext \
15234 conftest$ac_exeext conftest.$ac_ext
15235 else
15236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15237 /* end confdefs.h. */
15239 extern void tputs (const char *, int, int (*)(int));
15240 int main (int argc, char **argv)
15242 if (argc == 10000)
15243 tputs (argv[0], 0, 0);
15244 return 0;
15247 _ACEOF
15248 if ac_fn_c_try_run "$LINENO"; then :
15250 else
15251 msg=no
15253 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15254 conftest.$ac_objext conftest.beam conftest.$ac_ext
15257 LIBS=$OLIBS
15258 if test "X$msg" != Xno; then
15259 break
15261 done
15263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
15264 $as_echo "$msg" >&6; }
15265 if test "X$msg" = Xno; then
15266 as_fn_error "The required function \`tputs' was not found in any library.
15267 The following libraries were tried (in order):
15268 libtinfo, libncurses, libterminfo, libtermcap, libcurses
15269 Please try installing whichever of these libraries is most appropriate
15270 for your system, together with its header files.
15271 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
15274 ## Use termcap instead of terminfo?
15275 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
15276 TERMINFO=yes
15277 ## FIXME? In the cases below where we unconditionally set
15278 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
15279 ## if that was found above to have tputs.
15280 ## Should we use the gnu* logic everywhere?
15281 case "$opsys" in
15282 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
15283 ## The ncurses library has been moved out of the System framework in
15284 ## Mac OS X 10.2. So if configure detects it, set the command-line
15285 ## option to use it.
15286 darwin) LIBS_TERMCAP="-lncurses" ;;
15288 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
15290 freebsd)
15291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
15292 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
15293 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
15294 $as_echo_n "(cached) " >&6
15295 else
15296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15297 /* end confdefs.h. */
15298 #include <osreldate.h>
15300 main ()
15302 #if __FreeBSD_version < 400000
15303 fail;
15304 #endif
15307 return 0;
15309 _ACEOF
15310 if ac_fn_c_try_link "$LINENO"; then :
15311 emacs_cv_freebsd_terminfo=yes
15312 else
15313 emacs_cv_freebsd_terminfo=no
15315 rm -f core conftest.err conftest.$ac_objext \
15316 conftest$ac_exeext conftest.$ac_ext
15320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
15321 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
15323 if test $emacs_cv_freebsd_terminfo = yes; then
15324 LIBS_TERMCAP="-lncurses"
15325 else
15326 TERMINFO=no
15327 LIBS_TERMCAP="-ltermcap"
15331 mingw32)
15332 TERMINFO=no
15333 LIBS_TERMCAP=
15336 netbsd)
15337 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15338 TERMINFO=no
15339 LIBS_TERMCAP="-ltermcap"
15343 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15345 ## hpux: Make sure we get select from libc rather than from libcurses
15346 ## because libcurses on HPUX 10.10 has a broken version of select.
15347 ## We used to use -lc -lcurses, but this may be cleaner.
15348 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15349 # set that way, now it uses the default). Isn't this a contradiction?
15350 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15352 esac
15354 TERMCAP_OBJ=tparam.o
15355 if test $TERMINFO = yes; then
15357 $as_echo "#define TERMINFO 1" >>confdefs.h
15359 TERMCAP_OBJ=terminfo.o
15361 if test "X$LIBS_TERMCAP" = "X-lncurses"; then
15363 $as_echo "#define USE_NCURSES 1" >>confdefs.h
15370 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15371 # On Darwin, res_init appears not to be useful: see bug#562 and
15372 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15373 resolv=no
15375 if test $opsys != darwin; then
15377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15378 /* end confdefs.h. */
15379 #include <netinet/in.h>
15380 #include <arpa/nameser.h>
15381 #include <resolv.h>
15383 main ()
15385 return res_init();
15387 return 0;
15389 _ACEOF
15390 if ac_fn_c_try_link "$LINENO"; then :
15391 have_res_init=yes
15392 else
15393 have_res_init=no
15395 rm -f core conftest.err conftest.$ac_objext \
15396 conftest$ac_exeext conftest.$ac_ext
15397 if test "$have_res_init" = no; then
15398 OLIBS="$LIBS"
15399 LIBS="$LIBS -lresolv"
15400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15401 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15403 /* end confdefs.h. */
15404 #include <netinet/in.h>
15405 #include <arpa/nameser.h>
15406 #include <resolv.h>
15408 main ()
15410 return res_init();
15412 return 0;
15414 _ACEOF
15415 if ac_fn_c_try_link "$LINENO"; then :
15416 have_res_init=yes
15417 else
15418 have_res_init=no
15420 rm -f core conftest.err conftest.$ac_objext \
15421 conftest$ac_exeext conftest.$ac_ext
15422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15423 $as_echo "$have_res_init" >&6; }
15424 if test "$have_res_init" = yes ; then
15425 resolv=yes
15427 LIBS="$OLIBS"
15430 if test "$have_res_init" = yes; then
15432 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15436 # Do we need the Hesiod library to provide the support routines?
15437 LIBHESIOD=
15438 if test "$with_hesiod" != no ; then
15439 # Don't set $LIBS here -- see comments above. FIXME which comments?
15440 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15441 if test "x$ac_cv_func_res_send" = x""yes; then :
15443 else
15444 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15445 if test "x$ac_cv_func___res_send" = x""yes; then :
15447 else
15448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15449 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15450 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15451 $as_echo_n "(cached) " >&6
15452 else
15453 ac_check_lib_save_LIBS=$LIBS
15454 LIBS="-lresolv $LIBS"
15455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15456 /* end confdefs.h. */
15458 /* Override any GCC internal prototype to avoid an error.
15459 Use char because int might match the return type of a GCC
15460 builtin and then its argument prototype would still apply. */
15461 #ifdef __cplusplus
15462 extern "C"
15463 #endif
15464 char res_send ();
15466 main ()
15468 return res_send ();
15470 return 0;
15472 _ACEOF
15473 if ac_fn_c_try_link "$LINENO"; then :
15474 ac_cv_lib_resolv_res_send=yes
15475 else
15476 ac_cv_lib_resolv_res_send=no
15478 rm -f core conftest.err conftest.$ac_objext \
15479 conftest$ac_exeext conftest.$ac_ext
15480 LIBS=$ac_check_lib_save_LIBS
15482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15483 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15484 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15485 resolv=yes
15486 else
15487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15488 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15489 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15490 $as_echo_n "(cached) " >&6
15491 else
15492 ac_check_lib_save_LIBS=$LIBS
15493 LIBS="-lresolv $LIBS"
15494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15495 /* end confdefs.h. */
15497 /* Override any GCC internal prototype to avoid an error.
15498 Use char because int might match the return type of a GCC
15499 builtin and then its argument prototype would still apply. */
15500 #ifdef __cplusplus
15501 extern "C"
15502 #endif
15503 char __res_send ();
15505 main ()
15507 return __res_send ();
15509 return 0;
15511 _ACEOF
15512 if ac_fn_c_try_link "$LINENO"; then :
15513 ac_cv_lib_resolv___res_send=yes
15514 else
15515 ac_cv_lib_resolv___res_send=no
15517 rm -f core conftest.err conftest.$ac_objext \
15518 conftest$ac_exeext conftest.$ac_ext
15519 LIBS=$ac_check_lib_save_LIBS
15521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15522 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15523 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15524 resolv=yes
15533 if test "$resolv" = yes ; then
15534 RESOLVLIB=-lresolv
15535 else
15536 RESOLVLIB=
15538 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15539 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15541 else
15542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15543 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15544 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15545 $as_echo_n "(cached) " >&6
15546 else
15547 ac_check_lib_save_LIBS=$LIBS
15548 LIBS="-lhesiod $RESOLVLIB $LIBS"
15549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15550 /* end confdefs.h. */
15552 /* Override any GCC internal prototype to avoid an error.
15553 Use char because int might match the return type of a GCC
15554 builtin and then its argument prototype would still apply. */
15555 #ifdef __cplusplus
15556 extern "C"
15557 #endif
15558 char hes_getmailhost ();
15560 main ()
15562 return hes_getmailhost ();
15564 return 0;
15566 _ACEOF
15567 if ac_fn_c_try_link "$LINENO"; then :
15568 ac_cv_lib_hesiod_hes_getmailhost=yes
15569 else
15570 ac_cv_lib_hesiod_hes_getmailhost=no
15572 rm -f core conftest.err conftest.$ac_objext \
15573 conftest$ac_exeext conftest.$ac_ext
15574 LIBS=$ac_check_lib_save_LIBS
15576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15577 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15578 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15579 hesiod=yes
15580 else
15587 if test x"$hesiod" = xyes; then
15588 LIBHESIOD=-lhesiod
15593 # Do we need libresolv (due to res_init or Hesiod)?
15594 if test "$resolv" = yes && test $opsys != darwin; then
15595 LIBRESOLV=-lresolv
15596 else
15597 LIBRESOLV=
15601 # These tell us which Kerberos-related libraries to use.
15602 COM_ERRLIB=
15603 CRYPTOLIB=
15604 KRB5LIB=
15605 DESLIB=
15606 KRB4LIB=
15608 if test "${with_kerberos}" != no; then
15609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15610 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15611 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15612 $as_echo_n "(cached) " >&6
15613 else
15614 ac_check_lib_save_LIBS=$LIBS
15615 LIBS="-lcom_err $LIBS"
15616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15617 /* end confdefs.h. */
15619 /* Override any GCC internal prototype to avoid an error.
15620 Use char because int might match the return type of a GCC
15621 builtin and then its argument prototype would still apply. */
15622 #ifdef __cplusplus
15623 extern "C"
15624 #endif
15625 char com_err ();
15627 main ()
15629 return com_err ();
15631 return 0;
15633 _ACEOF
15634 if ac_fn_c_try_link "$LINENO"; then :
15635 ac_cv_lib_com_err_com_err=yes
15636 else
15637 ac_cv_lib_com_err_com_err=no
15639 rm -f core conftest.err conftest.$ac_objext \
15640 conftest$ac_exeext conftest.$ac_ext
15641 LIBS=$ac_check_lib_save_LIBS
15643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15644 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15645 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15646 have_com_err=yes
15647 else
15648 have_com_err=no
15651 if test $have_com_err = yes; then
15652 COM_ERRLIB=-lcom_err
15653 LIBS="$COM_ERRLIB $LIBS"
15655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15656 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15657 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15658 $as_echo_n "(cached) " >&6
15659 else
15660 ac_check_lib_save_LIBS=$LIBS
15661 LIBS="-lcrypto $LIBS"
15662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15663 /* end confdefs.h. */
15665 /* Override any GCC internal prototype to avoid an error.
15666 Use char because int might match the return type of a GCC
15667 builtin and then its argument prototype would still apply. */
15668 #ifdef __cplusplus
15669 extern "C"
15670 #endif
15671 char mit_des_cbc_encrypt ();
15673 main ()
15675 return mit_des_cbc_encrypt ();
15677 return 0;
15679 _ACEOF
15680 if ac_fn_c_try_link "$LINENO"; then :
15681 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15682 else
15683 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15685 rm -f core conftest.err conftest.$ac_objext \
15686 conftest$ac_exeext conftest.$ac_ext
15687 LIBS=$ac_check_lib_save_LIBS
15689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15690 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15691 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15692 have_crypto=yes
15693 else
15694 have_crypto=no
15697 if test $have_crypto = yes; then
15698 CRYPTOLIB=-lcrypto
15699 LIBS="$CRYPTOLIB $LIBS"
15701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15702 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15703 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15704 $as_echo_n "(cached) " >&6
15705 else
15706 ac_check_lib_save_LIBS=$LIBS
15707 LIBS="-lk5crypto $LIBS"
15708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15709 /* end confdefs.h. */
15711 /* Override any GCC internal prototype to avoid an error.
15712 Use char because int might match the return type of a GCC
15713 builtin and then its argument prototype would still apply. */
15714 #ifdef __cplusplus
15715 extern "C"
15716 #endif
15717 char mit_des_cbc_encrypt ();
15719 main ()
15721 return mit_des_cbc_encrypt ();
15723 return 0;
15725 _ACEOF
15726 if ac_fn_c_try_link "$LINENO"; then :
15727 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15728 else
15729 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15731 rm -f core conftest.err conftest.$ac_objext \
15732 conftest$ac_exeext conftest.$ac_ext
15733 LIBS=$ac_check_lib_save_LIBS
15735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15736 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15737 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15738 have_k5crypto=yes
15739 else
15740 have_k5crypto=no
15743 if test $have_k5crypto = yes; then
15744 CRYPTOLIB=-lk5crypto
15745 LIBS="$CRYPTOLIB $LIBS"
15747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15748 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15749 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15750 $as_echo_n "(cached) " >&6
15751 else
15752 ac_check_lib_save_LIBS=$LIBS
15753 LIBS="-lkrb5 $LIBS"
15754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15755 /* end confdefs.h. */
15757 /* Override any GCC internal prototype to avoid an error.
15758 Use char because int might match the return type of a GCC
15759 builtin and then its argument prototype would still apply. */
15760 #ifdef __cplusplus
15761 extern "C"
15762 #endif
15763 char krb5_init_context ();
15765 main ()
15767 return krb5_init_context ();
15769 return 0;
15771 _ACEOF
15772 if ac_fn_c_try_link "$LINENO"; then :
15773 ac_cv_lib_krb5_krb5_init_context=yes
15774 else
15775 ac_cv_lib_krb5_krb5_init_context=no
15777 rm -f core conftest.err conftest.$ac_objext \
15778 conftest$ac_exeext conftest.$ac_ext
15779 LIBS=$ac_check_lib_save_LIBS
15781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15782 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15783 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15784 have_krb5=yes
15785 else
15786 have_krb5=no
15789 if test $have_krb5=yes; then
15790 KRB5LIB=-lkrb5
15791 LIBS="$KRB5LIB $LIBS"
15793 if test "${with_kerberos5}" = no; then
15794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15795 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15796 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15797 $as_echo_n "(cached) " >&6
15798 else
15799 ac_check_lib_save_LIBS=$LIBS
15800 LIBS="-ldes425 $LIBS"
15801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15802 /* end confdefs.h. */
15804 /* Override any GCC internal prototype to avoid an error.
15805 Use char because int might match the return type of a GCC
15806 builtin and then its argument prototype would still apply. */
15807 #ifdef __cplusplus
15808 extern "C"
15809 #endif
15810 char des_cbc_encrypt ();
15812 main ()
15814 return des_cbc_encrypt ();
15816 return 0;
15818 _ACEOF
15819 if ac_fn_c_try_link "$LINENO"; then :
15820 ac_cv_lib_des425_des_cbc_encrypt=yes
15821 else
15822 ac_cv_lib_des425_des_cbc_encrypt=no
15824 rm -f core conftest.err conftest.$ac_objext \
15825 conftest$ac_exeext conftest.$ac_ext
15826 LIBS=$ac_check_lib_save_LIBS
15828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15829 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15830 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15831 have_des425=yes
15832 else
15833 have_des425=no
15836 if test $have_des425 = yes; then
15837 DESLIB=-ldes425
15838 LIBS="$DESLIB $LIBS"
15839 else
15840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15841 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15842 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15843 $as_echo_n "(cached) " >&6
15844 else
15845 ac_check_lib_save_LIBS=$LIBS
15846 LIBS="-ldes $LIBS"
15847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15848 /* end confdefs.h. */
15850 /* Override any GCC internal prototype to avoid an error.
15851 Use char because int might match the return type of a GCC
15852 builtin and then its argument prototype would still apply. */
15853 #ifdef __cplusplus
15854 extern "C"
15855 #endif
15856 char des_cbc_encrypt ();
15858 main ()
15860 return des_cbc_encrypt ();
15862 return 0;
15864 _ACEOF
15865 if ac_fn_c_try_link "$LINENO"; then :
15866 ac_cv_lib_des_des_cbc_encrypt=yes
15867 else
15868 ac_cv_lib_des_des_cbc_encrypt=no
15870 rm -f core conftest.err conftest.$ac_objext \
15871 conftest$ac_exeext conftest.$ac_ext
15872 LIBS=$ac_check_lib_save_LIBS
15874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
15875 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
15876 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
15877 have_des=yes
15878 else
15879 have_des=no
15882 if test $have_des = yes; then
15883 DESLIB=-ldes
15884 LIBS="$DESLIB $LIBS"
15887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
15888 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
15889 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
15890 $as_echo_n "(cached) " >&6
15891 else
15892 ac_check_lib_save_LIBS=$LIBS
15893 LIBS="-lkrb4 $LIBS"
15894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15895 /* end confdefs.h. */
15897 /* Override any GCC internal prototype to avoid an error.
15898 Use char because int might match the return type of a GCC
15899 builtin and then its argument prototype would still apply. */
15900 #ifdef __cplusplus
15901 extern "C"
15902 #endif
15903 char krb_get_cred ();
15905 main ()
15907 return krb_get_cred ();
15909 return 0;
15911 _ACEOF
15912 if ac_fn_c_try_link "$LINENO"; then :
15913 ac_cv_lib_krb4_krb_get_cred=yes
15914 else
15915 ac_cv_lib_krb4_krb_get_cred=no
15917 rm -f core conftest.err conftest.$ac_objext \
15918 conftest$ac_exeext conftest.$ac_ext
15919 LIBS=$ac_check_lib_save_LIBS
15921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
15922 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
15923 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
15924 have_krb4=yes
15925 else
15926 have_krb4=no
15929 if test $have_krb4 = yes; then
15930 KRB4LIB=-lkrb4
15931 LIBS="$KRB4LIB $LIBS"
15932 else
15933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
15934 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
15935 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
15936 $as_echo_n "(cached) " >&6
15937 else
15938 ac_check_lib_save_LIBS=$LIBS
15939 LIBS="-lkrb $LIBS"
15940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15941 /* end confdefs.h. */
15943 /* Override any GCC internal prototype to avoid an error.
15944 Use char because int might match the return type of a GCC
15945 builtin and then its argument prototype would still apply. */
15946 #ifdef __cplusplus
15947 extern "C"
15948 #endif
15949 char krb_get_cred ();
15951 main ()
15953 return krb_get_cred ();
15955 return 0;
15957 _ACEOF
15958 if ac_fn_c_try_link "$LINENO"; then :
15959 ac_cv_lib_krb_krb_get_cred=yes
15960 else
15961 ac_cv_lib_krb_krb_get_cred=no
15963 rm -f core conftest.err conftest.$ac_objext \
15964 conftest$ac_exeext conftest.$ac_ext
15965 LIBS=$ac_check_lib_save_LIBS
15967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
15968 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
15969 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
15970 have_krb=yes
15971 else
15972 have_krb=no
15975 if test $have_krb = yes; then
15976 KRB4LIB=-lkrb
15977 LIBS="$KRB4LIB $LIBS"
15982 if test "${with_kerberos5}" != no; then
15983 for ac_header in krb5.h
15984 do :
15985 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
15986 if test "x$ac_cv_header_krb5_h" = x""yes; then :
15987 cat >>confdefs.h <<_ACEOF
15988 #define HAVE_KRB5_H 1
15989 _ACEOF
15990 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
15992 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
15994 cat >>confdefs.h <<_ACEOF
15995 #define HAVE_KRB5_ERROR_TEXT 1
15996 _ACEOF
16000 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
16002 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
16004 cat >>confdefs.h <<_ACEOF
16005 #define HAVE_KRB5_ERROR_E_TEXT 1
16006 _ACEOF
16013 done
16015 else
16016 for ac_header in krb.h
16017 do :
16018 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
16019 if test "x$ac_cv_header_krb_h" = x""yes; then :
16020 cat >>confdefs.h <<_ACEOF
16021 #define HAVE_KRB_H 1
16022 _ACEOF
16024 else
16025 for ac_header in kerberosIV/krb.h
16026 do :
16027 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
16028 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
16029 cat >>confdefs.h <<_ACEOF
16030 #define HAVE_KERBEROSIV_KRB_H 1
16031 _ACEOF
16033 else
16034 for ac_header in kerberos/krb.h
16035 do :
16036 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
16037 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
16038 cat >>confdefs.h <<_ACEOF
16039 #define HAVE_KERBEROS_KRB_H 1
16040 _ACEOF
16044 done
16048 done
16052 done
16055 for ac_header in com_err.h
16056 do :
16057 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
16058 if test "x$ac_cv_header_com_err_h" = x""yes; then :
16059 cat >>confdefs.h <<_ACEOF
16060 #define HAVE_COM_ERR_H 1
16061 _ACEOF
16065 done
16078 for ac_func in $ac_func_list
16079 do :
16080 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16081 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16082 eval as_val=\$$as_ac_var
16083 if test "x$as_val" = x""yes; then :
16084 cat >>confdefs.h <<_ACEOF
16085 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16086 _ACEOF
16089 done
16094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
16095 $as_echo_n "checking whether localtime caches TZ... " >&6; }
16096 if test "${emacs_cv_localtime_cache+set}" = set; then :
16097 $as_echo_n "(cached) " >&6
16098 else
16099 if test x$ac_cv_func_tzset = xyes; then
16100 if test "$cross_compiling" = yes; then :
16101 # If we have tzset, assume the worst when cross-compiling.
16102 emacs_cv_localtime_cache=yes
16103 else
16104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16105 /* end confdefs.h. */
16106 #include <time.h>
16107 char TZ_GMT0[] = "TZ=GMT0";
16108 char TZ_PST8[] = "TZ=PST8";
16109 main()
16111 time_t now = time ((time_t *) 0);
16112 int hour_GMT0, hour_unset;
16113 if (putenv (TZ_GMT0) != 0)
16114 exit (1);
16115 hour_GMT0 = localtime (&now)->tm_hour;
16116 unsetenv("TZ");
16117 hour_unset = localtime (&now)->tm_hour;
16118 if (putenv (TZ_PST8) != 0)
16119 exit (1);
16120 if (localtime (&now)->tm_hour == hour_GMT0)
16121 exit (1);
16122 unsetenv("TZ");
16123 if (localtime (&now)->tm_hour != hour_unset)
16124 exit (1);
16125 exit (0);
16127 _ACEOF
16128 if ac_fn_c_try_run "$LINENO"; then :
16129 emacs_cv_localtime_cache=no
16130 else
16131 emacs_cv_localtime_cache=yes
16133 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16134 conftest.$ac_objext conftest.beam conftest.$ac_ext
16137 else
16138 # If we lack tzset, report that localtime does not cache TZ,
16139 # since we can't invalidate the cache if we don't have tzset.
16140 emacs_cv_localtime_cache=no
16143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
16144 $as_echo "$emacs_cv_localtime_cache" >&6; }
16145 if test $emacs_cv_localtime_cache = yes; then
16147 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
16151 ok_so_far=yes
16152 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
16153 if test "x$ac_cv_func_socket" = x""yes; then :
16155 else
16156 ok_so_far=no
16159 if test $ok_so_far = yes; then
16160 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
16161 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
16163 else
16164 ok_so_far=no
16169 if test $ok_so_far = yes; then
16170 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
16171 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
16173 else
16174 ok_so_far=no
16179 if test $ok_so_far = yes; then
16181 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
16185 case $canonical in
16186 *-solaris2.4 | *-solaris2.4.*)
16187 : ${ac_cv_func_vfork_works=no};;
16188 esac
16190 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
16191 if test "x$ac_cv_type_pid_t" = x""yes; then :
16193 else
16195 cat >>confdefs.h <<_ACEOF
16196 #define pid_t int
16197 _ACEOF
16201 for ac_header in vfork.h
16202 do :
16203 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
16204 if test "x$ac_cv_header_vfork_h" = x""yes; then :
16205 cat >>confdefs.h <<_ACEOF
16206 #define HAVE_VFORK_H 1
16207 _ACEOF
16211 done
16213 for ac_func in fork vfork
16214 do :
16215 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16216 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16217 eval as_val=\$$as_ac_var
16218 if test "x$as_val" = x""yes; then :
16219 cat >>confdefs.h <<_ACEOF
16220 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16221 _ACEOF
16224 done
16226 if test "x$ac_cv_func_fork" = xyes; then
16227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
16228 $as_echo_n "checking for working fork... " >&6; }
16229 if test "${ac_cv_func_fork_works+set}" = set; then :
16230 $as_echo_n "(cached) " >&6
16231 else
16232 if test "$cross_compiling" = yes; then :
16233 ac_cv_func_fork_works=cross
16234 else
16235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16236 /* end confdefs.h. */
16237 $ac_includes_default
16239 main ()
16242 /* By Ruediger Kuhlmann. */
16243 return fork () < 0;
16246 return 0;
16248 _ACEOF
16249 if ac_fn_c_try_run "$LINENO"; then :
16250 ac_cv_func_fork_works=yes
16251 else
16252 ac_cv_func_fork_works=no
16254 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16255 conftest.$ac_objext conftest.beam conftest.$ac_ext
16259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
16260 $as_echo "$ac_cv_func_fork_works" >&6; }
16262 else
16263 ac_cv_func_fork_works=$ac_cv_func_fork
16265 if test "x$ac_cv_func_fork_works" = xcross; then
16266 case $host in
16267 *-*-amigaos* | *-*-msdosdjgpp*)
16268 # Override, as these systems have only a dummy fork() stub
16269 ac_cv_func_fork_works=no
16272 ac_cv_func_fork_works=yes
16274 esac
16275 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
16276 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
16278 ac_cv_func_vfork_works=$ac_cv_func_vfork
16279 if test "x$ac_cv_func_vfork" = xyes; then
16280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
16281 $as_echo_n "checking for working vfork... " >&6; }
16282 if test "${ac_cv_func_vfork_works+set}" = set; then :
16283 $as_echo_n "(cached) " >&6
16284 else
16285 if test "$cross_compiling" = yes; then :
16286 ac_cv_func_vfork_works=cross
16287 else
16288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16289 /* end confdefs.h. */
16290 /* Thanks to Paul Eggert for this test. */
16291 $ac_includes_default
16292 #include <sys/wait.h>
16293 #ifdef HAVE_VFORK_H
16294 # include <vfork.h>
16295 #endif
16296 /* On some sparc systems, changes by the child to local and incoming
16297 argument registers are propagated back to the parent. The compiler
16298 is told about this with #include <vfork.h>, but some compilers
16299 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
16300 static variable whose address is put into a register that is
16301 clobbered by the vfork. */
16302 static void
16303 #ifdef __cplusplus
16304 sparc_address_test (int arg)
16305 # else
16306 sparc_address_test (arg) int arg;
16307 #endif
16309 static pid_t child;
16310 if (!child) {
16311 child = vfork ();
16312 if (child < 0) {
16313 perror ("vfork");
16314 _exit(2);
16316 if (!child) {
16317 arg = getpid();
16318 write(-1, "", 0);
16319 _exit (arg);
16325 main ()
16327 pid_t parent = getpid ();
16328 pid_t child;
16330 sparc_address_test (0);
16332 child = vfork ();
16334 if (child == 0) {
16335 /* Here is another test for sparc vfork register problems. This
16336 test uses lots of local variables, at least as many local
16337 variables as main has allocated so far including compiler
16338 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16339 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16340 reuse the register of parent for one of the local variables,
16341 since it will think that parent can't possibly be used any more
16342 in this routine. Assigning to the local variable will thus
16343 munge parent in the parent process. */
16344 pid_t
16345 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16346 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16347 /* Convince the compiler that p..p7 are live; otherwise, it might
16348 use the same hardware register for all 8 local variables. */
16349 if (p != p1 || p != p2 || p != p3 || p != p4
16350 || p != p5 || p != p6 || p != p7)
16351 _exit(1);
16353 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16354 from child file descriptors. If the child closes a descriptor
16355 before it execs or exits, this munges the parent's descriptor
16356 as well. Test for this by closing stdout in the child. */
16357 _exit(close(fileno(stdout)) != 0);
16358 } else {
16359 int status;
16360 struct stat st;
16362 while (wait(&status) != child)
16364 return (
16365 /* Was there some problem with vforking? */
16366 child < 0
16368 /* Did the child fail? (This shouldn't happen.) */
16369 || status
16371 /* Did the vfork/compiler bug occur? */
16372 || parent != getpid()
16374 /* Did the file descriptor bug occur? */
16375 || fstat(fileno(stdout), &st) != 0
16379 _ACEOF
16380 if ac_fn_c_try_run "$LINENO"; then :
16381 ac_cv_func_vfork_works=yes
16382 else
16383 ac_cv_func_vfork_works=no
16385 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16386 conftest.$ac_objext conftest.beam conftest.$ac_ext
16390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16391 $as_echo "$ac_cv_func_vfork_works" >&6; }
16394 if test "x$ac_cv_func_fork_works" = xcross; then
16395 ac_cv_func_vfork_works=$ac_cv_func_vfork
16396 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16397 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16400 if test "x$ac_cv_func_vfork_works" = xyes; then
16402 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16404 else
16406 $as_echo "#define vfork fork" >>confdefs.h
16409 if test "x$ac_cv_func_fork_works" = xyes; then
16411 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16416 for ac_func in snprintf
16417 do :
16418 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16419 if test "x$ac_cv_func_snprintf" = x""yes; then :
16420 cat >>confdefs.h <<_ACEOF
16421 #define HAVE_SNPRINTF 1
16422 _ACEOF
16425 done
16428 XGSELOBJ=
16429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16430 $as_echo_n "checking whether GLib is linked in... " >&6; }
16431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16432 /* end confdefs.h. */
16433 #include <glib.h>
16436 main ()
16438 g_print ("Hello world");
16440 return 0;
16442 _ACEOF
16443 if ac_fn_c_try_link "$LINENO"; then :
16444 links_glib=yes
16445 else
16446 links_glib=no
16448 rm -f core conftest.err conftest.$ac_objext \
16449 conftest$ac_exeext conftest.$ac_ext
16450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16451 $as_echo "$links_glib" >&6; }
16452 if test "${links_glib}" = "yes"; then
16454 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16456 if test "$HAVE_NS" = no;then
16457 XGSELOBJ=xgselect.o
16462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16463 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16464 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16465 $as_echo_n "(cached) " >&6
16466 else
16467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16468 /* end confdefs.h. */
16469 #include <langinfo.h>
16471 main ()
16473 char* cs = nl_langinfo(CODESET);
16475 return 0;
16477 _ACEOF
16478 if ac_fn_c_try_link "$LINENO"; then :
16479 emacs_cv_langinfo_codeset=yes
16480 else
16481 emacs_cv_langinfo_codeset=no
16483 rm -f core conftest.err conftest.$ac_objext \
16484 conftest$ac_exeext conftest.$ac_ext
16487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16488 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16489 if test $emacs_cv_langinfo_codeset = yes; then
16491 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16496 $as_echo_n "checking for mbstate_t... " >&6; }
16497 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16498 $as_echo_n "(cached) " >&6
16499 else
16500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16501 /* end confdefs.h. */
16502 $ac_includes_default
16503 # include <wchar.h>
16505 main ()
16507 mbstate_t x; return sizeof x;
16509 return 0;
16511 _ACEOF
16512 if ac_fn_c_try_compile "$LINENO"; then :
16513 ac_cv_type_mbstate_t=yes
16514 else
16515 ac_cv_type_mbstate_t=no
16517 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16520 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16521 if test $ac_cv_type_mbstate_t = yes; then
16523 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16525 else
16527 $as_echo "#define mbstate_t int" >>confdefs.h
16531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16532 $as_echo_n "checking for C restricted array declarations... " >&6; }
16533 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16534 $as_echo_n "(cached) " >&6
16535 else
16536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16537 /* end confdefs.h. */
16538 void fred (int x[__restrict]);
16540 main ()
16544 return 0;
16546 _ACEOF
16547 if ac_fn_c_try_compile "$LINENO"; then :
16548 emacs_cv_c_restrict_arr=yes
16549 else
16550 emacs_cv_c_restrict_arr=no
16552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16555 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16556 if test "$emacs_cv_c_restrict_arr" = yes; then
16558 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16563 if test "${opsys}" != "mingw32"; then
16565 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16570 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16573 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16574 if test "${opsys}" != "mingw32"; then
16576 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16581 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16587 if test "${opsys}" = "mingw32"; then
16588 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16590 else
16591 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16596 if test "${opsys}" = "mingw32"; then
16597 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16599 else
16600 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16605 $as_echo "#define subprocesses 1" >>confdefs.h
16609 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16614 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16617 if test "${opsys}" = "mingw32"; then
16619 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == ':')" >>confdefs.h
16623 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16627 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16629 else
16631 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16635 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16639 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16645 case $opsys in
16646 aix4-2)
16647 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16648 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16653 hpux*)
16654 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16657 esac
16660 case $opsys in
16661 irix6-5 | sol2* | unixware )
16663 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16666 esac
16668 emacs_broken_SIGIO=no
16670 case $opsys in
16671 hpux* | irix6-5 | openbsd | sol2* | unixware )
16672 emacs_broken_SIGIO=yes
16675 aix4-2)
16677 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16681 freebsd)
16683 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16686 esac
16688 case $opsys in
16689 gnu-* | sol2-10 )
16691 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16694 esac
16696 case $opsys in
16697 darwin | dragonfly | freebsd | netbsd | openbsd )
16699 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16702 esac
16704 case $opsys in
16705 netbsd | openbsd) sound_device="/dev/audio" ;;
16706 *) sound_device="/dev/dsp" ;;
16707 esac
16710 cat >>confdefs.h <<_ACEOF
16711 #define DEFAULT_SOUND_DEVICE "$sound_device"
16712 _ACEOF
16716 case $opsys in
16717 darwin | gnu-linux | gnu-kfreebsd )
16719 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16722 esac
16725 case $opsys in
16726 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16728 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16731 esac
16740 case $opsys in
16741 aix4-2 )
16742 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16744 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16746 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16750 cygwin )
16751 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16753 $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
16755 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16757 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16761 darwin )
16762 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16764 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16766 $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
16768 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16770 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16774 gnu | openbsd )
16775 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16779 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16780 if test "x$ac_cv_func_grantpt" = xyes; then
16782 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16784 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16786 $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
16788 if test "x$ac_cv_func_posix_openpt" = xyes; then
16789 $as_echo "#define PTY_OPEN do { fd = posix_openpt (O_RDWR | O_CLOEXEC | O_NOCTTY); if (fd < 0 && errno == EINVAL) fd = posix_openpt (O_RDWR | O_NOCTTY); } while (0)" >>confdefs.h
16791 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16793 elif test "x$ac_cv_func_getpt" = xyes; then
16794 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16796 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16798 else
16799 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16802 else
16803 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16808 hpux*)
16809 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16811 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16813 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16817 irix6-5 )
16818 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16820 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16822 $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
16824 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16826 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16830 sol2* )
16831 $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
16835 unixware )
16836 $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
16839 esac
16842 case $opsys in
16843 sol2* | unixware )
16844 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16846 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16849 $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
16852 esac
16857 case $opsys in
16858 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
16859 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16863 gnu-linux | gnu-kfreebsd )
16865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
16866 $as_echo_n "checking for signals via characters... " >&6; }
16867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16868 /* end confdefs.h. */
16870 #include <linux/version.h>
16871 #if LINUX_VERSION_CODE < 0x20400
16872 # error "Linux version too old"
16873 #endif
16876 main ()
16880 return 0;
16882 _ACEOF
16883 if ac_fn_c_try_cpp "$LINENO"; then :
16884 emacs_signals_via_chars=yes
16885 else
16886 emacs_signals_via_chars=no
16888 rm -f conftest.err conftest.$ac_ext
16890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
16891 $as_echo "$emacs_signals_via_chars" >&6; }
16892 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16895 esac
16900 case $opsys in
16901 aix*)
16902 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
16905 hpux*)
16906 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
16909 irix6-5)
16910 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
16913 esac
16918 case $opsys in
16919 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
16922 gnu | dragonfly | freebsd | netbsd | openbsd )
16924 $as_echo "#define TABDLY OXTABS" >>confdefs.h
16926 $as_echo "#define TAB3 OXTABS" >>confdefs.h
16930 gnu-linux | gnu-kfreebsd )
16931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16932 /* end confdefs.h. */
16934 #ifndef __ia64__
16935 # error "not ia64"
16936 #endif
16939 main ()
16943 return 0;
16945 _ACEOF
16946 if ac_fn_c_try_cpp "$LINENO"; then :
16948 $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
16951 rm -f conftest.err conftest.$ac_ext
16954 hpux*)
16956 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
16959 esac
16965 case $opsys in
16966 gnu-linux | gnu-kfreebsd )
16967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16968 /* end confdefs.h. */
16970 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
16971 || defined __alpha__ || defined __mips__ || defined __s390__ \
16972 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
16973 || defined __ia64__ || defined __sh__
16974 /* ok */
16975 #else
16976 # error "setjmp not known to work on this arch"
16977 #endif
16980 main ()
16984 return 0;
16986 _ACEOF
16987 if ac_fn_c_try_cpp "$LINENO"; then :
16988 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16991 rm -f conftest.err conftest.$ac_ext
16993 esac
16996 if test x$GCC = xyes; then
16997 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16999 else
17000 case $opsys in
17001 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
17002 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17005 esac
17007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
17008 $as_echo_n "checking for _setjmp... " >&6; }
17009 if test "${emacs_cv_func__setjmp+set}" = set; then :
17010 $as_echo_n "(cached) " >&6
17011 else
17012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17013 /* end confdefs.h. */
17014 #include <setjmp.h>
17015 #ifdef __MINGW32__
17016 # define _longjmp longjmp
17017 #endif
17020 main ()
17022 jmp_buf j;
17023 if (! _setjmp (j))
17024 _longjmp (j, 1);
17026 return 0;
17028 _ACEOF
17029 if ac_fn_c_try_link "$LINENO"; then :
17030 emacs_cv_func__setjmp=yes
17031 else
17032 emacs_cv_func__setjmp=no
17034 rm -f core conftest.err conftest.$ac_objext \
17035 conftest$ac_exeext conftest.$ac_ext
17037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
17038 $as_echo "$emacs_cv_func__setjmp" >&6; }
17039 if test $emacs_cv_func__setjmp = yes; then
17041 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
17043 else
17044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
17045 $as_echo_n "checking for sigsetjmp... " >&6; }
17046 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
17047 $as_echo_n "(cached) " >&6
17048 else
17049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17050 /* end confdefs.h. */
17051 #include <setjmp.h>
17054 main ()
17056 sigjmp_buf j;
17057 if (! sigsetjmp (j, 1))
17058 siglongjmp (j, 1);
17060 return 0;
17062 _ACEOF
17063 if ac_fn_c_try_link "$LINENO"; then :
17064 emacs_cv_func_sigsetjmp=yes
17065 else
17066 emacs_cv_func_sigsetjmp=no
17068 rm -f core conftest.err conftest.$ac_objext \
17069 conftest$ac_exeext conftest.$ac_ext
17071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
17072 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
17073 if test $emacs_cv_func_sigsetjmp = yes; then
17075 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
17080 case $opsys in
17081 sol2* | unixware )
17083 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
17086 esac
17089 case $opsys in
17090 hpux* | sol2* )
17092 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
17095 esac
17103 case $opsys in
17104 aix4-2)
17105 $as_echo "#define USG /**/" >>confdefs.h
17107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17108 /* end confdefs.h. */
17110 #ifndef _AIX
17111 # error "_AIX not defined"
17112 #endif
17115 main ()
17119 return 0;
17121 _ACEOF
17122 if ac_fn_c_try_cpp "$LINENO"; then :
17124 else
17126 $as_echo "#define _AIX /**/" >>confdefs.h
17129 rm -f conftest.err conftest.$ac_ext
17132 cygwin)
17134 $as_echo "#define CYGWIN 1" >>confdefs.h
17138 darwin)
17140 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
17144 gnu-linux | gnu-kfreebsd )
17145 $as_echo "#define USG /**/" >>confdefs.h
17148 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
17152 hpux*)
17153 $as_echo "#define USG /**/" >>confdefs.h
17156 $as_echo "#define HPUX /**/" >>confdefs.h
17160 irix6-5)
17161 $as_echo "#define USG /**/" >>confdefs.h
17163 $as_echo "#define USG5_4 /**/" >>confdefs.h
17166 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
17170 mingw32)
17171 $as_echo "#define DOS_NT /**/" >>confdefs.h
17174 $as_echo "#define WINDOWSNT 1" >>confdefs.h
17176 if test "x$ac_enable_checking" != "x" ; then
17178 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
17183 sol2*)
17184 $as_echo "#define USG /**/" >>confdefs.h
17186 $as_echo "#define USG5_4 /**/" >>confdefs.h
17189 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
17193 unixware)
17194 $as_echo "#define USG /**/" >>confdefs.h
17196 $as_echo "#define USG5_4 /**/" >>confdefs.h
17199 esac
17201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
17202 $as_echo_n "checking for usable FIONREAD... " >&6; }
17203 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
17204 $as_echo_n "(cached) " >&6
17205 else
17206 case $opsys in
17207 aix4-2)
17208 emacs_cv_usable_FIONREAD=no
17211 mingw32)
17212 emacs_cv_usable_FIONREAD=yes
17216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17217 /* end confdefs.h. */
17218 #include <sys/types.h>
17219 #include <sys/ioctl.h>
17220 #ifdef USG5_4
17221 # include <sys/filio.h>
17222 #endif
17225 main ()
17227 int foo = ioctl (0, FIONREAD, &foo);
17229 return 0;
17231 _ACEOF
17232 if ac_fn_c_try_compile "$LINENO"; then :
17233 emacs_cv_usable_FIONREAD=yes
17234 else
17235 emacs_cv_usable_FIONREAD=no
17237 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17239 esac
17241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
17242 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
17243 if test $emacs_cv_usable_FIONREAD = yes; then
17245 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
17248 if test $emacs_broken_SIGIO = no; then
17249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
17250 $as_echo_n "checking for usable SIGIO... " >&6; }
17251 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
17252 $as_echo_n "(cached) " >&6
17253 else
17254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17255 /* end confdefs.h. */
17256 #include <fcntl.h>
17257 #include <signal.h>
17260 main ()
17262 int foo = SIGIO | F_SETFL | FASYNC;
17264 return 0;
17266 _ACEOF
17267 if ac_fn_c_try_compile "$LINENO"; then :
17268 emacs_cv_usable_SIGIO=yes
17269 else
17270 emacs_cv_usable_SIGIO=no
17272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
17275 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
17276 if test $emacs_cv_usable_SIGIO = yes; then
17278 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
17285 case $opsys in
17286 cygwin)
17288 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
17292 hpux11)
17294 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
17298 irix6-5)
17300 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
17304 sol2-10)
17306 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
17309 esac
17311 # Set up the CFLAGS for real compilation, so we can substitute it.
17312 CFLAGS="$REAL_CFLAGS"
17313 CPPFLAGS="$REAL_CPPFLAGS"
17315 ## Hack to detect a buggy GCC version.
17316 if test "x$GCC" = xyes \
17317 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17318 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17319 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17320 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17323 version=$PACKAGE_VERSION
17325 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17327 cat >>confdefs.h <<_ACEOF
17328 #define COPYRIGHT "$copyright"
17329 _ACEOF
17333 ### Specify what sort of things we'll be editing into Makefile and config.h.
17334 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17337 ## Unused?
17360 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17361 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17362 ## end of LIBX_BASE, but nothing ever set it.
17367 ## Used in lwlib/Makefile.in.
17376 if test -n "${term_header}"; then
17378 cat >>confdefs.h <<_ACEOF
17379 #define TERM_HEADER "${term_header}"
17380 _ACEOF
17385 cat >>confdefs.h <<_ACEOF
17386 #define EMACS_CONFIGURATION "${canonical}"
17387 _ACEOF
17390 cat >>confdefs.h <<_ACEOF
17391 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17392 _ACEOF
17396 case $opsys in
17397 mingw32)
17398 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17401 esac
17403 XMENU_OBJ=
17404 XOBJ=
17405 FONT_OBJ=
17406 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17408 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17410 XMENU_OBJ=xmenu.o
17411 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17412 FONT_OBJ=xfont.o
17413 if test "$HAVE_XFT" = "yes"; then
17414 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17415 elif test "$HAVE_FREETYPE" = "yes"; then
17416 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17424 WIDGET_OBJ=
17425 MOTIF_LIBW=
17426 if test "${USE_X_TOOLKIT}" != "none" ; then
17427 WIDGET_OBJ=widget.o
17429 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17431 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17433 $as_echo "#define USE_LUCID 1" >>confdefs.h
17435 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17437 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17439 MOTIF_LIBW=-lXm
17440 case "$opsys" in
17441 gnu-linux)
17442 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17443 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17446 unixware)
17447 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17448 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17449 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17452 aix4-2)
17453 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17454 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17456 esac
17457 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17462 TOOLKIT_LIBW=
17463 case "$USE_X_TOOLKIT" in
17464 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17465 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17466 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17467 esac
17470 if test "${opsys}" != "mingw32"; then
17471 if test "$USE_X_TOOLKIT" = "none"; then
17472 LIBXT_OTHER="\$(LIBXSM)"
17473 OLDXMENU_TARGET="really-oldXMenu"
17474 else
17475 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17476 OLDXMENU_TARGET="really-lwlib"
17481 ## The X Menu stuff is present in the X10 distribution, but missing
17482 ## from X11. If we have X10, just use the installed library;
17483 ## otherwise, use our own copy.
17484 if test "${HAVE_X11}" = "yes" ; then
17486 $as_echo "#define HAVE_X11 1" >>confdefs.h
17489 if test "$USE_X_TOOLKIT" = "none"; then
17490 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17491 else
17492 OLDXMENU="\${lwlibdir}/liblw.a"
17494 LIBXMENU="\$(OLDXMENU)"
17495 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17496 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17497 else
17498 ## For a syntactically valid Makefile; not actually used for anything.
17499 ## See comments in src/Makefile.in.
17500 OLDXMENU=nothing
17501 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17502 if test "${HAVE_X_WINDOWS}" = "yes"; then
17503 LIBXMENU="-lXMenu"
17504 else
17505 LIBXMENU=
17507 LIBX_OTHER=
17508 OLDXMENU_DEPS=
17511 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17512 OLDXMENU_TARGET=
17513 OLDXMENU=nothing
17514 LIBXMENU=
17515 OLDXMENU_DEPS=
17524 if test "${HAVE_MENUS}" = "yes" ; then
17526 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17530 if test "${GNU_MALLOC}" = "yes" ; then
17532 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17536 RALLOC_OBJ=
17537 if test "${REL_ALLOC}" = "yes" ; then
17539 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17542 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17546 if test "$opsys" = "cygwin"; then
17547 CYGWIN_OBJ="sheap.o cygw32.o"
17548 ## Cygwin differs because of its unexec().
17549 PRE_ALLOC_OBJ=
17550 POST_ALLOC_OBJ=lastfile.o
17551 elif test "$opsys" = "mingw32"; then
17552 CYGWIN_OBJ=
17553 PRE_ALLOC_OBJ=
17554 POST_ALLOC_OBJ=lastfile.o
17555 else
17556 CYGWIN_OBJ=
17557 PRE_ALLOC_OBJ=lastfile.o
17558 POST_ALLOC_OBJ=
17564 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17565 # it temporarily reverts them to their pre-pkg-config values,
17566 # because gnulib needs to work with both src (which uses the
17567 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17568 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17569 # and it therefore needs to run in an environment where LIBS does not
17570 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17571 # for some package unrelated to lib-src.
17572 SAVE_CFLAGS=$CFLAGS
17573 SAVE_LIBS=$LIBS
17574 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17575 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17587 LIBC_FATAL_STDERR_=1
17588 export LIBC_FATAL_STDERR_
17590 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17591 # for constant arguments. Useless!
17592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17593 $as_echo_n "checking for working alloca.h... " >&6; }
17594 if test "${ac_cv_working_alloca_h+set}" = set; then :
17595 $as_echo_n "(cached) " >&6
17596 else
17597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17598 /* end confdefs.h. */
17599 #include <alloca.h>
17601 main ()
17603 char *p = (char *) alloca (2 * sizeof (int));
17604 if (p) return 0;
17606 return 0;
17608 _ACEOF
17609 if ac_fn_c_try_link "$LINENO"; then :
17610 ac_cv_working_alloca_h=yes
17611 else
17612 ac_cv_working_alloca_h=no
17614 rm -f core conftest.err conftest.$ac_objext \
17615 conftest$ac_exeext conftest.$ac_ext
17617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17618 $as_echo "$ac_cv_working_alloca_h" >&6; }
17619 if test $ac_cv_working_alloca_h = yes; then
17621 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17626 $as_echo_n "checking for alloca... " >&6; }
17627 if test "${ac_cv_func_alloca_works+set}" = set; then :
17628 $as_echo_n "(cached) " >&6
17629 else
17630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17631 /* end confdefs.h. */
17632 #ifdef __GNUC__
17633 # define alloca __builtin_alloca
17634 #else
17635 # ifdef _MSC_VER
17636 # include <malloc.h>
17637 # define alloca _alloca
17638 # else
17639 # ifdef HAVE_ALLOCA_H
17640 # include <alloca.h>
17641 # else
17642 # ifdef _AIX
17643 #pragma alloca
17644 # else
17645 # ifndef alloca /* predefined by HP cc +Olibcalls */
17646 char *alloca ();
17647 # endif
17648 # endif
17649 # endif
17650 # endif
17651 #endif
17654 main ()
17656 char *p = (char *) alloca (1);
17657 if (p) return 0;
17659 return 0;
17661 _ACEOF
17662 if ac_fn_c_try_link "$LINENO"; then :
17663 ac_cv_func_alloca_works=yes
17664 else
17665 ac_cv_func_alloca_works=no
17667 rm -f core conftest.err conftest.$ac_objext \
17668 conftest$ac_exeext conftest.$ac_ext
17670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17671 $as_echo "$ac_cv_func_alloca_works" >&6; }
17673 if test $ac_cv_func_alloca_works = yes; then
17675 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17677 else
17678 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17679 # that cause trouble. Some versions do not even contain alloca or
17680 # contain a buggy version. If you still want to use their alloca,
17681 # use ar to extract alloca.o from them instead of compiling alloca.c.
17687 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17689 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17693 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17694 if test "${ac_cv_os_cray+set}" = set; then :
17695 $as_echo_n "(cached) " >&6
17696 else
17697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17698 /* end confdefs.h. */
17699 #if defined CRAY && ! defined CRAY2
17700 webecray
17701 #else
17702 wenotbecray
17703 #endif
17705 _ACEOF
17706 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17707 $EGREP "webecray" >/dev/null 2>&1; then :
17708 ac_cv_os_cray=yes
17709 else
17710 ac_cv_os_cray=no
17712 rm -f conftest*
17715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17716 $as_echo "$ac_cv_os_cray" >&6; }
17717 if test $ac_cv_os_cray = yes; then
17718 for ac_func in _getb67 GETB67 getb67; do
17719 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17720 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17721 eval as_val=\$$as_ac_var
17722 if test "x$as_val" = x""yes; then :
17724 cat >>confdefs.h <<_ACEOF
17725 #define CRAY_STACKSEG_END $ac_func
17726 _ACEOF
17728 break
17731 done
17734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17735 $as_echo_n "checking stack direction for C alloca... " >&6; }
17736 if test "${ac_cv_c_stack_direction+set}" = set; then :
17737 $as_echo_n "(cached) " >&6
17738 else
17739 if test "$cross_compiling" = yes; then :
17740 ac_cv_c_stack_direction=0
17741 else
17742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17743 /* end confdefs.h. */
17744 $ac_includes_default
17746 find_stack_direction (int *addr, int depth)
17748 int dir, dummy = 0;
17749 if (! addr)
17750 addr = &dummy;
17751 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17752 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17753 return dir + dummy;
17757 main (int argc, char **argv)
17759 return find_stack_direction (0, argc + !argv + 20) < 0;
17761 _ACEOF
17762 if ac_fn_c_try_run "$LINENO"; then :
17763 ac_cv_c_stack_direction=1
17764 else
17765 ac_cv_c_stack_direction=-1
17767 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17768 conftest.$ac_objext conftest.beam conftest.$ac_ext
17772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17773 $as_echo "$ac_cv_c_stack_direction" >&6; }
17774 cat >>confdefs.h <<_ACEOF
17775 #define STACK_DIRECTION $ac_cv_c_stack_direction
17776 _ACEOF
17784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17785 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17786 if test "${ac_cv_c_bigendian+set}" = set; then :
17787 $as_echo_n "(cached) " >&6
17788 else
17789 ac_cv_c_bigendian=unknown
17790 # See if we're dealing with a universal compiler.
17791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17792 /* end confdefs.h. */
17793 #ifndef __APPLE_CC__
17794 not a universal capable compiler
17795 #endif
17796 typedef int dummy;
17798 _ACEOF
17799 if ac_fn_c_try_compile "$LINENO"; then :
17801 # Check for potential -arch flags. It is not universal unless
17802 # there are at least two -arch flags with different values.
17803 ac_arch=
17804 ac_prev=
17805 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17806 if test -n "$ac_prev"; then
17807 case $ac_word in
17808 i?86 | x86_64 | ppc | ppc64)
17809 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17810 ac_arch=$ac_word
17811 else
17812 ac_cv_c_bigendian=universal
17813 break
17816 esac
17817 ac_prev=
17818 elif test "x$ac_word" = "x-arch"; then
17819 ac_prev=arch
17821 done
17823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17824 if test $ac_cv_c_bigendian = unknown; then
17825 # See if sys/param.h defines the BYTE_ORDER macro.
17826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17827 /* end confdefs.h. */
17828 #include <sys/types.h>
17829 #include <sys/param.h>
17832 main ()
17834 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17835 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17836 && LITTLE_ENDIAN)
17837 bogus endian macros
17838 #endif
17841 return 0;
17843 _ACEOF
17844 if ac_fn_c_try_compile "$LINENO"; then :
17845 # It does; now see whether it defined to BIG_ENDIAN or not.
17846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17847 /* end confdefs.h. */
17848 #include <sys/types.h>
17849 #include <sys/param.h>
17852 main ()
17854 #if BYTE_ORDER != BIG_ENDIAN
17855 not big endian
17856 #endif
17859 return 0;
17861 _ACEOF
17862 if ac_fn_c_try_compile "$LINENO"; then :
17863 ac_cv_c_bigendian=yes
17864 else
17865 ac_cv_c_bigendian=no
17867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17869 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17871 if test $ac_cv_c_bigendian = unknown; then
17872 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
17873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17874 /* end confdefs.h. */
17875 #include <limits.h>
17878 main ()
17880 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
17881 bogus endian macros
17882 #endif
17885 return 0;
17887 _ACEOF
17888 if ac_fn_c_try_compile "$LINENO"; then :
17889 # It does; now see whether it defined to _BIG_ENDIAN or not.
17890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17891 /* end confdefs.h. */
17892 #include <limits.h>
17895 main ()
17897 #ifndef _BIG_ENDIAN
17898 not big endian
17899 #endif
17902 return 0;
17904 _ACEOF
17905 if ac_fn_c_try_compile "$LINENO"; then :
17906 ac_cv_c_bigendian=yes
17907 else
17908 ac_cv_c_bigendian=no
17910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17914 if test $ac_cv_c_bigendian = unknown; then
17915 # Compile a test program.
17916 if test "$cross_compiling" = yes; then :
17917 # Try to guess by grepping values from an object file.
17918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17919 /* end confdefs.h. */
17920 short int ascii_mm[] =
17921 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
17922 short int ascii_ii[] =
17923 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17924 int use_ascii (int i) {
17925 return ascii_mm[i] + ascii_ii[i];
17927 short int ebcdic_ii[] =
17928 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
17929 short int ebcdic_mm[] =
17930 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17931 int use_ebcdic (int i) {
17932 return ebcdic_mm[i] + ebcdic_ii[i];
17934 extern int foo;
17937 main ()
17939 return use_ascii (foo) == use_ebcdic (foo);
17941 return 0;
17943 _ACEOF
17944 if ac_fn_c_try_compile "$LINENO"; then :
17945 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
17946 ac_cv_c_bigendian=yes
17948 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
17949 if test "$ac_cv_c_bigendian" = unknown; then
17950 ac_cv_c_bigendian=no
17951 else
17952 # finding both strings is unlikely to happen, but who knows?
17953 ac_cv_c_bigendian=unknown
17957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17958 else
17959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17960 /* end confdefs.h. */
17961 $ac_includes_default
17963 main ()
17966 /* Are we little or big endian? From Harbison&Steele. */
17967 union
17969 long int l;
17970 char c[sizeof (long int)];
17971 } u;
17972 u.l = 1;
17973 return u.c[sizeof (long int) - 1] == 1;
17976 return 0;
17978 _ACEOF
17979 if ac_fn_c_try_run "$LINENO"; then :
17980 ac_cv_c_bigendian=no
17981 else
17982 ac_cv_c_bigendian=yes
17984 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17985 conftest.$ac_objext conftest.beam conftest.$ac_ext
17990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
17991 $as_echo "$ac_cv_c_bigendian" >&6; }
17992 case $ac_cv_c_bigendian in #(
17993 yes)
17994 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
17995 ;; #(
17997 ;; #(
17998 universal)
18000 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
18002 ;; #(
18004 as_fn_error "unknown endianness
18005 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
18006 esac
18010 GNULIB_CHDIR=0;
18011 GNULIB_CHOWN=0;
18012 GNULIB_CLOSE=0;
18013 GNULIB_DUP=0;
18014 GNULIB_DUP2=0;
18015 GNULIB_DUP3=0;
18016 GNULIB_ENVIRON=0;
18017 GNULIB_EUIDACCESS=0;
18018 GNULIB_FACCESSAT=0;
18019 GNULIB_FCHDIR=0;
18020 GNULIB_FCHOWNAT=0;
18021 GNULIB_FDATASYNC=0;
18022 GNULIB_FSYNC=0;
18023 GNULIB_FTRUNCATE=0;
18024 GNULIB_GETCWD=0;
18025 GNULIB_GETDOMAINNAME=0;
18026 GNULIB_GETDTABLESIZE=0;
18027 GNULIB_GETGROUPS=0;
18028 GNULIB_GETHOSTNAME=0;
18029 GNULIB_GETLOGIN=0;
18030 GNULIB_GETLOGIN_R=0;
18031 GNULIB_GETPAGESIZE=0;
18032 GNULIB_GETUSERSHELL=0;
18033 GNULIB_GROUP_MEMBER=0;
18034 GNULIB_ISATTY=0;
18035 GNULIB_LCHOWN=0;
18036 GNULIB_LINK=0;
18037 GNULIB_LINKAT=0;
18038 GNULIB_LSEEK=0;
18039 GNULIB_PIPE=0;
18040 GNULIB_PIPE2=0;
18041 GNULIB_PREAD=0;
18042 GNULIB_PWRITE=0;
18043 GNULIB_READ=0;
18044 GNULIB_READLINK=0;
18045 GNULIB_READLINKAT=0;
18046 GNULIB_RMDIR=0;
18047 GNULIB_SETHOSTNAME=0;
18048 GNULIB_SLEEP=0;
18049 GNULIB_SYMLINK=0;
18050 GNULIB_SYMLINKAT=0;
18051 GNULIB_TTYNAME_R=0;
18052 GNULIB_UNISTD_H_NONBLOCKING=0;
18053 GNULIB_UNISTD_H_SIGPIPE=0;
18054 GNULIB_UNLINK=0;
18055 GNULIB_UNLINKAT=0;
18056 GNULIB_USLEEP=0;
18057 GNULIB_WRITE=0;
18058 HAVE_CHOWN=1;
18059 HAVE_DUP2=1;
18060 HAVE_DUP3=1;
18061 HAVE_EUIDACCESS=1;
18062 HAVE_FACCESSAT=1;
18063 HAVE_FCHDIR=1;
18064 HAVE_FCHOWNAT=1;
18065 HAVE_FDATASYNC=1;
18066 HAVE_FSYNC=1;
18067 HAVE_FTRUNCATE=1;
18068 HAVE_GETDTABLESIZE=1;
18069 HAVE_GETGROUPS=1;
18070 HAVE_GETHOSTNAME=1;
18071 HAVE_GETLOGIN=1;
18072 HAVE_GETPAGESIZE=1;
18073 HAVE_GROUP_MEMBER=1;
18074 HAVE_LCHOWN=1;
18075 HAVE_LINK=1;
18076 HAVE_LINKAT=1;
18077 HAVE_PIPE=1;
18078 HAVE_PIPE2=1;
18079 HAVE_PREAD=1;
18080 HAVE_PWRITE=1;
18081 HAVE_READLINK=1;
18082 HAVE_READLINKAT=1;
18083 HAVE_SETHOSTNAME=1;
18084 HAVE_SLEEP=1;
18085 HAVE_SYMLINK=1;
18086 HAVE_SYMLINKAT=1;
18087 HAVE_UNLINKAT=1;
18088 HAVE_USLEEP=1;
18089 HAVE_DECL_ENVIRON=1;
18090 HAVE_DECL_FCHDIR=1;
18091 HAVE_DECL_FDATASYNC=1;
18092 HAVE_DECL_GETDOMAINNAME=1;
18093 HAVE_DECL_GETLOGIN_R=1;
18094 HAVE_DECL_GETPAGESIZE=1;
18095 HAVE_DECL_GETUSERSHELL=1;
18096 HAVE_DECL_SETHOSTNAME=1;
18097 HAVE_DECL_TTYNAME_R=1;
18098 HAVE_OS_H=0;
18099 HAVE_SYS_PARAM_H=0;
18100 REPLACE_CHOWN=0;
18101 REPLACE_CLOSE=0;
18102 REPLACE_DUP=0;
18103 REPLACE_DUP2=0;
18104 REPLACE_FCHOWNAT=0;
18105 REPLACE_FTRUNCATE=0;
18106 REPLACE_GETCWD=0;
18107 REPLACE_GETDOMAINNAME=0;
18108 REPLACE_GETLOGIN_R=0;
18109 REPLACE_GETGROUPS=0;
18110 REPLACE_GETPAGESIZE=0;
18111 REPLACE_ISATTY=0;
18112 REPLACE_LCHOWN=0;
18113 REPLACE_LINK=0;
18114 REPLACE_LINKAT=0;
18115 REPLACE_LSEEK=0;
18116 REPLACE_PREAD=0;
18117 REPLACE_PWRITE=0;
18118 REPLACE_READ=0;
18119 REPLACE_READLINK=0;
18120 REPLACE_RMDIR=0;
18121 REPLACE_SLEEP=0;
18122 REPLACE_SYMLINK=0;
18123 REPLACE_TTYNAME_R=0;
18124 REPLACE_UNLINK=0;
18125 REPLACE_UNLINKAT=0;
18126 REPLACE_USLEEP=0;
18127 REPLACE_WRITE=0;
18128 UNISTD_H_HAVE_WINSOCK2_H=0;
18129 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
18133 GNULIB_OPENDIR=0;
18134 GNULIB_READDIR=0;
18135 GNULIB_REWINDDIR=0;
18136 GNULIB_CLOSEDIR=0;
18137 GNULIB_DIRFD=0;
18138 GNULIB_FDOPENDIR=0;
18139 GNULIB_SCANDIR=0;
18140 GNULIB_ALPHASORT=0;
18141 HAVE_OPENDIR=1;
18142 HAVE_READDIR=1;
18143 HAVE_REWINDDIR=1;
18144 HAVE_CLOSEDIR=1;
18145 HAVE_DECL_DIRFD=1;
18146 HAVE_DECL_FDOPENDIR=1;
18147 HAVE_FDOPENDIR=1;
18148 HAVE_SCANDIR=1;
18149 HAVE_ALPHASORT=1;
18150 REPLACE_OPENDIR=0;
18151 REPLACE_CLOSEDIR=0;
18152 REPLACE_DIRFD=0;
18153 REPLACE_FDOPENDIR=0;
18157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
18158 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
18159 if test "${gl_cv_have_include_next+set}" = set; then :
18160 $as_echo_n "(cached) " >&6
18161 else
18162 rm -rf conftestd1a conftestd1b conftestd2
18163 mkdir conftestd1a conftestd1b conftestd2
18164 cat <<EOF > conftestd1a/conftest.h
18165 #define DEFINED_IN_CONFTESTD1
18166 #include_next <conftest.h>
18167 #ifdef DEFINED_IN_CONFTESTD2
18168 int foo;
18169 #else
18170 #error "include_next doesn't work"
18171 #endif
18173 cat <<EOF > conftestd1b/conftest.h
18174 #define DEFINED_IN_CONFTESTD1
18175 #include <stdio.h>
18176 #include_next <conftest.h>
18177 #ifdef DEFINED_IN_CONFTESTD2
18178 int foo;
18179 #else
18180 #error "include_next doesn't work"
18181 #endif
18183 cat <<EOF > conftestd2/conftest.h
18184 #ifndef DEFINED_IN_CONFTESTD1
18185 #error "include_next test doesn't work"
18186 #endif
18187 #define DEFINED_IN_CONFTESTD2
18189 gl_save_CPPFLAGS="$CPPFLAGS"
18190 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
18191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18192 /* end confdefs.h. */
18193 #include <conftest.h>
18194 _ACEOF
18195 if ac_fn_c_try_compile "$LINENO"; then :
18196 gl_cv_have_include_next=yes
18197 else
18198 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
18199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18200 /* end confdefs.h. */
18201 #include <conftest.h>
18202 _ACEOF
18203 if ac_fn_c_try_compile "$LINENO"; then :
18204 gl_cv_have_include_next=buggy
18205 else
18206 gl_cv_have_include_next=no
18208 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18212 CPPFLAGS="$gl_save_CPPFLAGS"
18213 rm -rf conftestd1a conftestd1b conftestd2
18216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
18217 $as_echo "$gl_cv_have_include_next" >&6; }
18218 PRAGMA_SYSTEM_HEADER=
18219 if test $gl_cv_have_include_next = yes; then
18220 INCLUDE_NEXT=include_next
18221 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18222 if test -n "$GCC"; then
18223 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
18225 else
18226 if test $gl_cv_have_include_next = buggy; then
18227 INCLUDE_NEXT=include
18228 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18229 else
18230 INCLUDE_NEXT=include
18231 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
18237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
18238 $as_echo_n "checking whether system header files limit the line length... " >&6; }
18239 if test "${gl_cv_pragma_columns+set}" = set; then :
18240 $as_echo_n "(cached) " >&6
18241 else
18242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18243 /* end confdefs.h. */
18245 #ifdef __TANDEM
18246 choke me
18247 #endif
18249 _ACEOF
18250 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18251 $EGREP "choke me" >/dev/null 2>&1; then :
18252 gl_cv_pragma_columns=yes
18253 else
18254 gl_cv_pragma_columns=no
18256 rm -f conftest*
18260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
18261 $as_echo "$gl_cv_pragma_columns" >&6; }
18262 if test $gl_cv_pragma_columns = yes; then
18263 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
18264 else
18265 PRAGMA_COLUMNS=
18272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
18273 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
18274 if test "${gl_cv_func_c99_strtold+set}" = set; then :
18275 $as_echo_n "(cached) " >&6
18276 else
18277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18278 /* end confdefs.h. */
18279 /* On HP-UX before 11.23, strtold returns a struct instead of
18280 long double. Reject implementations like that, by requiring
18281 compatibility with the C99 prototype. */
18282 #include <stdlib.h>
18283 static long double (*p) (char const *, char **) = strtold;
18284 static long double
18285 test (char const *nptr, char **endptr)
18287 long double r;
18288 r = strtold (nptr, endptr);
18289 return r;
18292 main ()
18294 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
18296 return 0;
18298 _ACEOF
18299 if ac_fn_c_try_link "$LINENO"; then :
18300 gl_cv_func_c99_strtold=yes
18301 else
18302 gl_cv_func_c99_strtold=no
18304 rm -f core conftest.err conftest.$ac_objext \
18305 conftest$ac_exeext conftest.$ac_ext
18307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
18308 $as_echo "$gl_cv_func_c99_strtold" >&6; }
18309 if test $gl_cv_func_c99_strtold = yes; then
18311 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18323 $as_echo_n "checking if environ is properly declared... " >&6; }
18324 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18325 $as_echo_n "(cached) " >&6
18326 else
18328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18329 /* end confdefs.h. */
18330 #if HAVE_UNISTD_H
18331 #include <unistd.h>
18332 #endif
18333 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18334 #include <stdlib.h>
18336 extern struct { int foo; } environ;
18338 main ()
18340 environ.foo = 1;
18342 return 0;
18344 _ACEOF
18345 if ac_fn_c_try_compile "$LINENO"; then :
18346 gt_cv_var_environ_declaration=no
18347 else
18348 gt_cv_var_environ_declaration=yes
18350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18354 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18355 if test $gt_cv_var_environ_declaration = yes; then
18357 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18362 if test $gt_cv_var_environ_declaration != yes; then
18363 HAVE_DECL_ENVIRON=0
18368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18369 $as_echo_n "checking for complete errno.h... " >&6; }
18370 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18371 $as_echo_n "(cached) " >&6
18372 else
18374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18375 /* end confdefs.h. */
18377 #include <errno.h>
18378 #if !defined ETXTBSY
18379 booboo
18380 #endif
18381 #if !defined ENOMSG
18382 booboo
18383 #endif
18384 #if !defined EIDRM
18385 booboo
18386 #endif
18387 #if !defined ENOLINK
18388 booboo
18389 #endif
18390 #if !defined EPROTO
18391 booboo
18392 #endif
18393 #if !defined EMULTIHOP
18394 booboo
18395 #endif
18396 #if !defined EBADMSG
18397 booboo
18398 #endif
18399 #if !defined EOVERFLOW
18400 booboo
18401 #endif
18402 #if !defined ENOTSUP
18403 booboo
18404 #endif
18405 #if !defined ENETRESET
18406 booboo
18407 #endif
18408 #if !defined ECONNABORTED
18409 booboo
18410 #endif
18411 #if !defined ESTALE
18412 booboo
18413 #endif
18414 #if !defined EDQUOT
18415 booboo
18416 #endif
18417 #if !defined ECANCELED
18418 booboo
18419 #endif
18420 #if !defined EOWNERDEAD
18421 booboo
18422 #endif
18423 #if !defined ENOTRECOVERABLE
18424 booboo
18425 #endif
18426 #if !defined EILSEQ
18427 booboo
18428 #endif
18430 _ACEOF
18431 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18432 $EGREP "booboo" >/dev/null 2>&1; then :
18433 gl_cv_header_errno_h_complete=no
18434 else
18435 gl_cv_header_errno_h_complete=yes
18437 rm -f conftest*
18441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18442 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18443 if test $gl_cv_header_errno_h_complete = yes; then
18444 ERRNO_H=''
18445 else
18454 if test $gl_cv_have_include_next = yes; then
18455 gl_cv_next_errno_h='<'errno.h'>'
18456 else
18457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18458 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18459 if test "${gl_cv_next_errno_h+set}" = set; then :
18460 $as_echo_n "(cached) " >&6
18461 else
18463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18464 /* end confdefs.h. */
18465 #include <errno.h>
18467 _ACEOF
18468 case "$host_os" in
18469 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18470 *) gl_absname_cpp="$ac_cpp" ;;
18471 esac
18473 case "$host_os" in
18474 mingw*)
18475 gl_dirsep_regex='[/\\]'
18478 gl_dirsep_regex='\/'
18480 esac
18481 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18483 gl_header_literal_regex=`echo 'errno.h' \
18484 | sed -e "$gl_make_literal_regex_sed"`
18485 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18486 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18487 s|^/[^/]|//&|
18491 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18492 sed -n "$gl_absolute_header_sed"`'"'
18496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18497 $as_echo "$gl_cv_next_errno_h" >&6; }
18499 NEXT_ERRNO_H=$gl_cv_next_errno_h
18501 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18502 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18503 gl_next_as_first_directive='<'errno.h'>'
18504 else
18505 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18506 gl_next_as_first_directive=$gl_cv_next_errno_h
18508 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18513 ERRNO_H='errno.h'
18516 if test -n "$ERRNO_H"; then
18517 GL_GENERATE_ERRNO_H_TRUE=
18518 GL_GENERATE_ERRNO_H_FALSE='#'
18519 else
18520 GL_GENERATE_ERRNO_H_TRUE='#'
18521 GL_GENERATE_ERRNO_H_FALSE=
18525 if test -n "$ERRNO_H"; then
18526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18527 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18528 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18529 $as_echo_n "(cached) " >&6
18530 else
18532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18533 /* end confdefs.h. */
18535 #include <errno.h>
18536 #ifdef EMULTIHOP
18538 #endif
18540 _ACEOF
18541 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18542 $EGREP "yes" >/dev/null 2>&1; then :
18543 gl_cv_header_errno_h_EMULTIHOP=yes
18544 else
18545 gl_cv_header_errno_h_EMULTIHOP=no
18547 rm -f conftest*
18549 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18551 /* end confdefs.h. */
18553 #define _XOPEN_SOURCE_EXTENDED 1
18554 #include <errno.h>
18555 #ifdef EMULTIHOP
18557 #endif
18559 _ACEOF
18560 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18561 $EGREP "yes" >/dev/null 2>&1; then :
18562 gl_cv_header_errno_h_EMULTIHOP=hidden
18564 rm -f conftest*
18566 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18567 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18568 #define _XOPEN_SOURCE_EXTENDED 1
18569 #include <errno.h>
18570 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18571 #include <stdio.h>
18572 #include <stdlib.h>
18573 "; then :
18581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18582 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18583 case $gl_cv_header_errno_h_EMULTIHOP in
18584 yes | no)
18585 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18588 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18590 esac
18596 if test -n "$ERRNO_H"; then
18597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18598 $as_echo_n "checking for ENOLINK value... " >&6; }
18599 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18600 $as_echo_n "(cached) " >&6
18601 else
18603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18604 /* end confdefs.h. */
18606 #include <errno.h>
18607 #ifdef ENOLINK
18609 #endif
18611 _ACEOF
18612 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18613 $EGREP "yes" >/dev/null 2>&1; then :
18614 gl_cv_header_errno_h_ENOLINK=yes
18615 else
18616 gl_cv_header_errno_h_ENOLINK=no
18618 rm -f conftest*
18620 if test $gl_cv_header_errno_h_ENOLINK = no; then
18621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18622 /* end confdefs.h. */
18624 #define _XOPEN_SOURCE_EXTENDED 1
18625 #include <errno.h>
18626 #ifdef ENOLINK
18628 #endif
18630 _ACEOF
18631 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18632 $EGREP "yes" >/dev/null 2>&1; then :
18633 gl_cv_header_errno_h_ENOLINK=hidden
18635 rm -f conftest*
18637 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18638 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18639 #define _XOPEN_SOURCE_EXTENDED 1
18640 #include <errno.h>
18641 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18642 #include <stdio.h>
18643 #include <stdlib.h>
18644 "; then :
18652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18653 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18654 case $gl_cv_header_errno_h_ENOLINK in
18655 yes | no)
18656 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18659 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18661 esac
18667 if test -n "$ERRNO_H"; then
18668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18669 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18670 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18671 $as_echo_n "(cached) " >&6
18672 else
18674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18675 /* end confdefs.h. */
18677 #include <errno.h>
18678 #ifdef EOVERFLOW
18680 #endif
18682 _ACEOF
18683 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18684 $EGREP "yes" >/dev/null 2>&1; then :
18685 gl_cv_header_errno_h_EOVERFLOW=yes
18686 else
18687 gl_cv_header_errno_h_EOVERFLOW=no
18689 rm -f conftest*
18691 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18693 /* end confdefs.h. */
18695 #define _XOPEN_SOURCE_EXTENDED 1
18696 #include <errno.h>
18697 #ifdef EOVERFLOW
18699 #endif
18701 _ACEOF
18702 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18703 $EGREP "yes" >/dev/null 2>&1; then :
18704 gl_cv_header_errno_h_EOVERFLOW=hidden
18706 rm -f conftest*
18708 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18709 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18710 #define _XOPEN_SOURCE_EXTENDED 1
18711 #include <errno.h>
18712 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18713 #include <stdio.h>
18714 #include <stdlib.h>
18715 "; then :
18723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18724 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18725 case $gl_cv_header_errno_h_EOVERFLOW in
18726 yes | no)
18727 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18730 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18732 esac
18746 GNULIB_FCNTL=0;
18747 GNULIB_NONBLOCKING=0;
18748 GNULIB_OPEN=0;
18749 GNULIB_OPENAT=0;
18750 HAVE_FCNTL=1;
18751 HAVE_OPENAT=1;
18752 REPLACE_FCNTL=0;
18753 REPLACE_OPEN=0;
18754 REPLACE_OPENAT=0;
18759 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18760 if test "x$ac_cv_type_mode_t" = x""yes; then :
18762 else
18764 cat >>confdefs.h <<_ACEOF
18765 #define mode_t int
18766 _ACEOF
18770 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18771 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18772 ac_have_decl=1
18773 else
18774 ac_have_decl=0
18777 cat >>confdefs.h <<_ACEOF
18778 #define HAVE_DECL_FDATASYNC $ac_have_decl
18779 _ACEOF
18783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18784 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18785 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18786 $as_echo_n "(cached) " >&6
18787 else
18788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18789 /* end confdefs.h. */
18791 #include <sys/types.h>
18792 #include <sys/stat.h>
18794 main ()
18796 struct stat s; s.st_dm_mode;
18798 return 0;
18800 _ACEOF
18801 if ac_fn_c_try_compile "$LINENO"; then :
18802 ac_cv_struct_st_dm_mode=yes
18803 else
18804 ac_cv_struct_st_dm_mode=no
18806 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
18809 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
18811 if test $ac_cv_struct_st_dm_mode = yes; then
18813 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
18818 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
18819 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
18820 ac_have_decl=1
18821 else
18822 ac_have_decl=0
18825 cat >>confdefs.h <<_ACEOF
18826 #define HAVE_DECL_STRMODE $ac_have_decl
18827 _ACEOF
18832 GNULIB_FCHMODAT=0;
18833 GNULIB_FSTAT=0;
18834 GNULIB_FSTATAT=0;
18835 GNULIB_FUTIMENS=0;
18836 GNULIB_LCHMOD=0;
18837 GNULIB_LSTAT=0;
18838 GNULIB_MKDIRAT=0;
18839 GNULIB_MKFIFO=0;
18840 GNULIB_MKFIFOAT=0;
18841 GNULIB_MKNOD=0;
18842 GNULIB_MKNODAT=0;
18843 GNULIB_STAT=0;
18844 GNULIB_UTIMENSAT=0;
18845 HAVE_FCHMODAT=1;
18846 HAVE_FSTATAT=1;
18847 HAVE_FUTIMENS=1;
18848 HAVE_LCHMOD=1;
18849 HAVE_LSTAT=1;
18850 HAVE_MKDIRAT=1;
18851 HAVE_MKFIFO=1;
18852 HAVE_MKFIFOAT=1;
18853 HAVE_MKNOD=1;
18854 HAVE_MKNODAT=1;
18855 HAVE_UTIMENSAT=1;
18856 REPLACE_FSTAT=0;
18857 REPLACE_FSTATAT=0;
18858 REPLACE_FUTIMENS=0;
18859 REPLACE_LSTAT=0;
18860 REPLACE_MKDIR=0;
18861 REPLACE_MKFIFO=0;
18862 REPLACE_MKNOD=0;
18863 REPLACE_STAT=0;
18864 REPLACE_UTIMENSAT=0;
18867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18868 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18869 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18870 $as_echo_n "(cached) " >&6
18871 else
18872 rm -f conftest.sym conftest.file
18873 echo >conftest.file
18874 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18875 if test "$cross_compiling" = yes; then :
18876 case "$host_os" in
18877 # Guess yes on glibc systems.
18878 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18879 # If we don't know, assume the worst.
18880 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18881 esac
18883 else
18884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18885 /* end confdefs.h. */
18886 $ac_includes_default
18888 main ()
18890 struct stat sbuf;
18891 /* Linux will dereference the symlink and fail, as required by
18892 POSIX. That is better in the sense that it means we will not
18893 have to compile and use the lstat wrapper. */
18894 return lstat ("conftest.sym/", &sbuf) == 0;
18897 return 0;
18899 _ACEOF
18900 if ac_fn_c_try_run "$LINENO"; then :
18901 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18902 else
18903 gl_cv_func_lstat_dereferences_slashed_symlink=no
18905 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18906 conftest.$ac_objext conftest.beam conftest.$ac_ext
18909 else
18910 # If the 'ln -s' command failed, then we probably don't even
18911 # have an lstat function.
18912 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18914 rm -f conftest.sym conftest.file
18917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18918 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18919 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18920 *yes)
18922 cat >>confdefs.h <<_ACEOF
18923 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18924 _ACEOF
18927 esac
18934 GNULIB__EXIT=0;
18935 GNULIB_ATOLL=0;
18936 GNULIB_CALLOC_POSIX=0;
18937 GNULIB_CANONICALIZE_FILE_NAME=0;
18938 GNULIB_GETLOADAVG=0;
18939 GNULIB_GETSUBOPT=0;
18940 GNULIB_GRANTPT=0;
18941 GNULIB_MALLOC_POSIX=0;
18942 GNULIB_MBTOWC=0;
18943 GNULIB_MKDTEMP=0;
18944 GNULIB_MKOSTEMP=0;
18945 GNULIB_MKOSTEMPS=0;
18946 GNULIB_MKSTEMP=0;
18947 GNULIB_MKSTEMPS=0;
18948 GNULIB_POSIX_OPENPT=0;
18949 GNULIB_PTSNAME=0;
18950 GNULIB_PTSNAME_R=0;
18951 GNULIB_PUTENV=0;
18952 GNULIB_RANDOM=0;
18953 GNULIB_RANDOM_R=0;
18954 GNULIB_REALLOC_POSIX=0;
18955 GNULIB_REALPATH=0;
18956 GNULIB_RPMATCH=0;
18957 GNULIB_SECURE_GETENV=0;
18958 GNULIB_SETENV=0;
18959 GNULIB_STRTOD=0;
18960 GNULIB_STRTOLL=0;
18961 GNULIB_STRTOULL=0;
18962 GNULIB_SYSTEM_POSIX=0;
18963 GNULIB_UNLOCKPT=0;
18964 GNULIB_UNSETENV=0;
18965 GNULIB_WCTOMB=0;
18966 HAVE__EXIT=1;
18967 HAVE_ATOLL=1;
18968 HAVE_CANONICALIZE_FILE_NAME=1;
18969 HAVE_DECL_GETLOADAVG=1;
18970 HAVE_GETSUBOPT=1;
18971 HAVE_GRANTPT=1;
18972 HAVE_MKDTEMP=1;
18973 HAVE_MKOSTEMP=1;
18974 HAVE_MKOSTEMPS=1;
18975 HAVE_MKSTEMP=1;
18976 HAVE_MKSTEMPS=1;
18977 HAVE_POSIX_OPENPT=1;
18978 HAVE_PTSNAME=1;
18979 HAVE_PTSNAME_R=1;
18980 HAVE_RANDOM=1;
18981 HAVE_RANDOM_H=1;
18982 HAVE_RANDOM_R=1;
18983 HAVE_REALPATH=1;
18984 HAVE_RPMATCH=1;
18985 HAVE_SECURE_GETENV=1;
18986 HAVE_SETENV=1;
18987 HAVE_DECL_SETENV=1;
18988 HAVE_STRTOD=1;
18989 HAVE_STRTOLL=1;
18990 HAVE_STRTOULL=1;
18991 HAVE_STRUCT_RANDOM_DATA=1;
18992 HAVE_SYS_LOADAVG_H=0;
18993 HAVE_UNLOCKPT=1;
18994 HAVE_DECL_UNSETENV=1;
18995 REPLACE_CALLOC=0;
18996 REPLACE_CANONICALIZE_FILE_NAME=0;
18997 REPLACE_MALLOC=0;
18998 REPLACE_MBTOWC=0;
18999 REPLACE_MKSTEMP=0;
19000 REPLACE_PTSNAME=0;
19001 REPLACE_PTSNAME_R=0;
19002 REPLACE_PUTENV=0;
19003 REPLACE_RANDOM_R=0;
19004 REPLACE_REALLOC=0;
19005 REPLACE_REALPATH=0;
19006 REPLACE_SETENV=0;
19007 REPLACE_STRTOD=0;
19008 REPLACE_UNSETENV=0;
19009 REPLACE_WCTOMB=0;
19026 if test $gl_cv_have_include_next = yes; then
19027 gl_cv_next_getopt_h='<'getopt.h'>'
19028 else
19029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
19030 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
19031 if test "${gl_cv_next_getopt_h+set}" = set; then :
19032 $as_echo_n "(cached) " >&6
19033 else
19035 if test $ac_cv_header_getopt_h = yes; then
19038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19039 /* end confdefs.h. */
19040 #include <getopt.h>
19042 _ACEOF
19043 case "$host_os" in
19044 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19045 *) gl_absname_cpp="$ac_cpp" ;;
19046 esac
19048 case "$host_os" in
19049 mingw*)
19050 gl_dirsep_regex='[/\\]'
19053 gl_dirsep_regex='\/'
19055 esac
19056 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19058 gl_header_literal_regex=`echo 'getopt.h' \
19059 | sed -e "$gl_make_literal_regex_sed"`
19060 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19061 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19062 s|^/[^/]|//&|
19066 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19067 sed -n "$gl_absolute_header_sed"`'"'
19068 else
19069 gl_cv_next_getopt_h='<'getopt.h'>'
19074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
19075 $as_echo "$gl_cv_next_getopt_h" >&6; }
19077 NEXT_GETOPT_H=$gl_cv_next_getopt_h
19079 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19080 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19081 gl_next_as_first_directive='<'getopt.h'>'
19082 else
19083 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19084 gl_next_as_first_directive=$gl_cv_next_getopt_h
19086 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
19091 if test $ac_cv_header_getopt_h = yes; then
19092 HAVE_GETOPT_H=1
19093 else
19094 HAVE_GETOPT_H=0
19098 gl_replace_getopt=
19100 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19101 for ac_header in getopt.h
19102 do :
19103 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
19104 if test "x$ac_cv_header_getopt_h" = x""yes; then :
19105 cat >>confdefs.h <<_ACEOF
19106 #define HAVE_GETOPT_H 1
19107 _ACEOF
19109 else
19110 gl_replace_getopt=yes
19113 done
19117 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19118 for ac_func in getopt_long_only
19119 do :
19120 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
19121 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
19122 cat >>confdefs.h <<_ACEOF
19123 #define HAVE_GETOPT_LONG_ONLY 1
19124 _ACEOF
19126 else
19127 gl_replace_getopt=yes
19129 done
19133 if test -z "$gl_replace_getopt"; then
19134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
19135 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
19136 if test "${gl_cv_func_getopt_posix+set}" = set; then :
19137 $as_echo_n "(cached) " >&6
19138 else
19140 if test $cross_compiling = no; then
19141 if test "$cross_compiling" = yes; then :
19142 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19143 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19144 as_fn_error "cannot run test program while cross compiling
19145 See \`config.log' for more details." "$LINENO" 5; }
19146 else
19147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19148 /* end confdefs.h. */
19150 #include <unistd.h>
19151 #include <stdlib.h>
19152 #include <string.h>
19155 main ()
19157 static char program[] = "program";
19158 static char a[] = "-a";
19159 static char foo[] = "foo";
19160 static char bar[] = "bar";
19161 char *argv[] = { program, a, foo, bar, NULL };
19162 int c;
19164 c = getopt (4, argv, "ab");
19165 if (!(c == 'a'))
19166 return 1;
19167 c = getopt (4, argv, "ab");
19168 if (!(c == -1))
19169 return 2;
19170 if (!(optind == 2))
19171 return 3;
19172 return 0;
19175 _ACEOF
19176 if ac_fn_c_try_run "$LINENO"; then :
19177 gl_cv_func_getopt_posix=maybe
19178 else
19179 gl_cv_func_getopt_posix=no
19181 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19182 conftest.$ac_objext conftest.beam conftest.$ac_ext
19185 if test $gl_cv_func_getopt_posix = maybe; then
19186 if test "$cross_compiling" = yes; then :
19187 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19188 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19189 as_fn_error "cannot run test program while cross compiling
19190 See \`config.log' for more details." "$LINENO" 5; }
19191 else
19192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19193 /* end confdefs.h. */
19195 #include <unistd.h>
19196 #include <stdlib.h>
19197 #include <string.h>
19200 main ()
19202 static char program[] = "program";
19203 static char donald[] = "donald";
19204 static char p[] = "-p";
19205 static char billy[] = "billy";
19206 static char duck[] = "duck";
19207 static char a[] = "-a";
19208 static char bar[] = "bar";
19209 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
19210 int c;
19212 c = getopt (7, argv, "+abp:q:");
19213 if (!(c == -1))
19214 return 4;
19215 if (!(strcmp (argv[0], "program") == 0))
19216 return 5;
19217 if (!(strcmp (argv[1], "donald") == 0))
19218 return 6;
19219 if (!(strcmp (argv[2], "-p") == 0))
19220 return 7;
19221 if (!(strcmp (argv[3], "billy") == 0))
19222 return 8;
19223 if (!(strcmp (argv[4], "duck") == 0))
19224 return 9;
19225 if (!(strcmp (argv[5], "-a") == 0))
19226 return 10;
19227 if (!(strcmp (argv[6], "bar") == 0))
19228 return 11;
19229 if (!(optind == 1))
19230 return 12;
19231 return 0;
19234 _ACEOF
19235 if ac_fn_c_try_run "$LINENO"; then :
19236 gl_cv_func_getopt_posix=maybe
19237 else
19238 gl_cv_func_getopt_posix=no
19240 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19241 conftest.$ac_objext conftest.beam conftest.$ac_ext
19245 if test $gl_cv_func_getopt_posix = maybe; then
19246 if test "$cross_compiling" = yes; then :
19247 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19248 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19249 as_fn_error "cannot run test program while cross compiling
19250 See \`config.log' for more details." "$LINENO" 5; }
19251 else
19252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19253 /* end confdefs.h. */
19255 #include <unistd.h>
19256 #include <stdlib.h>
19257 #include <string.h>
19260 main ()
19262 static char program[] = "program";
19263 static char ab[] = "-ab";
19264 char *argv[3] = { program, ab, NULL };
19265 if (getopt (2, argv, "ab:") != 'a')
19266 return 13;
19267 if (getopt (2, argv, "ab:") != '?')
19268 return 14;
19269 if (optopt != 'b')
19270 return 15;
19271 if (optind != 2)
19272 return 16;
19273 return 0;
19276 _ACEOF
19277 if ac_fn_c_try_run "$LINENO"; then :
19278 gl_cv_func_getopt_posix=yes
19279 else
19280 gl_cv_func_getopt_posix=no
19282 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19283 conftest.$ac_objext conftest.beam conftest.$ac_ext
19287 else
19288 case "$host_os" in
19289 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
19290 *) gl_cv_func_getopt_posix="guessing yes";;
19291 esac
19295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
19296 $as_echo "$gl_cv_func_getopt_posix" >&6; }
19297 case "$gl_cv_func_getopt_posix" in
19298 *no) gl_replace_getopt=yes ;;
19299 esac
19302 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
19304 $as_echo_n "checking for working GNU getopt function... " >&6; }
19305 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
19306 $as_echo_n "(cached) " >&6
19307 else
19308 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
19309 # optstring is necessary for programs like m4 that have POSIX-mandated
19310 # semantics for supporting options interspersed with files.
19311 # Also, since getopt_long is a GNU extension, we require optind=0.
19312 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
19313 # so take care to revert to the correct (non-)export state.
19314 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19315 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19316 xx) gl_had_POSIXLY_CORRECT=exported ;;
19317 x) gl_had_POSIXLY_CORRECT=yes ;;
19318 *) gl_had_POSIXLY_CORRECT= ;;
19319 esac
19320 POSIXLY_CORRECT=1
19321 export POSIXLY_CORRECT
19322 if test "$cross_compiling" = yes; then :
19323 gl_cv_func_getopt_gnu="guessing no"
19325 else
19326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19327 /* end confdefs.h. */
19328 #include <getopt.h>
19329 #include <stddef.h>
19330 #include <string.h>
19332 #include <stdlib.h>
19333 #if defined __MACH__ && defined __APPLE__
19334 /* Avoid a crash on Mac OS X. */
19335 #include <mach/mach.h>
19336 #include <mach/mach_error.h>
19337 #include <mach/thread_status.h>
19338 #include <mach/exception.h>
19339 #include <mach/task.h>
19340 #include <pthread.h>
19341 /* The exception port on which our thread listens. */
19342 static mach_port_t our_exception_port;
19343 /* The main function of the thread listening for exceptions of type
19344 EXC_BAD_ACCESS. */
19345 static void *
19346 mach_exception_thread (void *arg)
19348 /* Buffer for a message to be received. */
19349 struct {
19350 mach_msg_header_t head;
19351 mach_msg_body_t msgh_body;
19352 char data[1024];
19353 } msg;
19354 mach_msg_return_t retval;
19355 /* Wait for a message on the exception port. */
19356 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19357 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19358 if (retval != MACH_MSG_SUCCESS)
19359 abort ();
19360 exit (1);
19362 static void
19363 nocrash_init (void)
19365 mach_port_t self = mach_task_self ();
19366 /* Allocate a port on which the thread shall listen for exceptions. */
19367 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19368 == KERN_SUCCESS) {
19369 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19370 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19371 MACH_MSG_TYPE_MAKE_SEND)
19372 == KERN_SUCCESS) {
19373 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19374 for us. */
19375 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19376 /* Create the thread listening on the exception port. */
19377 pthread_attr_t attr;
19378 pthread_t thread;
19379 if (pthread_attr_init (&attr) == 0
19380 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19381 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19382 pthread_attr_destroy (&attr);
19383 /* Replace the exception port info for these exceptions with our own.
19384 Note that we replace the exception port for the entire task, not only
19385 for a particular thread. This has the effect that when our exception
19386 port gets the message, the thread specific exception port has already
19387 been asked, and we don't need to bother about it.
19388 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19389 task_set_exception_ports (self, mask, our_exception_port,
19390 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19395 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19396 /* Avoid a crash on native Windows. */
19397 #define WIN32_LEAN_AND_MEAN
19398 #include <windows.h>
19399 #include <winerror.h>
19400 static LONG WINAPI
19401 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19403 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19405 case EXCEPTION_ACCESS_VIOLATION:
19406 case EXCEPTION_IN_PAGE_ERROR:
19407 case EXCEPTION_STACK_OVERFLOW:
19408 case EXCEPTION_GUARD_PAGE:
19409 case EXCEPTION_PRIV_INSTRUCTION:
19410 case EXCEPTION_ILLEGAL_INSTRUCTION:
19411 case EXCEPTION_DATATYPE_MISALIGNMENT:
19412 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19413 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19414 exit (1);
19416 return EXCEPTION_CONTINUE_SEARCH;
19418 static void
19419 nocrash_init (void)
19421 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19423 #else
19424 /* Avoid a crash on POSIX systems. */
19425 #include <signal.h>
19426 /* A POSIX signal handler. */
19427 static void
19428 exception_handler (int sig)
19430 exit (1);
19432 static void
19433 nocrash_init (void)
19435 #ifdef SIGSEGV
19436 signal (SIGSEGV, exception_handler);
19437 #endif
19438 #ifdef SIGBUS
19439 signal (SIGBUS, exception_handler);
19440 #endif
19442 #endif
19446 main ()
19449 int result = 0;
19451 nocrash_init();
19453 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19454 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19455 OSF/1 5.1, Solaris 10. */
19457 static char conftest[] = "conftest";
19458 static char plus[] = "-+";
19459 char *argv[3] = { conftest, plus, NULL };
19460 opterr = 0;
19461 if (getopt (2, argv, "+a") != '?')
19462 result |= 1;
19464 /* This code succeeds on glibc 2.8, mingw,
19465 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19466 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19468 static char program[] = "program";
19469 static char p[] = "-p";
19470 static char foo[] = "foo";
19471 static char bar[] = "bar";
19472 char *argv[] = { program, p, foo, bar, NULL };
19474 optind = 1;
19475 if (getopt (4, argv, "p::") != 'p')
19476 result |= 2;
19477 else if (optarg != NULL)
19478 result |= 4;
19479 else if (getopt (4, argv, "p::") != -1)
19480 result |= 6;
19481 else if (optind != 2)
19482 result |= 8;
19484 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19486 static char program[] = "program";
19487 static char foo[] = "foo";
19488 static char p[] = "-p";
19489 char *argv[] = { program, foo, p, NULL };
19490 optind = 0;
19491 if (getopt (3, argv, "-p") != 1)
19492 result |= 16;
19493 else if (getopt (3, argv, "-p") != 'p')
19494 result |= 16;
19496 /* This code fails on glibc 2.11. */
19498 static char program[] = "program";
19499 static char b[] = "-b";
19500 static char a[] = "-a";
19501 char *argv[] = { program, b, a, NULL };
19502 optind = opterr = 0;
19503 if (getopt (3, argv, "+:a:b") != 'b')
19504 result |= 32;
19505 else if (getopt (3, argv, "+:a:b") != ':')
19506 result |= 32;
19508 /* This code dumps core on glibc 2.14. */
19510 static char program[] = "program";
19511 static char w[] = "-W";
19512 static char dummy[] = "dummy";
19513 char *argv[] = { program, w, dummy, NULL };
19514 optind = opterr = 1;
19515 if (getopt (3, argv, "W;") != 'W')
19516 result |= 64;
19518 return result;
19521 return 0;
19523 _ACEOF
19524 if ac_fn_c_try_run "$LINENO"; then :
19525 gl_cv_func_getopt_gnu=yes
19526 else
19527 gl_cv_func_getopt_gnu=no
19529 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19530 conftest.$ac_objext conftest.beam conftest.$ac_ext
19533 case $gl_had_POSIXLY_CORRECT in
19534 exported) ;;
19535 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19536 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19537 esac
19540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19541 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19542 if test "$gl_cv_func_getopt_gnu" != yes; then
19543 gl_replace_getopt=yes
19544 else
19545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19546 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19547 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19548 $as_echo_n "(cached) " >&6
19549 else
19550 if test "$cross_compiling" = yes; then :
19551 case "$host_os" in
19552 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19553 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19554 esac
19556 else
19557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19558 /* end confdefs.h. */
19559 #include <getopt.h>
19560 #include <stddef.h>
19561 #include <string.h>
19564 main ()
19566 static const struct option long_options[] =
19568 { "xtremely-",no_argument, NULL, 1003 },
19569 { "xtra", no_argument, NULL, 1001 },
19570 { "xtreme", no_argument, NULL, 1002 },
19571 { "xtremely", no_argument, NULL, 1003 },
19572 { NULL, 0, NULL, 0 }
19574 /* This code fails on OpenBSD 5.0. */
19576 static char program[] = "program";
19577 static char xtremel[] = "--xtremel";
19578 char *argv[] = { program, xtremel, NULL };
19579 int option_index;
19580 optind = 1; opterr = 0;
19581 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19582 return 1;
19584 return 0;
19587 return 0;
19589 _ACEOF
19590 if ac_fn_c_try_run "$LINENO"; then :
19591 gl_cv_func_getopt_long_gnu=yes
19592 else
19593 gl_cv_func_getopt_long_gnu=no
19595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19596 conftest.$ac_objext conftest.beam conftest.$ac_ext
19601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19602 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19603 case "$gl_cv_func_getopt_long_gnu" in
19604 *yes) ;;
19605 *) gl_replace_getopt=yes ;;
19606 esac
19615 REPLACE_GETOPT=0
19616 if test -n "$gl_replace_getopt"; then
19617 REPLACE_GETOPT=1
19620 if test $REPLACE_GETOPT = 1; then
19622 GETOPT_H=getopt.h
19624 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19630 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19631 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19632 ac_have_decl=1
19633 else
19634 ac_have_decl=0
19637 cat >>confdefs.h <<_ACEOF
19638 #define HAVE_DECL_GETENV $ac_have_decl
19639 _ACEOF
19646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19647 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19648 if test "${ac_cv_c_restrict+set}" = set; then :
19649 $as_echo_n "(cached) " >&6
19650 else
19651 ac_cv_c_restrict=no
19652 # The order here caters to the fact that C++ does not require restrict.
19653 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19655 /* end confdefs.h. */
19656 typedef int * int_ptr;
19657 int foo (int_ptr $ac_kw ip) {
19658 return ip[0];
19661 main ()
19663 int s[1];
19664 int * $ac_kw t = s;
19665 t[0] = 0;
19666 return foo(t)
19668 return 0;
19670 _ACEOF
19671 if ac_fn_c_try_compile "$LINENO"; then :
19672 ac_cv_c_restrict=$ac_kw
19674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19675 test "$ac_cv_c_restrict" != no && break
19676 done
19679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19680 $as_echo "$ac_cv_c_restrict" >&6; }
19682 case $ac_cv_c_restrict in
19683 restrict) ;;
19684 no) $as_echo "#define restrict /**/" >>confdefs.h
19686 *) cat >>confdefs.h <<_ACEOF
19687 #define restrict $ac_cv_c_restrict
19688 _ACEOF
19690 esac
19693 GNULIB_GETTIMEOFDAY=0;
19694 HAVE_GETTIMEOFDAY=1;
19695 HAVE_STRUCT_TIMEVAL=1;
19696 HAVE_SYS_TIME_H=1;
19697 REPLACE_GETTIMEOFDAY=0;
19698 REPLACE_STRUCT_TIMEVAL=0;
19715 if test $gl_cv_have_include_next = yes; then
19716 gl_cv_next_sys_time_h='<'sys/time.h'>'
19717 else
19718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19719 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19720 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19721 $as_echo_n "(cached) " >&6
19722 else
19724 if test $ac_cv_header_sys_time_h = yes; then
19727 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19728 /* end confdefs.h. */
19729 #include <sys/time.h>
19731 _ACEOF
19732 case "$host_os" in
19733 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19734 *) gl_absname_cpp="$ac_cpp" ;;
19735 esac
19737 case "$host_os" in
19738 mingw*)
19739 gl_dirsep_regex='[/\\]'
19742 gl_dirsep_regex='\/'
19744 esac
19745 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19747 gl_header_literal_regex=`echo 'sys/time.h' \
19748 | sed -e "$gl_make_literal_regex_sed"`
19749 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19750 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19751 s|^/[^/]|//&|
19755 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19756 sed -n "$gl_absolute_header_sed"`'"'
19757 else
19758 gl_cv_next_sys_time_h='<'sys/time.h'>'
19763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19764 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19766 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19768 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19769 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19770 gl_next_as_first_directive='<'sys/time.h'>'
19771 else
19772 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19773 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19775 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19781 if test $ac_cv_header_sys_time_h != yes; then
19782 HAVE_SYS_TIME_H=0
19789 if test $ac_cv_header_sys_socket_h != yes; then
19790 for ac_header in winsock2.h
19791 do :
19792 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19793 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19794 cat >>confdefs.h <<_ACEOF
19795 #define HAVE_WINSOCK2_H 1
19796 _ACEOF
19800 done
19803 if test "$ac_cv_header_winsock2_h" = yes; then
19804 HAVE_WINSOCK2_H=1
19805 UNISTD_H_HAVE_WINSOCK2_H=1
19806 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19807 else
19808 HAVE_WINSOCK2_H=0
19812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
19813 $as_echo_n "checking for struct timeval... " >&6; }
19814 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
19815 $as_echo_n "(cached) " >&6
19816 else
19817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19818 /* end confdefs.h. */
19819 #if HAVE_SYS_TIME_H
19820 #include <sys/time.h>
19821 #endif
19822 #include <time.h>
19823 #if HAVE_WINSOCK2_H
19824 # include <winsock2.h>
19825 #endif
19828 main ()
19830 static struct timeval x; x.tv_sec = x.tv_usec;
19832 return 0;
19834 _ACEOF
19835 if ac_fn_c_try_compile "$LINENO"; then :
19836 gl_cv_sys_struct_timeval=yes
19837 else
19838 gl_cv_sys_struct_timeval=no
19840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
19844 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
19845 if test $gl_cv_sys_struct_timeval != yes; then
19846 HAVE_STRUCT_TIMEVAL=0
19847 else
19848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
19849 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
19850 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
19851 $as_echo_n "(cached) " >&6
19852 else
19853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19854 /* end confdefs.h. */
19855 #if HAVE_SYS_TIME_H
19856 #include <sys/time.h>
19857 #endif
19858 #include <time.h>
19859 #if HAVE_WINSOCK2_H
19860 # include <winsock2.h>
19861 #endif
19864 main ()
19866 static struct timeval x;
19867 typedef int verify_tv_sec_type[
19868 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
19872 return 0;
19874 _ACEOF
19875 if ac_fn_c_try_compile "$LINENO"; then :
19876 gl_cv_sys_struct_timeval_tv_sec=yes
19877 else
19878 gl_cv_sys_struct_timeval_tv_sec=no
19880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
19884 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
19885 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
19886 REPLACE_STRUCT_TIMEVAL=1
19896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
19897 $as_echo_n "checking for unsigned long long int... " >&6; }
19898 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
19899 $as_echo_n "(cached) " >&6
19900 else
19901 ac_cv_type_unsigned_long_long_int=yes
19902 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19904 /* end confdefs.h. */
19906 /* For now, do not test the preprocessor; as of 2007 there are too many
19907 implementations with broken preprocessors. Perhaps this can
19908 be revisited in 2012. In the meantime, code should not expect
19909 #if to work with literals wider than 32 bits. */
19910 /* Test literals. */
19911 long long int ll = 9223372036854775807ll;
19912 long long int nll = -9223372036854775807LL;
19913 unsigned long long int ull = 18446744073709551615ULL;
19914 /* Test constant expressions. */
19915 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
19916 ? 1 : -1)];
19917 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
19918 ? 1 : -1)];
19919 int i = 63;
19921 main ()
19923 /* Test availability of runtime routines for shift and division. */
19924 long long int llmax = 9223372036854775807ll;
19925 unsigned long long int ullmax = 18446744073709551615ull;
19926 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
19927 | (llmax / ll) | (llmax % ll)
19928 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
19929 | (ullmax / ull) | (ullmax % ull));
19931 return 0;
19934 _ACEOF
19935 if ac_fn_c_try_link "$LINENO"; then :
19937 else
19938 ac_cv_type_unsigned_long_long_int=no
19940 rm -f core conftest.err conftest.$ac_objext \
19941 conftest$ac_exeext conftest.$ac_ext
19944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
19945 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
19946 if test $ac_cv_type_unsigned_long_long_int = yes; then
19948 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
19954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
19955 $as_echo_n "checking for long long int... " >&6; }
19956 if test "${ac_cv_type_long_long_int+set}" = set; then :
19957 $as_echo_n "(cached) " >&6
19958 else
19959 ac_cv_type_long_long_int=yes
19960 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19961 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
19962 if test $ac_cv_type_long_long_int = yes; then
19963 if test "$cross_compiling" = yes; then :
19965 else
19966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19967 /* end confdefs.h. */
19968 #include <limits.h>
19969 #ifndef LLONG_MAX
19970 # define HALF \
19971 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
19972 # define LLONG_MAX (HALF - 1 + HALF)
19973 #endif
19975 main ()
19977 long long int n = 1;
19978 int i;
19979 for (i = 0; ; i++)
19981 long long int m = n << i;
19982 if (m >> i != n)
19983 return 1;
19984 if (LLONG_MAX / 2 < m)
19985 break;
19987 return 0;
19989 return 0;
19991 _ACEOF
19992 if ac_fn_c_try_run "$LINENO"; then :
19994 else
19995 ac_cv_type_long_long_int=no
19997 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19998 conftest.$ac_objext conftest.beam conftest.$ac_ext
20004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
20005 $as_echo "$ac_cv_type_long_long_int" >&6; }
20006 if test $ac_cv_type_long_long_int = yes; then
20008 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
20017 gl_cv_c_multiarch=no
20018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20019 /* end confdefs.h. */
20020 #ifndef __APPLE_CC__
20021 not a universal capable compiler
20022 #endif
20023 typedef int dummy;
20025 _ACEOF
20026 if ac_fn_c_try_compile "$LINENO"; then :
20028 arch=
20029 prev=
20030 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
20031 if test -n "$prev"; then
20032 case $word in
20033 i?86 | x86_64 | ppc | ppc64)
20034 if test -z "$arch" || test "$arch" = "$word"; then
20035 arch="$word"
20036 else
20037 gl_cv_c_multiarch=yes
20040 esac
20041 prev=
20042 else
20043 if test "x$word" = "x-arch"; then
20044 prev=arch
20047 done
20050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20051 if test $gl_cv_c_multiarch = yes; then
20052 APPLE_UNIVERSAL_BUILD=1
20053 else
20054 APPLE_UNIVERSAL_BUILD=0
20061 if test $ac_cv_type_long_long_int = yes; then
20062 HAVE_LONG_LONG_INT=1
20063 else
20064 HAVE_LONG_LONG_INT=0
20068 if test $ac_cv_type_unsigned_long_long_int = yes; then
20069 HAVE_UNSIGNED_LONG_LONG_INT=1
20070 else
20071 HAVE_UNSIGNED_LONG_LONG_INT=0
20076 if test $ac_cv_header_wchar_h = yes; then
20077 HAVE_WCHAR_H=1
20078 else
20079 HAVE_WCHAR_H=0
20083 if test $ac_cv_header_inttypes_h = yes; then
20084 HAVE_INTTYPES_H=1
20085 else
20086 HAVE_INTTYPES_H=0
20090 if test $ac_cv_header_sys_types_h = yes; then
20091 HAVE_SYS_TYPES_H=1
20092 else
20093 HAVE_SYS_TYPES_H=0
20106 if test $gl_cv_have_include_next = yes; then
20107 gl_cv_next_stdint_h='<'stdint.h'>'
20108 else
20109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
20110 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
20111 if test "${gl_cv_next_stdint_h+set}" = set; then :
20112 $as_echo_n "(cached) " >&6
20113 else
20115 if test $ac_cv_header_stdint_h = yes; then
20118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20119 /* end confdefs.h. */
20120 #include <stdint.h>
20122 _ACEOF
20123 case "$host_os" in
20124 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20125 *) gl_absname_cpp="$ac_cpp" ;;
20126 esac
20128 case "$host_os" in
20129 mingw*)
20130 gl_dirsep_regex='[/\\]'
20133 gl_dirsep_regex='\/'
20135 esac
20136 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20138 gl_header_literal_regex=`echo 'stdint.h' \
20139 | sed -e "$gl_make_literal_regex_sed"`
20140 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20141 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20142 s|^/[^/]|//&|
20146 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20147 sed -n "$gl_absolute_header_sed"`'"'
20148 else
20149 gl_cv_next_stdint_h='<'stdint.h'>'
20154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
20155 $as_echo "$gl_cv_next_stdint_h" >&6; }
20157 NEXT_STDINT_H=$gl_cv_next_stdint_h
20159 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20160 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20161 gl_next_as_first_directive='<'stdint.h'>'
20162 else
20163 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20164 gl_next_as_first_directive=$gl_cv_next_stdint_h
20166 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
20171 if test $ac_cv_header_stdint_h = yes; then
20172 HAVE_STDINT_H=1
20173 else
20174 HAVE_STDINT_H=0
20178 if test $ac_cv_header_stdint_h = yes; then
20179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
20180 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
20181 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
20182 $as_echo_n "(cached) " >&6
20183 else
20184 gl_cv_header_working_stdint_h=no
20185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20186 /* end confdefs.h. */
20189 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20190 #include <stdint.h>
20191 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
20192 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
20193 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
20194 #endif
20197 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20198 included before <wchar.h>. */
20199 #include <stddef.h>
20200 #include <signal.h>
20201 #if HAVE_WCHAR_H
20202 # include <stdio.h>
20203 # include <time.h>
20204 # include <wchar.h>
20205 #endif
20208 #ifdef INT8_MAX
20209 int8_t a1 = INT8_MAX;
20210 int8_t a1min = INT8_MIN;
20211 #endif
20212 #ifdef INT16_MAX
20213 int16_t a2 = INT16_MAX;
20214 int16_t a2min = INT16_MIN;
20215 #endif
20216 #ifdef INT32_MAX
20217 int32_t a3 = INT32_MAX;
20218 int32_t a3min = INT32_MIN;
20219 #endif
20220 #ifdef INT64_MAX
20221 int64_t a4 = INT64_MAX;
20222 int64_t a4min = INT64_MIN;
20223 #endif
20224 #ifdef UINT8_MAX
20225 uint8_t b1 = UINT8_MAX;
20226 #else
20227 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
20228 #endif
20229 #ifdef UINT16_MAX
20230 uint16_t b2 = UINT16_MAX;
20231 #endif
20232 #ifdef UINT32_MAX
20233 uint32_t b3 = UINT32_MAX;
20234 #endif
20235 #ifdef UINT64_MAX
20236 uint64_t b4 = UINT64_MAX;
20237 #endif
20238 int_least8_t c1 = INT8_C (0x7f);
20239 int_least8_t c1max = INT_LEAST8_MAX;
20240 int_least8_t c1min = INT_LEAST8_MIN;
20241 int_least16_t c2 = INT16_C (0x7fff);
20242 int_least16_t c2max = INT_LEAST16_MAX;
20243 int_least16_t c2min = INT_LEAST16_MIN;
20244 int_least32_t c3 = INT32_C (0x7fffffff);
20245 int_least32_t c3max = INT_LEAST32_MAX;
20246 int_least32_t c3min = INT_LEAST32_MIN;
20247 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20248 int_least64_t c4max = INT_LEAST64_MAX;
20249 int_least64_t c4min = INT_LEAST64_MIN;
20250 uint_least8_t d1 = UINT8_C (0xff);
20251 uint_least8_t d1max = UINT_LEAST8_MAX;
20252 uint_least16_t d2 = UINT16_C (0xffff);
20253 uint_least16_t d2max = UINT_LEAST16_MAX;
20254 uint_least32_t d3 = UINT32_C (0xffffffff);
20255 uint_least32_t d3max = UINT_LEAST32_MAX;
20256 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20257 uint_least64_t d4max = UINT_LEAST64_MAX;
20258 int_fast8_t e1 = INT_FAST8_MAX;
20259 int_fast8_t e1min = INT_FAST8_MIN;
20260 int_fast16_t e2 = INT_FAST16_MAX;
20261 int_fast16_t e2min = INT_FAST16_MIN;
20262 int_fast32_t e3 = INT_FAST32_MAX;
20263 int_fast32_t e3min = INT_FAST32_MIN;
20264 int_fast64_t e4 = INT_FAST64_MAX;
20265 int_fast64_t e4min = INT_FAST64_MIN;
20266 uint_fast8_t f1 = UINT_FAST8_MAX;
20267 uint_fast16_t f2 = UINT_FAST16_MAX;
20268 uint_fast32_t f3 = UINT_FAST32_MAX;
20269 uint_fast64_t f4 = UINT_FAST64_MAX;
20270 #ifdef INTPTR_MAX
20271 intptr_t g = INTPTR_MAX;
20272 intptr_t gmin = INTPTR_MIN;
20273 #endif
20274 #ifdef UINTPTR_MAX
20275 uintptr_t h = UINTPTR_MAX;
20276 #endif
20277 intmax_t i = INTMAX_MAX;
20278 uintmax_t j = UINTMAX_MAX;
20280 #include <limits.h> /* for CHAR_BIT */
20281 #define TYPE_MINIMUM(t) \
20282 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
20283 #define TYPE_MAXIMUM(t) \
20284 ((t) ((t) 0 < (t) -1 \
20285 ? (t) -1 \
20286 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
20287 struct s {
20288 int check_PTRDIFF:
20289 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20290 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20291 ? 1 : -1;
20292 /* Detect bug in FreeBSD 6.0 / ia64. */
20293 int check_SIG_ATOMIC:
20294 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20295 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20296 ? 1 : -1;
20297 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20298 int check_WCHAR:
20299 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20300 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20301 ? 1 : -1;
20302 /* Detect bug in mingw. */
20303 int check_WINT:
20304 WINT_MIN == TYPE_MINIMUM (wint_t)
20305 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20306 ? 1 : -1;
20308 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20309 int check_UINT8_C:
20310 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20311 int check_UINT16_C:
20312 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20314 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20315 #ifdef UINT8_MAX
20316 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20317 #endif
20318 #ifdef UINT16_MAX
20319 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20320 #endif
20321 #ifdef UINT32_MAX
20322 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20323 #endif
20324 #ifdef UINT64_MAX
20325 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20326 #endif
20327 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20328 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20329 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20330 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20331 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20332 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20333 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20334 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20335 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20336 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20337 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20341 main ()
20345 return 0;
20347 _ACEOF
20348 if ac_fn_c_try_compile "$LINENO"; then :
20349 if test "$cross_compiling" = yes; then :
20350 gl_cv_header_working_stdint_h=yes
20352 else
20353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20354 /* end confdefs.h. */
20357 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20358 #include <stdint.h>
20361 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20362 included before <wchar.h>. */
20363 #include <stddef.h>
20364 #include <signal.h>
20365 #if HAVE_WCHAR_H
20366 # include <stdio.h>
20367 # include <time.h>
20368 # include <wchar.h>
20369 #endif
20372 #include <stdio.h>
20373 #include <string.h>
20374 #define MVAL(macro) MVAL1(macro)
20375 #define MVAL1(expression) #expression
20376 static const char *macro_values[] =
20378 #ifdef INT8_MAX
20379 MVAL (INT8_MAX),
20380 #endif
20381 #ifdef INT16_MAX
20382 MVAL (INT16_MAX),
20383 #endif
20384 #ifdef INT32_MAX
20385 MVAL (INT32_MAX),
20386 #endif
20387 #ifdef INT64_MAX
20388 MVAL (INT64_MAX),
20389 #endif
20390 #ifdef UINT8_MAX
20391 MVAL (UINT8_MAX),
20392 #endif
20393 #ifdef UINT16_MAX
20394 MVAL (UINT16_MAX),
20395 #endif
20396 #ifdef UINT32_MAX
20397 MVAL (UINT32_MAX),
20398 #endif
20399 #ifdef UINT64_MAX
20400 MVAL (UINT64_MAX),
20401 #endif
20402 NULL
20406 main ()
20409 const char **mv;
20410 for (mv = macro_values; *mv != NULL; mv++)
20412 const char *value = *mv;
20413 /* Test whether it looks like a cast expression. */
20414 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20415 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20416 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20417 || strncmp (value, "((int)"/*)*/, 6) == 0
20418 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20419 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20420 return mv - macro_values + 1;
20422 return 0;
20425 return 0;
20427 _ACEOF
20428 if ac_fn_c_try_run "$LINENO"; then :
20429 gl_cv_header_working_stdint_h=yes
20431 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20432 conftest.$ac_objext conftest.beam conftest.$ac_ext
20437 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20441 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20443 if test "$gl_cv_header_working_stdint_h" = yes; then
20444 STDINT_H=
20445 else
20446 for ac_header in sys/inttypes.h sys/bitypes.h
20447 do :
20448 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20449 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20450 eval as_val=\$$as_ac_Header
20451 if test "x$as_val" = x""yes; then :
20452 cat >>confdefs.h <<_ACEOF
20453 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20454 _ACEOF
20458 done
20460 if test $ac_cv_header_sys_inttypes_h = yes; then
20461 HAVE_SYS_INTTYPES_H=1
20462 else
20463 HAVE_SYS_INTTYPES_H=0
20466 if test $ac_cv_header_sys_bitypes_h = yes; then
20467 HAVE_SYS_BITYPES_H=1
20468 else
20469 HAVE_SYS_BITYPES_H=0
20475 if test $APPLE_UNIVERSAL_BUILD = 0; then
20478 for gltype in ptrdiff_t size_t ; do
20479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20480 $as_echo_n "checking for bit size of $gltype... " >&6; }
20481 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20482 $as_echo_n "(cached) " >&6
20483 else
20484 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20485 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20486 included before <wchar.h>. */
20487 #include <stddef.h>
20488 #include <signal.h>
20489 #if HAVE_WCHAR_H
20490 # include <stdio.h>
20491 # include <time.h>
20492 # include <wchar.h>
20493 #endif
20495 #include <limits.h>"; then :
20497 else
20498 result=unknown
20501 eval gl_cv_bitsizeof_${gltype}=\$result
20504 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20506 $as_echo "$ac_res" >&6; }
20507 eval result=\$gl_cv_bitsizeof_${gltype}
20508 if test $result = unknown; then
20509 result=0
20511 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20512 cat >>confdefs.h <<_ACEOF
20513 #define BITSIZEOF_${GLTYPE} $result
20514 _ACEOF
20516 eval BITSIZEOF_${GLTYPE}=\$result
20517 done
20523 for gltype in sig_atomic_t wchar_t wint_t ; do
20524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20525 $as_echo_n "checking for bit size of $gltype... " >&6; }
20526 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20527 $as_echo_n "(cached) " >&6
20528 else
20529 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20530 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20531 included before <wchar.h>. */
20532 #include <stddef.h>
20533 #include <signal.h>
20534 #if HAVE_WCHAR_H
20535 # include <stdio.h>
20536 # include <time.h>
20537 # include <wchar.h>
20538 #endif
20540 #include <limits.h>"; then :
20542 else
20543 result=unknown
20546 eval gl_cv_bitsizeof_${gltype}=\$result
20549 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20551 $as_echo "$ac_res" >&6; }
20552 eval result=\$gl_cv_bitsizeof_${gltype}
20553 if test $result = unknown; then
20554 result=0
20556 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20557 cat >>confdefs.h <<_ACEOF
20558 #define BITSIZEOF_${GLTYPE} $result
20559 _ACEOF
20561 eval BITSIZEOF_${GLTYPE}=\$result
20562 done
20567 for gltype in sig_atomic_t wchar_t wint_t ; do
20568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20569 $as_echo_n "checking whether $gltype is signed... " >&6; }
20570 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20571 $as_echo_n "(cached) " >&6
20572 else
20573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20574 /* end confdefs.h. */
20576 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20577 included before <wchar.h>. */
20578 #include <stddef.h>
20579 #include <signal.h>
20580 #if HAVE_WCHAR_H
20581 # include <stdio.h>
20582 # include <time.h>
20583 # include <wchar.h>
20584 #endif
20586 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20588 main ()
20592 return 0;
20594 _ACEOF
20595 if ac_fn_c_try_compile "$LINENO"; then :
20596 result=yes
20597 else
20598 result=no
20600 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20601 eval gl_cv_type_${gltype}_signed=\$result
20604 eval ac_res=\$gl_cv_type_${gltype}_signed
20605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20606 $as_echo "$ac_res" >&6; }
20607 eval result=\$gl_cv_type_${gltype}_signed
20608 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20609 if test "$result" = yes; then
20610 cat >>confdefs.h <<_ACEOF
20611 #define HAVE_SIGNED_${GLTYPE} 1
20612 _ACEOF
20614 eval HAVE_SIGNED_${GLTYPE}=1
20615 else
20616 eval HAVE_SIGNED_${GLTYPE}=0
20618 done
20621 gl_cv_type_ptrdiff_t_signed=yes
20622 gl_cv_type_size_t_signed=no
20623 if test $APPLE_UNIVERSAL_BUILD = 0; then
20626 for gltype in ptrdiff_t size_t ; do
20627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20628 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20629 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20630 $as_echo_n "(cached) " >&6
20631 else
20632 eval gl_cv_type_${gltype}_suffix=no
20633 eval result=\$gl_cv_type_${gltype}_signed
20634 if test "$result" = yes; then
20635 glsufu=
20636 else
20637 glsufu=u
20639 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20640 case $glsuf in
20641 '') gltype1='int';;
20642 l) gltype1='long int';;
20643 ll) gltype1='long long int';;
20644 i64) gltype1='__int64';;
20645 u) gltype1='unsigned int';;
20646 ul) gltype1='unsigned long int';;
20647 ull) gltype1='unsigned long long int';;
20648 ui64)gltype1='unsigned __int64';;
20649 esac
20650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20651 /* end confdefs.h. */
20653 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20654 included before <wchar.h>. */
20655 #include <stddef.h>
20656 #include <signal.h>
20657 #if HAVE_WCHAR_H
20658 # include <stdio.h>
20659 # include <time.h>
20660 # include <wchar.h>
20661 #endif
20663 extern $gltype foo;
20664 extern $gltype1 foo;
20666 main ()
20670 return 0;
20672 _ACEOF
20673 if ac_fn_c_try_compile "$LINENO"; then :
20674 eval gl_cv_type_${gltype}_suffix=\$glsuf
20676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20677 eval result=\$gl_cv_type_${gltype}_suffix
20678 test "$result" != no && break
20679 done
20681 eval ac_res=\$gl_cv_type_${gltype}_suffix
20682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20683 $as_echo "$ac_res" >&6; }
20684 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20685 eval result=\$gl_cv_type_${gltype}_suffix
20686 test "$result" = no && result=
20687 eval ${GLTYPE}_SUFFIX=\$result
20688 cat >>confdefs.h <<_ACEOF
20689 #define ${GLTYPE}_SUFFIX $result
20690 _ACEOF
20692 done
20698 for gltype in sig_atomic_t wchar_t wint_t ; do
20699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20700 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20701 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20702 $as_echo_n "(cached) " >&6
20703 else
20704 eval gl_cv_type_${gltype}_suffix=no
20705 eval result=\$gl_cv_type_${gltype}_signed
20706 if test "$result" = yes; then
20707 glsufu=
20708 else
20709 glsufu=u
20711 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20712 case $glsuf in
20713 '') gltype1='int';;
20714 l) gltype1='long int';;
20715 ll) gltype1='long long int';;
20716 i64) gltype1='__int64';;
20717 u) gltype1='unsigned int';;
20718 ul) gltype1='unsigned long int';;
20719 ull) gltype1='unsigned long long int';;
20720 ui64)gltype1='unsigned __int64';;
20721 esac
20722 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20723 /* end confdefs.h. */
20725 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20726 included before <wchar.h>. */
20727 #include <stddef.h>
20728 #include <signal.h>
20729 #if HAVE_WCHAR_H
20730 # include <stdio.h>
20731 # include <time.h>
20732 # include <wchar.h>
20733 #endif
20735 extern $gltype foo;
20736 extern $gltype1 foo;
20738 main ()
20742 return 0;
20744 _ACEOF
20745 if ac_fn_c_try_compile "$LINENO"; then :
20746 eval gl_cv_type_${gltype}_suffix=\$glsuf
20748 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20749 eval result=\$gl_cv_type_${gltype}_suffix
20750 test "$result" != no && break
20751 done
20753 eval ac_res=\$gl_cv_type_${gltype}_suffix
20754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20755 $as_echo "$ac_res" >&6; }
20756 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20757 eval result=\$gl_cv_type_${gltype}_suffix
20758 test "$result" = no && result=
20759 eval ${GLTYPE}_SUFFIX=\$result
20760 cat >>confdefs.h <<_ACEOF
20761 #define ${GLTYPE}_SUFFIX $result
20762 _ACEOF
20764 done
20768 if test $BITSIZEOF_WINT_T -lt 32; then
20769 BITSIZEOF_WINT_T=32
20772 STDINT_H=stdint.h
20775 if test -n "$STDINT_H"; then
20776 GL_GENERATE_STDINT_H_TRUE=
20777 GL_GENERATE_STDINT_H_FALSE='#'
20778 else
20779 GL_GENERATE_STDINT_H_TRUE='#'
20780 GL_GENERATE_STDINT_H_FALSE=
20787 GNULIB_IMAXABS=0;
20788 GNULIB_IMAXDIV=0;
20789 GNULIB_STRTOIMAX=0;
20790 GNULIB_STRTOUMAX=0;
20791 HAVE_DECL_IMAXABS=1;
20792 HAVE_DECL_IMAXDIV=1;
20793 HAVE_DECL_STRTOIMAX=1;
20794 HAVE_DECL_STRTOUMAX=1;
20795 REPLACE_STRTOIMAX=0;
20796 INT32_MAX_LT_INTMAX_MAX=1;
20797 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20798 PRI_MACROS_BROKEN=0;
20799 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20800 UINT32_MAX_LT_UINTMAX_MAX=1;
20801 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20817 if test $gl_cv_have_include_next = yes; then
20818 gl_cv_next_inttypes_h='<'inttypes.h'>'
20819 else
20820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20821 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20822 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20823 $as_echo_n "(cached) " >&6
20824 else
20826 if test $ac_cv_header_inttypes_h = yes; then
20829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20830 /* end confdefs.h. */
20831 #include <inttypes.h>
20833 _ACEOF
20834 case "$host_os" in
20835 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20836 *) gl_absname_cpp="$ac_cpp" ;;
20837 esac
20839 case "$host_os" in
20840 mingw*)
20841 gl_dirsep_regex='[/\\]'
20844 gl_dirsep_regex='\/'
20846 esac
20847 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20849 gl_header_literal_regex=`echo 'inttypes.h' \
20850 | sed -e "$gl_make_literal_regex_sed"`
20851 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20852 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20853 s|^/[^/]|//&|
20857 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20858 sed -n "$gl_absolute_header_sed"`'"'
20859 else
20860 gl_cv_next_inttypes_h='<'inttypes.h'>'
20865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
20866 $as_echo "$gl_cv_next_inttypes_h" >&6; }
20868 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
20870 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20871 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20872 gl_next_as_first_directive='<'inttypes.h'>'
20873 else
20874 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20875 gl_next_as_first_directive=$gl_cv_next_inttypes_h
20877 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
20889 case "$host_os" in
20890 mingw*)
20891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
20892 $as_echo_n "checking for 64-bit off_t... " >&6; }
20893 if test "${gl_cv_type_off_t_64+set}" = set; then :
20894 $as_echo_n "(cached) " >&6
20895 else
20896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20897 /* end confdefs.h. */
20898 #include <sys/types.h>
20899 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
20902 main ()
20906 return 0;
20908 _ACEOF
20909 if ac_fn_c_try_compile "$LINENO"; then :
20910 gl_cv_type_off_t_64=yes
20911 else
20912 gl_cv_type_off_t_64=no
20914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
20918 $as_echo "$gl_cv_type_off_t_64" >&6; }
20919 if test $gl_cv_type_off_t_64 = no; then
20920 WINDOWS_64_BIT_OFF_T=1
20921 else
20922 WINDOWS_64_BIT_OFF_T=0
20924 WINDOWS_64_BIT_ST_SIZE=1
20927 WINDOWS_64_BIT_OFF_T=0
20928 WINDOWS_64_BIT_ST_SIZE=0
20930 esac
20935 GNULIB_FFSL=0;
20936 GNULIB_FFSLL=0;
20937 GNULIB_MEMCHR=0;
20938 GNULIB_MEMMEM=0;
20939 GNULIB_MEMPCPY=0;
20940 GNULIB_MEMRCHR=0;
20941 GNULIB_RAWMEMCHR=0;
20942 GNULIB_STPCPY=0;
20943 GNULIB_STPNCPY=0;
20944 GNULIB_STRCHRNUL=0;
20945 GNULIB_STRDUP=0;
20946 GNULIB_STRNCAT=0;
20947 GNULIB_STRNDUP=0;
20948 GNULIB_STRNLEN=0;
20949 GNULIB_STRPBRK=0;
20950 GNULIB_STRSEP=0;
20951 GNULIB_STRSTR=0;
20952 GNULIB_STRCASESTR=0;
20953 GNULIB_STRTOK_R=0;
20954 GNULIB_MBSLEN=0;
20955 GNULIB_MBSNLEN=0;
20956 GNULIB_MBSCHR=0;
20957 GNULIB_MBSRCHR=0;
20958 GNULIB_MBSSTR=0;
20959 GNULIB_MBSCASECMP=0;
20960 GNULIB_MBSNCASECMP=0;
20961 GNULIB_MBSPCASECMP=0;
20962 GNULIB_MBSCASESTR=0;
20963 GNULIB_MBSCSPN=0;
20964 GNULIB_MBSPBRK=0;
20965 GNULIB_MBSSPN=0;
20966 GNULIB_MBSSEP=0;
20967 GNULIB_MBSTOK_R=0;
20968 GNULIB_STRERROR=0;
20969 GNULIB_STRERROR_R=0;
20970 GNULIB_STRSIGNAL=0;
20971 GNULIB_STRVERSCMP=0;
20972 HAVE_MBSLEN=0;
20973 HAVE_FFSL=1;
20974 HAVE_FFSLL=1;
20975 HAVE_MEMCHR=1;
20976 HAVE_DECL_MEMMEM=1;
20977 HAVE_MEMPCPY=1;
20978 HAVE_DECL_MEMRCHR=1;
20979 HAVE_RAWMEMCHR=1;
20980 HAVE_STPCPY=1;
20981 HAVE_STPNCPY=1;
20982 HAVE_STRCHRNUL=1;
20983 HAVE_DECL_STRDUP=1;
20984 HAVE_DECL_STRNDUP=1;
20985 HAVE_DECL_STRNLEN=1;
20986 HAVE_STRPBRK=1;
20987 HAVE_STRSEP=1;
20988 HAVE_STRCASESTR=1;
20989 HAVE_DECL_STRTOK_R=1;
20990 HAVE_DECL_STRERROR_R=1;
20991 HAVE_DECL_STRSIGNAL=1;
20992 HAVE_STRVERSCMP=1;
20993 REPLACE_MEMCHR=0;
20994 REPLACE_MEMMEM=0;
20995 REPLACE_STPNCPY=0;
20996 REPLACE_STRDUP=0;
20997 REPLACE_STRSTR=0;
20998 REPLACE_STRCASESTR=0;
20999 REPLACE_STRCHRNUL=0;
21000 REPLACE_STRERROR=0;
21001 REPLACE_STRERROR_R=0;
21002 REPLACE_STRNCAT=0;
21003 REPLACE_STRNDUP=0;
21004 REPLACE_STRNLEN=0;
21005 REPLACE_STRSIGNAL=0;
21006 REPLACE_STRTOK_R=0;
21007 UNDEFINE_STRTOK_R=0;
21009 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
21010 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
21011 ac_have_decl=1
21012 else
21013 ac_have_decl=0
21016 cat >>confdefs.h <<_ACEOF
21017 #define HAVE_DECL_MEMRCHR $ac_have_decl
21018 _ACEOF
21023 GNULIB_MKTIME=0;
21024 GNULIB_NANOSLEEP=0;
21025 GNULIB_STRPTIME=0;
21026 GNULIB_TIMEGM=0;
21027 GNULIB_TIME_R=0;
21028 HAVE_DECL_LOCALTIME_R=1;
21029 HAVE_NANOSLEEP=1;
21030 HAVE_STRPTIME=1;
21031 HAVE_TIMEGM=1;
21032 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
21033 REPLACE_MKTIME=GNULIB_PORTCHECK;
21034 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
21035 REPLACE_TIMEGM=GNULIB_PORTCHECK;
21037 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
21038 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
21039 ac_have_decl=1
21040 else
21041 ac_have_decl=0
21044 cat >>confdefs.h <<_ACEOF
21045 #define HAVE_DECL_ALARM $ac_have_decl
21046 _ACEOF
21051 GNULIB_PSELECT=0;
21052 GNULIB_SELECT=0;
21053 HAVE_PSELECT=1;
21054 REPLACE_PSELECT=0;
21055 REPLACE_SELECT=0;
21062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
21063 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
21064 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
21065 $as_echo_n "(cached) " >&6
21066 else
21068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21069 /* end confdefs.h. */
21070 #include <sys/select.h>
21072 main ()
21074 struct timeval b;
21076 return 0;
21078 _ACEOF
21079 if ac_fn_c_try_compile "$LINENO"; then :
21080 gl_cv_header_sys_select_h_selfcontained=yes
21081 else
21082 gl_cv_header_sys_select_h_selfcontained=no
21084 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21085 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
21086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21087 /* end confdefs.h. */
21088 #include <sys/select.h>
21090 main ()
21092 int memset; int bzero;
21094 return 0;
21097 _ACEOF
21098 if ac_fn_c_try_compile "$LINENO"; then :
21099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21100 /* end confdefs.h. */
21101 #include <sys/select.h>
21103 main ()
21106 #undef memset
21107 #define memset nonexistent_memset
21108 extern
21109 #ifdef __cplusplus
21111 #endif
21112 void *memset (void *, int, unsigned long);
21113 #undef bzero
21114 #define bzero nonexistent_bzero
21115 extern
21116 #ifdef __cplusplus
21118 #endif
21119 void bzero (void *, unsigned long);
21120 fd_set fds;
21121 FD_ZERO (&fds);
21124 return 0;
21127 _ACEOF
21128 if ac_fn_c_try_link "$LINENO"; then :
21130 else
21131 gl_cv_header_sys_select_h_selfcontained=no
21133 rm -f core conftest.err conftest.$ac_objext \
21134 conftest$ac_exeext conftest.$ac_ext
21137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
21142 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
21152 if test $gl_cv_have_include_next = yes; then
21153 gl_cv_next_sys_select_h='<'sys/select.h'>'
21154 else
21155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
21156 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
21157 if test "${gl_cv_next_sys_select_h+set}" = set; then :
21158 $as_echo_n "(cached) " >&6
21159 else
21161 if test $ac_cv_header_sys_select_h = yes; then
21164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21165 /* end confdefs.h. */
21166 #include <sys/select.h>
21168 _ACEOF
21169 case "$host_os" in
21170 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21171 *) gl_absname_cpp="$ac_cpp" ;;
21172 esac
21174 case "$host_os" in
21175 mingw*)
21176 gl_dirsep_regex='[/\\]'
21179 gl_dirsep_regex='\/'
21181 esac
21182 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21184 gl_header_literal_regex=`echo 'sys/select.h' \
21185 | sed -e "$gl_make_literal_regex_sed"`
21186 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21187 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21188 s|^/[^/]|//&|
21192 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21193 sed -n "$gl_absolute_header_sed"`'"'
21194 else
21195 gl_cv_next_sys_select_h='<'sys/select.h'>'
21200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
21201 $as_echo "$gl_cv_next_sys_select_h" >&6; }
21203 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
21205 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21206 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21207 gl_next_as_first_directive='<'sys/select.h'>'
21208 else
21209 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21210 gl_next_as_first_directive=$gl_cv_next_sys_select_h
21212 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
21217 if test $ac_cv_header_sys_select_h = yes; then
21218 HAVE_SYS_SELECT_H=1
21219 else
21220 HAVE_SYS_SELECT_H=0
21227 if test $ac_cv_header_sys_socket_h != yes; then
21228 for ac_header in winsock2.h
21229 do :
21230 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21231 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
21232 cat >>confdefs.h <<_ACEOF
21233 #define HAVE_WINSOCK2_H 1
21234 _ACEOF
21238 done
21241 if test "$ac_cv_header_winsock2_h" = yes; then
21242 HAVE_WINSOCK2_H=1
21243 UNISTD_H_HAVE_WINSOCK2_H=1
21244 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21245 else
21246 HAVE_WINSOCK2_H=0
21256 GNULIB_PTHREAD_SIGMASK=0;
21257 GNULIB_RAISE=0;
21258 GNULIB_SIGNAL_H_SIGPIPE=0;
21259 GNULIB_SIGPROCMASK=0;
21260 GNULIB_SIGACTION=0;
21261 HAVE_POSIX_SIGNALBLOCKING=1;
21262 HAVE_PTHREAD_SIGMASK=1;
21263 HAVE_RAISE=1;
21264 HAVE_SIGSET_T=1;
21265 HAVE_SIGINFO_T=1;
21266 HAVE_SIGACTION=1;
21267 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
21269 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
21271 HAVE_SIGHANDLER_T=1;
21272 REPLACE_PTHREAD_SIGMASK=0;
21273 REPLACE_RAISE=0;
21281 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
21282 #include <signal.h>
21283 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
21284 #include <sys/types.h>
21287 if test "x$ac_cv_type_sigset_t" = x""yes; then :
21289 cat >>confdefs.h <<_ACEOF
21290 #define HAVE_SIGSET_T 1
21291 _ACEOF
21293 gl_cv_type_sigset_t=yes
21294 else
21295 gl_cv_type_sigset_t=no
21298 if test $gl_cv_type_sigset_t != yes; then
21299 HAVE_SIGSET_T=0
21304 if test $ac_cv_header_sys_socket_h = no; then
21305 for ac_header in ws2tcpip.h
21306 do :
21307 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
21308 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
21309 cat >>confdefs.h <<_ACEOF
21310 #define HAVE_WS2TCPIP_H 1
21311 _ACEOF
21315 done
21319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21320 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21321 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21322 $as_echo_n "(cached) " >&6
21323 else
21324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21325 /* end confdefs.h. */
21327 #include <stdbool.h>
21328 #ifndef bool
21329 "error: bool is not defined"
21330 #endif
21331 #ifndef false
21332 "error: false is not defined"
21333 #endif
21334 #if false
21335 "error: false is not 0"
21336 #endif
21337 #ifndef true
21338 "error: true is not defined"
21339 #endif
21340 #if true != 1
21341 "error: true is not 1"
21342 #endif
21343 #ifndef __bool_true_false_are_defined
21344 "error: __bool_true_false_are_defined is not defined"
21345 #endif
21347 struct s { _Bool s: 1; _Bool t; } s;
21349 char a[true == 1 ? 1 : -1];
21350 char b[false == 0 ? 1 : -1];
21351 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21352 char d[(bool) 0.5 == true ? 1 : -1];
21353 /* See body of main program for 'e'. */
21354 char f[(_Bool) 0.0 == false ? 1 : -1];
21355 char g[true];
21356 char h[sizeof (_Bool)];
21357 char i[sizeof s.t];
21358 enum { j = false, k = true, l = false * true, m = true * 256 };
21359 /* The following fails for
21360 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21361 _Bool n[m];
21362 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21363 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21364 /* Catch a bug in an HP-UX C compiler. See
21365 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21366 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21368 _Bool q = true;
21369 _Bool *pq = &q;
21372 main ()
21375 bool e = &s;
21376 *pq |= q;
21377 *pq |= ! q;
21378 /* Refer to every declared value, to avoid compiler optimizations. */
21379 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21380 + !m + !n + !o + !p + !q + !pq);
21383 return 0;
21385 _ACEOF
21386 if ac_fn_c_try_compile "$LINENO"; then :
21387 ac_cv_header_stdbool_h=yes
21388 else
21389 ac_cv_header_stdbool_h=no
21391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21394 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21395 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21396 if test "x$ac_cv_type__Bool" = x""yes; then :
21398 cat >>confdefs.h <<_ACEOF
21399 #define HAVE__BOOL 1
21400 _ACEOF
21407 REPLACE_NULL=0;
21408 HAVE_WCHAR_T=1;
21411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21412 $as_echo_n "checking for wchar_t... " >&6; }
21413 if test "${gt_cv_c_wchar_t+set}" = set; then :
21414 $as_echo_n "(cached) " >&6
21415 else
21416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21417 /* end confdefs.h. */
21418 #include <stddef.h>
21419 wchar_t foo = (wchar_t)'\0';
21421 main ()
21425 return 0;
21427 _ACEOF
21428 if ac_fn_c_try_compile "$LINENO"; then :
21429 gt_cv_c_wchar_t=yes
21430 else
21431 gt_cv_c_wchar_t=no
21433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21436 $as_echo "$gt_cv_c_wchar_t" >&6; }
21437 if test $gt_cv_c_wchar_t = yes; then
21439 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21444 GNULIB_DPRINTF=0;
21445 GNULIB_FCLOSE=0;
21446 GNULIB_FDOPEN=0;
21447 GNULIB_FFLUSH=0;
21448 GNULIB_FGETC=0;
21449 GNULIB_FGETS=0;
21450 GNULIB_FOPEN=0;
21451 GNULIB_FPRINTF=0;
21452 GNULIB_FPRINTF_POSIX=0;
21453 GNULIB_FPURGE=0;
21454 GNULIB_FPUTC=0;
21455 GNULIB_FPUTS=0;
21456 GNULIB_FREAD=0;
21457 GNULIB_FREOPEN=0;
21458 GNULIB_FSCANF=0;
21459 GNULIB_FSEEK=0;
21460 GNULIB_FSEEKO=0;
21461 GNULIB_FTELL=0;
21462 GNULIB_FTELLO=0;
21463 GNULIB_FWRITE=0;
21464 GNULIB_GETC=0;
21465 GNULIB_GETCHAR=0;
21466 GNULIB_GETDELIM=0;
21467 GNULIB_GETLINE=0;
21468 GNULIB_OBSTACK_PRINTF=0;
21469 GNULIB_OBSTACK_PRINTF_POSIX=0;
21470 GNULIB_PCLOSE=0;
21471 GNULIB_PERROR=0;
21472 GNULIB_POPEN=0;
21473 GNULIB_PRINTF=0;
21474 GNULIB_PRINTF_POSIX=0;
21475 GNULIB_PUTC=0;
21476 GNULIB_PUTCHAR=0;
21477 GNULIB_PUTS=0;
21478 GNULIB_REMOVE=0;
21479 GNULIB_RENAME=0;
21480 GNULIB_RENAMEAT=0;
21481 GNULIB_SCANF=0;
21482 GNULIB_SNPRINTF=0;
21483 GNULIB_SPRINTF_POSIX=0;
21484 GNULIB_STDIO_H_NONBLOCKING=0;
21485 GNULIB_STDIO_H_SIGPIPE=0;
21486 GNULIB_TMPFILE=0;
21487 GNULIB_VASPRINTF=0;
21488 GNULIB_VFSCANF=0;
21489 GNULIB_VSCANF=0;
21490 GNULIB_VDPRINTF=0;
21491 GNULIB_VFPRINTF=0;
21492 GNULIB_VFPRINTF_POSIX=0;
21493 GNULIB_VPRINTF=0;
21494 GNULIB_VPRINTF_POSIX=0;
21495 GNULIB_VSNPRINTF=0;
21496 GNULIB_VSPRINTF_POSIX=0;
21497 HAVE_DECL_FPURGE=1;
21498 HAVE_DECL_FSEEKO=1;
21499 HAVE_DECL_FTELLO=1;
21500 HAVE_DECL_GETDELIM=1;
21501 HAVE_DECL_GETLINE=1;
21502 HAVE_DECL_OBSTACK_PRINTF=1;
21503 HAVE_DECL_SNPRINTF=1;
21504 HAVE_DECL_VSNPRINTF=1;
21505 HAVE_DPRINTF=1;
21506 HAVE_FSEEKO=1;
21507 HAVE_FTELLO=1;
21508 HAVE_PCLOSE=1;
21509 HAVE_POPEN=1;
21510 HAVE_RENAMEAT=1;
21511 HAVE_VASPRINTF=1;
21512 HAVE_VDPRINTF=1;
21513 REPLACE_DPRINTF=0;
21514 REPLACE_FCLOSE=0;
21515 REPLACE_FDOPEN=0;
21516 REPLACE_FFLUSH=0;
21517 REPLACE_FOPEN=0;
21518 REPLACE_FPRINTF=0;
21519 REPLACE_FPURGE=0;
21520 REPLACE_FREOPEN=0;
21521 REPLACE_FSEEK=0;
21522 REPLACE_FSEEKO=0;
21523 REPLACE_FTELL=0;
21524 REPLACE_FTELLO=0;
21525 REPLACE_GETDELIM=0;
21526 REPLACE_GETLINE=0;
21527 REPLACE_OBSTACK_PRINTF=0;
21528 REPLACE_PERROR=0;
21529 REPLACE_POPEN=0;
21530 REPLACE_PRINTF=0;
21531 REPLACE_REMOVE=0;
21532 REPLACE_RENAME=0;
21533 REPLACE_RENAMEAT=0;
21534 REPLACE_SNPRINTF=0;
21535 REPLACE_SPRINTF=0;
21536 REPLACE_STDIO_READ_FUNCS=0;
21537 REPLACE_STDIO_WRITE_FUNCS=0;
21538 REPLACE_TMPFILE=0;
21539 REPLACE_VASPRINTF=0;
21540 REPLACE_VDPRINTF=0;
21541 REPLACE_VFPRINTF=0;
21542 REPLACE_VPRINTF=0;
21543 REPLACE_VSNPRINTF=0;
21544 REPLACE_VSPRINTF=0;
21546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21547 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21548 if test "${ac_cv_struct_tm+set}" = set; then :
21549 $as_echo_n "(cached) " >&6
21550 else
21551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21552 /* end confdefs.h. */
21553 #include <sys/types.h>
21554 #include <time.h>
21557 main ()
21559 struct tm tm;
21560 int *p = &tm.tm_sec;
21561 return !p;
21563 return 0;
21565 _ACEOF
21566 if ac_fn_c_try_compile "$LINENO"; then :
21567 ac_cv_struct_tm=time.h
21568 else
21569 ac_cv_struct_tm=sys/time.h
21571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21574 $as_echo "$ac_cv_struct_tm" >&6; }
21575 if test $ac_cv_struct_tm = sys/time.h; then
21577 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21581 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21582 #include <$ac_cv_struct_tm>
21585 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21587 cat >>confdefs.h <<_ACEOF
21588 #define HAVE_STRUCT_TM_TM_ZONE 1
21589 _ACEOF
21594 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21596 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21598 else
21599 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21601 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21602 ac_have_decl=1
21603 else
21604 ac_have_decl=0
21607 cat >>confdefs.h <<_ACEOF
21608 #define HAVE_DECL_TZNAME $ac_have_decl
21609 _ACEOF
21611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21612 $as_echo_n "checking for tzname... " >&6; }
21613 if test "${ac_cv_var_tzname+set}" = set; then :
21614 $as_echo_n "(cached) " >&6
21615 else
21616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21617 /* end confdefs.h. */
21618 #include <time.h>
21619 #if !HAVE_DECL_TZNAME
21620 extern char *tzname[];
21621 #endif
21624 main ()
21626 return tzname[0][0];
21628 return 0;
21630 _ACEOF
21631 if ac_fn_c_try_link "$LINENO"; then :
21632 ac_cv_var_tzname=yes
21633 else
21634 ac_cv_var_tzname=no
21636 rm -f core conftest.err conftest.$ac_objext \
21637 conftest$ac_exeext conftest.$ac_ext
21639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21640 $as_echo "$ac_cv_var_tzname" >&6; }
21641 if test $ac_cv_var_tzname = yes; then
21643 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21649 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21651 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21653 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21669 if test $gl_cv_have_include_next = yes; then
21670 gl_cv_next_string_h='<'string.h'>'
21671 else
21672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21673 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21674 if test "${gl_cv_next_string_h+set}" = set; then :
21675 $as_echo_n "(cached) " >&6
21676 else
21678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21679 /* end confdefs.h. */
21680 #include <string.h>
21682 _ACEOF
21683 case "$host_os" in
21684 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21685 *) gl_absname_cpp="$ac_cpp" ;;
21686 esac
21688 case "$host_os" in
21689 mingw*)
21690 gl_dirsep_regex='[/\\]'
21693 gl_dirsep_regex='\/'
21695 esac
21696 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21698 gl_header_literal_regex=`echo 'string.h' \
21699 | sed -e "$gl_make_literal_regex_sed"`
21700 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21701 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21702 s|^/[^/]|//&|
21706 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21707 sed -n "$gl_absolute_header_sed"`'"'
21711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21712 $as_echo "$gl_cv_next_string_h" >&6; }
21714 NEXT_STRING_H=$gl_cv_next_string_h
21716 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21717 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21718 gl_next_as_first_directive='<'string.h'>'
21719 else
21720 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21721 gl_next_as_first_directive=$gl_cv_next_string_h
21723 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21733 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21734 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21735 ac_have_decl=1
21736 else
21737 ac_have_decl=0
21740 cat >>confdefs.h <<_ACEOF
21741 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21742 _ACEOF
21746 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21747 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21748 ac_have_decl=1
21749 else
21750 ac_have_decl=0
21753 cat >>confdefs.h <<_ACEOF
21754 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21755 _ACEOF
21759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21760 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21761 if test "${ac_cv_header_stat_broken+set}" = set; then :
21762 $as_echo_n "(cached) " >&6
21763 else
21764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21765 /* end confdefs.h. */
21766 #include <sys/types.h>
21767 #include <sys/stat.h>
21769 #if defined S_ISBLK && defined S_IFDIR
21770 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21771 #endif
21773 #if defined S_ISBLK && defined S_IFCHR
21774 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21775 #endif
21777 #if defined S_ISLNK && defined S_IFREG
21778 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21779 #endif
21781 #if defined S_ISSOCK && defined S_IFREG
21782 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21783 #endif
21785 _ACEOF
21786 if ac_fn_c_try_compile "$LINENO"; then :
21787 ac_cv_header_stat_broken=no
21788 else
21789 ac_cv_header_stat_broken=yes
21791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21794 $as_echo "$ac_cv_header_stat_broken" >&6; }
21795 if test $ac_cv_header_stat_broken = yes; then
21797 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21806 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21807 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21808 $as_echo_n "(cached) " >&6
21809 else
21810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21811 /* end confdefs.h. */
21812 #include <time.h>
21815 main ()
21817 static struct timespec x; x.tv_sec = x.tv_nsec;
21819 return 0;
21821 _ACEOF
21822 if ac_fn_c_try_compile "$LINENO"; then :
21823 gl_cv_sys_struct_timespec_in_time_h=yes
21824 else
21825 gl_cv_sys_struct_timespec_in_time_h=no
21827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21830 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21832 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21833 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21834 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21835 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21836 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21837 else
21838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21839 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21840 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21841 $as_echo_n "(cached) " >&6
21842 else
21843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21844 /* end confdefs.h. */
21845 #include <sys/time.h>
21848 main ()
21850 static struct timespec x; x.tv_sec = x.tv_nsec;
21852 return 0;
21854 _ACEOF
21855 if ac_fn_c_try_compile "$LINENO"; then :
21856 gl_cv_sys_struct_timespec_in_sys_time_h=yes
21857 else
21858 gl_cv_sys_struct_timespec_in_sys_time_h=no
21860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
21863 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
21864 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
21865 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
21866 else
21867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
21868 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
21869 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
21870 $as_echo_n "(cached) " >&6
21871 else
21872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21873 /* end confdefs.h. */
21874 #include <pthread.h>
21877 main ()
21879 static struct timespec x; x.tv_sec = x.tv_nsec;
21881 return 0;
21883 _ACEOF
21884 if ac_fn_c_try_compile "$LINENO"; then :
21885 gl_cv_sys_struct_timespec_in_pthread_h=yes
21886 else
21887 gl_cv_sys_struct_timespec_in_pthread_h=no
21889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
21892 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
21893 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
21894 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
21913 if test $gl_cv_have_include_next = yes; then
21914 gl_cv_next_time_h='<'time.h'>'
21915 else
21916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
21917 $as_echo_n "checking absolute name of <time.h>... " >&6; }
21918 if test "${gl_cv_next_time_h+set}" = set; then :
21919 $as_echo_n "(cached) " >&6
21920 else
21922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21923 /* end confdefs.h. */
21924 #include <time.h>
21926 _ACEOF
21927 case "$host_os" in
21928 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21929 *) gl_absname_cpp="$ac_cpp" ;;
21930 esac
21932 case "$host_os" in
21933 mingw*)
21934 gl_dirsep_regex='[/\\]'
21937 gl_dirsep_regex='\/'
21939 esac
21940 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21942 gl_header_literal_regex=`echo 'time.h' \
21943 | sed -e "$gl_make_literal_regex_sed"`
21944 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21945 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21946 s|^/[^/]|//&|
21950 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21951 sed -n "$gl_absolute_header_sed"`'"'
21955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
21956 $as_echo "$gl_cv_next_time_h" >&6; }
21958 NEXT_TIME_H=$gl_cv_next_time_h
21960 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21961 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21962 gl_next_as_first_directive='<'time.h'>'
21963 else
21964 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21965 gl_next_as_first_directive=$gl_cv_next_time_h
21967 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
21982 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
21983 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
21984 ac_have_decl=1
21985 else
21986 ac_have_decl=0
21989 cat >>confdefs.h <<_ACEOF
21990 #define HAVE_DECL_UNSETENV $ac_have_decl
21991 _ACEOF
21994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
21995 $as_echo_n "checking whether the utimes function works... " >&6; }
21996 if test "${gl_cv_func_working_utimes+set}" = set; then :
21997 $as_echo_n "(cached) " >&6
21998 else
22000 if test "$cross_compiling" = yes; then :
22001 gl_cv_func_working_utimes=no
22002 else
22003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22004 /* end confdefs.h. */
22006 #include <sys/types.h>
22007 #include <sys/stat.h>
22008 #include <fcntl.h>
22009 #include <sys/time.h>
22010 #include <time.h>
22011 #include <unistd.h>
22012 #include <stdlib.h>
22013 #include <stdio.h>
22014 #include <utime.h>
22016 static int
22017 inorder (time_t a, time_t b, time_t c)
22019 return a <= b && b <= c;
22023 main ()
22025 int result = 0;
22026 char const *file = "conftest.utimes";
22027 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
22029 /* Test whether utimes() essentially works. */
22031 struct stat sbuf;
22032 FILE *f = fopen (file, "w");
22033 if (f == NULL)
22034 result |= 1;
22035 else if (fclose (f) != 0)
22036 result |= 1;
22037 else if (utimes (file, timeval) != 0)
22038 result |= 2;
22039 else if (lstat (file, &sbuf) != 0)
22040 result |= 1;
22041 else if (!(sbuf.st_atime == timeval[0].tv_sec
22042 && sbuf.st_mtime == timeval[1].tv_sec))
22043 result |= 4;
22044 if (unlink (file) != 0)
22045 result |= 1;
22048 /* Test whether utimes() with a NULL argument sets the file's timestamp
22049 to the current time. Use 'fstat' as well as 'time' to
22050 determine the "current" time, to accommodate NFS file systems
22051 if there is a time skew between the host and the NFS server. */
22053 int fd = open (file, O_WRONLY|O_CREAT, 0644);
22054 if (fd < 0)
22055 result |= 1;
22056 else
22058 time_t t0, t2;
22059 struct stat st0, st1, st2;
22060 if (time (&t0) == (time_t) -1)
22061 result |= 1;
22062 else if (fstat (fd, &st0) != 0)
22063 result |= 1;
22064 else if (utimes (file, timeval) != 0)
22065 result |= 2;
22066 else if (utimes (file, NULL) != 0)
22067 result |= 8;
22068 else if (fstat (fd, &st1) != 0)
22069 result |= 1;
22070 else if (write (fd, "\n", 1) != 1)
22071 result |= 1;
22072 else if (fstat (fd, &st2) != 0)
22073 result |= 1;
22074 else if (time (&t2) == (time_t) -1)
22075 result |= 1;
22076 else
22078 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
22079 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
22080 if (! (st1.st_atime == st1.st_mtime))
22081 result |= 16;
22082 if (! (m_ok_POSIX || m_ok_NFS))
22083 result |= 32;
22085 if (close (fd) != 0)
22086 result |= 1;
22088 if (unlink (file) != 0)
22089 result |= 1;
22092 /* Test whether utimes() with a NULL argument works on read-only files. */
22094 int fd = open (file, O_WRONLY|O_CREAT, 0444);
22095 if (fd < 0)
22096 result |= 1;
22097 else if (close (fd) != 0)
22098 result |= 1;
22099 else if (utimes (file, NULL) != 0)
22100 result |= 64;
22101 if (unlink (file) != 0)
22102 result |= 1;
22105 return result;
22108 _ACEOF
22109 if ac_fn_c_try_run "$LINENO"; then :
22110 gl_cv_func_working_utimes=yes
22111 else
22112 gl_cv_func_working_utimes=no
22114 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22115 conftest.$ac_objext conftest.beam conftest.$ac_ext
22119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
22120 $as_echo "$gl_cv_func_working_utimes" >&6; }
22122 if test $gl_cv_func_working_utimes = yes; then
22124 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
22132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
22133 $as_echo_n "checking for struct utimbuf... " >&6; }
22134 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
22135 $as_echo_n "(cached) " >&6
22136 else
22137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22138 /* end confdefs.h. */
22139 #if HAVE_SYS_TIME_H
22140 #include <sys/time.h>
22141 #endif
22142 #include <time.h>
22143 #ifdef HAVE_UTIME_H
22144 #include <utime.h>
22145 #endif
22148 main ()
22150 static struct utimbuf x; x.actime = x.modtime;
22152 return 0;
22154 _ACEOF
22155 if ac_fn_c_try_compile "$LINENO"; then :
22156 gl_cv_sys_struct_utimbuf=yes
22157 else
22158 gl_cv_sys_struct_utimbuf=no
22160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
22163 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
22165 if test $gl_cv_sys_struct_utimbuf = yes; then
22167 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
22181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
22182 $as_echo_n "checking type of array argument to getgroups... " >&6; }
22183 if test "${ac_cv_type_getgroups+set}" = set; then :
22184 $as_echo_n "(cached) " >&6
22185 else
22186 if test "$cross_compiling" = yes; then :
22187 ac_cv_type_getgroups=cross
22188 else
22189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22190 /* end confdefs.h. */
22191 /* Thanks to Mike Rendell for this test. */
22192 $ac_includes_default
22193 #define NGID 256
22194 #undef MAX
22195 #define MAX(x, y) ((x) > (y) ? (x) : (y))
22198 main ()
22200 gid_t gidset[NGID];
22201 int i, n;
22202 union { gid_t gval; long int lval; } val;
22204 val.lval = -1;
22205 for (i = 0; i < NGID; i++)
22206 gidset[i] = val.gval;
22207 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
22208 gidset);
22209 /* Exit non-zero if getgroups seems to require an array of ints. This
22210 happens when gid_t is short int but getgroups modifies an array
22211 of ints. */
22212 return n > 0 && gidset[n] != val.gval;
22214 _ACEOF
22215 if ac_fn_c_try_run "$LINENO"; then :
22216 ac_cv_type_getgroups=gid_t
22217 else
22218 ac_cv_type_getgroups=int
22220 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22221 conftest.$ac_objext conftest.beam conftest.$ac_ext
22224 if test $ac_cv_type_getgroups = cross; then
22225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22226 /* end confdefs.h. */
22227 #include <unistd.h>
22229 _ACEOF
22230 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22231 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
22232 ac_cv_type_getgroups=gid_t
22233 else
22234 ac_cv_type_getgroups=int
22236 rm -f conftest*
22240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
22241 $as_echo "$ac_cv_type_getgroups" >&6; }
22243 cat >>confdefs.h <<_ACEOF
22244 #define GETGROUPS_T $ac_cv_type_getgroups
22245 _ACEOF
22254 if false; then
22255 GL_COND_LIBTOOL_TRUE=
22256 GL_COND_LIBTOOL_FALSE='#'
22257 else
22258 GL_COND_LIBTOOL_TRUE='#'
22259 GL_COND_LIBTOOL_FALSE=
22262 gl_cond_libtool=false
22263 gl_libdeps=
22264 gl_ltlibdeps=
22265 gl_m4_base='m4'
22275 gl_source_base='lib'
22278 if test $ac_cv_func_alloca_works = no; then
22282 # Define an additional variable used in the Makefile substitution.
22283 if test $ac_cv_working_alloca_h = yes; then
22284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
22285 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
22286 if test "${gl_cv_rpl_alloca+set}" = set; then :
22287 $as_echo_n "(cached) " >&6
22288 else
22290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22291 /* end confdefs.h. */
22293 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
22294 Need own alloca
22295 #endif
22297 _ACEOF
22298 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22299 $EGREP "Need own alloca" >/dev/null 2>&1; then :
22300 gl_cv_rpl_alloca=yes
22301 else
22302 gl_cv_rpl_alloca=no
22304 rm -f conftest*
22308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
22309 $as_echo "$gl_cv_rpl_alloca" >&6; }
22310 if test $gl_cv_rpl_alloca = yes; then
22312 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
22314 ALLOCA_H=alloca.h
22315 else
22316 ALLOCA_H=
22318 else
22319 ALLOCA_H=alloca.h
22322 if test -n "$ALLOCA_H"; then
22323 GL_GENERATE_ALLOCA_H_TRUE=
22324 GL_GENERATE_ALLOCA_H_FALSE='#'
22325 else
22326 GL_GENERATE_ALLOCA_H_TRUE='#'
22327 GL_GENERATE_ALLOCA_H_FALSE=
22335 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22336 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22338 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22339 # programs in the package would end up linked with that potentially-shared
22340 # library, inducing unnecessary run-time overhead.
22341 LIB_CLOCK_GETTIME=
22343 gl_saved_libs=$LIBS
22344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22345 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22346 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22347 $as_echo_n "(cached) " >&6
22348 else
22349 ac_func_search_save_LIBS=$LIBS
22350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22351 /* end confdefs.h. */
22353 /* Override any GCC internal prototype to avoid an error.
22354 Use char because int might match the return type of a GCC
22355 builtin and then its argument prototype would still apply. */
22356 #ifdef __cplusplus
22357 extern "C"
22358 #endif
22359 char clock_gettime ();
22361 main ()
22363 return clock_gettime ();
22365 return 0;
22367 _ACEOF
22368 for ac_lib in '' rt posix4; do
22369 if test -z "$ac_lib"; then
22370 ac_res="none required"
22371 else
22372 ac_res=-l$ac_lib
22373 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22375 if ac_fn_c_try_link "$LINENO"; then :
22376 ac_cv_search_clock_gettime=$ac_res
22378 rm -f core conftest.err conftest.$ac_objext \
22379 conftest$ac_exeext
22380 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22381 break
22383 done
22384 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22386 else
22387 ac_cv_search_clock_gettime=no
22389 rm conftest.$ac_ext
22390 LIBS=$ac_func_search_save_LIBS
22392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22393 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22394 ac_res=$ac_cv_search_clock_gettime
22395 if test "$ac_res" != no; then :
22396 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22397 test "$ac_cv_search_clock_gettime" = "none required" ||
22398 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22401 for ac_func in clock_gettime clock_settime
22402 do :
22403 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22404 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22405 eval as_val=\$$as_ac_var
22406 if test "x$as_val" = x""yes; then :
22407 cat >>confdefs.h <<_ACEOF
22408 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22409 _ACEOF
22412 done
22414 LIBS=$gl_saved_libs
22421 cat >>confdefs.h <<_ACEOF
22422 #define GNULIB_CLOSE_STREAM 1
22423 _ACEOF
22454 if test $gl_cv_have_include_next = yes; then
22455 gl_cv_next_dirent_h='<'dirent.h'>'
22456 else
22457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22458 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22459 if test "${gl_cv_next_dirent_h+set}" = set; then :
22460 $as_echo_n "(cached) " >&6
22461 else
22463 if test $ac_cv_header_dirent_h = yes; then
22466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22467 /* end confdefs.h. */
22468 #include <dirent.h>
22470 _ACEOF
22471 case "$host_os" in
22472 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22473 *) gl_absname_cpp="$ac_cpp" ;;
22474 esac
22476 case "$host_os" in
22477 mingw*)
22478 gl_dirsep_regex='[/\\]'
22481 gl_dirsep_regex='\/'
22483 esac
22484 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22486 gl_header_literal_regex=`echo 'dirent.h' \
22487 | sed -e "$gl_make_literal_regex_sed"`
22488 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22489 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22490 s|^/[^/]|//&|
22494 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22495 sed -n "$gl_absolute_header_sed"`'"'
22496 else
22497 gl_cv_next_dirent_h='<'dirent.h'>'
22502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22503 $as_echo "$gl_cv_next_dirent_h" >&6; }
22505 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22507 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22508 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22509 gl_next_as_first_directive='<'dirent.h'>'
22510 else
22511 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22512 gl_next_as_first_directive=$gl_cv_next_dirent_h
22514 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22519 if test $ac_cv_header_dirent_h = yes; then
22520 HAVE_DIRENT_H=1
22521 else
22522 HAVE_DIRENT_H=0
22534 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22537 if test $HAVE_DUP2 = 1; then
22538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22539 $as_echo_n "checking whether dup2 works... " >&6; }
22540 if test "${gl_cv_func_dup2_works+set}" = set; then :
22541 $as_echo_n "(cached) " >&6
22542 else
22543 if test "$cross_compiling" = yes; then :
22544 case "$host_os" in
22545 mingw*) # on this platform, dup2 always returns 0 for success
22546 gl_cv_func_dup2_works="guessing no" ;;
22547 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22548 gl_cv_func_dup2_works="guessing no" ;;
22549 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22550 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22551 gl_cv_func_dup2_works="guessing no" ;;
22552 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22553 gl_cv_func_dup2_works="guessing no" ;;
22554 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22555 gl_cv_func_dup2_works="guessing no" ;;
22556 *) gl_cv_func_dup2_works="guessing yes" ;;
22557 esac
22558 else
22559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22560 /* end confdefs.h. */
22562 #include <unistd.h>
22563 #include <fcntl.h>
22564 #include <errno.h>
22566 main ()
22568 int result = 0;
22569 #ifdef FD_CLOEXEC
22570 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22571 result |= 1;
22572 #endif
22573 if (dup2 (1, 1) == 0)
22574 result |= 2;
22575 #ifdef FD_CLOEXEC
22576 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22577 result |= 4;
22578 #endif
22579 close (0);
22580 if (dup2 (0, 0) != -1)
22581 result |= 8;
22582 /* Many gnulib modules require POSIX conformance of EBADF. */
22583 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22584 result |= 16;
22585 /* Flush out a cygwin core dump. */
22586 if (dup2 (2, -1) != -1 || errno != EBADF)
22587 result |= 32;
22588 return result;
22591 return 0;
22594 _ACEOF
22595 if ac_fn_c_try_run "$LINENO"; then :
22596 gl_cv_func_dup2_works=yes
22597 else
22598 gl_cv_func_dup2_works=no
22600 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22601 conftest.$ac_objext conftest.beam conftest.$ac_ext
22606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22607 $as_echo "$gl_cv_func_dup2_works" >&6; }
22608 case "$gl_cv_func_dup2_works" in
22609 *yes) ;;
22611 REPLACE_DUP2=1
22613 esac
22617 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22626 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22635 GNULIB_DUP2=1
22647 GNULIB_ENVIRON=1
22657 LIB_EXECINFO=''
22658 EXECINFO_H='execinfo.h'
22660 if test $ac_cv_header_execinfo_h = yes; then
22661 gl_saved_libs=$LIBS
22662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22663 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22664 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22665 $as_echo_n "(cached) " >&6
22666 else
22667 ac_func_search_save_LIBS=$LIBS
22668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22669 /* end confdefs.h. */
22671 /* Override any GCC internal prototype to avoid an error.
22672 Use char because int might match the return type of a GCC
22673 builtin and then its argument prototype would still apply. */
22674 #ifdef __cplusplus
22675 extern "C"
22676 #endif
22677 char backtrace_symbols_fd ();
22679 main ()
22681 return backtrace_symbols_fd ();
22683 return 0;
22685 _ACEOF
22686 for ac_lib in '' execinfo; do
22687 if test -z "$ac_lib"; then
22688 ac_res="none required"
22689 else
22690 ac_res=-l$ac_lib
22691 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22693 if ac_fn_c_try_link "$LINENO"; then :
22694 ac_cv_search_backtrace_symbols_fd=$ac_res
22696 rm -f core conftest.err conftest.$ac_objext \
22697 conftest$ac_exeext
22698 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22699 break
22701 done
22702 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22704 else
22705 ac_cv_search_backtrace_symbols_fd=no
22707 rm conftest.$ac_ext
22708 LIBS=$ac_func_search_save_LIBS
22710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22711 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22712 ac_res=$ac_cv_search_backtrace_symbols_fd
22713 if test "$ac_res" != no; then :
22714 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22715 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22716 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22719 LIBS=$gl_saved_libs
22720 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22723 if test -n "$EXECINFO_H"; then
22732 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22738 if test -n "$EXECINFO_H"; then
22739 GL_GENERATE_EXECINFO_H_TRUE=
22740 GL_GENERATE_EXECINFO_H_FALSE='#'
22741 else
22742 GL_GENERATE_EXECINFO_H_TRUE='#'
22743 GL_GENERATE_EXECINFO_H_FALSE=
22754 if test $ac_cv_func_faccessat = no; then
22755 HAVE_FACCESSAT=0
22758 if test $HAVE_FACCESSAT = 0; then
22767 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22770 for ac_func in access
22771 do :
22772 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22773 if test "x$ac_cv_func_access" = x""yes; then :
22774 cat >>confdefs.h <<_ACEOF
22775 #define HAVE_ACCESS 1
22776 _ACEOF
22779 done
22785 cat >>confdefs.h <<_ACEOF
22786 #define GNULIB_FACCESSAT 1
22787 _ACEOF
22795 GNULIB_FACCESSAT=1
22806 if test $ac_cv_func_fcntl = no; then
22810 if test $ac_cv_func_fcntl = no; then
22811 HAVE_FCNTL=0
22812 else
22813 REPLACE_FCNTL=1
22816 else
22817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
22818 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
22819 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
22820 $as_echo_n "(cached) " >&6
22821 else
22822 if test "$cross_compiling" = yes; then :
22823 # Guess that it works on glibc systems
22824 case $host_os in #((
22825 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
22826 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
22827 esac
22828 else
22829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22830 /* end confdefs.h. */
22832 #include <fcntl.h>
22833 #include <errno.h>
22836 main ()
22838 int result = 0;
22839 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
22840 if (errno != EINVAL) result |= 2;
22841 return result;
22844 return 0;
22846 _ACEOF
22847 if ac_fn_c_try_run "$LINENO"; then :
22848 gl_cv_func_fcntl_f_dupfd_works=yes
22849 else
22850 gl_cv_func_fcntl_f_dupfd_works=no
22852 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22853 conftest.$ac_objext conftest.beam conftest.$ac_ext
22857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
22858 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
22859 case $gl_cv_func_fcntl_f_dupfd_works in
22860 *yes) ;;
22864 if test $ac_cv_func_fcntl = no; then
22865 HAVE_FCNTL=0
22866 else
22867 REPLACE_FCNTL=1
22871 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
22873 esac
22875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
22876 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
22877 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
22878 $as_echo_n "(cached) " >&6
22879 else
22880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22881 /* end confdefs.h. */
22883 #include <fcntl.h>
22884 #ifndef F_DUPFD_CLOEXEC
22885 choke me
22886 #endif
22889 main ()
22893 return 0;
22895 _ACEOF
22896 if ac_fn_c_try_compile "$LINENO"; then :
22897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22898 /* end confdefs.h. */
22900 #ifdef __linux__
22901 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
22902 it to support the semantics on older kernels that failed with EINVAL. */
22903 choke me
22904 #endif
22907 main ()
22911 return 0;
22913 _ACEOF
22914 if ac_fn_c_try_compile "$LINENO"; then :
22915 gl_cv_func_fcntl_f_dupfd_cloexec=yes
22916 else
22917 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
22919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22920 else
22921 gl_cv_func_fcntl_f_dupfd_cloexec=no
22923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
22926 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
22927 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
22931 if test $ac_cv_func_fcntl = no; then
22932 HAVE_FCNTL=0
22933 else
22934 REPLACE_FCNTL=1
22941 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
22950 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
22958 GNULIB_FCNTL=1
22975 if test $gl_cv_have_include_next = yes; then
22976 gl_cv_next_fcntl_h='<'fcntl.h'>'
22977 else
22978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
22979 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
22980 if test "${gl_cv_next_fcntl_h+set}" = set; then :
22981 $as_echo_n "(cached) " >&6
22982 else
22984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22985 /* end confdefs.h. */
22986 #include <fcntl.h>
22988 _ACEOF
22989 case "$host_os" in
22990 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22991 *) gl_absname_cpp="$ac_cpp" ;;
22992 esac
22994 case "$host_os" in
22995 mingw*)
22996 gl_dirsep_regex='[/\\]'
22999 gl_dirsep_regex='\/'
23001 esac
23002 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23004 gl_header_literal_regex=`echo 'fcntl.h' \
23005 | sed -e "$gl_make_literal_regex_sed"`
23006 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23007 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23008 s|^/[^/]|//&|
23012 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23013 sed -n "$gl_absolute_header_sed"`'"'
23017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
23018 $as_echo "$gl_cv_next_fcntl_h" >&6; }
23020 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
23022 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23023 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23024 gl_next_as_first_directive='<'fcntl.h'>'
23025 else
23026 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23027 gl_next_as_first_directive=$gl_cv_next_fcntl_h
23029 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
23045 LIB_FDATASYNC=
23048 if test $ac_cv_have_decl_fdatasync = no; then
23049 HAVE_DECL_FDATASYNC=0
23050 for ac_func in fdatasync
23051 do :
23052 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
23053 if test "x$ac_cv_func_fdatasync" = x""yes; then :
23054 cat >>confdefs.h <<_ACEOF
23055 #define HAVE_FDATASYNC 1
23056 _ACEOF
23059 done
23061 if test $ac_cv_func_fdatasync = no; then
23062 HAVE_FDATASYNC=0
23064 else
23065 gl_saved_libs=$LIBS
23066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
23067 $as_echo_n "checking for library containing fdatasync... " >&6; }
23068 if test "${ac_cv_search_fdatasync+set}" = set; then :
23069 $as_echo_n "(cached) " >&6
23070 else
23071 ac_func_search_save_LIBS=$LIBS
23072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23073 /* end confdefs.h. */
23075 /* Override any GCC internal prototype to avoid an error.
23076 Use char because int might match the return type of a GCC
23077 builtin and then its argument prototype would still apply. */
23078 #ifdef __cplusplus
23079 extern "C"
23080 #endif
23081 char fdatasync ();
23083 main ()
23085 return fdatasync ();
23087 return 0;
23089 _ACEOF
23090 for ac_lib in '' rt posix4; do
23091 if test -z "$ac_lib"; then
23092 ac_res="none required"
23093 else
23094 ac_res=-l$ac_lib
23095 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23097 if ac_fn_c_try_link "$LINENO"; then :
23098 ac_cv_search_fdatasync=$ac_res
23100 rm -f core conftest.err conftest.$ac_objext \
23101 conftest$ac_exeext
23102 if test "${ac_cv_search_fdatasync+set}" = set; then :
23103 break
23105 done
23106 if test "${ac_cv_search_fdatasync+set}" = set; then :
23108 else
23109 ac_cv_search_fdatasync=no
23111 rm conftest.$ac_ext
23112 LIBS=$ac_func_search_save_LIBS
23114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
23115 $as_echo "$ac_cv_search_fdatasync" >&6; }
23116 ac_res=$ac_cv_search_fdatasync
23117 if test "$ac_res" != no; then :
23118 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23119 test "$ac_cv_search_fdatasync" = "none required" ||
23120 LIB_FDATASYNC=$ac_cv_search_fdatasync
23123 LIBS=$gl_saved_libs
23126 if test $HAVE_FDATASYNC = 0; then
23135 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
23143 GNULIB_FDATASYNC=1
23154 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
23155 #include <dirent.h>
23158 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
23159 ac_have_decl=1
23160 else
23161 ac_have_decl=0
23164 cat >>confdefs.h <<_ACEOF
23165 #define HAVE_DECL_FDOPENDIR $ac_have_decl
23166 _ACEOF
23167 if test $ac_have_decl = 1; then :
23169 else
23170 HAVE_DECL_FDOPENDIR=0
23174 if test $ac_cv_func_fdopendir = no; then
23175 HAVE_FDOPENDIR=0
23176 else
23177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
23178 $as_echo_n "checking whether fdopendir works... " >&6; }
23179 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
23180 $as_echo_n "(cached) " >&6
23181 else
23182 if test "$cross_compiling" = yes; then :
23183 case "$host_os" in
23184 # Guess yes on glibc systems.
23185 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
23186 # If we don't know, assume the worst.
23187 *) gl_cv_func_fdopendir_works="guessing no" ;;
23188 esac
23190 else
23191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23192 /* end confdefs.h. */
23194 #include <dirent.h>
23195 #include <fcntl.h>
23196 #include <unistd.h>
23197 #if !HAVE_DECL_FDOPENDIR
23198 extern
23199 # ifdef __cplusplus
23201 # endif
23202 DIR *fdopendir (int);
23203 #endif
23206 main ()
23208 int result = 0;
23209 int fd = open ("conftest.c", O_RDONLY);
23210 if (fd < 0) result |= 1;
23211 if (fdopendir (fd)) result |= 2;
23212 if (close (fd)) result |= 4;
23213 return result;
23215 return 0;
23217 _ACEOF
23218 if ac_fn_c_try_run "$LINENO"; then :
23219 gl_cv_func_fdopendir_works=yes
23220 else
23221 gl_cv_func_fdopendir_works=no
23223 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23224 conftest.$ac_objext conftest.beam conftest.$ac_ext
23228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
23229 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
23230 case "$gl_cv_func_fdopendir_works" in
23231 *yes) ;;
23233 REPLACE_FDOPENDIR=1
23235 esac
23238 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
23247 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
23255 GNULIB_FDOPENDIR=1
23263 cat >>confdefs.h <<_ACEOF
23264 #define GNULIB_FDOPENDIR 1
23265 _ACEOF
23274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpending" >&5
23275 $as_echo_n "checking for __fpending... " >&6; }
23276 if test "${gl_cv_func___fpending+set}" = set; then :
23277 $as_echo_n "(cached) " >&6
23278 else
23280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23281 /* end confdefs.h. */
23282 #include <stdio.h>
23283 #if HAVE_STDIO_EXT_H
23284 # include <stdio_ext.h>
23285 #endif
23288 main ()
23290 return ! __fpending (stdin);
23292 return 0;
23294 _ACEOF
23295 if ac_fn_c_try_link "$LINENO"; then :
23296 gl_cv_func___fpending=yes
23297 else
23298 gl_cv_func___fpending=no
23300 rm -f core conftest.err conftest.$ac_objext \
23301 conftest$ac_exeext conftest.$ac_ext
23304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func___fpending" >&5
23305 $as_echo "$gl_cv_func___fpending" >&6; }
23307 if test $gl_cv_func___fpending = no; then
23316 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
23319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
23320 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
23321 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
23322 $as_echo_n "(cached) " >&6
23323 else
23325 for ac_expr in \
23327 '# glibc2' \
23328 'fp->_IO_write_ptr - fp->_IO_write_base' \
23330 '# traditional Unix' \
23331 'fp->_ptr - fp->_base' \
23333 '# BSD' \
23334 'fp->_p - fp->_bf._base' \
23336 '# SCO, Unixware' \
23337 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
23339 '# QNX' \
23340 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
23342 '# old glibc?' \
23343 'fp->__bufp - fp->__buffer' \
23345 '# old glibc iostream?' \
23346 'fp->_pptr - fp->_pbase' \
23348 '# emx+gcc' \
23349 'fp->_ptr - fp->_buffer' \
23351 '# Minix' \
23352 'fp->_ptr - fp->_buf' \
23354 '# Plan9' \
23355 'fp->wp - fp->buf' \
23357 '# VMS' \
23358 '(*fp)->_ptr - (*fp)->_base' \
23360 '# e.g., DGUX R4.11; the info is not available' \
23362 ; do
23364 # Skip each embedded comment.
23365 case "$ac_expr" in '#'*) continue;; esac
23367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23368 /* end confdefs.h. */
23369 #include <stdio.h>
23371 main ()
23373 FILE *fp = stdin; (void) ($ac_expr);
23375 return 0;
23377 _ACEOF
23378 if ac_fn_c_try_compile "$LINENO"; then :
23379 fp_done=yes
23382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23383 test "$fp_done" = yes && break
23384 done
23386 ac_cv_sys_pending_output_n_bytes=$ac_expr
23390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
23391 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
23393 cat >>confdefs.h <<_ACEOF
23394 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
23395 _ACEOF
23405 if test $ac_cv_func_fstatat = no; then
23406 HAVE_FSTATAT=0
23407 else
23408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
23409 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
23410 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
23411 $as_echo_n "(cached) " >&6
23412 else
23413 if test "$cross_compiling" = yes; then :
23414 case "$host_os" in
23415 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
23416 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
23417 esac
23419 else
23420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23421 /* end confdefs.h. */
23423 #include <fcntl.h>
23424 #include <sys/stat.h>
23426 main (void)
23428 struct stat a;
23429 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23432 _ACEOF
23433 if ac_fn_c_try_run "$LINENO"; then :
23434 gl_cv_func_fstatat_zero_flag=yes
23435 else
23436 gl_cv_func_fstatat_zero_flag=no
23438 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23439 conftest.$ac_objext conftest.beam conftest.$ac_ext
23444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23445 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23447 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23448 *yes+*yes) ;;
23449 *) REPLACE_FSTATAT=1
23450 case $gl_cv_func_fstatat_zero_flag in
23451 *yes)
23453 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23456 esac
23458 esac
23461 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23470 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23478 GNULIB_FSTATAT=1
23487 if test $ac_cv_func_fsync = no; then
23488 HAVE_FSYNC=0
23491 if test $HAVE_FSYNC = 0; then
23500 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23509 GNULIB_FSYNC=1
23517 # Persuade glibc <stdlib.h> to declare getloadavg().
23520 gl_save_LIBS=$LIBS
23522 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23523 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23524 HAVE_GETLOADAVG=1
23525 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23526 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23528 else
23529 gl_func_getloadavg_done=no
23531 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23532 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23533 # to get the right answer into the cache.
23534 # For kstat on solaris, we need to test for libelf and libkvm to force the
23535 # definition of SVR4 below.
23536 if test $gl_func_getloadavg_done = no; then
23537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23538 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23539 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23540 $as_echo_n "(cached) " >&6
23541 else
23542 ac_check_lib_save_LIBS=$LIBS
23543 LIBS="-lelf $LIBS"
23544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23545 /* end confdefs.h. */
23547 /* Override any GCC internal prototype to avoid an error.
23548 Use char because int might match the return type of a GCC
23549 builtin and then its argument prototype would still apply. */
23550 #ifdef __cplusplus
23551 extern "C"
23552 #endif
23553 char elf_begin ();
23555 main ()
23557 return elf_begin ();
23559 return 0;
23561 _ACEOF
23562 if ac_fn_c_try_link "$LINENO"; then :
23563 ac_cv_lib_elf_elf_begin=yes
23564 else
23565 ac_cv_lib_elf_elf_begin=no
23567 rm -f core conftest.err conftest.$ac_objext \
23568 conftest$ac_exeext conftest.$ac_ext
23569 LIBS=$ac_check_lib_save_LIBS
23571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23572 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23573 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23574 LIBS="-lelf $LIBS"
23577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23578 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23579 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23580 $as_echo_n "(cached) " >&6
23581 else
23582 ac_check_lib_save_LIBS=$LIBS
23583 LIBS="-lkvm $LIBS"
23584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23585 /* end confdefs.h. */
23587 /* Override any GCC internal prototype to avoid an error.
23588 Use char because int might match the return type of a GCC
23589 builtin and then its argument prototype would still apply. */
23590 #ifdef __cplusplus
23591 extern "C"
23592 #endif
23593 char kvm_open ();
23595 main ()
23597 return kvm_open ();
23599 return 0;
23601 _ACEOF
23602 if ac_fn_c_try_link "$LINENO"; then :
23603 ac_cv_lib_kvm_kvm_open=yes
23604 else
23605 ac_cv_lib_kvm_kvm_open=no
23607 rm -f core conftest.err conftest.$ac_objext \
23608 conftest$ac_exeext conftest.$ac_ext
23609 LIBS=$ac_check_lib_save_LIBS
23611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23612 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23613 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23614 LIBS="-lkvm $LIBS"
23617 # Check for the 4.4BSD definition of getloadavg.
23618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23619 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23620 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23621 $as_echo_n "(cached) " >&6
23622 else
23623 ac_check_lib_save_LIBS=$LIBS
23624 LIBS="-lutil $LIBS"
23625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23626 /* end confdefs.h. */
23628 /* Override any GCC internal prototype to avoid an error.
23629 Use char because int might match the return type of a GCC
23630 builtin and then its argument prototype would still apply. */
23631 #ifdef __cplusplus
23632 extern "C"
23633 #endif
23634 char getloadavg ();
23636 main ()
23638 return getloadavg ();
23640 return 0;
23642 _ACEOF
23643 if ac_fn_c_try_link "$LINENO"; then :
23644 ac_cv_lib_util_getloadavg=yes
23645 else
23646 ac_cv_lib_util_getloadavg=no
23648 rm -f core conftest.err conftest.$ac_objext \
23649 conftest$ac_exeext conftest.$ac_ext
23650 LIBS=$ac_check_lib_save_LIBS
23652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23653 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23654 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23655 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23660 if test $gl_func_getloadavg_done = no; then
23661 # There is a commonly available library for RS/6000 AIX.
23662 # Since it is not a standard part of AIX, it might be installed locally.
23663 gl_getloadavg_LIBS=$LIBS
23664 LIBS="-L/usr/local/lib $LIBS"
23665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23666 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23667 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23668 $as_echo_n "(cached) " >&6
23669 else
23670 ac_check_lib_save_LIBS=$LIBS
23671 LIBS="-lgetloadavg $LIBS"
23672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23673 /* end confdefs.h. */
23675 /* Override any GCC internal prototype to avoid an error.
23676 Use char because int might match the return type of a GCC
23677 builtin and then its argument prototype would still apply. */
23678 #ifdef __cplusplus
23679 extern "C"
23680 #endif
23681 char getloadavg ();
23683 main ()
23685 return getloadavg ();
23687 return 0;
23689 _ACEOF
23690 if ac_fn_c_try_link "$LINENO"; then :
23691 ac_cv_lib_getloadavg_getloadavg=yes
23692 else
23693 ac_cv_lib_getloadavg_getloadavg=no
23695 rm -f core conftest.err conftest.$ac_objext \
23696 conftest$ac_exeext conftest.$ac_ext
23697 LIBS=$ac_check_lib_save_LIBS
23699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23700 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23701 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23702 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23703 else
23704 LIBS=$gl_getloadavg_LIBS
23709 # Set up the replacement function if necessary.
23710 if test $gl_func_getloadavg_done = no; then
23711 HAVE_GETLOADAVG=0
23713 # Solaris has libkstat which does not require root.
23714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23715 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23716 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23717 $as_echo_n "(cached) " >&6
23718 else
23719 ac_check_lib_save_LIBS=$LIBS
23720 LIBS="-lkstat $LIBS"
23721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23722 /* end confdefs.h. */
23724 /* Override any GCC internal prototype to avoid an error.
23725 Use char because int might match the return type of a GCC
23726 builtin and then its argument prototype would still apply. */
23727 #ifdef __cplusplus
23728 extern "C"
23729 #endif
23730 char kstat_open ();
23732 main ()
23734 return kstat_open ();
23736 return 0;
23738 _ACEOF
23739 if ac_fn_c_try_link "$LINENO"; then :
23740 ac_cv_lib_kstat_kstat_open=yes
23741 else
23742 ac_cv_lib_kstat_kstat_open=no
23744 rm -f core conftest.err conftest.$ac_objext \
23745 conftest$ac_exeext conftest.$ac_ext
23746 LIBS=$ac_check_lib_save_LIBS
23748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23749 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23750 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23751 cat >>confdefs.h <<_ACEOF
23752 #define HAVE_LIBKSTAT 1
23753 _ACEOF
23755 LIBS="-lkstat $LIBS"
23759 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23761 # AIX has libperfstat which does not require root
23762 if test $gl_func_getloadavg_done = no; then
23763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23764 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23765 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23766 $as_echo_n "(cached) " >&6
23767 else
23768 ac_check_lib_save_LIBS=$LIBS
23769 LIBS="-lperfstat $LIBS"
23770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23771 /* end confdefs.h. */
23773 /* Override any GCC internal prototype to avoid an error.
23774 Use char because int might match the return type of a GCC
23775 builtin and then its argument prototype would still apply. */
23776 #ifdef __cplusplus
23777 extern "C"
23778 #endif
23779 char perfstat_cpu_total ();
23781 main ()
23783 return perfstat_cpu_total ();
23785 return 0;
23787 _ACEOF
23788 if ac_fn_c_try_link "$LINENO"; then :
23789 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23790 else
23791 ac_cv_lib_perfstat_perfstat_cpu_total=no
23793 rm -f core conftest.err conftest.$ac_objext \
23794 conftest$ac_exeext conftest.$ac_ext
23795 LIBS=$ac_check_lib_save_LIBS
23797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
23798 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
23799 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
23800 cat >>confdefs.h <<_ACEOF
23801 #define HAVE_LIBPERFSTAT 1
23802 _ACEOF
23804 LIBS="-lperfstat $LIBS"
23808 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
23811 if test $gl_func_getloadavg_done = no; then
23812 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
23813 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
23814 gl_func_getloadavg_done=yes
23816 $as_echo "#define DGUX 1" >>confdefs.h
23818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
23819 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
23820 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
23821 $as_echo_n "(cached) " >&6
23822 else
23823 ac_check_lib_save_LIBS=$LIBS
23824 LIBS="-ldgc $LIBS"
23825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23826 /* end confdefs.h. */
23828 /* Override any GCC internal prototype to avoid an error.
23829 Use char because int might match the return type of a GCC
23830 builtin and then its argument prototype would still apply. */
23831 #ifdef __cplusplus
23832 extern "C"
23833 #endif
23834 char dg_sys_info ();
23836 main ()
23838 return dg_sys_info ();
23840 return 0;
23842 _ACEOF
23843 if ac_fn_c_try_link "$LINENO"; then :
23844 ac_cv_lib_dgc_dg_sys_info=yes
23845 else
23846 ac_cv_lib_dgc_dg_sys_info=no
23848 rm -f core conftest.err conftest.$ac_objext \
23849 conftest$ac_exeext conftest.$ac_ext
23850 LIBS=$ac_check_lib_save_LIBS
23852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
23853 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
23854 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
23855 cat >>confdefs.h <<_ACEOF
23856 #define HAVE_LIBDGC 1
23857 _ACEOF
23859 LIBS="-ldgc $LIBS"
23871 if test "x$gl_save_LIBS" = x; then
23872 GETLOADAVG_LIBS=$LIBS
23873 else
23874 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
23876 LIBS=$gl_save_LIBS
23879 # Test whether the system declares getloadavg. Solaris has the function
23880 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
23881 for ac_header in sys/loadavg.h
23882 do :
23883 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
23884 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
23885 cat >>confdefs.h <<_ACEOF
23886 #define HAVE_SYS_LOADAVG_H 1
23887 _ACEOF
23891 done
23893 if test $ac_cv_header_sys_loadavg_h = yes; then
23894 HAVE_SYS_LOADAVG_H=1
23895 else
23896 HAVE_SYS_LOADAVG_H=0
23898 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
23899 # include <sys/loadavg.h>
23900 #endif
23901 #include <stdlib.h>
23903 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
23905 else
23906 HAVE_DECL_GETLOADAVG=0
23910 if test $HAVE_GETLOADAVG = 0; then
23919 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
23922 # Figure out what our getloadavg.c needs.
23926 # On HPUX9, an unprivileged user can get load averages this way.
23927 if test $gl_func_getloadavg_done = no; then
23928 for ac_func in pstat_getdynamic
23929 do :
23930 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
23931 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
23932 cat >>confdefs.h <<_ACEOF
23933 #define HAVE_PSTAT_GETDYNAMIC 1
23934 _ACEOF
23935 gl_func_getloadavg_done=yes
23937 done
23941 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
23942 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
23943 # Irix 4.0.5F has the header but not the library.
23944 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
23945 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
23946 gl_func_getloadavg_done=yes
23948 $as_echo "#define SVR4 1" >>confdefs.h
23952 if test $gl_func_getloadavg_done = no; then
23953 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
23954 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
23955 gl_func_getloadavg_done=yes
23957 $as_echo "#define UMAX 1" >>confdefs.h
23960 $as_echo "#define UMAX4_3 1" >>confdefs.h
23967 if test $gl_func_getloadavg_done = no; then
23968 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
23969 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
23970 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
23977 if test $gl_func_getloadavg_done = no; then
23978 for ac_header in mach/mach.h
23979 do :
23980 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
23981 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
23982 cat >>confdefs.h <<_ACEOF
23983 #define HAVE_MACH_MACH_H 1
23984 _ACEOF
23988 done
23992 for ac_header in nlist.h
23993 do :
23994 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
23995 if test "x$ac_cv_header_nlist_h" = x""yes; then :
23996 cat >>confdefs.h <<_ACEOF
23997 #define HAVE_NLIST_H 1
23998 _ACEOF
23999 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
24001 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
24003 cat >>confdefs.h <<_ACEOF
24004 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
24005 _ACEOF
24010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24011 /* end confdefs.h. */
24012 #include <nlist.h>
24014 main ()
24016 struct nlist x;
24017 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
24018 x.n_un.n_name = "";
24019 #else
24020 x.n_name = "";
24021 #endif
24023 return 0;
24025 _ACEOF
24026 if ac_fn_c_try_link "$LINENO"; then :
24028 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
24031 rm -f core conftest.err conftest.$ac_objext \
24032 conftest$ac_exeext conftest.$ac_ext
24036 done
24044 GNULIB_GETLOADAVG=1
24055 if test $REPLACE_GETOPT = 1; then
24064 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24074 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24079 GNULIB_GL_UNISTD_H_GETOPT=1
24088 REPLACE_GETOPT=0
24089 if test -n "$gl_replace_getopt"; then
24090 REPLACE_GETOPT=1
24093 if test $REPLACE_GETOPT = 1; then
24095 GETOPT_H=getopt.h
24097 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
24103 if test $REPLACE_GETOPT = 1; then
24112 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24122 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24127 GNULIB_GL_UNISTD_H_GETOPT=1
24141 gl_gettimeofday_timezone=void
24142 if test $ac_cv_func_gettimeofday != yes; then
24143 HAVE_GETTIMEOFDAY=0
24144 else
24148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
24149 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
24150 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
24151 $as_echo_n "(cached) " >&6
24152 else
24153 if test "$cross_compiling" = yes; then :
24154 # When cross-compiling:
24155 case "$host_os" in
24156 # Guess all is fine on glibc systems.
24157 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
24158 # If we don't know, assume the worst.
24159 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
24160 esac
24162 else
24163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24164 /* end confdefs.h. */
24165 #include <string.h>
24166 #include <sys/time.h>
24167 #include <time.h>
24168 #include <stdlib.h>
24171 main ()
24174 time_t t = 0;
24175 struct tm *lt;
24176 struct tm saved_lt;
24177 struct timeval tv;
24178 lt = localtime (&t);
24179 saved_lt = *lt;
24180 gettimeofday (&tv, NULL);
24181 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
24184 return 0;
24186 _ACEOF
24187 if ac_fn_c_try_run "$LINENO"; then :
24188 gl_cv_func_gettimeofday_clobber=no
24189 else
24190 gl_cv_func_gettimeofday_clobber=yes
24192 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24193 conftest.$ac_objext conftest.beam conftest.$ac_ext
24197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
24198 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
24200 case "$gl_cv_func_gettimeofday_clobber" in
24201 *yes)
24202 REPLACE_GETTIMEOFDAY=1
24205 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
24208 $as_echo "#define localtime rpl_localtime" >>confdefs.h
24212 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
24215 esac
24217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
24218 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
24219 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
24220 $as_echo_n "(cached) " >&6
24221 else
24222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24223 /* end confdefs.h. */
24224 #include <sys/time.h>
24225 struct timeval c;
24226 int gettimeofday (struct timeval *restrict, void *restrict);
24229 main ()
24231 /* glibc uses struct timezone * rather than the POSIX void *
24232 if _GNU_SOURCE is defined. However, since the only portable
24233 use of gettimeofday uses NULL as the second parameter, and
24234 since the glibc definition is actually more typesafe, it is
24235 not worth wrapping this to get a compliant signature. */
24236 int (*f) (struct timeval *restrict, void *restrict)
24237 = gettimeofday;
24238 int x = f (&c, 0);
24239 return !(x | c.tv_sec | c.tv_usec);
24242 return 0;
24244 _ACEOF
24245 if ac_fn_c_try_compile "$LINENO"; then :
24246 gl_cv_func_gettimeofday_posix_signature=yes
24247 else
24248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24249 /* end confdefs.h. */
24250 #include <sys/time.h>
24251 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
24254 main ()
24258 return 0;
24260 _ACEOF
24261 if ac_fn_c_try_compile "$LINENO"; then :
24262 gl_cv_func_gettimeofday_posix_signature=almost
24263 else
24264 gl_cv_func_gettimeofday_posix_signature=no
24266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24268 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
24271 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
24272 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
24273 gl_gettimeofday_timezone='struct timezone'
24274 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
24275 REPLACE_GETTIMEOFDAY=1
24277 if test $REPLACE_STRUCT_TIMEVAL = 1; then
24278 REPLACE_GETTIMEOFDAY=1
24283 cat >>confdefs.h <<_ACEOF
24284 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
24285 _ACEOF
24288 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
24297 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
24300 for ac_header in sys/timeb.h
24301 do :
24302 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
24303 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
24304 cat >>confdefs.h <<_ACEOF
24305 #define HAVE_SYS_TIMEB_H 1
24306 _ACEOF
24310 done
24312 for ac_func in _ftime
24313 do :
24314 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
24315 if test "x$ac_cv_func__ftime" = x""yes; then :
24316 cat >>confdefs.h <<_ACEOF
24317 #define HAVE__FTIME 1
24318 _ACEOF
24321 done
24330 GNULIB_GETTIMEOFDAY=1
24341 if test $ac_cv_func_lstat = yes; then
24343 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
24344 *no)
24345 REPLACE_LSTAT=1
24347 esac
24348 else
24349 HAVE_LSTAT=0
24352 if test $REPLACE_LSTAT = 1; then
24361 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
24370 GNULIB_LSTAT=1
24381 if test $ac_cv_have_decl_memrchr = no; then
24382 HAVE_DECL_MEMRCHR=0
24385 for ac_func in memrchr
24386 do :
24387 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
24388 if test "x$ac_cv_func_memrchr" = x""yes; then :
24389 cat >>confdefs.h <<_ACEOF
24390 #define HAVE_MEMRCHR 1
24391 _ACEOF
24394 done
24397 if test $ac_cv_func_memrchr = no; then
24406 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24415 GNULIB_MEMRCHR=1
24427 if test $ac_cv_func_mkostemp != yes; then
24428 HAVE_MKOSTEMP=0
24431 if test $HAVE_MKOSTEMP = 0; then
24440 gl_LIBOBJS="$gl_LIBOBJS mkostemp.$ac_objext"
24447 cat >>confdefs.h <<_ACEOF
24448 #define GNULIB_MKOSTEMP 1
24449 _ACEOF
24457 GNULIB_MKOSTEMP=1
24469 if test $APPLE_UNIVERSAL_BUILD = 1; then
24470 # A universal build on Apple Mac OS X platforms.
24471 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24472 # But we need a configuration result that is valid in both modes.
24473 gl_cv_func_working_mktime=no
24475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24476 $as_echo_n "checking for working mktime... " >&6; }
24477 if test "${gl_cv_func_working_mktime+set}" = set; then :
24478 $as_echo_n "(cached) " >&6
24479 else
24480 if test "$cross_compiling" = yes; then :
24481 gl_cv_func_working_mktime=no
24482 else
24483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24484 /* end confdefs.h. */
24485 /* Test program from Paul Eggert and Tony Leneis. */
24486 #include <limits.h>
24487 #include <stdlib.h>
24488 #include <time.h>
24490 #ifdef HAVE_UNISTD_H
24491 # include <unistd.h>
24492 #endif
24494 #if HAVE_DECL_ALARM
24495 # include <signal.h>
24496 #endif
24498 /* Work around redefinition to rpl_putenv by other config tests. */
24499 #undef putenv
24501 static time_t time_t_max;
24502 static time_t time_t_min;
24504 /* Values we'll use to set the TZ environment variable. */
24505 static char *tz_strings[] = {
24506 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24507 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24509 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24511 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24512 Based on a problem report from Andreas Jaeger. */
24513 static int
24514 spring_forward_gap ()
24516 /* glibc (up to about 1998-10-07) failed this test. */
24517 struct tm tm;
24519 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24520 instead of "TZ=America/Vancouver" in order to detect the bug even
24521 on systems that don't support the Olson extension, or don't have the
24522 full zoneinfo tables installed. */
24523 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24525 tm.tm_year = 98;
24526 tm.tm_mon = 3;
24527 tm.tm_mday = 5;
24528 tm.tm_hour = 2;
24529 tm.tm_min = 0;
24530 tm.tm_sec = 0;
24531 tm.tm_isdst = -1;
24532 return mktime (&tm) != (time_t) -1;
24535 static int
24536 mktime_test1 (time_t now)
24538 struct tm *lt;
24539 return ! (lt = localtime (&now)) || mktime (lt) == now;
24542 static int
24543 mktime_test (time_t now)
24545 return (mktime_test1 (now)
24546 && mktime_test1 ((time_t) (time_t_max - now))
24547 && mktime_test1 ((time_t) (time_t_min + now)));
24550 static int
24551 irix_6_4_bug ()
24553 /* Based on code from Ariel Faigon. */
24554 struct tm tm;
24555 tm.tm_year = 96;
24556 tm.tm_mon = 3;
24557 tm.tm_mday = 0;
24558 tm.tm_hour = 0;
24559 tm.tm_min = 0;
24560 tm.tm_sec = 0;
24561 tm.tm_isdst = -1;
24562 mktime (&tm);
24563 return tm.tm_mon == 2 && tm.tm_mday == 31;
24566 static int
24567 bigtime_test (int j)
24569 struct tm tm;
24570 time_t now;
24571 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24572 now = mktime (&tm);
24573 if (now != (time_t) -1)
24575 struct tm *lt = localtime (&now);
24576 if (! (lt
24577 && lt->tm_year == tm.tm_year
24578 && lt->tm_mon == tm.tm_mon
24579 && lt->tm_mday == tm.tm_mday
24580 && lt->tm_hour == tm.tm_hour
24581 && lt->tm_min == tm.tm_min
24582 && lt->tm_sec == tm.tm_sec
24583 && lt->tm_yday == tm.tm_yday
24584 && lt->tm_wday == tm.tm_wday
24585 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24586 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24587 return 0;
24589 return 1;
24592 static int
24593 year_2050_test ()
24595 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24596 ignoring leap seconds. */
24597 unsigned long int answer = 2527315200UL;
24599 struct tm tm;
24600 time_t t;
24601 tm.tm_year = 2050 - 1900;
24602 tm.tm_mon = 2 - 1;
24603 tm.tm_mday = 1;
24604 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24605 tm.tm_isdst = -1;
24607 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24608 instead of "TZ=America/Vancouver" in order to detect the bug even
24609 on systems that don't support the Olson extension, or don't have the
24610 full zoneinfo tables installed. */
24611 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24613 t = mktime (&tm);
24615 /* Check that the result is either a failure, or close enough
24616 to the correct answer that we can assume the discrepancy is
24617 due to leap seconds. */
24618 return (t == (time_t) -1
24619 || (0 < t && answer - 120 <= t && t <= answer + 120));
24623 main ()
24625 int result = 0;
24626 time_t t, delta;
24627 int i, j;
24628 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24629 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24631 #if HAVE_DECL_ALARM
24632 /* This test makes some buggy mktime implementations loop.
24633 Give up after 60 seconds; a mktime slower than that
24634 isn't worth using anyway. */
24635 signal (SIGALRM, SIG_DFL);
24636 alarm (60);
24637 #endif
24639 time_t_max = (! time_t_signed
24640 ? (time_t) -1
24641 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24642 * 2 + 1));
24643 time_t_min = (! time_t_signed
24644 ? (time_t) 0
24645 : time_t_signed_magnitude
24646 ? ~ (time_t) 0
24647 : ~ time_t_max);
24649 delta = time_t_max / 997; /* a suitable prime number */
24650 for (i = 0; i < N_STRINGS; i++)
24652 if (tz_strings[i])
24653 putenv (tz_strings[i]);
24655 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24656 if (! mktime_test (t))
24657 result |= 1;
24658 if ((result & 2) == 0
24659 && ! (mktime_test ((time_t) 1)
24660 && mktime_test ((time_t) (60 * 60))
24661 && mktime_test ((time_t) (60 * 60 * 24))))
24662 result |= 2;
24664 for (j = 1; (result & 4) == 0; j <<= 1)
24666 if (! bigtime_test (j))
24667 result |= 4;
24668 if (INT_MAX / 2 < j)
24669 break;
24671 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24672 result |= 8;
24674 if (! irix_6_4_bug ())
24675 result |= 16;
24676 if (! spring_forward_gap ())
24677 result |= 32;
24678 if (! year_2050_test ())
24679 result |= 64;
24680 return result;
24682 _ACEOF
24683 if ac_fn_c_try_run "$LINENO"; then :
24684 gl_cv_func_working_mktime=yes
24685 else
24686 gl_cv_func_working_mktime=no
24688 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24689 conftest.$ac_objext conftest.beam conftest.$ac_ext
24694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24695 $as_echo "$gl_cv_func_working_mktime" >&6; }
24697 if test $gl_cv_func_working_mktime = no; then
24698 REPLACE_MKTIME=1
24699 else
24700 REPLACE_MKTIME=0
24703 if test $REPLACE_MKTIME = 1; then
24712 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24721 GNULIB_MKTIME=1
24734 if test $ac_cv_func_pipe2 != yes; then
24735 HAVE_PIPE2=0
24743 GNULIB_PIPE2=1
24754 if test $ac_cv_func_pselect = yes; then
24755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24756 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24757 if test "${gl_cv_sig_pselect+set}" = set; then :
24758 $as_echo_n "(cached) " >&6
24759 else
24760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24761 /* end confdefs.h. */
24762 #include <sys/select.h>
24765 main ()
24767 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24768 struct timespec const *restrict,
24769 sigset_t const *restrict) = pselect;
24770 return !p;
24772 return 0;
24774 _ACEOF
24775 if ac_fn_c_try_link "$LINENO"; then :
24776 gl_cv_sig_pselect=yes
24777 else
24778 gl_cv_sig_pselect=no
24780 rm -f core conftest.err conftest.$ac_objext \
24781 conftest$ac_exeext conftest.$ac_ext
24783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24784 $as_echo "$gl_cv_sig_pselect" >&6; }
24786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24787 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24788 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24789 $as_echo_n "(cached) " >&6
24790 else
24792 if test "$cross_compiling" = yes; then :
24794 case "$host_os" in
24795 # Guess yes on glibc systems.
24796 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24797 # If we don't know, assume the worst.
24798 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
24799 esac
24801 else
24802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24803 /* end confdefs.h. */
24805 #include <sys/types.h>
24806 #include <sys/time.h>
24807 #if HAVE_SYS_SELECT_H
24808 # include <sys/select.h>
24809 #endif
24810 #include <unistd.h>
24811 #include <errno.h>
24814 main ()
24817 fd_set set;
24818 dup2(0, 16);
24819 FD_ZERO(&set);
24820 FD_SET(16, &set);
24821 close(16);
24822 struct timespec timeout;
24823 timeout.tv_sec = 0;
24824 timeout.tv_nsec = 5000;
24825 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
24828 return 0;
24830 _ACEOF
24831 if ac_fn_c_try_run "$LINENO"; then :
24832 gl_cv_func_pselect_detects_ebadf=yes
24833 else
24834 gl_cv_func_pselect_detects_ebadf=no
24836 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24837 conftest.$ac_objext conftest.beam conftest.$ac_ext
24842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
24843 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
24844 case $gl_cv_func_pselect_detects_ebadf in
24845 *yes) ;;
24846 *) REPLACE_PSELECT=1 ;;
24847 esac
24850 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
24851 REPLACE_PSELECT=1
24854 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
24863 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
24871 GNULIB_PSELECT=1
24881 LIB_PTHREAD_SIGMASK=
24886 if test "$gl_threads_api" = posix; then
24887 if test $ac_cv_func_pthread_sigmask = yes; then
24889 else
24890 if test -n "$LIBMULTITHREAD"; then
24891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
24892 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
24893 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
24894 $as_echo_n "(cached) " >&6
24895 else
24896 gl_save_LIBS="$LIBS"
24897 LIBS="$LIBS $LIBMULTITHREAD"
24898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24899 /* end confdefs.h. */
24900 #include <pthread.h>
24901 #include <signal.h>
24904 main ()
24906 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
24908 return 0;
24911 _ACEOF
24912 if ac_fn_c_try_link "$LINENO"; then :
24913 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
24914 else
24915 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
24917 rm -f core conftest.err conftest.$ac_objext \
24918 conftest$ac_exeext conftest.$ac_ext
24919 LIBS="$gl_save_LIBS"
24922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
24923 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
24924 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
24925 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
24926 else
24927 HAVE_PTHREAD_SIGMASK=0
24929 else
24930 HAVE_PTHREAD_SIGMASK=0
24933 else
24934 if test $ac_cv_func_pthread_sigmask = yes; then
24935 REPLACE_PTHREAD_SIGMASK=1
24936 else
24937 HAVE_PTHREAD_SIGMASK=0
24944 if test $HAVE_PTHREAD_SIGMASK = 1; then
24947 if test -z "$LIB_PTHREAD_SIGMASK"; then
24948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
24949 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
24950 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
24951 $as_echo_n "(cached) " >&6
24952 else
24954 if test "$cross_compiling" = yes; then :
24956 case "$host_os" in
24957 freebsd* | hpux* | solaris | solaris2.[2-9]*)
24958 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
24960 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
24961 esac
24963 else
24964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24965 /* end confdefs.h. */
24967 #include <pthread.h>
24968 #include <signal.h>
24969 #include <stddef.h>
24970 int main ()
24972 sigset_t set;
24973 sigemptyset (&set);
24974 return pthread_sigmask (1729, &set, NULL) != 0;
24976 _ACEOF
24977 if ac_fn_c_try_run "$LINENO"; then :
24978 gl_cv_func_pthread_sigmask_in_libc_works=no
24979 else
24980 gl_cv_func_pthread_sigmask_in_libc_works=yes
24982 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24983 conftest.$ac_objext conftest.beam conftest.$ac_ext
24988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
24989 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
24990 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
24991 *no)
24992 REPLACE_PTHREAD_SIGMASK=1
24994 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
24997 esac
25000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
25001 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
25002 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
25003 $as_echo_n "(cached) " >&6
25004 else
25006 gl_save_LIBS="$LIBS"
25007 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
25008 if test "$cross_compiling" = yes; then :
25009 case "$host_os" in
25010 cygwin*)
25011 gl_cv_func_pthread_sigmask_return_works="guessing no";;
25013 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
25014 esac
25016 else
25017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25018 /* end confdefs.h. */
25020 #include <pthread.h>
25021 #include <signal.h>
25022 #include <stddef.h>
25023 int main ()
25025 sigset_t set;
25026 sigemptyset (&set);
25027 if (pthread_sigmask (1729, &set, NULL) == -1)
25028 return 1;
25029 return 0;
25031 _ACEOF
25032 if ac_fn_c_try_run "$LINENO"; then :
25033 gl_cv_func_pthread_sigmask_return_works=yes
25034 else
25035 gl_cv_func_pthread_sigmask_return_works=no
25037 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25038 conftest.$ac_objext conftest.beam conftest.$ac_ext
25041 LIBS="$gl_save_LIBS"
25044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
25045 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
25046 case "$gl_cv_func_pthread_sigmask_return_works" in
25047 *no)
25048 REPLACE_PTHREAD_SIGMASK=1
25050 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
25053 esac
25055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
25056 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
25057 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
25058 $as_echo_n "(cached) " >&6
25059 else
25061 case "$host_os" in
25062 irix*)
25063 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
25065 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
25066 esac
25067 gl_save_LIBS="$LIBS"
25068 LIBS="$LIBS $LIBMULTITHREAD"
25069 if test "$cross_compiling" = yes; then :
25071 else
25072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25073 /* end confdefs.h. */
25075 #include <pthread.h>
25076 #include <signal.h>
25077 #include <stdio.h>
25078 #include <stdlib.h>
25079 #include <unistd.h>
25080 static volatile int sigint_occurred;
25081 static void
25082 sigint_handler (int sig)
25084 sigint_occurred++;
25086 int main ()
25088 sigset_t set;
25089 int pid = getpid ();
25090 char command[80];
25091 signal (SIGINT, sigint_handler);
25092 sigemptyset (&set);
25093 sigaddset (&set, SIGINT);
25094 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
25095 return 1;
25096 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
25097 if (!(system (command) == 0))
25098 return 2;
25099 sleep (2);
25100 if (!(sigint_occurred == 0))
25101 return 3;
25102 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
25103 return 4;
25104 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
25105 return 5;
25106 return 0;
25108 _ACEOF
25109 if ac_fn_c_try_run "$LINENO"; then :
25111 else
25112 gl_cv_func_pthread_sigmask_unblock_works=no
25114 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25115 conftest.$ac_objext conftest.beam conftest.$ac_ext
25118 LIBS="$gl_save_LIBS"
25121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
25122 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
25123 case "$gl_cv_func_pthread_sigmask_unblock_works" in
25124 *no)
25125 REPLACE_PTHREAD_SIGMASK=1
25127 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
25130 esac
25133 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
25142 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
25145 if test $HAVE_PTHREAD_SIGMASK = 1; then
25147 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
25157 GNULIB_PTHREAD_SIGMASK=1
25165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
25166 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
25167 if test "${gl_cv_func_svid_putenv+set}" = set; then :
25168 $as_echo_n "(cached) " >&6
25169 else
25170 if test "$cross_compiling" = yes; then :
25171 case "$host_os" in
25172 # Guess yes on glibc systems.
25173 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
25174 # If we don't know, assume the worst.
25175 *) gl_cv_func_svid_putenv="guessing no" ;;
25176 esac
25178 else
25179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25180 /* end confdefs.h. */
25181 $ac_includes_default
25183 main ()
25186 /* Put it in env. */
25187 if (putenv ("CONFTEST_putenv=val"))
25188 return 1;
25190 /* Try to remove it. */
25191 if (putenv ("CONFTEST_putenv"))
25192 return 2;
25194 /* Make sure it was deleted. */
25195 if (getenv ("CONFTEST_putenv") != 0)
25196 return 3;
25198 return 0;
25201 return 0;
25203 _ACEOF
25204 if ac_fn_c_try_run "$LINENO"; then :
25205 gl_cv_func_svid_putenv=yes
25206 else
25207 gl_cv_func_svid_putenv=no
25209 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25210 conftest.$ac_objext conftest.beam conftest.$ac_ext
25215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
25216 $as_echo "$gl_cv_func_svid_putenv" >&6; }
25217 case "$gl_cv_func_svid_putenv" in
25218 *yes) ;;
25220 REPLACE_PUTENV=1
25222 esac
25224 if test $REPLACE_PUTENV = 1; then
25233 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
25236 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
25237 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
25238 ac_have_decl=1
25239 else
25240 ac_have_decl=0
25243 cat >>confdefs.h <<_ACEOF
25244 #define HAVE_DECL__PUTENV $ac_have_decl
25245 _ACEOF
25254 GNULIB_PUTENV=1
25261 # Check whether --enable-acl was given.
25262 if test "${enable_acl+set}" = set; then :
25263 enableval=$enable_acl;
25264 else
25265 enable_acl=auto
25269 LIB_ACL=
25270 use_acl=0
25271 if test "x$enable_acl" != "xno"; then
25272 for ac_header in sys/acl.h
25273 do :
25274 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
25275 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
25276 cat >>confdefs.h <<_ACEOF
25277 #define HAVE_SYS_ACL_H 1
25278 _ACEOF
25282 done
25284 if test $ac_cv_header_sys_acl_h = yes; then
25285 ac_save_LIBS=$LIBS
25287 if test $use_acl = 0; then
25288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
25289 $as_echo_n "checking for library containing acl_get_file... " >&6; }
25290 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25291 $as_echo_n "(cached) " >&6
25292 else
25293 ac_func_search_save_LIBS=$LIBS
25294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25295 /* end confdefs.h. */
25297 /* Override any GCC internal prototype to avoid an error.
25298 Use char because int might match the return type of a GCC
25299 builtin and then its argument prototype would still apply. */
25300 #ifdef __cplusplus
25301 extern "C"
25302 #endif
25303 char acl_get_file ();
25305 main ()
25307 return acl_get_file ();
25309 return 0;
25311 _ACEOF
25312 for ac_lib in '' acl pacl; do
25313 if test -z "$ac_lib"; then
25314 ac_res="none required"
25315 else
25316 ac_res=-l$ac_lib
25317 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25319 if ac_fn_c_try_link "$LINENO"; then :
25320 ac_cv_search_acl_get_file=$ac_res
25322 rm -f core conftest.err conftest.$ac_objext \
25323 conftest$ac_exeext
25324 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25325 break
25327 done
25328 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25330 else
25331 ac_cv_search_acl_get_file=no
25333 rm conftest.$ac_ext
25334 LIBS=$ac_func_search_save_LIBS
25336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
25337 $as_echo "$ac_cv_search_acl_get_file" >&6; }
25338 ac_res=$ac_cv_search_acl_get_file
25339 if test "$ac_res" != no; then :
25340 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25341 if test "$ac_cv_search_acl_get_file" != "none required"; then
25342 LIB_ACL=$ac_cv_search_acl_get_file
25344 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
25345 acl_free acl_from_mode acl_from_text \
25346 acl_delete_def_file acl_extended_file \
25347 acl_delete_fd_np acl_delete_file_np \
25348 acl_copy_ext_native acl_create_entry_np \
25349 acl_to_short_text acl_free_text
25350 do :
25351 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25352 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
25353 eval as_val=\$$as_ac_var
25354 if test "x$as_val" = x""yes; then :
25355 cat >>confdefs.h <<_ACEOF
25356 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25357 _ACEOF
25360 done
25362 # If the acl_get_file bug is detected, don't enable the ACL support.
25364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
25365 $as_echo_n "checking for working acl_get_file... " >&6; }
25366 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
25367 $as_echo_n "(cached) " >&6
25368 else
25369 if test "$cross_compiling" = yes; then :
25370 gl_cv_func_working_acl_get_file=cross-compiling
25371 else
25372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25373 /* end confdefs.h. */
25374 #include <sys/types.h>
25375 #include <sys/acl.h>
25376 #include <errno.h>
25379 main ()
25381 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25382 return 1;
25383 return 0;
25386 return 0;
25388 _ACEOF
25389 if ac_fn_c_try_run "$LINENO"; then :
25390 gl_cv_func_working_acl_get_file=yes
25391 else
25392 gl_cv_func_working_acl_get_file=no
25394 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25395 conftest.$ac_objext conftest.beam conftest.$ac_ext
25399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25400 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25402 if test $gl_cv_func_working_acl_get_file = yes; then :
25403 use_acl=1
25406 if test $use_acl = 1; then
25407 for ac_header in acl/libacl.h
25408 do :
25409 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25410 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
25411 cat >>confdefs.h <<_ACEOF
25412 #define HAVE_ACL_LIBACL_H 1
25413 _ACEOF
25417 done
25427 for ac_func in acl_entries
25428 do :
25429 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25430 if test "x$ac_cv_func_acl_entries" = x""yes; then :
25431 cat >>confdefs.h <<_ACEOF
25432 #define HAVE_ACL_ENTRIES 1
25433 _ACEOF
25435 else
25437 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25440 done
25443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25444 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25445 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
25446 $as_echo_n "(cached) " >&6
25447 else
25448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25449 /* end confdefs.h. */
25450 #include <sys/types.h>
25451 #include <sys/acl.h>
25452 int type = ACL_FIRST_ENTRY;
25454 main ()
25458 return 0;
25460 _ACEOF
25461 if ac_fn_c_try_compile "$LINENO"; then :
25462 gl_cv_acl_ACL_FIRST_ENTRY=yes
25463 else
25464 gl_cv_acl_ACL_FIRST_ENTRY=no
25466 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25469 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25470 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25472 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25476 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25477 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
25478 $as_echo_n "(cached) " >&6
25479 else
25480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25481 /* end confdefs.h. */
25482 #include <sys/types.h>
25483 #include <sys/acl.h>
25484 int type = ACL_TYPE_EXTENDED;
25486 main ()
25490 return 0;
25492 _ACEOF
25493 if ac_fn_c_try_compile "$LINENO"; then :
25494 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25495 else
25496 gl_cv_acl_ACL_TYPE_EXTENDED=no
25498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25501 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25502 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25504 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25507 else
25508 LIB_ACL=
25515 if test $use_acl = 0; then
25516 for ac_func in facl
25517 do :
25518 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25519 if test "x$ac_cv_func_facl" = x""yes; then :
25520 cat >>confdefs.h <<_ACEOF
25521 #define HAVE_FACL 1
25522 _ACEOF
25525 done
25527 if test $ac_cv_func_facl = yes; then
25528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25529 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25530 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25531 $as_echo_n "(cached) " >&6
25532 else
25533 ac_func_search_save_LIBS=$LIBS
25534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25535 /* end confdefs.h. */
25537 /* Override any GCC internal prototype to avoid an error.
25538 Use char because int might match the return type of a GCC
25539 builtin and then its argument prototype would still apply. */
25540 #ifdef __cplusplus
25541 extern "C"
25542 #endif
25543 char acl_trivial ();
25545 main ()
25547 return acl_trivial ();
25549 return 0;
25551 _ACEOF
25552 for ac_lib in '' sec; do
25553 if test -z "$ac_lib"; then
25554 ac_res="none required"
25555 else
25556 ac_res=-l$ac_lib
25557 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25559 if ac_fn_c_try_link "$LINENO"; then :
25560 ac_cv_search_acl_trivial=$ac_res
25562 rm -f core conftest.err conftest.$ac_objext \
25563 conftest$ac_exeext
25564 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25565 break
25567 done
25568 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25570 else
25571 ac_cv_search_acl_trivial=no
25573 rm conftest.$ac_ext
25574 LIBS=$ac_func_search_save_LIBS
25576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25577 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25578 ac_res=$ac_cv_search_acl_trivial
25579 if test "$ac_res" != no; then :
25580 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25581 if test "$ac_cv_search_acl_trivial" != "none required"; then
25582 LIB_ACL=$ac_cv_search_acl_trivial
25587 for ac_func in acl_trivial
25588 do :
25589 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25590 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25591 cat >>confdefs.h <<_ACEOF
25592 #define HAVE_ACL_TRIVIAL 1
25593 _ACEOF
25596 done
25598 use_acl=1
25602 if test $use_acl = 0; then
25603 for ac_func in getacl
25604 do :
25605 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25606 if test "x$ac_cv_func_getacl" = x""yes; then :
25607 cat >>confdefs.h <<_ACEOF
25608 #define HAVE_GETACL 1
25609 _ACEOF
25612 done
25614 if test $ac_cv_func_getacl = yes; then
25615 use_acl=1
25617 for ac_header in aclv.h
25618 do :
25619 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25621 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25622 cat >>confdefs.h <<_ACEOF
25623 #define HAVE_ACLV_H 1
25624 _ACEOF
25628 done
25632 if test $use_acl = 0; then
25633 for ac_func in aclx_get
25634 do :
25635 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25636 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25637 cat >>confdefs.h <<_ACEOF
25638 #define HAVE_ACLX_GET 1
25639 _ACEOF
25642 done
25644 if test $ac_cv_func_aclx_get = yes; then
25645 use_acl=1
25649 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25650 for ac_func in statacl
25651 do :
25652 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25653 if test "x$ac_cv_func_statacl" = x""yes; then :
25654 cat >>confdefs.h <<_ACEOF
25655 #define HAVE_STATACL 1
25656 _ACEOF
25659 done
25661 if test $ac_cv_func_statacl = yes; then
25662 use_acl=1
25666 if test $use_acl = 0; then
25667 for ac_func in aclsort
25668 do :
25669 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25670 if test "x$ac_cv_func_aclsort" = x""yes; then :
25671 cat >>confdefs.h <<_ACEOF
25672 #define HAVE_ACLSORT 1
25673 _ACEOF
25676 done
25678 if test $ac_cv_func_aclsort = yes; then
25679 use_acl=1
25683 LIBS=$ac_save_LIBS
25685 if test "x$enable_acl$use_acl" = "xyes0"; then
25686 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25687 elif test "x$enable_acl$use_acl" = "xauto0"; then
25688 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25689 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25690 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25691 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25696 cat >>confdefs.h <<_ACEOF
25697 #define USE_ACL $use_acl
25698 _ACEOF
25700 USE_ACL=$use_acl
25706 if test $ac_cv_func_readlink = no; then
25707 HAVE_READLINK=0
25708 else
25709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25710 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25711 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25712 $as_echo_n "(cached) " >&6
25713 else
25714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25715 /* end confdefs.h. */
25716 #include <unistd.h>
25717 /* Cause compilation failure if original declaration has wrong type. */
25718 ssize_t readlink (const char *, char *, size_t);
25720 main ()
25724 return 0;
25726 _ACEOF
25727 if ac_fn_c_try_compile "$LINENO"; then :
25728 gl_cv_decl_readlink_works=yes
25729 else
25730 gl_cv_decl_readlink_works=no
25732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25735 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25737 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25738 if test "${gl_cv_func_readlink_works+set}" = set; then :
25739 $as_echo_n "(cached) " >&6
25740 else
25741 # We have readlink, so assume ln -s works.
25742 ln -s conftest.no-such conftest.link
25743 ln -s conftest.link conftest.lnk2
25744 if test "$cross_compiling" = yes; then :
25745 case "$host_os" in
25746 # Guess yes on glibc systems.
25747 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25748 # If we don't know, assume the worst.
25749 *) gl_cv_func_readlink_works="guessing no" ;;
25750 esac
25752 else
25753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25754 /* end confdefs.h. */
25755 #include <unistd.h>
25758 main ()
25760 char buf[20];
25761 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25763 return 0;
25765 _ACEOF
25766 if ac_fn_c_try_run "$LINENO"; then :
25767 gl_cv_func_readlink_works=yes
25768 else
25769 gl_cv_func_readlink_works=no
25771 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25772 conftest.$ac_objext conftest.beam conftest.$ac_ext
25775 rm -f conftest.link conftest.lnk2
25777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25778 $as_echo "$gl_cv_func_readlink_works" >&6; }
25779 case "$gl_cv_func_readlink_works" in
25780 *yes)
25781 if test "$gl_cv_decl_readlink_works" != yes; then
25782 REPLACE_READLINK=1
25787 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25789 REPLACE_READLINK=1
25791 esac
25794 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25803 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
25814 GNULIB_READLINK=1
25824 if test $ac_cv_func_readlinkat = no; then
25825 HAVE_READLINKAT=0
25828 if test $HAVE_READLINKAT = 0; then
25837 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
25845 GNULIB_READLINKAT=1
25852 for ac_func in sig2str
25853 do :
25854 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
25855 if test "x$ac_cv_func_sig2str" = x""yes; then :
25856 cat >>confdefs.h <<_ACEOF
25857 #define HAVE_SIG2STR 1
25858 _ACEOF
25861 done
25864 if test $ac_cv_func_sig2str = no; then
25873 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
25890 if test $gl_cv_have_include_next = yes; then
25891 gl_cv_next_signal_h='<'signal.h'>'
25892 else
25893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
25894 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
25895 if test "${gl_cv_next_signal_h+set}" = set; then :
25896 $as_echo_n "(cached) " >&6
25897 else
25899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25900 /* end confdefs.h. */
25901 #include <signal.h>
25903 _ACEOF
25904 case "$host_os" in
25905 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25906 *) gl_absname_cpp="$ac_cpp" ;;
25907 esac
25909 case "$host_os" in
25910 mingw*)
25911 gl_dirsep_regex='[/\\]'
25914 gl_dirsep_regex='\/'
25916 esac
25917 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25919 gl_header_literal_regex=`echo 'signal.h' \
25920 | sed -e "$gl_make_literal_regex_sed"`
25921 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25922 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25923 s|^/[^/]|//&|
25927 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25928 sed -n "$gl_absolute_header_sed"`'"'
25932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
25933 $as_echo "$gl_cv_next_signal_h" >&6; }
25935 NEXT_SIGNAL_H=$gl_cv_next_signal_h
25937 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25938 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25939 gl_next_as_first_directive='<'signal.h'>'
25940 else
25941 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25942 gl_next_as_first_directive=$gl_cv_next_signal_h
25944 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
25950 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
25951 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
25952 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
25953 #include <signal.h>
25956 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
25958 else
25959 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
25968 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
25969 #include <signal.h>
25972 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
25974 else
25975 HAVE_SIGHANDLER_T=0
25981 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
25982 /* <sys/types.h> is not needed according to POSIX, but the
25983 <sys/socket.h> in i386-unknown-freebsd4.10 and
25984 powerpc-apple-darwin5.5 required it. */
25985 #include <sys/types.h>
25986 #if HAVE_SYS_SOCKET_H
25987 # include <sys/socket.h>
25988 #elif HAVE_WS2TCPIP_H
25989 # include <ws2tcpip.h>
25990 #endif
25993 if test "x$ac_cv_type_socklen_t" = x""yes; then :
25995 else
25996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
25997 $as_echo_n "checking for socklen_t equivalent... " >&6; }
25998 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
25999 $as_echo_n "(cached) " >&6
26000 else
26001 # Systems have either "struct sockaddr *" or
26002 # "void *" as the second argument to getpeername
26003 gl_cv_socklen_t_equiv=
26004 for arg2 in "struct sockaddr" void; do
26005 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
26006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26007 /* end confdefs.h. */
26008 #include <sys/types.h>
26009 #include <sys/socket.h>
26011 int getpeername (int, $arg2 *, $t *);
26013 main ()
26015 $t len;
26016 getpeername (0, 0, &len);
26018 return 0;
26020 _ACEOF
26021 if ac_fn_c_try_compile "$LINENO"; then :
26022 gl_cv_socklen_t_equiv="$t"
26024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26025 test "$gl_cv_socklen_t_equiv" != "" && break
26026 done
26027 test "$gl_cv_socklen_t_equiv" != "" && break
26028 done
26032 if test "$gl_cv_socklen_t_equiv" = ""; then
26033 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
26035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
26036 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
26038 cat >>confdefs.h <<_ACEOF
26039 #define socklen_t $gl_cv_socklen_t_equiv
26040 _ACEOF
26045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
26046 $as_echo_n "checking for ssize_t... " >&6; }
26047 if test "${gt_cv_ssize_t+set}" = set; then :
26048 $as_echo_n "(cached) " >&6
26049 else
26050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26051 /* end confdefs.h. */
26052 #include <sys/types.h>
26054 main ()
26056 int x = sizeof (ssize_t *) + sizeof (ssize_t);
26057 return !x;
26059 return 0;
26061 _ACEOF
26062 if ac_fn_c_try_compile "$LINENO"; then :
26063 gt_cv_ssize_t=yes
26064 else
26065 gt_cv_ssize_t=no
26067 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
26070 $as_echo "$gt_cv_ssize_t" >&6; }
26071 if test $gt_cv_ssize_t = no; then
26073 $as_echo "#define ssize_t int" >>confdefs.h
26081 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>
26082 #include <sys/stat.h>
26084 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
26086 cat >>confdefs.h <<_ACEOF
26087 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
26088 _ACEOF
26090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
26091 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
26092 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
26093 $as_echo_n "(cached) " >&6
26094 else
26095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26096 /* end confdefs.h. */
26098 #include <sys/types.h>
26099 #include <sys/stat.h>
26100 #if HAVE_SYS_TIME_H
26101 # include <sys/time.h>
26102 #endif
26103 #include <time.h>
26104 struct timespec ts;
26105 struct stat st;
26108 main ()
26111 st.st_atim = ts;
26114 return 0;
26116 _ACEOF
26117 if ac_fn_c_try_compile "$LINENO"; then :
26118 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
26119 else
26120 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
26122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
26125 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
26126 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
26128 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
26131 else
26132 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>
26133 #include <sys/stat.h>
26135 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
26137 cat >>confdefs.h <<_ACEOF
26138 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
26139 _ACEOF
26142 else
26143 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
26144 #include <sys/stat.h>
26146 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
26148 cat >>confdefs.h <<_ACEOF
26149 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
26150 _ACEOF
26153 else
26154 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>
26155 #include <sys/stat.h>
26157 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
26159 cat >>confdefs.h <<_ACEOF
26160 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
26161 _ACEOF
26176 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>
26177 #include <sys/stat.h>
26179 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
26181 cat >>confdefs.h <<_ACEOF
26182 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
26183 _ACEOF
26186 else
26187 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
26188 #include <sys/stat.h>
26190 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
26192 cat >>confdefs.h <<_ACEOF
26193 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
26194 _ACEOF
26197 else
26198 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>
26199 #include <sys/stat.h>
26201 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
26203 cat >>confdefs.h <<_ACEOF
26204 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
26205 _ACEOF
26216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
26217 $as_echo_n "checking for working stdalign.h... " >&6; }
26218 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
26219 $as_echo_n "(cached) " >&6
26220 else
26221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26222 /* end confdefs.h. */
26223 #include <stdalign.h>
26224 #include <stddef.h>
26226 /* Test that alignof yields a result consistent with offsetof.
26227 This catches GCC bug 52023
26228 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
26229 #ifdef __cplusplus
26230 template <class t> struct alignof_helper { char a; t b; };
26231 # define ao(type) offsetof (alignof_helper<type>, b)
26232 #else
26233 # define ao(type) offsetof (struct { char a; type b; }, b)
26234 #endif
26235 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
26236 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
26237 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
26239 /* Test _Alignas only on platforms where gnulib can help. */
26240 #if \
26241 ((defined __cplusplus && 201103 <= __cplusplus) \
26242 || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
26243 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
26244 struct alignas_test { char c; char alignas (8) alignas_8; };
26245 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
26246 ? 1 : -1];
26247 #endif
26250 main ()
26254 return 0;
26256 _ACEOF
26257 if ac_fn_c_try_compile "$LINENO"; then :
26258 gl_cv_header_working_stdalign_h=yes
26259 else
26260 gl_cv_header_working_stdalign_h=no
26262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
26265 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
26267 if test $gl_cv_header_working_stdalign_h = yes; then
26268 STDALIGN_H=''
26269 else
26270 STDALIGN_H='stdalign.h'
26274 if test -n "$STDALIGN_H"; then
26275 GL_GENERATE_STDALIGN_H_TRUE=
26276 GL_GENERATE_STDALIGN_H_FALSE='#'
26277 else
26278 GL_GENERATE_STDALIGN_H_TRUE='#'
26279 GL_GENERATE_STDALIGN_H_FALSE=
26284 STDARG_H=''
26285 NEXT_STDARG_H='<stdarg.h>'
26286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
26287 $as_echo_n "checking for va_copy... " >&6; }
26288 if test "${gl_cv_func_va_copy+set}" = set; then :
26289 $as_echo_n "(cached) " >&6
26290 else
26292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26293 /* end confdefs.h. */
26294 #include <stdarg.h>
26296 main ()
26299 #ifndef va_copy
26300 void (*func) (va_list, va_list) = va_copy;
26301 #endif
26304 return 0;
26306 _ACEOF
26307 if ac_fn_c_try_compile "$LINENO"; then :
26308 gl_cv_func_va_copy=yes
26309 else
26310 gl_cv_func_va_copy=no
26312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
26316 $as_echo "$gl_cv_func_va_copy" >&6; }
26317 if test $gl_cv_func_va_copy = no; then
26318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26319 /* end confdefs.h. */
26320 #if defined _AIX && !defined __GNUC__
26321 AIX vaccine
26322 #endif
26324 _ACEOF
26325 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26326 $EGREP "vaccine" >/dev/null 2>&1; then :
26327 gl_aixcc=yes
26328 else
26329 gl_aixcc=no
26331 rm -f conftest*
26333 if test $gl_aixcc = yes; then
26334 STDARG_H=stdarg.h
26343 if test $gl_cv_have_include_next = yes; then
26344 gl_cv_next_stdarg_h='<'stdarg.h'>'
26345 else
26346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
26347 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
26348 if test "${gl_cv_next_stdarg_h+set}" = set; then :
26349 $as_echo_n "(cached) " >&6
26350 else
26352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26353 /* end confdefs.h. */
26354 #include <stdarg.h>
26356 _ACEOF
26357 case "$host_os" in
26358 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26359 *) gl_absname_cpp="$ac_cpp" ;;
26360 esac
26362 case "$host_os" in
26363 mingw*)
26364 gl_dirsep_regex='[/\\]'
26367 gl_dirsep_regex='\/'
26369 esac
26370 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26372 gl_header_literal_regex=`echo 'stdarg.h' \
26373 | sed -e "$gl_make_literal_regex_sed"`
26374 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26375 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26376 s|^/[^/]|//&|
26380 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26381 sed -n "$gl_absolute_header_sed"`'"'
26385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
26386 $as_echo "$gl_cv_next_stdarg_h" >&6; }
26388 NEXT_STDARG_H=$gl_cv_next_stdarg_h
26390 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26391 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26392 gl_next_as_first_directive='<'stdarg.h'>'
26393 else
26394 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26395 gl_next_as_first_directive=$gl_cv_next_stdarg_h
26397 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
26402 if test "$gl_cv_next_stdarg_h" = '""'; then
26403 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
26404 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
26406 else
26408 saved_as_echo_n="$as_echo_n"
26409 as_echo_n=':'
26410 if test "${gl_cv_func___va_copy+set}" = set; then :
26411 $as_echo_n "(cached) " >&6
26412 else
26414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26415 /* end confdefs.h. */
26416 #include <stdarg.h>
26418 main ()
26421 #ifndef __va_copy
26422 error, bail out
26423 #endif
26426 return 0;
26428 _ACEOF
26429 if ac_fn_c_try_compile "$LINENO"; then :
26430 gl_cv_func___va_copy=yes
26431 else
26432 gl_cv_func___va_copy=no
26434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26437 as_echo_n="$saved_as_echo_n"
26439 if test $gl_cv_func___va_copy = yes; then
26441 $as_echo "#define va_copy __va_copy" >>confdefs.h
26443 else
26446 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
26452 if test -n "$STDARG_H"; then
26453 GL_GENERATE_STDARG_H_TRUE=
26454 GL_GENERATE_STDARG_H_FALSE='#'
26455 else
26456 GL_GENERATE_STDARG_H_TRUE='#'
26457 GL_GENERATE_STDARG_H_FALSE=
26465 # Define two additional variables used in the Makefile substitution.
26467 if test "$ac_cv_header_stdbool_h" = yes; then
26468 STDBOOL_H=''
26469 else
26470 STDBOOL_H='stdbool.h'
26473 if test -n "$STDBOOL_H"; then
26474 GL_GENERATE_STDBOOL_H_TRUE=
26475 GL_GENERATE_STDBOOL_H_FALSE='#'
26476 else
26477 GL_GENERATE_STDBOOL_H_TRUE='#'
26478 GL_GENERATE_STDBOOL_H_FALSE=
26482 if test "$ac_cv_type__Bool" = yes; then
26483 HAVE__BOOL=1
26484 else
26485 HAVE__BOOL=0
26492 STDDEF_H=
26493 if test $gt_cv_c_wchar_t = no; then
26494 HAVE_WCHAR_T=0
26495 STDDEF_H=stddef.h
26497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26498 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26499 if test "${gl_cv_decl_null_works+set}" = set; then :
26500 $as_echo_n "(cached) " >&6
26501 else
26502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26503 /* end confdefs.h. */
26504 #include <stddef.h>
26505 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26508 main ()
26512 return 0;
26514 _ACEOF
26515 if ac_fn_c_try_compile "$LINENO"; then :
26516 gl_cv_decl_null_works=yes
26517 else
26518 gl_cv_decl_null_works=no
26520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26523 $as_echo "$gl_cv_decl_null_works" >&6; }
26524 if test $gl_cv_decl_null_works = no; then
26525 REPLACE_NULL=1
26526 STDDEF_H=stddef.h
26529 if test -n "$STDDEF_H"; then
26530 GL_GENERATE_STDDEF_H_TRUE=
26531 GL_GENERATE_STDDEF_H_FALSE='#'
26532 else
26533 GL_GENERATE_STDDEF_H_TRUE='#'
26534 GL_GENERATE_STDDEF_H_FALSE=
26537 if test -n "$STDDEF_H"; then
26546 if test $gl_cv_have_include_next = yes; then
26547 gl_cv_next_stddef_h='<'stddef.h'>'
26548 else
26549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26550 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26551 if test "${gl_cv_next_stddef_h+set}" = set; then :
26552 $as_echo_n "(cached) " >&6
26553 else
26555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26556 /* end confdefs.h. */
26557 #include <stddef.h>
26559 _ACEOF
26560 case "$host_os" in
26561 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26562 *) gl_absname_cpp="$ac_cpp" ;;
26563 esac
26565 case "$host_os" in
26566 mingw*)
26567 gl_dirsep_regex='[/\\]'
26570 gl_dirsep_regex='\/'
26572 esac
26573 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26575 gl_header_literal_regex=`echo 'stddef.h' \
26576 | sed -e "$gl_make_literal_regex_sed"`
26577 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26578 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26579 s|^/[^/]|//&|
26583 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26584 sed -n "$gl_absolute_header_sed"`'"'
26588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26589 $as_echo "$gl_cv_next_stddef_h" >&6; }
26591 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26593 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26594 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26595 gl_next_as_first_directive='<'stddef.h'>'
26596 else
26597 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26598 gl_next_as_first_directive=$gl_cv_next_stddef_h
26600 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26618 if test $gl_cv_have_include_next = yes; then
26619 gl_cv_next_stdio_h='<'stdio.h'>'
26620 else
26621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26622 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26623 if test "${gl_cv_next_stdio_h+set}" = set; then :
26624 $as_echo_n "(cached) " >&6
26625 else
26627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26628 /* end confdefs.h. */
26629 #include <stdio.h>
26631 _ACEOF
26632 case "$host_os" in
26633 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26634 *) gl_absname_cpp="$ac_cpp" ;;
26635 esac
26637 case "$host_os" in
26638 mingw*)
26639 gl_dirsep_regex='[/\\]'
26642 gl_dirsep_regex='\/'
26644 esac
26645 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26647 gl_header_literal_regex=`echo 'stdio.h' \
26648 | sed -e "$gl_make_literal_regex_sed"`
26649 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26650 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26651 s|^/[^/]|//&|
26655 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26656 sed -n "$gl_absolute_header_sed"`'"'
26660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26661 $as_echo "$gl_cv_next_stdio_h" >&6; }
26663 NEXT_STDIO_H=$gl_cv_next_stdio_h
26665 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26666 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26667 gl_next_as_first_directive='<'stdio.h'>'
26668 else
26669 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26670 gl_next_as_first_directive=$gl_cv_next_stdio_h
26672 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26678 GNULIB_FSCANF=1
26681 cat >>confdefs.h <<_ACEOF
26682 #define GNULIB_FSCANF 1
26683 _ACEOF
26686 GNULIB_SCANF=1
26689 cat >>confdefs.h <<_ACEOF
26690 #define GNULIB_SCANF 1
26691 _ACEOF
26694 GNULIB_FGETC=1
26695 GNULIB_GETC=1
26696 GNULIB_GETCHAR=1
26697 GNULIB_FGETS=1
26698 GNULIB_FREAD=1
26701 GNULIB_FPRINTF=1
26702 GNULIB_PRINTF=1
26703 GNULIB_VFPRINTF=1
26704 GNULIB_VPRINTF=1
26705 GNULIB_FPUTC=1
26706 GNULIB_PUTC=1
26707 GNULIB_PUTCHAR=1
26708 GNULIB_FPUTS=1
26709 GNULIB_PUTS=1
26710 GNULIB_FWRITE=1
26726 if test $gl_cv_have_include_next = yes; then
26727 gl_cv_next_stdlib_h='<'stdlib.h'>'
26728 else
26729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26730 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26731 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26732 $as_echo_n "(cached) " >&6
26733 else
26735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26736 /* end confdefs.h. */
26737 #include <stdlib.h>
26739 _ACEOF
26740 case "$host_os" in
26741 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26742 *) gl_absname_cpp="$ac_cpp" ;;
26743 esac
26745 case "$host_os" in
26746 mingw*)
26747 gl_dirsep_regex='[/\\]'
26750 gl_dirsep_regex='\/'
26752 esac
26753 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26755 gl_header_literal_regex=`echo 'stdlib.h' \
26756 | sed -e "$gl_make_literal_regex_sed"`
26757 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26758 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26759 s|^/[^/]|//&|
26763 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26764 sed -n "$gl_absolute_header_sed"`'"'
26768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26769 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26771 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26773 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26774 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26775 gl_next_as_first_directive='<'stdlib.h'>'
26776 else
26777 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26778 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26780 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26790 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26798 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26810 if test "$ac_cv_have_decl_strtoimax" != yes; then
26811 HAVE_DECL_STRTOIMAX=0
26814 if test $ac_cv_func_strtoimax = yes; then
26815 HAVE_STRTOIMAX=1
26816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
26817 $as_echo_n "checking whether strtoimax works... " >&6; }
26818 if test "${gl_cv_func_strtoimax+set}" = set; then :
26819 $as_echo_n "(cached) " >&6
26820 else
26821 if test "$cross_compiling" = yes; then :
26822 case "$host_os" in
26823 # Guess no on AIX 5.
26824 aix5*) gl_cv_func_strtoimax="guessing no" ;;
26825 # Guess yes otherwise.
26826 *) gl_cv_func_strtoimax="guessing yes" ;;
26827 esac
26829 else
26830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26831 /* end confdefs.h. */
26833 #include <errno.h>
26834 #include <string.h>
26835 #include <inttypes.h>
26836 int main ()
26838 if (sizeof (intmax_t) > sizeof (int))
26840 const char *s = "4294967295";
26841 char *p;
26842 intmax_t res;
26843 errno = 0;
26844 res = strtoimax (s, &p, 10);
26845 if (p != s + strlen (s))
26846 return 1;
26847 if (errno != 0)
26848 return 2;
26849 if (res != (intmax_t) 65535 * (intmax_t) 65537)
26850 return 3;
26852 else
26854 const char *s = "2147483647";
26855 char *p;
26856 intmax_t res;
26857 errno = 0;
26858 res = strtoimax (s, &p, 10);
26859 if (p != s + strlen (s))
26860 return 1;
26861 if (errno != 0)
26862 return 2;
26863 if (res != 2147483647)
26864 return 3;
26866 return 0;
26869 _ACEOF
26870 if ac_fn_c_try_run "$LINENO"; then :
26871 gl_cv_func_strtoimax=yes
26872 else
26873 gl_cv_func_strtoimax=no
26875 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26876 conftest.$ac_objext conftest.beam conftest.$ac_ext
26881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
26882 $as_echo "$gl_cv_func_strtoimax" >&6; }
26883 case "$gl_cv_func_strtoimax" in
26884 *no) REPLACE_STRTOIMAX=1 ;;
26885 esac
26886 else
26887 HAVE_STRTOIMAX=0
26890 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
26899 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
26902 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
26903 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
26904 ac_have_decl=1
26905 else
26906 ac_have_decl=0
26909 cat >>confdefs.h <<_ACEOF
26910 #define HAVE_DECL_STRTOLL $ac_have_decl
26911 _ACEOF
26921 GNULIB_STRTOIMAX=1
26931 if test "$ac_cv_have_decl_strtoumax" != yes; then
26932 HAVE_DECL_STRTOUMAX=0
26935 if test $ac_cv_func_strtoumax = no; then
26944 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
26947 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
26948 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
26949 ac_have_decl=1
26950 else
26951 ac_have_decl=0
26954 cat >>confdefs.h <<_ACEOF
26955 #define HAVE_DECL_STRTOULL $ac_have_decl
26956 _ACEOF
26966 GNULIB_STRTOUMAX=1
26974 if test $ac_cv_func_symlink = no; then
26975 HAVE_SYMLINK=0
26976 else
26977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
26978 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
26979 if test "${gl_cv_func_symlink_works+set}" = set; then :
26980 $as_echo_n "(cached) " >&6
26981 else
26982 if test "$cross_compiling" = yes; then :
26983 case "$host_os" in
26984 # Guess yes on glibc systems.
26985 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
26986 # If we don't know, assume the worst.
26987 *) gl_cv_func_symlink_works="guessing no" ;;
26988 esac
26990 else
26991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26992 /* end confdefs.h. */
26993 #include <unistd.h>
26996 main ()
26998 int result = 0;
26999 if (!symlink ("a", "conftest.link/"))
27000 result |= 1;
27001 if (symlink ("conftest.f", "conftest.lnk2"))
27002 result |= 2;
27003 else if (!symlink ("a", "conftest.lnk2/"))
27004 result |= 4;
27005 return result;
27008 return 0;
27010 _ACEOF
27011 if ac_fn_c_try_run "$LINENO"; then :
27012 gl_cv_func_symlink_works=yes
27013 else
27014 gl_cv_func_symlink_works=no
27016 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27017 conftest.$ac_objext conftest.beam conftest.$ac_ext
27020 rm -f conftest.f conftest.link conftest.lnk2
27022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
27023 $as_echo "$gl_cv_func_symlink_works" >&6; }
27024 case "$gl_cv_func_symlink_works" in
27025 *yes) ;;
27027 REPLACE_SYMLINK=1
27029 esac
27032 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
27041 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
27049 GNULIB_SYMLINK=1
27058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
27059 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
27060 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
27061 $as_echo_n "(cached) " >&6
27062 else
27064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27065 /* end confdefs.h. */
27066 #include <sys/select.h>
27068 main ()
27070 struct timeval b;
27072 return 0;
27074 _ACEOF
27075 if ac_fn_c_try_compile "$LINENO"; then :
27076 gl_cv_header_sys_select_h_selfcontained=yes
27077 else
27078 gl_cv_header_sys_select_h_selfcontained=no
27080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27081 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
27082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27083 /* end confdefs.h. */
27084 #include <sys/select.h>
27086 main ()
27088 int memset; int bzero;
27090 return 0;
27093 _ACEOF
27094 if ac_fn_c_try_compile "$LINENO"; then :
27095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27096 /* end confdefs.h. */
27097 #include <sys/select.h>
27099 main ()
27102 #undef memset
27103 #define memset nonexistent_memset
27104 extern
27105 #ifdef __cplusplus
27107 #endif
27108 void *memset (void *, int, unsigned long);
27109 #undef bzero
27110 #define bzero nonexistent_bzero
27111 extern
27112 #ifdef __cplusplus
27114 #endif
27115 void bzero (void *, unsigned long);
27116 fd_set fds;
27117 FD_ZERO (&fds);
27120 return 0;
27123 _ACEOF
27124 if ac_fn_c_try_link "$LINENO"; then :
27126 else
27127 gl_cv_header_sys_select_h_selfcontained=no
27129 rm -f core conftest.err conftest.$ac_objext \
27130 conftest$ac_exeext conftest.$ac_ext
27133 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
27138 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
27148 if test $gl_cv_have_include_next = yes; then
27149 gl_cv_next_sys_select_h='<'sys/select.h'>'
27150 else
27151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
27152 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
27153 if test "${gl_cv_next_sys_select_h+set}" = set; then :
27154 $as_echo_n "(cached) " >&6
27155 else
27157 if test $ac_cv_header_sys_select_h = yes; then
27160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27161 /* end confdefs.h. */
27162 #include <sys/select.h>
27164 _ACEOF
27165 case "$host_os" in
27166 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27167 *) gl_absname_cpp="$ac_cpp" ;;
27168 esac
27170 case "$host_os" in
27171 mingw*)
27172 gl_dirsep_regex='[/\\]'
27175 gl_dirsep_regex='\/'
27177 esac
27178 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27180 gl_header_literal_regex=`echo 'sys/select.h' \
27181 | sed -e "$gl_make_literal_regex_sed"`
27182 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27183 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27184 s|^/[^/]|//&|
27188 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27189 sed -n "$gl_absolute_header_sed"`'"'
27190 else
27191 gl_cv_next_sys_select_h='<'sys/select.h'>'
27196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
27197 $as_echo "$gl_cv_next_sys_select_h" >&6; }
27199 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
27201 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27202 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27203 gl_next_as_first_directive='<'sys/select.h'>'
27204 else
27205 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27206 gl_next_as_first_directive=$gl_cv_next_sys_select_h
27208 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
27213 if test $ac_cv_header_sys_select_h = yes; then
27214 HAVE_SYS_SELECT_H=1
27215 else
27216 HAVE_SYS_SELECT_H=0
27223 if test $ac_cv_header_sys_socket_h != yes; then
27224 for ac_header in winsock2.h
27225 do :
27226 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
27227 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
27228 cat >>confdefs.h <<_ACEOF
27229 #define HAVE_WINSOCK2_H 1
27230 _ACEOF
27234 done
27237 if test "$ac_cv_header_winsock2_h" = yes; then
27238 HAVE_WINSOCK2_H=1
27239 UNISTD_H_HAVE_WINSOCK2_H=1
27240 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
27241 else
27242 HAVE_WINSOCK2_H=0
27264 if test $gl_cv_have_include_next = yes; then
27265 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27266 else
27267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
27268 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
27269 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
27270 $as_echo_n "(cached) " >&6
27271 else
27273 if test $ac_cv_header_sys_stat_h = yes; then
27276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27277 /* end confdefs.h. */
27278 #include <sys/stat.h>
27280 _ACEOF
27281 case "$host_os" in
27282 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27283 *) gl_absname_cpp="$ac_cpp" ;;
27284 esac
27286 case "$host_os" in
27287 mingw*)
27288 gl_dirsep_regex='[/\\]'
27291 gl_dirsep_regex='\/'
27293 esac
27294 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27296 gl_header_literal_regex=`echo 'sys/stat.h' \
27297 | sed -e "$gl_make_literal_regex_sed"`
27298 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27299 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27300 s|^/[^/]|//&|
27304 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27305 sed -n "$gl_absolute_header_sed"`'"'
27306 else
27307 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
27313 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
27315 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
27317 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27318 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27319 gl_next_as_first_directive='<'sys/stat.h'>'
27320 else
27321 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27322 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
27324 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
27336 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
27338 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
27342 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
27343 #include <sys/stat.h>
27345 if test "x$ac_cv_type_nlink_t" = x""yes; then :
27347 else
27349 $as_echo "#define nlink_t int" >>confdefs.h
27370 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
27372 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
27373 ac_have_decl=1
27374 else
27375 ac_have_decl=0
27378 cat >>confdefs.h <<_ACEOF
27379 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
27380 _ACEOF
27382 if test $ac_cv_have_decl_localtime_r = no; then
27383 HAVE_DECL_LOCALTIME_R=0
27387 if test $ac_cv_func_localtime_r = yes; then
27388 HAVE_LOCALTIME_R=1
27389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
27390 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
27391 if test "${gl_cv_time_r_posix+set}" = set; then :
27392 $as_echo_n "(cached) " >&6
27393 else
27394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27395 /* end confdefs.h. */
27396 #include <time.h>
27398 main ()
27400 /* We don't need to append 'restrict's to the argument types,
27401 even though the POSIX signature has the 'restrict's,
27402 since C99 says they can't affect type compatibility. */
27403 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
27404 if (ptr) return 0;
27405 /* Check the return type is a pointer.
27406 On HP-UX 10 it is 'int'. */
27407 *localtime_r (0, 0);
27409 return 0;
27412 _ACEOF
27413 if ac_fn_c_try_compile "$LINENO"; then :
27414 gl_cv_time_r_posix=yes
27415 else
27416 gl_cv_time_r_posix=no
27418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
27422 $as_echo "$gl_cv_time_r_posix" >&6; }
27423 if test $gl_cv_time_r_posix = yes; then
27424 REPLACE_LOCALTIME_R=0
27425 else
27426 REPLACE_LOCALTIME_R=1
27428 else
27429 HAVE_LOCALTIME_R=0
27432 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
27441 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
27452 GNULIB_TIME_R=1
27463 LIB_TIMER_TIME=
27465 gl_saved_libs=$LIBS
27466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
27467 $as_echo_n "checking for library containing timer_settime... " >&6; }
27468 if test "${ac_cv_search_timer_settime+set}" = set; then :
27469 $as_echo_n "(cached) " >&6
27470 else
27471 ac_func_search_save_LIBS=$LIBS
27472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27473 /* end confdefs.h. */
27475 /* Override any GCC internal prototype to avoid an error.
27476 Use char because int might match the return type of a GCC
27477 builtin and then its argument prototype would still apply. */
27478 #ifdef __cplusplus
27479 extern "C"
27480 #endif
27481 char timer_settime ();
27483 main ()
27485 return timer_settime ();
27487 return 0;
27489 _ACEOF
27490 for ac_lib in '' rt posix4; do
27491 if test -z "$ac_lib"; then
27492 ac_res="none required"
27493 else
27494 ac_res=-l$ac_lib
27495 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27497 if ac_fn_c_try_link "$LINENO"; then :
27498 ac_cv_search_timer_settime=$ac_res
27500 rm -f core conftest.err conftest.$ac_objext \
27501 conftest$ac_exeext
27502 if test "${ac_cv_search_timer_settime+set}" = set; then :
27503 break
27505 done
27506 if test "${ac_cv_search_timer_settime+set}" = set; then :
27508 else
27509 ac_cv_search_timer_settime=no
27511 rm conftest.$ac_ext
27512 LIBS=$ac_func_search_save_LIBS
27514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27515 $as_echo "$ac_cv_search_timer_settime" >&6; }
27516 ac_res=$ac_cv_search_timer_settime
27517 if test "$ac_res" != no; then :
27518 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27519 test "$ac_cv_search_timer_settime" = "none required" ||
27520 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27524 /* end confdefs.h. */
27526 #include <features.h>
27527 #ifdef __GNU_LIBRARY__
27528 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27529 && !defined __UCLIBC__
27530 Thread emulation available
27531 #endif
27532 #endif
27534 _ACEOF
27535 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27536 $EGREP "Thread" >/dev/null 2>&1; then :
27537 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27539 rm -f conftest*
27541 for ac_func in timer_settime
27542 do :
27543 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27544 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27545 cat >>confdefs.h <<_ACEOF
27546 #define HAVE_TIMER_SETTIME 1
27547 _ACEOF
27550 done
27552 LIBS=$gl_saved_libs
27567 if test $gl_cv_have_include_next = yes; then
27568 gl_cv_next_unistd_h='<'unistd.h'>'
27569 else
27570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27571 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27572 if test "${gl_cv_next_unistd_h+set}" = set; then :
27573 $as_echo_n "(cached) " >&6
27574 else
27576 if test $ac_cv_header_unistd_h = yes; then
27579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27580 /* end confdefs.h. */
27581 #include <unistd.h>
27583 _ACEOF
27584 case "$host_os" in
27585 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27586 *) gl_absname_cpp="$ac_cpp" ;;
27587 esac
27589 case "$host_os" in
27590 mingw*)
27591 gl_dirsep_regex='[/\\]'
27594 gl_dirsep_regex='\/'
27596 esac
27597 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27599 gl_header_literal_regex=`echo 'unistd.h' \
27600 | sed -e "$gl_make_literal_regex_sed"`
27601 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27602 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27603 s|^/[^/]|//&|
27607 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27608 sed -n "$gl_absolute_header_sed"`'"'
27609 else
27610 gl_cv_next_unistd_h='<'unistd.h'>'
27615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27616 $as_echo "$gl_cv_next_unistd_h" >&6; }
27618 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27620 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27621 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27622 gl_next_as_first_directive='<'unistd.h'>'
27623 else
27624 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27625 gl_next_as_first_directive=$gl_cv_next_unistd_h
27627 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27632 if test $ac_cv_header_unistd_h = yes; then
27633 HAVE_UNISTD_H=1
27634 else
27635 HAVE_UNISTD_H=0
27648 if test $ac_cv_have_decl_unsetenv = no; then
27649 HAVE_DECL_UNSETENV=0
27651 for ac_func in unsetenv
27652 do :
27653 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27654 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27655 cat >>confdefs.h <<_ACEOF
27656 #define HAVE_UNSETENV 1
27657 _ACEOF
27660 done
27662 if test $ac_cv_func_unsetenv = no; then
27663 HAVE_UNSETENV=0
27664 else
27665 HAVE_UNSETENV=1
27666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27667 $as_echo_n "checking for unsetenv() return type... " >&6; }
27668 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27669 $as_echo_n "(cached) " >&6
27670 else
27671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27672 /* end confdefs.h. */
27674 #undef _BSD
27675 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27676 #include <stdlib.h>
27677 extern
27678 #ifdef __cplusplus
27680 #endif
27681 int unsetenv (const char *name);
27684 main ()
27688 return 0;
27690 _ACEOF
27691 if ac_fn_c_try_compile "$LINENO"; then :
27692 gt_cv_func_unsetenv_ret='int'
27693 else
27694 gt_cv_func_unsetenv_ret='void'
27696 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27699 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27700 if test $gt_cv_func_unsetenv_ret = 'void'; then
27702 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27704 REPLACE_UNSETENV=1
27707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27708 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27709 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27710 $as_echo_n "(cached) " >&6
27711 else
27712 if test "$cross_compiling" = yes; then :
27713 case "$host_os" in
27714 # Guess yes on glibc systems.
27715 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27716 # If we don't know, assume the worst.
27717 *) gl_cv_func_unsetenv_works="guessing no" ;;
27718 esac
27720 else
27721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27722 /* end confdefs.h. */
27724 #include <stdlib.h>
27725 #include <errno.h>
27726 extern char **environ;
27729 main ()
27732 char entry1[] = "a=1";
27733 char entry2[] = "b=2";
27734 char *env[] = { entry1, entry2, NULL };
27735 if (putenv ((char *) "a=1")) return 1;
27736 if (putenv (entry2)) return 2;
27737 entry2[0] = 'a';
27738 unsetenv ("a");
27739 if (getenv ("a")) return 3;
27740 if (!unsetenv ("") || errno != EINVAL) return 4;
27741 entry2[0] = 'b';
27742 environ = env;
27743 if (!getenv ("a")) return 5;
27744 entry2[0] = 'a';
27745 unsetenv ("a");
27746 if (getenv ("a")) return 6;
27749 return 0;
27751 _ACEOF
27752 if ac_fn_c_try_run "$LINENO"; then :
27753 gl_cv_func_unsetenv_works=yes
27754 else
27755 gl_cv_func_unsetenv_works=no
27757 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27758 conftest.$ac_objext conftest.beam conftest.$ac_ext
27762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27763 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27764 case "$gl_cv_func_unsetenv_works" in
27765 *yes) ;;
27767 REPLACE_UNSETENV=1
27769 esac
27772 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27781 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27793 GNULIB_UNSETENV=1
27805 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
27806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
27807 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
27808 if test "${gl_cv_func_futimesat_works+set}" = set; then :
27809 $as_echo_n "(cached) " >&6
27810 else
27811 touch conftest.file
27812 if test "$cross_compiling" = yes; then :
27813 case "$host_os" in
27814 # Guess yes on glibc systems.
27815 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
27816 # If we don't know, assume the worst.
27817 *) gl_cv_func_futimesat_works="guessing no" ;;
27818 esac
27820 else
27821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27822 /* end confdefs.h. */
27824 #include <stddef.h>
27825 #include <sys/times.h>
27826 #include <fcntl.h>
27829 main ()
27831 int fd = open ("conftest.file", O_RDWR);
27832 if (fd < 0) return 1;
27833 if (futimesat (fd, NULL, NULL)) return 2;
27836 return 0;
27838 _ACEOF
27839 if ac_fn_c_try_run "$LINENO"; then :
27840 gl_cv_func_futimesat_works=yes
27841 else
27842 gl_cv_func_futimesat_works=no
27844 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27845 conftest.$ac_objext conftest.beam conftest.$ac_ext
27848 rm -f conftest.file
27850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
27851 $as_echo "$gl_cv_func_futimesat_works" >&6; }
27852 case "$gl_cv_func_futimesat_works" in
27853 *yes) ;;
27856 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
27859 esac
27862 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
27863 gl_gnulib_enabled_dosname=false
27864 gl_gnulib_enabled_euidaccess=false
27865 gl_gnulib_enabled_getdtablesize=false
27866 gl_gnulib_enabled_getgroups=false
27867 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
27868 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
27869 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
27870 gl_gnulib_enabled_pathmax=false
27871 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
27872 gl_gnulib_enabled_secure_getenv=false
27873 gl_gnulib_enabled_stat=false
27874 gl_gnulib_enabled_strtoll=false
27875 gl_gnulib_enabled_strtoull=false
27876 gl_gnulib_enabled_tempname=false
27877 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
27878 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
27880 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
27889 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
27891 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
27894 func_gl_gnulib_m4code_dosname ()
27896 if ! $gl_gnulib_enabled_dosname; then
27897 gl_gnulib_enabled_dosname=true
27900 func_gl_gnulib_m4code_euidaccess ()
27902 if ! $gl_gnulib_enabled_euidaccess; then
27908 for ac_func in euidaccess
27909 do :
27910 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
27911 if test "x$ac_cv_func_euidaccess" = x""yes; then :
27912 cat >>confdefs.h <<_ACEOF
27913 #define HAVE_EUIDACCESS 1
27914 _ACEOF
27917 done
27919 if test $ac_cv_func_euidaccess = no; then
27920 HAVE_EUIDACCESS=0
27923 if test $HAVE_EUIDACCESS = 0; then
27932 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
27936 for ac_header in libgen.h
27937 do :
27938 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
27939 if test "x$ac_cv_header_libgen_h" = x""yes; then :
27940 cat >>confdefs.h <<_ACEOF
27941 #define HAVE_LIBGEN_H 1
27942 _ACEOF
27946 done
27949 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27950 if test "x$ac_cv_func_getgroups" = x""yes; then :
27955 # If we don't yet have getgroups, see if it's in -lbsd.
27956 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27957 ac_save_LIBS=$LIBS
27958 if test $ac_cv_func_getgroups = no; then
27959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27960 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27961 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27962 $as_echo_n "(cached) " >&6
27963 else
27964 ac_check_lib_save_LIBS=$LIBS
27965 LIBS="-lbsd $LIBS"
27966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27967 /* end confdefs.h. */
27969 /* Override any GCC internal prototype to avoid an error.
27970 Use char because int might match the return type of a GCC
27971 builtin and then its argument prototype would still apply. */
27972 #ifdef __cplusplus
27973 extern "C"
27974 #endif
27975 char getgroups ();
27977 main ()
27979 return getgroups ();
27981 return 0;
27983 _ACEOF
27984 if ac_fn_c_try_link "$LINENO"; then :
27985 ac_cv_lib_bsd_getgroups=yes
27986 else
27987 ac_cv_lib_bsd_getgroups=no
27989 rm -f core conftest.err conftest.$ac_objext \
27990 conftest$ac_exeext conftest.$ac_ext
27991 LIBS=$ac_check_lib_save_LIBS
27993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27994 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27995 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27996 GETGROUPS_LIB=-lbsd
28001 # Run the program to test the functionality of the system-supplied
28002 # getgroups function only if there is such a function.
28003 if test $ac_cv_func_getgroups = yes; then
28004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28005 $as_echo_n "checking for working getgroups... " >&6; }
28006 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28007 $as_echo_n "(cached) " >&6
28008 else
28009 if test "$cross_compiling" = yes; then :
28010 case "$host_os" in # ((
28011 # Guess yes on glibc systems.
28012 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28013 # If we don't know, assume the worst.
28014 *) ac_cv_func_getgroups_works="guessing no" ;;
28015 esac
28017 else
28018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28019 /* end confdefs.h. */
28020 $ac_includes_default
28022 main ()
28024 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28025 return getgroups (0, 0) == -1;
28027 return 0;
28030 _ACEOF
28031 if ac_fn_c_try_run "$LINENO"; then :
28032 ac_cv_func_getgroups_works=yes
28033 else
28034 ac_cv_func_getgroups_works=no
28036 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28037 conftest.$ac_objext conftest.beam conftest.$ac_ext
28042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28043 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28044 else
28045 ac_cv_func_getgroups_works=no
28047 case "$ac_cv_func_getgroups_works" in
28048 *yes)
28050 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28053 esac
28054 LIBS=$ac_save_LIBS
28057 # Solaris 9 and 10 need -lgen to get the eaccess function.
28058 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
28059 # programs in the package would end up linked with that potentially-shared
28060 # library, inducing unnecessary run-time overhead.
28061 LIB_EACCESS=
28063 gl_saved_libs=$LIBS
28064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
28065 $as_echo_n "checking for library containing eaccess... " >&6; }
28066 if test "${ac_cv_search_eaccess+set}" = set; then :
28067 $as_echo_n "(cached) " >&6
28068 else
28069 ac_func_search_save_LIBS=$LIBS
28070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28071 /* end confdefs.h. */
28073 /* Override any GCC internal prototype to avoid an error.
28074 Use char because int might match the return type of a GCC
28075 builtin and then its argument prototype would still apply. */
28076 #ifdef __cplusplus
28077 extern "C"
28078 #endif
28079 char eaccess ();
28081 main ()
28083 return eaccess ();
28085 return 0;
28087 _ACEOF
28088 for ac_lib in '' gen; do
28089 if test -z "$ac_lib"; then
28090 ac_res="none required"
28091 else
28092 ac_res=-l$ac_lib
28093 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
28095 if ac_fn_c_try_link "$LINENO"; then :
28096 ac_cv_search_eaccess=$ac_res
28098 rm -f core conftest.err conftest.$ac_objext \
28099 conftest$ac_exeext
28100 if test "${ac_cv_search_eaccess+set}" = set; then :
28101 break
28103 done
28104 if test "${ac_cv_search_eaccess+set}" = set; then :
28106 else
28107 ac_cv_search_eaccess=no
28109 rm conftest.$ac_ext
28110 LIBS=$ac_func_search_save_LIBS
28112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
28113 $as_echo "$ac_cv_search_eaccess" >&6; }
28114 ac_res=$ac_cv_search_eaccess
28115 if test "$ac_res" != no; then :
28116 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28117 test "$ac_cv_search_eaccess" = "none required" ||
28118 LIB_EACCESS=$ac_cv_search_eaccess
28121 for ac_func in eaccess
28122 do :
28123 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
28124 if test "x$ac_cv_func_eaccess" = x""yes; then :
28125 cat >>confdefs.h <<_ACEOF
28126 #define HAVE_EACCESS 1
28127 _ACEOF
28130 done
28132 LIBS=$gl_saved_libs
28140 GNULIB_EUIDACCESS=1
28146 gl_gnulib_enabled_euidaccess=true
28147 if test $HAVE_EUIDACCESS = 0; then
28148 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
28150 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
28151 if test $HAVE_EUIDACCESS = 0; then
28152 func_gl_gnulib_m4code_stat
28156 func_gl_gnulib_m4code_getdtablesize ()
28158 if ! $gl_gnulib_enabled_getdtablesize; then
28162 if test $ac_cv_func_getdtablesize != yes; then
28163 HAVE_GETDTABLESIZE=0
28166 if test $HAVE_GETDTABLESIZE = 0; then
28175 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
28184 GNULIB_GETDTABLESIZE=1
28190 gl_gnulib_enabled_getdtablesize=true
28193 func_gl_gnulib_m4code_getgroups ()
28195 if ! $gl_gnulib_enabled_getgroups; then
28201 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28202 if test "x$ac_cv_func_getgroups" = x""yes; then :
28207 # If we don't yet have getgroups, see if it's in -lbsd.
28208 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28209 ac_save_LIBS=$LIBS
28210 if test $ac_cv_func_getgroups = no; then
28211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28212 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28213 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28214 $as_echo_n "(cached) " >&6
28215 else
28216 ac_check_lib_save_LIBS=$LIBS
28217 LIBS="-lbsd $LIBS"
28218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28219 /* end confdefs.h. */
28221 /* Override any GCC internal prototype to avoid an error.
28222 Use char because int might match the return type of a GCC
28223 builtin and then its argument prototype would still apply. */
28224 #ifdef __cplusplus
28225 extern "C"
28226 #endif
28227 char getgroups ();
28229 main ()
28231 return getgroups ();
28233 return 0;
28235 _ACEOF
28236 if ac_fn_c_try_link "$LINENO"; then :
28237 ac_cv_lib_bsd_getgroups=yes
28238 else
28239 ac_cv_lib_bsd_getgroups=no
28241 rm -f core conftest.err conftest.$ac_objext \
28242 conftest$ac_exeext conftest.$ac_ext
28243 LIBS=$ac_check_lib_save_LIBS
28245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28246 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28247 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28248 GETGROUPS_LIB=-lbsd
28253 # Run the program to test the functionality of the system-supplied
28254 # getgroups function only if there is such a function.
28255 if test $ac_cv_func_getgroups = yes; then
28256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28257 $as_echo_n "checking for working getgroups... " >&6; }
28258 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28259 $as_echo_n "(cached) " >&6
28260 else
28261 if test "$cross_compiling" = yes; then :
28262 case "$host_os" in # ((
28263 # Guess yes on glibc systems.
28264 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28265 # If we don't know, assume the worst.
28266 *) ac_cv_func_getgroups_works="guessing no" ;;
28267 esac
28269 else
28270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28271 /* end confdefs.h. */
28272 $ac_includes_default
28274 main ()
28276 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28277 return getgroups (0, 0) == -1;
28279 return 0;
28282 _ACEOF
28283 if ac_fn_c_try_run "$LINENO"; then :
28284 ac_cv_func_getgroups_works=yes
28285 else
28286 ac_cv_func_getgroups_works=no
28288 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28289 conftest.$ac_objext conftest.beam conftest.$ac_ext
28294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28295 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28296 else
28297 ac_cv_func_getgroups_works=no
28299 case "$ac_cv_func_getgroups_works" in
28300 *yes)
28302 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28305 esac
28306 LIBS=$ac_save_LIBS
28308 if test $ac_cv_func_getgroups != yes; then
28309 HAVE_GETGROUPS=0
28310 else
28311 if test "$ac_cv_type_getgroups" != gid_t \
28312 || { case "$ac_cv_func_getgroups_works" in
28313 *yes) false;;
28314 *) true;;
28315 esac
28316 }; then
28317 REPLACE_GETGROUPS=1
28319 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
28321 else
28322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
28323 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
28324 if test "${gl_cv_func_getgroups_works+set}" = set; then :
28325 $as_echo_n "(cached) " >&6
28326 else
28327 if test "$cross_compiling" = yes; then :
28328 case "$host_os" in
28329 # Guess yes on glibc systems.
28330 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
28331 # If we don't know, assume the worst.
28332 *) gl_cv_func_getgroups_works="guessing no" ;;
28333 esac
28335 else
28336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28337 /* end confdefs.h. */
28338 $ac_includes_default
28340 main ()
28342 int size = getgroups (0, 0);
28343 gid_t *list = malloc (size * sizeof *list);
28344 return getgroups (-1, list) != -1;
28346 return 0;
28348 _ACEOF
28349 if ac_fn_c_try_run "$LINENO"; then :
28350 gl_cv_func_getgroups_works=yes
28351 else
28352 gl_cv_func_getgroups_works=no
28354 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28355 conftest.$ac_objext conftest.beam conftest.$ac_ext
28359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
28360 $as_echo "$gl_cv_func_getgroups_works" >&6; }
28361 case "$gl_cv_func_getgroups_works" in
28362 *yes) ;;
28363 *) REPLACE_GETGROUPS=1 ;;
28364 esac
28367 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
28369 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
28378 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
28386 GNULIB_GETGROUPS=1
28392 gl_gnulib_enabled_getgroups=true
28395 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
28397 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28400 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
28403 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
28405 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28411 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
28412 if test "x$ac_cv_func_group_member" = x""yes; then :
28414 else
28416 HAVE_GROUP_MEMBER=0
28421 if test $HAVE_GROUP_MEMBER = 0; then
28430 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
28441 GNULIB_GROUP_MEMBER=1
28447 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
28448 if test $HAVE_GROUP_MEMBER = 0; then
28449 func_gl_gnulib_m4code_getgroups
28451 if test $HAVE_GROUP_MEMBER = 0; then
28452 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
28456 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
28458 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28459 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
28462 func_gl_gnulib_m4code_pathmax ()
28464 if ! $gl_gnulib_enabled_pathmax; then
28468 gl_gnulib_enabled_pathmax=true
28471 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
28473 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28474 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
28477 func_gl_gnulib_m4code_secure_getenv ()
28479 if ! $gl_gnulib_enabled_secure_getenv; then
28485 if test $ac_cv_func_secure_getenv = no; then
28486 HAVE_SECURE_GETENV=0
28489 if test $HAVE_SECURE_GETENV = 0; then
28498 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
28501 for ac_func in __secure_getenv
28502 do :
28503 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
28504 if test "x$ac_cv_func___secure_getenv" = x""yes; then :
28505 cat >>confdefs.h <<_ACEOF
28506 #define HAVE___SECURE_GETENV 1
28507 _ACEOF
28510 done
28512 if test $ac_cv_func___secure_getenv = no; then
28513 for ac_func in issetugid
28514 do :
28515 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
28516 if test "x$ac_cv_func_issetugid" = x""yes; then :
28517 cat >>confdefs.h <<_ACEOF
28518 #define HAVE_ISSETUGID 1
28519 _ACEOF
28522 done
28532 GNULIB_SECURE_GETENV=1
28538 gl_gnulib_enabled_secure_getenv=true
28541 func_gl_gnulib_m4code_stat ()
28543 if ! $gl_gnulib_enabled_stat; then
28547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
28548 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
28549 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
28550 $as_echo_n "(cached) " >&6
28551 else
28552 if test "$cross_compiling" = yes; then :
28553 case $host_os in
28554 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
28555 *) gl_cv_func_stat_dir_slash="guessing yes";;
28556 esac
28557 else
28558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28559 /* end confdefs.h. */
28560 #include <sys/stat.h>
28563 main ()
28565 struct stat st; return stat (".", &st) != stat ("./", &st);
28567 return 0;
28569 _ACEOF
28570 if ac_fn_c_try_run "$LINENO"; then :
28571 gl_cv_func_stat_dir_slash=yes
28572 else
28573 gl_cv_func_stat_dir_slash=no
28575 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28576 conftest.$ac_objext conftest.beam conftest.$ac_ext
28580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
28581 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
28582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28583 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28584 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
28585 $as_echo_n "(cached) " >&6
28586 else
28587 touch conftest.tmp
28588 # Assume that if we have lstat, we can also check symlinks.
28589 if test $ac_cv_func_lstat = yes; then
28590 ln -s conftest.tmp conftest.lnk
28592 if test "$cross_compiling" = yes; then :
28593 case "$host_os" in
28594 # Guess yes on glibc systems.
28595 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28596 # If we don't know, assume the worst.
28597 *) gl_cv_func_stat_file_slash="guessing no" ;;
28598 esac
28600 else
28601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28602 /* end confdefs.h. */
28603 #include <sys/stat.h>
28606 main ()
28608 int result = 0;
28609 struct stat st;
28610 if (!stat ("conftest.tmp/", &st))
28611 result |= 1;
28612 #if HAVE_LSTAT
28613 if (!stat ("conftest.lnk/", &st))
28614 result |= 2;
28615 #endif
28616 return result;
28619 return 0;
28621 _ACEOF
28622 if ac_fn_c_try_run "$LINENO"; then :
28623 gl_cv_func_stat_file_slash=yes
28624 else
28625 gl_cv_func_stat_file_slash=no
28627 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28628 conftest.$ac_objext conftest.beam conftest.$ac_ext
28631 rm -f conftest.tmp conftest.lnk
28633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28634 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28635 case $gl_cv_func_stat_dir_slash in
28636 *no) REPLACE_STAT=1
28638 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28640 esac
28641 case $gl_cv_func_stat_file_slash in
28642 *no) REPLACE_STAT=1
28644 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28646 esac
28648 if test $REPLACE_STAT = 1; then
28657 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28666 GNULIB_STAT=1
28672 gl_gnulib_enabled_stat=true
28673 if test $REPLACE_STAT = 1; then
28674 func_gl_gnulib_m4code_dosname
28676 if test $REPLACE_STAT = 1; then
28677 func_gl_gnulib_m4code_pathmax
28681 func_gl_gnulib_m4code_strtoll ()
28683 if ! $gl_gnulib_enabled_strtoll; then
28687 if test "$ac_cv_type_long_long_int" = yes; then
28688 for ac_func in strtoll
28689 do :
28690 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28691 if test "x$ac_cv_func_strtoll" = x""yes; then :
28692 cat >>confdefs.h <<_ACEOF
28693 #define HAVE_STRTOLL 1
28694 _ACEOF
28697 done
28699 if test $ac_cv_func_strtoll = no; then
28700 HAVE_STRTOLL=0
28704 if test $HAVE_STRTOLL = 0; then
28713 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28724 GNULIB_STRTOLL=1
28730 gl_gnulib_enabled_strtoll=true
28733 func_gl_gnulib_m4code_strtoull ()
28735 if ! $gl_gnulib_enabled_strtoull; then
28739 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28740 for ac_func in strtoull
28741 do :
28742 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
28743 if test "x$ac_cv_func_strtoull" = x""yes; then :
28744 cat >>confdefs.h <<_ACEOF
28745 #define HAVE_STRTOULL 1
28746 _ACEOF
28749 done
28751 if test $ac_cv_func_strtoull = no; then
28752 HAVE_STRTOULL=0
28756 if test $HAVE_STRTOULL = 0; then
28765 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
28776 GNULIB_STRTOULL=1
28782 gl_gnulib_enabled_strtoull=true
28785 func_gl_gnulib_m4code_tempname ()
28787 if ! $gl_gnulib_enabled_tempname; then
28793 gl_gnulib_enabled_tempname=true
28794 func_gl_gnulib_m4code_secure_getenv
28797 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
28799 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28800 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
28803 if test $HAVE_FACCESSAT = 0; then
28804 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28806 if test $HAVE_FACCESSAT = 0; then
28807 func_gl_gnulib_m4code_dosname
28809 if test $HAVE_FACCESSAT = 0; then
28810 func_gl_gnulib_m4code_euidaccess
28812 if test $HAVE_FACCESSAT = 0; then
28813 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28815 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
28816 func_gl_gnulib_m4code_getdtablesize
28818 if test $HAVE_FDOPENDIR = 0; then
28819 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28821 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28822 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28824 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28825 func_gl_gnulib_m4code_dosname
28827 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28828 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28830 if test $REPLACE_GETOPT = 1; then
28831 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
28833 if test $REPLACE_LSTAT = 1; then
28834 func_gl_gnulib_m4code_dosname
28836 if test $REPLACE_LSTAT = 1; then
28837 func_gl_gnulib_m4code_stat
28839 if test $HAVE_MKOSTEMP = 0; then
28840 func_gl_gnulib_m4code_tempname
28842 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
28843 func_gl_gnulib_m4code_stat
28845 if test $HAVE_READLINKAT = 0; then
28846 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28848 if test $HAVE_READLINKAT = 0; then
28849 func_gl_gnulib_m4code_dosname
28851 if test $HAVE_READLINKAT = 0; then
28852 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28854 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
28855 func_gl_gnulib_m4code_strtoll
28857 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
28858 func_gl_gnulib_m4code_strtoull
28861 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28862 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
28863 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
28864 else
28865 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
28866 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
28869 if $gl_gnulib_enabled_dosname; then
28870 gl_GNULIB_ENABLED_dosname_TRUE=
28871 gl_GNULIB_ENABLED_dosname_FALSE='#'
28872 else
28873 gl_GNULIB_ENABLED_dosname_TRUE='#'
28874 gl_GNULIB_ENABLED_dosname_FALSE=
28877 if $gl_gnulib_enabled_euidaccess; then
28878 gl_GNULIB_ENABLED_euidaccess_TRUE=
28879 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
28880 else
28881 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
28882 gl_GNULIB_ENABLED_euidaccess_FALSE=
28885 if $gl_gnulib_enabled_getdtablesize; then
28886 gl_GNULIB_ENABLED_getdtablesize_TRUE=
28887 gl_GNULIB_ENABLED_getdtablesize_FALSE='#'
28888 else
28889 gl_GNULIB_ENABLED_getdtablesize_TRUE='#'
28890 gl_GNULIB_ENABLED_getdtablesize_FALSE=
28893 if $gl_gnulib_enabled_getgroups; then
28894 gl_GNULIB_ENABLED_getgroups_TRUE=
28895 gl_GNULIB_ENABLED_getgroups_FALSE='#'
28896 else
28897 gl_GNULIB_ENABLED_getgroups_TRUE='#'
28898 gl_GNULIB_ENABLED_getgroups_FALSE=
28901 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28902 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
28903 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
28904 else
28905 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
28906 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
28909 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28910 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
28911 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
28912 else
28913 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
28914 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
28917 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28918 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
28919 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
28920 else
28921 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
28922 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
28925 if $gl_gnulib_enabled_pathmax; then
28926 gl_GNULIB_ENABLED_pathmax_TRUE=
28927 gl_GNULIB_ENABLED_pathmax_FALSE='#'
28928 else
28929 gl_GNULIB_ENABLED_pathmax_TRUE='#'
28930 gl_GNULIB_ENABLED_pathmax_FALSE=
28933 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28934 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
28935 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
28936 else
28937 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
28938 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
28941 if $gl_gnulib_enabled_secure_getenv; then
28942 gl_GNULIB_ENABLED_secure_getenv_TRUE=
28943 gl_GNULIB_ENABLED_secure_getenv_FALSE='#'
28944 else
28945 gl_GNULIB_ENABLED_secure_getenv_TRUE='#'
28946 gl_GNULIB_ENABLED_secure_getenv_FALSE=
28949 if $gl_gnulib_enabled_stat; then
28950 gl_GNULIB_ENABLED_stat_TRUE=
28951 gl_GNULIB_ENABLED_stat_FALSE='#'
28952 else
28953 gl_GNULIB_ENABLED_stat_TRUE='#'
28954 gl_GNULIB_ENABLED_stat_FALSE=
28957 if $gl_gnulib_enabled_strtoll; then
28958 gl_GNULIB_ENABLED_strtoll_TRUE=
28959 gl_GNULIB_ENABLED_strtoll_FALSE='#'
28960 else
28961 gl_GNULIB_ENABLED_strtoll_TRUE='#'
28962 gl_GNULIB_ENABLED_strtoll_FALSE=
28965 if $gl_gnulib_enabled_strtoull; then
28966 gl_GNULIB_ENABLED_strtoull_TRUE=
28967 gl_GNULIB_ENABLED_strtoull_FALSE='#'
28968 else
28969 gl_GNULIB_ENABLED_strtoull_TRUE='#'
28970 gl_GNULIB_ENABLED_strtoull_FALSE=
28973 if $gl_gnulib_enabled_tempname; then
28974 gl_GNULIB_ENABLED_tempname_TRUE=
28975 gl_GNULIB_ENABLED_tempname_FALSE='#'
28976 else
28977 gl_GNULIB_ENABLED_tempname_TRUE='#'
28978 gl_GNULIB_ENABLED_tempname_FALSE=
28981 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28982 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
28983 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
28984 else
28985 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
28986 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
28989 # End of code from modules
28999 gltests_libdeps=
29000 gltests_ltlibdeps=
29010 gl_source_base='tests'
29011 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
29013 gl_module_indicator_condition=$gltests_WITNESS
29024 LIBGNU_LIBDEPS="$gl_libdeps"
29026 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
29029 CFLAGS=$SAVE_CFLAGS
29030 LIBS=$SAVE_LIBS
29032 if test "${opsys}" = "mingw32"; then
29033 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
29034 # Remove unneeded switches from the value of CC that goes to Makefiles
29035 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
29038 case "$opsys" in
29039 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
29041 darwin)
29042 ## The -headerpad option tells ld (see man page) to leave room at the
29043 ## end of the header for adding load commands. Needed for dumping.
29044 ## 0x690 is the total size of 30 segment load commands (at 56
29045 ## each); under Cocoa 31 commands are required.
29046 if test "$HAVE_NS" = "yes"; then
29047 libs_nsgui="-framework AppKit"
29048 if test "$NS_IMPL_COCOA" = "yes"; then
29049 libs_nsgui="$libs_nsgui -framework IOKit"
29051 headerpad_extra=6C8
29052 else
29053 libs_nsgui=
29054 headerpad_extra=690
29056 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
29058 ## This is here because src/Makefile.in did some extra fiddling around
29059 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
29060 ## LD_SWITCH_SYSTEM_TEMACS instead,
29061 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
29062 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
29065 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
29066 ## find X at run-time.
29067 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
29068 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
29069 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
29070 ## had different values in configure (in ac_link) and src/Makefile.in.
29071 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
29072 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
29074 mingw32)
29075 ## MinGW64 does not prepend an underscore to symbols, so we must
29076 ## pass a different -entry switch to linker. FIXME: It is better
29077 ## to make the entry points the same by changing unexw32.c.
29078 case "$canonical" in
29079 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
29080 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
29081 esac
29084 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
29086 *) LD_SWITCH_SYSTEM_TEMACS= ;;
29087 esac
29089 if test x$ac_enable_profiling != x ; then
29090 case $opsys in
29091 *freebsd | gnu-linux) ;;
29092 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
29093 esac
29096 LD_SWITCH_SYSTEM_TEMACS="$LDFLAGS_NOCOMBRELOC $LD_SWITCH_SYSTEM_TEMACS"
29100 ## MinGW-specific post-link processing of temacs.
29101 TEMACS_POST_LINK=":"
29102 ADDSECTION=
29103 EMACS_HEAPSIZE=
29104 if test "${opsys}" = "mingw32"; then
29105 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
29106 ADDSECTION="../nt/addsection\$(EXEEXT)"
29107 ## Preload heap size of temacs.exe in MB.
29108 case "$canonical" in
29109 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
29110 *) EMACS_HEAPSIZE=27 ;;
29111 esac
29118 ## Common for all window systems
29119 if test "$window_system" != "none"; then
29121 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
29123 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
29130 #### Report on what we decided to do.
29131 #### Report GTK as a toolkit, even if it doesn't use Xt.
29132 #### It makes printing result more understandable as using GTK sets
29133 #### toolkit_scroll_bars to yes by default.
29134 if test "${HAVE_GTK}" = "yes"; then
29135 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
29138 if test $USE_ACL -ne 0; then
29139 acl_summary="yes $LIB_ACL"
29140 else
29141 acl_summary=no
29144 echo "
29145 Configured for \`${canonical}'.
29147 Where should the build process find the source code? ${srcdir}
29148 What compiler should emacs be built with? ${CC} ${CFLAGS}
29149 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
29150 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
29151 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
29152 What window system should Emacs use? ${window_system}
29153 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
29155 if test -n "${x_includes}"; then
29156 echo " Where do we find X Windows header files? ${x_includes}"
29157 else
29158 echo " Where do we find X Windows header files? Standard dirs"
29160 if test -n "${x_libraries}"; then
29161 echo " Where do we find X Windows libraries? ${x_libraries}"
29162 else
29163 echo " Where do we find X Windows libraries? Standard dirs"
29166 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
29167 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
29168 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
29169 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
29170 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
29171 echo " Does Emacs use -lpng? ${HAVE_PNG}"
29172 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
29173 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
29175 echo " Does Emacs support sound? ${HAVE_SOUND}"
29177 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
29178 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
29179 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
29180 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
29181 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
29182 echo " Does Emacs use access control lists? ${acl_summary}"
29183 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
29184 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
29185 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
29187 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
29188 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
29189 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
29190 echo " Does Emacs use -lxft? ${HAVE_XFT}"
29191 echo " Does Emacs directly use zlib? ${HAVE_ZLIB}"
29193 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
29194 echo
29196 if test -n "${EMACSDATA}"; then
29197 echo " Environment variable EMACSDATA set to: $EMACSDATA"
29199 if test -n "${EMACSDOC}"; then
29200 echo " Environment variable EMACSDOC set to: $EMACSDOC"
29203 echo
29205 if test "$HAVE_NS" = "yes"; then
29206 echo
29207 echo "You must run \"${MAKE-make} install\" in order to test the built application.
29208 The installed application will go to nextstep/Emacs.app and can be
29209 run or moved from there."
29210 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
29211 echo "The application will be fully self-contained."
29212 else
29213 echo "The lisp resources for the application will be installed under ${prefix}.
29214 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
29215 to run if these resources are not installed."
29217 echo
29220 if test "${opsys}" = "cygwin"; then
29221 case `uname -r` in
29222 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
29223 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
29224 echo
29226 esac
29229 # Remove any trailing slashes in these variables.
29230 test "${prefix}" != NONE &&
29231 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
29232 test "${exec_prefix}" != NONE &&
29233 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
29235 if test "$HAVE_NS" = "yes"; then
29236 if test "$NS_IMPL_GNUSTEP" = yes; then
29237 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"
29239 ns_check_file=Resources/Info-gnustep.plist
29240 else
29241 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"
29243 ns_check_file=Contents/Info.plist
29248 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"
29250 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"
29253 opt_makefile=test/automated/Makefile
29255 if test -f "$srcdir/$opt_makefile.in"; then
29256 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29257 ac_config_files="$ac_config_files test/automated/Makefile"
29262 opt_makefile=admin/unidata/Makefile
29264 if test -f "$srcdir/$opt_makefile.in"; then
29265 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29266 ac_config_files="$ac_config_files admin/unidata/Makefile"
29271 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
29275 ac_config_commands="$ac_config_commands src/epaths.h"
29278 ac_config_commands="$ac_config_commands src/.gdbinit"
29281 cat >confcache <<\_ACEOF
29282 # This file is a shell script that caches the results of configure
29283 # tests run on this system so they can be shared between configure
29284 # scripts and configure runs, see configure's option --config-cache.
29285 # It is not useful on other systems. If it contains results you don't
29286 # want to keep, you may remove or edit it.
29288 # config.status only pays attention to the cache file if you give it
29289 # the --recheck option to rerun configure.
29291 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29292 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29293 # following values.
29295 _ACEOF
29297 # The following way of writing the cache mishandles newlines in values,
29298 # but we know of no workaround that is simple, portable, and efficient.
29299 # So, we kill variables containing newlines.
29300 # Ultrix sh set writes to stderr and can't be redirected directly,
29301 # and sets the high bit in the cache file unless we assign to the vars.
29303 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29304 eval ac_val=\$$ac_var
29305 case $ac_val in #(
29306 *${as_nl}*)
29307 case $ac_var in #(
29308 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
29309 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29310 esac
29311 case $ac_var in #(
29312 _ | IFS | as_nl) ;; #(
29313 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29314 *) { eval $ac_var=; unset $ac_var;} ;;
29315 esac ;;
29316 esac
29317 done
29319 (set) 2>&1 |
29320 case $as_nl`(ac_space=' '; set) 2>&1` in #(
29321 *${as_nl}ac_space=\ *)
29322 # `set' does not quote correctly, so add quotes: double-quote
29323 # substitution turns \\\\ into \\, and sed turns \\ into \.
29324 sed -n \
29325 "s/'/'\\\\''/g;
29326 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29327 ;; #(
29329 # `set' quotes correctly as required by POSIX, so do not add quotes.
29330 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29332 esac |
29333 sort
29335 sed '
29336 /^ac_cv_env_/b end
29337 t clear
29338 :clear
29339 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29340 t end
29341 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29342 :end' >>confcache
29343 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29344 if test -w "$cache_file"; then
29345 test "x$cache_file" != "x/dev/null" &&
29346 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
29347 $as_echo "$as_me: updating cache $cache_file" >&6;}
29348 cat confcache >$cache_file
29349 else
29350 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
29351 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29354 rm -f confcache
29356 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29357 # Let make expand exec_prefix.
29358 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29360 DEFS=-DHAVE_CONFIG_H
29362 ac_libobjs=
29363 ac_ltlibobjs=
29364 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29365 # 1. Remove the extension, and $U if already installed.
29366 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29367 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29368 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
29369 # will be set to the directory where LIBOBJS objects are built.
29370 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29371 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
29372 done
29373 LIBOBJS=$ac_libobjs
29375 LTLIBOBJS=$ac_ltlibobjs
29378 if test -n "$EXEEXT"; then
29379 am__EXEEXT_TRUE=
29380 am__EXEEXT_FALSE='#'
29381 else
29382 am__EXEEXT_TRUE='#'
29383 am__EXEEXT_FALSE=
29386 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
29387 as_fn_error "conditional \"AMDEP\" was never defined.
29388 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29390 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
29391 as_fn_error "conditional \"am__fastdepCC\" was never defined.
29392 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29394 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
29395 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
29396 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29398 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
29399 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
29400 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29402 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
29403 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
29404 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29407 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
29408 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
29409 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29411 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
29412 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
29413 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29415 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
29416 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
29417 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29419 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
29420 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
29421 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29423 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
29424 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
29425 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29427 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
29428 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
29429 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29431 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
29432 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
29433 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29435 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
29436 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
29437 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29439 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
29440 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
29441 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29443 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
29444 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
29445 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29447 if test -z "${gl_GNULIB_ENABLED_getdtablesize_TRUE}" && test -z "${gl_GNULIB_ENABLED_getdtablesize_FALSE}"; then
29448 as_fn_error "conditional \"gl_GNULIB_ENABLED_getdtablesize\" was never defined.
29449 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29451 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
29452 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
29453 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29455 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
29456 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
29457 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29459 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
29460 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
29461 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29463 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
29464 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
29465 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29467 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
29468 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
29469 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29471 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
29472 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
29473 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29475 if test -z "${gl_GNULIB_ENABLED_secure_getenv_TRUE}" && test -z "${gl_GNULIB_ENABLED_secure_getenv_FALSE}"; then
29476 as_fn_error "conditional \"gl_GNULIB_ENABLED_secure_getenv\" was never defined.
29477 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29479 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
29480 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
29481 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29483 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
29484 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
29485 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29487 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
29488 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
29489 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29491 if test -z "${gl_GNULIB_ENABLED_tempname_TRUE}" && test -z "${gl_GNULIB_ENABLED_tempname_FALSE}"; then
29492 as_fn_error "conditional \"gl_GNULIB_ENABLED_tempname\" was never defined.
29493 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29495 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
29496 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
29497 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29500 gl_libobjs=
29501 gl_ltlibobjs=
29502 if test -n "$gl_LIBOBJS"; then
29503 # Remove the extension.
29504 sed_drop_objext='s/\.o$//;s/\.obj$//'
29505 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29506 gl_libobjs="$gl_libobjs $i.$ac_objext"
29507 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
29508 done
29510 gl_LIBOBJS=$gl_libobjs
29512 gl_LTLIBOBJS=$gl_ltlibobjs
29516 gltests_libobjs=
29517 gltests_ltlibobjs=
29518 if test -n "$gltests_LIBOBJS"; then
29519 # Remove the extension.
29520 sed_drop_objext='s/\.o$//;s/\.obj$//'
29521 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29522 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
29523 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
29524 done
29526 gltests_LIBOBJS=$gltests_libobjs
29528 gltests_LTLIBOBJS=$gltests_ltlibobjs
29532 : ${CONFIG_STATUS=./config.status}
29533 ac_write_fail=0
29534 ac_clean_files_save=$ac_clean_files
29535 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29536 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29537 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29538 as_write_fail=0
29539 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29540 #! $SHELL
29541 # Generated by $as_me.
29542 # Run this file to recreate the current configuration.
29543 # Compiler output produced by configure, useful for debugging
29544 # configure, is in config.log if it exists.
29546 debug=false
29547 ac_cs_recheck=false
29548 ac_cs_silent=false
29550 SHELL=\${CONFIG_SHELL-$SHELL}
29551 export SHELL
29552 _ASEOF
29553 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29554 ## -------------------- ##
29555 ## M4sh Initialization. ##
29556 ## -------------------- ##
29558 # Be more Bourne compatible
29559 DUALCASE=1; export DUALCASE # for MKS sh
29560 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29561 emulate sh
29562 NULLCMD=:
29563 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29564 # is contrary to our usage. Disable this feature.
29565 alias -g '${1+"$@"}'='"$@"'
29566 setopt NO_GLOB_SUBST
29567 else
29568 case `(set -o) 2>/dev/null` in #(
29569 *posix*) :
29570 set -o posix ;; #(
29571 *) :
29573 esac
29577 as_nl='
29579 export as_nl
29580 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29581 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29582 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29583 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29584 # Prefer a ksh shell builtin over an external printf program on Solaris,
29585 # but without wasting forks for bash or zsh.
29586 if test -z "$BASH_VERSION$ZSH_VERSION" \
29587 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29588 as_echo='print -r --'
29589 as_echo_n='print -rn --'
29590 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29591 as_echo='printf %s\n'
29592 as_echo_n='printf %s'
29593 else
29594 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29595 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29596 as_echo_n='/usr/ucb/echo -n'
29597 else
29598 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29599 as_echo_n_body='eval
29600 arg=$1;
29601 case $arg in #(
29602 *"$as_nl"*)
29603 expr "X$arg" : "X\\(.*\\)$as_nl";
29604 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29605 esac;
29606 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29608 export as_echo_n_body
29609 as_echo_n='sh -c $as_echo_n_body as_echo'
29611 export as_echo_body
29612 as_echo='sh -c $as_echo_body as_echo'
29615 # The user is always right.
29616 if test "${PATH_SEPARATOR+set}" != set; then
29617 PATH_SEPARATOR=:
29618 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29619 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29620 PATH_SEPARATOR=';'
29625 # IFS
29626 # We need space, tab and new line, in precisely that order. Quoting is
29627 # there to prevent editors from complaining about space-tab.
29628 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29629 # splitting by setting IFS to empty value.)
29630 IFS=" "" $as_nl"
29632 # Find who we are. Look in the path if we contain no directory separator.
29633 case $0 in #((
29634 *[\\/]* ) as_myself=$0 ;;
29635 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29636 for as_dir in $PATH
29638 IFS=$as_save_IFS
29639 test -z "$as_dir" && as_dir=.
29640 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29641 done
29642 IFS=$as_save_IFS
29645 esac
29646 # We did not find ourselves, most probably we were run as `sh COMMAND'
29647 # in which case we are not to be found in the path.
29648 if test "x$as_myself" = x; then
29649 as_myself=$0
29651 if test ! -f "$as_myself"; then
29652 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29653 exit 1
29656 # Unset variables that we do not need and which cause bugs (e.g. in
29657 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29658 # suppresses any "Segmentation fault" message there. '((' could
29659 # trigger a bug in pdksh 5.2.14.
29660 for as_var in BASH_ENV ENV MAIL MAILPATH
29661 do eval test x\${$as_var+set} = xset \
29662 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29663 done
29664 PS1='$ '
29665 PS2='> '
29666 PS4='+ '
29668 # NLS nuisances.
29669 LC_ALL=C
29670 export LC_ALL
29671 LANGUAGE=C
29672 export LANGUAGE
29674 # CDPATH.
29675 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29678 # as_fn_error ERROR [LINENO LOG_FD]
29679 # ---------------------------------
29680 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29681 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29682 # script with status $?, using 1 if that was 0.
29683 as_fn_error ()
29685 as_status=$?; test $as_status -eq 0 && as_status=1
29686 if test "$3"; then
29687 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29688 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29690 $as_echo "$as_me: error: $1" >&2
29691 as_fn_exit $as_status
29692 } # as_fn_error
29695 # as_fn_set_status STATUS
29696 # -----------------------
29697 # Set $? to STATUS, without forking.
29698 as_fn_set_status ()
29700 return $1
29701 } # as_fn_set_status
29703 # as_fn_exit STATUS
29704 # -----------------
29705 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29706 as_fn_exit ()
29708 set +e
29709 as_fn_set_status $1
29710 exit $1
29711 } # as_fn_exit
29713 # as_fn_unset VAR
29714 # ---------------
29715 # Portably unset VAR.
29716 as_fn_unset ()
29718 { eval $1=; unset $1;}
29720 as_unset=as_fn_unset
29721 # as_fn_append VAR VALUE
29722 # ----------------------
29723 # Append the text in VALUE to the end of the definition contained in VAR. Take
29724 # advantage of any shell optimizations that allow amortized linear growth over
29725 # repeated appends, instead of the typical quadratic growth present in naive
29726 # implementations.
29727 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29728 eval 'as_fn_append ()
29730 eval $1+=\$2
29732 else
29733 as_fn_append ()
29735 eval $1=\$$1\$2
29737 fi # as_fn_append
29739 # as_fn_arith ARG...
29740 # ------------------
29741 # Perform arithmetic evaluation on the ARGs, and store the result in the
29742 # global $as_val. Take advantage of shells that can avoid forks. The arguments
29743 # must be portable across $(()) and expr.
29744 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29745 eval 'as_fn_arith ()
29747 as_val=$(( $* ))
29749 else
29750 as_fn_arith ()
29752 as_val=`expr "$@" || test $? -eq 1`
29754 fi # as_fn_arith
29757 if expr a : '\(a\)' >/dev/null 2>&1 &&
29758 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29759 as_expr=expr
29760 else
29761 as_expr=false
29764 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29765 as_basename=basename
29766 else
29767 as_basename=false
29770 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29771 as_dirname=dirname
29772 else
29773 as_dirname=false
29776 as_me=`$as_basename -- "$0" ||
29777 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29778 X"$0" : 'X\(//\)$' \| \
29779 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29780 $as_echo X/"$0" |
29781 sed '/^.*\/\([^/][^/]*\)\/*$/{
29782 s//\1/
29785 /^X\/\(\/\/\)$/{
29786 s//\1/
29789 /^X\/\(\/\).*/{
29790 s//\1/
29793 s/.*/./; q'`
29795 # Avoid depending upon Character Ranges.
29796 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29797 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29798 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29799 as_cr_digits='0123456789'
29800 as_cr_alnum=$as_cr_Letters$as_cr_digits
29802 ECHO_C= ECHO_N= ECHO_T=
29803 case `echo -n x` in #(((((
29804 -n*)
29805 case `echo 'xy\c'` in
29806 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29807 xy) ECHO_C='\c';;
29808 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29809 ECHO_T=' ';;
29810 esac;;
29812 ECHO_N='-n';;
29813 esac
29815 rm -f conf$$ conf$$.exe conf$$.file
29816 if test -d conf$$.dir; then
29817 rm -f conf$$.dir/conf$$.file
29818 else
29819 rm -f conf$$.dir
29820 mkdir conf$$.dir 2>/dev/null
29822 if (echo >conf$$.file) 2>/dev/null; then
29823 if ln -s conf$$.file conf$$ 2>/dev/null; then
29824 as_ln_s='ln -s'
29825 # ... but there are two gotchas:
29826 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29827 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29828 # In both cases, we have to default to `cp -p'.
29829 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29830 as_ln_s='cp -p'
29831 elif ln conf$$.file conf$$ 2>/dev/null; then
29832 as_ln_s=ln
29833 else
29834 as_ln_s='cp -p'
29836 else
29837 as_ln_s='cp -p'
29839 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29840 rmdir conf$$.dir 2>/dev/null
29843 # as_fn_mkdir_p
29844 # -------------
29845 # Create "$as_dir" as a directory, including parents if necessary.
29846 as_fn_mkdir_p ()
29849 case $as_dir in #(
29850 -*) as_dir=./$as_dir;;
29851 esac
29852 test -d "$as_dir" || eval $as_mkdir_p || {
29853 as_dirs=
29854 while :; do
29855 case $as_dir in #(
29856 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29857 *) as_qdir=$as_dir;;
29858 esac
29859 as_dirs="'$as_qdir' $as_dirs"
29860 as_dir=`$as_dirname -- "$as_dir" ||
29861 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29862 X"$as_dir" : 'X\(//\)[^/]' \| \
29863 X"$as_dir" : 'X\(//\)$' \| \
29864 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29865 $as_echo X"$as_dir" |
29866 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29867 s//\1/
29870 /^X\(\/\/\)[^/].*/{
29871 s//\1/
29874 /^X\(\/\/\)$/{
29875 s//\1/
29878 /^X\(\/\).*/{
29879 s//\1/
29882 s/.*/./; q'`
29883 test -d "$as_dir" && break
29884 done
29885 test -z "$as_dirs" || eval "mkdir $as_dirs"
29886 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
29889 } # as_fn_mkdir_p
29890 if mkdir -p . 2>/dev/null; then
29891 as_mkdir_p='mkdir -p "$as_dir"'
29892 else
29893 test -d ./-p && rmdir ./-p
29894 as_mkdir_p=false
29897 if test -x / >/dev/null 2>&1; then
29898 as_test_x='test -x'
29899 else
29900 if ls -dL / >/dev/null 2>&1; then
29901 as_ls_L_option=L
29902 else
29903 as_ls_L_option=
29905 as_test_x='
29906 eval sh -c '\''
29907 if test -d "$1"; then
29908 test -d "$1/.";
29909 else
29910 case $1 in #(
29911 -*)set "./$1";;
29912 esac;
29913 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
29914 ???[sx]*):;;*)false;;esac;fi
29915 '\'' sh
29918 as_executable_p=$as_test_x
29920 # Sed expression to map a string onto a valid CPP name.
29921 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29923 # Sed expression to map a string onto a valid variable name.
29924 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29927 exec 6>&1
29928 ## ----------------------------------- ##
29929 ## Main body of $CONFIG_STATUS script. ##
29930 ## ----------------------------------- ##
29931 _ASEOF
29932 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
29934 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29935 # Save the log message, to keep $0 and so on meaningful, and to
29936 # report actual input values of CONFIG_FILES etc. instead of their
29937 # values after options handling.
29938 ac_log="
29939 This file was extended by emacs $as_me 24.3.50, which was
29940 generated by GNU Autoconf 2.65. Invocation command line was
29942 CONFIG_FILES = $CONFIG_FILES
29943 CONFIG_HEADERS = $CONFIG_HEADERS
29944 CONFIG_LINKS = $CONFIG_LINKS
29945 CONFIG_COMMANDS = $CONFIG_COMMANDS
29946 $ $0 $@
29948 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29951 _ACEOF
29953 case $ac_config_files in *"
29954 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29955 esac
29957 case $ac_config_headers in *"
29958 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29959 esac
29962 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29963 # Files that config.status was made for.
29964 config_files="$ac_config_files"
29965 config_headers="$ac_config_headers"
29966 config_commands="$ac_config_commands"
29968 _ACEOF
29970 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29971 ac_cs_usage="\
29972 \`$as_me' instantiates files and other configuration actions
29973 from templates according to the current configuration. Unless the files
29974 and actions are specified as TAGs, all are instantiated by default.
29976 Usage: $0 [OPTION]... [TAG]...
29978 -h, --help print this help, then exit
29979 -V, --version print version number and configuration settings, then exit
29980 --config print configuration, then exit
29981 -q, --quiet, --silent
29982 do not print progress messages
29983 -d, --debug don't remove temporary files
29984 --recheck update $as_me by reconfiguring in the same conditions
29985 --file=FILE[:TEMPLATE]
29986 instantiate the configuration file FILE
29987 --header=FILE[:TEMPLATE]
29988 instantiate the configuration header FILE
29990 Configuration files:
29991 $config_files
29993 Configuration headers:
29994 $config_headers
29996 Configuration commands:
29997 $config_commands
29999 Report bugs to the package provider."
30001 _ACEOF
30002 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30003 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
30004 ac_cs_version="\\
30005 emacs config.status 24.3.50
30006 configured by $0, generated by GNU Autoconf 2.65,
30007 with options \\"\$ac_cs_config\\"
30009 Copyright (C) 2009 Free Software Foundation, Inc.
30010 This config.status script is free software; the Free Software Foundation
30011 gives unlimited permission to copy, distribute and modify it."
30013 ac_pwd='$ac_pwd'
30014 srcdir='$srcdir'
30015 INSTALL='$INSTALL'
30016 MKDIR_P='$MKDIR_P'
30017 AWK='$AWK'
30018 test -n "\$AWK" || AWK=awk
30019 _ACEOF
30021 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30022 # The default lists apply if the user does not specify any file.
30023 ac_need_defaults=:
30024 while test $# != 0
30026 case $1 in
30027 --*=*)
30028 ac_option=`expr "X$1" : 'X\([^=]*\)='`
30029 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30030 ac_shift=:
30033 ac_option=$1
30034 ac_optarg=$2
30035 ac_shift=shift
30037 esac
30039 case $ac_option in
30040 # Handling of the options.
30041 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30042 ac_cs_recheck=: ;;
30043 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30044 $as_echo "$ac_cs_version"; exit ;;
30045 --config | --confi | --conf | --con | --co | --c )
30046 $as_echo "$ac_cs_config"; exit ;;
30047 --debug | --debu | --deb | --de | --d | -d )
30048 debug=: ;;
30049 --file | --fil | --fi | --f )
30050 $ac_shift
30051 case $ac_optarg in
30052 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30053 esac
30054 as_fn_append CONFIG_FILES " '$ac_optarg'"
30055 ac_need_defaults=false;;
30056 --header | --heade | --head | --hea )
30057 $ac_shift
30058 case $ac_optarg in
30059 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30060 esac
30061 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
30062 ac_need_defaults=false;;
30063 --he | --h)
30064 # Conflict between --help and --header
30065 as_fn_error "ambiguous option: \`$1'
30066 Try \`$0 --help' for more information.";;
30067 --help | --hel | -h )
30068 $as_echo "$ac_cs_usage"; exit ;;
30069 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30070 | -silent | --silent | --silen | --sile | --sil | --si | --s)
30071 ac_cs_silent=: ;;
30073 # This is an error.
30074 -*) as_fn_error "unrecognized option: \`$1'
30075 Try \`$0 --help' for more information." ;;
30077 *) as_fn_append ac_config_targets " $1"
30078 ac_need_defaults=false ;;
30080 esac
30081 shift
30082 done
30084 ac_configure_extra_args=
30086 if $ac_cs_silent; then
30087 exec 6>/dev/null
30088 ac_configure_extra_args="$ac_configure_extra_args --silent"
30091 _ACEOF
30092 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30093 if \$ac_cs_recheck; then
30094 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30095 shift
30096 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30097 CONFIG_SHELL='$SHELL'
30098 export CONFIG_SHELL
30099 exec "\$@"
30102 _ACEOF
30103 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30104 exec 5>>config.log
30106 echo
30107 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30108 ## Running $as_me. ##
30109 _ASBOX
30110 $as_echo "$ac_log"
30111 } >&5
30113 _ACEOF
30114 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30116 # INIT-COMMANDS
30118 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
30119 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
30121 _ACEOF
30123 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30125 # Handling of arguments.
30126 for ac_config_target in $ac_config_targets
30128 case $ac_config_target in
30129 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
30130 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
30131 "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" ;;
30132 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
30133 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
30134 "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" ;;
30135 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
30136 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
30137 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
30138 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
30139 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
30140 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
30141 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
30142 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
30143 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
30144 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
30145 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
30146 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
30147 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
30148 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
30149 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
30150 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
30151 "src/epaths.h") CONFIG_COMMANDS="$CONFIG_COMMANDS src/epaths.h" ;;
30152 "src/.gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS src/.gdbinit" ;;
30154 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
30155 esac
30156 done
30159 # If the user did not use the arguments to specify the items to instantiate,
30160 # then the envvar interface is used. Set only those that are not.
30161 # We use the long form for the default assignment because of an extremely
30162 # bizarre bug on SunOS 4.1.3.
30163 if $ac_need_defaults; then
30164 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30165 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30166 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30169 # Have a temporary directory for convenience. Make it in the build tree
30170 # simply because there is no reason against having it here, and in addition,
30171 # creating and moving files from /tmp can sometimes cause problems.
30172 # Hook for its removal unless debugging.
30173 # Note that there is a small window in which the directory will not be cleaned:
30174 # after its creation but before its name has been assigned to `$tmp'.
30175 $debug ||
30177 tmp=
30178 trap 'exit_status=$?
30179 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30181 trap 'as_fn_exit 1' 1 2 13 15
30183 # Create a (secure) tmp directory for tmp files.
30186 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30187 test -n "$tmp" && test -d "$tmp"
30188 } ||
30190 tmp=./conf$$-$RANDOM
30191 (umask 077 && mkdir "$tmp")
30192 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
30194 # Set up the scripts for CONFIG_FILES section.
30195 # No need to generate them if there are no CONFIG_FILES.
30196 # This happens for instance with `./config.status config.h'.
30197 if test -n "$CONFIG_FILES"; then
30199 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
30200 ac_cs_awk_getline=:
30201 ac_cs_awk_pipe_init=
30202 ac_cs_awk_read_file='
30203 while ((getline aline < (F[key])) > 0)
30204 print(aline)
30205 close(F[key])'
30206 ac_cs_awk_pipe_fini=
30207 else
30208 ac_cs_awk_getline=false
30209 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
30210 ac_cs_awk_read_file='
30211 print "|#_!!_#|"
30212 print "cat " F[key] " &&"
30213 '$ac_cs_awk_pipe_init
30214 # The final `:' finishes the AND list.
30215 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
30217 ac_cr=`echo X | tr X '\015'`
30218 # On cygwin, bash can eat \r inside `` if the user requested igncr.
30219 # But we know of no other shell where ac_cr would be empty at this
30220 # point, so we can use a bashism as a fallback.
30221 if test "x$ac_cr" = x; then
30222 eval ac_cr=\$\'\\r\'
30224 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30225 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30226 ac_cs_awk_cr='\r'
30227 else
30228 ac_cs_awk_cr=$ac_cr
30231 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30232 _ACEOF
30234 # Create commands to substitute file output variables.
30236 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
30237 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
30238 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
30239 echo "_ACAWK" &&
30240 echo "_ACEOF"
30241 } >conf$$files.sh &&
30242 . ./conf$$files.sh ||
30243 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30244 rm -f conf$$files.sh
30247 echo "cat >conf$$subs.awk <<_ACEOF" &&
30248 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30249 echo "_ACEOF"
30250 } >conf$$subs.sh ||
30251 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30252 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30253 ac_delim='%!_!# '
30254 for ac_last_try in false false false false false :; do
30255 . ./conf$$subs.sh ||
30256 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30258 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30259 if test $ac_delim_n = $ac_delim_num; then
30260 break
30261 elif $ac_last_try; then
30262 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30263 else
30264 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30266 done
30267 rm -f conf$$subs.sh
30269 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30270 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30271 _ACEOF
30272 sed -n '
30274 s/^/S["/; s/!.*/"]=/
30277 s/^[^!]*!//
30278 :repl
30279 t repl
30280 s/'"$ac_delim"'$//
30281 t delim
30284 s/\(.\{148\}\)..*/\1/
30285 t more1
30286 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30289 b repl
30290 :more1
30291 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30294 s/.\{148\}//
30295 t nl
30296 :delim
30298 s/\(.\{148\}\)..*/\1/
30299 t more2
30300 s/["\\]/\\&/g; s/^/"/; s/$/"/
30303 :more2
30304 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30307 s/.\{148\}//
30308 t delim
30309 ' <conf$$subs.awk | sed '
30310 /^[^""]/{
30312 s/\n//
30314 ' >>$CONFIG_STATUS || ac_write_fail=1
30315 rm -f conf$$subs.awk
30316 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30317 _ACAWK
30318 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30319 for (key in S) S_is_set[key] = 1
30320 FS = "\a"
30321 \$ac_cs_awk_pipe_init
30324 line = $ 0
30325 nfields = split(line, field, "@")
30326 substed = 0
30327 len = length(field[1])
30328 for (i = 2; i < nfields; i++) {
30329 key = field[i]
30330 keylen = length(key)
30331 if (S_is_set[key]) {
30332 value = S[key]
30333 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30334 len += length(value) + length(field[++i])
30335 substed = 1
30336 } else
30337 len += 1 + keylen
30339 if (nfields == 3 && !substed) {
30340 key = field[2]
30341 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
30342 \$ac_cs_awk_read_file
30343 next
30346 print line
30348 \$ac_cs_awk_pipe_fini
30349 _ACAWK
30350 _ACEOF
30351 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30352 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30353 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30354 else
30356 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30357 || as_fn_error "could not setup config files machinery" "$LINENO" 5
30358 _ACEOF
30360 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30361 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30362 # trailing colons and then remove the whole line if VPATH becomes empty
30363 # (actually we leave an empty line to preserve line numbers).
30364 if test "x$srcdir" = x.; then
30365 ac_vpsub='/^[ ]*VPATH[ ]*=/{
30366 s/:*\$(srcdir):*/:/
30367 s/:*\${srcdir}:*/:/
30368 s/:*@srcdir@:*/:/
30369 s/^\([^=]*=[ ]*\):*/\1/
30370 s/:*$//
30371 s/^[^=]*=[ ]*$//
30375 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30376 fi # test -n "$CONFIG_FILES"
30378 # Set up the scripts for CONFIG_HEADERS section.
30379 # No need to generate them if there are no CONFIG_HEADERS.
30380 # This happens for instance with `./config.status Makefile'.
30381 if test -n "$CONFIG_HEADERS"; then
30382 cat >"$tmp/defines.awk" <<\_ACAWK ||
30383 BEGIN {
30384 _ACEOF
30386 # Transform confdefs.h into an awk script `defines.awk', embedded as
30387 # here-document in config.status, that substitutes the proper values into
30388 # config.h.in to produce config.h.
30390 # Create a delimiter string that does not exist in confdefs.h, to ease
30391 # handling of long lines.
30392 ac_delim='%!_!# '
30393 for ac_last_try in false false :; do
30394 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30395 if test -z "$ac_t"; then
30396 break
30397 elif $ac_last_try; then
30398 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
30399 else
30400 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30402 done
30404 # For the awk script, D is an array of macro values keyed by name,
30405 # likewise P contains macro parameters if any. Preserve backslash
30406 # newline sequences.
30408 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30409 sed -n '
30410 s/.\{148\}/&'"$ac_delim"'/g
30411 t rset
30412 :rset
30413 s/^[ ]*#[ ]*define[ ][ ]*/ /
30414 t def
30416 :def
30417 s/\\$//
30418 t bsnl
30419 s/["\\]/\\&/g
30420 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30421 D["\1"]=" \3"/p
30422 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
30424 :bsnl
30425 s/["\\]/\\&/g
30426 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30427 D["\1"]=" \3\\\\\\n"\\/p
30428 t cont
30429 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30430 t cont
30432 :cont
30434 s/.\{148\}/&'"$ac_delim"'/g
30435 t clear
30436 :clear
30437 s/\\$//
30438 t bsnlc
30439 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30441 :bsnlc
30442 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30443 b cont
30444 ' <confdefs.h | sed '
30445 s/'"$ac_delim"'/"\\\
30446 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30448 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30449 for (key in D) D_is_set[key] = 1
30450 FS = "\a"
30452 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30453 line = \$ 0
30454 split(line, arg, " ")
30455 if (arg[1] == "#") {
30456 defundef = arg[2]
30457 mac1 = arg[3]
30458 } else {
30459 defundef = substr(arg[1], 2)
30460 mac1 = arg[2]
30462 split(mac1, mac2, "(") #)
30463 macro = mac2[1]
30464 prefix = substr(line, 1, index(line, defundef) - 1)
30465 if (D_is_set[macro]) {
30466 # Preserve the white space surrounding the "#".
30467 print prefix "define", macro P[macro] D[macro]
30468 next
30469 } else {
30470 # Replace #undef with comments. This is necessary, for example,
30471 # in the case of _POSIX_SOURCE, which is predefined and required
30472 # on some systems where configure will not decide to define it.
30473 if (defundef == "undef") {
30474 print "/*", prefix defundef, macro, "*/"
30475 next
30479 { print }
30480 _ACAWK
30481 _ACEOF
30482 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30483 as_fn_error "could not setup config headers machinery" "$LINENO" 5
30484 fi # test -n "$CONFIG_HEADERS"
30487 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
30488 shift
30489 for ac_tag
30491 case $ac_tag in
30492 :[FHLC]) ac_mode=$ac_tag; continue;;
30493 esac
30494 case $ac_mode$ac_tag in
30495 :[FHL]*:*);;
30496 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
30497 :[FH]-) ac_tag=-:-;;
30498 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30499 esac
30500 ac_save_IFS=$IFS
30501 IFS=:
30502 set x $ac_tag
30503 IFS=$ac_save_IFS
30504 shift
30505 ac_file=$1
30506 shift
30508 case $ac_mode in
30509 :L) ac_source=$1;;
30510 :[FH])
30511 ac_file_inputs=
30512 for ac_f
30514 case $ac_f in
30515 -) ac_f="$tmp/stdin";;
30516 *) # Look for the file first in the build tree, then in the source tree
30517 # (if the path is not absolute). The absolute path cannot be DOS-style,
30518 # because $ac_f cannot contain `:'.
30519 test -f "$ac_f" ||
30520 case $ac_f in
30521 [\\/$]*) false;;
30522 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30523 esac ||
30524 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30525 esac
30526 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30527 as_fn_append ac_file_inputs " '$ac_f'"
30528 done
30530 # Let's still pretend it is `configure' which instantiates (i.e., don't
30531 # use $as_me), people would be surprised to read:
30532 # /* config.h. Generated by config.status. */
30533 configure_input='Generated from '`
30534 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30535 `' by configure.'
30536 if test x"$ac_file" != x-; then
30537 configure_input="$ac_file. $configure_input"
30538 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30539 $as_echo "$as_me: creating $ac_file" >&6;}
30541 # Neutralize special characters interpreted by sed in replacement strings.
30542 case $configure_input in #(
30543 *\&* | *\|* | *\\* )
30544 ac_sed_conf_input=`$as_echo "$configure_input" |
30545 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30546 *) ac_sed_conf_input=$configure_input;;
30547 esac
30549 case $ac_tag in
30550 *:-:* | *:-) cat >"$tmp/stdin" \
30551 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
30552 esac
30554 esac
30556 ac_dir=`$as_dirname -- "$ac_file" ||
30557 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30558 X"$ac_file" : 'X\(//\)[^/]' \| \
30559 X"$ac_file" : 'X\(//\)$' \| \
30560 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30561 $as_echo X"$ac_file" |
30562 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30563 s//\1/
30566 /^X\(\/\/\)[^/].*/{
30567 s//\1/
30570 /^X\(\/\/\)$/{
30571 s//\1/
30574 /^X\(\/\).*/{
30575 s//\1/
30578 s/.*/./; q'`
30579 as_dir="$ac_dir"; as_fn_mkdir_p
30580 ac_builddir=.
30582 case "$ac_dir" in
30583 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30585 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30586 # A ".." for each directory in $ac_dir_suffix.
30587 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30588 case $ac_top_builddir_sub in
30589 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30590 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30591 esac ;;
30592 esac
30593 ac_abs_top_builddir=$ac_pwd
30594 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30595 # for backward compatibility:
30596 ac_top_builddir=$ac_top_build_prefix
30598 case $srcdir in
30599 .) # We are building in place.
30600 ac_srcdir=.
30601 ac_top_srcdir=$ac_top_builddir_sub
30602 ac_abs_top_srcdir=$ac_pwd ;;
30603 [\\/]* | ?:[\\/]* ) # Absolute name.
30604 ac_srcdir=$srcdir$ac_dir_suffix;
30605 ac_top_srcdir=$srcdir
30606 ac_abs_top_srcdir=$srcdir ;;
30607 *) # Relative name.
30608 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30609 ac_top_srcdir=$ac_top_build_prefix$srcdir
30610 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30611 esac
30612 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30615 case $ac_mode in
30618 # CONFIG_FILE
30621 case $INSTALL in
30622 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30623 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30624 esac
30625 ac_MKDIR_P=$MKDIR_P
30626 case $MKDIR_P in
30627 [\\/$]* | ?:[\\/]* ) ;;
30628 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30629 esac
30630 _ACEOF
30632 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30633 # If the template does not know about datarootdir, expand it.
30634 # FIXME: This hack should be removed a few years after 2.60.
30635 ac_datarootdir_hack=; ac_datarootdir_seen=
30636 ac_sed_dataroot='
30637 /datarootdir/ {
30641 /@datadir@/p
30642 /@docdir@/p
30643 /@infodir@/p
30644 /@localedir@/p
30645 /@mandir@/p'
30646 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30647 *datarootdir*) ac_datarootdir_seen=yes;;
30648 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30650 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30651 _ACEOF
30652 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30653 ac_datarootdir_hack='
30654 s&@datadir@&$datadir&g
30655 s&@docdir@&$docdir&g
30656 s&@infodir@&$infodir&g
30657 s&@localedir@&$localedir&g
30658 s&@mandir@&$mandir&g
30659 s&\\\${datarootdir}&$datarootdir&g' ;;
30660 esac
30661 _ACEOF
30663 # Neutralize VPATH when `$srcdir' = `.'.
30664 # Shell code in configure.ac might set extrasub.
30665 # FIXME: do we really want to maintain this feature?
30666 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30667 ac_sed_extra="$ac_vpsub
30668 $extrasub
30669 _ACEOF
30670 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30672 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30673 s|@configure_input@|$ac_sed_conf_input|;t t
30674 s&@top_builddir@&$ac_top_builddir_sub&;t t
30675 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30676 s&@srcdir@&$ac_srcdir&;t t
30677 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30678 s&@top_srcdir@&$ac_top_srcdir&;t t
30679 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30680 s&@builddir@&$ac_builddir&;t t
30681 s&@abs_builddir@&$ac_abs_builddir&;t t
30682 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30683 s&@INSTALL@&$ac_INSTALL&;t t
30684 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30685 $ac_datarootdir_hack
30687 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30688 if $ac_cs_awk_getline; then
30689 $AWK -f "$tmp/subs.awk"
30690 else
30691 $AWK -f "$tmp/subs.awk" | $SHELL
30692 fi >$tmp/out \
30693 || as_fn_error "could not create $ac_file" "$LINENO" 5
30695 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30696 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30697 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30698 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30699 which seems to be undefined. Please make sure it is defined." >&5
30700 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30701 which seems to be undefined. Please make sure it is defined." >&2;}
30703 rm -f "$tmp/stdin"
30704 case $ac_file in
30705 -) cat "$tmp/out" && rm -f "$tmp/out";;
30706 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30707 esac \
30708 || as_fn_error "could not create $ac_file" "$LINENO" 5
30712 # CONFIG_HEADER
30714 if test x"$ac_file" != x-; then
30716 $as_echo "/* $configure_input */" \
30717 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30718 } >"$tmp/config.h" \
30719 || as_fn_error "could not create $ac_file" "$LINENO" 5
30720 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30721 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30722 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30723 else
30724 rm -f "$ac_file"
30725 mv "$tmp/config.h" "$ac_file" \
30726 || as_fn_error "could not create $ac_file" "$LINENO" 5
30728 else
30729 $as_echo "/* $configure_input */" \
30730 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30731 || as_fn_error "could not create -" "$LINENO" 5
30733 # Compute "$ac_file"'s index in $config_headers.
30734 _am_arg="$ac_file"
30735 _am_stamp_count=1
30736 for _am_header in $config_headers :; do
30737 case $_am_header in
30738 $_am_arg | $_am_arg:* )
30739 break ;;
30741 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30742 esac
30743 done
30744 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30745 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30746 X"$_am_arg" : 'X\(//\)[^/]' \| \
30747 X"$_am_arg" : 'X\(//\)$' \| \
30748 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30749 $as_echo X"$_am_arg" |
30750 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30751 s//\1/
30754 /^X\(\/\/\)[^/].*/{
30755 s//\1/
30758 /^X\(\/\/\)$/{
30759 s//\1/
30762 /^X\(\/\).*/{
30763 s//\1/
30766 s/.*/./; q'`/stamp-h$_am_stamp_count
30769 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30770 $as_echo "$as_me: executing $ac_file commands" >&6;}
30772 esac
30775 case $ac_file$ac_mode in
30776 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30777 # Autoconf 2.62 quotes --file arguments for eval, but not when files
30778 # are listed without --file. Let's play safe and only enable the eval
30779 # if we detect the quoting.
30780 case $CONFIG_FILES in
30781 *\'*) eval set x "$CONFIG_FILES" ;;
30782 *) set x $CONFIG_FILES ;;
30783 esac
30784 shift
30785 for mf
30787 # Strip MF so we end up with the name of the file.
30788 mf=`echo "$mf" | sed -e 's/:.*$//'`
30789 # Check whether this is an Automake generated Makefile or not.
30790 # We used to match only the files named `Makefile.in', but
30791 # some people rename them; so instead we look at the file content.
30792 # Grep'ing the first line is not enough: some people post-process
30793 # each Makefile.in and add a new line on top of each file to say so.
30794 # Grep'ing the whole file is not good either: AIX grep has a line
30795 # limit of 2048, but all sed's we know have understand at least 4000.
30796 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30797 dirpart=`$as_dirname -- "$mf" ||
30798 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30799 X"$mf" : 'X\(//\)[^/]' \| \
30800 X"$mf" : 'X\(//\)$' \| \
30801 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30802 $as_echo X"$mf" |
30803 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30804 s//\1/
30807 /^X\(\/\/\)[^/].*/{
30808 s//\1/
30811 /^X\(\/\/\)$/{
30812 s//\1/
30815 /^X\(\/\).*/{
30816 s//\1/
30819 s/.*/./; q'`
30820 else
30821 continue
30823 # Extract the definition of DEPDIR, am__include, and am__quote
30824 # from the Makefile without running `make'.
30825 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30826 test -z "$DEPDIR" && continue
30827 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30828 test -z "am__include" && continue
30829 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30830 # When using ansi2knr, U may be empty or an underscore; expand it
30831 U=`sed -n 's/^U = //p' < "$mf"`
30832 # Find all dependency output files, they are included files with
30833 # $(DEPDIR) in their names. We invoke sed twice because it is the
30834 # simplest approach to changing $(DEPDIR) to its actual value in the
30835 # expansion.
30836 for file in `sed -n "
30837 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30838 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
30839 # Make sure the directory exists.
30840 test -f "$dirpart/$file" && continue
30841 fdir=`$as_dirname -- "$file" ||
30842 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30843 X"$file" : 'X\(//\)[^/]' \| \
30844 X"$file" : 'X\(//\)$' \| \
30845 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30846 $as_echo X"$file" |
30847 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30848 s//\1/
30851 /^X\(\/\/\)[^/].*/{
30852 s//\1/
30855 /^X\(\/\/\)$/{
30856 s//\1/
30859 /^X\(\/\).*/{
30860 s//\1/
30863 s/.*/./; q'`
30864 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30865 # echo "creating $dirpart/$file"
30866 echo '# dummy' > "$dirpart/$file"
30867 done
30868 done
30871 "src/epaths.h":C)
30872 if test "${opsys}" = "mingw32"; then
30873 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
30874 else
30875 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
30878 "src/.gdbinit":C)
30879 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
30880 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
30884 esac
30885 done # for ac_tag
30888 as_fn_exit 0
30889 _ACEOF
30890 ac_clean_files=$ac_clean_files_save
30892 test $ac_write_fail = 0 ||
30893 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
30896 # configure is writing to config.log, and then calls config.status.
30897 # config.status does its own redirection, appending to config.log.
30898 # Unfortunately, on DOS this fails, as config.log is still kept open
30899 # by configure, so config.status won't be able to write to it; its
30900 # output is simply discarded. So we exec the FD to /dev/null,
30901 # effectively closing config.log, so it can be properly (re)opened and
30902 # appended to by config.status. When coming back to configure, we
30903 # need to make the FD available again.
30904 if test "$no_create" != yes; then
30905 ac_cs_success=:
30906 ac_config_status_args=
30907 test "$silent" = yes &&
30908 ac_config_status_args="$ac_config_status_args --quiet"
30909 exec 5>/dev/null
30910 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30911 exec 5>>config.log
30912 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30913 # would make configure fail if this is the last instruction.
30914 $ac_cs_success || as_fn_exit $?
30916 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30917 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30918 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}