Auto-commit of generated files.
[emacs.git] / autogen / configure
blobab58e8d1727f2f4ffcc0d9c00b7c28f3f483eeb6
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.3.50.
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
32 esac
36 as_nl='
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
150 esac
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
166 else
167 exitcode=1; echo positional parameters were not saved.
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
236 exit 1
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
254 { eval $1=; unset $1;}
256 as_unset=as_fn_unset
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
263 return $1
264 } # as_fn_set_status
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
307 /^X\(\/\/\)$/{
308 s//\1/
311 /^X\(\/\).*/{
312 s//\1/
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
332 eval $1+=\$2
334 else
335 as_fn_append ()
337 eval $1=\$$1\$2
339 fi # as_fn_append
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
349 as_val=$(( $* ))
351 else
352 as_fn_arith ()
354 as_val=`expr "$@" || test $? -eq 1`
356 fi # as_fn_arith
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
403 /^X\/\(\/\/\)$/{
404 s//\1/
407 /^X\/\(\/\).*/{
408 s//\1/
411 s/.*/./; q'`
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
434 :lineno
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
462 ECHO_N='-n';;
463 esac
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
486 else
487 as_ln_s='cp -p'
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
520 as_executable_p=$as_test_x
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
538 # Initializations.
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.3.50'
553 PACKAGE_STRING='emacs 24.3.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 WINDOW_SYSTEM_OBJ
608 LIB_GCC
609 LD_FIRSTFLAG
610 LD_SWITCH_SYSTEM_TEMACS
611 LIBGNU_LTLIBDEPS
612 LIBGNU_LIBDEPS
613 gltests_WITNESS
614 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE
615 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE
616 gl_GNULIB_ENABLED_verify_FALSE
617 gl_GNULIB_ENABLED_verify_TRUE
618 gl_GNULIB_ENABLED_strtoull_FALSE
619 gl_GNULIB_ENABLED_strtoull_TRUE
620 gl_GNULIB_ENABLED_strtoll_FALSE
621 gl_GNULIB_ENABLED_strtoll_TRUE
622 gl_GNULIB_ENABLED_stat_FALSE
623 gl_GNULIB_ENABLED_stat_TRUE
624 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
625 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
626 gl_GNULIB_ENABLED_pathmax_FALSE
627 gl_GNULIB_ENABLED_pathmax_TRUE
628 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
629 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
630 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
631 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
632 gl_GNULIB_ENABLED_getgroups_FALSE
633 gl_GNULIB_ENABLED_getgroups_TRUE
634 gl_GNULIB_ENABLED_euidaccess_FALSE
635 gl_GNULIB_ENABLED_euidaccess_TRUE
636 gl_GNULIB_ENABLED_dosname_FALSE
637 gl_GNULIB_ENABLED_dosname_TRUE
638 LTLIBINTL
639 LIBINTL
640 LIB_EACCESS
641 WINDOWS_64_BIT_OFF_T
642 HAVE_UNISTD_H
643 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
644 NEXT_UNISTD_H
645 LIB_TIMER_TIME
646 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
647 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
648 TIME_H_DEFINES_STRUCT_TIMESPEC
649 NEXT_AS_FIRST_DIRECTIVE_TIME_H
650 NEXT_TIME_H
651 WINDOWS_64_BIT_ST_SIZE
652 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
653 NEXT_SYS_STAT_H
654 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
655 NEXT_STDLIB_H
656 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
657 NEXT_STDIO_H
658 REPLACE_VSPRINTF
659 REPLACE_VSNPRINTF
660 REPLACE_VPRINTF
661 REPLACE_VFPRINTF
662 REPLACE_VDPRINTF
663 REPLACE_VASPRINTF
664 REPLACE_TMPFILE
665 REPLACE_STDIO_WRITE_FUNCS
666 REPLACE_STDIO_READ_FUNCS
667 REPLACE_SPRINTF
668 REPLACE_SNPRINTF
669 REPLACE_RENAMEAT
670 REPLACE_RENAME
671 REPLACE_REMOVE
672 REPLACE_PRINTF
673 REPLACE_POPEN
674 REPLACE_PERROR
675 REPLACE_OBSTACK_PRINTF
676 REPLACE_GETLINE
677 REPLACE_GETDELIM
678 REPLACE_FTELLO
679 REPLACE_FTELL
680 REPLACE_FSEEKO
681 REPLACE_FSEEK
682 REPLACE_FREOPEN
683 REPLACE_FPURGE
684 REPLACE_FPRINTF
685 REPLACE_FOPEN
686 REPLACE_FFLUSH
687 REPLACE_FDOPEN
688 REPLACE_FCLOSE
689 REPLACE_DPRINTF
690 HAVE_VDPRINTF
691 HAVE_VASPRINTF
692 HAVE_RENAMEAT
693 HAVE_POPEN
694 HAVE_PCLOSE
695 HAVE_FTELLO
696 HAVE_FSEEKO
697 HAVE_DPRINTF
698 HAVE_DECL_VSNPRINTF
699 HAVE_DECL_SNPRINTF
700 HAVE_DECL_OBSTACK_PRINTF
701 HAVE_DECL_GETLINE
702 HAVE_DECL_GETDELIM
703 HAVE_DECL_FTELLO
704 HAVE_DECL_FSEEKO
705 HAVE_DECL_FPURGE
706 GNULIB_VSPRINTF_POSIX
707 GNULIB_VSNPRINTF
708 GNULIB_VPRINTF_POSIX
709 GNULIB_VPRINTF
710 GNULIB_VFPRINTF_POSIX
711 GNULIB_VFPRINTF
712 GNULIB_VDPRINTF
713 GNULIB_VSCANF
714 GNULIB_VFSCANF
715 GNULIB_VASPRINTF
716 GNULIB_TMPFILE
717 GNULIB_STDIO_H_SIGPIPE
718 GNULIB_STDIO_H_NONBLOCKING
719 GNULIB_SPRINTF_POSIX
720 GNULIB_SNPRINTF
721 GNULIB_SCANF
722 GNULIB_RENAMEAT
723 GNULIB_RENAME
724 GNULIB_REMOVE
725 GNULIB_PUTS
726 GNULIB_PUTCHAR
727 GNULIB_PUTC
728 GNULIB_PRINTF_POSIX
729 GNULIB_PRINTF
730 GNULIB_POPEN
731 GNULIB_PERROR
732 GNULIB_PCLOSE
733 GNULIB_OBSTACK_PRINTF_POSIX
734 GNULIB_OBSTACK_PRINTF
735 GNULIB_GETLINE
736 GNULIB_GETDELIM
737 GNULIB_GETCHAR
738 GNULIB_GETC
739 GNULIB_FWRITE
740 GNULIB_FTELLO
741 GNULIB_FTELL
742 GNULIB_FSEEKO
743 GNULIB_FSEEK
744 GNULIB_FSCANF
745 GNULIB_FREOPEN
746 GNULIB_FREAD
747 GNULIB_FPUTS
748 GNULIB_FPUTC
749 GNULIB_FPURGE
750 GNULIB_FPRINTF_POSIX
751 GNULIB_FPRINTF
752 GNULIB_FOPEN
753 GNULIB_FGETS
754 GNULIB_FGETC
755 GNULIB_FFLUSH
756 GNULIB_FDOPEN
757 GNULIB_FCLOSE
758 GNULIB_DPRINTF
759 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
760 NEXT_STDDEF_H
761 GL_GENERATE_STDDEF_H_FALSE
762 GL_GENERATE_STDDEF_H_TRUE
763 STDDEF_H
764 HAVE_WCHAR_T
765 REPLACE_NULL
766 HAVE__BOOL
767 GL_GENERATE_STDBOOL_H_FALSE
768 GL_GENERATE_STDBOOL_H_TRUE
769 STDBOOL_H
770 GL_GENERATE_STDARG_H_FALSE
771 GL_GENERATE_STDARG_H_TRUE
772 STDARG_H
773 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
774 NEXT_STDARG_H
775 GL_GENERATE_STDALIGN_H_FALSE
776 GL_GENERATE_STDALIGN_H_TRUE
777 STDALIGN_H
778 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
779 NEXT_SIGNAL_H
780 LIB_PTHREAD_SIGMASK
781 REPLACE_RAISE
782 REPLACE_PTHREAD_SIGMASK
783 HAVE_SIGHANDLER_T
784 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
785 HAVE_STRUCT_SIGACTION_SA_SIGACTION
786 HAVE_SIGACTION
787 HAVE_SIGINFO_T
788 HAVE_SIGSET_T
789 HAVE_RAISE
790 HAVE_PTHREAD_SIGMASK
791 HAVE_POSIX_SIGNALBLOCKING
792 GNULIB_SIGACTION
793 GNULIB_SIGPROCMASK
794 GNULIB_SIGNAL_H_SIGPIPE
795 GNULIB_RAISE
796 GNULIB_PTHREAD_SIGMASK
797 HAVE_SYS_SELECT_H
798 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
799 NEXT_SYS_SELECT_H
800 REPLACE_SELECT
801 REPLACE_PSELECT
802 HAVE_PSELECT
803 GNULIB_SELECT
804 GNULIB_PSELECT
805 REPLACE_TIMEGM
806 REPLACE_NANOSLEEP
807 REPLACE_MKTIME
808 REPLACE_LOCALTIME_R
809 HAVE_TIMEGM
810 HAVE_STRPTIME
811 HAVE_NANOSLEEP
812 HAVE_DECL_LOCALTIME_R
813 GNULIB_TIME_R
814 GNULIB_TIMEGM
815 GNULIB_STRPTIME
816 GNULIB_NANOSLEEP
817 GNULIB_MKTIME
818 REPLACE_UTIMENSAT
819 REPLACE_STAT
820 REPLACE_MKNOD
821 REPLACE_MKFIFO
822 REPLACE_MKDIR
823 REPLACE_LSTAT
824 REPLACE_FUTIMENS
825 REPLACE_FSTATAT
826 REPLACE_FSTAT
827 HAVE_UTIMENSAT
828 HAVE_MKNODAT
829 HAVE_MKNOD
830 HAVE_MKFIFOAT
831 HAVE_MKFIFO
832 HAVE_MKDIRAT
833 HAVE_LSTAT
834 HAVE_LCHMOD
835 HAVE_FUTIMENS
836 HAVE_FSTATAT
837 HAVE_FCHMODAT
838 GNULIB_UTIMENSAT
839 GNULIB_STAT
840 GNULIB_MKNODAT
841 GNULIB_MKNOD
842 GNULIB_MKFIFOAT
843 GNULIB_MKFIFO
844 GNULIB_MKDIRAT
845 GNULIB_LSTAT
846 GNULIB_LCHMOD
847 GNULIB_FUTIMENS
848 GNULIB_FSTATAT
849 GNULIB_FSTAT
850 GNULIB_FCHMODAT
851 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
852 NEXT_INTTYPES_H
853 UINT64_MAX_EQ_ULONG_MAX
854 UINT32_MAX_LT_UINTMAX_MAX
855 PRIPTR_PREFIX
856 PRI_MACROS_BROKEN
857 INT64_MAX_EQ_LONG_MAX
858 INT32_MAX_LT_INTMAX_MAX
859 REPLACE_STRTOIMAX
860 HAVE_DECL_STRTOUMAX
861 HAVE_DECL_STRTOIMAX
862 HAVE_DECL_IMAXDIV
863 HAVE_DECL_IMAXABS
864 GNULIB_STRTOUMAX
865 GNULIB_STRTOIMAX
866 GNULIB_IMAXDIV
867 GNULIB_IMAXABS
868 GL_GENERATE_STDINT_H_FALSE
869 GL_GENERATE_STDINT_H_TRUE
870 STDINT_H
871 WINT_T_SUFFIX
872 WCHAR_T_SUFFIX
873 SIG_ATOMIC_T_SUFFIX
874 SIZE_T_SUFFIX
875 PTRDIFF_T_SUFFIX
876 HAVE_SIGNED_WINT_T
877 HAVE_SIGNED_WCHAR_T
878 HAVE_SIGNED_SIG_ATOMIC_T
879 BITSIZEOF_WINT_T
880 BITSIZEOF_WCHAR_T
881 BITSIZEOF_SIG_ATOMIC_T
882 BITSIZEOF_SIZE_T
883 BITSIZEOF_PTRDIFF_T
884 APPLE_UNIVERSAL_BUILD
885 HAVE_SYS_BITYPES_H
886 HAVE_SYS_INTTYPES_H
887 HAVE_STDINT_H
888 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
889 NEXT_STDINT_H
890 HAVE_SYS_TYPES_H
891 HAVE_INTTYPES_H
892 HAVE_WCHAR_H
893 HAVE_UNSIGNED_LONG_LONG_INT
894 HAVE_LONG_LONG_INT
895 HAVE_WINSOCK2_H
896 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
897 NEXT_SYS_TIME_H
898 REPLACE_STRUCT_TIMEVAL
899 REPLACE_GETTIMEOFDAY
900 HAVE_SYS_TIME_H
901 HAVE_STRUCT_TIMEVAL
902 HAVE_GETTIMEOFDAY
903 GNULIB_GETTIMEOFDAY
904 GNULIB_GL_UNISTD_H_GETOPT
905 GETOPT_H
906 HAVE_GETOPT_H
907 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
908 NEXT_GETOPT_H
909 GETLOADAVG_LIBS
910 REPLACE_WCTOMB
911 REPLACE_UNSETENV
912 REPLACE_STRTOD
913 REPLACE_SETENV
914 REPLACE_REALPATH
915 REPLACE_REALLOC
916 REPLACE_RANDOM_R
917 REPLACE_PUTENV
918 REPLACE_PTSNAME_R
919 REPLACE_PTSNAME
920 REPLACE_MKSTEMP
921 REPLACE_MBTOWC
922 REPLACE_MALLOC
923 REPLACE_CANONICALIZE_FILE_NAME
924 REPLACE_CALLOC
925 HAVE_DECL_UNSETENV
926 HAVE_UNLOCKPT
927 HAVE_SYS_LOADAVG_H
928 HAVE_STRUCT_RANDOM_DATA
929 HAVE_STRTOULL
930 HAVE_STRTOLL
931 HAVE_STRTOD
932 HAVE_DECL_SETENV
933 HAVE_SETENV
934 HAVE_RPMATCH
935 HAVE_REALPATH
936 HAVE_RANDOM_R
937 HAVE_RANDOM_H
938 HAVE_RANDOM
939 HAVE_PTSNAME_R
940 HAVE_PTSNAME
941 HAVE_POSIX_OPENPT
942 HAVE_MKSTEMPS
943 HAVE_MKSTEMP
944 HAVE_MKOSTEMPS
945 HAVE_MKOSTEMP
946 HAVE_MKDTEMP
947 HAVE_GRANTPT
948 HAVE_GETSUBOPT
949 HAVE_DECL_GETLOADAVG
950 HAVE_CANONICALIZE_FILE_NAME
951 HAVE_ATOLL
952 HAVE__EXIT
953 GNULIB_WCTOMB
954 GNULIB_UNSETENV
955 GNULIB_UNLOCKPT
956 GNULIB_SYSTEM_POSIX
957 GNULIB_STRTOULL
958 GNULIB_STRTOLL
959 GNULIB_STRTOD
960 GNULIB_SETENV
961 GNULIB_RPMATCH
962 GNULIB_REALPATH
963 GNULIB_REALLOC_POSIX
964 GNULIB_RANDOM_R
965 GNULIB_RANDOM
966 GNULIB_PUTENV
967 GNULIB_PTSNAME_R
968 GNULIB_PTSNAME
969 GNULIB_POSIX_OPENPT
970 GNULIB_MKSTEMPS
971 GNULIB_MKSTEMP
972 GNULIB_MKOSTEMPS
973 GNULIB_MKOSTEMP
974 GNULIB_MKDTEMP
975 GNULIB_MBTOWC
976 GNULIB_MALLOC_POSIX
977 GNULIB_GRANTPT
978 GNULIB_GETSUBOPT
979 GNULIB_GETLOADAVG
980 GNULIB_CANONICALIZE_FILE_NAME
981 GNULIB_CALLOC_POSIX
982 GNULIB_ATOLL
983 GNULIB__EXIT
984 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
985 NEXT_FCNTL_H
986 PRAGMA_COLUMNS
987 PRAGMA_SYSTEM_HEADER
988 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
989 INCLUDE_NEXT
990 REPLACE_OPENAT
991 REPLACE_OPEN
992 REPLACE_FCNTL
993 HAVE_OPENAT
994 HAVE_FCNTL
995 GNULIB_OPENAT
996 GNULIB_OPEN
997 GNULIB_NONBLOCKING
998 GNULIB_FCNTL
999 GL_GENERATE_EXECINFO_H_FALSE
1000 GL_GENERATE_EXECINFO_H_TRUE
1001 LIB_EXECINFO
1002 EXECINFO_H
1003 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1004 UNISTD_H_HAVE_WINSOCK2_H
1005 REPLACE_WRITE
1006 REPLACE_USLEEP
1007 REPLACE_UNLINKAT
1008 REPLACE_UNLINK
1009 REPLACE_TTYNAME_R
1010 REPLACE_SYMLINK
1011 REPLACE_SLEEP
1012 REPLACE_RMDIR
1013 REPLACE_READLINK
1014 REPLACE_READ
1015 REPLACE_PWRITE
1016 REPLACE_PREAD
1017 REPLACE_LSEEK
1018 REPLACE_LINKAT
1019 REPLACE_LINK
1020 REPLACE_LCHOWN
1021 REPLACE_ISATTY
1022 REPLACE_GETPAGESIZE
1023 REPLACE_GETGROUPS
1024 REPLACE_GETLOGIN_R
1025 REPLACE_GETDOMAINNAME
1026 REPLACE_GETCWD
1027 REPLACE_FTRUNCATE
1028 REPLACE_FCHOWNAT
1029 REPLACE_DUP2
1030 REPLACE_DUP
1031 REPLACE_CLOSE
1032 REPLACE_CHOWN
1033 HAVE_SYS_PARAM_H
1034 HAVE_OS_H
1035 HAVE_DECL_TTYNAME_R
1036 HAVE_DECL_SETHOSTNAME
1037 HAVE_DECL_GETUSERSHELL
1038 HAVE_DECL_GETPAGESIZE
1039 HAVE_DECL_GETLOGIN_R
1040 HAVE_DECL_GETDOMAINNAME
1041 HAVE_DECL_FDATASYNC
1042 HAVE_DECL_FCHDIR
1043 HAVE_DECL_ENVIRON
1044 HAVE_USLEEP
1045 HAVE_UNLINKAT
1046 HAVE_SYMLINKAT
1047 HAVE_SYMLINK
1048 HAVE_SLEEP
1049 HAVE_SETHOSTNAME
1050 HAVE_READLINKAT
1051 HAVE_READLINK
1052 HAVE_PWRITE
1053 HAVE_PREAD
1054 HAVE_PIPE2
1055 HAVE_PIPE
1056 HAVE_LINKAT
1057 HAVE_LINK
1058 HAVE_LCHOWN
1059 HAVE_GROUP_MEMBER
1060 HAVE_GETPAGESIZE
1061 HAVE_GETLOGIN
1062 HAVE_GETHOSTNAME
1063 HAVE_GETGROUPS
1064 HAVE_GETDTABLESIZE
1065 HAVE_FTRUNCATE
1066 HAVE_FSYNC
1067 HAVE_FDATASYNC
1068 HAVE_FCHOWNAT
1069 HAVE_FCHDIR
1070 HAVE_FACCESSAT
1071 HAVE_EUIDACCESS
1072 HAVE_DUP3
1073 HAVE_DUP2
1074 HAVE_CHOWN
1075 GNULIB_WRITE
1076 GNULIB_USLEEP
1077 GNULIB_UNLINKAT
1078 GNULIB_UNLINK
1079 GNULIB_UNISTD_H_SIGPIPE
1080 GNULIB_UNISTD_H_NONBLOCKING
1081 GNULIB_TTYNAME_R
1082 GNULIB_SYMLINKAT
1083 GNULIB_SYMLINK
1084 GNULIB_SLEEP
1085 GNULIB_SETHOSTNAME
1086 GNULIB_RMDIR
1087 GNULIB_READLINKAT
1088 GNULIB_READLINK
1089 GNULIB_READ
1090 GNULIB_PWRITE
1091 GNULIB_PREAD
1092 GNULIB_PIPE2
1093 GNULIB_PIPE
1094 GNULIB_LSEEK
1095 GNULIB_LINKAT
1096 GNULIB_LINK
1097 GNULIB_LCHOWN
1098 GNULIB_ISATTY
1099 GNULIB_GROUP_MEMBER
1100 GNULIB_GETUSERSHELL
1101 GNULIB_GETPAGESIZE
1102 GNULIB_GETLOGIN_R
1103 GNULIB_GETLOGIN
1104 GNULIB_GETHOSTNAME
1105 GNULIB_GETGROUPS
1106 GNULIB_GETDTABLESIZE
1107 GNULIB_GETDOMAINNAME
1108 GNULIB_GETCWD
1109 GNULIB_FTRUNCATE
1110 GNULIB_FSYNC
1111 GNULIB_FDATASYNC
1112 GNULIB_FCHOWNAT
1113 GNULIB_FCHDIR
1114 GNULIB_FACCESSAT
1115 GNULIB_EUIDACCESS
1116 GNULIB_ENVIRON
1117 GNULIB_DUP3
1118 GNULIB_DUP2
1119 GNULIB_DUP
1120 GNULIB_CLOSE
1121 GNULIB_CHOWN
1122 GNULIB_CHDIR
1123 LIB_CLOCK_GETTIME
1124 GL_GENERATE_ALLOCA_H_FALSE
1125 GL_GENERATE_ALLOCA_H_TRUE
1126 ALLOCA_H
1127 ALLOCA
1128 GL_COND_LIBTOOL_FALSE
1129 GL_COND_LIBTOOL_TRUE
1130 POST_ALLOC_OBJ
1131 PRE_ALLOC_OBJ
1132 CYGWIN_OBJ
1133 RALLOC_OBJ
1134 OLDXMENU_DEPS
1135 LIBX_OTHER
1136 LIBXMENU
1137 OLDXMENU
1138 OLDXMENU_TARGET
1139 LIBXT_OTHER
1140 TOOLKIT_LIBW
1141 WIDGET_OBJ
1142 XOBJ
1143 XMENU_OBJ
1144 FONT_OBJ
1145 OTHER_FILES
1146 GNU_OBJC_CFLAGS
1147 ns_appsrc
1148 ns_appresdir
1149 ns_appbindir
1150 ns_appdir
1151 X_TOOLKIT_TYPE
1152 GNUSTEP_CFLAGS
1153 C_SWITCH_X_SITE
1154 LD_SWITCH_X_SITE
1155 gameuser
1156 gamedir
1157 bitmapdir
1158 archlibdir
1159 etcdir
1160 x_default_search_path
1161 lisppath
1162 locallisppath
1163 standardlisppath
1164 leimdir
1165 lispdir
1166 srcdir
1167 canonical
1168 configuration
1169 version
1170 copyright
1171 KRB4LIB
1172 DESLIB
1173 KRB5LIB
1174 CRYPTOLIB
1175 COM_ERRLIB
1176 LIBRESOLV
1177 LIBHESIOD
1178 TERMCAP_OBJ
1179 LIBS_TERMCAP
1180 BLESSMAIL_TARGET
1181 LIBS_MAIL
1182 liblockfile
1183 LIBXML2_LIBS
1184 LIBXML2_CFLAGS
1185 LIBXSM
1186 LIBGPM
1187 LIBGIF
1188 LIBTIFF
1189 LIBPNG
1190 LIBJPEG
1191 LIBXPM
1192 M17N_FLT_LIBS
1193 M17N_FLT_CFLAGS
1194 LIBOTF_LIBS
1195 LIBOTF_CFLAGS
1196 FREETYPE_LIBS
1197 FREETYPE_CFLAGS
1198 XFT_LIBS
1199 XFT_CFLAGS
1200 FONTCONFIG_LIBS
1201 FONTCONFIG_CFLAGS
1202 LIBXMU
1203 LIBXTR6
1204 LIBACL_LIBS
1205 LIBGNUTLS_LIBS
1206 LIBGNUTLS_CFLAGS
1207 LIBSELINUX_LIBS
1208 SETTINGS_LIBS
1209 SETTINGS_CFLAGS
1210 GOBJECT_LIBS
1211 GOBJECT_CFLAGS
1212 GCONF_LIBS
1213 GCONF_CFLAGS
1214 GSETTINGS_LIBS
1215 GSETTINGS_CFLAGS
1216 DBUS_OBJ
1217 DBUS_LIBS
1218 DBUS_CFLAGS
1219 GTK_OBJ
1220 GTK_LIBS
1221 GTK_CFLAGS
1222 IMAGEMAGICK_LIBS
1223 IMAGEMAGICK_CFLAGS
1224 RSVG_LIBS
1225 RSVG_CFLAGS
1226 LIB_PTHREAD
1227 VMLIMIT_OBJ
1228 GMALLOC_OBJ
1229 HAVE_XSERVER
1230 W32_RES_LINK
1231 W32_RES
1232 W32_LIBS
1233 W32_OBJ
1234 WINDRES
1235 LIB_STANDARD
1236 NS_OBJC_OBJ
1237 NS_OBJ
1238 ns_self_contained
1239 INSTALL_ARCH_INDEP_EXTRA
1240 TEMACS_LDFLAGS2
1241 LD_SWITCH_X_SITE_RPATH
1242 XMKMF
1243 DEPFLAGS
1244 MKDEPDIR
1245 CFLAGS_SOUND
1246 ALSA_LIBS
1247 ALSA_CFLAGS
1248 LIBSOUND
1249 PKG_CONFIG
1250 CRT_DIR
1251 START_FILES
1252 LIB_MATH
1253 LIBS_SYSTEM
1254 C_SWITCH_SYSTEM
1255 UNEXEC_OBJ
1256 C_SWITCH_MACHINE
1257 LD_SWITCH_SYSTEM
1258 CANNOT_DUMP
1259 INFO_OPTS
1260 INFO_EXT
1261 HAVE_MAKEINFO
1262 PAXCTL
1263 GZIP_PROG
1264 INSTALL_INFO
1265 LN_S
1266 GNULIB_WARN_CFLAGS
1267 WARN_CFLAGS
1268 WERROR_CFLAGS
1269 RANLIB
1270 ARFLAGS
1272 EGREP
1273 GREP
1275 am__fastdepCC_FALSE
1276 am__fastdepCC_TRUE
1277 CCDEPMODE
1278 AMDEPBACKSLASH
1279 AMDEP_FALSE
1280 AMDEP_TRUE
1281 am__quote
1282 am__include
1283 DEPDIR
1284 OBJEXT
1285 EXEEXT
1286 ac_ct_CC
1287 CPPFLAGS
1288 LDFLAGS
1289 CFLAGS
1291 host_os
1292 host_vendor
1293 host_cpu
1294 host
1295 build_os
1296 build_vendor
1297 build_cpu
1298 build
1299 PROFILING_CFLAGS
1300 GZIP_INFO
1301 cache_file
1302 am__untar
1303 am__tar
1304 AMTAR
1305 am__leading_dot
1306 SET_MAKE
1308 mkdir_p
1309 MKDIR_P
1310 INSTALL_STRIP_PROGRAM
1311 STRIP
1312 install_sh
1313 MAKEINFO
1314 AUTOHEADER
1315 AUTOMAKE
1316 AUTOCONF
1317 ACLOCAL
1318 VERSION
1319 PACKAGE
1320 CYGPATH_W
1321 am__isrc
1322 INSTALL_DATA
1323 INSTALL_SCRIPT
1324 INSTALL_PROGRAM
1325 target_alias
1326 host_alias
1327 build_alias
1328 LIBS
1329 ECHO_T
1330 ECHO_N
1331 ECHO_C
1332 DEFS
1333 mandir
1334 localedir
1335 libdir
1336 psdir
1337 pdfdir
1338 dvidir
1339 htmldir
1340 infodir
1341 docdir
1342 oldincludedir
1343 includedir
1344 localstatedir
1345 sharedstatedir
1346 sysconfdir
1347 datadir
1348 datarootdir
1349 libexecdir
1350 sbindir
1351 bindir
1352 program_transform_name
1353 prefix
1354 exec_prefix
1355 PACKAGE_URL
1356 PACKAGE_BUGREPORT
1357 PACKAGE_STRING
1358 PACKAGE_VERSION
1359 PACKAGE_TARNAME
1360 PACKAGE_NAME
1361 PATH_SEPARATOR
1362 SHELL'
1363 ac_subst_files='deps_frag
1364 lisp_frag'
1365 ac_user_opts='
1366 enable_option_checking
1367 with_all
1368 with_pop
1369 with_kerberos
1370 with_kerberos5
1371 with_hesiod
1372 with_mmdf
1373 with_mail_unlink
1374 with_mailhost
1375 with_sound
1376 with_x_toolkit
1377 with_wide_int
1378 with_xpm
1379 with_jpeg
1380 with_tiff
1381 with_gif
1382 with_png
1383 with_rsvg
1384 with_xml2
1385 with_imagemagick
1386 with_xft
1387 with_libotf
1388 with_m17n_flt
1389 with_toolkit_scroll_bars
1390 with_xaw3d
1391 with_xim
1392 with_ns
1393 with_w32
1394 with_gpm
1395 with_dbus
1396 with_gconf
1397 with_gsettings
1398 with_selinux
1399 with_acl
1400 with_gnutls
1401 with_inotify
1402 with_makeinfo
1403 with_compress_info
1404 with_pkg_config_prog
1405 with_crt_dir
1406 with_gameuser
1407 with_gnustep_conf
1408 enable_ns_self_contained
1409 enable_locallisppath
1410 enable_checking
1411 enable_check_lisp_object_type
1412 enable_profiling
1413 enable_autodepend
1414 enable_dependency_tracking
1415 enable_largefile
1416 enable_gcc_warnings
1417 enable_link_time_optimization
1418 with_x
1420 ac_precious_vars='build_alias
1421 host_alias
1422 target_alias
1424 CFLAGS
1425 LDFLAGS
1426 LIBS
1427 CPPFLAGS
1429 XMKMF'
1432 # Initialize some variables set by options.
1433 ac_init_help=
1434 ac_init_version=false
1435 ac_unrecognized_opts=
1436 ac_unrecognized_sep=
1437 # The variables have the same names as the options, with
1438 # dashes changed to underlines.
1439 cache_file=/dev/null
1440 exec_prefix=NONE
1441 no_create=
1442 no_recursion=
1443 prefix=NONE
1444 program_prefix=NONE
1445 program_suffix=NONE
1446 program_transform_name=s,x,x,
1447 silent=
1448 site=
1449 srcdir=
1450 verbose=
1451 x_includes=NONE
1452 x_libraries=NONE
1454 # Installation directory options.
1455 # These are left unexpanded so users can "make install exec_prefix=/foo"
1456 # and all the variables that are supposed to be based on exec_prefix
1457 # by default will actually change.
1458 # Use braces instead of parens because sh, perl, etc. also accept them.
1459 # (The list follows the same order as the GNU Coding Standards.)
1460 bindir='${exec_prefix}/bin'
1461 sbindir='${exec_prefix}/sbin'
1462 libexecdir='${exec_prefix}/libexec'
1463 datarootdir='${prefix}/share'
1464 datadir='${datarootdir}'
1465 sysconfdir='${prefix}/etc'
1466 sharedstatedir='${prefix}/com'
1467 localstatedir='${prefix}/var'
1468 includedir='${prefix}/include'
1469 oldincludedir='/usr/include'
1470 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1471 infodir='${datarootdir}/info'
1472 htmldir='${docdir}'
1473 dvidir='${docdir}'
1474 pdfdir='${docdir}'
1475 psdir='${docdir}'
1476 libdir='${exec_prefix}/lib'
1477 localedir='${datarootdir}/locale'
1478 mandir='${datarootdir}/man'
1480 ac_prev=
1481 ac_dashdash=
1482 for ac_option
1484 # If the previous option needs an argument, assign it.
1485 if test -n "$ac_prev"; then
1486 eval $ac_prev=\$ac_option
1487 ac_prev=
1488 continue
1491 case $ac_option in
1492 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1493 *) ac_optarg=yes ;;
1494 esac
1496 # Accept the important Cygnus configure options, so we can diagnose typos.
1498 case $ac_dashdash$ac_option in
1500 ac_dashdash=yes ;;
1502 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1503 ac_prev=bindir ;;
1504 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1505 bindir=$ac_optarg ;;
1507 -build | --build | --buil | --bui | --bu)
1508 ac_prev=build_alias ;;
1509 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1510 build_alias=$ac_optarg ;;
1512 -cache-file | --cache-file | --cache-fil | --cache-fi \
1513 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1514 ac_prev=cache_file ;;
1515 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1516 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1517 cache_file=$ac_optarg ;;
1519 --config-cache | -C)
1520 cache_file=config.cache ;;
1522 -datadir | --datadir | --datadi | --datad)
1523 ac_prev=datadir ;;
1524 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1525 datadir=$ac_optarg ;;
1527 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1528 | --dataroo | --dataro | --datar)
1529 ac_prev=datarootdir ;;
1530 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1531 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1532 datarootdir=$ac_optarg ;;
1534 -disable-* | --disable-*)
1535 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1536 # Reject names that are not valid shell variable names.
1537 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1538 as_fn_error "invalid feature name: $ac_useropt"
1539 ac_useropt_orig=$ac_useropt
1540 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1541 case $ac_user_opts in
1543 "enable_$ac_useropt"
1544 "*) ;;
1545 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1546 ac_unrecognized_sep=', ';;
1547 esac
1548 eval enable_$ac_useropt=no ;;
1550 -docdir | --docdir | --docdi | --doc | --do)
1551 ac_prev=docdir ;;
1552 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1553 docdir=$ac_optarg ;;
1555 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1556 ac_prev=dvidir ;;
1557 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1558 dvidir=$ac_optarg ;;
1560 -enable-* | --enable-*)
1561 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1562 # Reject names that are not valid shell variable names.
1563 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1564 as_fn_error "invalid feature name: $ac_useropt"
1565 ac_useropt_orig=$ac_useropt
1566 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1567 case $ac_user_opts in
1569 "enable_$ac_useropt"
1570 "*) ;;
1571 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1572 ac_unrecognized_sep=', ';;
1573 esac
1574 eval enable_$ac_useropt=\$ac_optarg ;;
1576 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1577 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1578 | --exec | --exe | --ex)
1579 ac_prev=exec_prefix ;;
1580 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1581 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1582 | --exec=* | --exe=* | --ex=*)
1583 exec_prefix=$ac_optarg ;;
1585 -gas | --gas | --ga | --g)
1586 # Obsolete; use --with-gas.
1587 with_gas=yes ;;
1589 -help | --help | --hel | --he | -h)
1590 ac_init_help=long ;;
1591 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1592 ac_init_help=recursive ;;
1593 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1594 ac_init_help=short ;;
1596 -host | --host | --hos | --ho)
1597 ac_prev=host_alias ;;
1598 -host=* | --host=* | --hos=* | --ho=*)
1599 host_alias=$ac_optarg ;;
1601 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1602 ac_prev=htmldir ;;
1603 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1604 | --ht=*)
1605 htmldir=$ac_optarg ;;
1607 -includedir | --includedir | --includedi | --included | --include \
1608 | --includ | --inclu | --incl | --inc)
1609 ac_prev=includedir ;;
1610 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1611 | --includ=* | --inclu=* | --incl=* | --inc=*)
1612 includedir=$ac_optarg ;;
1614 -infodir | --infodir | --infodi | --infod | --info | --inf)
1615 ac_prev=infodir ;;
1616 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1617 infodir=$ac_optarg ;;
1619 -libdir | --libdir | --libdi | --libd)
1620 ac_prev=libdir ;;
1621 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1622 libdir=$ac_optarg ;;
1624 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1625 | --libexe | --libex | --libe)
1626 ac_prev=libexecdir ;;
1627 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1628 | --libexe=* | --libex=* | --libe=*)
1629 libexecdir=$ac_optarg ;;
1631 -localedir | --localedir | --localedi | --localed | --locale)
1632 ac_prev=localedir ;;
1633 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1634 localedir=$ac_optarg ;;
1636 -localstatedir | --localstatedir | --localstatedi | --localstated \
1637 | --localstate | --localstat | --localsta | --localst | --locals)
1638 ac_prev=localstatedir ;;
1639 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1640 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1641 localstatedir=$ac_optarg ;;
1643 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1644 ac_prev=mandir ;;
1645 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1646 mandir=$ac_optarg ;;
1648 -nfp | --nfp | --nf)
1649 # Obsolete; use --without-fp.
1650 with_fp=no ;;
1652 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1653 | --no-cr | --no-c | -n)
1654 no_create=yes ;;
1656 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1657 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1658 no_recursion=yes ;;
1660 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1661 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1662 | --oldin | --oldi | --old | --ol | --o)
1663 ac_prev=oldincludedir ;;
1664 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1665 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1666 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1667 oldincludedir=$ac_optarg ;;
1669 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1670 ac_prev=prefix ;;
1671 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1672 prefix=$ac_optarg ;;
1674 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1675 | --program-pre | --program-pr | --program-p)
1676 ac_prev=program_prefix ;;
1677 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1678 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1679 program_prefix=$ac_optarg ;;
1681 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1682 | --program-suf | --program-su | --program-s)
1683 ac_prev=program_suffix ;;
1684 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1685 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1686 program_suffix=$ac_optarg ;;
1688 -program-transform-name | --program-transform-name \
1689 | --program-transform-nam | --program-transform-na \
1690 | --program-transform-n | --program-transform- \
1691 | --program-transform | --program-transfor \
1692 | --program-transfo | --program-transf \
1693 | --program-trans | --program-tran \
1694 | --progr-tra | --program-tr | --program-t)
1695 ac_prev=program_transform_name ;;
1696 -program-transform-name=* | --program-transform-name=* \
1697 | --program-transform-nam=* | --program-transform-na=* \
1698 | --program-transform-n=* | --program-transform-=* \
1699 | --program-transform=* | --program-transfor=* \
1700 | --program-transfo=* | --program-transf=* \
1701 | --program-trans=* | --program-tran=* \
1702 | --progr-tra=* | --program-tr=* | --program-t=*)
1703 program_transform_name=$ac_optarg ;;
1705 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1706 ac_prev=pdfdir ;;
1707 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1708 pdfdir=$ac_optarg ;;
1710 -psdir | --psdir | --psdi | --psd | --ps)
1711 ac_prev=psdir ;;
1712 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1713 psdir=$ac_optarg ;;
1715 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1716 | -silent | --silent | --silen | --sile | --sil)
1717 silent=yes ;;
1719 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1720 ac_prev=sbindir ;;
1721 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1722 | --sbi=* | --sb=*)
1723 sbindir=$ac_optarg ;;
1725 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1726 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1727 | --sharedst | --shareds | --shared | --share | --shar \
1728 | --sha | --sh)
1729 ac_prev=sharedstatedir ;;
1730 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1731 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1732 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1733 | --sha=* | --sh=*)
1734 sharedstatedir=$ac_optarg ;;
1736 -site | --site | --sit)
1737 ac_prev=site ;;
1738 -site=* | --site=* | --sit=*)
1739 site=$ac_optarg ;;
1741 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1742 ac_prev=srcdir ;;
1743 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1744 srcdir=$ac_optarg ;;
1746 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1747 | --syscon | --sysco | --sysc | --sys | --sy)
1748 ac_prev=sysconfdir ;;
1749 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1750 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1751 sysconfdir=$ac_optarg ;;
1753 -target | --target | --targe | --targ | --tar | --ta | --t)
1754 ac_prev=target_alias ;;
1755 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1756 target_alias=$ac_optarg ;;
1758 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1759 verbose=yes ;;
1761 -version | --version | --versio | --versi | --vers | -V)
1762 ac_init_version=: ;;
1764 -with-* | --with-*)
1765 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1766 # Reject names that are not valid shell variable names.
1767 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1768 as_fn_error "invalid package name: $ac_useropt"
1769 ac_useropt_orig=$ac_useropt
1770 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1771 case $ac_user_opts in
1773 "with_$ac_useropt"
1774 "*) ;;
1775 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1776 ac_unrecognized_sep=', ';;
1777 esac
1778 eval with_$ac_useropt=\$ac_optarg ;;
1780 -without-* | --without-*)
1781 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1782 # Reject names that are not valid shell variable names.
1783 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1784 as_fn_error "invalid package name: $ac_useropt"
1785 ac_useropt_orig=$ac_useropt
1786 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1787 case $ac_user_opts in
1789 "with_$ac_useropt"
1790 "*) ;;
1791 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1792 ac_unrecognized_sep=', ';;
1793 esac
1794 eval with_$ac_useropt=no ;;
1796 --x)
1797 # Obsolete; use --with-x.
1798 with_x=yes ;;
1800 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1801 | --x-incl | --x-inc | --x-in | --x-i)
1802 ac_prev=x_includes ;;
1803 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1804 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1805 x_includes=$ac_optarg ;;
1807 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1808 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1809 ac_prev=x_libraries ;;
1810 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1811 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1812 x_libraries=$ac_optarg ;;
1814 -*) as_fn_error "unrecognized option: \`$ac_option'
1815 Try \`$0 --help' for more information."
1818 *=*)
1819 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1820 # Reject names that are not valid shell variable names.
1821 case $ac_envvar in #(
1822 '' | [0-9]* | *[!_$as_cr_alnum]* )
1823 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1824 esac
1825 eval $ac_envvar=\$ac_optarg
1826 export $ac_envvar ;;
1829 # FIXME: should be removed in autoconf 3.0.
1830 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1831 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1832 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1833 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1836 esac
1837 done
1839 if test -n "$ac_prev"; then
1840 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1841 as_fn_error "missing argument to $ac_option"
1844 if test -n "$ac_unrecognized_opts"; then
1845 case $enable_option_checking in
1846 no) ;;
1847 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1848 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1849 esac
1852 # Check all directory arguments for consistency.
1853 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1854 datadir sysconfdir sharedstatedir localstatedir includedir \
1855 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1856 libdir localedir mandir
1858 eval ac_val=\$$ac_var
1859 # Remove trailing slashes.
1860 case $ac_val in
1861 */ )
1862 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1863 eval $ac_var=\$ac_val;;
1864 esac
1865 # Be sure to have absolute directory names.
1866 case $ac_val in
1867 [\\/$]* | ?:[\\/]* ) continue;;
1868 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1869 esac
1870 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1871 done
1873 # There might be people who depend on the old broken behavior: `$host'
1874 # used to hold the argument of --host etc.
1875 # FIXME: To remove some day.
1876 build=$build_alias
1877 host=$host_alias
1878 target=$target_alias
1880 # FIXME: To remove some day.
1881 if test "x$host_alias" != x; then
1882 if test "x$build_alias" = x; then
1883 cross_compiling=maybe
1884 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1885 If a cross compiler is detected then cross compile mode will be used." >&2
1886 elif test "x$build_alias" != "x$host_alias"; then
1887 cross_compiling=yes
1891 ac_tool_prefix=
1892 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1894 test "$silent" = yes && exec 6>/dev/null
1897 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1898 ac_ls_di=`ls -di .` &&
1899 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1900 as_fn_error "working directory cannot be determined"
1901 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1902 as_fn_error "pwd does not report name of working directory"
1905 # Find the source files, if location was not specified.
1906 if test -z "$srcdir"; then
1907 ac_srcdir_defaulted=yes
1908 # Try the directory containing this script, then the parent directory.
1909 ac_confdir=`$as_dirname -- "$as_myself" ||
1910 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1911 X"$as_myself" : 'X\(//\)[^/]' \| \
1912 X"$as_myself" : 'X\(//\)$' \| \
1913 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1914 $as_echo X"$as_myself" |
1915 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1916 s//\1/
1919 /^X\(\/\/\)[^/].*/{
1920 s//\1/
1923 /^X\(\/\/\)$/{
1924 s//\1/
1927 /^X\(\/\).*/{
1928 s//\1/
1931 s/.*/./; q'`
1932 srcdir=$ac_confdir
1933 if test ! -r "$srcdir/$ac_unique_file"; then
1934 srcdir=..
1936 else
1937 ac_srcdir_defaulted=no
1939 if test ! -r "$srcdir/$ac_unique_file"; then
1940 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1941 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1943 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1944 ac_abs_confdir=`(
1945 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1946 pwd)`
1947 # When building in place, set srcdir=.
1948 if test "$ac_abs_confdir" = "$ac_pwd"; then
1949 srcdir=.
1951 # Remove unnecessary trailing slashes from srcdir.
1952 # Double slashes in file names in object file debugging info
1953 # mess up M-x gdb in Emacs.
1954 case $srcdir in
1955 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1956 esac
1957 for ac_var in $ac_precious_vars; do
1958 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1959 eval ac_env_${ac_var}_value=\$${ac_var}
1960 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1961 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1962 done
1965 # Report the --help message.
1967 if test "$ac_init_help" = "long"; then
1968 # Omit some internal or obsolete options to make the list less imposing.
1969 # This message is too long to be a string in the A/UX 3.1 sh.
1970 cat <<_ACEOF
1971 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
1973 Usage: $0 [OPTION]... [VAR=VALUE]...
1975 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1976 VAR=VALUE. See below for descriptions of some of the useful variables.
1978 Defaults for the options are specified in brackets.
1980 Configuration:
1981 -h, --help display this help and exit
1982 --help=short display options specific to this package
1983 --help=recursive display the short help of all the included packages
1984 -V, --version display version information and exit
1985 -q, --quiet, --silent do not print \`checking...' messages
1986 --cache-file=FILE cache test results in FILE [disabled]
1987 -C, --config-cache alias for \`--cache-file=config.cache'
1988 -n, --no-create do not create output files
1989 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1991 Installation directories:
1992 --prefix=PREFIX install architecture-independent files in PREFIX
1993 [$ac_default_prefix]
1994 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1995 [PREFIX]
1997 By default, \`make install' will install all the files in
1998 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1999 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2000 for instance \`--prefix=\$HOME'.
2002 For better control, use the options below.
2004 Fine tuning of the installation directories:
2005 --bindir=DIR user executables [EPREFIX/bin]
2006 --sbindir=DIR system admin executables [EPREFIX/sbin]
2007 --libexecdir=DIR program executables [EPREFIX/libexec]
2008 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2009 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2010 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2011 --libdir=DIR object code libraries [EPREFIX/lib]
2012 --includedir=DIR C header files [PREFIX/include]
2013 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2014 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2015 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2016 --infodir=DIR info documentation [DATAROOTDIR/info]
2017 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2018 --mandir=DIR man documentation [DATAROOTDIR/man]
2019 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2020 --htmldir=DIR html documentation [DOCDIR]
2021 --dvidir=DIR dvi documentation [DOCDIR]
2022 --pdfdir=DIR pdf documentation [DOCDIR]
2023 --psdir=DIR ps documentation [DOCDIR]
2024 _ACEOF
2026 cat <<\_ACEOF
2028 Program names:
2029 --program-prefix=PREFIX prepend PREFIX to installed program names
2030 --program-suffix=SUFFIX append SUFFIX to installed program names
2031 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2033 X features:
2034 --x-includes=DIR X include files are in DIR
2035 --x-libraries=DIR X library files are in DIR
2037 System types:
2038 --build=BUILD configure for building on BUILD [guessed]
2039 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2040 _ACEOF
2043 if test -n "$ac_init_help"; then
2044 case $ac_init_help in
2045 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2046 esac
2047 cat <<\_ACEOF
2049 Optional Features:
2050 --disable-option-checking ignore unrecognized --enable/--with options
2051 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2052 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2053 --disable-ns-self-contained
2054 disable self contained build under NeXTstep
2055 --enable-locallisppath=PATH
2056 directories Emacs should search for lisp files
2057 specific to this site
2058 --enable-checking[=LIST]
2059 enable expensive run-time checks. With LIST, enable
2060 only specific categories of checks. Categories are:
2061 all,yes,no. Flags are: stringbytes, stringoverrun,
2062 stringfreelist, xmallocoverrun, conslist, glyphs
2063 --enable-check-lisp-object-type
2064 enable compile time checks for the Lisp_Object data
2065 type. This is useful for development for catching
2066 certain types of bugs.
2067 --enable-profiling build emacs with low-level, gprof profiling support.
2068 Mainly useful for debugging Emacs itself. May not
2069 work on all platforms. Stops profiler.el working.
2070 --enable-autodepend automatically generate dependencies to .h-files.
2071 Requires GNU Make and Gcc. Enabled if GNU Make and
2072 Gcc is found
2073 --disable-dependency-tracking speeds up one-time build
2074 --enable-dependency-tracking do not reject slow dependency extractors
2075 --disable-largefile omit support for large files
2076 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2077 developers, and may generate false alarms when used
2078 with older or non-GNU development tools.
2079 --enable-link-time-optimization
2080 build emacs with link-time optimization. This is
2081 supported only for GCC since 4.5.0.
2083 Optional Packages:
2084 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2085 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2086 --without-all omit almost all features and build small executable
2087 with minimal dependencies
2088 --without-pop don't support POP mail retrieval with movemail
2089 --with-kerberos support Kerberos-authenticated POP
2090 --with-kerberos5 support Kerberos version 5 authenticated POP
2091 --with-hesiod support Hesiod to get the POP server host
2092 --with-mmdf support MMDF mailboxes
2093 --with-mail-unlink unlink, rather than empty, mail spool after reading
2094 --with-mailhost=HOSTNAME
2095 string giving default POP mail host
2096 --without-sound don't compile with sound support
2097 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2098 gtk3, lucid or athena, motif, no)
2099 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2100 --without-xpm don't compile with XPM image support
2101 --without-jpeg don't compile with JPEG image support
2102 --without-tiff don't compile with TIFF image support
2103 --without-gif don't compile with GIF image support
2104 --without-png don't compile with PNG image support
2105 --without-rsvg don't compile with SVG image support
2106 --without-xml2 don't compile with XML parsing support
2107 --without-imagemagick don't compile with ImageMagick image support
2108 --without-xft don't use XFT for anti aliased fonts
2109 --without-libotf don't use libotf for OpenType font support
2110 --without-m17n-flt don't use m17n-flt for text shaping
2111 --without-toolkit-scroll-bars
2112 don't use Motif or Xaw3d scroll bars
2113 --without-xaw3d don't use Xaw3d
2114 --without-xim don't use X11 XIM
2115 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2116 --with-w32 use native MS Windows GUI
2117 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2118 console
2119 --without-dbus don't compile with D-Bus support
2120 --without-gconf don't compile with GConf support
2121 --without-gsettings don't compile with GSettings support
2122 --without-selinux don't compile with SELinux support
2123 --without-acl don't compile with ACL support
2124 --without-gnutls don't use -lgnutls for SSL/TLS support
2125 --without-inotify don't compile with inotify (file-watch) support
2126 --without-makeinfo don't require makeinfo for building manuals
2127 --without-compress-info don't compress the installed Info pages
2128 --with-pkg-config-prog=FILENAME
2129 file name of pkg-config for finding GTK and librsvg
2130 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2131 /usr/lib, or /usr/lib64 on some platforms.
2132 --with-gameuser=USER user for shared game score files
2133 --with-gnustep-conf=FILENAME
2134 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2135 or /etc/GNUstep/GNUstep.conf
2136 --with-x use the X Window System
2138 Some influential environment variables:
2139 CC C compiler command
2140 CFLAGS C compiler flags
2141 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2142 nonstandard directory <lib dir>
2143 LIBS libraries to pass to the linker, e.g. -l<library>
2144 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2145 you have headers in a nonstandard directory <include dir>
2146 CPP C preprocessor
2147 XMKMF Path to xmkmf, Makefile generator for X Window System
2149 Use these variables to override the choices made by `configure' or to help
2150 it to find libraries and programs with nonstandard names/locations.
2152 Report bugs to the package provider.
2153 _ACEOF
2154 ac_status=$?
2157 if test "$ac_init_help" = "recursive"; then
2158 # If there are subdirs, report their specific --help.
2159 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2160 test -d "$ac_dir" ||
2161 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2162 continue
2163 ac_builddir=.
2165 case "$ac_dir" in
2166 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2168 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2169 # A ".." for each directory in $ac_dir_suffix.
2170 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2171 case $ac_top_builddir_sub in
2172 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2173 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2174 esac ;;
2175 esac
2176 ac_abs_top_builddir=$ac_pwd
2177 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2178 # for backward compatibility:
2179 ac_top_builddir=$ac_top_build_prefix
2181 case $srcdir in
2182 .) # We are building in place.
2183 ac_srcdir=.
2184 ac_top_srcdir=$ac_top_builddir_sub
2185 ac_abs_top_srcdir=$ac_pwd ;;
2186 [\\/]* | ?:[\\/]* ) # Absolute name.
2187 ac_srcdir=$srcdir$ac_dir_suffix;
2188 ac_top_srcdir=$srcdir
2189 ac_abs_top_srcdir=$srcdir ;;
2190 *) # Relative name.
2191 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2192 ac_top_srcdir=$ac_top_build_prefix$srcdir
2193 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2194 esac
2195 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2197 cd "$ac_dir" || { ac_status=$?; continue; }
2198 # Check for guested configure.
2199 if test -f "$ac_srcdir/configure.gnu"; then
2200 echo &&
2201 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2202 elif test -f "$ac_srcdir/configure"; then
2203 echo &&
2204 $SHELL "$ac_srcdir/configure" --help=recursive
2205 else
2206 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2207 fi || ac_status=$?
2208 cd "$ac_pwd" || { ac_status=$?; break; }
2209 done
2212 test -n "$ac_init_help" && exit $ac_status
2213 if $ac_init_version; then
2214 cat <<\_ACEOF
2215 emacs configure 24.3.50
2216 generated by GNU Autoconf 2.65
2218 Copyright (C) 2009 Free Software Foundation, Inc.
2219 This configure script is free software; the Free Software Foundation
2220 gives unlimited permission to copy, distribute and modify it.
2221 _ACEOF
2222 exit
2225 ## ------------------------ ##
2226 ## Autoconf initialization. ##
2227 ## ------------------------ ##
2229 # ac_fn_c_try_compile LINENO
2230 # --------------------------
2231 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2232 ac_fn_c_try_compile ()
2234 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2235 rm -f conftest.$ac_objext
2236 if { { ac_try="$ac_compile"
2237 case "(($ac_try" in
2238 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2239 *) ac_try_echo=$ac_try;;
2240 esac
2241 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2242 $as_echo "$ac_try_echo"; } >&5
2243 (eval "$ac_compile") 2>conftest.err
2244 ac_status=$?
2245 if test -s conftest.err; then
2246 grep -v '^ *+' conftest.err >conftest.er1
2247 cat conftest.er1 >&5
2248 mv -f conftest.er1 conftest.err
2250 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2251 test $ac_status = 0; } && {
2252 test -z "$ac_c_werror_flag" ||
2253 test ! -s conftest.err
2254 } && test -s conftest.$ac_objext; then :
2255 ac_retval=0
2256 else
2257 $as_echo "$as_me: failed program was:" >&5
2258 sed 's/^/| /' conftest.$ac_ext >&5
2260 ac_retval=1
2262 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2263 as_fn_set_status $ac_retval
2265 } # ac_fn_c_try_compile
2267 # ac_fn_c_try_cpp LINENO
2268 # ----------------------
2269 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2270 ac_fn_c_try_cpp ()
2272 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2273 if { { ac_try="$ac_cpp conftest.$ac_ext"
2274 case "(($ac_try" in
2275 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2276 *) ac_try_echo=$ac_try;;
2277 esac
2278 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2279 $as_echo "$ac_try_echo"; } >&5
2280 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2281 ac_status=$?
2282 if test -s conftest.err; then
2283 grep -v '^ *+' conftest.err >conftest.er1
2284 cat conftest.er1 >&5
2285 mv -f conftest.er1 conftest.err
2287 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2288 test $ac_status = 0; } >/dev/null && {
2289 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2290 test ! -s conftest.err
2291 }; then :
2292 ac_retval=0
2293 else
2294 $as_echo "$as_me: failed program was:" >&5
2295 sed 's/^/| /' conftest.$ac_ext >&5
2297 ac_retval=1
2299 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2300 as_fn_set_status $ac_retval
2302 } # ac_fn_c_try_cpp
2304 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2305 # -------------------------------------------------------
2306 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2307 # the include files in INCLUDES and setting the cache variable VAR
2308 # accordingly.
2309 ac_fn_c_check_header_mongrel ()
2311 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2312 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2314 $as_echo_n "checking for $2... " >&6; }
2315 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2316 $as_echo_n "(cached) " >&6
2318 eval ac_res=\$$3
2319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2320 $as_echo "$ac_res" >&6; }
2321 else
2322 # Is the header compilable?
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2324 $as_echo_n "checking $2 usability... " >&6; }
2325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2326 /* end confdefs.h. */
2328 #include <$2>
2329 _ACEOF
2330 if ac_fn_c_try_compile "$LINENO"; then :
2331 ac_header_compiler=yes
2332 else
2333 ac_header_compiler=no
2335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2337 $as_echo "$ac_header_compiler" >&6; }
2339 # Is the header present?
2340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2341 $as_echo_n "checking $2 presence... " >&6; }
2342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2343 /* end confdefs.h. */
2344 #include <$2>
2345 _ACEOF
2346 if ac_fn_c_try_cpp "$LINENO"; then :
2347 ac_header_preproc=yes
2348 else
2349 ac_header_preproc=no
2351 rm -f conftest.err conftest.$ac_ext
2352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2353 $as_echo "$ac_header_preproc" >&6; }
2355 # So? What about this header?
2356 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2357 yes:no: )
2358 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2359 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2360 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2361 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2363 no:yes:* )
2364 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2365 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2366 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2367 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2368 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2369 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2370 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2371 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2372 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2373 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2375 esac
2376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2377 $as_echo_n "checking for $2... " >&6; }
2378 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2379 $as_echo_n "(cached) " >&6
2380 else
2381 eval "$3=\$ac_header_compiler"
2383 eval ac_res=\$$3
2384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2385 $as_echo "$ac_res" >&6; }
2387 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2389 } # ac_fn_c_check_header_mongrel
2391 # ac_fn_c_try_run LINENO
2392 # ----------------------
2393 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2394 # that executables *can* be run.
2395 ac_fn_c_try_run ()
2397 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2398 if { { ac_try="$ac_link"
2399 case "(($ac_try" in
2400 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2401 *) ac_try_echo=$ac_try;;
2402 esac
2403 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2404 $as_echo "$ac_try_echo"; } >&5
2405 (eval "$ac_link") 2>&5
2406 ac_status=$?
2407 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2408 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2409 { { case "(($ac_try" in
2410 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2411 *) ac_try_echo=$ac_try;;
2412 esac
2413 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2414 $as_echo "$ac_try_echo"; } >&5
2415 (eval "$ac_try") 2>&5
2416 ac_status=$?
2417 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2418 test $ac_status = 0; }; }; then :
2419 ac_retval=0
2420 else
2421 $as_echo "$as_me: program exited with status $ac_status" >&5
2422 $as_echo "$as_me: failed program was:" >&5
2423 sed 's/^/| /' conftest.$ac_ext >&5
2425 ac_retval=$ac_status
2427 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2428 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2429 as_fn_set_status $ac_retval
2431 } # ac_fn_c_try_run
2433 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2434 # -------------------------------------------------------
2435 # Tests whether HEADER exists and can be compiled using the include files in
2436 # INCLUDES, setting the cache variable VAR accordingly.
2437 ac_fn_c_check_header_compile ()
2439 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2441 $as_echo_n "checking for $2... " >&6; }
2442 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2443 $as_echo_n "(cached) " >&6
2444 else
2445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2446 /* end confdefs.h. */
2448 #include <$2>
2449 _ACEOF
2450 if ac_fn_c_try_compile "$LINENO"; then :
2451 eval "$3=yes"
2452 else
2453 eval "$3=no"
2455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2457 eval ac_res=\$$3
2458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2459 $as_echo "$ac_res" >&6; }
2460 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2462 } # ac_fn_c_check_header_compile
2464 # ac_fn_c_try_link LINENO
2465 # -----------------------
2466 # Try to link conftest.$ac_ext, and return whether this succeeded.
2467 ac_fn_c_try_link ()
2469 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2470 rm -f conftest.$ac_objext conftest$ac_exeext
2471 if { { ac_try="$ac_link"
2472 case "(($ac_try" in
2473 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2474 *) ac_try_echo=$ac_try;;
2475 esac
2476 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2477 $as_echo "$ac_try_echo"; } >&5
2478 (eval "$ac_link") 2>conftest.err
2479 ac_status=$?
2480 if test -s conftest.err; then
2481 grep -v '^ *+' conftest.err >conftest.er1
2482 cat conftest.er1 >&5
2483 mv -f conftest.er1 conftest.err
2485 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2486 test $ac_status = 0; } && {
2487 test -z "$ac_c_werror_flag" ||
2488 test ! -s conftest.err
2489 } && test -s conftest$ac_exeext && {
2490 test "$cross_compiling" = yes ||
2491 $as_test_x conftest$ac_exeext
2492 }; then :
2493 ac_retval=0
2494 else
2495 $as_echo "$as_me: failed program was:" >&5
2496 sed 's/^/| /' conftest.$ac_ext >&5
2498 ac_retval=1
2500 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2501 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2502 # interfere with the next link command; also delete a directory that is
2503 # left behind by Apple's compiler. We do this before executing the actions.
2504 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2505 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2506 as_fn_set_status $ac_retval
2508 } # ac_fn_c_try_link
2510 # ac_fn_c_check_decl LINENO SYMBOL VAR
2511 # ------------------------------------
2512 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2513 ac_fn_c_check_decl ()
2515 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2517 $as_echo_n "checking whether $2 is declared... " >&6; }
2518 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2519 $as_echo_n "(cached) " >&6
2520 else
2521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2522 /* end confdefs.h. */
2525 main ()
2527 #ifndef $2
2528 (void) $2;
2529 #endif
2532 return 0;
2534 _ACEOF
2535 if ac_fn_c_try_compile "$LINENO"; then :
2536 eval "$3=yes"
2537 else
2538 eval "$3=no"
2540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2542 eval ac_res=\$$3
2543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2544 $as_echo "$ac_res" >&6; }
2545 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2547 } # ac_fn_c_check_decl
2549 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2550 # ----------------------------------------------
2551 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2552 ac_fn_c_check_header_preproc ()
2554 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2556 $as_echo_n "checking for $2... " >&6; }
2557 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2558 $as_echo_n "(cached) " >&6
2559 else
2560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2561 /* end confdefs.h. */
2562 #include <$2>
2563 _ACEOF
2564 if ac_fn_c_try_cpp "$LINENO"; then :
2565 eval "$3=yes"
2566 else
2567 eval "$3=no"
2569 rm -f conftest.err conftest.$ac_ext
2571 eval ac_res=\$$3
2572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2573 $as_echo "$ac_res" >&6; }
2574 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2576 } # ac_fn_c_check_header_preproc
2578 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2579 # ----------------------------------------------------
2580 # Tries to find if the field MEMBER exists in type AGGR, after including
2581 # INCLUDES, setting cache variable VAR accordingly.
2582 ac_fn_c_check_member ()
2584 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2586 $as_echo_n "checking for $2.$3... " >&6; }
2587 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2588 $as_echo_n "(cached) " >&6
2589 else
2590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2591 /* end confdefs.h. */
2594 main ()
2596 static $2 ac_aggr;
2597 if (ac_aggr.$3)
2598 return 0;
2600 return 0;
2602 _ACEOF
2603 if ac_fn_c_try_compile "$LINENO"; then :
2604 eval "$4=yes"
2605 else
2606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2607 /* end confdefs.h. */
2610 main ()
2612 static $2 ac_aggr;
2613 if (sizeof ac_aggr.$3)
2614 return 0;
2616 return 0;
2618 _ACEOF
2619 if ac_fn_c_try_compile "$LINENO"; then :
2620 eval "$4=yes"
2621 else
2622 eval "$4=no"
2624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2628 eval ac_res=\$$4
2629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2630 $as_echo "$ac_res" >&6; }
2631 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2633 } # ac_fn_c_check_member
2635 # ac_fn_c_check_func LINENO FUNC VAR
2636 # ----------------------------------
2637 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2638 ac_fn_c_check_func ()
2640 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2642 $as_echo_n "checking for $2... " >&6; }
2643 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2644 $as_echo_n "(cached) " >&6
2645 else
2646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2647 /* end confdefs.h. */
2648 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2649 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2650 #define $2 innocuous_$2
2652 /* System header to define __stub macros and hopefully few prototypes,
2653 which can conflict with char $2 (); below.
2654 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2655 <limits.h> exists even on freestanding compilers. */
2657 #ifdef __STDC__
2658 # include <limits.h>
2659 #else
2660 # include <assert.h>
2661 #endif
2663 #undef $2
2665 /* Override any GCC internal prototype to avoid an error.
2666 Use char because int might match the return type of a GCC
2667 builtin and then its argument prototype would still apply. */
2668 #ifdef __cplusplus
2669 extern "C"
2670 #endif
2671 char $2 ();
2672 /* The GNU C library defines this for functions which it implements
2673 to always fail with ENOSYS. Some functions are actually named
2674 something starting with __ and the normal name is an alias. */
2675 #if defined __stub_$2 || defined __stub___$2
2676 choke me
2677 #endif
2680 main ()
2682 return $2 ();
2684 return 0;
2686 _ACEOF
2687 if ac_fn_c_try_link "$LINENO"; then :
2688 eval "$3=yes"
2689 else
2690 eval "$3=no"
2692 rm -f core conftest.err conftest.$ac_objext \
2693 conftest$ac_exeext 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_func
2702 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2703 # -------------------------------------------
2704 # Tests whether TYPE exists after having included INCLUDES, setting cache
2705 # variable VAR accordingly.
2706 ac_fn_c_check_type ()
2708 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2710 $as_echo_n "checking for $2... " >&6; }
2711 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2712 $as_echo_n "(cached) " >&6
2713 else
2714 eval "$3=no"
2715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2716 /* end confdefs.h. */
2719 main ()
2721 if (sizeof ($2))
2722 return 0;
2724 return 0;
2726 _ACEOF
2727 if ac_fn_c_try_compile "$LINENO"; then :
2728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2729 /* end confdefs.h. */
2732 main ()
2734 if (sizeof (($2)))
2735 return 0;
2737 return 0;
2739 _ACEOF
2740 if ac_fn_c_try_compile "$LINENO"; then :
2742 else
2743 eval "$3=yes"
2745 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2749 eval ac_res=\$$3
2750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2751 $as_echo "$ac_res" >&6; }
2752 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2754 } # ac_fn_c_check_type
2756 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2757 # --------------------------------------------
2758 # Tries to find the compile-time value of EXPR in a program that includes
2759 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2760 # computed
2761 ac_fn_c_compute_int ()
2763 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2764 if test "$cross_compiling" = yes; then
2765 # Depending upon the size, compute the lo and hi bounds.
2766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2767 /* end confdefs.h. */
2770 main ()
2772 static int test_array [1 - 2 * !(($2) >= 0)];
2773 test_array [0] = 0
2776 return 0;
2778 _ACEOF
2779 if ac_fn_c_try_compile "$LINENO"; then :
2780 ac_lo=0 ac_mid=0
2781 while :; do
2782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2783 /* end confdefs.h. */
2786 main ()
2788 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2789 test_array [0] = 0
2792 return 0;
2794 _ACEOF
2795 if ac_fn_c_try_compile "$LINENO"; then :
2796 ac_hi=$ac_mid; break
2797 else
2798 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2799 if test $ac_lo -le $ac_mid; then
2800 ac_lo= ac_hi=
2801 break
2803 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2806 done
2807 else
2808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2809 /* end confdefs.h. */
2812 main ()
2814 static int test_array [1 - 2 * !(($2) < 0)];
2815 test_array [0] = 0
2818 return 0;
2820 _ACEOF
2821 if ac_fn_c_try_compile "$LINENO"; then :
2822 ac_hi=-1 ac_mid=-1
2823 while :; do
2824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2825 /* end confdefs.h. */
2828 main ()
2830 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2831 test_array [0] = 0
2834 return 0;
2836 _ACEOF
2837 if ac_fn_c_try_compile "$LINENO"; then :
2838 ac_lo=$ac_mid; break
2839 else
2840 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2841 if test $ac_mid -le $ac_hi; then
2842 ac_lo= ac_hi=
2843 break
2845 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2848 done
2849 else
2850 ac_lo= ac_hi=
2852 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2855 # Binary search between lo and hi bounds.
2856 while test "x$ac_lo" != "x$ac_hi"; do
2857 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2859 /* end confdefs.h. */
2862 main ()
2864 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2865 test_array [0] = 0
2868 return 0;
2870 _ACEOF
2871 if ac_fn_c_try_compile "$LINENO"; then :
2872 ac_hi=$ac_mid
2873 else
2874 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2877 done
2878 case $ac_lo in #((
2879 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2880 '') ac_retval=1 ;;
2881 esac
2882 else
2883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2884 /* end confdefs.h. */
2886 static long int longval () { return $2; }
2887 static unsigned long int ulongval () { return $2; }
2888 #include <stdio.h>
2889 #include <stdlib.h>
2891 main ()
2894 FILE *f = fopen ("conftest.val", "w");
2895 if (! f)
2896 return 1;
2897 if (($2) < 0)
2899 long int i = longval ();
2900 if (i != ($2))
2901 return 1;
2902 fprintf (f, "%ld", i);
2904 else
2906 unsigned long int i = ulongval ();
2907 if (i != ($2))
2908 return 1;
2909 fprintf (f, "%lu", i);
2911 /* Do not output a trailing newline, as this causes \r\n confusion
2912 on some platforms. */
2913 return ferror (f) || fclose (f) != 0;
2916 return 0;
2918 _ACEOF
2919 if ac_fn_c_try_run "$LINENO"; then :
2920 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2921 else
2922 ac_retval=1
2924 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2925 conftest.$ac_objext conftest.beam conftest.$ac_ext
2926 rm -f conftest.val
2929 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2930 as_fn_set_status $ac_retval
2932 } # ac_fn_c_compute_int
2933 cat >config.log <<_ACEOF
2934 This file contains any messages produced by compilers while
2935 running configure, to aid debugging if configure makes a mistake.
2937 It was created by emacs $as_me 24.3.50, which was
2938 generated by GNU Autoconf 2.65. Invocation command line was
2940 $ $0 $@
2942 _ACEOF
2943 exec 5>>config.log
2945 cat <<_ASUNAME
2946 ## --------- ##
2947 ## Platform. ##
2948 ## --------- ##
2950 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2951 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2952 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2953 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2954 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2956 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2957 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2959 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2960 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2961 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2962 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2963 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2964 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2965 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2967 _ASUNAME
2969 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2970 for as_dir in $PATH
2972 IFS=$as_save_IFS
2973 test -z "$as_dir" && as_dir=.
2974 $as_echo "PATH: $as_dir"
2975 done
2976 IFS=$as_save_IFS
2978 } >&5
2980 cat >&5 <<_ACEOF
2983 ## ----------- ##
2984 ## Core tests. ##
2985 ## ----------- ##
2987 _ACEOF
2990 # Keep a trace of the command line.
2991 # Strip out --no-create and --no-recursion so they do not pile up.
2992 # Strip out --silent because we don't want to record it for future runs.
2993 # Also quote any args containing shell meta-characters.
2994 # Make two passes to allow for proper duplicate-argument suppression.
2995 ac_configure_args=
2996 ac_configure_args0=
2997 ac_configure_args1=
2998 ac_must_keep_next=false
2999 for ac_pass in 1 2
3001 for ac_arg
3003 case $ac_arg in
3004 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3005 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3006 | -silent | --silent | --silen | --sile | --sil)
3007 continue ;;
3008 *\'*)
3009 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3010 esac
3011 case $ac_pass in
3012 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3014 as_fn_append ac_configure_args1 " '$ac_arg'"
3015 if test $ac_must_keep_next = true; then
3016 ac_must_keep_next=false # Got value, back to normal.
3017 else
3018 case $ac_arg in
3019 *=* | --config-cache | -C | -disable-* | --disable-* \
3020 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3021 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3022 | -with-* | --with-* | -without-* | --without-* | --x)
3023 case "$ac_configure_args0 " in
3024 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3025 esac
3027 -* ) ac_must_keep_next=true ;;
3028 esac
3030 as_fn_append ac_configure_args " '$ac_arg'"
3032 esac
3033 done
3034 done
3035 { ac_configure_args0=; unset ac_configure_args0;}
3036 { ac_configure_args1=; unset ac_configure_args1;}
3038 # When interrupted or exit'd, cleanup temporary files, and complete
3039 # config.log. We remove comments because anyway the quotes in there
3040 # would cause problems or look ugly.
3041 # WARNING: Use '\'' to represent an apostrophe within the trap.
3042 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3043 trap 'exit_status=$?
3044 # Save into config.log some information that might help in debugging.
3046 echo
3048 cat <<\_ASBOX
3049 ## ---------------- ##
3050 ## Cache variables. ##
3051 ## ---------------- ##
3052 _ASBOX
3053 echo
3054 # The following way of writing the cache mishandles newlines in values,
3056 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3057 eval ac_val=\$$ac_var
3058 case $ac_val in #(
3059 *${as_nl}*)
3060 case $ac_var in #(
3061 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3062 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3063 esac
3064 case $ac_var in #(
3065 _ | IFS | as_nl) ;; #(
3066 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3067 *) { eval $ac_var=; unset $ac_var;} ;;
3068 esac ;;
3069 esac
3070 done
3071 (set) 2>&1 |
3072 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3073 *${as_nl}ac_space=\ *)
3074 sed -n \
3075 "s/'\''/'\''\\\\'\'''\''/g;
3076 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3077 ;; #(
3079 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3081 esac |
3082 sort
3084 echo
3086 cat <<\_ASBOX
3087 ## ----------------- ##
3088 ## Output variables. ##
3089 ## ----------------- ##
3090 _ASBOX
3091 echo
3092 for ac_var in $ac_subst_vars
3094 eval ac_val=\$$ac_var
3095 case $ac_val in
3096 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3097 esac
3098 $as_echo "$ac_var='\''$ac_val'\''"
3099 done | sort
3100 echo
3102 if test -n "$ac_subst_files"; then
3103 cat <<\_ASBOX
3104 ## ------------------- ##
3105 ## File substitutions. ##
3106 ## ------------------- ##
3107 _ASBOX
3108 echo
3109 for ac_var in $ac_subst_files
3111 eval ac_val=\$$ac_var
3112 case $ac_val in
3113 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3114 esac
3115 $as_echo "$ac_var='\''$ac_val'\''"
3116 done | sort
3117 echo
3120 if test -s confdefs.h; then
3121 cat <<\_ASBOX
3122 ## ----------- ##
3123 ## confdefs.h. ##
3124 ## ----------- ##
3125 _ASBOX
3126 echo
3127 cat confdefs.h
3128 echo
3130 test "$ac_signal" != 0 &&
3131 $as_echo "$as_me: caught signal $ac_signal"
3132 $as_echo "$as_me: exit $exit_status"
3133 } >&5
3134 rm -f core *.core core.conftest.* &&
3135 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3136 exit $exit_status
3138 for ac_signal in 1 2 13 15; do
3139 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3140 done
3141 ac_signal=0
3143 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3144 rm -f -r conftest* confdefs.h
3146 $as_echo "/* confdefs.h */" > confdefs.h
3148 # Predefined preprocessor variables.
3150 cat >>confdefs.h <<_ACEOF
3151 #define PACKAGE_NAME "$PACKAGE_NAME"
3152 _ACEOF
3154 cat >>confdefs.h <<_ACEOF
3155 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3156 _ACEOF
3158 cat >>confdefs.h <<_ACEOF
3159 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3160 _ACEOF
3162 cat >>confdefs.h <<_ACEOF
3163 #define PACKAGE_STRING "$PACKAGE_STRING"
3164 _ACEOF
3166 cat >>confdefs.h <<_ACEOF
3167 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3168 _ACEOF
3170 cat >>confdefs.h <<_ACEOF
3171 #define PACKAGE_URL "$PACKAGE_URL"
3172 _ACEOF
3175 # Let the site file select an alternate cache file if it wants to.
3176 # Prefer an explicitly selected file to automatically selected ones.
3177 ac_site_file1=NONE
3178 ac_site_file2=NONE
3179 if test -n "$CONFIG_SITE"; then
3180 ac_site_file1=$CONFIG_SITE
3181 elif test "x$prefix" != xNONE; then
3182 ac_site_file1=$prefix/share/config.site
3183 ac_site_file2=$prefix/etc/config.site
3184 else
3185 ac_site_file1=$ac_default_prefix/share/config.site
3186 ac_site_file2=$ac_default_prefix/etc/config.site
3188 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3190 test "x$ac_site_file" = xNONE && continue
3191 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3192 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3193 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3194 sed 's/^/| /' "$ac_site_file" >&5
3195 . "$ac_site_file"
3197 done
3199 if test -r "$cache_file"; then
3200 # Some versions of bash will fail to source /dev/null (special files
3201 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3202 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3203 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3204 $as_echo "$as_me: loading cache $cache_file" >&6;}
3205 case $cache_file in
3206 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3207 *) . "./$cache_file";;
3208 esac
3210 else
3211 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3212 $as_echo "$as_me: creating cache $cache_file" >&6;}
3213 >$cache_file
3216 as_fn_append ac_header_list " linux/version.h"
3217 as_fn_append ac_header_list " sys/systeminfo.h"
3218 as_fn_append ac_header_list " coff.h"
3219 as_fn_append ac_header_list " pty.h"
3220 as_fn_append ac_header_list " sys/vlimit.h"
3221 as_fn_append ac_header_list " sys/resource.h"
3222 as_fn_append ac_header_list " sys/utsname.h"
3223 as_fn_append ac_header_list " pwd.h"
3224 as_fn_append ac_header_list " utmp.h"
3225 as_fn_append ac_header_list " util.h"
3226 as_fn_append ac_header_list " sys/socket.h"
3227 as_fn_append ac_header_list " stdlib.h"
3228 as_fn_append ac_header_list " unistd.h"
3229 as_fn_append ac_header_list " sys/param.h"
3230 as_fn_append ac_header_list " pthread.h"
3231 as_fn_append ac_header_list " malloc/malloc.h"
3232 as_fn_append ac_header_list " maillock.h"
3233 as_fn_append ac_header_list " sys/un.h"
3234 as_fn_append ac_func_list " tzset"
3235 as_fn_append ac_func_list " readlinkat"
3236 as_fn_append ac_header_list " execinfo.h"
3237 as_fn_append ac_func_list " faccessat"
3238 as_fn_append ac_header_list " stdio_ext.h"
3239 as_fn_append ac_func_list " __fpending"
3240 gl_getopt_required=GNU
3241 as_fn_append ac_header_list " getopt.h"
3242 as_fn_append ac_func_list " gettimeofday"
3243 as_fn_append ac_func_list " nanotime"
3244 as_fn_append ac_header_list " sys/time.h"
3245 as_fn_append ac_header_list " wchar.h"
3246 as_fn_append ac_header_list " stdint.h"
3247 as_fn_append ac_header_list " inttypes.h"
3248 as_fn_append ac_func_list " lstat"
3249 as_fn_append ac_func_list " alarm"
3250 as_fn_append ac_header_list " sys/select.h"
3251 as_fn_append ac_func_list " pselect"
3252 as_fn_append ac_func_list " pthread_sigmask"
3253 as_fn_append ac_func_list " readlink"
3254 as_fn_append ac_func_list " strtoimax"
3255 as_fn_append ac_func_list " strtoumax"
3256 as_fn_append ac_func_list " symlink"
3257 as_fn_append ac_header_list " sys/stat.h"
3258 as_fn_append ac_func_list " localtime_r"
3259 as_fn_append ac_header_list " utime.h"
3260 as_fn_append ac_func_list " futimes"
3261 as_fn_append ac_func_list " futimesat"
3262 as_fn_append ac_func_list " futimens"
3263 as_fn_append ac_func_list " utimensat"
3264 as_fn_append ac_func_list " lutimes"
3265 # Check that the precious variables saved in the cache have kept the same
3266 # value.
3267 ac_cache_corrupted=false
3268 for ac_var in $ac_precious_vars; do
3269 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3270 eval ac_new_set=\$ac_env_${ac_var}_set
3271 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3272 eval ac_new_val=\$ac_env_${ac_var}_value
3273 case $ac_old_set,$ac_new_set in
3274 set,)
3275 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3276 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3277 ac_cache_corrupted=: ;;
3278 ,set)
3279 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3280 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3281 ac_cache_corrupted=: ;;
3282 ,);;
3284 if test "x$ac_old_val" != "x$ac_new_val"; then
3285 # differences in whitespace do not lead to failure.
3286 ac_old_val_w=`echo x $ac_old_val`
3287 ac_new_val_w=`echo x $ac_new_val`
3288 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3289 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3290 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3291 ac_cache_corrupted=:
3292 else
3293 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3294 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3295 eval $ac_var=\$ac_old_val
3297 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3298 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3299 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3300 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3301 fi;;
3302 esac
3303 # Pass precious variables to config.status.
3304 if test "$ac_new_set" = set; then
3305 case $ac_new_val in
3306 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3307 *) ac_arg=$ac_var=$ac_new_val ;;
3308 esac
3309 case " $ac_configure_args " in
3310 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3311 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3312 esac
3314 done
3315 if $ac_cache_corrupted; then
3316 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3317 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3318 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3319 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3320 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3322 ## -------------------- ##
3323 ## Main body of script. ##
3324 ## -------------------- ##
3326 ac_ext=c
3327 ac_cpp='$CPP $CPPFLAGS'
3328 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3329 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3330 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3333 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3336 ac_aux_dir=
3337 for ac_dir in build-aux "$srcdir"/build-aux; do
3338 for ac_t in install-sh install.sh shtool; do
3339 if test -f "$ac_dir/$ac_t"; then
3340 ac_aux_dir=$ac_dir
3341 ac_install_sh="$ac_aux_dir/$ac_t -c"
3342 break 2
3344 done
3345 done
3346 if test -z "$ac_aux_dir"; then
3347 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3350 # These three variables are undocumented and unsupported,
3351 # and are intended to be withdrawn in a future Autoconf release.
3352 # They can cause serious problems if a builder's source tree is in a directory
3353 # whose full name contains unusual characters.
3354 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3355 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3356 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3359 am__api_version='1.11'
3361 # Find a good install program. We prefer a C program (faster),
3362 # so one script is as good as another. But avoid the broken or
3363 # incompatible versions:
3364 # SysV /etc/install, /usr/sbin/install
3365 # SunOS /usr/etc/install
3366 # IRIX /sbin/install
3367 # AIX /bin/install
3368 # AmigaOS /C/install, which installs bootblocks on floppy discs
3369 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3370 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3371 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3372 # OS/2's system install, which has a completely different semantic
3373 # ./install, which can be erroneously created by make from ./install.sh.
3374 # Reject install programs that cannot install multiple files.
3375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3376 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3377 if test -z "$INSTALL"; then
3378 if test "${ac_cv_path_install+set}" = set; then :
3379 $as_echo_n "(cached) " >&6
3380 else
3381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3382 for as_dir in $PATH
3384 IFS=$as_save_IFS
3385 test -z "$as_dir" && as_dir=.
3386 # Account for people who put trailing slashes in PATH elements.
3387 case $as_dir/ in #((
3388 ./ | .// | /[cC]/* | \
3389 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3390 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3391 /usr/ucb/* ) ;;
3393 # OSF1 and SCO ODT 3.0 have their own names for install.
3394 # Don't use installbsd from OSF since it installs stuff as root
3395 # by default.
3396 for ac_prog in ginstall scoinst install; do
3397 for ac_exec_ext in '' $ac_executable_extensions; do
3398 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3399 if test $ac_prog = install &&
3400 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3401 # AIX install. It has an incompatible calling convention.
3403 elif test $ac_prog = install &&
3404 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3405 # program-specific install script used by HP pwplus--don't use.
3407 else
3408 rm -rf conftest.one conftest.two conftest.dir
3409 echo one > conftest.one
3410 echo two > conftest.two
3411 mkdir conftest.dir
3412 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3413 test -s conftest.one && test -s conftest.two &&
3414 test -s conftest.dir/conftest.one &&
3415 test -s conftest.dir/conftest.two
3416 then
3417 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3418 break 3
3422 done
3423 done
3425 esac
3427 done
3428 IFS=$as_save_IFS
3430 rm -rf conftest.one conftest.two conftest.dir
3433 if test "${ac_cv_path_install+set}" = set; then
3434 INSTALL=$ac_cv_path_install
3435 else
3436 # As a last resort, use the slow shell script. Don't cache a
3437 # value for INSTALL within a source directory, because that will
3438 # break other packages using the cache if that directory is
3439 # removed, or if the value is a relative name.
3440 INSTALL=$ac_install_sh
3443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3444 $as_echo "$INSTALL" >&6; }
3446 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3447 # It thinks the first close brace ends the variable substitution.
3448 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3450 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3452 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3455 $as_echo_n "checking whether build environment is sane... " >&6; }
3456 # Just in case
3457 sleep 1
3458 echo timestamp > conftest.file
3459 # Reject unsafe characters in $srcdir or the absolute working directory
3460 # name. Accept space and tab only in the latter.
3461 am_lf='
3463 case `pwd` in
3464 *[\\\"\#\$\&\'\`$am_lf]*)
3465 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3466 esac
3467 case $srcdir in
3468 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3469 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3470 esac
3472 # Do `set' in a subshell so we don't clobber the current shell's
3473 # arguments. Must try -L first in case configure is actually a
3474 # symlink; some systems play weird games with the mod time of symlinks
3475 # (eg FreeBSD returns the mod time of the symlink's containing
3476 # directory).
3477 if (
3478 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3479 if test "$*" = "X"; then
3480 # -L didn't work.
3481 set X `ls -t "$srcdir/configure" conftest.file`
3483 rm -f conftest.file
3484 if test "$*" != "X $srcdir/configure conftest.file" \
3485 && test "$*" != "X conftest.file $srcdir/configure"; then
3487 # If neither matched, then we have a broken ls. This can happen
3488 # if, for instance, CONFIG_SHELL is bash and it inherits a
3489 # broken ls alias from the environment. This has actually
3490 # happened. Such a system could not be considered "sane".
3491 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3492 alias in your environment" "$LINENO" 5
3495 test "$2" = conftest.file
3497 then
3498 # Ok.
3500 else
3501 as_fn_error "newly created file is older than distributed files!
3502 Check your system clock" "$LINENO" 5
3504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3505 $as_echo "yes" >&6; }
3506 test "$program_prefix" != NONE &&
3507 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3508 # Use a double $ so make ignores it.
3509 test "$program_suffix" != NONE &&
3510 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3511 # Double any \ or $.
3512 # By default was `s,x,x', remove it if useless.
3513 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3514 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3516 # expand $ac_aux_dir to an absolute path
3517 am_aux_dir=`cd $ac_aux_dir && pwd`
3519 if test x"${MISSING+set}" != xset; then
3520 case $am_aux_dir in
3521 *\ * | *\ *)
3522 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3524 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3525 esac
3527 # Use eval to expand $SHELL
3528 if eval "$MISSING --run true"; then
3529 am_missing_run="$MISSING --run "
3530 else
3531 am_missing_run=
3532 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3533 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3536 if test x"${install_sh}" != xset; then
3537 case $am_aux_dir in
3538 *\ * | *\ *)
3539 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3541 install_sh="\${SHELL} $am_aux_dir/install-sh"
3542 esac
3545 # Installed binaries are usually stripped using `strip' when the user
3546 # run `make install-strip'. However `strip' might not be the right
3547 # tool to use in cross-compilation environments, therefore Automake
3548 # will honor the `STRIP' environment variable to overrule this program.
3549 if test "$cross_compiling" != no; then
3550 if test -n "$ac_tool_prefix"; then
3551 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3552 set dummy ${ac_tool_prefix}strip; ac_word=$2
3553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3554 $as_echo_n "checking for $ac_word... " >&6; }
3555 if test "${ac_cv_prog_STRIP+set}" = set; then :
3556 $as_echo_n "(cached) " >&6
3557 else
3558 if test -n "$STRIP"; then
3559 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3560 else
3561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3562 for as_dir in $PATH
3564 IFS=$as_save_IFS
3565 test -z "$as_dir" && as_dir=.
3566 for ac_exec_ext in '' $ac_executable_extensions; do
3567 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3568 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3570 break 2
3572 done
3573 done
3574 IFS=$as_save_IFS
3578 STRIP=$ac_cv_prog_STRIP
3579 if test -n "$STRIP"; then
3580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3581 $as_echo "$STRIP" >&6; }
3582 else
3583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3584 $as_echo "no" >&6; }
3589 if test -z "$ac_cv_prog_STRIP"; then
3590 ac_ct_STRIP=$STRIP
3591 # Extract the first word of "strip", so it can be a program name with args.
3592 set dummy strip; ac_word=$2
3593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3594 $as_echo_n "checking for $ac_word... " >&6; }
3595 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3596 $as_echo_n "(cached) " >&6
3597 else
3598 if test -n "$ac_ct_STRIP"; then
3599 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3600 else
3601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3602 for as_dir in $PATH
3604 IFS=$as_save_IFS
3605 test -z "$as_dir" && as_dir=.
3606 for ac_exec_ext in '' $ac_executable_extensions; do
3607 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3608 ac_cv_prog_ac_ct_STRIP="strip"
3609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3610 break 2
3612 done
3613 done
3614 IFS=$as_save_IFS
3618 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3619 if test -n "$ac_ct_STRIP"; then
3620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3621 $as_echo "$ac_ct_STRIP" >&6; }
3622 else
3623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3624 $as_echo "no" >&6; }
3627 if test "x$ac_ct_STRIP" = x; then
3628 STRIP=":"
3629 else
3630 case $cross_compiling:$ac_tool_warned in
3631 yes:)
3632 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3633 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3634 ac_tool_warned=yes ;;
3635 esac
3636 STRIP=$ac_ct_STRIP
3638 else
3639 STRIP="$ac_cv_prog_STRIP"
3643 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3646 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3647 if test -z "$MKDIR_P"; then
3648 if test "${ac_cv_path_mkdir+set}" = set; then :
3649 $as_echo_n "(cached) " >&6
3650 else
3651 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3652 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3654 IFS=$as_save_IFS
3655 test -z "$as_dir" && as_dir=.
3656 for ac_prog in mkdir gmkdir; do
3657 for ac_exec_ext in '' $ac_executable_extensions; do
3658 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3659 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3660 'mkdir (GNU coreutils) '* | \
3661 'mkdir (coreutils) '* | \
3662 'mkdir (fileutils) '4.1*)
3663 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3664 break 3;;
3665 esac
3666 done
3667 done
3668 done
3669 IFS=$as_save_IFS
3673 test -d ./--version && rmdir ./--version
3674 if test "${ac_cv_path_mkdir+set}" = set; then
3675 MKDIR_P="$ac_cv_path_mkdir -p"
3676 else
3677 # As a last resort, use the slow shell script. Don't cache a
3678 # value for MKDIR_P within a source directory, because that will
3679 # break other packages using the cache if that directory is
3680 # removed, or if the value is a relative name.
3681 MKDIR_P="$ac_install_sh -d"
3684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3685 $as_echo "$MKDIR_P" >&6; }
3688 mkdir_p="$MKDIR_P"
3689 case $mkdir_p in
3690 [\\/$]* | ?:[\\/]*) ;;
3691 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3692 esac
3694 for ac_prog in gawk mawk nawk awk
3696 # Extract the first word of "$ac_prog", so it can be a program name with args.
3697 set dummy $ac_prog; ac_word=$2
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3699 $as_echo_n "checking for $ac_word... " >&6; }
3700 if test "${ac_cv_prog_AWK+set}" = set; then :
3701 $as_echo_n "(cached) " >&6
3702 else
3703 if test -n "$AWK"; then
3704 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3705 else
3706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3707 for as_dir in $PATH
3709 IFS=$as_save_IFS
3710 test -z "$as_dir" && as_dir=.
3711 for ac_exec_ext in '' $ac_executable_extensions; do
3712 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3713 ac_cv_prog_AWK="$ac_prog"
3714 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3715 break 2
3717 done
3718 done
3719 IFS=$as_save_IFS
3723 AWK=$ac_cv_prog_AWK
3724 if test -n "$AWK"; then
3725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3726 $as_echo "$AWK" >&6; }
3727 else
3728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3729 $as_echo "no" >&6; }
3733 test -n "$AWK" && break
3734 done
3736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3737 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3738 set x ${MAKE-make}
3739 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3740 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3741 $as_echo_n "(cached) " >&6
3742 else
3743 cat >conftest.make <<\_ACEOF
3744 SHELL = /bin/sh
3745 all:
3746 @echo '@@@%%%=$(MAKE)=@@@%%%'
3747 _ACEOF
3748 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3749 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3750 *@@@%%%=?*=@@@%%%*)
3751 eval ac_cv_prog_make_${ac_make}_set=yes;;
3753 eval ac_cv_prog_make_${ac_make}_set=no;;
3754 esac
3755 rm -f conftest.make
3757 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3759 $as_echo "yes" >&6; }
3760 SET_MAKE=
3761 else
3762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3763 $as_echo "no" >&6; }
3764 SET_MAKE="MAKE=${MAKE-make}"
3767 rm -rf .tst 2>/dev/null
3768 mkdir .tst 2>/dev/null
3769 if test -d .tst; then
3770 am__leading_dot=.
3771 else
3772 am__leading_dot=_
3774 rmdir .tst 2>/dev/null
3776 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3777 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3778 # is not polluted with repeated "-I."
3779 am__isrc=' -I$(srcdir)'
3780 # test to see if srcdir already configured
3781 if test -f $srcdir/config.status; then
3782 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3786 # test whether we have cygpath
3787 if test -z "$CYGPATH_W"; then
3788 if (cygpath --version) >/dev/null 2>/dev/null; then
3789 CYGPATH_W='cygpath -w'
3790 else
3791 CYGPATH_W=echo
3796 # Define the identity of the package.
3797 PACKAGE='emacs'
3798 VERSION='24.3.50'
3801 cat >>confdefs.h <<_ACEOF
3802 #define PACKAGE "$PACKAGE"
3803 _ACEOF
3806 cat >>confdefs.h <<_ACEOF
3807 #define VERSION "$VERSION"
3808 _ACEOF
3810 # Some tools Automake needs.
3812 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3815 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3818 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3821 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3824 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3826 # We need awk for the "check" target. The system "awk" is bad on
3827 # some platforms.
3828 # Always define AMTAR for backward compatibility.
3830 AMTAR=${AMTAR-"${am_missing_run}tar"}
3832 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3841 lispdir='${datadir}/emacs/${version}/lisp'
3842 leimdir='${datadir}/emacs/${version}/leim'
3843 standardlisppath='${lispdir}:${leimdir}'
3844 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3845 '${datadir}/emacs/site-lisp'
3846 lisppath='${locallisppath}:${standardlisppath}'
3847 etcdir='${datadir}/emacs/${version}/etc'
3848 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3849 docdir='${datadir}/emacs/${version}/etc'
3850 gamedir='${localstatedir}/games/emacs'
3853 # Check whether --with-all was given.
3854 if test "${with_all+set}" = set; then :
3855 withval=$with_all; with_features=$withval
3856 else
3857 with_features=yes
3864 # Check whether --with-pop was given.
3865 if test "${with_pop+set}" = set; then :
3866 withval=$with_pop;
3867 else
3868 with_pop=$with_features
3871 if test "$with_pop" = yes; then
3872 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3877 # Check whether --with-kerberos was given.
3878 if test "${with_kerberos+set}" = set; then :
3879 withval=$with_kerberos;
3880 else
3881 with_kerberos=no
3884 if test "$with_kerberos" != no; then
3885 $as_echo "#define KERBEROS 1" >>confdefs.h
3890 # Check whether --with-kerberos5 was given.
3891 if test "${with_kerberos5+set}" = set; then :
3892 withval=$with_kerberos5;
3893 else
3894 with_kerberos5=no
3897 if test "${with_kerberos5}" != no; then
3898 if test "${with_kerberos}" = no; then
3899 with_kerberos=yes
3900 $as_echo "#define KERBEROS 1" >>confdefs.h
3904 $as_echo "#define KERBEROS5 1" >>confdefs.h
3909 # Check whether --with-hesiod was given.
3910 if test "${with_hesiod+set}" = set; then :
3911 withval=$with_hesiod;
3912 else
3913 with_hesiod=no
3916 if test "$with_hesiod" != no; then
3918 $as_echo "#define HESIOD 1" >>confdefs.h
3923 # Check whether --with-mmdf was given.
3924 if test "${with_mmdf+set}" = set; then :
3925 withval=$with_mmdf;
3926 else
3927 with_mmdf=no
3930 if test "$with_mmdf" != no; then
3932 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3937 # Check whether --with-mail-unlink was given.
3938 if test "${with_mail_unlink+set}" = set; then :
3939 withval=$with_mail_unlink;
3940 else
3941 with_mail_unlink=no
3944 if test "$with_mail_unlink" != no; then
3946 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3951 # Check whether --with-mailhost was given.
3952 if test "${with_mailhost+set}" = set; then :
3953 withval=$with_mailhost;
3954 cat >>confdefs.h <<_ACEOF
3955 #define MAILHOST "$withval"
3956 _ACEOF
3962 # Check whether --with-sound was given.
3963 if test "${with_sound+set}" = set; then :
3964 withval=$with_sound;
3965 else
3966 with_sound=$with_features
3971 # Check whether --with-x-toolkit was given.
3972 if test "${with_x_toolkit+set}" = set; then :
3973 withval=$with_x_toolkit; case "${withval}" in
3974 y | ye | yes ) val=gtk ;;
3975 n | no ) val=no ;;
3976 l | lu | luc | luci | lucid ) val=lucid ;;
3977 a | at | ath | athe | athen | athena ) val=athena ;;
3978 m | mo | mot | moti | motif ) val=motif ;;
3979 g | gt | gtk ) val=gtk ;;
3980 gtk2 ) val=gtk2 ;;
3981 gtk3 ) val=gtk3 ;;
3983 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3984 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
3985 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
3986 \`athena' and \`lucid' are synonyms." "$LINENO" 5
3988 esac
3989 with_x_toolkit=$val
3995 # Check whether --with-wide-int was given.
3996 if test "${with_wide_int+set}" = set; then :
3997 withval=$with_wide_int;
3998 else
3999 with_wide_int=no
4002 if test "$with_wide_int" = yes; then
4004 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4009 # Check whether --with-xpm was given.
4010 if test "${with_xpm+set}" = set; then :
4011 withval=$with_xpm;
4012 else
4013 with_xpm=$with_features
4017 # Check whether --with-jpeg was given.
4018 if test "${with_jpeg+set}" = set; then :
4019 withval=$with_jpeg;
4020 else
4021 with_jpeg=$with_features
4025 # Check whether --with-tiff was given.
4026 if test "${with_tiff+set}" = set; then :
4027 withval=$with_tiff;
4028 else
4029 with_tiff=$with_features
4033 # Check whether --with-gif was given.
4034 if test "${with_gif+set}" = set; then :
4035 withval=$with_gif;
4036 else
4037 with_gif=$with_features
4041 # Check whether --with-png was given.
4042 if test "${with_png+set}" = set; then :
4043 withval=$with_png;
4044 else
4045 with_png=$with_features
4049 # Check whether --with-rsvg was given.
4050 if test "${with_rsvg+set}" = set; then :
4051 withval=$with_rsvg;
4052 else
4053 with_rsvg=$with_features
4057 # Check whether --with-xml2 was given.
4058 if test "${with_xml2+set}" = set; then :
4059 withval=$with_xml2;
4060 else
4061 with_xml2=$with_features
4065 # Check whether --with-imagemagick was given.
4066 if test "${with_imagemagick+set}" = set; then :
4067 withval=$with_imagemagick;
4068 else
4069 with_imagemagick=$with_features
4074 # Check whether --with-xft was given.
4075 if test "${with_xft+set}" = set; then :
4076 withval=$with_xft;
4077 else
4078 with_xft=$with_features
4082 # Check whether --with-libotf was given.
4083 if test "${with_libotf+set}" = set; then :
4084 withval=$with_libotf;
4085 else
4086 with_libotf=$with_features
4090 # Check whether --with-m17n-flt was given.
4091 if test "${with_m17n_flt+set}" = set; then :
4092 withval=$with_m17n_flt;
4093 else
4094 with_m17n_flt=$with_features
4099 # Check whether --with-toolkit-scroll-bars was given.
4100 if test "${with_toolkit_scroll_bars+set}" = set; then :
4101 withval=$with_toolkit_scroll_bars;
4102 else
4103 with_toolkit_scroll_bars=$with_features
4107 # Check whether --with-xaw3d was given.
4108 if test "${with_xaw3d+set}" = set; then :
4109 withval=$with_xaw3d;
4110 else
4111 with_xaw3d=$with_features
4115 # Check whether --with-xim was given.
4116 if test "${with_xim+set}" = set; then :
4117 withval=$with_xim;
4118 else
4119 with_xim=$with_features
4123 # Check whether --with-ns was given.
4124 if test "${with_ns+set}" = set; then :
4125 withval=$with_ns;
4126 else
4127 with_ns=no
4131 # Check whether --with-w32 was given.
4132 if test "${with_w32+set}" = set; then :
4133 withval=$with_w32;
4134 else
4135 with_w32=no
4140 # Check whether --with-gpm was given.
4141 if test "${with_gpm+set}" = set; then :
4142 withval=$with_gpm;
4143 else
4144 with_gpm=$with_features
4148 # Check whether --with-dbus was given.
4149 if test "${with_dbus+set}" = set; then :
4150 withval=$with_dbus;
4151 else
4152 with_dbus=$with_features
4156 # Check whether --with-gconf was given.
4157 if test "${with_gconf+set}" = set; then :
4158 withval=$with_gconf;
4159 else
4160 with_gconf=$with_features
4164 # Check whether --with-gsettings was given.
4165 if test "${with_gsettings+set}" = set; then :
4166 withval=$with_gsettings;
4167 else
4168 with_gsettings=$with_features
4172 # Check whether --with-selinux was given.
4173 if test "${with_selinux+set}" = set; then :
4174 withval=$with_selinux;
4175 else
4176 with_selinux=$with_features
4180 # Check whether --with-acl was given.
4181 if test "${with_acl+set}" = set; then :
4182 withval=$with_acl;
4183 else
4184 with_acl=$with_features
4188 # Check whether --with-gnutls was given.
4189 if test "${with_gnutls+set}" = set; then :
4190 withval=$with_gnutls;
4191 else
4192 with_gnutls=$with_features
4196 # Check whether --with-inotify was given.
4197 if test "${with_inotify+set}" = set; then :
4198 withval=$with_inotify;
4199 else
4200 with_inotify=$with_features
4204 ## For the times when you want to build Emacs but don't have
4205 ## a suitable makeinfo, and can live without the manuals.
4207 # Check whether --with-makeinfo was given.
4208 if test "${with_makeinfo+set}" = set; then :
4209 withval=$with_makeinfo;
4210 else
4211 with_makeinfo=$with_features
4215 ## Makefile.in needs the cache file name.
4218 ## This is an option because I do not know if all info/man support
4219 ## compressed files, nor how to test if they do so.
4221 # Check whether --with-compress-info was given.
4222 if test "${with_compress_info+set}" = set; then :
4223 withval=$with_compress_info;
4224 else
4225 with_compress_info=$with_features
4228 if test $with_compress_info = yes; then
4229 GZIP_INFO=yes
4230 else
4231 GZIP_INFO=
4236 # Check whether --with-pkg-config-prog was given.
4237 if test "${with_pkg_config_prog+set}" = set; then :
4238 withval=$with_pkg_config_prog;
4241 if test "X${with_pkg_config_prog}" != X; then
4242 if test "${with_pkg_config_prog}" != yes; then
4243 PKG_CONFIG="${with_pkg_config_prog}"
4247 CRT_DIR=
4249 # Check whether --with-crt-dir was given.
4250 if test "${with_crt_dir+set}" = set; then :
4251 withval=$with_crt_dir;
4254 CRT_DIR="${with_crt_dir}"
4257 # Check whether --with-gameuser was given.
4258 if test "${with_gameuser+set}" = set; then :
4259 withval=$with_gameuser;
4262 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4263 && gameuser="${with_gameuser}"
4264 test "X$gameuser" = X && gameuser=games
4267 # Check whether --with-gnustep-conf was given.
4268 if test "${with_gnustep_conf+set}" = set; then :
4269 withval=$with_gnustep_conf;
4272 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4273 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4274 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4275 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4277 # Check whether --enable-ns-self-contained was given.
4278 if test "${enable_ns_self_contained+set}" = set; then :
4279 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4280 else
4281 EN_NS_SELF_CONTAINED=yes
4285 # Check whether --enable-locallisppath was given.
4286 if test "${enable_locallisppath+set}" = set; then :
4287 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4288 locallisppath=
4289 elif test "${enableval}" != "yes"; then
4290 locallisppath=${enableval}
4295 # Check whether --enable-checking was given.
4296 if test "${enable_checking+set}" = set; then :
4297 enableval=$enable_checking; ac_checking_flags="${enableval}"
4300 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4301 for check in $ac_checking_flags
4303 case $check in
4304 # these set all the flags to specific states
4305 yes) ac_enable_checking=1 ;;
4306 no) ac_enable_checking= ;
4307 ac_gc_check_stringbytes= ;
4308 ac_gc_check_string_overrun= ;
4309 ac_gc_check_string_free_list= ;
4310 ac_xmalloc_overrun= ;
4311 ac_gc_check_cons_list= ;
4312 ac_glyphs_debug= ;;
4313 all) ac_enable_checking=1 ;
4314 ac_gc_check_stringbytes=1 ;
4315 ac_gc_check_string_overrun=1 ;
4316 ac_gc_check_string_free_list=1 ;
4317 ac_xmalloc_overrun=1 ;
4318 ac_gc_check_cons_list=1 ;
4319 ac_glyphs_debug=1 ;;
4320 # these enable particular checks
4321 stringbytes) ac_gc_check_stringbytes=1 ;;
4322 stringoverrun) ac_gc_check_string_overrun=1 ;;
4323 stringfreelist) ac_gc_check_string_free_list=1 ;;
4324 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4325 conslist) ac_gc_check_cons_list=1 ;;
4326 glyphs) ac_glyphs_debug=1 ;;
4327 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4328 esac
4329 done
4330 IFS="$ac_save_IFS"
4332 if test x$ac_enable_checking != x ; then
4334 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4337 if test x$ac_gc_check_stringbytes != x ; then
4339 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4342 if test x$ac_gc_check_string_overrun != x ; then
4344 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4347 if test x$ac_gc_check_string_free_list != x ; then
4349 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4352 if test x$ac_xmalloc_overrun != x ; then
4354 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4357 if test x$ac_gc_check_cons_list != x ; then
4359 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4362 if test x$ac_glyphs_debug != x ; then
4364 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4368 # Check whether --enable-check-lisp-object-type was given.
4369 if test "${enable_check_lisp_object_type+set}" = set; then :
4370 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4372 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4379 # Check whether --enable-profiling was given.
4380 if test "${enable_profiling+set}" = set; then :
4381 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4384 if test x$ac_enable_profiling != x ; then
4385 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4386 else
4387 PROFILING_CFLAGS=
4391 # Check whether --enable-autodepend was given.
4392 if test "${enable_autodepend+set}" = set; then :
4393 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4394 else
4395 ac_enable_autodepend=yes
4399 #### Make srcdir absolute, if it isn't already. It's important to
4400 #### avoid running the file name through pwd unnecessarily, since pwd can
4401 #### give you automounter prefixes, which can go away. We do all this
4402 #### so Emacs can find its files when run uninstalled.
4403 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4404 unset CDPATH
4405 case "${srcdir}" in
4406 /* ) ;;
4408 ## We may be able to use the $PWD environment variable to make this
4409 ## absolute. But sometimes PWD is inaccurate.
4410 ## Note: we used to use $PWD at the end instead of `pwd`,
4411 ## but that tested only for a well-formed and valid PWD,
4412 ## it did not object when PWD was well-formed and valid but just wrong.
4413 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4414 then
4415 srcdir="$PWD"
4416 else
4417 srcdir=`(cd "$srcdir"; pwd)`
4420 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4421 esac
4423 ### Canonicalize the configuration name.
4425 # Make sure we can run config.sub.
4426 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4427 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4430 $as_echo_n "checking build system type... " >&6; }
4431 if test "${ac_cv_build+set}" = set; then :
4432 $as_echo_n "(cached) " >&6
4433 else
4434 ac_build_alias=$build_alias
4435 test "x$ac_build_alias" = x &&
4436 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4437 test "x$ac_build_alias" = x &&
4438 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4439 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4440 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4444 $as_echo "$ac_cv_build" >&6; }
4445 case $ac_cv_build in
4446 *-*-*) ;;
4447 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4448 esac
4449 build=$ac_cv_build
4450 ac_save_IFS=$IFS; IFS='-'
4451 set x $ac_cv_build
4452 shift
4453 build_cpu=$1
4454 build_vendor=$2
4455 shift; shift
4456 # Remember, the first character of IFS is used to create $*,
4457 # except with old shells:
4458 build_os=$*
4459 IFS=$ac_save_IFS
4460 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4464 $as_echo_n "checking host system type... " >&6; }
4465 if test "${ac_cv_host+set}" = set; then :
4466 $as_echo_n "(cached) " >&6
4467 else
4468 if test "x$host_alias" = x; then
4469 ac_cv_host=$ac_cv_build
4470 else
4471 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4472 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4477 $as_echo "$ac_cv_host" >&6; }
4478 case $ac_cv_host in
4479 *-*-*) ;;
4480 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4481 esac
4482 host=$ac_cv_host
4483 ac_save_IFS=$IFS; IFS='-'
4484 set x $ac_cv_host
4485 shift
4486 host_cpu=$1
4487 host_vendor=$2
4488 shift; shift
4489 # Remember, the first character of IFS is used to create $*,
4490 # except with old shells:
4491 host_os=$*
4492 IFS=$ac_save_IFS
4493 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4496 canonical=$host
4497 configuration=${host_alias-${build_alias-$host}}
4501 ### If you add support for a new configuration, add code to this
4502 ### switch statement to recognize your configuration name and select
4503 ### the appropriate operating system file.
4505 ### You would hope that you could choose an s/*.h
4506 ### file based on the operating system portion. However, it turns out
4507 ### that each s/*.h file is pretty manufacturer-specific.
4508 ### So we basically have to have a special case for each
4509 ### configuration name.
4511 ### As far as handling version numbers on operating systems is
4512 ### concerned, make sure things will fail in a fixable way. If
4513 ### /etc/MACHINES doesn't say anything about version numbers, be
4514 ### prepared to handle anything reasonably. If version numbers
4515 ### matter, be sure /etc/MACHINES says something about it.
4517 opsys='' unported=no
4518 case "${canonical}" in
4520 ## GNU/Linux and similar ports
4521 *-*-linux* )
4522 opsys=gnu-linux
4525 ## FreeBSD ports
4526 *-*-freebsd* )
4527 opsys=freebsd
4530 ## FreeBSD kernel + glibc based userland
4531 *-*-kfreebsd*gnu* )
4532 opsys=gnu-kfreebsd
4535 ## NetBSD ports
4536 *-*-netbsd* )
4537 opsys=netbsd
4540 ## OpenBSD ports
4541 *-*-openbsd* )
4542 opsys=openbsd
4545 ## Apple Darwin / Mac OS X
4546 *-apple-darwin* )
4547 case "${canonical}" in
4548 i[3456]86-* ) ;;
4549 powerpc-* ) ;;
4550 x86_64-* ) ;;
4551 * ) unported=yes ;;
4552 esac
4553 opsys=darwin
4554 ## Use fink packages if available.
4555 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4556 ## if test -d /sw/include && test -d /sw/lib; then
4557 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4558 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4559 ## fi
4562 ## HP 9000 series 700 and 800, running HP/UX
4563 hppa*-hp-hpux10.2* )
4564 opsys=hpux10-20
4566 hppa*-hp-hpux1[1-9]* )
4567 opsys=hpux11
4568 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4571 ## IBM machines
4572 rs6000-ibm-aix4.[23]* )
4573 opsys=aix4-2
4575 powerpc-ibm-aix4.[23]* )
4576 opsys=aix4-2
4578 rs6000-ibm-aix[56]* )
4579 opsys=aix4-2
4581 powerpc-ibm-aix[56]* )
4582 opsys=aix4-2
4585 ## Silicon Graphics machines
4586 ## Iris 4D
4587 mips-sgi-irix6.5 )
4588 opsys=irix6-5
4589 # Without defining _LANGUAGE_C, things get masked out in the headers
4590 # so that, for instance, grepping for `free' in stdlib.h fails and
4591 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4592 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4595 ## Suns
4596 *-sun-solaris* \
4597 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4598 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4599 case "${canonical}" in
4600 i[3456]86-*-* ) ;;
4601 amd64-*-*|x86_64-*-*) ;;
4602 sparc* ) ;;
4603 * ) unported=yes ;;
4604 esac
4605 case "${canonical}" in
4606 *-sunos5.6* | *-solaris2.6* )
4607 opsys=sol2-6
4608 RANLIB="ar -ts"
4610 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4611 opsys=sol2-6
4612 emacs_check_sunpro_c=yes
4614 *-sunos5* | *-solaris* )
4615 opsys=sol2-10
4616 emacs_check_sunpro_c=yes
4618 esac
4619 ## Watch out for a compiler that we know will not work.
4620 case "${canonical}" in
4621 *-solaris* | *-sunos5* )
4622 if [ "x$CC" = x/usr/ucb/cc ]; then
4623 ## /usr/ucb/cc doesn't work;
4624 ## we should find some other compiler that does work.
4625 unset CC
4628 *) ;;
4629 esac
4632 ## Intel 386 machines where we don't care about the manufacturer.
4633 i[3456]86-*-* )
4634 case "${canonical}" in
4635 *-cygwin ) opsys=cygwin ;;
4636 *-darwin* ) opsys=darwin ;;
4637 *-sysv4.2uw* ) opsys=unixware ;;
4638 *-sysv5uw* ) opsys=unixware ;;
4639 *-sysv5OpenUNIX* ) opsys=unixware ;;
4640 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4641 esac
4645 unported=yes
4647 esac
4649 ### If the code above didn't choose an operating system, just choose
4650 ### an operating system based on the configuration name. You really
4651 ### only want to use this when you have no idea what the right
4652 ### operating system is; if you know what operating systems a machine
4653 ### runs, it's cleaner to make it explicit in the case statement
4654 ### above.
4655 if test x"${opsys}" = x; then
4656 case "${canonical}" in
4657 *-gnu* ) opsys=gnu ;;
4659 unported=yes
4661 esac
4666 if test $unported = yes; then
4667 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4668 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4672 #### Choose a compiler.
4674 ac_ext=c
4675 ac_cpp='$CPP $CPPFLAGS'
4676 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4677 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4678 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4679 if test -n "$ac_tool_prefix"; then
4680 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4681 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4683 $as_echo_n "checking for $ac_word... " >&6; }
4684 if test "${ac_cv_prog_CC+set}" = set; then :
4685 $as_echo_n "(cached) " >&6
4686 else
4687 if test -n "$CC"; then
4688 ac_cv_prog_CC="$CC" # Let the user override the test.
4689 else
4690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4691 for as_dir in $PATH
4693 IFS=$as_save_IFS
4694 test -z "$as_dir" && as_dir=.
4695 for ac_exec_ext in '' $ac_executable_extensions; do
4696 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4697 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4698 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4699 break 2
4701 done
4702 done
4703 IFS=$as_save_IFS
4707 CC=$ac_cv_prog_CC
4708 if test -n "$CC"; then
4709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4710 $as_echo "$CC" >&6; }
4711 else
4712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4713 $as_echo "no" >&6; }
4718 if test -z "$ac_cv_prog_CC"; then
4719 ac_ct_CC=$CC
4720 # Extract the first word of "gcc", so it can be a program name with args.
4721 set dummy gcc; ac_word=$2
4722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4723 $as_echo_n "checking for $ac_word... " >&6; }
4724 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4725 $as_echo_n "(cached) " >&6
4726 else
4727 if test -n "$ac_ct_CC"; then
4728 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4729 else
4730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4731 for as_dir in $PATH
4733 IFS=$as_save_IFS
4734 test -z "$as_dir" && as_dir=.
4735 for ac_exec_ext in '' $ac_executable_extensions; do
4736 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4737 ac_cv_prog_ac_ct_CC="gcc"
4738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4739 break 2
4741 done
4742 done
4743 IFS=$as_save_IFS
4747 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4748 if test -n "$ac_ct_CC"; then
4749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4750 $as_echo "$ac_ct_CC" >&6; }
4751 else
4752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4753 $as_echo "no" >&6; }
4756 if test "x$ac_ct_CC" = x; then
4757 CC=""
4758 else
4759 case $cross_compiling:$ac_tool_warned in
4760 yes:)
4761 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4762 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4763 ac_tool_warned=yes ;;
4764 esac
4765 CC=$ac_ct_CC
4767 else
4768 CC="$ac_cv_prog_CC"
4771 if test -z "$CC"; then
4772 if test -n "$ac_tool_prefix"; then
4773 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4774 set dummy ${ac_tool_prefix}cc; ac_word=$2
4775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4776 $as_echo_n "checking for $ac_word... " >&6; }
4777 if test "${ac_cv_prog_CC+set}" = set; then :
4778 $as_echo_n "(cached) " >&6
4779 else
4780 if test -n "$CC"; then
4781 ac_cv_prog_CC="$CC" # Let the user override the test.
4782 else
4783 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4784 for as_dir in $PATH
4786 IFS=$as_save_IFS
4787 test -z "$as_dir" && as_dir=.
4788 for ac_exec_ext in '' $ac_executable_extensions; do
4789 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4790 ac_cv_prog_CC="${ac_tool_prefix}cc"
4791 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4792 break 2
4794 done
4795 done
4796 IFS=$as_save_IFS
4800 CC=$ac_cv_prog_CC
4801 if test -n "$CC"; then
4802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4803 $as_echo "$CC" >&6; }
4804 else
4805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4806 $as_echo "no" >&6; }
4812 if test -z "$CC"; then
4813 # Extract the first word of "cc", so it can be a program name with args.
4814 set dummy cc; ac_word=$2
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4816 $as_echo_n "checking for $ac_word... " >&6; }
4817 if test "${ac_cv_prog_CC+set}" = set; then :
4818 $as_echo_n "(cached) " >&6
4819 else
4820 if test -n "$CC"; then
4821 ac_cv_prog_CC="$CC" # Let the user override the test.
4822 else
4823 ac_prog_rejected=no
4824 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4825 for as_dir in $PATH
4827 IFS=$as_save_IFS
4828 test -z "$as_dir" && as_dir=.
4829 for ac_exec_ext in '' $ac_executable_extensions; do
4830 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4831 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4832 ac_prog_rejected=yes
4833 continue
4835 ac_cv_prog_CC="cc"
4836 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4837 break 2
4839 done
4840 done
4841 IFS=$as_save_IFS
4843 if test $ac_prog_rejected = yes; then
4844 # We found a bogon in the path, so make sure we never use it.
4845 set dummy $ac_cv_prog_CC
4846 shift
4847 if test $# != 0; then
4848 # We chose a different compiler from the bogus one.
4849 # However, it has the same basename, so the bogon will be chosen
4850 # first if we set CC to just the basename; use the full file name.
4851 shift
4852 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4857 CC=$ac_cv_prog_CC
4858 if test -n "$CC"; then
4859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4860 $as_echo "$CC" >&6; }
4861 else
4862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4863 $as_echo "no" >&6; }
4868 if test -z "$CC"; then
4869 if test -n "$ac_tool_prefix"; then
4870 for ac_prog in cl.exe
4872 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4873 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4875 $as_echo_n "checking for $ac_word... " >&6; }
4876 if test "${ac_cv_prog_CC+set}" = set; then :
4877 $as_echo_n "(cached) " >&6
4878 else
4879 if test -n "$CC"; then
4880 ac_cv_prog_CC="$CC" # Let the user override the test.
4881 else
4882 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4883 for as_dir in $PATH
4885 IFS=$as_save_IFS
4886 test -z "$as_dir" && as_dir=.
4887 for ac_exec_ext in '' $ac_executable_extensions; do
4888 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4889 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4891 break 2
4893 done
4894 done
4895 IFS=$as_save_IFS
4899 CC=$ac_cv_prog_CC
4900 if test -n "$CC"; then
4901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4902 $as_echo "$CC" >&6; }
4903 else
4904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4905 $as_echo "no" >&6; }
4909 test -n "$CC" && break
4910 done
4912 if test -z "$CC"; then
4913 ac_ct_CC=$CC
4914 for ac_prog in cl.exe
4916 # Extract the first word of "$ac_prog", so it can be a program name with args.
4917 set dummy $ac_prog; ac_word=$2
4918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4919 $as_echo_n "checking for $ac_word... " >&6; }
4920 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4921 $as_echo_n "(cached) " >&6
4922 else
4923 if test -n "$ac_ct_CC"; then
4924 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4925 else
4926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4927 for as_dir in $PATH
4929 IFS=$as_save_IFS
4930 test -z "$as_dir" && as_dir=.
4931 for ac_exec_ext in '' $ac_executable_extensions; do
4932 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4933 ac_cv_prog_ac_ct_CC="$ac_prog"
4934 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4935 break 2
4937 done
4938 done
4939 IFS=$as_save_IFS
4943 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4944 if test -n "$ac_ct_CC"; then
4945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4946 $as_echo "$ac_ct_CC" >&6; }
4947 else
4948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4949 $as_echo "no" >&6; }
4953 test -n "$ac_ct_CC" && break
4954 done
4956 if test "x$ac_ct_CC" = x; then
4957 CC=""
4958 else
4959 case $cross_compiling:$ac_tool_warned in
4960 yes:)
4961 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4962 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4963 ac_tool_warned=yes ;;
4964 esac
4965 CC=$ac_ct_CC
4972 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4973 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4974 as_fn_error "no acceptable C compiler found in \$PATH
4975 See \`config.log' for more details." "$LINENO" 5; }
4977 # Provide some information about the compiler.
4978 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4979 set X $ac_compile
4980 ac_compiler=$2
4981 for ac_option in --version -v -V -qversion; do
4982 { { ac_try="$ac_compiler $ac_option >&5"
4983 case "(($ac_try" in
4984 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4985 *) ac_try_echo=$ac_try;;
4986 esac
4987 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4988 $as_echo "$ac_try_echo"; } >&5
4989 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4990 ac_status=$?
4991 if test -s conftest.err; then
4992 sed '10a\
4993 ... rest of stderr output deleted ...
4994 10q' conftest.err >conftest.er1
4995 cat conftest.er1 >&5
4997 rm -f conftest.er1 conftest.err
4998 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4999 test $ac_status = 0; }
5000 done
5002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5003 /* end confdefs.h. */
5006 main ()
5010 return 0;
5012 _ACEOF
5013 ac_clean_files_save=$ac_clean_files
5014 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5015 # Try to create an executable without -o first, disregard a.out.
5016 # It will help us diagnose broken compilers, and finding out an intuition
5017 # of exeext.
5018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5019 $as_echo_n "checking whether the C compiler works... " >&6; }
5020 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5022 # The possible output files:
5023 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5025 ac_rmfiles=
5026 for ac_file in $ac_files
5028 case $ac_file in
5029 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5030 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5031 esac
5032 done
5033 rm -f $ac_rmfiles
5035 if { { ac_try="$ac_link_default"
5036 case "(($ac_try" in
5037 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5038 *) ac_try_echo=$ac_try;;
5039 esac
5040 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5041 $as_echo "$ac_try_echo"; } >&5
5042 (eval "$ac_link_default") 2>&5
5043 ac_status=$?
5044 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5045 test $ac_status = 0; }; then :
5046 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5047 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5048 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5049 # so that the user can short-circuit this test for compilers unknown to
5050 # Autoconf.
5051 for ac_file in $ac_files ''
5053 test -f "$ac_file" || continue
5054 case $ac_file in
5055 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5057 [ab].out )
5058 # We found the default executable, but exeext='' is most
5059 # certainly right.
5060 break;;
5061 *.* )
5062 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5063 then :; else
5064 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5066 # We set ac_cv_exeext here because the later test for it is not
5067 # safe: cross compilers may not add the suffix if given an `-o'
5068 # argument, so we may need to know it at that point already.
5069 # Even if this section looks crufty: it has the advantage of
5070 # actually working.
5071 break;;
5073 break;;
5074 esac
5075 done
5076 test "$ac_cv_exeext" = no && ac_cv_exeext=
5078 else
5079 ac_file=''
5081 if test -z "$ac_file"; then :
5082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5083 $as_echo "no" >&6; }
5084 $as_echo "$as_me: failed program was:" >&5
5085 sed 's/^/| /' conftest.$ac_ext >&5
5087 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5088 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5089 { as_fn_set_status 77
5090 as_fn_error "C compiler cannot create executables
5091 See \`config.log' for more details." "$LINENO" 5; }; }
5092 else
5093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5094 $as_echo "yes" >&6; }
5096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5097 $as_echo_n "checking for C compiler default output file name... " >&6; }
5098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5099 $as_echo "$ac_file" >&6; }
5100 ac_exeext=$ac_cv_exeext
5102 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5103 ac_clean_files=$ac_clean_files_save
5104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5105 $as_echo_n "checking for suffix of executables... " >&6; }
5106 if { { ac_try="$ac_link"
5107 case "(($ac_try" in
5108 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5109 *) ac_try_echo=$ac_try;;
5110 esac
5111 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5112 $as_echo "$ac_try_echo"; } >&5
5113 (eval "$ac_link") 2>&5
5114 ac_status=$?
5115 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5116 test $ac_status = 0; }; then :
5117 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5118 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5119 # work properly (i.e., refer to `conftest.exe'), while it won't with
5120 # `rm'.
5121 for ac_file in conftest.exe conftest conftest.*; do
5122 test -f "$ac_file" || continue
5123 case $ac_file in
5124 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5125 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5126 break;;
5127 * ) break;;
5128 esac
5129 done
5130 else
5131 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5132 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5133 as_fn_error "cannot compute suffix of executables: cannot compile and link
5134 See \`config.log' for more details." "$LINENO" 5; }
5136 rm -f conftest conftest$ac_cv_exeext
5137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5138 $as_echo "$ac_cv_exeext" >&6; }
5140 rm -f conftest.$ac_ext
5141 EXEEXT=$ac_cv_exeext
5142 ac_exeext=$EXEEXT
5143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5144 /* end confdefs.h. */
5145 #include <stdio.h>
5147 main ()
5149 FILE *f = fopen ("conftest.out", "w");
5150 return ferror (f) || fclose (f) != 0;
5153 return 0;
5155 _ACEOF
5156 ac_clean_files="$ac_clean_files conftest.out"
5157 # Check that the compiler produces executables we can run. If not, either
5158 # the compiler is broken, or we cross compile.
5159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5160 $as_echo_n "checking whether we are cross compiling... " >&6; }
5161 if test "$cross_compiling" != yes; then
5162 { { ac_try="$ac_link"
5163 case "(($ac_try" in
5164 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5165 *) ac_try_echo=$ac_try;;
5166 esac
5167 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5168 $as_echo "$ac_try_echo"; } >&5
5169 (eval "$ac_link") 2>&5
5170 ac_status=$?
5171 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5172 test $ac_status = 0; }
5173 if { ac_try='./conftest$ac_cv_exeext'
5174 { { case "(($ac_try" in
5175 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5176 *) ac_try_echo=$ac_try;;
5177 esac
5178 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5179 $as_echo "$ac_try_echo"; } >&5
5180 (eval "$ac_try") 2>&5
5181 ac_status=$?
5182 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5183 test $ac_status = 0; }; }; then
5184 cross_compiling=no
5185 else
5186 if test "$cross_compiling" = maybe; then
5187 cross_compiling=yes
5188 else
5189 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5190 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5191 as_fn_error "cannot run C compiled programs.
5192 If you meant to cross compile, use \`--host'.
5193 See \`config.log' for more details." "$LINENO" 5; }
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5198 $as_echo "$cross_compiling" >&6; }
5200 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5201 ac_clean_files=$ac_clean_files_save
5202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5203 $as_echo_n "checking for suffix of object files... " >&6; }
5204 if test "${ac_cv_objext+set}" = set; then :
5205 $as_echo_n "(cached) " >&6
5206 else
5207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5208 /* end confdefs.h. */
5211 main ()
5215 return 0;
5217 _ACEOF
5218 rm -f conftest.o conftest.obj
5219 if { { ac_try="$ac_compile"
5220 case "(($ac_try" in
5221 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5222 *) ac_try_echo=$ac_try;;
5223 esac
5224 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5225 $as_echo "$ac_try_echo"; } >&5
5226 (eval "$ac_compile") 2>&5
5227 ac_status=$?
5228 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5229 test $ac_status = 0; }; then :
5230 for ac_file in conftest.o conftest.obj conftest.*; do
5231 test -f "$ac_file" || continue;
5232 case $ac_file in
5233 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5234 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5235 break;;
5236 esac
5237 done
5238 else
5239 $as_echo "$as_me: failed program was:" >&5
5240 sed 's/^/| /' conftest.$ac_ext >&5
5242 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5243 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5244 as_fn_error "cannot compute suffix of object files: cannot compile
5245 See \`config.log' for more details." "$LINENO" 5; }
5247 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5250 $as_echo "$ac_cv_objext" >&6; }
5251 OBJEXT=$ac_cv_objext
5252 ac_objext=$OBJEXT
5253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5254 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5255 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5256 $as_echo_n "(cached) " >&6
5257 else
5258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5259 /* end confdefs.h. */
5262 main ()
5264 #ifndef __GNUC__
5265 choke me
5266 #endif
5269 return 0;
5271 _ACEOF
5272 if ac_fn_c_try_compile "$LINENO"; then :
5273 ac_compiler_gnu=yes
5274 else
5275 ac_compiler_gnu=no
5277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5278 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5282 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5283 if test $ac_compiler_gnu = yes; then
5284 GCC=yes
5285 else
5286 GCC=
5288 ac_test_CFLAGS=${CFLAGS+set}
5289 ac_save_CFLAGS=$CFLAGS
5290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5291 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5292 if test "${ac_cv_prog_cc_g+set}" = set; then :
5293 $as_echo_n "(cached) " >&6
5294 else
5295 ac_save_c_werror_flag=$ac_c_werror_flag
5296 ac_c_werror_flag=yes
5297 ac_cv_prog_cc_g=no
5298 CFLAGS="-g"
5299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5300 /* end confdefs.h. */
5303 main ()
5307 return 0;
5309 _ACEOF
5310 if ac_fn_c_try_compile "$LINENO"; then :
5311 ac_cv_prog_cc_g=yes
5312 else
5313 CFLAGS=""
5314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5315 /* end confdefs.h. */
5318 main ()
5322 return 0;
5324 _ACEOF
5325 if ac_fn_c_try_compile "$LINENO"; then :
5327 else
5328 ac_c_werror_flag=$ac_save_c_werror_flag
5329 CFLAGS="-g"
5330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5331 /* end confdefs.h. */
5334 main ()
5338 return 0;
5340 _ACEOF
5341 if ac_fn_c_try_compile "$LINENO"; then :
5342 ac_cv_prog_cc_g=yes
5344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5349 ac_c_werror_flag=$ac_save_c_werror_flag
5351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5352 $as_echo "$ac_cv_prog_cc_g" >&6; }
5353 if test "$ac_test_CFLAGS" = set; then
5354 CFLAGS=$ac_save_CFLAGS
5355 elif test $ac_cv_prog_cc_g = yes; then
5356 if test "$GCC" = yes; then
5357 CFLAGS="-g -O2"
5358 else
5359 CFLAGS="-g"
5361 else
5362 if test "$GCC" = yes; then
5363 CFLAGS="-O2"
5364 else
5365 CFLAGS=
5368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5369 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5370 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5371 $as_echo_n "(cached) " >&6
5372 else
5373 ac_cv_prog_cc_c89=no
5374 ac_save_CC=$CC
5375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5376 /* end confdefs.h. */
5377 #include <stdarg.h>
5378 #include <stdio.h>
5379 #include <sys/types.h>
5380 #include <sys/stat.h>
5381 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5382 struct buf { int x; };
5383 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5384 static char *e (p, i)
5385 char **p;
5386 int i;
5388 return p[i];
5390 static char *f (char * (*g) (char **, int), char **p, ...)
5392 char *s;
5393 va_list v;
5394 va_start (v,p);
5395 s = g (p, va_arg (v,int));
5396 va_end (v);
5397 return s;
5400 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5401 function prototypes and stuff, but not '\xHH' hex character constants.
5402 These don't provoke an error unfortunately, instead are silently treated
5403 as 'x'. The following induces an error, until -std is added to get
5404 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5405 array size at least. It's necessary to write '\x00'==0 to get something
5406 that's true only with -std. */
5407 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5409 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5410 inside strings and character constants. */
5411 #define FOO(x) 'x'
5412 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5414 int test (int i, double x);
5415 struct s1 {int (*f) (int a);};
5416 struct s2 {int (*f) (double a);};
5417 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5418 int argc;
5419 char **argv;
5421 main ()
5423 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5425 return 0;
5427 _ACEOF
5428 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5429 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5431 CC="$ac_save_CC $ac_arg"
5432 if ac_fn_c_try_compile "$LINENO"; then :
5433 ac_cv_prog_cc_c89=$ac_arg
5435 rm -f core conftest.err conftest.$ac_objext
5436 test "x$ac_cv_prog_cc_c89" != "xno" && break
5437 done
5438 rm -f conftest.$ac_ext
5439 CC=$ac_save_CC
5442 # AC_CACHE_VAL
5443 case "x$ac_cv_prog_cc_c89" in
5445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5446 $as_echo "none needed" >&6; } ;;
5447 xno)
5448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5449 $as_echo "unsupported" >&6; } ;;
5451 CC="$CC $ac_cv_prog_cc_c89"
5452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5453 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5454 esac
5455 if test "x$ac_cv_prog_cc_c89" != xno; then :
5459 ac_ext=c
5460 ac_cpp='$CPP $CPPFLAGS'
5461 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5462 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5463 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5464 DEPDIR="${am__leading_dot}deps"
5466 ac_config_commands="$ac_config_commands depfiles"
5469 am_make=${MAKE-make}
5470 cat > confinc << 'END'
5471 am__doit:
5472 @echo this is the am__doit target
5473 .PHONY: am__doit
5475 # If we don't find an include directive, just comment out the code.
5476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5477 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5478 am__include="#"
5479 am__quote=
5480 _am_result=none
5481 # First try GNU make style include.
5482 echo "include confinc" > confmf
5483 # Ignore all kinds of additional output from `make'.
5484 case `$am_make -s -f confmf 2> /dev/null` in #(
5485 *the\ am__doit\ target*)
5486 am__include=include
5487 am__quote=
5488 _am_result=GNU
5490 esac
5491 # Now try BSD make style include.
5492 if test "$am__include" = "#"; then
5493 echo '.include "confinc"' > confmf
5494 case `$am_make -s -f confmf 2> /dev/null` in #(
5495 *the\ am__doit\ target*)
5496 am__include=.include
5497 am__quote="\""
5498 _am_result=BSD
5500 esac
5504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5505 $as_echo "$_am_result" >&6; }
5506 rm -f confinc confmf
5508 # Check whether --enable-dependency-tracking was given.
5509 if test "${enable_dependency_tracking+set}" = set; then :
5510 enableval=$enable_dependency_tracking;
5513 if test "x$enable_dependency_tracking" != xno; then
5514 am_depcomp="$ac_aux_dir/depcomp"
5515 AMDEPBACKSLASH='\'
5517 if test "x$enable_dependency_tracking" != xno; then
5518 AMDEP_TRUE=
5519 AMDEP_FALSE='#'
5520 else
5521 AMDEP_TRUE='#'
5522 AMDEP_FALSE=
5527 depcc="$CC" am_compiler_list=
5529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5530 $as_echo_n "checking dependency style of $depcc... " >&6; }
5531 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5532 $as_echo_n "(cached) " >&6
5533 else
5534 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5535 # We make a subdir and do the tests there. Otherwise we can end up
5536 # making bogus files that we don't know about and never remove. For
5537 # instance it was reported that on HP-UX the gcc test will end up
5538 # making a dummy file named `D' -- because `-MD' means `put the output
5539 # in D'.
5540 mkdir conftest.dir
5541 # Copy depcomp to subdir because otherwise we won't find it if we're
5542 # using a relative directory.
5543 cp "$am_depcomp" conftest.dir
5544 cd conftest.dir
5545 # We will build objects and dependencies in a subdirectory because
5546 # it helps to detect inapplicable dependency modes. For instance
5547 # both Tru64's cc and ICC support -MD to output dependencies as a
5548 # side effect of compilation, but ICC will put the dependencies in
5549 # the current directory while Tru64 will put them in the object
5550 # directory.
5551 mkdir sub
5553 am_cv_CC_dependencies_compiler_type=none
5554 if test "$am_compiler_list" = ""; then
5555 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5557 am__universal=false
5558 case " $depcc " in #(
5559 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5560 esac
5562 for depmode in $am_compiler_list; do
5563 # Setup a source with many dependencies, because some compilers
5564 # like to wrap large dependency lists on column 80 (with \), and
5565 # we should not choose a depcomp mode which is confused by this.
5567 # We need to recreate these files for each test, as the compiler may
5568 # overwrite some of them when testing with obscure command lines.
5569 # This happens at least with the AIX C compiler.
5570 : > sub/conftest.c
5571 for i in 1 2 3 4 5 6; do
5572 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5573 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5574 # Solaris 8's {/usr,}/bin/sh.
5575 touch sub/conftst$i.h
5576 done
5577 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5579 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5580 # mode. It turns out that the SunPro C++ compiler does not properly
5581 # handle `-M -o', and we need to detect this. Also, some Intel
5582 # versions had trouble with output in subdirs
5583 am__obj=sub/conftest.${OBJEXT-o}
5584 am__minus_obj="-o $am__obj"
5585 case $depmode in
5586 gcc)
5587 # This depmode causes a compiler race in universal mode.
5588 test "$am__universal" = false || continue
5590 nosideeffect)
5591 # after this tag, mechanisms are not by side-effect, so they'll
5592 # only be used when explicitly requested
5593 if test "x$enable_dependency_tracking" = xyes; then
5594 continue
5595 else
5596 break
5599 msvisualcpp | msvcmsys)
5600 # This compiler won't grok `-c -o', but also, the minuso test has
5601 # not run yet. These depmodes are late enough in the game, and
5602 # so weak that their functioning should not be impacted.
5603 am__obj=conftest.${OBJEXT-o}
5604 am__minus_obj=
5606 none) break ;;
5607 esac
5608 if depmode=$depmode \
5609 source=sub/conftest.c object=$am__obj \
5610 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5611 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5612 >/dev/null 2>conftest.err &&
5613 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5614 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5615 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5616 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5617 # icc doesn't choke on unknown options, it will just issue warnings
5618 # or remarks (even with -Werror). So we grep stderr for any message
5619 # that says an option was ignored or not supported.
5620 # When given -MP, icc 7.0 and 7.1 complain thusly:
5621 # icc: Command line warning: ignoring option '-M'; no argument required
5622 # The diagnosis changed in icc 8.0:
5623 # icc: Command line remark: option '-MP' not supported
5624 if (grep 'ignoring option' conftest.err ||
5625 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5626 am_cv_CC_dependencies_compiler_type=$depmode
5627 break
5630 done
5632 cd ..
5633 rm -rf conftest.dir
5634 else
5635 am_cv_CC_dependencies_compiler_type=none
5639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5640 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5641 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5644 test "x$enable_dependency_tracking" != xno \
5645 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5646 am__fastdepCC_TRUE=
5647 am__fastdepCC_FALSE='#'
5648 else
5649 am__fastdepCC_TRUE='#'
5650 am__fastdepCC_FALSE=
5654 if test "x$CC" != xcc; then
5655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5656 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5657 else
5658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5659 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5661 set dummy $CC; ac_cc=`$as_echo "$2" |
5662 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5663 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5664 $as_echo_n "(cached) " >&6
5665 else
5666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5667 /* end confdefs.h. */
5670 main ()
5674 return 0;
5676 _ACEOF
5677 # Make sure it works both with $CC and with simple cc.
5678 # We do the test twice because some compilers refuse to overwrite an
5679 # existing .o file with -o, though they will create one.
5680 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5681 rm -f conftest2.*
5682 if { { case "(($ac_try" in
5683 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5684 *) ac_try_echo=$ac_try;;
5685 esac
5686 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5687 $as_echo "$ac_try_echo"; } >&5
5688 (eval "$ac_try") 2>&5
5689 ac_status=$?
5690 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5691 test $ac_status = 0; } &&
5692 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5693 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5694 *) ac_try_echo=$ac_try;;
5695 esac
5696 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5697 $as_echo "$ac_try_echo"; } >&5
5698 (eval "$ac_try") 2>&5
5699 ac_status=$?
5700 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5701 test $ac_status = 0; };
5702 then
5703 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5704 if test "x$CC" != xcc; then
5705 # Test first that cc exists at all.
5706 if { ac_try='cc -c conftest.$ac_ext >&5'
5707 { { case "(($ac_try" in
5708 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5709 *) ac_try_echo=$ac_try;;
5710 esac
5711 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5712 $as_echo "$ac_try_echo"; } >&5
5713 (eval "$ac_try") 2>&5
5714 ac_status=$?
5715 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5716 test $ac_status = 0; }; }; then
5717 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5718 rm -f conftest2.*
5719 if { { case "(($ac_try" in
5720 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5721 *) ac_try_echo=$ac_try;;
5722 esac
5723 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5724 $as_echo "$ac_try_echo"; } >&5
5725 (eval "$ac_try") 2>&5
5726 ac_status=$?
5727 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5728 test $ac_status = 0; } &&
5729 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5730 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5731 *) ac_try_echo=$ac_try;;
5732 esac
5733 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5734 $as_echo "$ac_try_echo"; } >&5
5735 (eval "$ac_try") 2>&5
5736 ac_status=$?
5737 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5738 test $ac_status = 0; };
5739 then
5740 # cc works too.
5742 else
5743 # cc exists but doesn't like -o.
5744 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5748 else
5749 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5751 rm -f core conftest*
5754 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5756 $as_echo "yes" >&6; }
5757 else
5758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5759 $as_echo "no" >&6; }
5761 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5765 # FIXME: we rely on the cache variable name because
5766 # there is no other way.
5767 set dummy $CC
5768 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5769 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5770 if test "$am_t" != yes; then
5771 # Losing compiler, so override with the script.
5772 # FIXME: It is wrong to rewrite CC.
5773 # But if we don't then we get into trouble of one sort or another.
5774 # A longer-term fix would be to have automake use am__CC in this case,
5775 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5776 CC="$am_aux_dir/compile $CC"
5781 if test x$GCC = xyes; then
5782 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5783 else
5784 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5787 # Avoid gnulib's tests for O_NOATIME and O_NOFOLLOW, as we don't use them.
5789 # Avoid gnulib's threadlib module, as we do threads our own way.
5792 # Initialize gnulib right after choosing the compiler.
5794 ac_ext=c
5795 ac_cpp='$CPP $CPPFLAGS'
5796 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5797 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5798 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5800 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5801 # On Suns, sometimes $CPP names a directory.
5802 if test -n "$CPP" && test -d "$CPP"; then
5803 CPP=
5805 if test -z "$CPP"; then
5806 if test "${ac_cv_prog_CPP+set}" = set; then :
5807 $as_echo_n "(cached) " >&6
5808 else
5809 # Double quotes because CPP needs to be expanded
5810 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5812 ac_preproc_ok=false
5813 for ac_c_preproc_warn_flag in '' yes
5815 # Use a header file that comes with gcc, so configuring glibc
5816 # with a fresh cross-compiler works.
5817 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5818 # <limits.h> exists even on freestanding compilers.
5819 # On the NeXT, cc -E runs the code through the compiler's parser,
5820 # not just through cpp. "Syntax error" is here to catch this case.
5821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5822 /* end confdefs.h. */
5823 #ifdef __STDC__
5824 # include <limits.h>
5825 #else
5826 # include <assert.h>
5827 #endif
5828 Syntax error
5829 _ACEOF
5830 if ac_fn_c_try_cpp "$LINENO"; then :
5832 else
5833 # Broken: fails on valid input.
5834 continue
5836 rm -f conftest.err conftest.$ac_ext
5838 # OK, works on sane cases. Now check whether nonexistent headers
5839 # can be detected and how.
5840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5841 /* end confdefs.h. */
5842 #include <ac_nonexistent.h>
5843 _ACEOF
5844 if ac_fn_c_try_cpp "$LINENO"; then :
5845 # Broken: success on invalid input.
5846 continue
5847 else
5848 # Passes both tests.
5849 ac_preproc_ok=:
5850 break
5852 rm -f conftest.err conftest.$ac_ext
5854 done
5855 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5856 rm -f conftest.err conftest.$ac_ext
5857 if $ac_preproc_ok; then :
5858 break
5861 done
5862 ac_cv_prog_CPP=$CPP
5865 CPP=$ac_cv_prog_CPP
5866 else
5867 ac_cv_prog_CPP=$CPP
5869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5870 $as_echo "$CPP" >&6; }
5871 ac_preproc_ok=false
5872 for ac_c_preproc_warn_flag in '' yes
5874 # Use a header file that comes with gcc, so configuring glibc
5875 # with a fresh cross-compiler works.
5876 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5877 # <limits.h> exists even on freestanding compilers.
5878 # On the NeXT, cc -E runs the code through the compiler's parser,
5879 # not just through cpp. "Syntax error" is here to catch this case.
5880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5881 /* end confdefs.h. */
5882 #ifdef __STDC__
5883 # include <limits.h>
5884 #else
5885 # include <assert.h>
5886 #endif
5887 Syntax error
5888 _ACEOF
5889 if ac_fn_c_try_cpp "$LINENO"; then :
5891 else
5892 # Broken: fails on valid input.
5893 continue
5895 rm -f conftest.err conftest.$ac_ext
5897 # OK, works on sane cases. Now check whether nonexistent headers
5898 # can be detected and how.
5899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5900 /* end confdefs.h. */
5901 #include <ac_nonexistent.h>
5902 _ACEOF
5903 if ac_fn_c_try_cpp "$LINENO"; then :
5904 # Broken: success on invalid input.
5905 continue
5906 else
5907 # Passes both tests.
5908 ac_preproc_ok=:
5909 break
5911 rm -f conftest.err conftest.$ac_ext
5913 done
5914 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5915 rm -f conftest.err conftest.$ac_ext
5916 if $ac_preproc_ok; then :
5918 else
5919 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5920 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5921 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5922 See \`config.log' for more details." "$LINENO" 5; }
5925 ac_ext=c
5926 ac_cpp='$CPP $CPPFLAGS'
5927 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5928 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5929 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5933 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5934 if test "${ac_cv_path_GREP+set}" = set; then :
5935 $as_echo_n "(cached) " >&6
5936 else
5937 if test -z "$GREP"; then
5938 ac_path_GREP_found=false
5939 # Loop through the user's path and test for each of PROGNAME-LIST
5940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5941 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5943 IFS=$as_save_IFS
5944 test -z "$as_dir" && as_dir=.
5945 for ac_prog in grep ggrep; do
5946 for ac_exec_ext in '' $ac_executable_extensions; do
5947 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5948 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5949 # Check for GNU ac_path_GREP and select it if it is found.
5950 # Check for GNU $ac_path_GREP
5951 case `"$ac_path_GREP" --version 2>&1` in
5952 *GNU*)
5953 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5955 ac_count=0
5956 $as_echo_n 0123456789 >"conftest.in"
5957 while :
5959 cat "conftest.in" "conftest.in" >"conftest.tmp"
5960 mv "conftest.tmp" "conftest.in"
5961 cp "conftest.in" "conftest.nl"
5962 $as_echo 'GREP' >> "conftest.nl"
5963 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5964 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5965 as_fn_arith $ac_count + 1 && ac_count=$as_val
5966 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5967 # Best one so far, save it but keep looking for a better one
5968 ac_cv_path_GREP="$ac_path_GREP"
5969 ac_path_GREP_max=$ac_count
5971 # 10*(2^10) chars as input seems more than enough
5972 test $ac_count -gt 10 && break
5973 done
5974 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5975 esac
5977 $ac_path_GREP_found && break 3
5978 done
5979 done
5980 done
5981 IFS=$as_save_IFS
5982 if test -z "$ac_cv_path_GREP"; then
5983 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5985 else
5986 ac_cv_path_GREP=$GREP
5990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5991 $as_echo "$ac_cv_path_GREP" >&6; }
5992 GREP="$ac_cv_path_GREP"
5995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5996 $as_echo_n "checking for egrep... " >&6; }
5997 if test "${ac_cv_path_EGREP+set}" = set; then :
5998 $as_echo_n "(cached) " >&6
5999 else
6000 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6001 then ac_cv_path_EGREP="$GREP -E"
6002 else
6003 if test -z "$EGREP"; then
6004 ac_path_EGREP_found=false
6005 # Loop through the user's path and test for each of PROGNAME-LIST
6006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6007 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6009 IFS=$as_save_IFS
6010 test -z "$as_dir" && as_dir=.
6011 for ac_prog in egrep; do
6012 for ac_exec_ext in '' $ac_executable_extensions; do
6013 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6014 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6015 # Check for GNU ac_path_EGREP and select it if it is found.
6016 # Check for GNU $ac_path_EGREP
6017 case `"$ac_path_EGREP" --version 2>&1` in
6018 *GNU*)
6019 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6021 ac_count=0
6022 $as_echo_n 0123456789 >"conftest.in"
6023 while :
6025 cat "conftest.in" "conftest.in" >"conftest.tmp"
6026 mv "conftest.tmp" "conftest.in"
6027 cp "conftest.in" "conftest.nl"
6028 $as_echo 'EGREP' >> "conftest.nl"
6029 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6030 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6031 as_fn_arith $ac_count + 1 && ac_count=$as_val
6032 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6033 # Best one so far, save it but keep looking for a better one
6034 ac_cv_path_EGREP="$ac_path_EGREP"
6035 ac_path_EGREP_max=$ac_count
6037 # 10*(2^10) chars as input seems more than enough
6038 test $ac_count -gt 10 && break
6039 done
6040 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6041 esac
6043 $ac_path_EGREP_found && break 3
6044 done
6045 done
6046 done
6047 IFS=$as_save_IFS
6048 if test -z "$ac_cv_path_EGREP"; then
6049 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6051 else
6052 ac_cv_path_EGREP=$EGREP
6057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6058 $as_echo "$ac_cv_path_EGREP" >&6; }
6059 EGREP="$ac_cv_path_EGREP"
6064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6065 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6066 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6067 $as_echo_n "(cached) " >&6
6068 else
6070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6071 /* end confdefs.h. */
6073 #ifdef __ACK__
6074 Amsterdam
6075 #endif
6077 _ACEOF
6078 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6079 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6080 gl_cv_c_amsterdam_compiler=yes
6081 else
6082 gl_cv_c_amsterdam_compiler=no
6084 rm -f conftest*
6088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6089 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6090 if test -z "$AR"; then
6091 if test $gl_cv_c_amsterdam_compiler = yes; then
6092 AR='cc -c.a'
6093 if test -z "$ARFLAGS"; then
6094 ARFLAGS='-o'
6096 else
6097 if test -n "$ac_tool_prefix"; then
6098 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6099 set dummy ${ac_tool_prefix}ar; ac_word=$2
6100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6101 $as_echo_n "checking for $ac_word... " >&6; }
6102 if test "${ac_cv_prog_AR+set}" = set; then :
6103 $as_echo_n "(cached) " >&6
6104 else
6105 if test -n "$AR"; then
6106 ac_cv_prog_AR="$AR" # Let the user override the test.
6107 else
6108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6109 for as_dir in $PATH
6111 IFS=$as_save_IFS
6112 test -z "$as_dir" && as_dir=.
6113 for ac_exec_ext in '' $ac_executable_extensions; do
6114 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6115 ac_cv_prog_AR="${ac_tool_prefix}ar"
6116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6117 break 2
6119 done
6120 done
6121 IFS=$as_save_IFS
6125 AR=$ac_cv_prog_AR
6126 if test -n "$AR"; then
6127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6128 $as_echo "$AR" >&6; }
6129 else
6130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6131 $as_echo "no" >&6; }
6136 if test -z "$ac_cv_prog_AR"; then
6137 ac_ct_AR=$AR
6138 # Extract the first word of "ar", so it can be a program name with args.
6139 set dummy ar; ac_word=$2
6140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6141 $as_echo_n "checking for $ac_word... " >&6; }
6142 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6143 $as_echo_n "(cached) " >&6
6144 else
6145 if test -n "$ac_ct_AR"; then
6146 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6147 else
6148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6149 for as_dir in $PATH
6151 IFS=$as_save_IFS
6152 test -z "$as_dir" && as_dir=.
6153 for ac_exec_ext in '' $ac_executable_extensions; do
6154 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6155 ac_cv_prog_ac_ct_AR="ar"
6156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6157 break 2
6159 done
6160 done
6161 IFS=$as_save_IFS
6165 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6166 if test -n "$ac_ct_AR"; then
6167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6168 $as_echo "$ac_ct_AR" >&6; }
6169 else
6170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6171 $as_echo "no" >&6; }
6174 if test "x$ac_ct_AR" = x; then
6175 AR="ar"
6176 else
6177 case $cross_compiling:$ac_tool_warned in
6178 yes:)
6179 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6180 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6181 ac_tool_warned=yes ;;
6182 esac
6183 AR=$ac_ct_AR
6185 else
6186 AR="$ac_cv_prog_AR"
6189 if test -z "$ARFLAGS"; then
6190 ARFLAGS='cru'
6193 else
6194 if test -z "$ARFLAGS"; then
6195 ARFLAGS='cru'
6200 if test -z "$RANLIB"; then
6201 if test $gl_cv_c_amsterdam_compiler = yes; then
6202 RANLIB=':'
6203 else
6204 if test -n "$ac_tool_prefix"; then
6205 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6206 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6208 $as_echo_n "checking for $ac_word... " >&6; }
6209 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6210 $as_echo_n "(cached) " >&6
6211 else
6212 if test -n "$RANLIB"; then
6213 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6214 else
6215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6216 for as_dir in $PATH
6218 IFS=$as_save_IFS
6219 test -z "$as_dir" && as_dir=.
6220 for ac_exec_ext in '' $ac_executable_extensions; do
6221 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6222 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6224 break 2
6226 done
6227 done
6228 IFS=$as_save_IFS
6232 RANLIB=$ac_cv_prog_RANLIB
6233 if test -n "$RANLIB"; then
6234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6235 $as_echo "$RANLIB" >&6; }
6236 else
6237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6238 $as_echo "no" >&6; }
6243 if test -z "$ac_cv_prog_RANLIB"; then
6244 ac_ct_RANLIB=$RANLIB
6245 # Extract the first word of "ranlib", so it can be a program name with args.
6246 set dummy ranlib; ac_word=$2
6247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6248 $as_echo_n "checking for $ac_word... " >&6; }
6249 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6250 $as_echo_n "(cached) " >&6
6251 else
6252 if test -n "$ac_ct_RANLIB"; then
6253 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6254 else
6255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6256 for as_dir in $PATH
6258 IFS=$as_save_IFS
6259 test -z "$as_dir" && as_dir=.
6260 for ac_exec_ext in '' $ac_executable_extensions; do
6261 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6262 ac_cv_prog_ac_ct_RANLIB="ranlib"
6263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6264 break 2
6266 done
6267 done
6268 IFS=$as_save_IFS
6272 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6273 if test -n "$ac_ct_RANLIB"; then
6274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6275 $as_echo "$ac_ct_RANLIB" >&6; }
6276 else
6277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6278 $as_echo "no" >&6; }
6281 if test "x$ac_ct_RANLIB" = x; then
6282 RANLIB=":"
6283 else
6284 case $cross_compiling:$ac_tool_warned in
6285 yes:)
6286 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6287 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6288 ac_tool_warned=yes ;;
6289 esac
6290 RANLIB=$ac_ct_RANLIB
6292 else
6293 RANLIB="$ac_cv_prog_RANLIB"
6300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6301 $as_echo_n "checking for ANSI C header files... " >&6; }
6302 if test "${ac_cv_header_stdc+set}" = set; then :
6303 $as_echo_n "(cached) " >&6
6304 else
6305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6306 /* end confdefs.h. */
6307 #include <stdlib.h>
6308 #include <stdarg.h>
6309 #include <string.h>
6310 #include <float.h>
6313 main ()
6317 return 0;
6319 _ACEOF
6320 if ac_fn_c_try_compile "$LINENO"; then :
6321 ac_cv_header_stdc=yes
6322 else
6323 ac_cv_header_stdc=no
6325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6327 if test $ac_cv_header_stdc = yes; then
6328 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6330 /* end confdefs.h. */
6331 #include <string.h>
6333 _ACEOF
6334 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6335 $EGREP "memchr" >/dev/null 2>&1; then :
6337 else
6338 ac_cv_header_stdc=no
6340 rm -f conftest*
6344 if test $ac_cv_header_stdc = yes; then
6345 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6347 /* end confdefs.h. */
6348 #include <stdlib.h>
6350 _ACEOF
6351 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6352 $EGREP "free" >/dev/null 2>&1; then :
6354 else
6355 ac_cv_header_stdc=no
6357 rm -f conftest*
6361 if test $ac_cv_header_stdc = yes; then
6362 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6363 if test "$cross_compiling" = yes; then :
6365 else
6366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6367 /* end confdefs.h. */
6368 #include <ctype.h>
6369 #include <stdlib.h>
6370 #if ((' ' & 0x0FF) == 0x020)
6371 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6372 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6373 #else
6374 # define ISLOWER(c) \
6375 (('a' <= (c) && (c) <= 'i') \
6376 || ('j' <= (c) && (c) <= 'r') \
6377 || ('s' <= (c) && (c) <= 'z'))
6378 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6379 #endif
6381 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6383 main ()
6385 int i;
6386 for (i = 0; i < 256; i++)
6387 if (XOR (islower (i), ISLOWER (i))
6388 || toupper (i) != TOUPPER (i))
6389 return 2;
6390 return 0;
6392 _ACEOF
6393 if ac_fn_c_try_run "$LINENO"; then :
6395 else
6396 ac_cv_header_stdc=no
6398 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6399 conftest.$ac_objext conftest.beam conftest.$ac_ext
6404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6405 $as_echo "$ac_cv_header_stdc" >&6; }
6406 if test $ac_cv_header_stdc = yes; then
6408 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6412 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6413 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6414 inttypes.h stdint.h unistd.h
6415 do :
6416 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6417 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6419 eval as_val=\$$as_ac_Header
6420 if test "x$as_val" = x""yes; then :
6421 cat >>confdefs.h <<_ACEOF
6422 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6423 _ACEOF
6427 done
6433 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6434 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6435 MINIX=yes
6436 else
6437 MINIX=
6441 if test "$MINIX" = yes; then
6443 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6446 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6449 $as_echo "#define _MINIX 1" >>confdefs.h
6453 case "$host_os" in
6454 hpux*)
6456 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6459 esac
6462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6463 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6464 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6465 $as_echo_n "(cached) " >&6
6466 else
6467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6468 /* end confdefs.h. */
6470 # define __EXTENSIONS__ 1
6471 $ac_includes_default
6473 main ()
6477 return 0;
6479 _ACEOF
6480 if ac_fn_c_try_compile "$LINENO"; then :
6481 ac_cv_safe_to_define___extensions__=yes
6482 else
6483 ac_cv_safe_to_define___extensions__=no
6485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6488 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6489 test $ac_cv_safe_to_define___extensions__ = yes &&
6490 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6492 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6494 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6496 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6498 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6500 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6509 # Check whether --enable-largefile was given.
6510 if test "${enable_largefile+set}" = set; then :
6511 enableval=$enable_largefile;
6514 if test "$enable_largefile" != no; then
6516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6517 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6518 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6519 $as_echo_n "(cached) " >&6
6520 else
6521 ac_cv_sys_largefile_CC=no
6522 if test "$GCC" != yes; then
6523 ac_save_CC=$CC
6524 while :; do
6525 # IRIX 6.2 and later do not support large files by default,
6526 # so use the C compiler's -n32 option if that helps.
6527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6528 /* end confdefs.h. */
6529 #include <sys/types.h>
6530 /* Check that off_t can represent 2**63 - 1 correctly.
6531 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6532 since some C++ compilers masquerading as C compilers
6533 incorrectly reject 9223372036854775807. */
6534 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6535 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6536 && LARGE_OFF_T % 2147483647 == 1)
6537 ? 1 : -1];
6539 main ()
6543 return 0;
6545 _ACEOF
6546 if ac_fn_c_try_compile "$LINENO"; then :
6547 break
6549 rm -f core conftest.err conftest.$ac_objext
6550 CC="$CC -n32"
6551 if ac_fn_c_try_compile "$LINENO"; then :
6552 ac_cv_sys_largefile_CC=' -n32'; break
6554 rm -f core conftest.err conftest.$ac_objext
6555 break
6556 done
6557 CC=$ac_save_CC
6558 rm -f conftest.$ac_ext
6561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6562 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6563 if test "$ac_cv_sys_largefile_CC" != no; then
6564 CC=$CC$ac_cv_sys_largefile_CC
6567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6568 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6569 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6570 $as_echo_n "(cached) " >&6
6571 else
6572 while :; do
6573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6574 /* end confdefs.h. */
6575 #include <sys/types.h>
6576 /* Check that off_t can represent 2**63 - 1 correctly.
6577 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6578 since some C++ compilers masquerading as C compilers
6579 incorrectly reject 9223372036854775807. */
6580 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6581 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6582 && LARGE_OFF_T % 2147483647 == 1)
6583 ? 1 : -1];
6585 main ()
6589 return 0;
6591 _ACEOF
6592 if ac_fn_c_try_compile "$LINENO"; then :
6593 ac_cv_sys_file_offset_bits=no; break
6595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6597 /* end confdefs.h. */
6598 #define _FILE_OFFSET_BITS 64
6599 #include <sys/types.h>
6600 /* Check that off_t can represent 2**63 - 1 correctly.
6601 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6602 since some C++ compilers masquerading as C compilers
6603 incorrectly reject 9223372036854775807. */
6604 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6605 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6606 && LARGE_OFF_T % 2147483647 == 1)
6607 ? 1 : -1];
6609 main ()
6613 return 0;
6615 _ACEOF
6616 if ac_fn_c_try_compile "$LINENO"; then :
6617 ac_cv_sys_file_offset_bits=64; break
6619 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6620 ac_cv_sys_file_offset_bits=unknown
6621 break
6622 done
6624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6625 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6626 case $ac_cv_sys_file_offset_bits in #(
6627 no | unknown) ;;
6629 cat >>confdefs.h <<_ACEOF
6630 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6631 _ACEOF
6633 esac
6634 rm -rf conftest*
6635 if test $ac_cv_sys_file_offset_bits = unknown; then
6636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6637 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6638 if test "${ac_cv_sys_large_files+set}" = set; then :
6639 $as_echo_n "(cached) " >&6
6640 else
6641 while :; do
6642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6643 /* end confdefs.h. */
6644 #include <sys/types.h>
6645 /* Check that off_t can represent 2**63 - 1 correctly.
6646 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6647 since some C++ compilers masquerading as C compilers
6648 incorrectly reject 9223372036854775807. */
6649 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6650 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6651 && LARGE_OFF_T % 2147483647 == 1)
6652 ? 1 : -1];
6654 main ()
6658 return 0;
6660 _ACEOF
6661 if ac_fn_c_try_compile "$LINENO"; then :
6662 ac_cv_sys_large_files=no; break
6664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6666 /* end confdefs.h. */
6667 #define _LARGE_FILES 1
6668 #include <sys/types.h>
6669 /* Check that off_t can represent 2**63 - 1 correctly.
6670 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6671 since some C++ compilers masquerading as C compilers
6672 incorrectly reject 9223372036854775807. */
6673 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6674 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6675 && LARGE_OFF_T % 2147483647 == 1)
6676 ? 1 : -1];
6678 main ()
6682 return 0;
6684 _ACEOF
6685 if ac_fn_c_try_compile "$LINENO"; then :
6686 ac_cv_sys_large_files=1; break
6688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6689 ac_cv_sys_large_files=unknown
6690 break
6691 done
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6694 $as_echo "$ac_cv_sys_large_files" >&6; }
6695 case $ac_cv_sys_large_files in #(
6696 no | unknown) ;;
6698 cat >>confdefs.h <<_ACEOF
6699 #define _LARGE_FILES $ac_cv_sys_large_files
6700 _ACEOF
6702 esac
6703 rm -rf conftest*
6709 case $ac_cv_prog_cc_stdc in #(
6710 no) :
6711 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6712 *) :
6713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6714 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6715 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6716 $as_echo_n "(cached) " >&6
6717 else
6718 ac_cv_prog_cc_c99=no
6719 ac_save_CC=$CC
6720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6721 /* end confdefs.h. */
6722 #include <stdarg.h>
6723 #include <stdbool.h>
6724 #include <stdlib.h>
6725 #include <wchar.h>
6726 #include <stdio.h>
6728 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6729 #define debug(...) fprintf (stderr, __VA_ARGS__)
6730 #define showlist(...) puts (#__VA_ARGS__)
6731 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6732 static void
6733 test_varargs_macros (void)
6735 int x = 1234;
6736 int y = 5678;
6737 debug ("Flag");
6738 debug ("X = %d\n", x);
6739 showlist (The first, second, and third items.);
6740 report (x>y, "x is %d but y is %d", x, y);
6743 // Check long long types.
6744 #define BIG64 18446744073709551615ull
6745 #define BIG32 4294967295ul
6746 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6747 #if !BIG_OK
6748 your preprocessor is broken;
6749 #endif
6750 #if BIG_OK
6751 #else
6752 your preprocessor is broken;
6753 #endif
6754 static long long int bignum = -9223372036854775807LL;
6755 static unsigned long long int ubignum = BIG64;
6757 struct incomplete_array
6759 int datasize;
6760 double data[];
6763 struct named_init {
6764 int number;
6765 const wchar_t *name;
6766 double average;
6769 typedef const char *ccp;
6771 static inline int
6772 test_restrict (ccp restrict text)
6774 // See if C++-style comments work.
6775 // Iterate through items via the restricted pointer.
6776 // Also check for declarations in for loops.
6777 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6778 continue;
6779 return 0;
6782 // Check varargs and va_copy.
6783 static void
6784 test_varargs (const char *format, ...)
6786 va_list args;
6787 va_start (args, format);
6788 va_list args_copy;
6789 va_copy (args_copy, args);
6791 const char *str;
6792 int number;
6793 float fnumber;
6795 while (*format)
6797 switch (*format++)
6799 case 's': // string
6800 str = va_arg (args_copy, const char *);
6801 break;
6802 case 'd': // int
6803 number = va_arg (args_copy, int);
6804 break;
6805 case 'f': // float
6806 fnumber = va_arg (args_copy, double);
6807 break;
6808 default:
6809 break;
6812 va_end (args_copy);
6813 va_end (args);
6817 main ()
6820 // Check bool.
6821 _Bool success = false;
6823 // Check restrict.
6824 if (test_restrict ("String literal") == 0)
6825 success = true;
6826 char *restrict newvar = "Another string";
6828 // Check varargs.
6829 test_varargs ("s, d' f .", "string", 65, 34.234);
6830 test_varargs_macros ();
6832 // Check flexible array members.
6833 struct incomplete_array *ia =
6834 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6835 ia->datasize = 10;
6836 for (int i = 0; i < ia->datasize; ++i)
6837 ia->data[i] = i * 1.234;
6839 // Check named initializers.
6840 struct named_init ni = {
6841 .number = 34,
6842 .name = L"Test wide string",
6843 .average = 543.34343,
6846 ni.number = 58;
6848 int dynamic_array[ni.number];
6849 dynamic_array[ni.number - 1] = 543;
6851 // work around unused variable warnings
6852 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6853 || dynamic_array[ni.number - 1] != 543);
6856 return 0;
6858 _ACEOF
6859 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6861 CC="$ac_save_CC $ac_arg"
6862 if ac_fn_c_try_compile "$LINENO"; then :
6863 ac_cv_prog_cc_c99=$ac_arg
6865 rm -f core conftest.err conftest.$ac_objext
6866 test "x$ac_cv_prog_cc_c99" != "xno" && break
6867 done
6868 rm -f conftest.$ac_ext
6869 CC=$ac_save_CC
6872 # AC_CACHE_VAL
6873 case "x$ac_cv_prog_cc_c99" in
6875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6876 $as_echo "none needed" >&6; } ;;
6877 xno)
6878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6879 $as_echo "unsupported" >&6; } ;;
6881 CC="$CC $ac_cv_prog_cc_c99"
6882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6883 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6884 esac
6885 if test "x$ac_cv_prog_cc_c99" != xno; then :
6886 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6887 else
6888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6889 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6890 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6891 $as_echo_n "(cached) " >&6
6892 else
6893 ac_cv_prog_cc_c89=no
6894 ac_save_CC=$CC
6895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6896 /* end confdefs.h. */
6897 #include <stdarg.h>
6898 #include <stdio.h>
6899 #include <sys/types.h>
6900 #include <sys/stat.h>
6901 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6902 struct buf { int x; };
6903 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6904 static char *e (p, i)
6905 char **p;
6906 int i;
6908 return p[i];
6910 static char *f (char * (*g) (char **, int), char **p, ...)
6912 char *s;
6913 va_list v;
6914 va_start (v,p);
6915 s = g (p, va_arg (v,int));
6916 va_end (v);
6917 return s;
6920 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6921 function prototypes and stuff, but not '\xHH' hex character constants.
6922 These don't provoke an error unfortunately, instead are silently treated
6923 as 'x'. The following induces an error, until -std is added to get
6924 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6925 array size at least. It's necessary to write '\x00'==0 to get something
6926 that's true only with -std. */
6927 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6929 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6930 inside strings and character constants. */
6931 #define FOO(x) 'x'
6932 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6934 int test (int i, double x);
6935 struct s1 {int (*f) (int a);};
6936 struct s2 {int (*f) (double a);};
6937 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6938 int argc;
6939 char **argv;
6941 main ()
6943 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6945 return 0;
6947 _ACEOF
6948 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6949 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6951 CC="$ac_save_CC $ac_arg"
6952 if ac_fn_c_try_compile "$LINENO"; then :
6953 ac_cv_prog_cc_c89=$ac_arg
6955 rm -f core conftest.err conftest.$ac_objext
6956 test "x$ac_cv_prog_cc_c89" != "xno" && break
6957 done
6958 rm -f conftest.$ac_ext
6959 CC=$ac_save_CC
6962 # AC_CACHE_VAL
6963 case "x$ac_cv_prog_cc_c89" in
6965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6966 $as_echo "none needed" >&6; } ;;
6967 xno)
6968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6969 $as_echo "unsupported" >&6; } ;;
6971 CC="$CC $ac_cv_prog_cc_c89"
6972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6973 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6974 esac
6975 if test "x$ac_cv_prog_cc_c89" != xno; then :
6976 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6977 else
6978 ac_cv_prog_cc_stdc=no
6983 esac
6984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6985 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6986 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6987 $as_echo_n "(cached) " >&6
6990 case $ac_cv_prog_cc_stdc in #(
6991 no) :
6992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6993 $as_echo "unsupported" >&6; } ;; #(
6994 '') :
6995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6996 $as_echo "none needed" >&6; } ;; #(
6997 *) :
6998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6999 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7000 esac
7004 # Code from module alloca-opt:
7005 # Code from module allocator:
7006 # Code from module c-ctype:
7007 # Code from module c-strcase:
7008 # Code from module careadlinkat:
7009 # Code from module clock-time:
7010 # Code from module close-stream:
7011 # Code from module crypto/md5:
7012 # Code from module crypto/sha1:
7013 # Code from module crypto/sha256:
7014 # Code from module crypto/sha512:
7015 # Code from module dosname:
7016 # Code from module dtoastr:
7017 # Code from module dtotimespec:
7018 # Code from module dup2:
7019 # Code from module environ:
7020 # Code from module euidaccess:
7021 # Code from module execinfo:
7022 # Code from module extensions:
7024 # Code from module extern-inline:
7025 # Code from module faccessat:
7026 # Code from module fcntl-h:
7027 # Code from module filemode:
7028 # Code from module fpending:
7029 # Code from module getgroups:
7030 # Code from module getloadavg:
7031 # Code from module getopt-gnu:
7032 # Code from module getopt-posix:
7033 # Code from module gettext-h:
7034 # Code from module gettime:
7035 # Code from module gettimeofday:
7036 # Code from module group-member:
7037 # Code from module ignore-value:
7038 # Code from module include_next:
7039 # Code from module intprops:
7040 # Code from module inttypes-incomplete:
7041 # Code from module largefile:
7043 # Code from module lstat:
7044 # Code from module manywarnings:
7045 # Code from module mktime:
7046 # Code from module multiarch:
7047 # Code from module nocrash:
7048 # Code from module pathmax:
7049 # Code from module pselect:
7050 # Code from module pthread_sigmask:
7051 # Code from module putenv:
7052 # Code from module readlink:
7053 # Code from module root-uid:
7054 # Code from module sig2str:
7055 # Code from module signal-h:
7056 # Code from module snippet/_Noreturn:
7057 # Code from module snippet/arg-nonnull:
7058 # Code from module snippet/c++defs:
7059 # Code from module snippet/warn-on-use:
7060 # Code from module socklen:
7061 # Code from module ssize_t:
7062 # Code from module stat:
7063 # Code from module stat-time:
7064 # Code from module stdalign:
7065 # Code from module stdarg:
7069 # Code from module stdbool:
7070 # Code from module stddef:
7071 # Code from module stdint:
7072 # Code from module stdio:
7073 # Code from module stdlib:
7074 # Code from module strftime:
7075 # Code from module strtoimax:
7076 # Code from module strtoll:
7077 # Code from module strtoull:
7078 # Code from module strtoumax:
7079 # Code from module symlink:
7080 # Code from module sys_select:
7081 # Code from module sys_stat:
7082 # Code from module sys_time:
7083 # Code from module time:
7084 # Code from module time_r:
7085 # Code from module timer-time:
7086 # Code from module timespec:
7087 # Code from module timespec-add:
7088 # Code from module timespec-sub:
7089 # Code from module u64:
7090 # Code from module unistd:
7091 # Code from module unsetenv:
7092 # Code from module utimens:
7093 # Code from module verify:
7094 # Code from module warnings:
7095 # Code from module xalloc-oversized:
7098 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7099 # if -g3 works and the user does not specify CFLAGS.
7100 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7101 if test "$ac_test_CFLAGS" != set; then
7102 case $CFLAGS in
7103 '-g')
7104 emacs_g3_CFLAGS='-g3';;
7105 '-g -O2')
7106 emacs_g3_CFLAGS='-g3 -O2';;
7108 emacs_g3_CFLAGS='';;
7109 esac
7110 if test -n "$emacs_g3_CFLAGS"; then
7111 emacs_save_CFLAGS=$CFLAGS
7112 CFLAGS=$emacs_g3_CFLAGS
7113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7114 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7115 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7116 $as_echo_n "(cached) " >&6
7117 else
7118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7119 /* end confdefs.h. */
7122 main ()
7126 return 0;
7128 _ACEOF
7129 if ac_fn_c_try_link "$LINENO"; then :
7130 emacs_cv_prog_cc_g3=yes
7131 else
7132 emacs_cv_prog_cc_g3=no
7134 rm -f core conftest.err conftest.$ac_objext \
7135 conftest$ac_exeext conftest.$ac_ext
7137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7138 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7139 if test $emacs_cv_prog_cc_g3 = yes; then
7140 CFLAGS=$emacs_g3_CFLAGS
7141 else
7142 CFLAGS=$emacs_save_CFLAGS
7147 # Check whether --enable-gcc-warnings was given.
7148 if test "${enable_gcc_warnings+set}" = set; then :
7149 enableval=$enable_gcc_warnings; case $enableval in
7150 yes|no) ;;
7151 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7152 esac
7153 gl_gcc_warnings=$enableval
7154 else
7155 gl_gcc_warnings=no
7160 # Check whether --enable-link-time-optimization was given.
7161 if test "${enable_link_time_optimization+set}" = set; then :
7162 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7164 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7165 ac_lto_supported=no
7166 if test x$GCC = xyes; then
7167 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7168 if test x$CPUS != x; then
7169 LTO="-flto=$CPUS"
7170 else
7171 LTO="-flto"
7173 old_CFLAGS=$CFLAGS
7174 CFLAGS="$CFLAGS $LTO"
7175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7176 /* end confdefs.h. */
7179 main ()
7183 return 0;
7185 _ACEOF
7186 if ac_fn_c_try_compile "$LINENO"; then :
7187 ac_lto_supported=yes
7188 else
7189 ac_lto_supported=no
7191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7192 CFLAGS="$old_CFLAGS"
7194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7195 $as_echo "$ac_lto_supported" >&6; }
7196 if test "$ac_lto_supported" = "yes"; then
7197 CFLAGS="$CFLAGS $LTO"
7203 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7204 # ------------------------------------------------
7205 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7206 # Otherwise, run RUN-IF-NOT-FOUND.
7209 # When compiling with GCC, prefer -isystem to -I when including system
7210 # include files, to avoid generating useless diagnostics for the files.
7211 if test "$gl_gcc_warnings" != yes; then
7212 isystem='-I'
7213 else
7214 isystem='-isystem '
7216 # This, $nw, is the list of warnings we disable.
7219 case $with_x_toolkit in
7220 lucid | athena | motif)
7221 # Old toolkits mishandle 'const'.
7222 nw="$nw -Wwrite-strings"
7225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7226 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7227 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7228 $as_echo_n "(cached) " >&6
7229 else
7231 gl_save_compiler_FLAGS="$CFLAGS"
7232 as_fn_append CFLAGS " -Werror"
7233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7234 /* end confdefs.h. */
7237 main ()
7241 return 0;
7243 _ACEOF
7244 if ac_fn_c_try_compile "$LINENO"; then :
7245 gl_cv_warn_c__Werror=yes
7246 else
7247 gl_cv_warn_c__Werror=no
7249 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7250 CFLAGS="$gl_save_compiler_FLAGS"
7253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7254 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7255 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7256 as_fn_append WERROR_CFLAGS " -Werror"
7261 esac
7264 nw="$nw -Waggregate-return" # anachronistic
7265 nw="$nw -Wlong-long" # C90 is anachronistic
7266 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7267 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7268 nw="$nw -Wtraditional" # Warns on #elif which we use often
7269 nw="$nw -Wcast-qual" # Too many warnings for now
7270 nw="$nw -Wconversion" # Too many warnings for now
7271 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7272 nw="$nw -Wsign-conversion" # Too many warnings for now
7273 nw="$nw -Woverlength-strings" # Not a problem these days
7274 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7275 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7276 nw="$nw -Wpadded" # Our structs are not padded
7277 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7278 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7279 nw="$nw -Wformat-nonliteral" # we do this a lot
7280 nw="$nw -Wvla" # warnings in gettext.h
7281 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7282 nw="$nw -Wswitch-enum" # Too many warnings for now
7283 nw="$nw -Wswitch-default" # Too many warnings for now
7284 nw="$nw -Wfloat-equal" # warns about high-quality code
7285 nw="$nw -Winline" # OK to ignore 'inline'
7286 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7287 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7288 # signed overflow has undefined behavior
7289 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7290 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7292 # Emacs doesn't care about shadowing; see
7293 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7294 nw="$nw -Wshadow"
7296 # The following line should be removable at some point.
7297 nw="$nw -Wsuggest-attribute=pure"
7299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use -Wstack-protector" >&5
7300 $as_echo_n "checking whether to use -Wstack-protector... " >&6; }
7301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7302 /* end confdefs.h. */
7303 #if (1 <= __LONG_MAX__ >> 31 >> 31 \
7304 && 4 < __GNUC__ + (7 < __GNUC_MINOR__ + (2 <= __GNUC_PATCHLEVEL__)))
7305 /* OK */
7306 #else
7307 #error "Not GCC, or GCC before 4.7.2, or 'long int' has < 64 bits."
7308 #endif
7311 main ()
7315 return 0;
7317 _ACEOF
7318 if ac_fn_c_try_cpp "$LINENO"; then :
7319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7320 $as_echo "yes" >&6; }
7321 else
7322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7323 $as_echo "no" >&6; }
7324 nw="$nw -Wstack-protector"
7326 rm -f conftest.err conftest.$ac_ext
7330 if test -n "$GCC"; then
7332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7333 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7334 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7335 $as_echo_n "(cached) " >&6
7336 else
7338 gl_save_CFLAGS="$CFLAGS"
7339 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7341 /* end confdefs.h. */
7344 main ()
7348 return 0;
7350 _ACEOF
7351 if ac_fn_c_try_compile "$LINENO"; then :
7352 gl_cv_cc_nomfi_supported=yes
7353 else
7354 gl_cv_cc_nomfi_supported=no
7356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7357 CFLAGS="$gl_save_CFLAGS"
7360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7361 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7363 if test "$gl_cv_cc_nomfi_supported" = yes; then
7364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7365 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7366 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7367 $as_echo_n "(cached) " >&6
7368 else
7370 gl_save_CFLAGS="$CFLAGS"
7371 CFLAGS="$CFLAGS -W -Werror"
7372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7373 /* end confdefs.h. */
7374 void f (void)
7376 typedef struct { int a; int b; } s_t;
7377 s_t s1 = { 0, };
7381 main ()
7385 return 0;
7387 _ACEOF
7388 if ac_fn_c_try_compile "$LINENO"; then :
7389 gl_cv_cc_nomfi_needed=no
7390 else
7391 gl_cv_cc_nomfi_needed=yes
7393 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7394 CFLAGS="$gl_save_CFLAGS"
7398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7399 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7403 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7404 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7405 $as_echo_n "(cached) " >&6
7406 else
7408 gl_save_CFLAGS="$CFLAGS"
7409 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7411 /* end confdefs.h. */
7414 main ()
7418 return 0;
7420 _ACEOF
7421 if ac_fn_c_try_compile "$LINENO"; then :
7422 gl_cv_cc_uninitialized_supported=yes
7423 else
7424 gl_cv_cc_uninitialized_supported=no
7426 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7427 CFLAGS="$gl_save_CFLAGS"
7430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7431 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7435 # List all gcc warning categories.
7436 gl_manywarn_set=
7437 for gl_manywarn_item in \
7438 -W \
7439 -Wabi \
7440 -Waddress \
7441 -Wall \
7442 -Warray-bounds \
7443 -Wattributes \
7444 -Wbad-function-cast \
7445 -Wbuiltin-macro-redefined \
7446 -Wcast-align \
7447 -Wchar-subscripts \
7448 -Wclobbered \
7449 -Wcomment \
7450 -Wcomments \
7451 -Wcoverage-mismatch \
7452 -Wcpp \
7453 -Wdeprecated \
7454 -Wdeprecated-declarations \
7455 -Wdisabled-optimization \
7456 -Wdiv-by-zero \
7457 -Wdouble-promotion \
7458 -Wempty-body \
7459 -Wendif-labels \
7460 -Wenum-compare \
7461 -Wextra \
7462 -Wformat-contains-nul \
7463 -Wformat-extra-args \
7464 -Wformat-nonliteral \
7465 -Wformat-security \
7466 -Wformat-y2k \
7467 -Wformat-zero-length \
7468 -Wformat=2 \
7469 -Wfree-nonheap-object \
7470 -Wignored-qualifiers \
7471 -Wimplicit \
7472 -Wimplicit-function-declaration \
7473 -Wimplicit-int \
7474 -Winit-self \
7475 -Winline \
7476 -Wint-to-pointer-cast \
7477 -Winvalid-memory-model \
7478 -Winvalid-pch \
7479 -Wjump-misses-init \
7480 -Wlogical-op \
7481 -Wmain \
7482 -Wmaybe-uninitialized \
7483 -Wmissing-braces \
7484 -Wmissing-declarations \
7485 -Wmissing-field-initializers \
7486 -Wmissing-format-attribute \
7487 -Wmissing-include-dirs \
7488 -Wmissing-noreturn \
7489 -Wmissing-parameter-type \
7490 -Wmissing-prototypes \
7491 -Wmudflap \
7492 -Wmultichar \
7493 -Wnarrowing \
7494 -Wnested-externs \
7495 -Wnonnull \
7496 -Wnormalized=nfc \
7497 -Wold-style-declaration \
7498 -Wold-style-definition \
7499 -Woverflow \
7500 -Woverlength-strings \
7501 -Woverride-init \
7502 -Wpacked \
7503 -Wpacked-bitfield-compat \
7504 -Wparentheses \
7505 -Wpointer-arith \
7506 -Wpointer-sign \
7507 -Wpointer-to-int-cast \
7508 -Wpragmas \
7509 -Wreturn-type \
7510 -Wsequence-point \
7511 -Wshadow \
7512 -Wsizeof-pointer-memaccess \
7513 -Wstack-protector \
7514 -Wstrict-aliasing \
7515 -Wstrict-overflow \
7516 -Wstrict-prototypes \
7517 -Wsuggest-attribute=const \
7518 -Wsuggest-attribute=format \
7519 -Wsuggest-attribute=noreturn \
7520 -Wsuggest-attribute=pure \
7521 -Wswitch \
7522 -Wswitch-default \
7523 -Wsync-nand \
7524 -Wsystem-headers \
7525 -Wtrampolines \
7526 -Wtrigraphs \
7527 -Wtype-limits \
7528 -Wuninitialized \
7529 -Wunknown-pragmas \
7530 -Wunreachable-code \
7531 -Wunsafe-loop-optimizations \
7532 -Wunused \
7533 -Wunused-but-set-parameter \
7534 -Wunused-but-set-variable \
7535 -Wunused-function \
7536 -Wunused-label \
7537 -Wunused-local-typedefs \
7538 -Wunused-macros \
7539 -Wunused-parameter \
7540 -Wunused-result \
7541 -Wunused-value \
7542 -Wunused-variable \
7543 -Wvarargs \
7544 -Wvariadic-macros \
7545 -Wvector-operation-performance \
7546 -Wvla \
7547 -Wvolatile-register-var \
7548 -Wwrite-strings \
7550 ; do
7551 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7552 done
7554 # Disable specific options as needed.
7555 if test "$gl_cv_cc_nomfi_needed" = yes; then
7556 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7559 if test "$gl_cv_cc_uninitialized_supported" = no; then
7560 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7563 ws=$gl_manywarn_set
7566 gl_warn_set=
7567 set x $ws; shift
7568 for gl_warn_item
7570 case " $nw " in
7571 *" $gl_warn_item "*)
7574 gl_warn_set="$gl_warn_set $gl_warn_item"
7576 esac
7577 done
7578 ws=$gl_warn_set
7580 for w in $ws; do
7581 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7583 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7584 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7585 $as_echo_n "(cached) " >&6
7586 else
7588 gl_save_compiler_FLAGS="$CFLAGS"
7589 as_fn_append CFLAGS " $w"
7590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7591 /* end confdefs.h. */
7594 main ()
7598 return 0;
7600 _ACEOF
7601 if ac_fn_c_try_compile "$LINENO"; then :
7602 eval "$as_gl_Warn=yes"
7603 else
7604 eval "$as_gl_Warn=no"
7606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7607 CFLAGS="$gl_save_compiler_FLAGS"
7610 eval ac_res=\$$as_gl_Warn
7611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7612 $as_echo "$ac_res" >&6; }
7613 eval as_val=\$$as_gl_Warn
7614 if test "x$as_val" = x""yes; then :
7615 as_fn_append WARN_CFLAGS " $w"
7619 done
7620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7621 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7622 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7623 $as_echo_n "(cached) " >&6
7624 else
7626 gl_save_compiler_FLAGS="$CFLAGS"
7627 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7629 /* end confdefs.h. */
7632 main ()
7636 return 0;
7638 _ACEOF
7639 if ac_fn_c_try_compile "$LINENO"; then :
7640 gl_cv_warn_c__Wno_missing_field_initializers=yes
7641 else
7642 gl_cv_warn_c__Wno_missing_field_initializers=no
7644 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7645 CFLAGS="$gl_save_compiler_FLAGS"
7648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7649 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7650 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7651 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7654 # We need this one
7655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7656 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7657 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7658 $as_echo_n "(cached) " >&6
7659 else
7661 gl_save_compiler_FLAGS="$CFLAGS"
7662 as_fn_append CFLAGS " -Wno-sign-compare"
7663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7664 /* end confdefs.h. */
7667 main ()
7671 return 0;
7673 _ACEOF
7674 if ac_fn_c_try_compile "$LINENO"; then :
7675 gl_cv_warn_c__Wno_sign_compare=yes
7676 else
7677 gl_cv_warn_c__Wno_sign_compare=no
7679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7680 CFLAGS="$gl_save_compiler_FLAGS"
7683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7684 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7685 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7686 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7689 # Too many warnings for now
7690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7691 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7692 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7693 $as_echo_n "(cached) " >&6
7694 else
7696 gl_save_compiler_FLAGS="$CFLAGS"
7697 as_fn_append CFLAGS " -Wno-type-limits"
7698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7699 /* end confdefs.h. */
7702 main ()
7706 return 0;
7708 _ACEOF
7709 if ac_fn_c_try_compile "$LINENO"; then :
7710 gl_cv_warn_c__Wno_type_limits=yes
7711 else
7712 gl_cv_warn_c__Wno_type_limits=no
7714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7715 CFLAGS="$gl_save_compiler_FLAGS"
7718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7719 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7720 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7721 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7724 # Too many warnings for now
7725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7726 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7727 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7728 $as_echo_n "(cached) " >&6
7729 else
7731 gl_save_compiler_FLAGS="$CFLAGS"
7732 as_fn_append CFLAGS " -Wno-switch"
7733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7734 /* end confdefs.h. */
7737 main ()
7741 return 0;
7743 _ACEOF
7744 if ac_fn_c_try_compile "$LINENO"; then :
7745 gl_cv_warn_c__Wno_switch=yes
7746 else
7747 gl_cv_warn_c__Wno_switch=no
7749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7750 CFLAGS="$gl_save_compiler_FLAGS"
7753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7754 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7755 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7756 as_fn_append WARN_CFLAGS " -Wno-switch"
7759 # Too many warnings for now
7760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7761 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7762 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7763 $as_echo_n "(cached) " >&6
7764 else
7766 gl_save_compiler_FLAGS="$CFLAGS"
7767 as_fn_append CFLAGS " -Wno-unused-parameter"
7768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7769 /* end confdefs.h. */
7772 main ()
7776 return 0;
7778 _ACEOF
7779 if ac_fn_c_try_compile "$LINENO"; then :
7780 gl_cv_warn_c__Wno_unused_parameter=yes
7781 else
7782 gl_cv_warn_c__Wno_unused_parameter=no
7784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7785 CFLAGS="$gl_save_compiler_FLAGS"
7788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7789 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7790 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7791 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7794 # Too many warnings for now
7795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7796 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7797 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7798 $as_echo_n "(cached) " >&6
7799 else
7801 gl_save_compiler_FLAGS="$CFLAGS"
7802 as_fn_append CFLAGS " -Wno-format-nonliteral"
7803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7804 /* end confdefs.h. */
7807 main ()
7811 return 0;
7813 _ACEOF
7814 if ac_fn_c_try_compile "$LINENO"; then :
7815 gl_cv_warn_c__Wno_format_nonliteral=yes
7816 else
7817 gl_cv_warn_c__Wno_format_nonliteral=no
7819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7820 CFLAGS="$gl_save_compiler_FLAGS"
7823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7824 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7825 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7826 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7831 # In spite of excluding -Wlogical-op above, it is enabled, as of
7832 # gcc 4.5.0 20090517.
7833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7834 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7835 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7836 $as_echo_n "(cached) " >&6
7837 else
7839 gl_save_compiler_FLAGS="$CFLAGS"
7840 as_fn_append CFLAGS " -Wno-logical-op"
7841 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7842 /* end confdefs.h. */
7845 main ()
7849 return 0;
7851 _ACEOF
7852 if ac_fn_c_try_compile "$LINENO"; then :
7853 gl_cv_warn_c__Wno_logical_op=yes
7854 else
7855 gl_cv_warn_c__Wno_logical_op=no
7857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7858 CFLAGS="$gl_save_compiler_FLAGS"
7861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7862 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7863 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7864 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7870 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7871 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7872 $as_echo_n "(cached) " >&6
7873 else
7875 gl_save_compiler_FLAGS="$CFLAGS"
7876 as_fn_append CFLAGS " -fdiagnostics-show-option"
7877 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7878 /* end confdefs.h. */
7881 main ()
7885 return 0;
7887 _ACEOF
7888 if ac_fn_c_try_compile "$LINENO"; then :
7889 gl_cv_warn_c__fdiagnostics_show_option=yes
7890 else
7891 gl_cv_warn_c__fdiagnostics_show_option=no
7893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7894 CFLAGS="$gl_save_compiler_FLAGS"
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7898 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7899 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7900 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7905 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7906 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7907 $as_echo_n "(cached) " >&6
7908 else
7910 gl_save_compiler_FLAGS="$CFLAGS"
7911 as_fn_append CFLAGS " -funit-at-a-time"
7912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7913 /* end confdefs.h. */
7916 main ()
7920 return 0;
7922 _ACEOF
7923 if ac_fn_c_try_compile "$LINENO"; then :
7924 gl_cv_warn_c__funit_at_a_time=yes
7925 else
7926 gl_cv_warn_c__funit_at_a_time=no
7928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7929 CFLAGS="$gl_save_compiler_FLAGS"
7932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7933 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7934 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7935 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7941 $as_echo "#define lint 1" >>confdefs.h
7945 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7948 # We use a slightly smaller set of warning options for lib/.
7949 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7951 nw="$nw -Wunused-macros"
7954 gl_warn_set=
7955 set x $WARN_CFLAGS; shift
7956 for gl_warn_item
7958 case " $nw " in
7959 *" $gl_warn_item "*)
7962 gl_warn_set="$gl_warn_set $gl_warn_item"
7964 esac
7965 done
7966 GNULIB_WARN_CFLAGS=$gl_warn_set
7973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7974 $as_echo_n "checking whether ln -s works... " >&6; }
7975 LN_S=$as_ln_s
7976 if test "$LN_S" = "ln -s"; then
7977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7978 $as_echo "yes" >&6; }
7979 else
7980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7981 $as_echo "no, using $LN_S" >&6; }
7985 # Extract the first word of "install-info", so it can be a program name with args.
7986 set dummy install-info; ac_word=$2
7987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7988 $as_echo_n "checking for $ac_word... " >&6; }
7989 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7990 $as_echo_n "(cached) " >&6
7991 else
7992 case $INSTALL_INFO in
7993 [\\/]* | ?:[\\/]*)
7994 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7998 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8000 IFS=$as_save_IFS
8001 test -z "$as_dir" && as_dir=.
8002 for ac_exec_ext in '' $ac_executable_extensions; do
8003 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8004 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8006 break 2
8008 done
8009 done
8010 IFS=$as_save_IFS
8012 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8014 esac
8016 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8017 if test -n "$INSTALL_INFO"; then
8018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8019 $as_echo "$INSTALL_INFO" >&6; }
8020 else
8021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8022 $as_echo "no" >&6; }
8026 # Extract the first word of "gzip", so it can be a program name with args.
8027 set dummy gzip; ac_word=$2
8028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8029 $as_echo_n "checking for $ac_word... " >&6; }
8030 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8031 $as_echo_n "(cached) " >&6
8032 else
8033 case $GZIP_PROG in
8034 [\\/]* | ?:[\\/]*)
8035 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8038 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8039 for as_dir in $PATH
8041 IFS=$as_save_IFS
8042 test -z "$as_dir" && as_dir=.
8043 for ac_exec_ext in '' $ac_executable_extensions; do
8044 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8045 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8046 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8047 break 2
8049 done
8050 done
8051 IFS=$as_save_IFS
8054 esac
8056 GZIP_PROG=$ac_cv_path_GZIP_PROG
8057 if test -n "$GZIP_PROG"; then
8058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8059 $as_echo "$GZIP_PROG" >&6; }
8060 else
8061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8062 $as_echo "no" >&6; }
8067 if test $opsys = gnu-linux; then
8068 # Extract the first word of "paxctl", so it can be a program name with args.
8069 set dummy paxctl; ac_word=$2
8070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8071 $as_echo_n "checking for $ac_word... " >&6; }
8072 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8073 $as_echo_n "(cached) " >&6
8074 else
8075 case $PAXCTL in
8076 [\\/]* | ?:[\\/]*)
8077 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8081 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8083 IFS=$as_save_IFS
8084 test -z "$as_dir" && as_dir=.
8085 for ac_exec_ext in '' $ac_executable_extensions; do
8086 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8087 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8089 break 2
8091 done
8092 done
8093 IFS=$as_save_IFS
8096 esac
8098 PAXCTL=$ac_cv_path_PAXCTL
8099 if test -n "$PAXCTL"; then
8100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8101 $as_echo "$PAXCTL" >&6; }
8102 else
8103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8104 $as_echo "no" >&6; }
8108 if test "X$PAXCTL" != X; then
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8110 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8111 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8112 /* end confdefs.h. */
8115 main ()
8119 return 0;
8121 _ACEOF
8122 if ac_fn_c_try_link "$LINENO"; then :
8123 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8124 $as_echo "yes" >&6; }
8125 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8126 $as_echo "no" >&6; }; PAXCTL=""; fi
8128 rm -f core conftest.err conftest.$ac_objext \
8129 conftest$ac_exeext conftest.$ac_ext
8133 ## Need makeinfo >= 4.7 (?) to build the manuals.
8134 # Extract the first word of "makeinfo", so it can be a program name with args.
8135 set dummy makeinfo; ac_word=$2
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8137 $as_echo_n "checking for $ac_word... " >&6; }
8138 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8139 $as_echo_n "(cached) " >&6
8140 else
8141 case $MAKEINFO in
8142 [\\/]* | ?:[\\/]*)
8143 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8147 for as_dir in $PATH
8149 IFS=$as_save_IFS
8150 test -z "$as_dir" && as_dir=.
8151 for ac_exec_ext in '' $ac_executable_extensions; do
8152 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8153 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8155 break 2
8157 done
8158 done
8159 IFS=$as_save_IFS
8161 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8163 esac
8165 MAKEINFO=$ac_cv_path_MAKEINFO
8166 if test -n "$MAKEINFO"; then
8167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8168 $as_echo "$MAKEINFO" >&6; }
8169 else
8170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8171 $as_echo "no" >&6; }
8175 if test "$MAKEINFO" != "no"; then
8176 case `
8177 $MAKEINFO --version 2> /dev/null |
8178 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8179 ` in
8180 '') MAKEINFO=no;;
8181 esac
8184 ## Makeinfo is unusual. For a released Emacs, the manuals are
8185 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8186 ## therefore in the category of "special tools" not normally required, which
8187 ## configure does not have to check for (eg autoconf itself).
8188 ## In a Bazaar checkout on the other hand, the manuals are not included.
8189 ## So makeinfo is a requirement to build from Bazaar, and configure
8190 ## should test for it as it does for any other build requirement.
8191 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8192 ## with pre-built manuals, from a Bazaar checkout.
8193 HAVE_MAKEINFO=yes
8195 if test "$MAKEINFO" = "no"; then
8196 MAKEINFO=makeinfo
8197 if test "x${with_makeinfo}" = "xno"; then
8198 HAVE_MAKEINFO=no
8199 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8200 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8201 source tree does not seem to have pre-built manuals in the \`info' directory.
8202 Either install a suitable version of makeinfo, or re-run configure
8203 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8208 INFO_EXT=.info
8209 INFO_OPTS=--no-split
8214 if test x$GCC = xyes; then
8215 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8216 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8217 else
8218 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8219 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8223 late_LDFLAGS=$LDFLAGS
8224 if test x$GCC = xyes; then
8225 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8226 else
8227 LDFLAGS="$LDFLAGS -znocombreloc"
8230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8231 $as_echo_n "checking for -znocombreloc... " >&6; }
8232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8233 /* end confdefs.h. */
8236 main ()
8240 return 0;
8242 _ACEOF
8243 if ac_fn_c_try_link "$LINENO"; then :
8244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8245 $as_echo "yes" >&6; }
8246 else
8247 LDFLAGS=$late_LDFLAGS
8248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8249 $as_echo "no" >&6; }
8251 rm -f core conftest.err conftest.$ac_objext \
8252 conftest$ac_exeext conftest.$ac_ext
8255 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8256 case "$opsys" in
8257 your-opsys-here) CANNOT_DUMP=yes ;;
8258 esac
8260 test "$CANNOT_DUMP" = "yes" && \
8262 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8268 UNEXEC_OBJ=unexelf.o
8269 case "$opsys" in
8270 # MSDOS uses unexcoff.o
8271 # MSWindows uses unexw32.o
8272 aix4-2)
8273 UNEXEC_OBJ=unexaix.o
8275 cygwin)
8276 UNEXEC_OBJ=unexcw.o
8278 darwin)
8279 UNEXEC_OBJ=unexmacosx.o
8281 hpux10-20 | hpux11)
8282 UNEXEC_OBJ=unexhp9k800.o
8284 sol2-10)
8285 # Use the Solaris dldump() function, called from unexsol.c, to dump
8286 # emacs, instead of the generic ELF dump code found in unexelf.c.
8287 # The resulting binary has a complete symbol table, and is better
8288 # for debugging and other observability tools (debuggers, pstack, etc).
8290 # If you encounter a problem using dldump(), please consider sending
8291 # a message to the OpenSolaris tools-linking mailing list:
8292 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8294 # It is likely that dldump() works with older Solaris too, but this has
8295 # not been tested, so for now this change is for Solaris 10 or newer.
8296 UNEXEC_OBJ=unexsol.o
8298 esac
8300 LD_SWITCH_SYSTEM=
8301 case "$opsys" in
8302 freebsd)
8303 ## Let `ld' find image libs and similar things in /usr/local/lib.
8304 ## The system compiler, GCC, has apparently been modified to not
8305 ## look there, contrary to what a stock GCC would do.
8306 ### It's not our place to do this. See bug#10313#17.
8307 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8311 gnu-linux)
8312 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8313 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8316 netbsd)
8317 ### It's not our place to do this. See bug#10313#17.
8318 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8322 openbsd)
8323 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8324 ## otherwise Emacs dumps core on elf systems.
8325 LD_SWITCH_SYSTEM="-Z"
8327 esac
8330 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8332 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8333 ## which has not been defined yet. When this was handled with cpp,
8334 ## it was expanded to null when configure sourced the s/*.h file.
8335 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8336 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8337 ## (or somesuch), but because it is supposed to go at the _front_
8338 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8339 ## Compare with the gnu-linux case below, which added to the end
8340 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8341 ## LD_SWITCH_SYSTEM_TEMACS.
8342 case "$opsys" in
8343 netbsd|openbsd)
8344 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8345 esac
8348 C_SWITCH_MACHINE=
8349 case $canonical in
8350 alpha*)
8351 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8352 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8356 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8357 ## With ELF, make sure that all common symbols get allocated to in the
8358 ## data section. Otherwise, the dump of temacs may miss variables in
8359 ## the shared library that have been initialized. For example, with
8360 ## GNU libc, __malloc_initialized would normally be resolved to the
8361 ## shared library's .bss section, which is fatal.
8362 if test "x$GCC" = "xyes"; then
8363 C_SWITCH_MACHINE="-fno-common"
8364 else
8365 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8367 else
8368 UNEXEC_OBJ=unexalpha.o
8371 esac
8376 C_SWITCH_SYSTEM=
8377 ## Some programs in src produce warnings saying certain subprograms
8378 ## are too complex and need a MAXMEM value greater than 2000 for
8379 ## additional optimization. --nils@exp-math.uni-essen.de
8380 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8381 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8382 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8383 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8387 LIBS_SYSTEM=
8388 case "$opsys" in
8389 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8390 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8392 freebsd) LIBS_SYSTEM="-lutil" ;;
8394 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8396 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8398 ## Motif needs -lgen.
8399 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8400 esac
8404 ### Make sure subsequent tests use flags consistent with the build flags.
8406 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8407 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8408 else
8409 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8412 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8414 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8418 LIB_MATH=-lm
8419 LIB_STANDARD=
8420 START_FILES=
8421 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8423 case $opsys in
8424 cygwin )
8425 LIB_MATH=
8426 START_FILES='pre-crt0.o'
8428 darwin )
8429 ## Adding -lm confuses the dynamic linker, so omit it.
8430 LIB_MATH=
8431 START_FILES='pre-crt0.o'
8433 freebsd )
8434 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8435 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8436 SYSTEM_TYPE=berkeley-unix
8438 gnu-linux | gnu-kfreebsd )
8439 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8440 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8442 hpux10-20 | hpux11 )
8443 LIB_STANDARD=-lc
8444 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8446 netbsd | openbsd )
8447 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8448 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8449 SYSTEM_TYPE=berkeley-unix
8452 sol2* | unixware )
8453 SYSTEM_TYPE=usg-unix-v
8456 esac
8461 cat >>confdefs.h <<_ACEOF
8462 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8463 _ACEOF
8466 crt_files=
8468 for file in x $LIB_STANDARD $START_FILES; do
8469 case "$file" in
8470 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8471 esac
8472 done
8474 if test "x$crt_files" != x; then
8476 ## If user specified a crt-dir, use that unconditionally.
8477 crt_gcc=no
8479 if test "X$CRT_DIR" = "X"; then
8481 CRT_DIR=/usr/lib # default
8483 case "$canonical" in
8484 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8485 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8486 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8487 ## For anything else (eg /usr/lib32), it is up the user to specify
8488 ## the location (bug#5655).
8489 ## Test for crtn.o, not just the directory, because sometimes the
8490 ## directory exists but does not have the relevant files (bug#1287).
8491 ## FIXME better to test for binary compatibility somehow.
8492 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8495 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8496 esac
8498 case "$opsys" in
8499 hpux10-20) CRT_DIR=/lib ;;
8500 esac
8502 test "x${GCC}" = xyes && crt_gcc=yes
8504 fi # CRT_DIR = ""
8506 crt_missing=
8508 for file in $crt_files; do
8510 ## If we're using gcc, try to determine it automatically by asking
8511 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8512 ## system-dependent default from above.]
8513 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8515 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8516 case "$crt_file" in
8517 */*)
8518 CRT_DIR=`$as_dirname -- "$crt_file" ||
8519 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8520 X"$crt_file" : 'X\(//\)[^/]' \| \
8521 X"$crt_file" : 'X\(//\)$' \| \
8522 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8523 $as_echo X"$crt_file" |
8524 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8525 s//\1/
8528 /^X\(\/\/\)[^/].*/{
8529 s//\1/
8532 /^X\(\/\/\)$/{
8533 s//\1/
8536 /^X\(\/\).*/{
8537 s//\1/
8540 s/.*/./; q'`
8542 esac
8545 crt_gcc=no
8547 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8548 done # $crt_files
8550 test "x$crt_missing" = x || \
8551 as_fn_error "Required file(s) not found:$crt_missing
8552 Try using the --with-crt-dir option." "$LINENO" 5
8554 fi # crt_files != ""
8558 case $opsys in
8559 netbsd | openbsd )
8560 if test -f $CRT_DIR/crti.o; then
8562 test -f $CRT_DIR/crtn.o || \
8563 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8565 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8566 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8569 esac
8572 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8573 pre_PKG_CONFIG_LIBS=$LIBS
8575 # Extract the first word of "pkg-config", so it can be a program name with args.
8576 set dummy pkg-config; ac_word=$2
8577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8578 $as_echo_n "checking for $ac_word... " >&6; }
8579 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8580 $as_echo_n "(cached) " >&6
8581 else
8582 case $PKG_CONFIG in
8583 [\\/]* | ?:[\\/]*)
8584 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8588 for as_dir in $PATH
8590 IFS=$as_save_IFS
8591 test -z "$as_dir" && as_dir=.
8592 for ac_exec_ext in '' $ac_executable_extensions; do
8593 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8594 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8595 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8596 break 2
8598 done
8599 done
8600 IFS=$as_save_IFS
8602 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8604 esac
8606 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8607 if test -n "$PKG_CONFIG"; then
8608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8609 $as_echo "$PKG_CONFIG" >&6; }
8610 else
8611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8612 $as_echo "no" >&6; }
8620 if test "${with_sound}" != "no"; then
8621 # Sound support for GNU/Linux and the free BSDs.
8622 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8623 do :
8624 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8625 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8626 eval as_val=\$$as_ac_Header
8627 if test "x$as_val" = x""yes; then :
8628 cat >>confdefs.h <<_ACEOF
8629 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8630 _ACEOF
8631 have_sound_header=yes
8634 done
8636 # Emulation library used on NetBSD.
8637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8638 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8639 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8640 $as_echo_n "(cached) " >&6
8641 else
8642 ac_check_lib_save_LIBS=$LIBS
8643 LIBS="-lossaudio $LIBS"
8644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8645 /* end confdefs.h. */
8647 /* Override any GCC internal prototype to avoid an error.
8648 Use char because int might match the return type of a GCC
8649 builtin and then its argument prototype would still apply. */
8650 #ifdef __cplusplus
8651 extern "C"
8652 #endif
8653 char _oss_ioctl ();
8655 main ()
8657 return _oss_ioctl ();
8659 return 0;
8661 _ACEOF
8662 if ac_fn_c_try_link "$LINENO"; then :
8663 ac_cv_lib_ossaudio__oss_ioctl=yes
8664 else
8665 ac_cv_lib_ossaudio__oss_ioctl=no
8667 rm -f core conftest.err conftest.$ac_objext \
8668 conftest$ac_exeext conftest.$ac_ext
8669 LIBS=$ac_check_lib_save_LIBS
8671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8672 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8673 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8674 LIBSOUND=-lossaudio
8675 else
8676 LIBSOUND=
8681 ALSA_REQUIRED=1.0.0
8682 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8684 succeeded=no
8686 if test "$PKG_CONFIG" = "no" ; then
8687 HAVE_ALSA=no
8688 else
8689 PKG_CONFIG_MIN_VERSION=0.9.0
8690 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8692 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8694 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
8695 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
8696 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
8697 edit_cflags="
8698 s,///*,/,g
8699 s/^/ /
8700 s/ -I/ $isystem/g
8701 s/^ //
8703 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8704 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8706 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8707 succeeded=yes
8708 else
8709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8710 $as_echo "no" >&6; }
8711 ALSA_CFLAGS=""
8712 ALSA_LIBS=""
8713 ## If we have a custom action on failure, don't print errors, but
8714 ## do set a variable so people can do so. Do it in a subshell
8715 ## to capture any diagnostics in invoking pkg-config.
8716 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
8722 else
8723 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8724 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8728 if test $succeeded = yes; then
8729 HAVE_ALSA=yes
8730 else
8731 HAVE_ALSA=no
8734 if test $HAVE_ALSA = yes; then
8735 SAVE_CFLAGS="$CFLAGS"
8736 SAVE_LIBS="$LIBS"
8737 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8738 LIBS="$ALSA_LIBS $LIBS"
8739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8740 /* end confdefs.h. */
8741 #include <asoundlib.h>
8743 main ()
8745 snd_lib_error_set_handler (0);
8747 return 0;
8749 _ACEOF
8750 if ac_fn_c_try_compile "$LINENO"; then :
8751 emacs_alsa_normal=yes
8752 else
8753 emacs_alsa_normal=no
8755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8756 if test "$emacs_alsa_normal" != yes; then
8757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8758 /* end confdefs.h. */
8759 #include <alsa/asoundlib.h>
8761 main ()
8763 snd_lib_error_set_handler (0);
8765 return 0;
8767 _ACEOF
8768 if ac_fn_c_try_compile "$LINENO"; then :
8769 emacs_alsa_subdir=yes
8770 else
8771 emacs_alsa_subdir=no
8773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8774 if test "$emacs_alsa_subdir" != yes; then
8775 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8777 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8780 CFLAGS="$SAVE_CFLAGS"
8781 LIBS="$SAVE_LIBS"
8782 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8783 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8785 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8789 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8790 case "$opsys" in
8791 gnu-linux|freebsd|netbsd)
8793 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8796 esac
8805 for ac_header in $ac_header_list
8806 do :
8807 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8808 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8810 eval as_val=\$$as_ac_Header
8811 if test "x$as_val" = x""yes; then :
8812 cat >>confdefs.h <<_ACEOF
8813 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8814 _ACEOF
8818 done
8842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8843 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8845 /* end confdefs.h. */
8846 #include <sys/personality.h>
8848 main ()
8850 personality (PER_LINUX32)
8852 return 0;
8854 _ACEOF
8855 if ac_fn_c_try_compile "$LINENO"; then :
8856 emacs_cv_personality_linux32=yes
8857 else
8858 emacs_cv_personality_linux32=no
8860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8862 $as_echo "$emacs_cv_personality_linux32" >&6; }
8864 if test $emacs_cv_personality_linux32 = yes; then
8866 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8870 for ac_header in term.h
8871 do :
8872 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8873 if test "x$ac_cv_header_term_h" = x""yes; then :
8874 cat >>confdefs.h <<_ACEOF
8875 #define HAVE_TERM_H 1
8876 _ACEOF
8880 done
8882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8883 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8884 if test "${ac_cv_header_time+set}" = set; then :
8885 $as_echo_n "(cached) " >&6
8886 else
8887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8888 /* end confdefs.h. */
8889 #include <sys/types.h>
8890 #include <sys/time.h>
8891 #include <time.h>
8894 main ()
8896 if ((struct tm *) 0)
8897 return 0;
8899 return 0;
8901 _ACEOF
8902 if ac_fn_c_try_compile "$LINENO"; then :
8903 ac_cv_header_time=yes
8904 else
8905 ac_cv_header_time=no
8907 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8910 $as_echo "$ac_cv_header_time" >&6; }
8911 if test $ac_cv_header_time = yes; then
8913 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8917 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
8920 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8921 ac_have_decl=1
8922 else
8923 ac_have_decl=0
8926 cat >>confdefs.h <<_ACEOF
8927 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8928 _ACEOF
8930 if test $ac_cv_have_decl_sys_siglist != yes; then
8931 # For Tru64, at least:
8932 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
8935 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8936 ac_have_decl=1
8937 else
8938 ac_have_decl=0
8941 cat >>confdefs.h <<_ACEOF
8942 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8943 _ACEOF
8945 if test $ac_cv_have_decl___sys_siglist = yes; then
8947 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8952 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8953 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8954 $as_echo_n "(cached) " >&6
8955 else
8956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8957 /* end confdefs.h. */
8958 #include <sys/types.h>
8959 #include <sys/wait.h>
8960 #ifndef WEXITSTATUS
8961 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8962 #endif
8963 #ifndef WIFEXITED
8964 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8965 #endif
8968 main ()
8970 int s;
8971 wait (&s);
8972 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8974 return 0;
8976 _ACEOF
8977 if ac_fn_c_try_compile "$LINENO"; then :
8978 ac_cv_header_sys_wait_h=yes
8979 else
8980 ac_cv_header_sys_wait_h=no
8982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8985 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8986 if test $ac_cv_header_sys_wait_h = yes; then
8988 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8994 $as_echo_n "checking for speed_t... " >&6; }
8995 if test "${emacs_cv_speed_t+set}" = set; then :
8996 $as_echo_n "(cached) " >&6
8997 else
8998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8999 /* end confdefs.h. */
9000 #include <termios.h>
9002 main ()
9004 speed_t x = 1;
9006 return 0;
9008 _ACEOF
9009 if ac_fn_c_try_compile "$LINENO"; then :
9010 emacs_cv_speed_t=yes
9011 else
9012 emacs_cv_speed_t=no
9014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
9017 $as_echo "$emacs_cv_speed_t" >&6; }
9018 if test $emacs_cv_speed_t = yes; then
9020 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
9027 for ac_header in net/if.h
9028 do :
9029 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9030 #if HAVE_SYS_SOCKET_H
9031 #include <sys/socket.h>
9032 #endif
9034 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9035 cat >>confdefs.h <<_ACEOF
9036 #define HAVE_NET_IF_H 1
9037 _ACEOF
9041 done
9043 for ac_header in ifaddrs.h
9044 do :
9045 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9046 #if HAVE_SYS_SOCKET_H
9047 #include <sys/socket.h>
9048 #endif
9050 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9051 cat >>confdefs.h <<_ACEOF
9052 #define HAVE_IFADDRS_H 1
9053 _ACEOF
9057 done
9059 for ac_header in net/if_dl.h
9060 do :
9061 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9062 #if HAVE_SYS_SOCKET_H
9063 #include <sys/socket.h>
9064 #endif
9066 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9067 cat >>confdefs.h <<_ACEOF
9068 #define HAVE_NET_IF_DL_H 1
9069 _ACEOF
9073 done
9076 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9077 #if HAVE_SYS_SOCKET_H
9078 #include <sys/socket.h>
9079 #endif
9080 #if HAVE_NET_IF_H
9081 #include <net/if.h>
9082 #endif
9084 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9086 cat >>confdefs.h <<_ACEOF
9087 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9088 _ACEOF
9092 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9093 #if HAVE_SYS_SOCKET_H
9094 #include <sys/socket.h>
9095 #endif
9096 #if HAVE_NET_IF_H
9097 #include <net/if.h>
9098 #endif
9100 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9102 cat >>confdefs.h <<_ACEOF
9103 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9104 _ACEOF
9108 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9109 #if HAVE_SYS_SOCKET_H
9110 #include <sys/socket.h>
9111 #endif
9112 #if HAVE_NET_IF_H
9113 #include <net/if.h>
9114 #endif
9116 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9118 cat >>confdefs.h <<_ACEOF
9119 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9120 _ACEOF
9124 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9125 #if HAVE_SYS_SOCKET_H
9126 #include <sys/socket.h>
9127 #endif
9128 #if HAVE_NET_IF_H
9129 #include <net/if.h>
9130 #endif
9132 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9134 cat >>confdefs.h <<_ACEOF
9135 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9136 _ACEOF
9140 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9141 #if HAVE_SYS_SOCKET_H
9142 #include <sys/socket.h>
9143 #endif
9144 #if HAVE_NET_IF_H
9145 #include <net/if.h>
9146 #endif
9148 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9150 cat >>confdefs.h <<_ACEOF
9151 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9152 _ACEOF
9156 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9157 #if HAVE_SYS_SOCKET_H
9158 #include <sys/socket.h>
9159 #endif
9160 #if HAVE_NET_IF_H
9161 #include <net/if.h>
9162 #endif
9164 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9166 cat >>confdefs.h <<_ACEOF
9167 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9168 _ACEOF
9176 DEPFLAGS=
9177 MKDEPDIR=":"
9178 deps_frag=deps.mk
9179 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9181 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9182 HAVE_GNU_MAKE=no
9183 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9184 if test "x$testval" != x; then
9185 HAVE_GNU_MAKE=yes
9186 else
9187 ac_enable_autodepend=no
9189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9190 $as_echo "$HAVE_GNU_MAKE" >&6; }
9191 if test $HAVE_GNU_MAKE = yes; then
9192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9193 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9194 SAVE_CFLAGS="$CFLAGS"
9195 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9197 /* end confdefs.h. */
9200 main ()
9204 return 0;
9206 _ACEOF
9207 if ac_fn_c_try_compile "$LINENO"; then :
9209 else
9210 ac_enable_autodepend=no
9212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9213 CFLAGS="$SAVE_CFLAGS"
9214 test -f deps.d || ac_enable_autodepend=no
9215 rm -rf deps.d
9216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9217 $as_echo "$ac_enable_autodepend" >&6; }
9219 if test $ac_enable_autodepend = yes; then
9220 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9221 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9222 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9223 deps_frag=autodeps.mk
9226 deps_frag=$srcdir/src/$deps_frag
9232 lisp_frag=$srcdir/src/lisp.mk
9236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9237 $as_echo_n "checking for long file names... " >&6; }
9238 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9239 $as_echo_n "(cached) " >&6
9240 else
9241 ac_cv_sys_long_file_names=yes
9242 # Test for long file names in all the places we know might matter:
9243 # . the current directory, where building will happen
9244 # $prefix/lib where we will be installing things
9245 # $exec_prefix/lib likewise
9246 # $TMPDIR if set, where it might want to write temporary files
9247 # /tmp where it might want to write temporary files
9248 # /var/tmp likewise
9249 # /usr/tmp likewise
9250 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9251 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9252 # in the usual case where exec_prefix is '${prefix}'.
9253 case $ac_dir in #(
9254 . | /* | ?:[\\/]*) ;; #(
9255 *) continue;;
9256 esac
9257 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9258 ac_xdir=$ac_dir/cf$$
9259 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9260 ac_tf1=$ac_xdir/conftest9012345
9261 ac_tf2=$ac_xdir/conftest9012346
9262 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9263 ac_cv_sys_long_file_names=no
9264 rm -f -r "$ac_xdir" 2>/dev/null
9265 test $ac_cv_sys_long_file_names = no && break
9266 done
9268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9269 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9270 if test $ac_cv_sys_long_file_names = yes; then
9272 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9277 #### Choose a window system.
9279 ## We leave window_system equal to none if
9280 ## we end up building without one. Any new window system should
9281 ## set window_system to an appropriate value and add objects to
9282 ## window-system-specific substs.
9284 window_system=none
9285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9286 $as_echo_n "checking for X... " >&6; }
9289 # Check whether --with-x was given.
9290 if test "${with_x+set}" = set; then :
9291 withval=$with_x;
9294 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9295 if test "x$with_x" = xno; then
9296 # The user explicitly disabled X.
9297 have_x=disabled
9298 else
9299 case $x_includes,$x_libraries in #(
9300 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9301 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9302 $as_echo_n "(cached) " >&6
9303 else
9304 # One or both of the vars are not set, and there is no cached value.
9305 ac_x_includes=no ac_x_libraries=no
9306 rm -f -r conftest.dir
9307 if mkdir conftest.dir; then
9308 cd conftest.dir
9309 cat >Imakefile <<'_ACEOF'
9310 incroot:
9311 @echo incroot='${INCROOT}'
9312 usrlibdir:
9313 @echo usrlibdir='${USRLIBDIR}'
9314 libdir:
9315 @echo libdir='${LIBDIR}'
9316 _ACEOF
9317 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9318 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9319 for ac_var in incroot usrlibdir libdir; do
9320 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9321 done
9322 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9323 for ac_extension in a so sl dylib la dll; do
9324 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9325 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9326 ac_im_usrlibdir=$ac_im_libdir; break
9328 done
9329 # Screen out bogus values from the imake configuration. They are
9330 # bogus both because they are the default anyway, and because
9331 # using them would break gcc on systems where it needs fixed includes.
9332 case $ac_im_incroot in
9333 /usr/include) ac_x_includes= ;;
9334 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9335 esac
9336 case $ac_im_usrlibdir in
9337 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9338 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9339 esac
9341 cd ..
9342 rm -f -r conftest.dir
9345 # Standard set of common directories for X headers.
9346 # Check X11 before X11Rn because it is often a symlink to the current release.
9347 ac_x_header_dirs='
9348 /usr/X11/include
9349 /usr/X11R7/include
9350 /usr/X11R6/include
9351 /usr/X11R5/include
9352 /usr/X11R4/include
9354 /usr/include/X11
9355 /usr/include/X11R7
9356 /usr/include/X11R6
9357 /usr/include/X11R5
9358 /usr/include/X11R4
9360 /usr/local/X11/include
9361 /usr/local/X11R7/include
9362 /usr/local/X11R6/include
9363 /usr/local/X11R5/include
9364 /usr/local/X11R4/include
9366 /usr/local/include/X11
9367 /usr/local/include/X11R7
9368 /usr/local/include/X11R6
9369 /usr/local/include/X11R5
9370 /usr/local/include/X11R4
9372 /usr/X386/include
9373 /usr/x386/include
9374 /usr/XFree86/include/X11
9376 /usr/include
9377 /usr/local/include
9378 /usr/unsupported/include
9379 /usr/athena/include
9380 /usr/local/x11r5/include
9381 /usr/lpp/Xamples/include
9383 /usr/openwin/include
9384 /usr/openwin/share/include'
9386 if test "$ac_x_includes" = no; then
9387 # Guess where to find include files, by looking for Xlib.h.
9388 # First, try using that file with no special directory specified.
9389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9390 /* end confdefs.h. */
9391 #include <X11/Xlib.h>
9392 _ACEOF
9393 if ac_fn_c_try_cpp "$LINENO"; then :
9394 # We can compile using X headers with no special include directory.
9395 ac_x_includes=
9396 else
9397 for ac_dir in $ac_x_header_dirs; do
9398 if test -r "$ac_dir/X11/Xlib.h"; then
9399 ac_x_includes=$ac_dir
9400 break
9402 done
9404 rm -f conftest.err conftest.$ac_ext
9405 fi # $ac_x_includes = no
9407 if test "$ac_x_libraries" = no; then
9408 # Check for the libraries.
9409 # See if we find them without any special options.
9410 # Don't add to $LIBS permanently.
9411 ac_save_LIBS=$LIBS
9412 LIBS="-lX11 $LIBS"
9413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9414 /* end confdefs.h. */
9415 #include <X11/Xlib.h>
9417 main ()
9419 XrmInitialize ()
9421 return 0;
9423 _ACEOF
9424 if ac_fn_c_try_link "$LINENO"; then :
9425 LIBS=$ac_save_LIBS
9426 # We can link X programs with no special library path.
9427 ac_x_libraries=
9428 else
9429 LIBS=$ac_save_LIBS
9430 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9432 # Don't even attempt the hair of trying to link an X program!
9433 for ac_extension in a so sl dylib la dll; do
9434 if test -r "$ac_dir/libX11.$ac_extension"; then
9435 ac_x_libraries=$ac_dir
9436 break 2
9438 done
9439 done
9441 rm -f core conftest.err conftest.$ac_objext \
9442 conftest$ac_exeext conftest.$ac_ext
9443 fi # $ac_x_libraries = no
9445 case $ac_x_includes,$ac_x_libraries in #(
9446 no,* | *,no | *\'*)
9447 # Didn't find X, or a directory has "'" in its name.
9448 ac_cv_have_x="have_x=no";; #(
9450 # Record where we found X for the cache.
9451 ac_cv_have_x="have_x=yes\
9452 ac_x_includes='$ac_x_includes'\
9453 ac_x_libraries='$ac_x_libraries'"
9454 esac
9456 ;; #(
9457 *) have_x=yes;;
9458 esac
9459 eval "$ac_cv_have_x"
9460 fi # $with_x != no
9462 if test "$have_x" != yes; then
9463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9464 $as_echo "$have_x" >&6; }
9465 no_x=yes
9466 else
9467 # If each of the values was on the command line, it overrides each guess.
9468 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9469 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9470 # Update the cache value to reflect the command line values.
9471 ac_cv_have_x="have_x=yes\
9472 ac_x_includes='$x_includes'\
9473 ac_x_libraries='$x_libraries'"
9474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9475 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9478 if test "$no_x" != yes; then
9479 window_system=x11
9482 LD_SWITCH_X_SITE_RPATH=
9483 if test "${x_libraries}" != NONE; then
9484 if test -n "${x_libraries}"; then
9485 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9486 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9488 x_default_search_path=""
9489 x_search_path=${x_libraries}
9490 if test -z "${x_search_path}"; then
9491 x_search_path=/usr/lib
9493 for x_library in `echo ${x_search_path}: | \
9494 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9495 x_search_path="\
9496 ${x_library}/X11/%L/%T/%N%C%S:\
9497 ${x_library}/X11/%l/%T/%N%C%S:\
9498 ${x_library}/X11/%T/%N%C%S:\
9499 ${x_library}/X11/%L/%T/%N%S:\
9500 ${x_library}/X11/%l/%T/%N%S:\
9501 ${x_library}/X11/%T/%N%S"
9502 if test x"${x_default_search_path}" = x; then
9503 x_default_search_path=${x_search_path}
9504 else
9505 x_default_search_path="${x_search_path}:${x_default_search_path}"
9507 done
9511 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9512 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9515 if test x"${x_includes}" = x; then
9516 bitmapdir=/usr/include/X11/bitmaps
9517 else
9518 # accumulate include directories that have X11 bitmap subdirectories
9519 bmd_acc="dummyval"
9520 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9521 if test -d "${bmd}/X11/bitmaps"; then
9522 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9524 if test -d "${bmd}/bitmaps"; then
9525 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9527 done
9528 if test ${bmd_acc} != "dummyval"; then
9529 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9533 HAVE_NS=no
9534 NS_IMPL_COCOA=no
9535 NS_IMPL_GNUSTEP=no
9536 tmp_CPPFLAGS="$CPPFLAGS"
9537 tmp_CFLAGS="$CFLAGS"
9538 CPPFLAGS="$CPPFLAGS -x objective-c"
9539 CFLAGS="$CFLAGS -x objective-c"
9540 TEMACS_LDFLAGS2="\${LDFLAGS}"
9541 GNU_OBJC_CFLAGS=
9542 if test "${with_ns}" != no; then
9543 if test "${opsys}" = darwin; then
9544 NS_IMPL_COCOA=yes
9545 ns_appdir=`pwd`/nextstep/Emacs.app
9546 ns_appbindir=${ns_appdir}/Contents/MacOS
9547 ns_appresdir=${ns_appdir}/Contents/Resources
9548 ns_appsrc=Cocoa/Emacs.base
9549 elif test -f $GNUSTEP_CONFIG_FILE; then
9550 NS_IMPL_GNUSTEP=yes
9551 ns_appdir=`pwd`/nextstep/Emacs.app
9552 ns_appbindir=${ns_appdir}
9553 ns_appresdir=${ns_appdir}/Resources
9554 ns_appsrc=GNUstep/Emacs.base
9555 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9556 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9557 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9558 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9559 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9560 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9561 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9562 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9563 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9564 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9565 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9566 LIB_STANDARD=
9567 START_FILES=
9568 TEMACS_LDFLAGS2=
9569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9570 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9571 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9572 $as_echo_n "(cached) " >&6
9573 else
9574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9575 /* end confdefs.h. */
9576 #include <GNUstepBase/GSConfig.h>
9578 main ()
9580 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9582 #else
9583 fail;
9584 #endif
9586 return 0;
9588 _ACEOF
9589 if ac_fn_c_try_compile "$LINENO"; then :
9590 emacs_cv_objc_exceptions=yes
9591 else
9592 emacs_cv_objc_exceptions=no
9594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9597 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9598 if test $emacs_cv_objc_exceptions = yes; then
9600 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9602 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9606 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9608 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9609 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9610 HAVE_NS=yes
9611 else
9612 as_fn_error "\`--with-ns' was specified, but the include
9613 files are missing or cannot be compiled." "$LINENO" 5
9618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9619 /* end confdefs.h. */
9620 #include <AppKit/AppKit.h>
9622 main ()
9625 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9626 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
9627 ; /* OK */
9628 #else
9629 #error "OSX 10.4 or newer required"
9630 #endif
9631 #endif
9634 return 0;
9636 _ACEOF
9637 if ac_fn_c_try_compile "$LINENO"; then :
9638 ns_osx_have_104=yes
9639 else
9640 ns_osx_have_104=no
9642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9644 /* end confdefs.h. */
9645 #include <Foundation/NSObjCRuntime.h>
9647 main ()
9649 NSInteger i;
9651 return 0;
9653 _ACEOF
9654 if ac_fn_c_try_compile "$LINENO"; then :
9655 ns_have_nsinteger=yes
9656 else
9657 ns_have_nsinteger=no
9659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9660 if test $ns_osx_have_104 = no; then
9661 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
9663 if test $ns_have_nsinteger = yes; then
9665 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9672 INSTALL_ARCH_INDEP_EXTRA=install-etc
9673 ns_self_contained=no
9674 NS_OBJ=
9675 NS_OBJC_OBJ=
9676 if test "${HAVE_NS}" = yes; then
9677 if test "$with_toolkit_scroll_bars" = "no"; then
9678 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9681 window_system=nextstep
9682 # set up packaging dirs
9683 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9684 ns_self_contained=yes
9685 prefix=${ns_appresdir}
9686 exec_prefix=${ns_appbindir}
9687 libexecdir="\${ns_appbindir}/libexec"
9688 archlibdir="\${ns_appbindir}/libexec"
9689 docdir="\${ns_appresdir}/etc"
9690 etcdir="\${ns_appresdir}/etc"
9691 infodir="\${ns_appresdir}/info"
9692 mandir="\${ns_appresdir}/man"
9693 lispdir="\${ns_appresdir}/lisp"
9694 leimdir="\${ns_appresdir}/leim"
9695 INSTALL_ARCH_INDEP_EXTRA=
9697 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9699 CFLAGS="$tmp_CFLAGS"
9700 CPPFLAGS="$tmp_CPPFLAGS"
9707 HAVE_W32=no
9708 W32_OBJ=
9709 W32_LIBS=
9710 W32_RES=
9711 W32_RES_LINK=
9712 if test "${with_w32}" != no; then
9713 if test "${opsys}" != "cygwin"; then
9714 as_fn_error "Using w32 with an autotools build is only supported for Cygwin." "$LINENO" 5
9716 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
9717 if test "x$ac_cv_header_windows_h" = x""yes; then :
9718 HAVE_W32=yes
9719 else
9720 as_fn_error "\`--with-w32' was specified, but windows.h
9721 cannot be found." "$LINENO" 5
9726 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
9728 if test -n "$ac_tool_prefix"; then
9729 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
9730 set dummy ${ac_tool_prefix}windres; ac_word=$2
9731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9732 $as_echo_n "checking for $ac_word... " >&6; }
9733 if test "${ac_cv_prog_WINDRES+set}" = set; then :
9734 $as_echo_n "(cached) " >&6
9735 else
9736 if test -n "$WINDRES"; then
9737 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
9738 else
9739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9740 for as_dir in $PATH
9742 IFS=$as_save_IFS
9743 test -z "$as_dir" && as_dir=.
9744 for ac_exec_ext in '' $ac_executable_extensions; do
9745 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9746 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
9747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9748 break 2
9750 done
9751 done
9752 IFS=$as_save_IFS
9756 WINDRES=$ac_cv_prog_WINDRES
9757 if test -n "$WINDRES"; then
9758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
9759 $as_echo "$WINDRES" >&6; }
9760 else
9761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9762 $as_echo "no" >&6; }
9767 if test -z "$ac_cv_prog_WINDRES"; then
9768 ac_ct_WINDRES=$WINDRES
9769 # Extract the first word of "windres", so it can be a program name with args.
9770 set dummy windres; ac_word=$2
9771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9772 $as_echo_n "checking for $ac_word... " >&6; }
9773 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
9774 $as_echo_n "(cached) " >&6
9775 else
9776 if test -n "$ac_ct_WINDRES"; then
9777 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
9778 else
9779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9780 for as_dir in $PATH
9782 IFS=$as_save_IFS
9783 test -z "$as_dir" && as_dir=.
9784 for ac_exec_ext in '' $ac_executable_extensions; do
9785 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9786 ac_cv_prog_ac_ct_WINDRES="windres"
9787 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9788 break 2
9790 done
9791 done
9792 IFS=$as_save_IFS
9796 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
9797 if test -n "$ac_ct_WINDRES"; then
9798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
9799 $as_echo "$ac_ct_WINDRES" >&6; }
9800 else
9801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9802 $as_echo "no" >&6; }
9805 if test "x$ac_ct_WINDRES" = x; then
9806 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
9807 else
9808 case $cross_compiling:$ac_tool_warned in
9809 yes:)
9810 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9811 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9812 ac_tool_warned=yes ;;
9813 esac
9814 WINDRES=$ac_ct_WINDRES
9816 else
9817 WINDRES="$ac_cv_prog_WINDRES"
9820 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
9821 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
9822 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
9823 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
9824 W32_RES="emacs.res"
9825 # Tell the linker that emacs.res is an object (which we compile from
9826 # the rc file), not a linker script.
9827 W32_RES_LINK="-Wl,-bpe-i386 -Wl,emacs.res"
9834 if test "${HAVE_W32}" = "yes"; then
9835 window_system=w32
9836 with_xft=no
9839 ## $window_system is now set to the window system we will
9840 ## ultimately use.
9842 term_header=
9843 HAVE_X_WINDOWS=no
9844 HAVE_X11=no
9845 USE_X_TOOLKIT=none
9847 case "${window_system}" in
9848 x11 )
9849 HAVE_X_WINDOWS=yes
9850 HAVE_X11=yes
9851 term_header=xterm.h
9852 case "${with_x_toolkit}" in
9853 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9854 motif ) USE_X_TOOLKIT=MOTIF ;;
9855 gtk ) with_gtk=yes
9856 term_header=gtkutil.h
9857 USE_X_TOOLKIT=none ;;
9858 gtk2 ) with_gtk2=yes
9859 term_header=gtkutil.h
9860 USE_X_TOOLKIT=none ;;
9861 gtk3 ) with_gtk3=yes
9862 term_header=gtkutil.h
9863 USE_X_TOOLKIT=none ;;
9864 no ) USE_X_TOOLKIT=none ;;
9865 * ) USE_X_TOOLKIT=maybe ;;
9866 esac
9868 nextstep )
9869 term_header=nsterm.h
9871 w32 )
9872 term_header=w32term.h
9874 esac
9876 if test -n "${term_header}"; then
9878 cat >>confdefs.h <<_ACEOF
9879 #define TERM_HEADER "${term_header}"
9880 _ACEOF
9884 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9885 # Extract the first word of "X", so it can be a program name with args.
9886 set dummy X; ac_word=$2
9887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9888 $as_echo_n "checking for $ac_word... " >&6; }
9889 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9890 $as_echo_n "(cached) " >&6
9891 else
9892 if test -n "$HAVE_XSERVER"; then
9893 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9894 else
9895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9896 for as_dir in $PATH
9898 IFS=$as_save_IFS
9899 test -z "$as_dir" && as_dir=.
9900 for ac_exec_ext in '' $ac_executable_extensions; do
9901 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9902 ac_cv_prog_HAVE_XSERVER="true"
9903 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9904 break 2
9906 done
9907 done
9908 IFS=$as_save_IFS
9910 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9913 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9914 if test -n "$HAVE_XSERVER"; then
9915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9916 $as_echo "$HAVE_XSERVER" >&6; }
9917 else
9918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9919 $as_echo "no" >&6; }
9923 if test "$HAVE_XSERVER" = true ||
9924 test -n "$DISPLAY" ||
9925 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9926 as_fn_error "You seem to be running X, but no X development libraries
9927 were found. You should install the relevant development files for X
9928 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9929 sure you have development files for image handling, i.e.
9930 tiff, gif, jpeg, png and xpm.
9931 If you are sure you want Emacs compiled without X window support, pass
9932 --without-x
9933 to configure." "$LINENO" 5
9937 ### If we're using X11, we should use the X menu package.
9938 HAVE_MENUS=no
9939 case ${HAVE_X11} in
9940 yes ) HAVE_MENUS=yes ;;
9941 esac
9943 # Does the opsystem file prohibit the use of the GNU malloc?
9944 # Assume not, until told otherwise.
9945 GNU_MALLOC=yes
9947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9948 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9949 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9950 $as_echo_n "(cached) " >&6
9951 else
9952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9953 /* end confdefs.h. */
9954 #include <malloc.h>
9955 static void hook (void) {}
9957 main ()
9959 malloc_set_state (malloc_get_state ());
9960 __after_morecore_hook = hook;
9961 __malloc_initialize_hook = hook;
9963 return 0;
9965 _ACEOF
9966 if ac_fn_c_try_link "$LINENO"; then :
9967 emacs_cv_var_doug_lea_malloc=yes
9968 else
9969 emacs_cv_var_doug_lea_malloc=no
9971 rm -f core conftest.err conftest.$ac_objext \
9972 conftest$ac_exeext conftest.$ac_ext
9974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9975 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9976 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9979 system_malloc=no
9980 case "$opsys" in
9981 ## darwin ld insists on the use of malloc routines in the System framework.
9982 darwin|sol2-10) system_malloc=yes ;;
9983 esac
9985 if test "${system_malloc}" = "yes"; then
9987 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9989 GNU_MALLOC=no
9990 GNU_MALLOC_reason="
9991 (The GNU allocators don't work with this system configuration.)"
9992 GMALLOC_OBJ=
9993 VMLIMIT_OBJ=
9994 else
9995 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9996 VMLIMIT_OBJ=vm-limit.o
10001 if test "$doug_lea_malloc" = "yes" ; then
10002 if test "$GNU_MALLOC" = yes ; then
10003 GNU_MALLOC_reason="
10004 (Using Doug Lea's new malloc from the GNU C Library.)"
10007 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10010 ## Use mmap directly for allocating larger buffers.
10011 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10012 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10013 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10014 case "$opsys" in
10015 gnu*) REL_ALLOC=no ;;
10016 esac
10019 if test x"${REL_ALLOC}" = x; then
10020 REL_ALLOC=${GNU_MALLOC}
10023 use_mmap_for_buffers=no
10024 case "$opsys" in
10025 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10026 esac
10035 for ac_func in getpagesize
10036 do :
10037 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10038 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10039 cat >>confdefs.h <<_ACEOF
10040 #define HAVE_GETPAGESIZE 1
10041 _ACEOF
10044 done
10046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10047 $as_echo_n "checking for working mmap... " >&6; }
10048 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10049 $as_echo_n "(cached) " >&6
10050 else
10051 if test "$cross_compiling" = yes; then :
10052 ac_cv_func_mmap_fixed_mapped=no
10053 else
10054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10055 /* end confdefs.h. */
10056 $ac_includes_default
10057 /* malloc might have been renamed as rpl_malloc. */
10058 #undef malloc
10060 /* Thanks to Mike Haertel and Jim Avera for this test.
10061 Here is a matrix of mmap possibilities:
10062 mmap private not fixed
10063 mmap private fixed at somewhere currently unmapped
10064 mmap private fixed at somewhere already mapped
10065 mmap shared not fixed
10066 mmap shared fixed at somewhere currently unmapped
10067 mmap shared fixed at somewhere already mapped
10068 For private mappings, we should verify that changes cannot be read()
10069 back from the file, nor mmap's back from the file at a different
10070 address. (There have been systems where private was not correctly
10071 implemented like the infamous i386 svr4.0, and systems where the
10072 VM page cache was not coherent with the file system buffer cache
10073 like early versions of FreeBSD and possibly contemporary NetBSD.)
10074 For shared mappings, we should conversely verify that changes get
10075 propagated back to all the places they're supposed to be.
10077 Grep wants private fixed already mapped.
10078 The main things grep needs to know about mmap are:
10079 * does it exist and is it safe to write into the mmap'd area
10080 * how to use it (BSD variants) */
10082 #include <fcntl.h>
10083 #include <sys/mman.h>
10085 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10086 char *malloc ();
10087 #endif
10089 /* This mess was copied from the GNU getpagesize.h. */
10090 #ifndef HAVE_GETPAGESIZE
10091 # ifdef _SC_PAGESIZE
10092 # define getpagesize() sysconf(_SC_PAGESIZE)
10093 # else /* no _SC_PAGESIZE */
10094 # ifdef HAVE_SYS_PARAM_H
10095 # include <sys/param.h>
10096 # ifdef EXEC_PAGESIZE
10097 # define getpagesize() EXEC_PAGESIZE
10098 # else /* no EXEC_PAGESIZE */
10099 # ifdef NBPG
10100 # define getpagesize() NBPG * CLSIZE
10101 # ifndef CLSIZE
10102 # define CLSIZE 1
10103 # endif /* no CLSIZE */
10104 # else /* no NBPG */
10105 # ifdef NBPC
10106 # define getpagesize() NBPC
10107 # else /* no NBPC */
10108 # ifdef PAGESIZE
10109 # define getpagesize() PAGESIZE
10110 # endif /* PAGESIZE */
10111 # endif /* no NBPC */
10112 # endif /* no NBPG */
10113 # endif /* no EXEC_PAGESIZE */
10114 # else /* no HAVE_SYS_PARAM_H */
10115 # define getpagesize() 8192 /* punt totally */
10116 # endif /* no HAVE_SYS_PARAM_H */
10117 # endif /* no _SC_PAGESIZE */
10119 #endif /* no HAVE_GETPAGESIZE */
10122 main ()
10124 char *data, *data2, *data3;
10125 const char *cdata2;
10126 int i, pagesize;
10127 int fd, fd2;
10129 pagesize = getpagesize ();
10131 /* First, make a file with some known garbage in it. */
10132 data = (char *) malloc (pagesize);
10133 if (!data)
10134 return 1;
10135 for (i = 0; i < pagesize; ++i)
10136 *(data + i) = rand ();
10137 umask (0);
10138 fd = creat ("conftest.mmap", 0600);
10139 if (fd < 0)
10140 return 2;
10141 if (write (fd, data, pagesize) != pagesize)
10142 return 3;
10143 close (fd);
10145 /* Next, check that the tail of a page is zero-filled. File must have
10146 non-zero length, otherwise we risk SIGBUS for entire page. */
10147 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10148 if (fd2 < 0)
10149 return 4;
10150 cdata2 = "";
10151 if (write (fd2, cdata2, 1) != 1)
10152 return 5;
10153 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10154 if (data2 == MAP_FAILED)
10155 return 6;
10156 for (i = 0; i < pagesize; ++i)
10157 if (*(data2 + i))
10158 return 7;
10159 close (fd2);
10160 if (munmap (data2, pagesize))
10161 return 8;
10163 /* Next, try to mmap the file at a fixed address which already has
10164 something else allocated at it. If we can, also make sure that
10165 we see the same garbage. */
10166 fd = open ("conftest.mmap", O_RDWR);
10167 if (fd < 0)
10168 return 9;
10169 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10170 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10171 return 10;
10172 for (i = 0; i < pagesize; ++i)
10173 if (*(data + i) != *(data2 + i))
10174 return 11;
10176 /* Finally, make sure that changes to the mapped area do not
10177 percolate back to the file as seen by read(). (This is a bug on
10178 some variants of i386 svr4.0.) */
10179 for (i = 0; i < pagesize; ++i)
10180 *(data2 + i) = *(data2 + i) + 1;
10181 data3 = (char *) malloc (pagesize);
10182 if (!data3)
10183 return 12;
10184 if (read (fd, data3, pagesize) != pagesize)
10185 return 13;
10186 for (i = 0; i < pagesize; ++i)
10187 if (*(data + i) != *(data3 + i))
10188 return 14;
10189 close (fd);
10190 return 0;
10192 _ACEOF
10193 if ac_fn_c_try_run "$LINENO"; then :
10194 ac_cv_func_mmap_fixed_mapped=yes
10195 else
10196 ac_cv_func_mmap_fixed_mapped=no
10198 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10199 conftest.$ac_objext conftest.beam conftest.$ac_ext
10203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10204 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10205 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10207 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10210 rm -f conftest.mmap conftest.txt
10212 if test $use_mmap_for_buffers = yes; then
10214 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10216 REL_ALLOC=no
10219 LIBS="$LIBS_SYSTEM $LIBS"
10221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10222 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10223 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10224 $as_echo_n "(cached) " >&6
10225 else
10226 ac_check_lib_save_LIBS=$LIBS
10227 LIBS="-ldnet $LIBS"
10228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10229 /* end confdefs.h. */
10231 /* Override any GCC internal prototype to avoid an error.
10232 Use char because int might match the return type of a GCC
10233 builtin and then its argument prototype would still apply. */
10234 #ifdef __cplusplus
10235 extern "C"
10236 #endif
10237 char dnet_ntoa ();
10239 main ()
10241 return dnet_ntoa ();
10243 return 0;
10245 _ACEOF
10246 if ac_fn_c_try_link "$LINENO"; then :
10247 ac_cv_lib_dnet_dnet_ntoa=yes
10248 else
10249 ac_cv_lib_dnet_dnet_ntoa=no
10251 rm -f core conftest.err conftest.$ac_objext \
10252 conftest$ac_exeext conftest.$ac_ext
10253 LIBS=$ac_check_lib_save_LIBS
10255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10256 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10257 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10258 cat >>confdefs.h <<_ACEOF
10259 #define HAVE_LIBDNET 1
10260 _ACEOF
10262 LIBS="-ldnet $LIBS"
10267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10268 $as_echo_n "checking for main in -lXbsd... " >&6; }
10269 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10270 $as_echo_n "(cached) " >&6
10271 else
10272 ac_check_lib_save_LIBS=$LIBS
10273 LIBS="-lXbsd $LIBS"
10274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10275 /* end confdefs.h. */
10279 main ()
10281 return main ();
10283 return 0;
10285 _ACEOF
10286 if ac_fn_c_try_link "$LINENO"; then :
10287 ac_cv_lib_Xbsd_main=yes
10288 else
10289 ac_cv_lib_Xbsd_main=no
10291 rm -f core conftest.err conftest.$ac_objext \
10292 conftest$ac_exeext conftest.$ac_ext
10293 LIBS=$ac_check_lib_save_LIBS
10295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10296 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10297 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10298 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10302 LIB_PTHREAD=
10306 if test "$ac_cv_header_pthread_h"; then
10307 if test "$GMALLOC_OBJ" = gmalloc.o; then
10308 emacs_pthread_function=pthread_atfork
10309 else
10310 emacs_pthread_function=pthread_self
10312 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10314 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10315 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10316 $as_echo_n "(cached) " >&6
10317 else
10318 ac_check_lib_save_LIBS=$LIBS
10319 LIBS="-lpthread $LIBS"
10320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10321 /* end confdefs.h. */
10323 /* Override any GCC internal prototype to avoid an error.
10324 Use char because int might match the return type of a GCC
10325 builtin and then its argument prototype would still apply. */
10326 #ifdef __cplusplus
10327 extern "C"
10328 #endif
10329 char $emacs_pthread_function ();
10331 main ()
10333 return $emacs_pthread_function ();
10335 return 0;
10337 _ACEOF
10338 if ac_fn_c_try_link "$LINENO"; then :
10339 eval "$as_ac_Lib=yes"
10340 else
10341 eval "$as_ac_Lib=no"
10343 rm -f core conftest.err conftest.$ac_objext \
10344 conftest$ac_exeext conftest.$ac_ext
10345 LIBS=$ac_check_lib_save_LIBS
10347 eval ac_res=\$$as_ac_Lib
10348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10349 $as_echo "$ac_res" >&6; }
10350 eval as_val=\$$as_ac_Lib
10351 if test "x$as_val" = x""yes; then :
10352 HAVE_PTHREAD=yes
10356 if test "$HAVE_PTHREAD" = yes; then
10357 case "${canonical}" in
10358 *-hpux*) ;;
10359 *) LIB_PTHREAD="-lpthread"
10360 LIBS="$LIB_PTHREAD $LIBS" ;;
10361 esac
10363 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10369 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10370 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10371 $as_echo_n "(cached) " >&6
10372 else
10373 ac_check_lib_save_LIBS=$LIBS
10374 LIBS="-lpthreads $LIBS"
10375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10376 /* end confdefs.h. */
10378 /* Override any GCC internal prototype to avoid an error.
10379 Use char because int might match the return type of a GCC
10380 builtin and then its argument prototype would still apply. */
10381 #ifdef __cplusplus
10382 extern "C"
10383 #endif
10384 char cma_open ();
10386 main ()
10388 return cma_open ();
10390 return 0;
10392 _ACEOF
10393 if ac_fn_c_try_link "$LINENO"; then :
10394 ac_cv_lib_pthreads_cma_open=yes
10395 else
10396 ac_cv_lib_pthreads_cma_open=no
10398 rm -f core conftest.err conftest.$ac_objext \
10399 conftest$ac_exeext conftest.$ac_ext
10400 LIBS=$ac_check_lib_save_LIBS
10402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10403 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10404 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10405 cat >>confdefs.h <<_ACEOF
10406 #define HAVE_LIBPTHREADS 1
10407 _ACEOF
10409 LIBS="-lpthreads $LIBS"
10414 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10415 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10416 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10417 ## added to LIBS in configure would never contain the pthreads part,
10418 ## but the value used in Makefiles might. FIXME?
10420 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10421 ## be harmless on older versions of X where it happens to exist.
10422 test "$opsys" = "aix4-2" && \
10423 test $ac_cv_lib_pthreads_cma_open = yes && \
10424 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10427 case ${host_os} in
10428 aix*)
10429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10430 $as_echo_n "checking for -bbigtoc option... " >&6; }
10431 if test "${gdb_cv_bigtoc+set}" = set; then :
10432 $as_echo_n "(cached) " >&6
10433 else
10435 case $GCC in
10436 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10437 *) gdb_cv_bigtoc=-bbigtoc ;;
10438 esac
10440 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10442 /* end confdefs.h. */
10445 main ()
10447 int i;
10449 return 0;
10451 _ACEOF
10452 if ac_fn_c_try_link "$LINENO"; then :
10454 else
10455 gdb_cv_bigtoc=
10457 rm -f core conftest.err conftest.$ac_objext \
10458 conftest$ac_exeext conftest.$ac_ext
10461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10462 $as_echo "$gdb_cv_bigtoc" >&6; }
10464 esac
10466 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10467 # used for the tests that follow. We set them back to REAL_CFLAGS and
10468 # REAL_CPPFLAGS later on.
10470 REAL_CFLAGS="$CFLAGS"
10471 REAL_CPPFLAGS="$CPPFLAGS"
10473 if test "${HAVE_X11}" = "yes"; then
10474 DEFS="$C_SWITCH_X_SITE $DEFS"
10475 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10476 LIBS="-lX11 $LIBS"
10477 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10478 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10480 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10481 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10482 # but it's more convenient here to set LD_RUN_PATH since this
10483 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10484 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10485 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10486 export LD_RUN_PATH
10489 if test "${opsys}" = "gnu-linux"; then
10490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10491 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10493 /* end confdefs.h. */
10496 main ()
10498 XOpenDisplay ("foo");
10500 return 0;
10502 _ACEOF
10503 if ac_fn_c_try_link "$LINENO"; then :
10504 xgnu_linux_first_failure=no
10505 else
10506 xgnu_linux_first_failure=yes
10508 rm -f core conftest.err conftest.$ac_objext \
10509 conftest$ac_exeext conftest.$ac_ext
10510 if test "${xgnu_linux_first_failure}" = "yes"; then
10511 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10512 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10513 OLD_CPPFLAGS="$CPPFLAGS"
10514 OLD_LIBS="$LIBS"
10515 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10516 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10517 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10518 LIBS="$LIBS -b i486-linuxaout"
10519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10520 /* end confdefs.h. */
10523 main ()
10525 XOpenDisplay ("foo");
10527 return 0;
10529 _ACEOF
10530 if ac_fn_c_try_link "$LINENO"; then :
10531 xgnu_linux_second_failure=no
10532 else
10533 xgnu_linux_second_failure=yes
10535 rm -f core conftest.err conftest.$ac_objext \
10536 conftest$ac_exeext conftest.$ac_ext
10537 if test "${xgnu_linux_second_failure}" = "yes"; then
10538 # If we get the same failure with -b, there is no use adding -b.
10539 # So take it out. This plays safe.
10540 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10541 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10542 CPPFLAGS="$OLD_CPPFLAGS"
10543 LIBS="$OLD_LIBS"
10544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10545 $as_echo "no" >&6; }
10546 else
10547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10548 $as_echo "yes" >&6; }
10550 else
10551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10552 $as_echo "no" >&6; }
10556 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10557 # header files included from there.
10558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10559 $as_echo_n "checking for Xkb... " >&6; }
10560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10561 /* end confdefs.h. */
10562 #include <X11/Xlib.h>
10563 #include <X11/XKBlib.h>
10565 main ()
10567 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10569 return 0;
10571 _ACEOF
10572 if ac_fn_c_try_link "$LINENO"; then :
10573 emacs_xkb=yes
10574 else
10575 emacs_xkb=no
10577 rm -f core conftest.err conftest.$ac_objext \
10578 conftest$ac_exeext conftest.$ac_ext
10579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10580 $as_echo "$emacs_xkb" >&6; }
10581 if test $emacs_xkb = yes; then
10583 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10587 for ac_func in XrmSetDatabase XScreenResourceString \
10588 XScreenNumberOfScreen
10589 do :
10590 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10591 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10592 eval as_val=\$$as_ac_var
10593 if test "x$as_val" = x""yes; then :
10594 cat >>confdefs.h <<_ACEOF
10595 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10596 _ACEOF
10599 done
10603 if test "${window_system}" = "x11"; then
10604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10605 $as_echo_n "checking X11 version 6... " >&6; }
10606 if test "${emacs_cv_x11_version_6+set}" = set; then :
10607 $as_echo_n "(cached) " >&6
10608 else
10609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10610 /* end confdefs.h. */
10611 #include <X11/Xlib.h>
10613 main ()
10615 #if XlibSpecificationRelease < 6
10616 fail;
10617 #endif
10620 return 0;
10622 _ACEOF
10623 if ac_fn_c_try_link "$LINENO"; then :
10624 emacs_cv_x11_version_6=yes
10625 else
10626 emacs_cv_x11_version_6=no
10628 rm -f core conftest.err conftest.$ac_objext \
10629 conftest$ac_exeext conftest.$ac_ext
10632 if test $emacs_cv_x11_version_6 = yes; then
10633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10634 $as_echo "6 or newer" >&6; }
10636 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10639 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10641 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10642 ## XIM support.
10643 case "$opsys" in
10644 sol2-*) : ;;
10646 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10649 esac
10650 else
10651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10652 $as_echo "before 6" >&6; }
10657 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10658 HAVE_RSVG=no
10659 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10660 if test "${with_rsvg}" != "no"; then
10661 RSVG_REQUIRED=2.11.0
10662 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10665 succeeded=no
10667 if test "$PKG_CONFIG" = "no" ; then
10669 else
10670 PKG_CONFIG_MIN_VERSION=0.9.0
10671 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10673 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10675 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
10676 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
10677 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
10678 edit_cflags="
10679 s,///*,/,g
10680 s/^/ /
10681 s/ -I/ $isystem/g
10682 s/^ //
10684 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10685 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10687 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10688 succeeded=yes
10689 else
10690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10691 $as_echo "no" >&6; }
10692 RSVG_CFLAGS=""
10693 RSVG_LIBS=""
10694 ## If we have a custom action on failure, don't print errors, but
10695 ## do set a variable so people can do so. Do it in a subshell
10696 ## to capture any diagnostics in invoking pkg-config.
10697 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
10703 else
10704 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10705 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10709 if test $succeeded = yes; then
10710 HAVE_RSVG=yes
10711 else
10718 if test $HAVE_RSVG = yes; then
10720 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10722 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10723 LIBS="$RSVG_LIBS $LIBS"
10728 HAVE_IMAGEMAGICK=no
10729 if test "${HAVE_X11}" = "yes"; then
10730 if test "${with_imagemagick}" != "no"; then
10731 ## 6.2.8 is the earliest version known to work, but earlier versions
10732 ## might work - let us know if you find one.
10733 ## 6.0.7 does not work. See bug#7955.
10734 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10736 succeeded=no
10738 if test "$PKG_CONFIG" = "no" ; then
10740 else
10741 PKG_CONFIG_MIN_VERSION=0.9.0
10742 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10744 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10746 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10747 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10748 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10749 edit_cflags="
10750 s,///*,/,g
10751 s/^/ /
10752 s/ -I/ $isystem/g
10753 s/^ //
10755 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10756 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10758 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10759 succeeded=yes
10760 else
10761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10762 $as_echo "no" >&6; }
10763 IMAGEMAGICK_CFLAGS=""
10764 IMAGEMAGICK_LIBS=""
10765 ## If we have a custom action on failure, don't print errors, but
10766 ## do set a variable so people can do so. Do it in a subshell
10767 ## to capture any diagnostics in invoking pkg-config.
10768 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
10774 else
10775 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10776 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10780 if test $succeeded = yes; then
10781 HAVE_IMAGEMAGICK=yes
10782 else
10789 if test $HAVE_IMAGEMAGICK = yes; then
10791 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10793 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10794 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10795 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10796 do :
10797 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10798 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10799 eval as_val=\$$as_ac_var
10800 if test "x$as_val" = x""yes; then :
10801 cat >>confdefs.h <<_ACEOF
10802 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10803 _ACEOF
10806 done
10813 HAVE_GTK=no
10814 GTK_OBJ=
10815 check_gtk2=no
10816 gtk3_pkg_errors=
10817 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10818 GLIB_REQUIRED=2.28
10819 GTK_REQUIRED=3.0
10820 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10823 succeeded=no
10825 if test "$PKG_CONFIG" = "no" ; then
10826 pkg_check_gtk=no
10827 else
10828 PKG_CONFIG_MIN_VERSION=0.9.0
10829 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10831 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10833 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
10834 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
10835 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
10836 edit_cflags="
10837 s,///*,/,g
10838 s/^/ /
10839 s/ -I/ $isystem/g
10840 s/^ //
10842 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10843 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10845 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10846 succeeded=yes
10847 else
10848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10849 $as_echo "no" >&6; }
10850 GTK_CFLAGS=""
10851 GTK_LIBS=""
10852 ## If we have a custom action on failure, don't print errors, but
10853 ## do set a variable so people can do so. Do it in a subshell
10854 ## to capture any diagnostics in invoking pkg-config.
10855 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
10861 else
10862 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10863 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10867 if test $succeeded = yes; then
10868 pkg_check_gtk=yes
10869 else
10870 pkg_check_gtk=no
10873 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
10874 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10876 if test "$pkg_check_gtk" = "yes"; then
10878 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10880 GTK_OBJ=emacsgtkfixed.o
10881 term_header=gtkutil.h
10882 USE_GTK_TOOLKIT="GTK3"
10883 else
10884 check_gtk2=yes
10885 gtk3_pkg_errors="$GTK_PKG_ERRORS "
10889 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
10890 GLIB_REQUIRED=2.10
10891 GTK_REQUIRED=2.10
10892 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10895 succeeded=no
10897 if test "$PKG_CONFIG" = "no" ; then
10898 pkg_check_gtk=no
10899 else
10900 PKG_CONFIG_MIN_VERSION=0.9.0
10901 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10903 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10905 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
10906 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
10907 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
10908 edit_cflags="
10909 s,///*,/,g
10910 s/^/ /
10911 s/ -I/ $isystem/g
10912 s/^ //
10914 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10915 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10917 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10918 succeeded=yes
10919 else
10920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10921 $as_echo "no" >&6; }
10922 GTK_CFLAGS=""
10923 GTK_LIBS=""
10924 ## If we have a custom action on failure, don't print errors, but
10925 ## do set a variable so people can do so. Do it in a subshell
10926 ## to capture any diagnostics in invoking pkg-config.
10927 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
10933 else
10934 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10935 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10939 if test $succeeded = yes; then
10940 pkg_check_gtk=yes
10941 else
10942 pkg_check_gtk=no
10945 if test "$pkg_check_gtk" = "no" &&
10946 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
10947 then
10948 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
10950 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
10953 if test x"$pkg_check_gtk" = xyes; then
10957 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10958 CFLAGS="$CFLAGS $GTK_CFLAGS"
10959 LIBS="$GTK_LIBS $LIBS"
10960 GTK_COMPILES=no
10961 for ac_func in gtk_main
10962 do :
10963 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10964 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10965 cat >>confdefs.h <<_ACEOF
10966 #define HAVE_GTK_MAIN 1
10967 _ACEOF
10968 GTK_COMPILES=yes
10970 done
10972 if test "${GTK_COMPILES}" != "yes"; then
10973 if test "$USE_X_TOOLKIT" != "maybe"; then
10974 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10976 else
10977 HAVE_GTK=yes
10979 $as_echo "#define USE_GTK 1" >>confdefs.h
10981 GTK_OBJ="gtkutil.o $GTK_OBJ"
10982 USE_X_TOOLKIT=none
10983 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
10985 else
10986 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10987 closing open displays. This is no problem if you just use
10988 one display, but if you use more than one and close one of them
10989 Emacs may crash." >&5
10990 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10991 closing open displays. This is no problem if you just use
10992 one display, but if you use more than one and close one of them
10993 Emacs may crash." >&2;}
10994 sleep 3
11002 if test "${HAVE_GTK}" = "yes"; then
11004 if test "$with_toolkit_scroll_bars" != no; then
11005 with_toolkit_scroll_bars=yes
11008 HAVE_GTK_FILE_SELECTION=no
11009 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11010 #include <gtk/gtk.h>
11012 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11013 HAVE_GTK_FILE_SELECTION=yes
11014 else
11015 HAVE_GTK_FILE_SELECTION=no
11018 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11019 for ac_func in gtk_file_selection_new
11020 do :
11021 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11022 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11023 cat >>confdefs.h <<_ACEOF
11024 #define HAVE_GTK_FILE_SELECTION_NEW 1
11025 _ACEOF
11028 done
11033 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11034 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11035 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11036 gtk_orientable_set_orientation \
11037 gtk_window_set_has_resize_grip
11038 do :
11039 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11040 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11041 eval as_val=\$$as_ac_var
11042 if test "x$as_val" = x""yes; then :
11043 cat >>confdefs.h <<_ACEOF
11044 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11045 _ACEOF
11048 done
11051 term_header=gtkutil.h
11054 HAVE_DBUS=no
11055 DBUS_OBJ=
11056 if test "${with_dbus}" = "yes"; then
11058 succeeded=no
11060 if test "$PKG_CONFIG" = "no" ; then
11061 HAVE_DBUS=no
11062 else
11063 PKG_CONFIG_MIN_VERSION=0.9.0
11064 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11066 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11068 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11069 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11070 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11071 edit_cflags="
11072 s,///*,/,g
11073 s/^/ /
11074 s/ -I/ $isystem/g
11075 s/^ //
11077 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11078 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11080 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11081 succeeded=yes
11082 else
11083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11084 $as_echo "no" >&6; }
11085 DBUS_CFLAGS=""
11086 DBUS_LIBS=""
11087 ## If we have a custom action on failure, don't print errors, but
11088 ## do set a variable so people can do so. Do it in a subshell
11089 ## to capture any diagnostics in invoking pkg-config.
11090 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11096 else
11097 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11098 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11102 if test $succeeded = yes; then
11103 HAVE_DBUS=yes
11104 else
11105 HAVE_DBUS=no
11108 if test "$HAVE_DBUS" = yes; then
11109 LIBS="$LIBS $DBUS_LIBS"
11111 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11113 for ac_func in dbus_watch_get_unix_fd \
11114 dbus_type_is_valid \
11115 dbus_validate_bus_name \
11116 dbus_validate_path \
11117 dbus_validate_interface \
11118 dbus_validate_member
11119 do :
11120 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11121 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11122 eval as_val=\$$as_ac_var
11123 if test "x$as_val" = x""yes; then :
11124 cat >>confdefs.h <<_ACEOF
11125 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11126 _ACEOF
11129 done
11131 DBUS_OBJ=dbusbind.o
11136 HAVE_GSETTINGS=no
11137 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11139 succeeded=no
11141 if test "$PKG_CONFIG" = "no" ; then
11142 HAVE_GSETTINGS=no
11143 else
11144 PKG_CONFIG_MIN_VERSION=0.9.0
11145 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11147 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11149 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11150 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11151 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11152 edit_cflags="
11153 s,///*,/,g
11154 s/^/ /
11155 s/ -I/ $isystem/g
11156 s/^ //
11158 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11159 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11161 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11162 succeeded=yes
11163 else
11164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11165 $as_echo "no" >&6; }
11166 GSETTINGS_CFLAGS=""
11167 GSETTINGS_LIBS=""
11168 ## If we have a custom action on failure, don't print errors, but
11169 ## do set a variable so people can do so. Do it in a subshell
11170 ## to capture any diagnostics in invoking pkg-config.
11171 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11177 else
11178 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11179 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11183 if test $succeeded = yes; then
11184 HAVE_GSETTINGS=yes
11185 else
11186 HAVE_GSETTINGS=no
11189 if test "$HAVE_GSETTINGS" = "yes"; then
11191 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11193 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11194 SETTINGS_LIBS="$GSETTINGS_LIBS"
11198 HAVE_GCONF=no
11199 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11201 succeeded=no
11203 if test "$PKG_CONFIG" = "no" ; then
11204 HAVE_GCONF=no
11205 else
11206 PKG_CONFIG_MIN_VERSION=0.9.0
11207 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11209 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11211 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
11212 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11213 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
11214 edit_cflags="
11215 s,///*,/,g
11216 s/^/ /
11217 s/ -I/ $isystem/g
11218 s/^ //
11220 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11221 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11223 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11224 succeeded=yes
11225 else
11226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11227 $as_echo "no" >&6; }
11228 GCONF_CFLAGS=""
11229 GCONF_LIBS=""
11230 ## If we have a custom action on failure, don't print errors, but
11231 ## do set a variable so people can do so. Do it in a subshell
11232 ## to capture any diagnostics in invoking pkg-config.
11233 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
11239 else
11240 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11241 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11245 if test $succeeded = yes; then
11246 HAVE_GCONF=yes
11247 else
11248 HAVE_GCONF=no
11251 if test "$HAVE_GCONF" = yes; then
11253 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11255 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11256 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11260 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11262 succeeded=no
11264 if test "$PKG_CONFIG" = "no" ; then
11265 HAVE_GOBJECT=no
11266 else
11267 PKG_CONFIG_MIN_VERSION=0.9.0
11268 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11270 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11272 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
11273 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11274 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
11275 edit_cflags="
11276 s,///*,/,g
11277 s/^/ /
11278 s/ -I/ $isystem/g
11279 s/^ //
11281 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11282 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11284 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11285 succeeded=yes
11286 else
11287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11288 $as_echo "no" >&6; }
11289 GOBJECT_CFLAGS=""
11290 GOBJECT_LIBS=""
11291 ## If we have a custom action on failure, don't print errors, but
11292 ## do set a variable so people can do so. Do it in a subshell
11293 ## to capture any diagnostics in invoking pkg-config.
11294 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
11300 else
11301 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11302 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11306 if test $succeeded = yes; then
11307 HAVE_GOBJECT=yes
11308 else
11309 HAVE_GOBJECT=no
11312 if test "$HAVE_GOBJECT" = "yes"; then
11313 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11314 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11316 SAVE_CFLAGS="$CFLAGS"
11317 SAVE_LIBS="$LIBS"
11318 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11319 LIBS="$SETTINGS_LIBS $LIBS"
11320 for ac_func in g_type_init
11321 do :
11322 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11323 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11324 cat >>confdefs.h <<_ACEOF
11325 #define HAVE_G_TYPE_INIT 1
11326 _ACEOF
11329 done
11331 CFLAGS="$SAVE_CFLAGS"
11332 LIBS="$SAVE_LIBS"
11338 HAVE_LIBSELINUX=no
11339 LIBSELINUX_LIBS=
11340 if test "${with_selinux}" = "yes"; then
11341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11342 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11343 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11344 $as_echo_n "(cached) " >&6
11345 else
11346 ac_check_lib_save_LIBS=$LIBS
11347 LIBS="-lselinux $LIBS"
11348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11349 /* end confdefs.h. */
11351 /* Override any GCC internal prototype to avoid an error.
11352 Use char because int might match the return type of a GCC
11353 builtin and then its argument prototype would still apply. */
11354 #ifdef __cplusplus
11355 extern "C"
11356 #endif
11357 char lgetfilecon ();
11359 main ()
11361 return lgetfilecon ();
11363 return 0;
11365 _ACEOF
11366 if ac_fn_c_try_link "$LINENO"; then :
11367 ac_cv_lib_selinux_lgetfilecon=yes
11368 else
11369 ac_cv_lib_selinux_lgetfilecon=no
11371 rm -f core conftest.err conftest.$ac_objext \
11372 conftest$ac_exeext conftest.$ac_ext
11373 LIBS=$ac_check_lib_save_LIBS
11375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11376 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11377 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11378 HAVE_LIBSELINUX=yes
11379 else
11380 HAVE_LIBSELINUX=no
11383 if test "$HAVE_LIBSELINUX" = yes; then
11385 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11387 LIBSELINUX_LIBS=-lselinux
11392 HAVE_GNUTLS=no
11393 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11394 if test "${with_gnutls}" = "yes" ; then
11396 succeeded=no
11398 if test "$PKG_CONFIG" = "no" ; then
11399 HAVE_GNUTLS=no
11400 else
11401 PKG_CONFIG_MIN_VERSION=0.9.0
11402 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11404 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11406 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
11407 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
11408 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
11409 edit_cflags="
11410 s,///*,/,g
11411 s/^/ /
11412 s/ -I/ $isystem/g
11413 s/^ //
11415 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11416 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11418 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11419 succeeded=yes
11420 else
11421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11422 $as_echo "no" >&6; }
11423 LIBGNUTLS_CFLAGS=""
11424 LIBGNUTLS_LIBS=""
11425 ## If we have a custom action on failure, don't print errors, but
11426 ## do set a variable so people can do so. Do it in a subshell
11427 ## to capture any diagnostics in invoking pkg-config.
11428 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
11434 else
11435 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11436 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11440 if test $succeeded = yes; then
11441 HAVE_GNUTLS=yes
11442 else
11443 HAVE_GNUTLS=no
11446 if test "${HAVE_GNUTLS}" = "yes"; then
11448 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11452 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11453 LIBS="$LIBGNUTLS_LIBS $LIBS"
11454 for ac_func in gnutls_certificate_set_verify_function
11455 do :
11456 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11457 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11458 cat >>confdefs.h <<_ACEOF
11459 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11460 _ACEOF
11461 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11463 done
11466 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11468 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11476 if test "${with_inotify}" = "yes"; then
11477 for ac_header in sys/inotify.h
11478 do :
11479 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
11480 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
11481 cat >>confdefs.h <<_ACEOF
11482 #define HAVE_SYS_INOTIFY_H 1
11483 _ACEOF
11487 done
11489 if test "$ac_cv_header_sys_inotify_h" = yes ; then
11490 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
11491 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
11497 if test "$ac_cv_func_inotify_init1" = yes; then
11499 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
11503 HAVE_POSIX_ACL=no
11504 LIBACL_LIBS=
11505 if test "${with_acl}" = "yes"; then
11506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_set_file in -lacl" >&5
11507 $as_echo_n "checking for acl_set_file in -lacl... " >&6; }
11508 if test "${ac_cv_lib_acl_acl_set_file+set}" = set; then :
11509 $as_echo_n "(cached) " >&6
11510 else
11511 ac_check_lib_save_LIBS=$LIBS
11512 LIBS="-lacl $LIBS"
11513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11514 /* end confdefs.h. */
11516 /* Override any GCC internal prototype to avoid an error.
11517 Use char because int might match the return type of a GCC
11518 builtin and then its argument prototype would still apply. */
11519 #ifdef __cplusplus
11520 extern "C"
11521 #endif
11522 char acl_set_file ();
11524 main ()
11526 return acl_set_file ();
11528 return 0;
11530 _ACEOF
11531 if ac_fn_c_try_link "$LINENO"; then :
11532 ac_cv_lib_acl_acl_set_file=yes
11533 else
11534 ac_cv_lib_acl_acl_set_file=no
11536 rm -f core conftest.err conftest.$ac_objext \
11537 conftest$ac_exeext conftest.$ac_ext
11538 LIBS=$ac_check_lib_save_LIBS
11540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_acl_acl_set_file" >&5
11541 $as_echo "$ac_cv_lib_acl_acl_set_file" >&6; }
11542 if test "x$ac_cv_lib_acl_acl_set_file" = x""yes; then :
11543 HAVE_POSIX_ACL=yes
11544 else
11545 HAVE_POSIX_ACL=no
11548 if test "$HAVE_POSIX_ACL" = yes; then
11550 $as_echo "#define HAVE_POSIX_ACL 1" >>confdefs.h
11552 LIBACL_LIBS=-lacl
11553 else
11554 ac_fn_c_check_func "$LINENO" "acl_set_file" "ac_cv_func_acl_set_file"
11555 if test "x$ac_cv_func_acl_set_file" = x""yes; then :
11556 HAVE_POSIX_ACL=yes
11557 else
11558 HAVE_POSIX_ACL=no
11561 if test "$HAVE_POSIX_ACL" = yes; then
11563 $as_echo "#define HAVE_POSIX_ACL 1" >>confdefs.h
11570 HAVE_XAW3D=no
11571 LUCID_LIBW=
11572 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11573 if test "$with_xaw3d" != no; then
11574 if test "${emacs_cv_xaw3d+set}" = set; then :
11575 $as_echo_n "(cached) " >&6
11576 else
11577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11578 /* end confdefs.h. */
11580 #include <X11/Intrinsic.h>
11581 #include <X11/Xaw3d/Simple.h>
11583 main ()
11587 return 0;
11589 _ACEOF
11590 if ac_fn_c_try_link "$LINENO"; then :
11591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11592 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11593 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11594 $as_echo_n "(cached) " >&6
11595 else
11596 ac_check_lib_save_LIBS=$LIBS
11597 LIBS="-lXaw3d $LIBS"
11598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11599 /* end confdefs.h. */
11601 /* Override any GCC internal prototype to avoid an error.
11602 Use char because int might match the return type of a GCC
11603 builtin and then its argument prototype would still apply. */
11604 #ifdef __cplusplus
11605 extern "C"
11606 #endif
11607 char XawScrollbarSetThumb ();
11609 main ()
11611 return XawScrollbarSetThumb ();
11613 return 0;
11615 _ACEOF
11616 if ac_fn_c_try_link "$LINENO"; then :
11617 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11618 else
11619 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11621 rm -f core conftest.err conftest.$ac_objext \
11622 conftest$ac_exeext conftest.$ac_ext
11623 LIBS=$ac_check_lib_save_LIBS
11625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11626 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11627 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11628 emacs_cv_xaw3d=yes
11629 else
11630 emacs_cv_xaw3d=no
11633 else
11634 emacs_cv_xaw3d=no
11636 rm -f core conftest.err conftest.$ac_objext \
11637 conftest$ac_exeext conftest.$ac_ext
11640 else
11641 emacs_cv_xaw3d=no
11643 if test $emacs_cv_xaw3d = yes; then
11644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11645 $as_echo_n "checking for xaw3d... " >&6; }
11646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11647 $as_echo "yes; using Lucid toolkit" >&6; }
11648 USE_X_TOOLKIT=LUCID
11649 HAVE_XAW3D=yes
11650 LUCID_LIBW=-lXaw3d
11652 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11654 else
11655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11656 $as_echo_n "checking for xaw3d... " >&6; }
11657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11658 $as_echo "no" >&6; }
11659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11660 $as_echo_n "checking for libXaw... " >&6; }
11661 if test "${emacs_cv_xaw+set}" = set; then :
11662 $as_echo_n "(cached) " >&6
11663 else
11664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11665 /* end confdefs.h. */
11667 #include <X11/Intrinsic.h>
11668 #include <X11/Xaw/Simple.h>
11670 main ()
11674 return 0;
11676 _ACEOF
11677 if ac_fn_c_try_link "$LINENO"; then :
11678 emacs_cv_xaw=yes
11679 else
11680 emacs_cv_xaw=no
11682 rm -f core conftest.err conftest.$ac_objext \
11683 conftest$ac_exeext conftest.$ac_ext
11686 if test $emacs_cv_xaw = yes; then
11687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11688 $as_echo "yes; using Lucid toolkit" >&6; }
11689 USE_X_TOOLKIT=LUCID
11690 LUCID_LIBW=-lXaw
11691 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11692 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11693 else
11694 as_fn_error "No X toolkit could be found.
11695 If you are sure you want Emacs compiled without an X toolkit, pass
11696 --with-x-toolkit=no
11697 to configure. Otherwise, install the development libraries for the toolkit
11698 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11703 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11705 LIBXTR6=
11706 if test "${USE_X_TOOLKIT}" != "none"; then
11707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11708 $as_echo_n "checking X11 toolkit version... " >&6; }
11709 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11710 $as_echo_n "(cached) " >&6
11711 else
11712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11713 /* end confdefs.h. */
11714 #include <X11/Intrinsic.h>
11716 main ()
11718 #if XtSpecificationRelease < 6
11719 fail;
11720 #endif
11723 return 0;
11725 _ACEOF
11726 if ac_fn_c_try_link "$LINENO"; then :
11727 emacs_cv_x11_toolkit_version_6=yes
11728 else
11729 emacs_cv_x11_toolkit_version_6=no
11731 rm -f core conftest.err conftest.$ac_objext \
11732 conftest$ac_exeext conftest.$ac_ext
11735 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11736 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11738 $as_echo "6 or newer" >&6; }
11740 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11742 LIBXTR6="-lSM -lICE"
11743 case "$opsys" in
11744 ## Use libw.a along with X11R6 Xt.
11745 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11746 esac
11747 else
11748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11749 $as_echo "before 6" >&6; }
11752 OLDLIBS="$LIBS"
11753 if test x$HAVE_X11XTR6 = xyes; then
11754 LIBS="-lXt -lSM -lICE $LIBS"
11755 else
11756 LIBS="-lXt $LIBS"
11758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11759 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11760 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11761 $as_echo_n "(cached) " >&6
11762 else
11763 ac_check_lib_save_LIBS=$LIBS
11764 LIBS="-lXmu $LIBS"
11765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11766 /* end confdefs.h. */
11768 /* Override any GCC internal prototype to avoid an error.
11769 Use char because int might match the return type of a GCC
11770 builtin and then its argument prototype would still apply. */
11771 #ifdef __cplusplus
11772 extern "C"
11773 #endif
11774 char XmuConvertStandardSelection ();
11776 main ()
11778 return XmuConvertStandardSelection ();
11780 return 0;
11782 _ACEOF
11783 if ac_fn_c_try_link "$LINENO"; then :
11784 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11785 else
11786 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11788 rm -f core conftest.err conftest.$ac_objext \
11789 conftest$ac_exeext conftest.$ac_ext
11790 LIBS=$ac_check_lib_save_LIBS
11792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11793 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11794 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11795 cat >>confdefs.h <<_ACEOF
11796 #define HAVE_LIBXMU 1
11797 _ACEOF
11799 LIBS="-lXmu $LIBS"
11803 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11807 LIBXMU=-lXmu
11808 case $opsys in
11809 ## These systems don't supply Xmu.
11810 hpux* | aix4-2 )
11811 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11813 esac
11816 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11817 if test "${HAVE_X11}" = "yes"; then
11818 if test "${USE_X_TOOLKIT}" != "none"; then
11819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11820 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11821 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11822 $as_echo_n "(cached) " >&6
11823 else
11824 ac_check_lib_save_LIBS=$LIBS
11825 LIBS="-lXext $LIBS"
11826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11827 /* end confdefs.h. */
11829 /* Override any GCC internal prototype to avoid an error.
11830 Use char because int might match the return type of a GCC
11831 builtin and then its argument prototype would still apply. */
11832 #ifdef __cplusplus
11833 extern "C"
11834 #endif
11835 char XShapeQueryExtension ();
11837 main ()
11839 return XShapeQueryExtension ();
11841 return 0;
11843 _ACEOF
11844 if ac_fn_c_try_link "$LINENO"; then :
11845 ac_cv_lib_Xext_XShapeQueryExtension=yes
11846 else
11847 ac_cv_lib_Xext_XShapeQueryExtension=no
11849 rm -f core conftest.err conftest.$ac_objext \
11850 conftest$ac_exeext conftest.$ac_ext
11851 LIBS=$ac_check_lib_save_LIBS
11853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11854 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11855 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11856 cat >>confdefs.h <<_ACEOF
11857 #define HAVE_LIBXEXT 1
11858 _ACEOF
11860 LIBS="-lXext $LIBS"
11867 LIBXP=
11868 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11869 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11870 if test -d /usr/include/openmotif; then
11871 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11872 emacs_cv_openmotif=yes
11873 case "$canonical" in
11874 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11875 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11878 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11879 esac
11880 else
11881 emacs_cv_openmotif=no
11883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11884 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11885 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11886 $as_echo_n "(cached) " >&6
11887 else
11888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11889 /* end confdefs.h. */
11890 #include <Xm/Xm.h>
11892 main ()
11894 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11895 int x = 5;
11896 #else
11897 Motif version prior to 2.1.
11898 #endif
11900 return 0;
11902 _ACEOF
11903 if ac_fn_c_try_compile "$LINENO"; then :
11904 emacs_cv_motif_version_2_1=yes
11905 else
11906 emacs_cv_motif_version_2_1=no
11908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11911 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11912 if test $emacs_cv_motif_version_2_1 = yes; then
11913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11914 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11915 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11916 $as_echo_n "(cached) " >&6
11917 else
11918 ac_check_lib_save_LIBS=$LIBS
11919 LIBS="-lXp $LIBS"
11920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11921 /* end confdefs.h. */
11923 /* Override any GCC internal prototype to avoid an error.
11924 Use char because int might match the return type of a GCC
11925 builtin and then its argument prototype would still apply. */
11926 #ifdef __cplusplus
11927 extern "C"
11928 #endif
11929 char XpCreateContext ();
11931 main ()
11933 return XpCreateContext ();
11935 return 0;
11937 _ACEOF
11938 if ac_fn_c_try_link "$LINENO"; then :
11939 ac_cv_lib_Xp_XpCreateContext=yes
11940 else
11941 ac_cv_lib_Xp_XpCreateContext=no
11943 rm -f core conftest.err conftest.$ac_objext \
11944 conftest$ac_exeext conftest.$ac_ext
11945 LIBS=$ac_check_lib_save_LIBS
11947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11948 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11949 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11950 LIBXP=-lXp
11953 if test x$emacs_cv_openmotif = xyes; then
11954 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11956 else
11957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11958 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11959 if test "${emacs_cv_lesstif+set}" = set; then :
11960 $as_echo_n "(cached) " >&6
11961 else
11962 # We put this in CFLAGS temporarily to precede other -I options
11963 # that might be in CFLAGS temporarily.
11964 # We put this in CPPFLAGS where it precedes the other -I options.
11965 OLD_CPPFLAGS=$CPPFLAGS
11966 OLD_CFLAGS=$CFLAGS
11967 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11968 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11970 /* end confdefs.h. */
11971 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11973 main ()
11975 int x = 5;
11977 return 0;
11979 _ACEOF
11980 if ac_fn_c_try_compile "$LINENO"; then :
11981 emacs_cv_lesstif=yes
11982 else
11983 emacs_cv_lesstif=no
11985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11988 $as_echo "$emacs_cv_lesstif" >&6; }
11989 if test $emacs_cv_lesstif = yes; then
11990 # Make sure this -I option remains in CPPFLAGS after it is set
11991 # back to REAL_CPPFLAGS.
11992 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11993 # have those other -I options anyway. Ultimately, having this
11994 # directory ultimately in CPPFLAGS will be enough.
11995 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11996 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11997 else
11998 CFLAGS=$OLD_CFLAGS
11999 CPPFLAGS=$OLD_CPPFLAGS
12002 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12003 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12005 else
12006 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12013 USE_TOOLKIT_SCROLL_BARS=no
12014 if test "${with_toolkit_scroll_bars}" != "no"; then
12015 if test "${USE_X_TOOLKIT}" != "none"; then
12016 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12017 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12019 HAVE_XAW3D=no
12020 USE_TOOLKIT_SCROLL_BARS=yes
12021 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12022 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12024 USE_TOOLKIT_SCROLL_BARS=yes
12026 elif test "${HAVE_GTK}" = "yes"; then
12027 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12029 USE_TOOLKIT_SCROLL_BARS=yes
12030 elif test "${HAVE_NS}" = "yes"; then
12031 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12033 USE_TOOLKIT_SCROLL_BARS=yes
12034 elif test "${HAVE_W32}" = "yes"; then
12035 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12037 USE_TOOLKIT_SCROLL_BARS=yes
12041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12042 /* end confdefs.h. */
12044 #include <X11/Xlib.h>
12045 #include <X11/Xresource.h>
12047 main ()
12049 XIMProc callback;
12051 return 0;
12053 _ACEOF
12054 if ac_fn_c_try_compile "$LINENO"; then :
12055 HAVE_XIM=yes
12057 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12059 else
12060 HAVE_XIM=no
12062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12065 if test "${with_xim}" != "no"; then
12067 $as_echo "#define USE_XIM 1" >>confdefs.h
12072 if test "${HAVE_XIM}" != "no"; then
12073 late_CFLAGS=$CFLAGS
12074 if test "$GCC" = yes; then
12075 CFLAGS="$CFLAGS --pedantic-errors"
12077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12078 /* end confdefs.h. */
12080 #include <X11/Xlib.h>
12081 #include <X11/Xresource.h>
12083 main ()
12085 Display *display;
12086 XrmDatabase db;
12087 char *res_name;
12088 char *res_class;
12089 XIMProc callback;
12090 XPointer *client_data;
12091 #ifndef __GNUC__
12092 /* If we're not using GCC, it's probably not XFree86, and this is
12093 probably right, but we can't use something like --pedantic-errors. */
12094 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12095 char*, XIMProc, XPointer*);
12096 #endif
12097 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12098 client_data);
12100 return 0;
12102 _ACEOF
12103 if ac_fn_c_try_compile "$LINENO"; then :
12104 emacs_cv_arg6_star=yes
12106 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12107 if test "$emacs_cv_arg6_star" = yes; then
12108 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12110 else
12111 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12114 CFLAGS=$late_CFLAGS
12117 ### Start of font-backend (under any platform) section.
12118 # (nothing here yet -- this is a placeholder)
12119 ### End of font-backend (under any platform) section.
12121 ### Start of font-backend (under X11) section.
12122 if test "${HAVE_X11}" = "yes"; then
12124 succeeded=no
12126 if test "$PKG_CONFIG" = "no" ; then
12127 HAVE_FC=no
12128 else
12129 PKG_CONFIG_MIN_VERSION=0.9.0
12130 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12132 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12134 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12135 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12136 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12137 edit_cflags="
12138 s,///*,/,g
12139 s/^/ /
12140 s/ -I/ $isystem/g
12141 s/^ //
12143 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12144 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12146 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12147 succeeded=yes
12148 else
12149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12150 $as_echo "no" >&6; }
12151 FONTCONFIG_CFLAGS=""
12152 FONTCONFIG_LIBS=""
12153 ## If we have a custom action on failure, don't print errors, but
12154 ## do set a variable so people can do so. Do it in a subshell
12155 ## to capture any diagnostics in invoking pkg-config.
12156 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12162 else
12163 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12164 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12168 if test $succeeded = yes; then
12169 HAVE_FC=yes
12170 else
12171 HAVE_FC=no
12175 ## Use -lXft if available, unless `--with-xft=no'.
12176 HAVE_XFT=maybe
12177 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12178 with_xft="no";
12180 if test "x${with_xft}" != "xno"; then
12183 succeeded=no
12185 if test "$PKG_CONFIG" = "no" ; then
12186 HAVE_XFT=no
12187 else
12188 PKG_CONFIG_MIN_VERSION=0.9.0
12189 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12191 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12193 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
12194 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
12195 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
12196 edit_cflags="
12197 s,///*,/,g
12198 s/^/ /
12199 s/ -I/ $isystem/g
12200 s/^ //
12202 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
12203 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12205 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12206 succeeded=yes
12207 else
12208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12209 $as_echo "no" >&6; }
12210 XFT_CFLAGS=""
12211 XFT_LIBS=""
12212 ## If we have a custom action on failure, don't print errors, but
12213 ## do set a variable so people can do so. Do it in a subshell
12214 ## to capture any diagnostics in invoking pkg-config.
12215 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
12221 else
12222 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12223 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12227 if test $succeeded = yes; then
12229 else
12230 HAVE_XFT=no
12233 ## Because xftfont.c uses XRenderQueryExtension, we also
12234 ## need to link to -lXrender.
12235 HAVE_XRENDER=no
12236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12237 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12238 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12239 $as_echo_n "(cached) " >&6
12240 else
12241 ac_check_lib_save_LIBS=$LIBS
12242 LIBS="-lXrender $LIBS"
12243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12244 /* end confdefs.h. */
12246 /* Override any GCC internal prototype to avoid an error.
12247 Use char because int might match the return type of a GCC
12248 builtin and then its argument prototype would still apply. */
12249 #ifdef __cplusplus
12250 extern "C"
12251 #endif
12252 char XRenderQueryExtension ();
12254 main ()
12256 return XRenderQueryExtension ();
12258 return 0;
12260 _ACEOF
12261 if ac_fn_c_try_link "$LINENO"; then :
12262 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12263 else
12264 ac_cv_lib_Xrender_XRenderQueryExtension=no
12266 rm -f core conftest.err conftest.$ac_objext \
12267 conftest$ac_exeext conftest.$ac_ext
12268 LIBS=$ac_check_lib_save_LIBS
12270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12271 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12272 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12273 HAVE_XRENDER=yes
12276 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12277 OLD_CPPFLAGS="$CPPFLAGS"
12278 OLD_CFLAGS="$CFLAGS"
12279 OLD_LIBS="$LIBS"
12280 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12281 CFLAGS="$CFLAGS $XFT_CFLAGS"
12282 XFT_LIBS="-lXrender $XFT_LIBS"
12283 LIBS="$XFT_LIBS $LIBS"
12284 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12285 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12287 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12288 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12289 $as_echo_n "(cached) " >&6
12290 else
12291 ac_check_lib_save_LIBS=$LIBS
12292 LIBS="-lXft $XFT_LIBS $LIBS"
12293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12294 /* end confdefs.h. */
12296 /* Override any GCC internal prototype to avoid an error.
12297 Use char because int might match the return type of a GCC
12298 builtin and then its argument prototype would still apply. */
12299 #ifdef __cplusplus
12300 extern "C"
12301 #endif
12302 char XftFontOpen ();
12304 main ()
12306 return XftFontOpen ();
12308 return 0;
12310 _ACEOF
12311 if ac_fn_c_try_link "$LINENO"; then :
12312 ac_cv_lib_Xft_XftFontOpen=yes
12313 else
12314 ac_cv_lib_Xft_XftFontOpen=no
12316 rm -f core conftest.err conftest.$ac_objext \
12317 conftest$ac_exeext conftest.$ac_ext
12318 LIBS=$ac_check_lib_save_LIBS
12320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12321 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12322 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12323 HAVE_XFT=yes
12330 if test "${HAVE_XFT}" = "yes"; then
12332 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12335 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12336 else
12337 CPPFLAGS="$OLD_CPPFLAGS"
12338 CFLAGS="$OLD_CFLAGS"
12339 LIBS="$OLD_LIBS"
12340 fi # "${HAVE_XFT}" = "yes"
12341 fi # "$HAVE_XFT" != no
12342 fi # "x${with_xft}" != "xno"
12344 ## We used to allow building with FreeType and without Xft.
12345 ## However, the ftx font backend driver is not in good shape.
12346 if test "$HAVE_XFT" != "yes"; then
12347 HAVE_XFT=no
12348 HAVE_FREETYPE=no
12349 else
12351 succeeded=no
12353 if test "$PKG_CONFIG" = "no" ; then
12354 HAVE_FREETYPE=no
12355 else
12356 PKG_CONFIG_MIN_VERSION=0.9.0
12357 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12359 $as_echo_n "checking for freetype2... " >&6; }
12361 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
12362 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
12363 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
12364 edit_cflags="
12365 s,///*,/,g
12366 s/^/ /
12367 s/ -I/ $isystem/g
12368 s/^ //
12370 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12371 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12373 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12374 succeeded=yes
12375 else
12376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12377 $as_echo "no" >&6; }
12378 FREETYPE_CFLAGS=""
12379 FREETYPE_LIBS=""
12380 ## If we have a custom action on failure, don't print errors, but
12381 ## do set a variable so people can do so. Do it in a subshell
12382 ## to capture any diagnostics in invoking pkg-config.
12383 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
12389 else
12390 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12391 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12395 if test $succeeded = yes; then
12396 HAVE_FREETYPE=yes
12397 else
12398 HAVE_FREETYPE=no
12402 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12405 HAVE_LIBOTF=no
12406 if test "${HAVE_FREETYPE}" = "yes"; then
12408 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12410 if test "${with_libotf}" != "no"; then
12412 succeeded=no
12414 if test "$PKG_CONFIG" = "no" ; then
12415 HAVE_LIBOTF=no
12416 else
12417 PKG_CONFIG_MIN_VERSION=0.9.0
12418 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12420 $as_echo_n "checking for libotf... " >&6; }
12422 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
12423 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
12424 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
12425 edit_cflags="
12426 s,///*,/,g
12427 s/^/ /
12428 s/ -I/ $isystem/g
12429 s/^ //
12431 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12432 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12434 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12435 succeeded=yes
12436 else
12437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12438 $as_echo "no" >&6; }
12439 LIBOTF_CFLAGS=""
12440 LIBOTF_LIBS=""
12441 ## If we have a custom action on failure, don't print errors, but
12442 ## do set a variable so people can do so. Do it in a subshell
12443 ## to capture any diagnostics in invoking pkg-config.
12444 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
12450 else
12451 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12452 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12456 if test $succeeded = yes; then
12457 HAVE_LIBOTF=yes
12458 else
12459 HAVE_LIBOTF=no
12462 if test "$HAVE_LIBOTF" = "yes"; then
12464 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12467 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12468 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12469 $as_echo_n "(cached) " >&6
12470 else
12471 ac_check_lib_save_LIBS=$LIBS
12472 LIBS="-lotf $LIBS"
12473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12474 /* end confdefs.h. */
12476 /* Override any GCC internal prototype to avoid an error.
12477 Use char because int might match the return type of a GCC
12478 builtin and then its argument prototype would still apply. */
12479 #ifdef __cplusplus
12480 extern "C"
12481 #endif
12482 char OTF_get_variation_glyphs ();
12484 main ()
12486 return OTF_get_variation_glyphs ();
12488 return 0;
12490 _ACEOF
12491 if ac_fn_c_try_link "$LINENO"; then :
12492 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12493 else
12494 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12496 rm -f core conftest.err conftest.$ac_objext \
12497 conftest$ac_exeext conftest.$ac_ext
12498 LIBS=$ac_check_lib_save_LIBS
12500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12501 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12502 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12503 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12504 else
12505 HAVE_OTF_GET_VARIATION_GLYPHS=no
12508 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12510 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12517 HAVE_M17N_FLT=no
12518 if test "${HAVE_LIBOTF}" = yes; then
12519 if test "${with_m17n_flt}" != "no"; then
12521 succeeded=no
12523 if test "$PKG_CONFIG" = "no" ; then
12524 HAVE_M17N_FLT=no
12525 else
12526 PKG_CONFIG_MIN_VERSION=0.9.0
12527 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12529 $as_echo_n "checking for m17n-flt... " >&6; }
12531 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
12532 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
12533 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
12534 edit_cflags="
12535 s,///*,/,g
12536 s/^/ /
12537 s/ -I/ $isystem/g
12538 s/^ //
12540 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12541 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12543 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12544 succeeded=yes
12545 else
12546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12547 $as_echo "no" >&6; }
12548 M17N_FLT_CFLAGS=""
12549 M17N_FLT_LIBS=""
12550 ## If we have a custom action on failure, don't print errors, but
12551 ## do set a variable so people can do so. Do it in a subshell
12552 ## to capture any diagnostics in invoking pkg-config.
12553 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
12559 else
12560 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12561 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12565 if test $succeeded = yes; then
12566 HAVE_M17N_FLT=yes
12567 else
12568 HAVE_M17N_FLT=no
12571 if test "$HAVE_M17N_FLT" = "yes"; then
12573 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12578 else
12579 HAVE_XFT=no
12580 HAVE_FREETYPE=no
12581 HAVE_LIBOTF=no
12582 HAVE_M17N_FLT=no
12585 ### End of font-backend (under X11) section.
12596 ### Use -lXpm if available, unless `--with-xpm=no'.
12597 HAVE_XPM=no
12598 LIBXPM=
12600 if test "${HAVE_W32}" = "yes"; then
12601 if test "${with_xpm}" != "no"; then
12602 SAVE_CPPFLAGS="$CPPFLAGS"
12603 SAVE_LDFLAGS="$LDFLAGS"
12604 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
12605 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
12606 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12607 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
12609 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
12610 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
12611 $as_echo_n "(cached) " >&6
12612 else
12613 ac_check_lib_save_LIBS=$LIBS
12614 LIBS="-lXpm $LIBS"
12615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12616 /* end confdefs.h. */
12618 /* Override any GCC internal prototype to avoid an error.
12619 Use char because int might match the return type of a GCC
12620 builtin and then its argument prototype would still apply. */
12621 #ifdef __cplusplus
12622 extern "C"
12623 #endif
12624 char XpmReadFileToImage ();
12626 main ()
12628 return XpmReadFileToImage ();
12630 return 0;
12632 _ACEOF
12633 if ac_fn_c_try_link "$LINENO"; then :
12634 ac_cv_lib_Xpm_XpmReadFileToImage=yes
12635 else
12636 ac_cv_lib_Xpm_XpmReadFileToImage=no
12638 rm -f core conftest.err conftest.$ac_objext \
12639 conftest$ac_exeext conftest.$ac_ext
12640 LIBS=$ac_check_lib_save_LIBS
12642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
12643 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
12644 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
12645 HAVE_XPM=yes
12651 if test "${HAVE_XPM}" = "yes"; then
12652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12653 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12655 /* end confdefs.h. */
12656 #include "X11/xpm.h"
12657 #ifndef XpmReturnAllocPixels
12658 no_return_alloc_pixels
12659 #endif
12661 _ACEOF
12662 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12663 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12664 HAVE_XPM=no
12665 else
12666 HAVE_XPM=yes
12668 rm -f conftest*
12671 if test "${HAVE_XPM}" = "yes"; then
12672 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
12673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12674 $as_echo "yes" >&6; }
12675 else
12676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12677 $as_echo "no" >&6; }
12678 CPPFLAGS="$SAVE_CPPFLAGS"
12679 LDFLAGS="$SAVE_LDFLAGS"
12684 if test "${HAVE_XPM}" = "yes"; then
12686 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12688 LIBXPM=-lXpm
12692 if test "${HAVE_X11}" = "yes"; then
12693 if test "${with_xpm}" != "no"; then
12694 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12695 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12697 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12698 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12699 $as_echo_n "(cached) " >&6
12700 else
12701 ac_check_lib_save_LIBS=$LIBS
12702 LIBS="-lXpm -lX11 $LIBS"
12703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12704 /* end confdefs.h. */
12706 /* Override any GCC internal prototype to avoid an error.
12707 Use char because int might match the return type of a GCC
12708 builtin and then its argument prototype would still apply. */
12709 #ifdef __cplusplus
12710 extern "C"
12711 #endif
12712 char XpmReadFileToPixmap ();
12714 main ()
12716 return XpmReadFileToPixmap ();
12718 return 0;
12720 _ACEOF
12721 if ac_fn_c_try_link "$LINENO"; then :
12722 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12723 else
12724 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12726 rm -f core conftest.err conftest.$ac_objext \
12727 conftest$ac_exeext conftest.$ac_ext
12728 LIBS=$ac_check_lib_save_LIBS
12730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12731 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12732 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12733 HAVE_XPM=yes
12739 if test "${HAVE_XPM}" = "yes"; then
12740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12741 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12743 /* end confdefs.h. */
12744 #include "X11/xpm.h"
12745 #ifndef XpmReturnAllocPixels
12746 no_return_alloc_pixels
12747 #endif
12749 _ACEOF
12750 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12751 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12752 HAVE_XPM=no
12753 else
12754 HAVE_XPM=yes
12756 rm -f conftest*
12759 if test "${HAVE_XPM}" = "yes"; then
12760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12761 $as_echo "yes" >&6; }
12762 else
12763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12764 $as_echo "no" >&6; }
12769 if test "${HAVE_XPM}" = "yes"; then
12771 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12773 LIBXPM=-lXpm
12779 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12780 HAVE_JPEG=no
12781 LIBJPEG=
12782 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12783 if test "${with_jpeg}" != "no"; then
12784 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12785 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12787 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12788 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12789 $as_echo_n "(cached) " >&6
12790 else
12791 ac_check_lib_save_LIBS=$LIBS
12792 LIBS="-ljpeg $LIBS"
12793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12794 /* end confdefs.h. */
12796 /* Override any GCC internal prototype to avoid an error.
12797 Use char because int might match the return type of a GCC
12798 builtin and then its argument prototype would still apply. */
12799 #ifdef __cplusplus
12800 extern "C"
12801 #endif
12802 char jpeg_destroy_compress ();
12804 main ()
12806 return jpeg_destroy_compress ();
12808 return 0;
12810 _ACEOF
12811 if ac_fn_c_try_link "$LINENO"; then :
12812 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12813 else
12814 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12816 rm -f core conftest.err conftest.$ac_objext \
12817 conftest$ac_exeext conftest.$ac_ext
12818 LIBS=$ac_check_lib_save_LIBS
12820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12821 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12822 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12823 HAVE_JPEG=yes
12831 if test "${HAVE_JPEG}" = "yes"; then
12832 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12834 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12835 /* end confdefs.h. */
12836 #include <jpeglib.h>
12837 version=JPEG_LIB_VERSION
12839 _ACEOF
12840 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12841 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12842 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12844 else
12845 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12846 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12847 HAVE_JPEG=no
12849 rm -f conftest*
12852 if test "${HAVE_JPEG}" = "yes"; then
12853 LIBJPEG=-ljpeg
12858 ### Use -lpng if available, unless `--with-png=no'.
12859 HAVE_PNG=no
12860 LIBPNG=
12861 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12862 if test "${with_png}" != "no"; then
12863 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12864 # in /usr/include/libpng.
12865 for ac_header in png.h libpng/png.h
12866 do :
12867 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12868 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12869 eval as_val=\$$as_ac_Header
12870 if test "x$as_val" = x""yes; then :
12871 cat >>confdefs.h <<_ACEOF
12872 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12873 _ACEOF
12874 break
12877 done
12879 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12881 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12882 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12883 $as_echo_n "(cached) " >&6
12884 else
12885 ac_check_lib_save_LIBS=$LIBS
12886 LIBS="-lpng -lz -lm $LIBS"
12887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12888 /* end confdefs.h. */
12890 /* Override any GCC internal prototype to avoid an error.
12891 Use char because int might match the return type of a GCC
12892 builtin and then its argument prototype would still apply. */
12893 #ifdef __cplusplus
12894 extern "C"
12895 #endif
12896 char png_get_channels ();
12898 main ()
12900 return png_get_channels ();
12902 return 0;
12904 _ACEOF
12905 if ac_fn_c_try_link "$LINENO"; then :
12906 ac_cv_lib_png_png_get_channels=yes
12907 else
12908 ac_cv_lib_png_png_get_channels=no
12910 rm -f core conftest.err conftest.$ac_objext \
12911 conftest$ac_exeext conftest.$ac_ext
12912 LIBS=$ac_check_lib_save_LIBS
12914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12915 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12916 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12917 HAVE_PNG=yes
12923 if test "${HAVE_PNG}" = "yes"; then
12925 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12927 LIBPNG="-lpng -lz -lm"
12929 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12930 # include <libpng/png.h>
12931 #else
12932 # include <png.h>
12933 #endif
12936 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12938 else
12940 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12948 ### Use -ltiff if available, unless `--with-tiff=no'.
12949 HAVE_TIFF=no
12950 LIBTIFF=
12951 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12952 if test "${with_tiff}" != "no"; then
12953 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12954 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12955 tifflibs="-lz -lm"
12956 # At least one tiff package requires the jpeg library.
12957 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12959 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12960 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12961 $as_echo_n "(cached) " >&6
12962 else
12963 ac_check_lib_save_LIBS=$LIBS
12964 LIBS="-ltiff $tifflibs $LIBS"
12965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12966 /* end confdefs.h. */
12968 /* Override any GCC internal prototype to avoid an error.
12969 Use char because int might match the return type of a GCC
12970 builtin and then its argument prototype would still apply. */
12971 #ifdef __cplusplus
12972 extern "C"
12973 #endif
12974 char TIFFGetVersion ();
12976 main ()
12978 return TIFFGetVersion ();
12980 return 0;
12982 _ACEOF
12983 if ac_fn_c_try_link "$LINENO"; then :
12984 ac_cv_lib_tiff_TIFFGetVersion=yes
12985 else
12986 ac_cv_lib_tiff_TIFFGetVersion=no
12988 rm -f core conftest.err conftest.$ac_objext \
12989 conftest$ac_exeext conftest.$ac_ext
12990 LIBS=$ac_check_lib_save_LIBS
12992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12993 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12994 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12995 HAVE_TIFF=yes
13003 if test "${HAVE_TIFF}" = "yes"; then
13005 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13007 LIBTIFF=-ltiff
13012 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13013 HAVE_GIF=no
13014 LIBGIF=
13015 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
13016 || test "${HAVE_W32}" = "yes"; then
13017 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13018 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13019 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13020 # Earlier versions can crash Emacs.
13021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13022 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13023 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13024 $as_echo_n "(cached) " >&6
13025 else
13026 ac_check_lib_save_LIBS=$LIBS
13027 LIBS="-lgif $LIBS"
13028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13029 /* end confdefs.h. */
13031 /* Override any GCC internal prototype to avoid an error.
13032 Use char because int might match the return type of a GCC
13033 builtin and then its argument prototype would still apply. */
13034 #ifdef __cplusplus
13035 extern "C"
13036 #endif
13037 char EGifPutExtensionLast ();
13039 main ()
13041 return EGifPutExtensionLast ();
13043 return 0;
13045 _ACEOF
13046 if ac_fn_c_try_link "$LINENO"; then :
13047 ac_cv_lib_gif_EGifPutExtensionLast=yes
13048 else
13049 ac_cv_lib_gif_EGifPutExtensionLast=no
13051 rm -f core conftest.err conftest.$ac_objext \
13052 conftest$ac_exeext conftest.$ac_ext
13053 LIBS=$ac_check_lib_save_LIBS
13055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13056 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13057 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13058 HAVE_GIF=yes
13059 else
13060 HAVE_GIF=maybe
13067 if test "$HAVE_GIF" = yes; then
13068 LIBGIF=-lgif
13069 elif test "$HAVE_GIF" = maybe; then
13070 # If gif_lib.h but no libgif, try libungif.
13071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13072 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13073 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13074 $as_echo_n "(cached) " >&6
13075 else
13076 ac_check_lib_save_LIBS=$LIBS
13077 LIBS="-lungif $LIBS"
13078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13079 /* end confdefs.h. */
13081 /* Override any GCC internal prototype to avoid an error.
13082 Use char because int might match the return type of a GCC
13083 builtin and then its argument prototype would still apply. */
13084 #ifdef __cplusplus
13085 extern "C"
13086 #endif
13087 char EGifPutExtensionLast ();
13089 main ()
13091 return EGifPutExtensionLast ();
13093 return 0;
13095 _ACEOF
13096 if ac_fn_c_try_link "$LINENO"; then :
13097 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13098 else
13099 ac_cv_lib_ungif_EGifPutExtensionLast=no
13101 rm -f core conftest.err conftest.$ac_objext \
13102 conftest$ac_exeext conftest.$ac_ext
13103 LIBS=$ac_check_lib_save_LIBS
13105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13106 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13107 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13108 HAVE_GIF=yes
13109 else
13110 HAVE_GIF=no
13113 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13116 if test "${HAVE_GIF}" = "yes"; then
13118 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13124 if test "${HAVE_X11}" = "yes"; then
13125 MISSING=""
13126 WITH_NO=""
13127 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13128 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13129 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13130 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13131 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13132 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13133 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13134 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13135 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13136 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13138 if test "X${MISSING}" != X; then
13139 as_fn_error "The following required libraries were not found:
13140 $MISSING
13141 Maybe some development libraries/packages are missing?
13142 If you don't want to link with them give
13143 $WITH_NO
13144 as options to configure" "$LINENO" 5
13148 ### Use -lgpm if available, unless `--with-gpm=no'.
13149 HAVE_GPM=no
13150 LIBGPM=
13151 if test "${with_gpm}" != "no"; then
13152 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13153 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13155 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13156 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13157 $as_echo_n "(cached) " >&6
13158 else
13159 ac_check_lib_save_LIBS=$LIBS
13160 LIBS="-lgpm $LIBS"
13161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13162 /* end confdefs.h. */
13164 /* Override any GCC internal prototype to avoid an error.
13165 Use char because int might match the return type of a GCC
13166 builtin and then its argument prototype would still apply. */
13167 #ifdef __cplusplus
13168 extern "C"
13169 #endif
13170 char Gpm_Open ();
13172 main ()
13174 return Gpm_Open ();
13176 return 0;
13178 _ACEOF
13179 if ac_fn_c_try_link "$LINENO"; then :
13180 ac_cv_lib_gpm_Gpm_Open=yes
13181 else
13182 ac_cv_lib_gpm_Gpm_Open=no
13184 rm -f core conftest.err conftest.$ac_objext \
13185 conftest$ac_exeext conftest.$ac_ext
13186 LIBS=$ac_check_lib_save_LIBS
13188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13189 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13190 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13191 HAVE_GPM=yes
13198 if test "${HAVE_GPM}" = "yes"; then
13200 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13202 LIBGPM=-lgpm
13211 GNUSTEP_CFLAGS=
13212 ### Use NeXTstep API to implement GUI.
13213 if test "${HAVE_NS}" = "yes"; then
13215 $as_echo "#define HAVE_NS 1" >>confdefs.h
13217 if test "${NS_IMPL_COCOA}" = "yes"; then
13219 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13222 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13224 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13226 # See also .m.o rule in Makefile.in */
13227 # FIXME: are all these flags really needed? Document here why. */
13228 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
13229 ## Extra CFLAGS applied to src/*.m files.
13230 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"
13232 # We also have mouse menus.
13233 HAVE_MENUS=yes
13234 OTHER_FILES=ns-app
13237 if test "${HAVE_W32}" = "yes"; then
13238 HAVE_MENUS=yes
13241 ### Use session management (-lSM -lICE) if available
13242 HAVE_X_SM=no
13243 LIBXSM=
13244 if test "${HAVE_X11}" = "yes"; then
13245 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13246 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13248 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13249 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13250 $as_echo_n "(cached) " >&6
13251 else
13252 ac_check_lib_save_LIBS=$LIBS
13253 LIBS="-lSM -lICE $LIBS"
13254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13255 /* end confdefs.h. */
13257 /* Override any GCC internal prototype to avoid an error.
13258 Use char because int might match the return type of a GCC
13259 builtin and then its argument prototype would still apply. */
13260 #ifdef __cplusplus
13261 extern "C"
13262 #endif
13263 char SmcOpenConnection ();
13265 main ()
13267 return SmcOpenConnection ();
13269 return 0;
13271 _ACEOF
13272 if ac_fn_c_try_link "$LINENO"; then :
13273 ac_cv_lib_SM_SmcOpenConnection=yes
13274 else
13275 ac_cv_lib_SM_SmcOpenConnection=no
13277 rm -f core conftest.err conftest.$ac_objext \
13278 conftest$ac_exeext conftest.$ac_ext
13279 LIBS=$ac_check_lib_save_LIBS
13281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13282 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13283 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13284 HAVE_X_SM=yes
13291 if test "${HAVE_X_SM}" = "yes"; then
13293 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13295 LIBXSM="-lSM -lICE"
13296 case "$LIBS" in
13297 *-lSM*) ;;
13298 *) LIBS="$LIBXSM $LIBS" ;;
13299 esac
13304 ### Use libxml (-lxml2) if available
13305 HAVE_LIBXML2=no
13306 if test "${with_xml2}" != "no"; then
13307 ### I'm not sure what the version number should be, so I just guessed.
13309 succeeded=no
13311 if test "$PKG_CONFIG" = "no" ; then
13312 HAVE_LIBXML2=no
13313 else
13314 PKG_CONFIG_MIN_VERSION=0.9.0
13315 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13317 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13319 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
13320 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
13321 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
13322 edit_cflags="
13323 s,///*,/,g
13324 s/^/ /
13325 s/ -I/ $isystem/g
13326 s/^ //
13328 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
13329 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
13330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
13331 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
13332 succeeded=yes
13333 else
13334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13335 $as_echo "no" >&6; }
13336 LIBXML2_CFLAGS=""
13337 LIBXML2_LIBS=""
13338 ## If we have a custom action on failure, don't print errors, but
13339 ## do set a variable so people can do so. Do it in a subshell
13340 ## to capture any diagnostics in invoking pkg-config.
13341 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
13347 else
13348 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13349 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13353 if test $succeeded = yes; then
13354 HAVE_LIBXML2=yes
13355 else
13356 HAVE_LIBXML2=no
13359 if test "${HAVE_LIBXML2}" = "yes"; then
13360 LIBS="$LIBXML2_LIBS $LIBS"
13361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13362 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13363 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13364 $as_echo_n "(cached) " >&6
13365 else
13366 ac_check_lib_save_LIBS=$LIBS
13367 LIBS="-lxml2 $LIBS"
13368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13369 /* end confdefs.h. */
13371 /* Override any GCC internal prototype to avoid an error.
13372 Use char because int might match the return type of a GCC
13373 builtin and then its argument prototype would still apply. */
13374 #ifdef __cplusplus
13375 extern "C"
13376 #endif
13377 char htmlReadMemory ();
13379 main ()
13381 return htmlReadMemory ();
13383 return 0;
13385 _ACEOF
13386 if ac_fn_c_try_link "$LINENO"; then :
13387 ac_cv_lib_xml2_htmlReadMemory=yes
13388 else
13389 ac_cv_lib_xml2_htmlReadMemory=no
13391 rm -f core conftest.err conftest.$ac_objext \
13392 conftest$ac_exeext conftest.$ac_ext
13393 LIBS=$ac_check_lib_save_LIBS
13395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13396 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13397 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13398 HAVE_LIBXML2=yes
13399 else
13400 HAVE_LIBXML2=no
13403 if test "${HAVE_LIBXML2}" = "yes"; then
13405 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13407 else
13408 LIBXML2_LIBS=""
13409 LIBXML2_CFLAGS=""
13416 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13418 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13419 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13420 $as_echo_n "(cached) " >&6
13421 else
13422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13423 /* end confdefs.h. */
13424 #include <netdb.h>
13426 main ()
13428 return h_errno;
13430 return 0;
13432 _ACEOF
13433 if ac_fn_c_try_link "$LINENO"; then :
13434 emacs_cv_netdb_declares_h_errno=yes
13435 else
13436 emacs_cv_netdb_declares_h_errno=no
13438 rm -f core conftest.err conftest.$ac_objext \
13439 conftest$ac_exeext conftest.$ac_ext
13441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13442 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13443 if test $emacs_cv_netdb_declares_h_errno = yes; then
13445 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13449 # sqrt and other floating-point functions such as fmod and frexp
13450 # are found in -lm on most systems.
13451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13452 $as_echo_n "checking for sqrt in -lm... " >&6; }
13453 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13454 $as_echo_n "(cached) " >&6
13455 else
13456 ac_check_lib_save_LIBS=$LIBS
13457 LIBS="-lm $LIBS"
13458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13459 /* end confdefs.h. */
13461 /* Override any GCC internal prototype to avoid an error.
13462 Use char because int might match the return type of a GCC
13463 builtin and then its argument prototype would still apply. */
13464 #ifdef __cplusplus
13465 extern "C"
13466 #endif
13467 char sqrt ();
13469 main ()
13471 return sqrt ();
13473 return 0;
13475 _ACEOF
13476 if ac_fn_c_try_link "$LINENO"; then :
13477 ac_cv_lib_m_sqrt=yes
13478 else
13479 ac_cv_lib_m_sqrt=no
13481 rm -f core conftest.err conftest.$ac_objext \
13482 conftest$ac_exeext conftest.$ac_ext
13483 LIBS=$ac_check_lib_save_LIBS
13485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13486 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13487 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13488 cat >>confdefs.h <<_ACEOF
13489 #define HAVE_LIBM 1
13490 _ACEOF
13492 LIBS="-lm $LIBS"
13497 # Check for mail-locking functions in a "mail" library. Probably this should
13498 # have the same check as for liblockfile below.
13499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13500 $as_echo_n "checking for maillock in -lmail... " >&6; }
13501 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13502 $as_echo_n "(cached) " >&6
13503 else
13504 ac_check_lib_save_LIBS=$LIBS
13505 LIBS="-lmail $LIBS"
13506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13507 /* end confdefs.h. */
13509 /* Override any GCC internal prototype to avoid an error.
13510 Use char because int might match the return type of a GCC
13511 builtin and then its argument prototype would still apply. */
13512 #ifdef __cplusplus
13513 extern "C"
13514 #endif
13515 char maillock ();
13517 main ()
13519 return maillock ();
13521 return 0;
13523 _ACEOF
13524 if ac_fn_c_try_link "$LINENO"; then :
13525 ac_cv_lib_mail_maillock=yes
13526 else
13527 ac_cv_lib_mail_maillock=no
13529 rm -f core conftest.err conftest.$ac_objext \
13530 conftest$ac_exeext conftest.$ac_ext
13531 LIBS=$ac_check_lib_save_LIBS
13533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13534 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13535 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13536 have_mail=yes
13537 else
13538 have_mail=no
13541 if test $have_mail = yes; then
13542 LIBS_MAIL=-lmail
13543 LIBS="$LIBS_MAIL $LIBS"
13545 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13547 else
13548 LIBS_MAIL=
13550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13551 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13552 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13553 $as_echo_n "(cached) " >&6
13554 else
13555 ac_check_lib_save_LIBS=$LIBS
13556 LIBS="-llockfile $LIBS"
13557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13558 /* end confdefs.h. */
13560 /* Override any GCC internal prototype to avoid an error.
13561 Use char because int might match the return type of a GCC
13562 builtin and then its argument prototype would still apply. */
13563 #ifdef __cplusplus
13564 extern "C"
13565 #endif
13566 char maillock ();
13568 main ()
13570 return maillock ();
13572 return 0;
13574 _ACEOF
13575 if ac_fn_c_try_link "$LINENO"; then :
13576 ac_cv_lib_lockfile_maillock=yes
13577 else
13578 ac_cv_lib_lockfile_maillock=no
13580 rm -f core conftest.err conftest.$ac_objext \
13581 conftest$ac_exeext conftest.$ac_ext
13582 LIBS=$ac_check_lib_save_LIBS
13584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13585 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13586 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13587 have_lockfile=yes
13588 else
13589 have_lockfile=no
13592 if test $have_lockfile = yes; then
13593 LIBS_MAIL=-llockfile
13594 LIBS="$LIBS_MAIL $LIBS"
13596 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13598 else
13599 # If we have the shared liblockfile, assume we must use it for mail
13600 # locking (e.g. Debian). If we couldn't link against liblockfile
13601 # (no liblockfile.a installed), ensure that we don't need to.
13602 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13603 set dummy liblockfile.so; ac_word=$2
13604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13605 $as_echo_n "checking for $ac_word... " >&6; }
13606 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13607 $as_echo_n "(cached) " >&6
13608 else
13609 if test -n "$liblockfile"; then
13610 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13611 else
13612 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13613 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13614 for as_dir in $as_dummy
13616 IFS=$as_save_IFS
13617 test -z "$as_dir" && as_dir=.
13618 for ac_exec_ext in '' $ac_executable_extensions; do
13619 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13620 ac_cv_prog_liblockfile="yes"
13621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13622 break 2
13624 done
13625 done
13626 IFS=$as_save_IFS
13628 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13631 liblockfile=$ac_cv_prog_liblockfile
13632 if test -n "$liblockfile"; then
13633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13634 $as_echo "$liblockfile" >&6; }
13635 else
13636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13637 $as_echo "no" >&6; }
13641 if test $ac_cv_prog_liblockfile = yes; then
13642 as_fn_error "Shared liblockfile found but can't link against it.
13643 This probably means that movemail could lose mail.
13644 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13652 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13653 ## interlock access to the mail spool. The alternative is a lock file named
13654 ## /usr/spool/mail/$USER.lock.
13655 mail_lock=no
13656 case "$opsys" in
13657 aix4-2) mail_lock="lockf" ;;
13659 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13661 ## On GNU/Linux systems, both methods are used by various mail programs.
13662 ## I assume most people are using newer mailers that have heard of flock.
13663 ## Change this if you need to.
13664 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13665 ## configure gets the right answers, and that means *NOT* using flock.
13666 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13667 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13668 ## Debian maintainer hasn't provided a clean fix for Emacs.
13669 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13670 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13671 ## correct logic. -- fx
13672 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13673 ## liblockfile is a Free Software replacement for libmail, used on
13674 ## Debian systems and elsewhere. -rfr.
13675 gnu-*)
13676 mail_lock="flock"
13677 if test $have_mail = yes || test $have_lockfile = yes; then
13678 test $ac_cv_header_maillock_h = yes && mail_lock=no
13681 esac
13683 BLESSMAIL_TARGET=
13684 case "$mail_lock" in
13685 flock)
13686 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13689 lockf)
13690 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13693 *) BLESSMAIL_TARGET="need-blessmail" ;;
13694 esac
13698 for ac_func in gethostname \
13699 getrusage get_current_dir_name \
13700 lrand48 \
13701 select getpagesize setlocale \
13702 utimes getrlimit setrlimit shutdown getaddrinfo \
13703 strsignal setitimer \
13704 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13705 gai_strerror mkstemp getline getdelim fsync sync \
13706 difftime posix_memalign \
13707 getpwent endpwent getgrent endgrent \
13708 touchlock \
13709 cfmakeraw cfsetspeed copysign __executable_start
13710 do :
13711 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13712 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13713 eval as_val=\$$as_ac_var
13714 if test "x$as_val" = x""yes; then :
13715 cat >>confdefs.h <<_ACEOF
13716 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13717 _ACEOF
13720 done
13723 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13724 ## has a broken `rint' in some library versions including math library
13725 ## version number A.09.05.
13726 ## You can fix the math library by installing patch number PHSS_4630.
13727 ## But we can fix it more reliably for Emacs by just not using rint.
13728 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13729 case $opsys in
13730 hpux*) : ;;
13731 *) for ac_func in random rint
13732 do :
13733 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13734 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13735 eval as_val=\$$as_ac_var
13736 if test "x$as_val" = x""yes; then :
13737 cat >>confdefs.h <<_ACEOF
13738 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13739 _ACEOF
13742 done
13744 esac
13746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13747 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13748 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13749 $as_echo_n "(cached) " >&6
13750 else
13751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13752 /* end confdefs.h. */
13755 main ()
13757 __builtin_unwind_init ();
13759 return 0;
13761 _ACEOF
13762 if ac_fn_c_try_link "$LINENO"; then :
13763 emacs_cv_func___builtin_unwind_init=yes
13764 else
13765 emacs_cv_func___builtin_unwind_init=no
13767 rm -f core conftest.err conftest.$ac_objext \
13768 conftest$ac_exeext conftest.$ac_ext
13770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13771 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13772 if test $emacs_cv_func___builtin_unwind_init = yes; then
13774 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13783 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13784 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13785 $as_echo_n "(cached) " >&6
13786 else
13787 while :; do
13788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13789 /* end confdefs.h. */
13790 #include <sys/types.h> /* for off_t */
13791 #include <stdio.h>
13793 main ()
13795 int (*fp) (FILE *, off_t, int) = fseeko;
13796 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13798 return 0;
13800 _ACEOF
13801 if ac_fn_c_try_link "$LINENO"; then :
13802 ac_cv_sys_largefile_source=no; break
13804 rm -f core conftest.err conftest.$ac_objext \
13805 conftest$ac_exeext conftest.$ac_ext
13806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13807 /* end confdefs.h. */
13808 #define _LARGEFILE_SOURCE 1
13809 #include <sys/types.h> /* for off_t */
13810 #include <stdio.h>
13812 main ()
13814 int (*fp) (FILE *, off_t, int) = fseeko;
13815 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13817 return 0;
13819 _ACEOF
13820 if ac_fn_c_try_link "$LINENO"; then :
13821 ac_cv_sys_largefile_source=1; break
13823 rm -f core conftest.err conftest.$ac_objext \
13824 conftest$ac_exeext conftest.$ac_ext
13825 ac_cv_sys_largefile_source=unknown
13826 break
13827 done
13829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13830 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13831 case $ac_cv_sys_largefile_source in #(
13832 no | unknown) ;;
13834 cat >>confdefs.h <<_ACEOF
13835 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13836 _ACEOF
13838 esac
13839 rm -rf conftest*
13841 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13842 # in glibc 2.1.3, but that breaks too many other things.
13843 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13844 if test $ac_cv_sys_largefile_source != unknown; then
13846 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13851 # UNIX98 PTYs.
13852 for ac_func in grantpt
13853 do :
13854 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13855 if test "x$ac_cv_func_grantpt" = x""yes; then :
13856 cat >>confdefs.h <<_ACEOF
13857 #define HAVE_GRANTPT 1
13858 _ACEOF
13861 done
13864 # PTY-related GNU extensions.
13865 for ac_func in getpt posix_openpt
13866 do :
13867 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13868 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13869 eval as_val=\$$as_ac_var
13870 if test "x$as_val" = x""yes; then :
13871 cat >>confdefs.h <<_ACEOF
13872 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13873 _ACEOF
13876 done
13879 # Check this now, so that we will NOT find the above functions in ncurses.
13880 # That is because we have not set up to link ncurses in lib-src.
13881 # It's better to believe a function is not available
13882 # than to expect to find it in ncurses.
13883 # Also we need tputs and friends to be able to build at all.
13884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13885 $as_echo_n "checking for library containing tputs... " >&6; }
13886 # Run a test program that contains a call to tputs, a call that is
13887 # never executed. This tests whether a pre-'main' dynamic linker
13888 # works with the library. It's too much trouble to actually call
13889 # tputs in the test program, due to portability hassles. When
13890 # cross-compiling, assume the test program will run if it links.
13892 # Maybe curses should be tried earlier?
13893 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13894 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13895 OLIBS=$LIBS
13896 if test -z "$tputs_library"; then
13897 LIBS_TERMCAP=
13898 msg='none required'
13899 else
13900 LIBS_TERMCAP=-l$tputs_library
13901 msg=$LIBS_TERMCAP
13902 LIBS="$LIBS_TERMCAP $LIBS"
13904 if test "$cross_compiling" = yes; then :
13905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13906 /* end confdefs.h. */
13908 extern void tputs (const char *, int, int (*)(int));
13909 int main (int argc, char **argv)
13911 if (argc == 10000)
13912 tputs (argv[0], 0, 0);
13913 return 0;
13916 _ACEOF
13917 if ac_fn_c_try_link "$LINENO"; then :
13919 else
13920 msg=no
13922 rm -f core conftest.err conftest.$ac_objext \
13923 conftest$ac_exeext conftest.$ac_ext
13924 else
13925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13926 /* end confdefs.h. */
13928 extern void tputs (const char *, int, int (*)(int));
13929 int main (int argc, char **argv)
13931 if (argc == 10000)
13932 tputs (argv[0], 0, 0);
13933 return 0;
13936 _ACEOF
13937 if ac_fn_c_try_run "$LINENO"; then :
13939 else
13940 msg=no
13942 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13943 conftest.$ac_objext conftest.beam conftest.$ac_ext
13946 LIBS=$OLIBS
13947 if test "X$msg" != Xno; then
13948 break
13950 done
13951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13952 $as_echo "$msg" >&6; }
13953 if test "X$msg" = Xno; then
13954 as_fn_error "The required function \`tputs' was not found in any library.
13955 The following libraries were tried (in order):
13956 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13957 Please try installing whichever of these libraries is most appropriate
13958 for your system, together with its header files.
13959 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13962 ## Use termcap instead of terminfo?
13963 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13964 TERMINFO=yes
13965 ## FIXME? In the cases below where we unconditionally set
13966 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13967 ## if that was found above to have tputs.
13968 ## Should we use the gnu* logic everywhere?
13969 case "$opsys" in
13970 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13971 ## The ncurses library has been moved out of the System framework in
13972 ## Mac OS X 10.2. So if configure detects it, set the command-line
13973 ## option to use it.
13974 darwin) LIBS_TERMCAP="-lncurses" ;;
13976 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13978 freebsd)
13979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13980 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13981 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13982 $as_echo_n "(cached) " >&6
13983 else
13984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13985 /* end confdefs.h. */
13986 #include <osreldate.h>
13988 main ()
13990 #if __FreeBSD_version < 400000
13991 fail;
13992 #endif
13995 return 0;
13997 _ACEOF
13998 if ac_fn_c_try_link "$LINENO"; then :
13999 emacs_cv_freebsd_terminfo=yes
14000 else
14001 emacs_cv_freebsd_terminfo=no
14003 rm -f core conftest.err conftest.$ac_objext \
14004 conftest$ac_exeext conftest.$ac_ext
14008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
14009 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
14011 if test $emacs_cv_freebsd_terminfo = yes; then
14012 LIBS_TERMCAP="-lncurses"
14013 else
14014 TERMINFO=no
14015 LIBS_TERMCAP="-ltermcap"
14019 netbsd)
14020 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
14021 TERMINFO=no
14022 LIBS_TERMCAP="-ltermcap"
14026 openbsd) LIBS_TERMCAP="-lncurses" ;;
14028 ## hpux: Make sure we get select from libc rather than from libcurses
14029 ## because libcurses on HPUX 10.10 has a broken version of select.
14030 ## We used to use -lc -lcurses, but this may be cleaner.
14031 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
14032 # set that way, now it uses the default). Isn't this a contradiction?
14033 hpux*) LIBS_TERMCAP="-ltermcap" ;;
14035 esac
14037 TERMCAP_OBJ=tparam.o
14038 if test $TERMINFO = yes; then
14040 $as_echo "#define TERMINFO 1" >>confdefs.h
14042 TERMCAP_OBJ=terminfo.o
14048 # Do we have res_init, for detecting changes in /etc/resolv.conf?
14049 # On Darwin, res_init appears not to be useful: see bug#562 and
14050 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
14051 resolv=no
14053 if test $opsys != darwin; then
14055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14056 /* end confdefs.h. */
14057 #include <netinet/in.h>
14058 #include <arpa/nameser.h>
14059 #include <resolv.h>
14061 main ()
14063 return res_init();
14065 return 0;
14067 _ACEOF
14068 if ac_fn_c_try_link "$LINENO"; then :
14069 have_res_init=yes
14070 else
14071 have_res_init=no
14073 rm -f core conftest.err conftest.$ac_objext \
14074 conftest$ac_exeext conftest.$ac_ext
14075 if test "$have_res_init" = no; then
14076 OLIBS="$LIBS"
14077 LIBS="$LIBS -lresolv"
14078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
14079 $as_echo_n "checking for res_init with -lresolv... " >&6; }
14080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14081 /* end confdefs.h. */
14082 #include <netinet/in.h>
14083 #include <arpa/nameser.h>
14084 #include <resolv.h>
14086 main ()
14088 return res_init();
14090 return 0;
14092 _ACEOF
14093 if ac_fn_c_try_link "$LINENO"; then :
14094 have_res_init=yes
14095 else
14096 have_res_init=no
14098 rm -f core conftest.err conftest.$ac_objext \
14099 conftest$ac_exeext conftest.$ac_ext
14100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
14101 $as_echo "$have_res_init" >&6; }
14102 if test "$have_res_init" = yes ; then
14103 resolv=yes
14105 LIBS="$OLIBS"
14108 if test "$have_res_init" = yes; then
14110 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
14114 # Do we need the Hesiod library to provide the support routines?
14115 LIBHESIOD=
14116 if test "$with_hesiod" != no ; then
14117 # Don't set $LIBS here -- see comments above. FIXME which comments?
14118 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
14119 if test "x$ac_cv_func_res_send" = x""yes; then :
14121 else
14122 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
14123 if test "x$ac_cv_func___res_send" = x""yes; then :
14125 else
14126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
14127 $as_echo_n "checking for res_send in -lresolv... " >&6; }
14128 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
14129 $as_echo_n "(cached) " >&6
14130 else
14131 ac_check_lib_save_LIBS=$LIBS
14132 LIBS="-lresolv $LIBS"
14133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14134 /* end confdefs.h. */
14136 /* Override any GCC internal prototype to avoid an error.
14137 Use char because int might match the return type of a GCC
14138 builtin and then its argument prototype would still apply. */
14139 #ifdef __cplusplus
14140 extern "C"
14141 #endif
14142 char res_send ();
14144 main ()
14146 return res_send ();
14148 return 0;
14150 _ACEOF
14151 if ac_fn_c_try_link "$LINENO"; then :
14152 ac_cv_lib_resolv_res_send=yes
14153 else
14154 ac_cv_lib_resolv_res_send=no
14156 rm -f core conftest.err conftest.$ac_objext \
14157 conftest$ac_exeext conftest.$ac_ext
14158 LIBS=$ac_check_lib_save_LIBS
14160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
14161 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
14162 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
14163 resolv=yes
14164 else
14165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
14166 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
14167 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
14168 $as_echo_n "(cached) " >&6
14169 else
14170 ac_check_lib_save_LIBS=$LIBS
14171 LIBS="-lresolv $LIBS"
14172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14173 /* end confdefs.h. */
14175 /* Override any GCC internal prototype to avoid an error.
14176 Use char because int might match the return type of a GCC
14177 builtin and then its argument prototype would still apply. */
14178 #ifdef __cplusplus
14179 extern "C"
14180 #endif
14181 char __res_send ();
14183 main ()
14185 return __res_send ();
14187 return 0;
14189 _ACEOF
14190 if ac_fn_c_try_link "$LINENO"; then :
14191 ac_cv_lib_resolv___res_send=yes
14192 else
14193 ac_cv_lib_resolv___res_send=no
14195 rm -f core conftest.err conftest.$ac_objext \
14196 conftest$ac_exeext conftest.$ac_ext
14197 LIBS=$ac_check_lib_save_LIBS
14199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
14200 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
14201 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
14202 resolv=yes
14211 if test "$resolv" = yes ; then
14212 RESOLVLIB=-lresolv
14213 else
14214 RESOLVLIB=
14216 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
14217 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
14219 else
14220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
14221 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
14222 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
14223 $as_echo_n "(cached) " >&6
14224 else
14225 ac_check_lib_save_LIBS=$LIBS
14226 LIBS="-lhesiod $RESOLVLIB $LIBS"
14227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14228 /* end confdefs.h. */
14230 /* Override any GCC internal prototype to avoid an error.
14231 Use char because int might match the return type of a GCC
14232 builtin and then its argument prototype would still apply. */
14233 #ifdef __cplusplus
14234 extern "C"
14235 #endif
14236 char hes_getmailhost ();
14238 main ()
14240 return hes_getmailhost ();
14242 return 0;
14244 _ACEOF
14245 if ac_fn_c_try_link "$LINENO"; then :
14246 ac_cv_lib_hesiod_hes_getmailhost=yes
14247 else
14248 ac_cv_lib_hesiod_hes_getmailhost=no
14250 rm -f core conftest.err conftest.$ac_objext \
14251 conftest$ac_exeext conftest.$ac_ext
14252 LIBS=$ac_check_lib_save_LIBS
14254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
14255 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
14256 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
14257 hesiod=yes
14258 else
14265 if test x"$hesiod" = xyes; then
14267 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14269 LIBHESIOD=-lhesiod
14274 # Do we need libresolv (due to res_init or Hesiod)?
14275 if test "$resolv" = yes && test $opsys != darwin; then
14277 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14279 LIBRESOLV=-lresolv
14280 else
14281 LIBRESOLV=
14285 # These tell us which Kerberos-related libraries to use.
14286 COM_ERRLIB=
14287 CRYPTOLIB=
14288 KRB5LIB=
14289 DESLIB=
14290 KRB4LIB=
14292 if test "${with_kerberos}" != no; then
14293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14294 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
14295 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
14296 $as_echo_n "(cached) " >&6
14297 else
14298 ac_check_lib_save_LIBS=$LIBS
14299 LIBS="-lcom_err $LIBS"
14300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14301 /* end confdefs.h. */
14303 /* Override any GCC internal prototype to avoid an error.
14304 Use char because int might match the return type of a GCC
14305 builtin and then its argument prototype would still apply. */
14306 #ifdef __cplusplus
14307 extern "C"
14308 #endif
14309 char com_err ();
14311 main ()
14313 return com_err ();
14315 return 0;
14317 _ACEOF
14318 if ac_fn_c_try_link "$LINENO"; then :
14319 ac_cv_lib_com_err_com_err=yes
14320 else
14321 ac_cv_lib_com_err_com_err=no
14323 rm -f core conftest.err conftest.$ac_objext \
14324 conftest$ac_exeext conftest.$ac_ext
14325 LIBS=$ac_check_lib_save_LIBS
14327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14328 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
14329 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
14330 have_com_err=yes
14331 else
14332 have_com_err=no
14335 if test $have_com_err = yes; then
14336 COM_ERRLIB=-lcom_err
14337 LIBS="$COM_ERRLIB $LIBS"
14339 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
14342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14343 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
14344 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
14345 $as_echo_n "(cached) " >&6
14346 else
14347 ac_check_lib_save_LIBS=$LIBS
14348 LIBS="-lcrypto $LIBS"
14349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14350 /* end confdefs.h. */
14352 /* Override any GCC internal prototype to avoid an error.
14353 Use char because int might match the return type of a GCC
14354 builtin and then its argument prototype would still apply. */
14355 #ifdef __cplusplus
14356 extern "C"
14357 #endif
14358 char mit_des_cbc_encrypt ();
14360 main ()
14362 return mit_des_cbc_encrypt ();
14364 return 0;
14366 _ACEOF
14367 if ac_fn_c_try_link "$LINENO"; then :
14368 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14369 else
14370 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14372 rm -f core conftest.err conftest.$ac_objext \
14373 conftest$ac_exeext conftest.$ac_ext
14374 LIBS=$ac_check_lib_save_LIBS
14376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14377 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
14378 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
14379 have_crypto=yes
14380 else
14381 have_crypto=no
14384 if test $have_crypto = yes; then
14385 CRYPTOLIB=-lcrypto
14386 LIBS="$CRYPTOLIB $LIBS"
14388 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
14391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14392 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
14393 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
14394 $as_echo_n "(cached) " >&6
14395 else
14396 ac_check_lib_save_LIBS=$LIBS
14397 LIBS="-lk5crypto $LIBS"
14398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14399 /* end confdefs.h. */
14401 /* Override any GCC internal prototype to avoid an error.
14402 Use char because int might match the return type of a GCC
14403 builtin and then its argument prototype would still apply. */
14404 #ifdef __cplusplus
14405 extern "C"
14406 #endif
14407 char mit_des_cbc_encrypt ();
14409 main ()
14411 return mit_des_cbc_encrypt ();
14413 return 0;
14415 _ACEOF
14416 if ac_fn_c_try_link "$LINENO"; then :
14417 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14418 else
14419 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14421 rm -f core conftest.err conftest.$ac_objext \
14422 conftest$ac_exeext conftest.$ac_ext
14423 LIBS=$ac_check_lib_save_LIBS
14425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14426 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
14427 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
14428 have_k5crypto=yes
14429 else
14430 have_k5crypto=no
14433 if test $have_k5crypto = yes; then
14434 CRYPTOLIB=-lk5crypto
14435 LIBS="$CRYPTOLIB $LIBS"
14437 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14441 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14442 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14443 $as_echo_n "(cached) " >&6
14444 else
14445 ac_check_lib_save_LIBS=$LIBS
14446 LIBS="-lkrb5 $LIBS"
14447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14448 /* end confdefs.h. */
14450 /* Override any GCC internal prototype to avoid an error.
14451 Use char because int might match the return type of a GCC
14452 builtin and then its argument prototype would still apply. */
14453 #ifdef __cplusplus
14454 extern "C"
14455 #endif
14456 char krb5_init_context ();
14458 main ()
14460 return krb5_init_context ();
14462 return 0;
14464 _ACEOF
14465 if ac_fn_c_try_link "$LINENO"; then :
14466 ac_cv_lib_krb5_krb5_init_context=yes
14467 else
14468 ac_cv_lib_krb5_krb5_init_context=no
14470 rm -f core conftest.err conftest.$ac_objext \
14471 conftest$ac_exeext conftest.$ac_ext
14472 LIBS=$ac_check_lib_save_LIBS
14474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14475 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14476 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14477 have_krb5=yes
14478 else
14479 have_krb5=no
14482 if test $have_krb5=yes; then
14483 KRB5LIB=-lkrb5
14484 LIBS="$KRB5LIB $LIBS"
14486 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14489 if test "${with_kerberos5}" = no; then
14490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14491 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14492 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14493 $as_echo_n "(cached) " >&6
14494 else
14495 ac_check_lib_save_LIBS=$LIBS
14496 LIBS="-ldes425 $LIBS"
14497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14498 /* end confdefs.h. */
14500 /* Override any GCC internal prototype to avoid an error.
14501 Use char because int might match the return type of a GCC
14502 builtin and then its argument prototype would still apply. */
14503 #ifdef __cplusplus
14504 extern "C"
14505 #endif
14506 char des_cbc_encrypt ();
14508 main ()
14510 return des_cbc_encrypt ();
14512 return 0;
14514 _ACEOF
14515 if ac_fn_c_try_link "$LINENO"; then :
14516 ac_cv_lib_des425_des_cbc_encrypt=yes
14517 else
14518 ac_cv_lib_des425_des_cbc_encrypt=no
14520 rm -f core conftest.err conftest.$ac_objext \
14521 conftest$ac_exeext conftest.$ac_ext
14522 LIBS=$ac_check_lib_save_LIBS
14524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14525 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14526 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14527 have_des425=yes
14528 else
14529 have_des425=no
14532 if test $have_des425 = yes; then
14533 DESLIB=-ldes425
14534 LIBS="$DESLIB $LIBS"
14536 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14538 else
14539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14540 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14541 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14542 $as_echo_n "(cached) " >&6
14543 else
14544 ac_check_lib_save_LIBS=$LIBS
14545 LIBS="-ldes $LIBS"
14546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14547 /* end confdefs.h. */
14549 /* Override any GCC internal prototype to avoid an error.
14550 Use char because int might match the return type of a GCC
14551 builtin and then its argument prototype would still apply. */
14552 #ifdef __cplusplus
14553 extern "C"
14554 #endif
14555 char des_cbc_encrypt ();
14557 main ()
14559 return des_cbc_encrypt ();
14561 return 0;
14563 _ACEOF
14564 if ac_fn_c_try_link "$LINENO"; then :
14565 ac_cv_lib_des_des_cbc_encrypt=yes
14566 else
14567 ac_cv_lib_des_des_cbc_encrypt=no
14569 rm -f core conftest.err conftest.$ac_objext \
14570 conftest$ac_exeext conftest.$ac_ext
14571 LIBS=$ac_check_lib_save_LIBS
14573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14574 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14575 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14576 have_des=yes
14577 else
14578 have_des=no
14581 if test $have_des = yes; then
14582 DESLIB=-ldes
14583 LIBS="$DESLIB $LIBS"
14585 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14590 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14591 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14592 $as_echo_n "(cached) " >&6
14593 else
14594 ac_check_lib_save_LIBS=$LIBS
14595 LIBS="-lkrb4 $LIBS"
14596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14597 /* end confdefs.h. */
14599 /* Override any GCC internal prototype to avoid an error.
14600 Use char because int might match the return type of a GCC
14601 builtin and then its argument prototype would still apply. */
14602 #ifdef __cplusplus
14603 extern "C"
14604 #endif
14605 char krb_get_cred ();
14607 main ()
14609 return krb_get_cred ();
14611 return 0;
14613 _ACEOF
14614 if ac_fn_c_try_link "$LINENO"; then :
14615 ac_cv_lib_krb4_krb_get_cred=yes
14616 else
14617 ac_cv_lib_krb4_krb_get_cred=no
14619 rm -f core conftest.err conftest.$ac_objext \
14620 conftest$ac_exeext conftest.$ac_ext
14621 LIBS=$ac_check_lib_save_LIBS
14623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14624 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14625 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14626 have_krb4=yes
14627 else
14628 have_krb4=no
14631 if test $have_krb4 = yes; then
14632 KRB4LIB=-lkrb4
14633 LIBS="$KRB4LIB $LIBS"
14635 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14637 else
14638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14639 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14640 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14641 $as_echo_n "(cached) " >&6
14642 else
14643 ac_check_lib_save_LIBS=$LIBS
14644 LIBS="-lkrb $LIBS"
14645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14646 /* end confdefs.h. */
14648 /* Override any GCC internal prototype to avoid an error.
14649 Use char because int might match the return type of a GCC
14650 builtin and then its argument prototype would still apply. */
14651 #ifdef __cplusplus
14652 extern "C"
14653 #endif
14654 char krb_get_cred ();
14656 main ()
14658 return krb_get_cred ();
14660 return 0;
14662 _ACEOF
14663 if ac_fn_c_try_link "$LINENO"; then :
14664 ac_cv_lib_krb_krb_get_cred=yes
14665 else
14666 ac_cv_lib_krb_krb_get_cred=no
14668 rm -f core conftest.err conftest.$ac_objext \
14669 conftest$ac_exeext conftest.$ac_ext
14670 LIBS=$ac_check_lib_save_LIBS
14672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14673 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14674 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14675 have_krb=yes
14676 else
14677 have_krb=no
14680 if test $have_krb = yes; then
14681 KRB4LIB=-lkrb
14682 LIBS="$KRB4LIB $LIBS"
14684 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14690 if test "${with_kerberos5}" != no; then
14691 for ac_header in krb5.h
14692 do :
14693 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14694 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14695 cat >>confdefs.h <<_ACEOF
14696 #define HAVE_KRB5_H 1
14697 _ACEOF
14698 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14700 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14702 cat >>confdefs.h <<_ACEOF
14703 #define HAVE_KRB5_ERROR_TEXT 1
14704 _ACEOF
14708 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14710 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14712 cat >>confdefs.h <<_ACEOF
14713 #define HAVE_KRB5_ERROR_E_TEXT 1
14714 _ACEOF
14721 done
14723 else
14724 for ac_header in des.h
14725 do :
14726 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14727 if test "x$ac_cv_header_des_h" = x""yes; then :
14728 cat >>confdefs.h <<_ACEOF
14729 #define HAVE_DES_H 1
14730 _ACEOF
14732 else
14733 for ac_header in kerberosIV/des.h
14734 do :
14735 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14736 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14737 cat >>confdefs.h <<_ACEOF
14738 #define HAVE_KERBEROSIV_DES_H 1
14739 _ACEOF
14741 else
14742 for ac_header in kerberos/des.h
14743 do :
14744 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14745 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14746 cat >>confdefs.h <<_ACEOF
14747 #define HAVE_KERBEROS_DES_H 1
14748 _ACEOF
14752 done
14756 done
14760 done
14762 for ac_header in krb.h
14763 do :
14764 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14765 if test "x$ac_cv_header_krb_h" = x""yes; then :
14766 cat >>confdefs.h <<_ACEOF
14767 #define HAVE_KRB_H 1
14768 _ACEOF
14770 else
14771 for ac_header in kerberosIV/krb.h
14772 do :
14773 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14774 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14775 cat >>confdefs.h <<_ACEOF
14776 #define HAVE_KERBEROSIV_KRB_H 1
14777 _ACEOF
14779 else
14780 for ac_header in kerberos/krb.h
14781 do :
14782 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14783 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14784 cat >>confdefs.h <<_ACEOF
14785 #define HAVE_KERBEROS_KRB_H 1
14786 _ACEOF
14790 done
14794 done
14798 done
14801 for ac_header in com_err.h
14802 do :
14803 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14804 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14805 cat >>confdefs.h <<_ACEOF
14806 #define HAVE_COM_ERR_H 1
14807 _ACEOF
14811 done
14824 for ac_func in $ac_func_list
14825 do :
14826 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14827 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14828 eval as_val=\$$as_ac_var
14829 if test "x$as_val" = x""yes; then :
14830 cat >>confdefs.h <<_ACEOF
14831 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14832 _ACEOF
14835 done
14840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14841 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14842 if test "${emacs_cv_localtime_cache+set}" = set; then :
14843 $as_echo_n "(cached) " >&6
14844 else
14845 if test x$ac_cv_func_tzset = xyes; then
14846 if test "$cross_compiling" = yes; then :
14847 # If we have tzset, assume the worst when cross-compiling.
14848 emacs_cv_localtime_cache=yes
14849 else
14850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14851 /* end confdefs.h. */
14852 #include <time.h>
14853 char TZ_GMT0[] = "TZ=GMT0";
14854 char TZ_PST8[] = "TZ=PST8";
14855 main()
14857 time_t now = time ((time_t *) 0);
14858 int hour_GMT0, hour_unset;
14859 if (putenv (TZ_GMT0) != 0)
14860 exit (1);
14861 hour_GMT0 = localtime (&now)->tm_hour;
14862 unsetenv("TZ");
14863 hour_unset = localtime (&now)->tm_hour;
14864 if (putenv (TZ_PST8) != 0)
14865 exit (1);
14866 if (localtime (&now)->tm_hour == hour_GMT0)
14867 exit (1);
14868 unsetenv("TZ");
14869 if (localtime (&now)->tm_hour != hour_unset)
14870 exit (1);
14871 exit (0);
14873 _ACEOF
14874 if ac_fn_c_try_run "$LINENO"; then :
14875 emacs_cv_localtime_cache=no
14876 else
14877 emacs_cv_localtime_cache=yes
14879 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14880 conftest.$ac_objext conftest.beam conftest.$ac_ext
14883 else
14884 # If we lack tzset, report that localtime does not cache TZ,
14885 # since we can't invalidate the cache if we don't have tzset.
14886 emacs_cv_localtime_cache=no
14889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14890 $as_echo "$emacs_cv_localtime_cache" >&6; }
14891 if test $emacs_cv_localtime_cache = yes; then
14893 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14897 ok_so_far=yes
14898 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14899 if test "x$ac_cv_func_socket" = x""yes; then :
14901 else
14902 ok_so_far=no
14905 if test $ok_so_far = yes; then
14906 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14907 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14909 else
14910 ok_so_far=no
14915 if test $ok_so_far = yes; then
14916 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14917 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14919 else
14920 ok_so_far=no
14925 if test $ok_so_far = yes; then
14927 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14931 if test -f /usr/lpp/X11/bin/smt.exp; then
14933 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14938 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14939 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14941 $as_echo "yes" >&6; }
14943 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14945 else
14946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14947 $as_echo "no" >&6; }
14950 case $canonical in
14951 *-solaris2.4 | *-solaris2.4.*)
14952 : ${ac_cv_func_vfork_works=no};;
14953 esac
14955 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14956 if test "x$ac_cv_type_pid_t" = x""yes; then :
14958 else
14960 cat >>confdefs.h <<_ACEOF
14961 #define pid_t int
14962 _ACEOF
14966 for ac_header in vfork.h
14967 do :
14968 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14969 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14970 cat >>confdefs.h <<_ACEOF
14971 #define HAVE_VFORK_H 1
14972 _ACEOF
14976 done
14978 for ac_func in fork vfork
14979 do :
14980 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14981 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14982 eval as_val=\$$as_ac_var
14983 if test "x$as_val" = x""yes; then :
14984 cat >>confdefs.h <<_ACEOF
14985 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14986 _ACEOF
14989 done
14991 if test "x$ac_cv_func_fork" = xyes; then
14992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14993 $as_echo_n "checking for working fork... " >&6; }
14994 if test "${ac_cv_func_fork_works+set}" = set; then :
14995 $as_echo_n "(cached) " >&6
14996 else
14997 if test "$cross_compiling" = yes; then :
14998 ac_cv_func_fork_works=cross
14999 else
15000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15001 /* end confdefs.h. */
15002 $ac_includes_default
15004 main ()
15007 /* By Ruediger Kuhlmann. */
15008 return fork () < 0;
15011 return 0;
15013 _ACEOF
15014 if ac_fn_c_try_run "$LINENO"; then :
15015 ac_cv_func_fork_works=yes
15016 else
15017 ac_cv_func_fork_works=no
15019 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15020 conftest.$ac_objext conftest.beam conftest.$ac_ext
15024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15025 $as_echo "$ac_cv_func_fork_works" >&6; }
15027 else
15028 ac_cv_func_fork_works=$ac_cv_func_fork
15030 if test "x$ac_cv_func_fork_works" = xcross; then
15031 case $host in
15032 *-*-amigaos* | *-*-msdosdjgpp*)
15033 # Override, as these systems have only a dummy fork() stub
15034 ac_cv_func_fork_works=no
15037 ac_cv_func_fork_works=yes
15039 esac
15040 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15041 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15043 ac_cv_func_vfork_works=$ac_cv_func_vfork
15044 if test "x$ac_cv_func_vfork" = xyes; then
15045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15046 $as_echo_n "checking for working vfork... " >&6; }
15047 if test "${ac_cv_func_vfork_works+set}" = set; then :
15048 $as_echo_n "(cached) " >&6
15049 else
15050 if test "$cross_compiling" = yes; then :
15051 ac_cv_func_vfork_works=cross
15052 else
15053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15054 /* end confdefs.h. */
15055 /* Thanks to Paul Eggert for this test. */
15056 $ac_includes_default
15057 #include <sys/wait.h>
15058 #ifdef HAVE_VFORK_H
15059 # include <vfork.h>
15060 #endif
15061 /* On some sparc systems, changes by the child to local and incoming
15062 argument registers are propagated back to the parent. The compiler
15063 is told about this with #include <vfork.h>, but some compilers
15064 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15065 static variable whose address is put into a register that is
15066 clobbered by the vfork. */
15067 static void
15068 #ifdef __cplusplus
15069 sparc_address_test (int arg)
15070 # else
15071 sparc_address_test (arg) int arg;
15072 #endif
15074 static pid_t child;
15075 if (!child) {
15076 child = vfork ();
15077 if (child < 0) {
15078 perror ("vfork");
15079 _exit(2);
15081 if (!child) {
15082 arg = getpid();
15083 write(-1, "", 0);
15084 _exit (arg);
15090 main ()
15092 pid_t parent = getpid ();
15093 pid_t child;
15095 sparc_address_test (0);
15097 child = vfork ();
15099 if (child == 0) {
15100 /* Here is another test for sparc vfork register problems. This
15101 test uses lots of local variables, at least as many local
15102 variables as main has allocated so far including compiler
15103 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
15104 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
15105 reuse the register of parent for one of the local variables,
15106 since it will think that parent can't possibly be used any more
15107 in this routine. Assigning to the local variable will thus
15108 munge parent in the parent process. */
15109 pid_t
15110 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15111 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15112 /* Convince the compiler that p..p7 are live; otherwise, it might
15113 use the same hardware register for all 8 local variables. */
15114 if (p != p1 || p != p2 || p != p3 || p != p4
15115 || p != p5 || p != p6 || p != p7)
15116 _exit(1);
15118 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15119 from child file descriptors. If the child closes a descriptor
15120 before it execs or exits, this munges the parent's descriptor
15121 as well. Test for this by closing stdout in the child. */
15122 _exit(close(fileno(stdout)) != 0);
15123 } else {
15124 int status;
15125 struct stat st;
15127 while (wait(&status) != child)
15129 return (
15130 /* Was there some problem with vforking? */
15131 child < 0
15133 /* Did the child fail? (This shouldn't happen.) */
15134 || status
15136 /* Did the vfork/compiler bug occur? */
15137 || parent != getpid()
15139 /* Did the file descriptor bug occur? */
15140 || fstat(fileno(stdout), &st) != 0
15144 _ACEOF
15145 if ac_fn_c_try_run "$LINENO"; then :
15146 ac_cv_func_vfork_works=yes
15147 else
15148 ac_cv_func_vfork_works=no
15150 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15151 conftest.$ac_objext conftest.beam conftest.$ac_ext
15155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15156 $as_echo "$ac_cv_func_vfork_works" >&6; }
15159 if test "x$ac_cv_func_fork_works" = xcross; then
15160 ac_cv_func_vfork_works=$ac_cv_func_vfork
15161 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15162 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15165 if test "x$ac_cv_func_vfork_works" = xyes; then
15167 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15169 else
15171 $as_echo "#define vfork fork" >>confdefs.h
15174 if test "x$ac_cv_func_fork_works" = xyes; then
15176 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15181 for ac_func in snprintf
15182 do :
15183 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
15184 if test "x$ac_cv_func_snprintf" = x""yes; then :
15185 cat >>confdefs.h <<_ACEOF
15186 #define HAVE_SNPRINTF 1
15187 _ACEOF
15190 done
15193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
15194 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
15195 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
15196 $as_echo_n "(cached) " >&6
15197 else
15198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15199 /* end confdefs.h. */
15200 #include <langinfo.h>
15202 main ()
15204 char* cs = nl_langinfo(CODESET);
15206 return 0;
15208 _ACEOF
15209 if ac_fn_c_try_link "$LINENO"; then :
15210 emacs_cv_langinfo_codeset=yes
15211 else
15212 emacs_cv_langinfo_codeset=no
15214 rm -f core conftest.err conftest.$ac_objext \
15215 conftest$ac_exeext conftest.$ac_ext
15218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
15219 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
15220 if test $emacs_cv_langinfo_codeset = yes; then
15222 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
15226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
15227 $as_echo_n "checking for mbstate_t... " >&6; }
15228 if test "${ac_cv_type_mbstate_t+set}" = set; then :
15229 $as_echo_n "(cached) " >&6
15230 else
15231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15232 /* end confdefs.h. */
15233 $ac_includes_default
15234 # include <wchar.h>
15236 main ()
15238 mbstate_t x; return sizeof x;
15240 return 0;
15242 _ACEOF
15243 if ac_fn_c_try_compile "$LINENO"; then :
15244 ac_cv_type_mbstate_t=yes
15245 else
15246 ac_cv_type_mbstate_t=no
15248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
15251 $as_echo "$ac_cv_type_mbstate_t" >&6; }
15252 if test $ac_cv_type_mbstate_t = yes; then
15254 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
15256 else
15258 $as_echo "#define mbstate_t int" >>confdefs.h
15262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15263 $as_echo_n "checking for C restricted array declarations... " >&6; }
15264 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
15265 $as_echo_n "(cached) " >&6
15266 else
15267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15268 /* end confdefs.h. */
15269 void fred (int x[__restrict]);
15271 main ()
15275 return 0;
15277 _ACEOF
15278 if ac_fn_c_try_compile "$LINENO"; then :
15279 emacs_cv_c_restrict_arr=yes
15280 else
15281 emacs_cv_c_restrict_arr=no
15283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15286 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
15287 if test "$emacs_cv_c_restrict_arr" = yes; then
15289 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
15295 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
15299 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
15302 ## Note: PTYs are broken on darwin <6. Use at your own risk.
15304 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
15308 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
15314 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
15318 $as_echo "#define SEPCHAR ':'" >>confdefs.h
15322 $as_echo "#define subprocesses 1" >>confdefs.h
15326 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
15331 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
15337 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
15341 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
15345 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
15351 case $opsys in
15352 aix4-2)
15353 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
15354 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15359 hpux*)
15360 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15363 esac
15366 case $opsys in
15367 irix6-5 | sol2* | unixware )
15369 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
15372 esac
15374 emacs_broken_SIGIO=no
15376 case $opsys in
15377 hpux* | irix6-5 | openbsd | sol2* | unixware )
15378 emacs_broken_SIGIO=yes
15381 aix4-2)
15383 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
15387 freebsd)
15389 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
15392 esac
15394 case $opsys in
15395 gnu-* | sol2-10 )
15397 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
15400 esac
15402 case $opsys in
15403 darwin | freebsd | netbsd | openbsd )
15405 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
15408 esac
15410 case $opsys in
15411 netbsd | openbsd) sound_device="/dev/audio" ;;
15412 *) sound_device="/dev/dsp" ;;
15413 esac
15416 cat >>confdefs.h <<_ACEOF
15417 #define DEFAULT_SOUND_DEVICE "$sound_device"
15418 _ACEOF
15422 case $opsys in
15423 darwin | gnu-linux | gnu-kfreebsd )
15425 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
15428 esac
15431 case $opsys in
15432 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
15434 $as_echo "#define NARROWPROTO 1" >>confdefs.h
15437 esac
15446 case $opsys in
15447 aix4-2 )
15448 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
15450 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
15452 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
15456 cygwin )
15457 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15459 $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
15461 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15463 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15467 darwin )
15468 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15470 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15472 $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
15474 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15476 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15480 gnu | openbsd )
15481 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15485 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15486 if test "x$ac_cv_func_grantpt" = xyes; then
15488 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15490 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15492 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15494 if test "x$ac_cv_func_posix_openpt" = xyes; then
15495 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15497 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15499 elif test "x$ac_cv_func_getpt" = xyes; then
15500 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15502 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15504 else
15505 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15508 else
15509 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15514 hpux*)
15515 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15517 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15519 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15523 irix6-5 )
15524 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15526 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15528 $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
15530 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15532 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15536 sol2* )
15537 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15541 unixware )
15542 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15545 esac
15548 case $opsys in
15549 sol2* | unixware )
15550 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15552 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15555 $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
15558 esac
15563 case $opsys in
15564 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15565 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15569 gnu-linux | gnu-kfreebsd )
15571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15572 $as_echo_n "checking for signals via characters... " >&6; }
15573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15574 /* end confdefs.h. */
15576 #include <linux/version.h>
15577 #if LINUX_VERSION_CODE < 0x20400
15578 # error "Linux version too old"
15579 #endif
15582 main ()
15586 return 0;
15588 _ACEOF
15589 if ac_fn_c_try_cpp "$LINENO"; then :
15590 emacs_signals_via_chars=yes
15591 else
15592 emacs_signals_via_chars=no
15594 rm -f conftest.err conftest.$ac_ext
15596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15597 $as_echo "$emacs_signals_via_chars" >&6; }
15598 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15601 esac
15607 case $opsys in
15608 gnu)
15609 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15613 hpux*)
15614 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15616 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15619 irix6-5)
15620 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15622 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15625 esac
15630 case $opsys in
15631 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15634 gnu | freebsd | netbsd | openbsd )
15636 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15638 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15642 gnu-linux | gnu-kfreebsd )
15643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15644 /* end confdefs.h. */
15646 #ifndef __ia64__
15647 # error "not ia64"
15648 #endif
15651 main ()
15655 return 0;
15657 _ACEOF
15658 if ac_fn_c_try_cpp "$LINENO"; then :
15660 $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
15663 rm -f conftest.err conftest.$ac_ext
15666 hpux*)
15668 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15671 esac
15679 case $opsys in
15680 aix4-2 | hpux* | unixware)
15681 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15685 gnu-linux | gnu-kfreebsd )
15686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15687 /* end confdefs.h. */
15689 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15690 || defined __alpha__ || defined __mips__ || defined __s390__ \
15691 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15692 || defined __ia64__ || defined __sh__
15693 /* ok */
15694 #else
15695 # error "setjmp not known to work on this arch"
15696 #endif
15699 main ()
15703 return 0;
15705 _ACEOF
15706 if ac_fn_c_try_cpp "$LINENO"; then :
15707 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15709 else
15710 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15713 rm -f conftest.err conftest.$ac_ext
15715 esac
15718 if test x$GCC = xyes; then
15719 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15721 else
15722 case $opsys in
15723 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15724 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15727 esac
15729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15730 $as_echo_n "checking for _setjmp... " >&6; }
15731 if test "${emacs_cv_func__setjmp+set}" = set; then :
15732 $as_echo_n "(cached) " >&6
15733 else
15734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15735 /* end confdefs.h. */
15736 #include <setjmp.h>
15739 main ()
15741 jmp_buf j;
15742 if (! _setjmp (j))
15743 _longjmp (j, 1);
15745 return 0;
15747 _ACEOF
15748 if ac_fn_c_try_link "$LINENO"; then :
15749 emacs_cv_func__setjmp=yes
15750 else
15751 emacs_cv_func__setjmp=no
15753 rm -f core conftest.err conftest.$ac_objext \
15754 conftest$ac_exeext conftest.$ac_ext
15756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15757 $as_echo "$emacs_cv_func__setjmp" >&6; }
15758 if test $emacs_cv_func__setjmp = yes; then
15760 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
15762 else
15763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
15764 $as_echo_n "checking for sigsetjmp... " >&6; }
15765 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
15766 $as_echo_n "(cached) " >&6
15767 else
15768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15769 /* end confdefs.h. */
15770 #include <setjmp.h>
15773 main ()
15775 sigjmp_buf j;
15776 if (! sigsetjmp (j, 1))
15777 siglongjmp (j, 1);
15779 return 0;
15781 _ACEOF
15782 if ac_fn_c_try_link "$LINENO"; then :
15783 emacs_cv_func_sigsetjmp=yes
15784 else
15785 emacs_cv_func_sigsetjmp=no
15787 rm -f core conftest.err conftest.$ac_objext \
15788 conftest$ac_exeext conftest.$ac_ext
15790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
15791 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
15792 if test $emacs_cv_func_sigsetjmp = yes; then
15794 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
15799 case $opsys in
15800 sol2* | unixware )
15802 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15805 esac
15808 case $opsys in
15809 hpux* | sol2* )
15811 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15814 esac
15824 case $opsys in
15825 aix4-2)
15826 $as_echo "#define USG /**/" >>confdefs.h
15828 $as_echo "#define USG5 /**/" >>confdefs.h
15830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15831 /* end confdefs.h. */
15833 #ifndef _AIX
15834 # error "_AIX not defined"
15835 #endif
15838 main ()
15842 return 0;
15844 _ACEOF
15845 if ac_fn_c_try_cpp "$LINENO"; then :
15847 else
15849 $as_echo "#define _AIX /**/" >>confdefs.h
15852 rm -f conftest.err conftest.$ac_ext
15855 cygwin)
15857 $as_echo "#define CYGWIN 1" >>confdefs.h
15861 darwin)
15862 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15865 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15869 freebsd)
15871 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15875 gnu | netbsd | openbsd )
15876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15877 /* end confdefs.h. */
15879 #ifndef BSD_SYSTEM
15880 # error "BSD_SYSTEM not defined"
15881 #endif
15884 main ()
15888 return 0;
15890 _ACEOF
15891 if ac_fn_c_try_cpp "$LINENO"; then :
15893 else
15894 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15897 rm -f conftest.err conftest.$ac_ext
15900 gnu-linux | gnu-kfreebsd )
15901 $as_echo "#define USG /**/" >>confdefs.h
15904 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15908 hpux*)
15909 $as_echo "#define USG /**/" >>confdefs.h
15911 $as_echo "#define USG5 /**/" >>confdefs.h
15914 $as_echo "#define HPUX /**/" >>confdefs.h
15918 irix6-5)
15919 $as_echo "#define USG /**/" >>confdefs.h
15921 $as_echo "#define USG5 /**/" >>confdefs.h
15923 $as_echo "#define USG5_4 /**/" >>confdefs.h
15926 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15930 sol2*)
15931 $as_echo "#define USG /**/" >>confdefs.h
15933 $as_echo "#define USG5 /**/" >>confdefs.h
15935 $as_echo "#define USG5_4 /**/" >>confdefs.h
15938 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15942 unixware)
15943 $as_echo "#define USG /**/" >>confdefs.h
15945 $as_echo "#define USG5 /**/" >>confdefs.h
15947 $as_echo "#define USG5_4 /**/" >>confdefs.h
15950 esac
15952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
15953 $as_echo_n "checking for usable FIONREAD... " >&6; }
15954 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
15955 $as_echo_n "(cached) " >&6
15956 else
15957 case $opsys in
15958 aix4-2)
15959 emacs_cv_usable_FIONREAD=no
15963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15964 /* end confdefs.h. */
15965 #include <sys/types.h>
15966 #include <sys/ioctl.h>
15967 #ifdef USG5_4
15968 # include <sys/filio.h>
15969 #endif
15972 main ()
15974 int foo = ioctl (0, FIONREAD, &foo);
15976 return 0;
15978 _ACEOF
15979 if ac_fn_c_try_compile "$LINENO"; then :
15980 emacs_cv_usable_FIONREAD=yes
15981 else
15982 emacs_cv_usable_FIONREAD=no
15984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15986 esac
15988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
15989 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
15990 if test $emacs_cv_usable_FIONREAD = yes; then
15992 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
15995 if test $emacs_broken_SIGIO = no; then
15996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
15997 $as_echo_n "checking for usable SIGIO... " >&6; }
15998 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
15999 $as_echo_n "(cached) " >&6
16000 else
16001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16002 /* end confdefs.h. */
16003 #include <fcntl.h>
16004 #include <signal.h>
16007 main ()
16009 int foo = SIGIO | F_SETFL | FASYNC;
16011 return 0;
16013 _ACEOF
16014 if ac_fn_c_try_compile "$LINENO"; then :
16015 emacs_cv_usable_SIGIO=yes
16016 else
16017 emacs_cv_usable_SIGIO=no
16019 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
16022 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
16023 if test $emacs_cv_usable_SIGIO = yes; then
16025 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
16032 case $opsys in
16033 cygwin)
16035 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
16039 hpux11)
16041 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
16045 irix6-5)
16047 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
16051 sol2-10)
16053 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
16056 esac
16058 # Set up the CFLAGS for real compilation, so we can substitute it.
16059 CFLAGS="$REAL_CFLAGS"
16060 CPPFLAGS="$REAL_CPPFLAGS"
16062 ## Hack to detect a buggy GCC version.
16063 if test "x$GCC" = xyes \
16064 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
16065 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
16066 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
16067 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
16070 version=$PACKAGE_VERSION
16072 copyright="Copyright (C) 2012 Free Software Foundation, Inc."
16074 cat >>confdefs.h <<_ACEOF
16075 #define COPYRIGHT "$copyright"
16076 _ACEOF
16080 ### Specify what sort of things we'll be editing into Makefile and config.h.
16081 ### Use configuration here uncanonicalized to avoid exceeding size limits.
16084 ## Unused?
16107 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
16108 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
16109 ## end of LIBX_BASE, but nothing ever set it.
16114 ## Used in lwlib/Makefile.in.
16123 if test -n "${term_header}"; then
16125 cat >>confdefs.h <<_ACEOF
16126 #define TERM_HEADER "${term_header}"
16127 _ACEOF
16132 cat >>confdefs.h <<_ACEOF
16133 #define EMACS_CONFIGURATION "${canonical}"
16134 _ACEOF
16137 cat >>confdefs.h <<_ACEOF
16138 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
16139 _ACEOF
16143 XMENU_OBJ=
16144 XOBJ=
16145 FONT_OBJ=
16146 if test "${HAVE_X_WINDOWS}" = "yes" ; then
16148 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
16150 XMENU_OBJ=xmenu.o
16151 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
16152 FONT_OBJ=xfont.o
16153 if test "$HAVE_XFT" = "yes"; then
16154 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
16155 elif test "$HAVE_FREETYPE" = "yes"; then
16156 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
16164 WIDGET_OBJ=
16165 MOTIF_LIBW=
16166 if test "${USE_X_TOOLKIT}" != "none" ; then
16167 WIDGET_OBJ=widget.o
16169 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
16171 if test "${USE_X_TOOLKIT}" = "LUCID"; then
16173 $as_echo "#define USE_LUCID 1" >>confdefs.h
16175 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
16177 $as_echo "#define USE_MOTIF 1" >>confdefs.h
16179 MOTIF_LIBW=-lXm
16180 case "$opsys" in
16181 gnu-linux)
16182 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
16183 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
16186 unixware)
16187 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
16188 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
16189 MOTIF_LIBW="MOTIF_LIBW -lXimp"
16192 aix4-2)
16193 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
16194 MOTIF_LIBW="$MOTIF_LIBW -li18n"
16196 esac
16197 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
16202 TOOLKIT_LIBW=
16203 case "$USE_X_TOOLKIT" in
16204 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
16205 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
16206 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
16207 esac
16210 if test "$USE_X_TOOLKIT" = "none"; then
16211 LIBXT_OTHER="\$(LIBXSM)"
16212 OLDXMENU_TARGET="really-oldXMenu"
16213 else
16214 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
16215 OLDXMENU_TARGET="really-lwlib"
16219 ## The X Menu stuff is present in the X10 distribution, but missing
16220 ## from X11. If we have X10, just use the installed library;
16221 ## otherwise, use our own copy.
16222 if test "${HAVE_X11}" = "yes" ; then
16224 $as_echo "#define HAVE_X11 1" >>confdefs.h
16227 if test "$USE_X_TOOLKIT" = "none"; then
16228 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
16229 else
16230 OLDXMENU="\${lwlibdir}/liblw.a"
16232 LIBXMENU="\$(OLDXMENU)"
16233 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
16234 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
16235 else
16236 ## For a syntactically valid Makefile; not actually used for anything.
16237 ## See comments in src/Makefile.in.
16238 OLDXMENU=nothing
16239 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
16240 if test "${HAVE_X_WINDOWS}" = "yes"; then
16241 LIBXMENU="-lXMenu"
16242 else
16243 LIBXMENU=
16245 LIBX_OTHER=
16246 OLDXMENU_DEPS=
16249 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
16250 OLDXMENU_TARGET=
16251 OLDXMENU=nothing
16252 LIBXMENU=
16253 OLDXMENU_DEPS=
16262 if test "${HAVE_MENUS}" = "yes" ; then
16264 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
16268 if test "${GNU_MALLOC}" = "yes" ; then
16270 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
16274 RALLOC_OBJ=
16275 if test "${REL_ALLOC}" = "yes" ; then
16277 $as_echo "#define REL_ALLOC 1" >>confdefs.h
16280 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
16284 if test "$opsys" = "cygwin"; then
16285 CYGWIN_OBJ="sheap.o cygw32.o"
16286 ## Cygwin differs because of its unexec().
16287 PRE_ALLOC_OBJ=
16288 POST_ALLOC_OBJ=lastfile.o
16289 else
16290 CYGWIN_OBJ=
16291 PRE_ALLOC_OBJ=lastfile.o
16292 POST_ALLOC_OBJ=
16298 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
16299 # it temporarily reverts them to their pre-pkg-config values,
16300 # because gnulib needs to work with both src (which uses the
16301 # pkg-config stuff) and lib-src (which does not). For example, gnulib
16302 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
16303 # and it therefore needs to run in an environment where LIBS does not
16304 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
16305 # for some package unrelated to lib-src.
16306 SAVE_CFLAGS=$CFLAGS
16307 SAVE_LIBS=$LIBS
16308 CFLAGS=$pre_PKG_CONFIG_CFLAGS
16309 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
16321 LIBC_FATAL_STDERR_=1
16322 export LIBC_FATAL_STDERR_
16324 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
16325 # for constant arguments. Useless!
16326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
16327 $as_echo_n "checking for working alloca.h... " >&6; }
16328 if test "${ac_cv_working_alloca_h+set}" = set; then :
16329 $as_echo_n "(cached) " >&6
16330 else
16331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16332 /* end confdefs.h. */
16333 #include <alloca.h>
16335 main ()
16337 char *p = (char *) alloca (2 * sizeof (int));
16338 if (p) return 0;
16340 return 0;
16342 _ACEOF
16343 if ac_fn_c_try_link "$LINENO"; then :
16344 ac_cv_working_alloca_h=yes
16345 else
16346 ac_cv_working_alloca_h=no
16348 rm -f core conftest.err conftest.$ac_objext \
16349 conftest$ac_exeext conftest.$ac_ext
16351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16352 $as_echo "$ac_cv_working_alloca_h" >&6; }
16353 if test $ac_cv_working_alloca_h = yes; then
16355 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
16359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16360 $as_echo_n "checking for alloca... " >&6; }
16361 if test "${ac_cv_func_alloca_works+set}" = set; then :
16362 $as_echo_n "(cached) " >&6
16363 else
16364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16365 /* end confdefs.h. */
16366 #ifdef __GNUC__
16367 # define alloca __builtin_alloca
16368 #else
16369 # ifdef _MSC_VER
16370 # include <malloc.h>
16371 # define alloca _alloca
16372 # else
16373 # ifdef HAVE_ALLOCA_H
16374 # include <alloca.h>
16375 # else
16376 # ifdef _AIX
16377 #pragma alloca
16378 # else
16379 # ifndef alloca /* predefined by HP cc +Olibcalls */
16380 char *alloca ();
16381 # endif
16382 # endif
16383 # endif
16384 # endif
16385 #endif
16388 main ()
16390 char *p = (char *) alloca (1);
16391 if (p) return 0;
16393 return 0;
16395 _ACEOF
16396 if ac_fn_c_try_link "$LINENO"; then :
16397 ac_cv_func_alloca_works=yes
16398 else
16399 ac_cv_func_alloca_works=no
16401 rm -f core conftest.err conftest.$ac_objext \
16402 conftest$ac_exeext conftest.$ac_ext
16404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16405 $as_echo "$ac_cv_func_alloca_works" >&6; }
16407 if test $ac_cv_func_alloca_works = yes; then
16409 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16411 else
16412 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16413 # that cause trouble. Some versions do not even contain alloca or
16414 # contain a buggy version. If you still want to use their alloca,
16415 # use ar to extract alloca.o from them instead of compiling alloca.c.
16421 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16423 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16427 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16428 if test "${ac_cv_os_cray+set}" = set; then :
16429 $as_echo_n "(cached) " >&6
16430 else
16431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16432 /* end confdefs.h. */
16433 #if defined CRAY && ! defined CRAY2
16434 webecray
16435 #else
16436 wenotbecray
16437 #endif
16439 _ACEOF
16440 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16441 $EGREP "webecray" >/dev/null 2>&1; then :
16442 ac_cv_os_cray=yes
16443 else
16444 ac_cv_os_cray=no
16446 rm -f conftest*
16449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16450 $as_echo "$ac_cv_os_cray" >&6; }
16451 if test $ac_cv_os_cray = yes; then
16452 for ac_func in _getb67 GETB67 getb67; do
16453 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16454 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16455 eval as_val=\$$as_ac_var
16456 if test "x$as_val" = x""yes; then :
16458 cat >>confdefs.h <<_ACEOF
16459 #define CRAY_STACKSEG_END $ac_func
16460 _ACEOF
16462 break
16465 done
16468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16469 $as_echo_n "checking stack direction for C alloca... " >&6; }
16470 if test "${ac_cv_c_stack_direction+set}" = set; then :
16471 $as_echo_n "(cached) " >&6
16472 else
16473 if test "$cross_compiling" = yes; then :
16474 ac_cv_c_stack_direction=0
16475 else
16476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16477 /* end confdefs.h. */
16478 $ac_includes_default
16480 find_stack_direction (int *addr, int depth)
16482 int dir, dummy = 0;
16483 if (! addr)
16484 addr = &dummy;
16485 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16486 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16487 return dir + dummy;
16491 main (int argc, char **argv)
16493 return find_stack_direction (0, argc + !argv + 20) < 0;
16495 _ACEOF
16496 if ac_fn_c_try_run "$LINENO"; then :
16497 ac_cv_c_stack_direction=1
16498 else
16499 ac_cv_c_stack_direction=-1
16501 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16502 conftest.$ac_objext conftest.beam conftest.$ac_ext
16506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16507 $as_echo "$ac_cv_c_stack_direction" >&6; }
16508 cat >>confdefs.h <<_ACEOF
16509 #define STACK_DIRECTION $ac_cv_c_stack_direction
16510 _ACEOF
16518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16519 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16520 if test "${ac_cv_c_bigendian+set}" = set; then :
16521 $as_echo_n "(cached) " >&6
16522 else
16523 ac_cv_c_bigendian=unknown
16524 # See if we're dealing with a universal compiler.
16525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16526 /* end confdefs.h. */
16527 #ifndef __APPLE_CC__
16528 not a universal capable compiler
16529 #endif
16530 typedef int dummy;
16532 _ACEOF
16533 if ac_fn_c_try_compile "$LINENO"; then :
16535 # Check for potential -arch flags. It is not universal unless
16536 # there are at least two -arch flags with different values.
16537 ac_arch=
16538 ac_prev=
16539 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16540 if test -n "$ac_prev"; then
16541 case $ac_word in
16542 i?86 | x86_64 | ppc | ppc64)
16543 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16544 ac_arch=$ac_word
16545 else
16546 ac_cv_c_bigendian=universal
16547 break
16550 esac
16551 ac_prev=
16552 elif test "x$ac_word" = "x-arch"; then
16553 ac_prev=arch
16555 done
16557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16558 if test $ac_cv_c_bigendian = unknown; then
16559 # See if sys/param.h defines the BYTE_ORDER macro.
16560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16561 /* end confdefs.h. */
16562 #include <sys/types.h>
16563 #include <sys/param.h>
16566 main ()
16568 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16569 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16570 && LITTLE_ENDIAN)
16571 bogus endian macros
16572 #endif
16575 return 0;
16577 _ACEOF
16578 if ac_fn_c_try_compile "$LINENO"; then :
16579 # It does; now see whether it defined to BIG_ENDIAN or not.
16580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16581 /* end confdefs.h. */
16582 #include <sys/types.h>
16583 #include <sys/param.h>
16586 main ()
16588 #if BYTE_ORDER != BIG_ENDIAN
16589 not big endian
16590 #endif
16593 return 0;
16595 _ACEOF
16596 if ac_fn_c_try_compile "$LINENO"; then :
16597 ac_cv_c_bigendian=yes
16598 else
16599 ac_cv_c_bigendian=no
16601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16603 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16605 if test $ac_cv_c_bigendian = unknown; then
16606 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16608 /* end confdefs.h. */
16609 #include <limits.h>
16612 main ()
16614 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16615 bogus endian macros
16616 #endif
16619 return 0;
16621 _ACEOF
16622 if ac_fn_c_try_compile "$LINENO"; then :
16623 # It does; now see whether it defined to _BIG_ENDIAN or not.
16624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16625 /* end confdefs.h. */
16626 #include <limits.h>
16629 main ()
16631 #ifndef _BIG_ENDIAN
16632 not big endian
16633 #endif
16636 return 0;
16638 _ACEOF
16639 if ac_fn_c_try_compile "$LINENO"; then :
16640 ac_cv_c_bigendian=yes
16641 else
16642 ac_cv_c_bigendian=no
16644 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16646 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16648 if test $ac_cv_c_bigendian = unknown; then
16649 # Compile a test program.
16650 if test "$cross_compiling" = yes; then :
16651 # Try to guess by grepping values from an object file.
16652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16653 /* end confdefs.h. */
16654 short int ascii_mm[] =
16655 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16656 short int ascii_ii[] =
16657 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16658 int use_ascii (int i) {
16659 return ascii_mm[i] + ascii_ii[i];
16661 short int ebcdic_ii[] =
16662 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16663 short int ebcdic_mm[] =
16664 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16665 int use_ebcdic (int i) {
16666 return ebcdic_mm[i] + ebcdic_ii[i];
16668 extern int foo;
16671 main ()
16673 return use_ascii (foo) == use_ebcdic (foo);
16675 return 0;
16677 _ACEOF
16678 if ac_fn_c_try_compile "$LINENO"; then :
16679 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16680 ac_cv_c_bigendian=yes
16682 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16683 if test "$ac_cv_c_bigendian" = unknown; then
16684 ac_cv_c_bigendian=no
16685 else
16686 # finding both strings is unlikely to happen, but who knows?
16687 ac_cv_c_bigendian=unknown
16691 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16692 else
16693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16694 /* end confdefs.h. */
16695 $ac_includes_default
16697 main ()
16700 /* Are we little or big endian? From Harbison&Steele. */
16701 union
16703 long int l;
16704 char c[sizeof (long int)];
16705 } u;
16706 u.l = 1;
16707 return u.c[sizeof (long int) - 1] == 1;
16710 return 0;
16712 _ACEOF
16713 if ac_fn_c_try_run "$LINENO"; then :
16714 ac_cv_c_bigendian=no
16715 else
16716 ac_cv_c_bigendian=yes
16718 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16719 conftest.$ac_objext conftest.beam conftest.$ac_ext
16724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16725 $as_echo "$ac_cv_c_bigendian" >&6; }
16726 case $ac_cv_c_bigendian in #(
16727 yes)
16728 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16729 ;; #(
16731 ;; #(
16732 universal)
16734 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16736 ;; #(
16738 as_fn_error "unknown endianness
16739 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16740 esac
16744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16745 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16746 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16747 $as_echo_n "(cached) " >&6
16748 else
16749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16750 /* end confdefs.h. */
16751 /* On HP-UX before 11.23, strtold returns a struct instead of
16752 long double. Reject implementations like that, by requiring
16753 compatibility with the C99 prototype. */
16754 #include <stdlib.h>
16755 static long double (*p) (char const *, char **) = strtold;
16756 static long double
16757 test (char const *nptr, char **endptr)
16759 long double r;
16760 r = strtold (nptr, endptr);
16761 return r;
16764 main ()
16766 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16768 return 0;
16770 _ACEOF
16771 if ac_fn_c_try_link "$LINENO"; then :
16772 gl_cv_func_c99_strtold=yes
16773 else
16774 gl_cv_func_c99_strtold=no
16776 rm -f core conftest.err conftest.$ac_objext \
16777 conftest$ac_exeext conftest.$ac_ext
16779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16780 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16781 if test $gl_cv_func_c99_strtold = yes; then
16783 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16788 GNULIB_CHDIR=0;
16789 GNULIB_CHOWN=0;
16790 GNULIB_CLOSE=0;
16791 GNULIB_DUP=0;
16792 GNULIB_DUP2=0;
16793 GNULIB_DUP3=0;
16794 GNULIB_ENVIRON=0;
16795 GNULIB_EUIDACCESS=0;
16796 GNULIB_FACCESSAT=0;
16797 GNULIB_FCHDIR=0;
16798 GNULIB_FCHOWNAT=0;
16799 GNULIB_FDATASYNC=0;
16800 GNULIB_FSYNC=0;
16801 GNULIB_FTRUNCATE=0;
16802 GNULIB_GETCWD=0;
16803 GNULIB_GETDOMAINNAME=0;
16804 GNULIB_GETDTABLESIZE=0;
16805 GNULIB_GETGROUPS=0;
16806 GNULIB_GETHOSTNAME=0;
16807 GNULIB_GETLOGIN=0;
16808 GNULIB_GETLOGIN_R=0;
16809 GNULIB_GETPAGESIZE=0;
16810 GNULIB_GETUSERSHELL=0;
16811 GNULIB_GROUP_MEMBER=0;
16812 GNULIB_ISATTY=0;
16813 GNULIB_LCHOWN=0;
16814 GNULIB_LINK=0;
16815 GNULIB_LINKAT=0;
16816 GNULIB_LSEEK=0;
16817 GNULIB_PIPE=0;
16818 GNULIB_PIPE2=0;
16819 GNULIB_PREAD=0;
16820 GNULIB_PWRITE=0;
16821 GNULIB_READ=0;
16822 GNULIB_READLINK=0;
16823 GNULIB_READLINKAT=0;
16824 GNULIB_RMDIR=0;
16825 GNULIB_SETHOSTNAME=0;
16826 GNULIB_SLEEP=0;
16827 GNULIB_SYMLINK=0;
16828 GNULIB_SYMLINKAT=0;
16829 GNULIB_TTYNAME_R=0;
16830 GNULIB_UNISTD_H_NONBLOCKING=0;
16831 GNULIB_UNISTD_H_SIGPIPE=0;
16832 GNULIB_UNLINK=0;
16833 GNULIB_UNLINKAT=0;
16834 GNULIB_USLEEP=0;
16835 GNULIB_WRITE=0;
16836 HAVE_CHOWN=1;
16837 HAVE_DUP2=1;
16838 HAVE_DUP3=1;
16839 HAVE_EUIDACCESS=1;
16840 HAVE_FACCESSAT=1;
16841 HAVE_FCHDIR=1;
16842 HAVE_FCHOWNAT=1;
16843 HAVE_FDATASYNC=1;
16844 HAVE_FSYNC=1;
16845 HAVE_FTRUNCATE=1;
16846 HAVE_GETDTABLESIZE=1;
16847 HAVE_GETGROUPS=1;
16848 HAVE_GETHOSTNAME=1;
16849 HAVE_GETLOGIN=1;
16850 HAVE_GETPAGESIZE=1;
16851 HAVE_GROUP_MEMBER=1;
16852 HAVE_LCHOWN=1;
16853 HAVE_LINK=1;
16854 HAVE_LINKAT=1;
16855 HAVE_PIPE=1;
16856 HAVE_PIPE2=1;
16857 HAVE_PREAD=1;
16858 HAVE_PWRITE=1;
16859 HAVE_READLINK=1;
16860 HAVE_READLINKAT=1;
16861 HAVE_SETHOSTNAME=1;
16862 HAVE_SLEEP=1;
16863 HAVE_SYMLINK=1;
16864 HAVE_SYMLINKAT=1;
16865 HAVE_UNLINKAT=1;
16866 HAVE_USLEEP=1;
16867 HAVE_DECL_ENVIRON=1;
16868 HAVE_DECL_FCHDIR=1;
16869 HAVE_DECL_FDATASYNC=1;
16870 HAVE_DECL_GETDOMAINNAME=1;
16871 HAVE_DECL_GETLOGIN_R=1;
16872 HAVE_DECL_GETPAGESIZE=1;
16873 HAVE_DECL_GETUSERSHELL=1;
16874 HAVE_DECL_SETHOSTNAME=1;
16875 HAVE_DECL_TTYNAME_R=1;
16876 HAVE_OS_H=0;
16877 HAVE_SYS_PARAM_H=0;
16878 REPLACE_CHOWN=0;
16879 REPLACE_CLOSE=0;
16880 REPLACE_DUP=0;
16881 REPLACE_DUP2=0;
16882 REPLACE_FCHOWNAT=0;
16883 REPLACE_FTRUNCATE=0;
16884 REPLACE_GETCWD=0;
16885 REPLACE_GETDOMAINNAME=0;
16886 REPLACE_GETLOGIN_R=0;
16887 REPLACE_GETGROUPS=0;
16888 REPLACE_GETPAGESIZE=0;
16889 REPLACE_ISATTY=0;
16890 REPLACE_LCHOWN=0;
16891 REPLACE_LINK=0;
16892 REPLACE_LINKAT=0;
16893 REPLACE_LSEEK=0;
16894 REPLACE_PREAD=0;
16895 REPLACE_PWRITE=0;
16896 REPLACE_READ=0;
16897 REPLACE_READLINK=0;
16898 REPLACE_RMDIR=0;
16899 REPLACE_SLEEP=0;
16900 REPLACE_SYMLINK=0;
16901 REPLACE_TTYNAME_R=0;
16902 REPLACE_UNLINK=0;
16903 REPLACE_UNLINKAT=0;
16904 REPLACE_USLEEP=0;
16905 REPLACE_WRITE=0;
16906 UNISTD_H_HAVE_WINSOCK2_H=0;
16907 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16918 $as_echo_n "checking if environ is properly declared... " >&6; }
16919 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16920 $as_echo_n "(cached) " >&6
16921 else
16923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16924 /* end confdefs.h. */
16925 #if HAVE_UNISTD_H
16926 #include <unistd.h>
16927 #endif
16928 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16929 #include <stdlib.h>
16931 extern struct { int foo; } environ;
16933 main ()
16935 environ.foo = 1;
16937 return 0;
16939 _ACEOF
16940 if ac_fn_c_try_compile "$LINENO"; then :
16941 gt_cv_var_environ_declaration=no
16942 else
16943 gt_cv_var_environ_declaration=yes
16945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16949 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16950 if test $gt_cv_var_environ_declaration = yes; then
16952 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16957 if test $gt_cv_var_environ_declaration != yes; then
16958 HAVE_DECL_ENVIRON=0
16969 GNULIB_FCNTL=0;
16970 GNULIB_NONBLOCKING=0;
16971 GNULIB_OPEN=0;
16972 GNULIB_OPENAT=0;
16973 HAVE_FCNTL=1;
16974 HAVE_OPENAT=1;
16975 REPLACE_FCNTL=0;
16976 REPLACE_OPEN=0;
16977 REPLACE_OPENAT=0;
16982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16983 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16984 if test "${gl_cv_have_include_next+set}" = set; then :
16985 $as_echo_n "(cached) " >&6
16986 else
16987 rm -rf conftestd1a conftestd1b conftestd2
16988 mkdir conftestd1a conftestd1b conftestd2
16989 cat <<EOF > conftestd1a/conftest.h
16990 #define DEFINED_IN_CONFTESTD1
16991 #include_next <conftest.h>
16992 #ifdef DEFINED_IN_CONFTESTD2
16993 int foo;
16994 #else
16995 #error "include_next doesn't work"
16996 #endif
16998 cat <<EOF > conftestd1b/conftest.h
16999 #define DEFINED_IN_CONFTESTD1
17000 #include <stdio.h>
17001 #include_next <conftest.h>
17002 #ifdef DEFINED_IN_CONFTESTD2
17003 int foo;
17004 #else
17005 #error "include_next doesn't work"
17006 #endif
17008 cat <<EOF > conftestd2/conftest.h
17009 #ifndef DEFINED_IN_CONFTESTD1
17010 #error "include_next test doesn't work"
17011 #endif
17012 #define DEFINED_IN_CONFTESTD2
17014 gl_save_CPPFLAGS="$CPPFLAGS"
17015 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17017 /* end confdefs.h. */
17018 #include <conftest.h>
17019 _ACEOF
17020 if ac_fn_c_try_compile "$LINENO"; then :
17021 gl_cv_have_include_next=yes
17022 else
17023 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
17024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17025 /* end confdefs.h. */
17026 #include <conftest.h>
17027 _ACEOF
17028 if ac_fn_c_try_compile "$LINENO"; then :
17029 gl_cv_have_include_next=buggy
17030 else
17031 gl_cv_have_include_next=no
17033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17037 CPPFLAGS="$gl_save_CPPFLAGS"
17038 rm -rf conftestd1a conftestd1b conftestd2
17041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
17042 $as_echo "$gl_cv_have_include_next" >&6; }
17043 PRAGMA_SYSTEM_HEADER=
17044 if test $gl_cv_have_include_next = yes; then
17045 INCLUDE_NEXT=include_next
17046 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17047 if test -n "$GCC"; then
17048 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
17050 else
17051 if test $gl_cv_have_include_next = buggy; then
17052 INCLUDE_NEXT=include
17053 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17054 else
17055 INCLUDE_NEXT=include
17056 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
17062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
17063 $as_echo_n "checking whether system header files limit the line length... " >&6; }
17064 if test "${gl_cv_pragma_columns+set}" = set; then :
17065 $as_echo_n "(cached) " >&6
17066 else
17067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17068 /* end confdefs.h. */
17070 #ifdef __TANDEM
17071 choke me
17072 #endif
17074 _ACEOF
17075 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17076 $EGREP "choke me" >/dev/null 2>&1; then :
17077 gl_cv_pragma_columns=yes
17078 else
17079 gl_cv_pragma_columns=no
17081 rm -f conftest*
17085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
17086 $as_echo "$gl_cv_pragma_columns" >&6; }
17087 if test $gl_cv_pragma_columns = yes; then
17088 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
17089 else
17090 PRAGMA_COLUMNS=
17094 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
17095 if test "x$ac_cv_type_mode_t" = x""yes; then :
17097 else
17099 cat >>confdefs.h <<_ACEOF
17100 #define mode_t int
17101 _ACEOF
17105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
17106 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
17107 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
17108 $as_echo_n "(cached) " >&6
17109 else
17110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17111 /* end confdefs.h. */
17113 #include <sys/types.h>
17114 #include <sys/stat.h>
17116 main ()
17118 struct stat s; s.st_dm_mode;
17120 return 0;
17122 _ACEOF
17123 if ac_fn_c_try_compile "$LINENO"; then :
17124 ac_cv_struct_st_dm_mode=yes
17125 else
17126 ac_cv_struct_st_dm_mode=no
17128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
17131 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
17133 if test $ac_cv_struct_st_dm_mode = yes; then
17135 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
17140 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
17141 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
17142 ac_have_decl=1
17143 else
17144 ac_have_decl=0
17147 cat >>confdefs.h <<_ACEOF
17148 #define HAVE_DECL_STRMODE $ac_have_decl
17149 _ACEOF
17156 GNULIB__EXIT=0;
17157 GNULIB_ATOLL=0;
17158 GNULIB_CALLOC_POSIX=0;
17159 GNULIB_CANONICALIZE_FILE_NAME=0;
17160 GNULIB_GETLOADAVG=0;
17161 GNULIB_GETSUBOPT=0;
17162 GNULIB_GRANTPT=0;
17163 GNULIB_MALLOC_POSIX=0;
17164 GNULIB_MBTOWC=0;
17165 GNULIB_MKDTEMP=0;
17166 GNULIB_MKOSTEMP=0;
17167 GNULIB_MKOSTEMPS=0;
17168 GNULIB_MKSTEMP=0;
17169 GNULIB_MKSTEMPS=0;
17170 GNULIB_POSIX_OPENPT=0;
17171 GNULIB_PTSNAME=0;
17172 GNULIB_PTSNAME_R=0;
17173 GNULIB_PUTENV=0;
17174 GNULIB_RANDOM=0;
17175 GNULIB_RANDOM_R=0;
17176 GNULIB_REALLOC_POSIX=0;
17177 GNULIB_REALPATH=0;
17178 GNULIB_RPMATCH=0;
17179 GNULIB_SETENV=0;
17180 GNULIB_STRTOD=0;
17181 GNULIB_STRTOLL=0;
17182 GNULIB_STRTOULL=0;
17183 GNULIB_SYSTEM_POSIX=0;
17184 GNULIB_UNLOCKPT=0;
17185 GNULIB_UNSETENV=0;
17186 GNULIB_WCTOMB=0;
17187 HAVE__EXIT=1;
17188 HAVE_ATOLL=1;
17189 HAVE_CANONICALIZE_FILE_NAME=1;
17190 HAVE_DECL_GETLOADAVG=1;
17191 HAVE_GETSUBOPT=1;
17192 HAVE_GRANTPT=1;
17193 HAVE_MKDTEMP=1;
17194 HAVE_MKOSTEMP=1;
17195 HAVE_MKOSTEMPS=1;
17196 HAVE_MKSTEMP=1;
17197 HAVE_MKSTEMPS=1;
17198 HAVE_POSIX_OPENPT=1;
17199 HAVE_PTSNAME=1;
17200 HAVE_PTSNAME_R=1;
17201 HAVE_RANDOM=1;
17202 HAVE_RANDOM_H=1;
17203 HAVE_RANDOM_R=1;
17204 HAVE_REALPATH=1;
17205 HAVE_RPMATCH=1;
17206 HAVE_SETENV=1;
17207 HAVE_DECL_SETENV=1;
17208 HAVE_STRTOD=1;
17209 HAVE_STRTOLL=1;
17210 HAVE_STRTOULL=1;
17211 HAVE_STRUCT_RANDOM_DATA=1;
17212 HAVE_SYS_LOADAVG_H=0;
17213 HAVE_UNLOCKPT=1;
17214 HAVE_DECL_UNSETENV=1;
17215 REPLACE_CALLOC=0;
17216 REPLACE_CANONICALIZE_FILE_NAME=0;
17217 REPLACE_MALLOC=0;
17218 REPLACE_MBTOWC=0;
17219 REPLACE_MKSTEMP=0;
17220 REPLACE_PTSNAME=0;
17221 REPLACE_PTSNAME_R=0;
17222 REPLACE_PUTENV=0;
17223 REPLACE_RANDOM_R=0;
17224 REPLACE_REALLOC=0;
17225 REPLACE_REALPATH=0;
17226 REPLACE_SETENV=0;
17227 REPLACE_STRTOD=0;
17228 REPLACE_UNSETENV=0;
17229 REPLACE_WCTOMB=0;
17246 if test $gl_cv_have_include_next = yes; then
17247 gl_cv_next_getopt_h='<'getopt.h'>'
17248 else
17249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
17250 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
17251 if test "${gl_cv_next_getopt_h+set}" = set; then :
17252 $as_echo_n "(cached) " >&6
17253 else
17255 if test $ac_cv_header_getopt_h = yes; then
17258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17259 /* end confdefs.h. */
17260 #include <getopt.h>
17262 _ACEOF
17263 case "$host_os" in
17264 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17265 *) gl_absname_cpp="$ac_cpp" ;;
17266 esac
17268 case "$host_os" in
17269 mingw*)
17270 gl_dirsep_regex='[/\\]'
17273 gl_dirsep_regex='\/'
17275 esac
17276 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17278 gl_header_literal_regex=`echo 'getopt.h' \
17279 | sed -e "$gl_make_literal_regex_sed"`
17280 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17281 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17282 s|^/[^/]|//&|
17286 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17287 sed -n "$gl_absolute_header_sed"`'"'
17288 else
17289 gl_cv_next_getopt_h='<'getopt.h'>'
17294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
17295 $as_echo "$gl_cv_next_getopt_h" >&6; }
17297 NEXT_GETOPT_H=$gl_cv_next_getopt_h
17299 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17300 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17301 gl_next_as_first_directive='<'getopt.h'>'
17302 else
17303 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17304 gl_next_as_first_directive=$gl_cv_next_getopt_h
17306 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
17311 if test $ac_cv_header_getopt_h = yes; then
17312 HAVE_GETOPT_H=1
17313 else
17314 HAVE_GETOPT_H=0
17318 gl_replace_getopt=
17320 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17321 for ac_header in getopt.h
17322 do :
17323 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
17324 if test "x$ac_cv_header_getopt_h" = x""yes; then :
17325 cat >>confdefs.h <<_ACEOF
17326 #define HAVE_GETOPT_H 1
17327 _ACEOF
17329 else
17330 gl_replace_getopt=yes
17333 done
17337 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17338 for ac_func in getopt_long_only
17339 do :
17340 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
17341 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
17342 cat >>confdefs.h <<_ACEOF
17343 #define HAVE_GETOPT_LONG_ONLY 1
17344 _ACEOF
17346 else
17347 gl_replace_getopt=yes
17349 done
17353 if test -z "$gl_replace_getopt"; then
17354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17355 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17356 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17357 $as_echo_n "(cached) " >&6
17358 else
17360 if test $cross_compiling = no; then
17361 if test "$cross_compiling" = yes; then :
17362 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17363 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17364 as_fn_error "cannot run test program while cross compiling
17365 See \`config.log' for more details." "$LINENO" 5; }
17366 else
17367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17368 /* end confdefs.h. */
17370 #include <unistd.h>
17371 #include <stdlib.h>
17372 #include <string.h>
17375 main ()
17377 static char program[] = "program";
17378 static char a[] = "-a";
17379 static char foo[] = "foo";
17380 static char bar[] = "bar";
17381 char *argv[] = { program, a, foo, bar, NULL };
17382 int c;
17384 c = getopt (4, argv, "ab");
17385 if (!(c == 'a'))
17386 return 1;
17387 c = getopt (4, argv, "ab");
17388 if (!(c == -1))
17389 return 2;
17390 if (!(optind == 2))
17391 return 3;
17392 return 0;
17395 _ACEOF
17396 if ac_fn_c_try_run "$LINENO"; then :
17397 gl_cv_func_getopt_posix=maybe
17398 else
17399 gl_cv_func_getopt_posix=no
17401 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17402 conftest.$ac_objext conftest.beam conftest.$ac_ext
17405 if test $gl_cv_func_getopt_posix = maybe; then
17406 if test "$cross_compiling" = yes; then :
17407 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17408 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17409 as_fn_error "cannot run test program while cross compiling
17410 See \`config.log' for more details." "$LINENO" 5; }
17411 else
17412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17413 /* end confdefs.h. */
17415 #include <unistd.h>
17416 #include <stdlib.h>
17417 #include <string.h>
17420 main ()
17422 static char program[] = "program";
17423 static char donald[] = "donald";
17424 static char p[] = "-p";
17425 static char billy[] = "billy";
17426 static char duck[] = "duck";
17427 static char a[] = "-a";
17428 static char bar[] = "bar";
17429 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17430 int c;
17432 c = getopt (7, argv, "+abp:q:");
17433 if (!(c == -1))
17434 return 4;
17435 if (!(strcmp (argv[0], "program") == 0))
17436 return 5;
17437 if (!(strcmp (argv[1], "donald") == 0))
17438 return 6;
17439 if (!(strcmp (argv[2], "-p") == 0))
17440 return 7;
17441 if (!(strcmp (argv[3], "billy") == 0))
17442 return 8;
17443 if (!(strcmp (argv[4], "duck") == 0))
17444 return 9;
17445 if (!(strcmp (argv[5], "-a") == 0))
17446 return 10;
17447 if (!(strcmp (argv[6], "bar") == 0))
17448 return 11;
17449 if (!(optind == 1))
17450 return 12;
17451 return 0;
17454 _ACEOF
17455 if ac_fn_c_try_run "$LINENO"; then :
17456 gl_cv_func_getopt_posix=maybe
17457 else
17458 gl_cv_func_getopt_posix=no
17460 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17461 conftest.$ac_objext conftest.beam conftest.$ac_ext
17465 if test $gl_cv_func_getopt_posix = maybe; then
17466 if test "$cross_compiling" = yes; then :
17467 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17468 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17469 as_fn_error "cannot run test program while cross compiling
17470 See \`config.log' for more details." "$LINENO" 5; }
17471 else
17472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17473 /* end confdefs.h. */
17475 #include <unistd.h>
17476 #include <stdlib.h>
17477 #include <string.h>
17480 main ()
17482 static char program[] = "program";
17483 static char ab[] = "-ab";
17484 char *argv[3] = { program, ab, NULL };
17485 if (getopt (2, argv, "ab:") != 'a')
17486 return 13;
17487 if (getopt (2, argv, "ab:") != '?')
17488 return 14;
17489 if (optopt != 'b')
17490 return 15;
17491 if (optind != 2)
17492 return 16;
17493 return 0;
17496 _ACEOF
17497 if ac_fn_c_try_run "$LINENO"; then :
17498 gl_cv_func_getopt_posix=yes
17499 else
17500 gl_cv_func_getopt_posix=no
17502 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17503 conftest.$ac_objext conftest.beam conftest.$ac_ext
17507 else
17508 case "$host_os" in
17509 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17510 *) gl_cv_func_getopt_posix="guessing yes";;
17511 esac
17515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17516 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17517 case "$gl_cv_func_getopt_posix" in
17518 *no) gl_replace_getopt=yes ;;
17519 esac
17522 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17524 $as_echo_n "checking for working GNU getopt function... " >&6; }
17525 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17526 $as_echo_n "(cached) " >&6
17527 else
17528 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17529 # optstring is necessary for programs like m4 that have POSIX-mandated
17530 # semantics for supporting options interspersed with files.
17531 # Also, since getopt_long is a GNU extension, we require optind=0.
17532 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17533 # so take care to revert to the correct (non-)export state.
17534 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17535 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17536 xx) gl_had_POSIXLY_CORRECT=exported ;;
17537 x) gl_had_POSIXLY_CORRECT=yes ;;
17538 *) gl_had_POSIXLY_CORRECT= ;;
17539 esac
17540 POSIXLY_CORRECT=1
17541 export POSIXLY_CORRECT
17542 if test "$cross_compiling" = yes; then :
17543 gl_cv_func_getopt_gnu="guessing no"
17545 else
17546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17547 /* end confdefs.h. */
17548 #include <getopt.h>
17549 #include <stddef.h>
17550 #include <string.h>
17552 #include <stdlib.h>
17553 #if defined __MACH__ && defined __APPLE__
17554 /* Avoid a crash on Mac OS X. */
17555 #include <mach/mach.h>
17556 #include <mach/mach_error.h>
17557 #include <mach/thread_status.h>
17558 #include <mach/exception.h>
17559 #include <mach/task.h>
17560 #include <pthread.h>
17561 /* The exception port on which our thread listens. */
17562 static mach_port_t our_exception_port;
17563 /* The main function of the thread listening for exceptions of type
17564 EXC_BAD_ACCESS. */
17565 static void *
17566 mach_exception_thread (void *arg)
17568 /* Buffer for a message to be received. */
17569 struct {
17570 mach_msg_header_t head;
17571 mach_msg_body_t msgh_body;
17572 char data[1024];
17573 } msg;
17574 mach_msg_return_t retval;
17575 /* Wait for a message on the exception port. */
17576 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17577 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17578 if (retval != MACH_MSG_SUCCESS)
17579 abort ();
17580 exit (1);
17582 static void
17583 nocrash_init (void)
17585 mach_port_t self = mach_task_self ();
17586 /* Allocate a port on which the thread shall listen for exceptions. */
17587 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17588 == KERN_SUCCESS) {
17589 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17590 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17591 MACH_MSG_TYPE_MAKE_SEND)
17592 == KERN_SUCCESS) {
17593 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17594 for us. */
17595 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17596 /* Create the thread listening on the exception port. */
17597 pthread_attr_t attr;
17598 pthread_t thread;
17599 if (pthread_attr_init (&attr) == 0
17600 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17601 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17602 pthread_attr_destroy (&attr);
17603 /* Replace the exception port info for these exceptions with our own.
17604 Note that we replace the exception port for the entire task, not only
17605 for a particular thread. This has the effect that when our exception
17606 port gets the message, the thread specific exception port has already
17607 been asked, and we don't need to bother about it.
17608 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17609 task_set_exception_ports (self, mask, our_exception_port,
17610 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17615 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17616 /* Avoid a crash on native Windows. */
17617 #define WIN32_LEAN_AND_MEAN
17618 #include <windows.h>
17619 #include <winerror.h>
17620 static LONG WINAPI
17621 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17623 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17625 case EXCEPTION_ACCESS_VIOLATION:
17626 case EXCEPTION_IN_PAGE_ERROR:
17627 case EXCEPTION_STACK_OVERFLOW:
17628 case EXCEPTION_GUARD_PAGE:
17629 case EXCEPTION_PRIV_INSTRUCTION:
17630 case EXCEPTION_ILLEGAL_INSTRUCTION:
17631 case EXCEPTION_DATATYPE_MISALIGNMENT:
17632 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17633 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17634 exit (1);
17636 return EXCEPTION_CONTINUE_SEARCH;
17638 static void
17639 nocrash_init (void)
17641 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17643 #else
17644 /* Avoid a crash on POSIX systems. */
17645 #include <signal.h>
17646 /* A POSIX signal handler. */
17647 static void
17648 exception_handler (int sig)
17650 exit (1);
17652 static void
17653 nocrash_init (void)
17655 #ifdef SIGSEGV
17656 signal (SIGSEGV, exception_handler);
17657 #endif
17658 #ifdef SIGBUS
17659 signal (SIGBUS, exception_handler);
17660 #endif
17662 #endif
17666 main ()
17669 int result = 0;
17671 nocrash_init();
17673 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17674 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17675 OSF/1 5.1, Solaris 10. */
17677 static char conftest[] = "conftest";
17678 static char plus[] = "-+";
17679 char *argv[3] = { conftest, plus, NULL };
17680 opterr = 0;
17681 if (getopt (2, argv, "+a") != '?')
17682 result |= 1;
17684 /* This code succeeds on glibc 2.8, mingw,
17685 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17686 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17688 static char program[] = "program";
17689 static char p[] = "-p";
17690 static char foo[] = "foo";
17691 static char bar[] = "bar";
17692 char *argv[] = { program, p, foo, bar, NULL };
17694 optind = 1;
17695 if (getopt (4, argv, "p::") != 'p')
17696 result |= 2;
17697 else if (optarg != NULL)
17698 result |= 4;
17699 else if (getopt (4, argv, "p::") != -1)
17700 result |= 6;
17701 else if (optind != 2)
17702 result |= 8;
17704 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17706 static char program[] = "program";
17707 static char foo[] = "foo";
17708 static char p[] = "-p";
17709 char *argv[] = { program, foo, p, NULL };
17710 optind = 0;
17711 if (getopt (3, argv, "-p") != 1)
17712 result |= 16;
17713 else if (getopt (3, argv, "-p") != 'p')
17714 result |= 16;
17716 /* This code fails on glibc 2.11. */
17718 static char program[] = "program";
17719 static char b[] = "-b";
17720 static char a[] = "-a";
17721 char *argv[] = { program, b, a, NULL };
17722 optind = opterr = 0;
17723 if (getopt (3, argv, "+:a:b") != 'b')
17724 result |= 32;
17725 else if (getopt (3, argv, "+:a:b") != ':')
17726 result |= 32;
17728 /* This code dumps core on glibc 2.14. */
17730 static char program[] = "program";
17731 static char w[] = "-W";
17732 static char dummy[] = "dummy";
17733 char *argv[] = { program, w, dummy, NULL };
17734 optind = opterr = 1;
17735 if (getopt (3, argv, "W;") != 'W')
17736 result |= 64;
17738 return result;
17741 return 0;
17743 _ACEOF
17744 if ac_fn_c_try_run "$LINENO"; then :
17745 gl_cv_func_getopt_gnu=yes
17746 else
17747 gl_cv_func_getopt_gnu=no
17749 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17750 conftest.$ac_objext conftest.beam conftest.$ac_ext
17753 case $gl_had_POSIXLY_CORRECT in
17754 exported) ;;
17755 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17756 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17757 esac
17760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17761 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17762 if test "$gl_cv_func_getopt_gnu" != yes; then
17763 gl_replace_getopt=yes
17764 else
17765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17766 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17767 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17768 $as_echo_n "(cached) " >&6
17769 else
17770 if test "$cross_compiling" = yes; then :
17771 case "$host_os" in
17772 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17773 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17774 esac
17776 else
17777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17778 /* end confdefs.h. */
17779 #include <getopt.h>
17780 #include <stddef.h>
17781 #include <string.h>
17784 main ()
17786 static const struct option long_options[] =
17788 { "xtremely-",no_argument, NULL, 1003 },
17789 { "xtra", no_argument, NULL, 1001 },
17790 { "xtreme", no_argument, NULL, 1002 },
17791 { "xtremely", no_argument, NULL, 1003 },
17792 { NULL, 0, NULL, 0 }
17794 /* This code fails on OpenBSD 5.0. */
17796 static char program[] = "program";
17797 static char xtremel[] = "--xtremel";
17798 char *argv[] = { program, xtremel, NULL };
17799 int option_index;
17800 optind = 1; opterr = 0;
17801 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17802 return 1;
17804 return 0;
17807 return 0;
17809 _ACEOF
17810 if ac_fn_c_try_run "$LINENO"; then :
17811 gl_cv_func_getopt_long_gnu=yes
17812 else
17813 gl_cv_func_getopt_long_gnu=no
17815 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17816 conftest.$ac_objext conftest.beam conftest.$ac_ext
17821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17822 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17823 case "$gl_cv_func_getopt_long_gnu" in
17824 *yes) ;;
17825 *) gl_replace_getopt=yes ;;
17826 esac
17835 REPLACE_GETOPT=0
17836 if test -n "$gl_replace_getopt"; then
17837 REPLACE_GETOPT=1
17840 if test $REPLACE_GETOPT = 1; then
17842 GETOPT_H=getopt.h
17844 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17850 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17851 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17852 ac_have_decl=1
17853 else
17854 ac_have_decl=0
17857 cat >>confdefs.h <<_ACEOF
17858 #define HAVE_DECL_GETENV $ac_have_decl
17859 _ACEOF
17866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17867 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17868 if test "${ac_cv_c_restrict+set}" = set; then :
17869 $as_echo_n "(cached) " >&6
17870 else
17871 ac_cv_c_restrict=no
17872 # The order here caters to the fact that C++ does not require restrict.
17873 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17875 /* end confdefs.h. */
17876 typedef int * int_ptr;
17877 int foo (int_ptr $ac_kw ip) {
17878 return ip[0];
17881 main ()
17883 int s[1];
17884 int * $ac_kw t = s;
17885 t[0] = 0;
17886 return foo(t)
17888 return 0;
17890 _ACEOF
17891 if ac_fn_c_try_compile "$LINENO"; then :
17892 ac_cv_c_restrict=$ac_kw
17894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17895 test "$ac_cv_c_restrict" != no && break
17896 done
17899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17900 $as_echo "$ac_cv_c_restrict" >&6; }
17902 case $ac_cv_c_restrict in
17903 restrict) ;;
17904 no) $as_echo "#define restrict /**/" >>confdefs.h
17906 *) cat >>confdefs.h <<_ACEOF
17907 #define restrict $ac_cv_c_restrict
17908 _ACEOF
17910 esac
17913 GNULIB_GETTIMEOFDAY=0;
17914 HAVE_GETTIMEOFDAY=1;
17915 HAVE_STRUCT_TIMEVAL=1;
17916 HAVE_SYS_TIME_H=1;
17917 REPLACE_GETTIMEOFDAY=0;
17918 REPLACE_STRUCT_TIMEVAL=0;
17935 if test $gl_cv_have_include_next = yes; then
17936 gl_cv_next_sys_time_h='<'sys/time.h'>'
17937 else
17938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17939 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17940 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17941 $as_echo_n "(cached) " >&6
17942 else
17944 if test $ac_cv_header_sys_time_h = yes; then
17947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17948 /* end confdefs.h. */
17949 #include <sys/time.h>
17951 _ACEOF
17952 case "$host_os" in
17953 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17954 *) gl_absname_cpp="$ac_cpp" ;;
17955 esac
17957 case "$host_os" in
17958 mingw*)
17959 gl_dirsep_regex='[/\\]'
17962 gl_dirsep_regex='\/'
17964 esac
17965 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17967 gl_header_literal_regex=`echo 'sys/time.h' \
17968 | sed -e "$gl_make_literal_regex_sed"`
17969 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17970 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17971 s|^/[^/]|//&|
17975 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17976 sed -n "$gl_absolute_header_sed"`'"'
17977 else
17978 gl_cv_next_sys_time_h='<'sys/time.h'>'
17983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17984 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17986 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17988 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17989 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17990 gl_next_as_first_directive='<'sys/time.h'>'
17991 else
17992 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17993 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17995 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
18001 if test $ac_cv_header_sys_time_h != yes; then
18002 HAVE_SYS_TIME_H=0
18009 if test $ac_cv_header_sys_socket_h != yes; then
18010 for ac_header in winsock2.h
18011 do :
18012 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
18013 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
18014 cat >>confdefs.h <<_ACEOF
18015 #define HAVE_WINSOCK2_H 1
18016 _ACEOF
18020 done
18023 if test "$ac_cv_header_winsock2_h" = yes; then
18024 HAVE_WINSOCK2_H=1
18025 UNISTD_H_HAVE_WINSOCK2_H=1
18026 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
18027 else
18028 HAVE_WINSOCK2_H=0
18032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
18033 $as_echo_n "checking for struct timeval... " >&6; }
18034 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
18035 $as_echo_n "(cached) " >&6
18036 else
18037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18038 /* end confdefs.h. */
18039 #if HAVE_SYS_TIME_H
18040 #include <sys/time.h>
18041 #endif
18042 #include <time.h>
18043 #if HAVE_WINSOCK2_H
18044 # include <winsock2.h>
18045 #endif
18048 main ()
18050 static struct timeval x; x.tv_sec = x.tv_usec;
18052 return 0;
18054 _ACEOF
18055 if ac_fn_c_try_compile "$LINENO"; then :
18056 gl_cv_sys_struct_timeval=yes
18057 else
18058 gl_cv_sys_struct_timeval=no
18060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
18064 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
18065 if test $gl_cv_sys_struct_timeval != yes; then
18066 HAVE_STRUCT_TIMEVAL=0
18067 else
18068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
18069 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
18070 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
18071 $as_echo_n "(cached) " >&6
18072 else
18073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18074 /* end confdefs.h. */
18075 #if HAVE_SYS_TIME_H
18076 #include <sys/time.h>
18077 #endif
18078 #include <time.h>
18079 #if HAVE_WINSOCK2_H
18080 # include <winsock2.h>
18081 #endif
18084 main ()
18086 static struct timeval x;
18087 typedef int verify_tv_sec_type[
18088 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
18092 return 0;
18094 _ACEOF
18095 if ac_fn_c_try_compile "$LINENO"; then :
18096 gl_cv_sys_struct_timeval_tv_sec=yes
18097 else
18098 gl_cv_sys_struct_timeval_tv_sec=no
18100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
18104 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
18105 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
18106 REPLACE_STRUCT_TIMEVAL=1
18116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
18117 $as_echo_n "checking for unsigned long long int... " >&6; }
18118 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
18119 $as_echo_n "(cached) " >&6
18120 else
18121 ac_cv_type_unsigned_long_long_int=yes
18122 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18124 /* end confdefs.h. */
18126 /* For now, do not test the preprocessor; as of 2007 there are too many
18127 implementations with broken preprocessors. Perhaps this can
18128 be revisited in 2012. In the meantime, code should not expect
18129 #if to work with literals wider than 32 bits. */
18130 /* Test literals. */
18131 long long int ll = 9223372036854775807ll;
18132 long long int nll = -9223372036854775807LL;
18133 unsigned long long int ull = 18446744073709551615ULL;
18134 /* Test constant expressions. */
18135 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
18136 ? 1 : -1)];
18137 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
18138 ? 1 : -1)];
18139 int i = 63;
18141 main ()
18143 /* Test availability of runtime routines for shift and division. */
18144 long long int llmax = 9223372036854775807ll;
18145 unsigned long long int ullmax = 18446744073709551615ull;
18146 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
18147 | (llmax / ll) | (llmax % ll)
18148 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
18149 | (ullmax / ull) | (ullmax % ull));
18151 return 0;
18154 _ACEOF
18155 if ac_fn_c_try_link "$LINENO"; then :
18157 else
18158 ac_cv_type_unsigned_long_long_int=no
18160 rm -f core conftest.err conftest.$ac_objext \
18161 conftest$ac_exeext conftest.$ac_ext
18164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
18165 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
18166 if test $ac_cv_type_unsigned_long_long_int = yes; then
18168 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
18174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
18175 $as_echo_n "checking for long long int... " >&6; }
18176 if test "${ac_cv_type_long_long_int+set}" = set; then :
18177 $as_echo_n "(cached) " >&6
18178 else
18179 ac_cv_type_long_long_int=yes
18180 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18181 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
18182 if test $ac_cv_type_long_long_int = yes; then
18183 if test "$cross_compiling" = yes; then :
18185 else
18186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18187 /* end confdefs.h. */
18188 #include <limits.h>
18189 #ifndef LLONG_MAX
18190 # define HALF \
18191 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
18192 # define LLONG_MAX (HALF - 1 + HALF)
18193 #endif
18195 main ()
18197 long long int n = 1;
18198 int i;
18199 for (i = 0; ; i++)
18201 long long int m = n << i;
18202 if (m >> i != n)
18203 return 1;
18204 if (LLONG_MAX / 2 < m)
18205 break;
18207 return 0;
18209 return 0;
18211 _ACEOF
18212 if ac_fn_c_try_run "$LINENO"; then :
18214 else
18215 ac_cv_type_long_long_int=no
18217 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18218 conftest.$ac_objext conftest.beam conftest.$ac_ext
18224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
18225 $as_echo "$ac_cv_type_long_long_int" >&6; }
18226 if test $ac_cv_type_long_long_int = yes; then
18228 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
18237 gl_cv_c_multiarch=no
18238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18239 /* end confdefs.h. */
18240 #ifndef __APPLE_CC__
18241 not a universal capable compiler
18242 #endif
18243 typedef int dummy;
18245 _ACEOF
18246 if ac_fn_c_try_compile "$LINENO"; then :
18248 arch=
18249 prev=
18250 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
18251 if test -n "$prev"; then
18252 case $word in
18253 i?86 | x86_64 | ppc | ppc64)
18254 if test -z "$arch" || test "$arch" = "$word"; then
18255 arch="$word"
18256 else
18257 gl_cv_c_multiarch=yes
18260 esac
18261 prev=
18262 else
18263 if test "x$word" = "x-arch"; then
18264 prev=arch
18267 done
18270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18271 if test $gl_cv_c_multiarch = yes; then
18272 APPLE_UNIVERSAL_BUILD=1
18273 else
18274 APPLE_UNIVERSAL_BUILD=0
18281 if test $ac_cv_type_long_long_int = yes; then
18282 HAVE_LONG_LONG_INT=1
18283 else
18284 HAVE_LONG_LONG_INT=0
18288 if test $ac_cv_type_unsigned_long_long_int = yes; then
18289 HAVE_UNSIGNED_LONG_LONG_INT=1
18290 else
18291 HAVE_UNSIGNED_LONG_LONG_INT=0
18296 if test $ac_cv_header_wchar_h = yes; then
18297 HAVE_WCHAR_H=1
18298 else
18299 HAVE_WCHAR_H=0
18303 if test $ac_cv_header_inttypes_h = yes; then
18304 HAVE_INTTYPES_H=1
18305 else
18306 HAVE_INTTYPES_H=0
18310 if test $ac_cv_header_sys_types_h = yes; then
18311 HAVE_SYS_TYPES_H=1
18312 else
18313 HAVE_SYS_TYPES_H=0
18326 if test $gl_cv_have_include_next = yes; then
18327 gl_cv_next_stdint_h='<'stdint.h'>'
18328 else
18329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
18330 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
18331 if test "${gl_cv_next_stdint_h+set}" = set; then :
18332 $as_echo_n "(cached) " >&6
18333 else
18335 if test $ac_cv_header_stdint_h = yes; then
18338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18339 /* end confdefs.h. */
18340 #include <stdint.h>
18342 _ACEOF
18343 case "$host_os" in
18344 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18345 *) gl_absname_cpp="$ac_cpp" ;;
18346 esac
18348 case "$host_os" in
18349 mingw*)
18350 gl_dirsep_regex='[/\\]'
18353 gl_dirsep_regex='\/'
18355 esac
18356 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18358 gl_header_literal_regex=`echo 'stdint.h' \
18359 | sed -e "$gl_make_literal_regex_sed"`
18360 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18361 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18362 s|^/[^/]|//&|
18366 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18367 sed -n "$gl_absolute_header_sed"`'"'
18368 else
18369 gl_cv_next_stdint_h='<'stdint.h'>'
18374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18375 $as_echo "$gl_cv_next_stdint_h" >&6; }
18377 NEXT_STDINT_H=$gl_cv_next_stdint_h
18379 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18380 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18381 gl_next_as_first_directive='<'stdint.h'>'
18382 else
18383 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18384 gl_next_as_first_directive=$gl_cv_next_stdint_h
18386 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18391 if test $ac_cv_header_stdint_h = yes; then
18392 HAVE_STDINT_H=1
18393 else
18394 HAVE_STDINT_H=0
18398 if test $ac_cv_header_stdint_h = yes; then
18399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18400 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18401 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18402 $as_echo_n "(cached) " >&6
18403 else
18404 gl_cv_header_working_stdint_h=no
18405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18406 /* end confdefs.h. */
18409 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18410 #include <stdint.h>
18411 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18412 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18413 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18414 #endif
18417 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18418 included before <wchar.h>. */
18419 #include <stddef.h>
18420 #include <signal.h>
18421 #if HAVE_WCHAR_H
18422 # include <stdio.h>
18423 # include <time.h>
18424 # include <wchar.h>
18425 #endif
18428 #ifdef INT8_MAX
18429 int8_t a1 = INT8_MAX;
18430 int8_t a1min = INT8_MIN;
18431 #endif
18432 #ifdef INT16_MAX
18433 int16_t a2 = INT16_MAX;
18434 int16_t a2min = INT16_MIN;
18435 #endif
18436 #ifdef INT32_MAX
18437 int32_t a3 = INT32_MAX;
18438 int32_t a3min = INT32_MIN;
18439 #endif
18440 #ifdef INT64_MAX
18441 int64_t a4 = INT64_MAX;
18442 int64_t a4min = INT64_MIN;
18443 #endif
18444 #ifdef UINT8_MAX
18445 uint8_t b1 = UINT8_MAX;
18446 #else
18447 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18448 #endif
18449 #ifdef UINT16_MAX
18450 uint16_t b2 = UINT16_MAX;
18451 #endif
18452 #ifdef UINT32_MAX
18453 uint32_t b3 = UINT32_MAX;
18454 #endif
18455 #ifdef UINT64_MAX
18456 uint64_t b4 = UINT64_MAX;
18457 #endif
18458 int_least8_t c1 = INT8_C (0x7f);
18459 int_least8_t c1max = INT_LEAST8_MAX;
18460 int_least8_t c1min = INT_LEAST8_MIN;
18461 int_least16_t c2 = INT16_C (0x7fff);
18462 int_least16_t c2max = INT_LEAST16_MAX;
18463 int_least16_t c2min = INT_LEAST16_MIN;
18464 int_least32_t c3 = INT32_C (0x7fffffff);
18465 int_least32_t c3max = INT_LEAST32_MAX;
18466 int_least32_t c3min = INT_LEAST32_MIN;
18467 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18468 int_least64_t c4max = INT_LEAST64_MAX;
18469 int_least64_t c4min = INT_LEAST64_MIN;
18470 uint_least8_t d1 = UINT8_C (0xff);
18471 uint_least8_t d1max = UINT_LEAST8_MAX;
18472 uint_least16_t d2 = UINT16_C (0xffff);
18473 uint_least16_t d2max = UINT_LEAST16_MAX;
18474 uint_least32_t d3 = UINT32_C (0xffffffff);
18475 uint_least32_t d3max = UINT_LEAST32_MAX;
18476 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18477 uint_least64_t d4max = UINT_LEAST64_MAX;
18478 int_fast8_t e1 = INT_FAST8_MAX;
18479 int_fast8_t e1min = INT_FAST8_MIN;
18480 int_fast16_t e2 = INT_FAST16_MAX;
18481 int_fast16_t e2min = INT_FAST16_MIN;
18482 int_fast32_t e3 = INT_FAST32_MAX;
18483 int_fast32_t e3min = INT_FAST32_MIN;
18484 int_fast64_t e4 = INT_FAST64_MAX;
18485 int_fast64_t e4min = INT_FAST64_MIN;
18486 uint_fast8_t f1 = UINT_FAST8_MAX;
18487 uint_fast16_t f2 = UINT_FAST16_MAX;
18488 uint_fast32_t f3 = UINT_FAST32_MAX;
18489 uint_fast64_t f4 = UINT_FAST64_MAX;
18490 #ifdef INTPTR_MAX
18491 intptr_t g = INTPTR_MAX;
18492 intptr_t gmin = INTPTR_MIN;
18493 #endif
18494 #ifdef UINTPTR_MAX
18495 uintptr_t h = UINTPTR_MAX;
18496 #endif
18497 intmax_t i = INTMAX_MAX;
18498 uintmax_t j = UINTMAX_MAX;
18500 #include <limits.h> /* for CHAR_BIT */
18501 #define TYPE_MINIMUM(t) \
18502 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18503 #define TYPE_MAXIMUM(t) \
18504 ((t) ((t) 0 < (t) -1 \
18505 ? (t) -1 \
18506 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18507 struct s {
18508 int check_PTRDIFF:
18509 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18510 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18511 ? 1 : -1;
18512 /* Detect bug in FreeBSD 6.0 / ia64. */
18513 int check_SIG_ATOMIC:
18514 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18515 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18516 ? 1 : -1;
18517 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18518 int check_WCHAR:
18519 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18520 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18521 ? 1 : -1;
18522 /* Detect bug in mingw. */
18523 int check_WINT:
18524 WINT_MIN == TYPE_MINIMUM (wint_t)
18525 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18526 ? 1 : -1;
18528 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18529 int check_UINT8_C:
18530 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18531 int check_UINT16_C:
18532 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18534 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18535 #ifdef UINT8_MAX
18536 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18537 #endif
18538 #ifdef UINT16_MAX
18539 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18540 #endif
18541 #ifdef UINT32_MAX
18542 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18543 #endif
18544 #ifdef UINT64_MAX
18545 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18546 #endif
18547 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18548 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18549 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18550 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18551 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18552 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18553 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18554 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18555 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18556 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18557 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18561 main ()
18565 return 0;
18567 _ACEOF
18568 if ac_fn_c_try_compile "$LINENO"; then :
18569 if test "$cross_compiling" = yes; then :
18570 gl_cv_header_working_stdint_h=yes
18572 else
18573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18574 /* end confdefs.h. */
18577 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18578 #include <stdint.h>
18581 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18582 included before <wchar.h>. */
18583 #include <stddef.h>
18584 #include <signal.h>
18585 #if HAVE_WCHAR_H
18586 # include <stdio.h>
18587 # include <time.h>
18588 # include <wchar.h>
18589 #endif
18592 #include <stdio.h>
18593 #include <string.h>
18594 #define MVAL(macro) MVAL1(macro)
18595 #define MVAL1(expression) #expression
18596 static const char *macro_values[] =
18598 #ifdef INT8_MAX
18599 MVAL (INT8_MAX),
18600 #endif
18601 #ifdef INT16_MAX
18602 MVAL (INT16_MAX),
18603 #endif
18604 #ifdef INT32_MAX
18605 MVAL (INT32_MAX),
18606 #endif
18607 #ifdef INT64_MAX
18608 MVAL (INT64_MAX),
18609 #endif
18610 #ifdef UINT8_MAX
18611 MVAL (UINT8_MAX),
18612 #endif
18613 #ifdef UINT16_MAX
18614 MVAL (UINT16_MAX),
18615 #endif
18616 #ifdef UINT32_MAX
18617 MVAL (UINT32_MAX),
18618 #endif
18619 #ifdef UINT64_MAX
18620 MVAL (UINT64_MAX),
18621 #endif
18622 NULL
18626 main ()
18629 const char **mv;
18630 for (mv = macro_values; *mv != NULL; mv++)
18632 const char *value = *mv;
18633 /* Test whether it looks like a cast expression. */
18634 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18635 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18636 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18637 || strncmp (value, "((int)"/*)*/, 6) == 0
18638 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18639 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18640 return mv - macro_values + 1;
18642 return 0;
18645 return 0;
18647 _ACEOF
18648 if ac_fn_c_try_run "$LINENO"; then :
18649 gl_cv_header_working_stdint_h=yes
18651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18652 conftest.$ac_objext conftest.beam conftest.$ac_ext
18657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18661 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18663 if test "$gl_cv_header_working_stdint_h" = yes; then
18664 STDINT_H=
18665 else
18666 for ac_header in sys/inttypes.h sys/bitypes.h
18667 do :
18668 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18669 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18670 eval as_val=\$$as_ac_Header
18671 if test "x$as_val" = x""yes; then :
18672 cat >>confdefs.h <<_ACEOF
18673 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18674 _ACEOF
18678 done
18680 if test $ac_cv_header_sys_inttypes_h = yes; then
18681 HAVE_SYS_INTTYPES_H=1
18682 else
18683 HAVE_SYS_INTTYPES_H=0
18686 if test $ac_cv_header_sys_bitypes_h = yes; then
18687 HAVE_SYS_BITYPES_H=1
18688 else
18689 HAVE_SYS_BITYPES_H=0
18695 if test $APPLE_UNIVERSAL_BUILD = 0; then
18698 for gltype in ptrdiff_t size_t ; do
18699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18700 $as_echo_n "checking for bit size of $gltype... " >&6; }
18701 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18702 $as_echo_n "(cached) " >&6
18703 else
18704 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18705 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18706 included before <wchar.h>. */
18707 #include <stddef.h>
18708 #include <signal.h>
18709 #if HAVE_WCHAR_H
18710 # include <stdio.h>
18711 # include <time.h>
18712 # include <wchar.h>
18713 #endif
18715 #include <limits.h>"; then :
18717 else
18718 result=unknown
18721 eval gl_cv_bitsizeof_${gltype}=\$result
18724 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18726 $as_echo "$ac_res" >&6; }
18727 eval result=\$gl_cv_bitsizeof_${gltype}
18728 if test $result = unknown; then
18729 result=0
18731 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18732 cat >>confdefs.h <<_ACEOF
18733 #define BITSIZEOF_${GLTYPE} $result
18734 _ACEOF
18736 eval BITSIZEOF_${GLTYPE}=\$result
18737 done
18743 for gltype in sig_atomic_t wchar_t wint_t ; do
18744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18745 $as_echo_n "checking for bit size of $gltype... " >&6; }
18746 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18747 $as_echo_n "(cached) " >&6
18748 else
18749 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18750 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18751 included before <wchar.h>. */
18752 #include <stddef.h>
18753 #include <signal.h>
18754 #if HAVE_WCHAR_H
18755 # include <stdio.h>
18756 # include <time.h>
18757 # include <wchar.h>
18758 #endif
18760 #include <limits.h>"; then :
18762 else
18763 result=unknown
18766 eval gl_cv_bitsizeof_${gltype}=\$result
18769 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18771 $as_echo "$ac_res" >&6; }
18772 eval result=\$gl_cv_bitsizeof_${gltype}
18773 if test $result = unknown; then
18774 result=0
18776 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18777 cat >>confdefs.h <<_ACEOF
18778 #define BITSIZEOF_${GLTYPE} $result
18779 _ACEOF
18781 eval BITSIZEOF_${GLTYPE}=\$result
18782 done
18787 for gltype in sig_atomic_t wchar_t wint_t ; do
18788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18789 $as_echo_n "checking whether $gltype is signed... " >&6; }
18790 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18791 $as_echo_n "(cached) " >&6
18792 else
18793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18794 /* end confdefs.h. */
18796 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18797 included before <wchar.h>. */
18798 #include <stddef.h>
18799 #include <signal.h>
18800 #if HAVE_WCHAR_H
18801 # include <stdio.h>
18802 # include <time.h>
18803 # include <wchar.h>
18804 #endif
18806 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18808 main ()
18812 return 0;
18814 _ACEOF
18815 if ac_fn_c_try_compile "$LINENO"; then :
18816 result=yes
18817 else
18818 result=no
18820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18821 eval gl_cv_type_${gltype}_signed=\$result
18824 eval ac_res=\$gl_cv_type_${gltype}_signed
18825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18826 $as_echo "$ac_res" >&6; }
18827 eval result=\$gl_cv_type_${gltype}_signed
18828 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18829 if test "$result" = yes; then
18830 cat >>confdefs.h <<_ACEOF
18831 #define HAVE_SIGNED_${GLTYPE} 1
18832 _ACEOF
18834 eval HAVE_SIGNED_${GLTYPE}=1
18835 else
18836 eval HAVE_SIGNED_${GLTYPE}=0
18838 done
18841 gl_cv_type_ptrdiff_t_signed=yes
18842 gl_cv_type_size_t_signed=no
18843 if test $APPLE_UNIVERSAL_BUILD = 0; then
18846 for gltype in ptrdiff_t size_t ; do
18847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18848 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18849 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18850 $as_echo_n "(cached) " >&6
18851 else
18852 eval gl_cv_type_${gltype}_suffix=no
18853 eval result=\$gl_cv_type_${gltype}_signed
18854 if test "$result" = yes; then
18855 glsufu=
18856 else
18857 glsufu=u
18859 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18860 case $glsuf in
18861 '') gltype1='int';;
18862 l) gltype1='long int';;
18863 ll) gltype1='long long int';;
18864 i64) gltype1='__int64';;
18865 u) gltype1='unsigned int';;
18866 ul) gltype1='unsigned long int';;
18867 ull) gltype1='unsigned long long int';;
18868 ui64)gltype1='unsigned __int64';;
18869 esac
18870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18871 /* end confdefs.h. */
18873 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18874 included before <wchar.h>. */
18875 #include <stddef.h>
18876 #include <signal.h>
18877 #if HAVE_WCHAR_H
18878 # include <stdio.h>
18879 # include <time.h>
18880 # include <wchar.h>
18881 #endif
18883 extern $gltype foo;
18884 extern $gltype1 foo;
18886 main ()
18890 return 0;
18892 _ACEOF
18893 if ac_fn_c_try_compile "$LINENO"; then :
18894 eval gl_cv_type_${gltype}_suffix=\$glsuf
18896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18897 eval result=\$gl_cv_type_${gltype}_suffix
18898 test "$result" != no && break
18899 done
18901 eval ac_res=\$gl_cv_type_${gltype}_suffix
18902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18903 $as_echo "$ac_res" >&6; }
18904 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18905 eval result=\$gl_cv_type_${gltype}_suffix
18906 test "$result" = no && result=
18907 eval ${GLTYPE}_SUFFIX=\$result
18908 cat >>confdefs.h <<_ACEOF
18909 #define ${GLTYPE}_SUFFIX $result
18910 _ACEOF
18912 done
18918 for gltype in sig_atomic_t wchar_t wint_t ; do
18919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18920 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18921 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18922 $as_echo_n "(cached) " >&6
18923 else
18924 eval gl_cv_type_${gltype}_suffix=no
18925 eval result=\$gl_cv_type_${gltype}_signed
18926 if test "$result" = yes; then
18927 glsufu=
18928 else
18929 glsufu=u
18931 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18932 case $glsuf in
18933 '') gltype1='int';;
18934 l) gltype1='long int';;
18935 ll) gltype1='long long int';;
18936 i64) gltype1='__int64';;
18937 u) gltype1='unsigned int';;
18938 ul) gltype1='unsigned long int';;
18939 ull) gltype1='unsigned long long int';;
18940 ui64)gltype1='unsigned __int64';;
18941 esac
18942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18943 /* end confdefs.h. */
18945 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18946 included before <wchar.h>. */
18947 #include <stddef.h>
18948 #include <signal.h>
18949 #if HAVE_WCHAR_H
18950 # include <stdio.h>
18951 # include <time.h>
18952 # include <wchar.h>
18953 #endif
18955 extern $gltype foo;
18956 extern $gltype1 foo;
18958 main ()
18962 return 0;
18964 _ACEOF
18965 if ac_fn_c_try_compile "$LINENO"; then :
18966 eval gl_cv_type_${gltype}_suffix=\$glsuf
18968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18969 eval result=\$gl_cv_type_${gltype}_suffix
18970 test "$result" != no && break
18971 done
18973 eval ac_res=\$gl_cv_type_${gltype}_suffix
18974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18975 $as_echo "$ac_res" >&6; }
18976 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18977 eval result=\$gl_cv_type_${gltype}_suffix
18978 test "$result" = no && result=
18979 eval ${GLTYPE}_SUFFIX=\$result
18980 cat >>confdefs.h <<_ACEOF
18981 #define ${GLTYPE}_SUFFIX $result
18982 _ACEOF
18984 done
18988 if test $BITSIZEOF_WINT_T -lt 32; then
18989 BITSIZEOF_WINT_T=32
18992 STDINT_H=stdint.h
18995 if test -n "$STDINT_H"; then
18996 GL_GENERATE_STDINT_H_TRUE=
18997 GL_GENERATE_STDINT_H_FALSE='#'
18998 else
18999 GL_GENERATE_STDINT_H_TRUE='#'
19000 GL_GENERATE_STDINT_H_FALSE=
19007 GNULIB_IMAXABS=0;
19008 GNULIB_IMAXDIV=0;
19009 GNULIB_STRTOIMAX=0;
19010 GNULIB_STRTOUMAX=0;
19011 HAVE_DECL_IMAXABS=1;
19012 HAVE_DECL_IMAXDIV=1;
19013 HAVE_DECL_STRTOIMAX=1;
19014 HAVE_DECL_STRTOUMAX=1;
19015 REPLACE_STRTOIMAX=0;
19016 INT32_MAX_LT_INTMAX_MAX=1;
19017 INT64_MAX_EQ_LONG_MAX='defined _LP64';
19018 PRI_MACROS_BROKEN=0;
19019 PRIPTR_PREFIX=__PRIPTR_PREFIX;
19020 UINT32_MAX_LT_UINTMAX_MAX=1;
19021 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
19037 if test $gl_cv_have_include_next = yes; then
19038 gl_cv_next_inttypes_h='<'inttypes.h'>'
19039 else
19040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
19041 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
19042 if test "${gl_cv_next_inttypes_h+set}" = set; then :
19043 $as_echo_n "(cached) " >&6
19044 else
19046 if test $ac_cv_header_inttypes_h = yes; then
19049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19050 /* end confdefs.h. */
19051 #include <inttypes.h>
19053 _ACEOF
19054 case "$host_os" in
19055 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19056 *) gl_absname_cpp="$ac_cpp" ;;
19057 esac
19059 case "$host_os" in
19060 mingw*)
19061 gl_dirsep_regex='[/\\]'
19064 gl_dirsep_regex='\/'
19066 esac
19067 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19069 gl_header_literal_regex=`echo 'inttypes.h' \
19070 | sed -e "$gl_make_literal_regex_sed"`
19071 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19072 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19073 s|^/[^/]|//&|
19077 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19078 sed -n "$gl_absolute_header_sed"`'"'
19079 else
19080 gl_cv_next_inttypes_h='<'inttypes.h'>'
19085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
19086 $as_echo "$gl_cv_next_inttypes_h" >&6; }
19088 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
19090 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19091 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19092 gl_next_as_first_directive='<'inttypes.h'>'
19093 else
19094 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19095 gl_next_as_first_directive=$gl_cv_next_inttypes_h
19097 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
19109 case "$host_os" in
19110 mingw*)
19111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
19112 $as_echo_n "checking for 64-bit off_t... " >&6; }
19113 if test "${gl_cv_type_off_t_64+set}" = set; then :
19114 $as_echo_n "(cached) " >&6
19115 else
19116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19117 /* end confdefs.h. */
19118 #include <sys/types.h>
19119 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
19122 main ()
19126 return 0;
19128 _ACEOF
19129 if ac_fn_c_try_compile "$LINENO"; then :
19130 gl_cv_type_off_t_64=yes
19131 else
19132 gl_cv_type_off_t_64=no
19134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
19138 $as_echo "$gl_cv_type_off_t_64" >&6; }
19139 if test $gl_cv_type_off_t_64 = no; then
19140 WINDOWS_64_BIT_OFF_T=1
19141 else
19142 WINDOWS_64_BIT_OFF_T=0
19144 WINDOWS_64_BIT_ST_SIZE=1
19147 WINDOWS_64_BIT_OFF_T=0
19148 WINDOWS_64_BIT_ST_SIZE=0
19150 esac
19153 GNULIB_FCHMODAT=0;
19154 GNULIB_FSTAT=0;
19155 GNULIB_FSTATAT=0;
19156 GNULIB_FUTIMENS=0;
19157 GNULIB_LCHMOD=0;
19158 GNULIB_LSTAT=0;
19159 GNULIB_MKDIRAT=0;
19160 GNULIB_MKFIFO=0;
19161 GNULIB_MKFIFOAT=0;
19162 GNULIB_MKNOD=0;
19163 GNULIB_MKNODAT=0;
19164 GNULIB_STAT=0;
19165 GNULIB_UTIMENSAT=0;
19166 HAVE_FCHMODAT=1;
19167 HAVE_FSTATAT=1;
19168 HAVE_FUTIMENS=1;
19169 HAVE_LCHMOD=1;
19170 HAVE_LSTAT=1;
19171 HAVE_MKDIRAT=1;
19172 HAVE_MKFIFO=1;
19173 HAVE_MKFIFOAT=1;
19174 HAVE_MKNOD=1;
19175 HAVE_MKNODAT=1;
19176 HAVE_UTIMENSAT=1;
19177 REPLACE_FSTAT=0;
19178 REPLACE_FSTATAT=0;
19179 REPLACE_FUTIMENS=0;
19180 REPLACE_LSTAT=0;
19181 REPLACE_MKDIR=0;
19182 REPLACE_MKFIFO=0;
19183 REPLACE_MKNOD=0;
19184 REPLACE_STAT=0;
19185 REPLACE_UTIMENSAT=0;
19190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
19191 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
19192 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
19193 $as_echo_n "(cached) " >&6
19194 else
19195 rm -f conftest.sym conftest.file
19196 echo >conftest.file
19197 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
19198 if test "$cross_compiling" = yes; then :
19199 case "$host_os" in
19200 # Guess yes on glibc systems.
19201 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
19202 # If we don't know, assume the worst.
19203 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
19204 esac
19206 else
19207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19208 /* end confdefs.h. */
19209 $ac_includes_default
19211 main ()
19213 struct stat sbuf;
19214 /* Linux will dereference the symlink and fail, as required by
19215 POSIX. That is better in the sense that it means we will not
19216 have to compile and use the lstat wrapper. */
19217 return lstat ("conftest.sym/", &sbuf) == 0;
19220 return 0;
19222 _ACEOF
19223 if ac_fn_c_try_run "$LINENO"; then :
19224 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19225 else
19226 gl_cv_func_lstat_dereferences_slashed_symlink=no
19228 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19229 conftest.$ac_objext conftest.beam conftest.$ac_ext
19232 else
19233 # If the 'ln -s' command failed, then we probably don't even
19234 # have an lstat function.
19235 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19237 rm -f conftest.sym conftest.file
19240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19241 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19242 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19243 *yes)
19245 cat >>confdefs.h <<_ACEOF
19246 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19247 _ACEOF
19250 esac
19253 GNULIB_MKTIME=0;
19254 GNULIB_NANOSLEEP=0;
19255 GNULIB_STRPTIME=0;
19256 GNULIB_TIMEGM=0;
19257 GNULIB_TIME_R=0;
19258 HAVE_DECL_LOCALTIME_R=1;
19259 HAVE_NANOSLEEP=1;
19260 HAVE_STRPTIME=1;
19261 HAVE_TIMEGM=1;
19262 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
19263 REPLACE_MKTIME=GNULIB_PORTCHECK;
19264 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
19265 REPLACE_TIMEGM=GNULIB_PORTCHECK;
19270 GNULIB_PSELECT=0;
19271 GNULIB_SELECT=0;
19272 HAVE_PSELECT=1;
19273 REPLACE_PSELECT=0;
19274 REPLACE_SELECT=0;
19281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
19282 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
19283 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
19284 $as_echo_n "(cached) " >&6
19285 else
19287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19288 /* end confdefs.h. */
19289 #include <sys/select.h>
19291 main ()
19293 struct timeval b;
19295 return 0;
19297 _ACEOF
19298 if ac_fn_c_try_compile "$LINENO"; then :
19299 gl_cv_header_sys_select_h_selfcontained=yes
19300 else
19301 gl_cv_header_sys_select_h_selfcontained=no
19303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19304 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
19305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19306 /* end confdefs.h. */
19307 #include <sys/select.h>
19309 main ()
19311 int memset; int bzero;
19313 return 0;
19316 _ACEOF
19317 if ac_fn_c_try_compile "$LINENO"; then :
19318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19319 /* end confdefs.h. */
19320 #include <sys/select.h>
19322 main ()
19325 #undef memset
19326 #define memset nonexistent_memset
19327 extern
19328 #ifdef __cplusplus
19330 #endif
19331 void *memset (void *, int, unsigned long);
19332 #undef bzero
19333 #define bzero nonexistent_bzero
19334 extern
19335 #ifdef __cplusplus
19337 #endif
19338 void bzero (void *, unsigned long);
19339 fd_set fds;
19340 FD_ZERO (&fds);
19343 return 0;
19346 _ACEOF
19347 if ac_fn_c_try_link "$LINENO"; then :
19349 else
19350 gl_cv_header_sys_select_h_selfcontained=no
19352 rm -f core conftest.err conftest.$ac_objext \
19353 conftest$ac_exeext conftest.$ac_ext
19356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19361 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19371 if test $gl_cv_have_include_next = yes; then
19372 gl_cv_next_sys_select_h='<'sys/select.h'>'
19373 else
19374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19375 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19376 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19377 $as_echo_n "(cached) " >&6
19378 else
19380 if test $ac_cv_header_sys_select_h = yes; then
19383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19384 /* end confdefs.h. */
19385 #include <sys/select.h>
19387 _ACEOF
19388 case "$host_os" in
19389 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19390 *) gl_absname_cpp="$ac_cpp" ;;
19391 esac
19393 case "$host_os" in
19394 mingw*)
19395 gl_dirsep_regex='[/\\]'
19398 gl_dirsep_regex='\/'
19400 esac
19401 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19403 gl_header_literal_regex=`echo 'sys/select.h' \
19404 | sed -e "$gl_make_literal_regex_sed"`
19405 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19406 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19407 s|^/[^/]|//&|
19411 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19412 sed -n "$gl_absolute_header_sed"`'"'
19413 else
19414 gl_cv_next_sys_select_h='<'sys/select.h'>'
19419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19420 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19422 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19424 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19425 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19426 gl_next_as_first_directive='<'sys/select.h'>'
19427 else
19428 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19429 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19431 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19436 if test $ac_cv_header_sys_select_h = yes; then
19437 HAVE_SYS_SELECT_H=1
19438 else
19439 HAVE_SYS_SELECT_H=0
19446 if test $ac_cv_header_sys_socket_h != yes; then
19447 for ac_header in winsock2.h
19448 do :
19449 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19450 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19451 cat >>confdefs.h <<_ACEOF
19452 #define HAVE_WINSOCK2_H 1
19453 _ACEOF
19457 done
19460 if test "$ac_cv_header_winsock2_h" = yes; then
19461 HAVE_WINSOCK2_H=1
19462 UNISTD_H_HAVE_WINSOCK2_H=1
19463 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19464 else
19465 HAVE_WINSOCK2_H=0
19475 GNULIB_PTHREAD_SIGMASK=0;
19476 GNULIB_RAISE=0;
19477 GNULIB_SIGNAL_H_SIGPIPE=0;
19478 GNULIB_SIGPROCMASK=0;
19479 GNULIB_SIGACTION=0;
19480 HAVE_POSIX_SIGNALBLOCKING=1;
19481 HAVE_PTHREAD_SIGMASK=1;
19482 HAVE_RAISE=1;
19483 HAVE_SIGSET_T=1;
19484 HAVE_SIGINFO_T=1;
19485 HAVE_SIGACTION=1;
19486 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19488 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19490 HAVE_SIGHANDLER_T=1;
19491 REPLACE_PTHREAD_SIGMASK=0;
19492 REPLACE_RAISE=0;
19500 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19501 #include <signal.h>
19502 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19503 #include <sys/types.h>
19506 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19508 cat >>confdefs.h <<_ACEOF
19509 #define HAVE_SIGSET_T 1
19510 _ACEOF
19512 gl_cv_type_sigset_t=yes
19513 else
19514 gl_cv_type_sigset_t=no
19517 if test $gl_cv_type_sigset_t != yes; then
19518 HAVE_SIGSET_T=0
19523 if test $ac_cv_header_sys_socket_h = no; then
19524 for ac_header in ws2tcpip.h
19525 do :
19526 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19527 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19528 cat >>confdefs.h <<_ACEOF
19529 #define HAVE_WS2TCPIP_H 1
19530 _ACEOF
19534 done
19538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19539 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19540 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19541 $as_echo_n "(cached) " >&6
19542 else
19543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19544 /* end confdefs.h. */
19546 #include <stdbool.h>
19547 #ifndef bool
19548 "error: bool is not defined"
19549 #endif
19550 #ifndef false
19551 "error: false is not defined"
19552 #endif
19553 #if false
19554 "error: false is not 0"
19555 #endif
19556 #ifndef true
19557 "error: true is not defined"
19558 #endif
19559 #if true != 1
19560 "error: true is not 1"
19561 #endif
19562 #ifndef __bool_true_false_are_defined
19563 "error: __bool_true_false_are_defined is not defined"
19564 #endif
19566 struct s { _Bool s: 1; _Bool t; } s;
19568 char a[true == 1 ? 1 : -1];
19569 char b[false == 0 ? 1 : -1];
19570 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19571 char d[(bool) 0.5 == true ? 1 : -1];
19572 /* See body of main program for 'e'. */
19573 char f[(_Bool) 0.0 == false ? 1 : -1];
19574 char g[true];
19575 char h[sizeof (_Bool)];
19576 char i[sizeof s.t];
19577 enum { j = false, k = true, l = false * true, m = true * 256 };
19578 /* The following fails for
19579 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19580 _Bool n[m];
19581 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19582 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19583 /* Catch a bug in an HP-UX C compiler. See
19584 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19585 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19587 _Bool q = true;
19588 _Bool *pq = &q;
19591 main ()
19594 bool e = &s;
19595 *pq |= q;
19596 *pq |= ! q;
19597 /* Refer to every declared value, to avoid compiler optimizations. */
19598 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19599 + !m + !n + !o + !p + !q + !pq);
19602 return 0;
19604 _ACEOF
19605 if ac_fn_c_try_compile "$LINENO"; then :
19606 ac_cv_header_stdbool_h=yes
19607 else
19608 ac_cv_header_stdbool_h=no
19610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19613 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19614 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19615 if test "x$ac_cv_type__Bool" = x""yes; then :
19617 cat >>confdefs.h <<_ACEOF
19618 #define HAVE__BOOL 1
19619 _ACEOF
19626 REPLACE_NULL=0;
19627 HAVE_WCHAR_T=1;
19630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19631 $as_echo_n "checking for wchar_t... " >&6; }
19632 if test "${gt_cv_c_wchar_t+set}" = set; then :
19633 $as_echo_n "(cached) " >&6
19634 else
19635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19636 /* end confdefs.h. */
19637 #include <stddef.h>
19638 wchar_t foo = (wchar_t)'\0';
19640 main ()
19644 return 0;
19646 _ACEOF
19647 if ac_fn_c_try_compile "$LINENO"; then :
19648 gt_cv_c_wchar_t=yes
19649 else
19650 gt_cv_c_wchar_t=no
19652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19655 $as_echo "$gt_cv_c_wchar_t" >&6; }
19656 if test $gt_cv_c_wchar_t = yes; then
19658 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19663 GNULIB_DPRINTF=0;
19664 GNULIB_FCLOSE=0;
19665 GNULIB_FDOPEN=0;
19666 GNULIB_FFLUSH=0;
19667 GNULIB_FGETC=0;
19668 GNULIB_FGETS=0;
19669 GNULIB_FOPEN=0;
19670 GNULIB_FPRINTF=0;
19671 GNULIB_FPRINTF_POSIX=0;
19672 GNULIB_FPURGE=0;
19673 GNULIB_FPUTC=0;
19674 GNULIB_FPUTS=0;
19675 GNULIB_FREAD=0;
19676 GNULIB_FREOPEN=0;
19677 GNULIB_FSCANF=0;
19678 GNULIB_FSEEK=0;
19679 GNULIB_FSEEKO=0;
19680 GNULIB_FTELL=0;
19681 GNULIB_FTELLO=0;
19682 GNULIB_FWRITE=0;
19683 GNULIB_GETC=0;
19684 GNULIB_GETCHAR=0;
19685 GNULIB_GETDELIM=0;
19686 GNULIB_GETLINE=0;
19687 GNULIB_OBSTACK_PRINTF=0;
19688 GNULIB_OBSTACK_PRINTF_POSIX=0;
19689 GNULIB_PCLOSE=0;
19690 GNULIB_PERROR=0;
19691 GNULIB_POPEN=0;
19692 GNULIB_PRINTF=0;
19693 GNULIB_PRINTF_POSIX=0;
19694 GNULIB_PUTC=0;
19695 GNULIB_PUTCHAR=0;
19696 GNULIB_PUTS=0;
19697 GNULIB_REMOVE=0;
19698 GNULIB_RENAME=0;
19699 GNULIB_RENAMEAT=0;
19700 GNULIB_SCANF=0;
19701 GNULIB_SNPRINTF=0;
19702 GNULIB_SPRINTF_POSIX=0;
19703 GNULIB_STDIO_H_NONBLOCKING=0;
19704 GNULIB_STDIO_H_SIGPIPE=0;
19705 GNULIB_TMPFILE=0;
19706 GNULIB_VASPRINTF=0;
19707 GNULIB_VFSCANF=0;
19708 GNULIB_VSCANF=0;
19709 GNULIB_VDPRINTF=0;
19710 GNULIB_VFPRINTF=0;
19711 GNULIB_VFPRINTF_POSIX=0;
19712 GNULIB_VPRINTF=0;
19713 GNULIB_VPRINTF_POSIX=0;
19714 GNULIB_VSNPRINTF=0;
19715 GNULIB_VSPRINTF_POSIX=0;
19716 HAVE_DECL_FPURGE=1;
19717 HAVE_DECL_FSEEKO=1;
19718 HAVE_DECL_FTELLO=1;
19719 HAVE_DECL_GETDELIM=1;
19720 HAVE_DECL_GETLINE=1;
19721 HAVE_DECL_OBSTACK_PRINTF=1;
19722 HAVE_DECL_SNPRINTF=1;
19723 HAVE_DECL_VSNPRINTF=1;
19724 HAVE_DPRINTF=1;
19725 HAVE_FSEEKO=1;
19726 HAVE_FTELLO=1;
19727 HAVE_PCLOSE=1;
19728 HAVE_POPEN=1;
19729 HAVE_RENAMEAT=1;
19730 HAVE_VASPRINTF=1;
19731 HAVE_VDPRINTF=1;
19732 REPLACE_DPRINTF=0;
19733 REPLACE_FCLOSE=0;
19734 REPLACE_FDOPEN=0;
19735 REPLACE_FFLUSH=0;
19736 REPLACE_FOPEN=0;
19737 REPLACE_FPRINTF=0;
19738 REPLACE_FPURGE=0;
19739 REPLACE_FREOPEN=0;
19740 REPLACE_FSEEK=0;
19741 REPLACE_FSEEKO=0;
19742 REPLACE_FTELL=0;
19743 REPLACE_FTELLO=0;
19744 REPLACE_GETDELIM=0;
19745 REPLACE_GETLINE=0;
19746 REPLACE_OBSTACK_PRINTF=0;
19747 REPLACE_PERROR=0;
19748 REPLACE_POPEN=0;
19749 REPLACE_PRINTF=0;
19750 REPLACE_REMOVE=0;
19751 REPLACE_RENAME=0;
19752 REPLACE_RENAMEAT=0;
19753 REPLACE_SNPRINTF=0;
19754 REPLACE_SPRINTF=0;
19755 REPLACE_STDIO_READ_FUNCS=0;
19756 REPLACE_STDIO_WRITE_FUNCS=0;
19757 REPLACE_TMPFILE=0;
19758 REPLACE_VASPRINTF=0;
19759 REPLACE_VDPRINTF=0;
19760 REPLACE_VFPRINTF=0;
19761 REPLACE_VPRINTF=0;
19762 REPLACE_VSNPRINTF=0;
19763 REPLACE_VSPRINTF=0;
19765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19766 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19767 if test "${ac_cv_struct_tm+set}" = set; then :
19768 $as_echo_n "(cached) " >&6
19769 else
19770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19771 /* end confdefs.h. */
19772 #include <sys/types.h>
19773 #include <time.h>
19776 main ()
19778 struct tm tm;
19779 int *p = &tm.tm_sec;
19780 return !p;
19782 return 0;
19784 _ACEOF
19785 if ac_fn_c_try_compile "$LINENO"; then :
19786 ac_cv_struct_tm=time.h
19787 else
19788 ac_cv_struct_tm=sys/time.h
19790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19793 $as_echo "$ac_cv_struct_tm" >&6; }
19794 if test $ac_cv_struct_tm = sys/time.h; then
19796 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19800 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19801 #include <$ac_cv_struct_tm>
19804 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19806 cat >>confdefs.h <<_ACEOF
19807 #define HAVE_STRUCT_TM_TM_ZONE 1
19808 _ACEOF
19813 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19815 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19817 else
19818 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19820 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19821 ac_have_decl=1
19822 else
19823 ac_have_decl=0
19826 cat >>confdefs.h <<_ACEOF
19827 #define HAVE_DECL_TZNAME $ac_have_decl
19828 _ACEOF
19830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19831 $as_echo_n "checking for tzname... " >&6; }
19832 if test "${ac_cv_var_tzname+set}" = set; then :
19833 $as_echo_n "(cached) " >&6
19834 else
19835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19836 /* end confdefs.h. */
19837 #include <time.h>
19838 #if !HAVE_DECL_TZNAME
19839 extern char *tzname[];
19840 #endif
19843 main ()
19845 return tzname[0][0];
19847 return 0;
19849 _ACEOF
19850 if ac_fn_c_try_link "$LINENO"; then :
19851 ac_cv_var_tzname=yes
19852 else
19853 ac_cv_var_tzname=no
19855 rm -f core conftest.err conftest.$ac_objext \
19856 conftest$ac_exeext conftest.$ac_ext
19858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19859 $as_echo "$ac_cv_var_tzname" >&6; }
19860 if test $ac_cv_var_tzname = yes; then
19862 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19868 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19870 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19872 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19879 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19880 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19881 ac_have_decl=1
19882 else
19883 ac_have_decl=0
19886 cat >>confdefs.h <<_ACEOF
19887 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19888 _ACEOF
19892 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19893 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19894 ac_have_decl=1
19895 else
19896 ac_have_decl=0
19899 cat >>confdefs.h <<_ACEOF
19900 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19901 _ACEOF
19905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19906 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19907 if test "${ac_cv_header_stat_broken+set}" = set; then :
19908 $as_echo_n "(cached) " >&6
19909 else
19910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19911 /* end confdefs.h. */
19912 #include <sys/types.h>
19913 #include <sys/stat.h>
19915 #if defined S_ISBLK && defined S_IFDIR
19916 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19917 #endif
19919 #if defined S_ISBLK && defined S_IFCHR
19920 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19921 #endif
19923 #if defined S_ISLNK && defined S_IFREG
19924 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19925 #endif
19927 #if defined S_ISSOCK && defined S_IFREG
19928 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19929 #endif
19931 _ACEOF
19932 if ac_fn_c_try_compile "$LINENO"; then :
19933 ac_cv_header_stat_broken=no
19934 else
19935 ac_cv_header_stat_broken=yes
19937 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19940 $as_echo "$ac_cv_header_stat_broken" >&6; }
19941 if test $ac_cv_header_stat_broken = yes; then
19943 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19952 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19953 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19954 $as_echo_n "(cached) " >&6
19955 else
19956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19957 /* end confdefs.h. */
19958 #include <time.h>
19961 main ()
19963 static struct timespec x; x.tv_sec = x.tv_nsec;
19965 return 0;
19967 _ACEOF
19968 if ac_fn_c_try_compile "$LINENO"; then :
19969 gl_cv_sys_struct_timespec_in_time_h=yes
19970 else
19971 gl_cv_sys_struct_timespec_in_time_h=no
19973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19976 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19978 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19979 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19980 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19981 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19982 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19983 else
19984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19985 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19986 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19987 $as_echo_n "(cached) " >&6
19988 else
19989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19990 /* end confdefs.h. */
19991 #include <sys/time.h>
19994 main ()
19996 static struct timespec x; x.tv_sec = x.tv_nsec;
19998 return 0;
20000 _ACEOF
20001 if ac_fn_c_try_compile "$LINENO"; then :
20002 gl_cv_sys_struct_timespec_in_sys_time_h=yes
20003 else
20004 gl_cv_sys_struct_timespec_in_sys_time_h=no
20006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
20009 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
20010 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
20011 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
20012 else
20013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
20014 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
20015 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
20016 $as_echo_n "(cached) " >&6
20017 else
20018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20019 /* end confdefs.h. */
20020 #include <pthread.h>
20023 main ()
20025 static struct timespec x; x.tv_sec = x.tv_nsec;
20027 return 0;
20029 _ACEOF
20030 if ac_fn_c_try_compile "$LINENO"; then :
20031 gl_cv_sys_struct_timespec_in_pthread_h=yes
20032 else
20033 gl_cv_sys_struct_timespec_in_pthread_h=no
20035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
20038 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
20039 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
20040 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
20059 if test $gl_cv_have_include_next = yes; then
20060 gl_cv_next_time_h='<'time.h'>'
20061 else
20062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
20063 $as_echo_n "checking absolute name of <time.h>... " >&6; }
20064 if test "${gl_cv_next_time_h+set}" = set; then :
20065 $as_echo_n "(cached) " >&6
20066 else
20068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20069 /* end confdefs.h. */
20070 #include <time.h>
20072 _ACEOF
20073 case "$host_os" in
20074 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20075 *) gl_absname_cpp="$ac_cpp" ;;
20076 esac
20078 case "$host_os" in
20079 mingw*)
20080 gl_dirsep_regex='[/\\]'
20083 gl_dirsep_regex='\/'
20085 esac
20086 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20088 gl_header_literal_regex=`echo 'time.h' \
20089 | sed -e "$gl_make_literal_regex_sed"`
20090 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20091 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20092 s|^/[^/]|//&|
20096 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20097 sed -n "$gl_absolute_header_sed"`'"'
20101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
20102 $as_echo "$gl_cv_next_time_h" >&6; }
20104 NEXT_TIME_H=$gl_cv_next_time_h
20106 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20107 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20108 gl_next_as_first_directive='<'time.h'>'
20109 else
20110 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20111 gl_next_as_first_directive=$gl_cv_next_time_h
20113 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
20128 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
20129 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
20130 ac_have_decl=1
20131 else
20132 ac_have_decl=0
20135 cat >>confdefs.h <<_ACEOF
20136 #define HAVE_DECL_UNSETENV $ac_have_decl
20137 _ACEOF
20140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
20141 $as_echo_n "checking whether the utimes function works... " >&6; }
20142 if test "${gl_cv_func_working_utimes+set}" = set; then :
20143 $as_echo_n "(cached) " >&6
20144 else
20146 if test "$cross_compiling" = yes; then :
20147 gl_cv_func_working_utimes=no
20148 else
20149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20150 /* end confdefs.h. */
20152 #include <sys/types.h>
20153 #include <sys/stat.h>
20154 #include <fcntl.h>
20155 #include <sys/time.h>
20156 #include <time.h>
20157 #include <unistd.h>
20158 #include <stdlib.h>
20159 #include <stdio.h>
20160 #include <utime.h>
20162 static int
20163 inorder (time_t a, time_t b, time_t c)
20165 return a <= b && b <= c;
20169 main ()
20171 int result = 0;
20172 char const *file = "conftest.utimes";
20173 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
20175 /* Test whether utimes() essentially works. */
20177 struct stat sbuf;
20178 FILE *f = fopen (file, "w");
20179 if (f == NULL)
20180 result |= 1;
20181 else if (fclose (f) != 0)
20182 result |= 1;
20183 else if (utimes (file, timeval) != 0)
20184 result |= 2;
20185 else if (lstat (file, &sbuf) != 0)
20186 result |= 1;
20187 else if (!(sbuf.st_atime == timeval[0].tv_sec
20188 && sbuf.st_mtime == timeval[1].tv_sec))
20189 result |= 4;
20190 if (unlink (file) != 0)
20191 result |= 1;
20194 /* Test whether utimes() with a NULL argument sets the file's timestamp
20195 to the current time. Use 'fstat' as well as 'time' to
20196 determine the "current" time, to accommodate NFS file systems
20197 if there is a time skew between the host and the NFS server. */
20199 int fd = open (file, O_WRONLY|O_CREAT, 0644);
20200 if (fd < 0)
20201 result |= 1;
20202 else
20204 time_t t0, t2;
20205 struct stat st0, st1, st2;
20206 if (time (&t0) == (time_t) -1)
20207 result |= 1;
20208 else if (fstat (fd, &st0) != 0)
20209 result |= 1;
20210 else if (utimes (file, timeval) != 0)
20211 result |= 2;
20212 else if (utimes (file, NULL) != 0)
20213 result |= 8;
20214 else if (fstat (fd, &st1) != 0)
20215 result |= 1;
20216 else if (write (fd, "\n", 1) != 1)
20217 result |= 1;
20218 else if (fstat (fd, &st2) != 0)
20219 result |= 1;
20220 else if (time (&t2) == (time_t) -1)
20221 result |= 1;
20222 else
20224 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
20225 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
20226 if (! (st1.st_atime == st1.st_mtime))
20227 result |= 16;
20228 if (! (m_ok_POSIX || m_ok_NFS))
20229 result |= 32;
20231 if (close (fd) != 0)
20232 result |= 1;
20234 if (unlink (file) != 0)
20235 result |= 1;
20238 /* Test whether utimes() with a NULL argument works on read-only files. */
20240 int fd = open (file, O_WRONLY|O_CREAT, 0444);
20241 if (fd < 0)
20242 result |= 1;
20243 else if (close (fd) != 0)
20244 result |= 1;
20245 else if (utimes (file, NULL) != 0)
20246 result |= 64;
20247 if (unlink (file) != 0)
20248 result |= 1;
20251 return result;
20254 _ACEOF
20255 if ac_fn_c_try_run "$LINENO"; then :
20256 gl_cv_func_working_utimes=yes
20257 else
20258 gl_cv_func_working_utimes=no
20260 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20261 conftest.$ac_objext conftest.beam conftest.$ac_ext
20265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
20266 $as_echo "$gl_cv_func_working_utimes" >&6; }
20268 if test $gl_cv_func_working_utimes = yes; then
20270 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
20278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
20279 $as_echo_n "checking for struct utimbuf... " >&6; }
20280 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
20281 $as_echo_n "(cached) " >&6
20282 else
20283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20284 /* end confdefs.h. */
20285 #if HAVE_SYS_TIME_H
20286 #include <sys/time.h>
20287 #endif
20288 #include <time.h>
20289 #ifdef HAVE_UTIME_H
20290 #include <utime.h>
20291 #endif
20294 main ()
20296 static struct utimbuf x; x.actime = x.modtime;
20298 return 0;
20300 _ACEOF
20301 if ac_fn_c_try_compile "$LINENO"; then :
20302 gl_cv_sys_struct_utimbuf=yes
20303 else
20304 gl_cv_sys_struct_utimbuf=no
20306 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
20309 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
20311 if test $gl_cv_sys_struct_utimbuf = yes; then
20313 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
20327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
20328 $as_echo_n "checking type of array argument to getgroups... " >&6; }
20329 if test "${ac_cv_type_getgroups+set}" = set; then :
20330 $as_echo_n "(cached) " >&6
20331 else
20332 if test "$cross_compiling" = yes; then :
20333 ac_cv_type_getgroups=cross
20334 else
20335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20336 /* end confdefs.h. */
20337 /* Thanks to Mike Rendell for this test. */
20338 $ac_includes_default
20339 #define NGID 256
20340 #undef MAX
20341 #define MAX(x, y) ((x) > (y) ? (x) : (y))
20344 main ()
20346 gid_t gidset[NGID];
20347 int i, n;
20348 union { gid_t gval; long int lval; } val;
20350 val.lval = -1;
20351 for (i = 0; i < NGID; i++)
20352 gidset[i] = val.gval;
20353 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
20354 gidset);
20355 /* Exit non-zero if getgroups seems to require an array of ints. This
20356 happens when gid_t is short int but getgroups modifies an array
20357 of ints. */
20358 return n > 0 && gidset[n] != val.gval;
20360 _ACEOF
20361 if ac_fn_c_try_run "$LINENO"; then :
20362 ac_cv_type_getgroups=gid_t
20363 else
20364 ac_cv_type_getgroups=int
20366 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20367 conftest.$ac_objext conftest.beam conftest.$ac_ext
20370 if test $ac_cv_type_getgroups = cross; then
20371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20372 /* end confdefs.h. */
20373 #include <unistd.h>
20375 _ACEOF
20376 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20377 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
20378 ac_cv_type_getgroups=gid_t
20379 else
20380 ac_cv_type_getgroups=int
20382 rm -f conftest*
20386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
20387 $as_echo "$ac_cv_type_getgroups" >&6; }
20389 cat >>confdefs.h <<_ACEOF
20390 #define GETGROUPS_T $ac_cv_type_getgroups
20391 _ACEOF
20396 if false; then
20397 GL_COND_LIBTOOL_TRUE=
20398 GL_COND_LIBTOOL_FALSE='#'
20399 else
20400 GL_COND_LIBTOOL_TRUE='#'
20401 GL_COND_LIBTOOL_FALSE=
20404 gl_cond_libtool=false
20405 gl_libdeps=
20406 gl_ltlibdeps=
20407 gl_m4_base='m4'
20417 gl_source_base='lib'
20420 if test $ac_cv_func_alloca_works = no; then
20424 # Define an additional variable used in the Makefile substitution.
20425 if test $ac_cv_working_alloca_h = yes; then
20426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20427 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20428 if test "${gl_cv_rpl_alloca+set}" = set; then :
20429 $as_echo_n "(cached) " >&6
20430 else
20432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20433 /* end confdefs.h. */
20435 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20436 Need own alloca
20437 #endif
20439 _ACEOF
20440 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20441 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20442 gl_cv_rpl_alloca=yes
20443 else
20444 gl_cv_rpl_alloca=no
20446 rm -f conftest*
20450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20451 $as_echo "$gl_cv_rpl_alloca" >&6; }
20452 if test $gl_cv_rpl_alloca = yes; then
20454 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20456 ALLOCA_H=alloca.h
20457 else
20458 ALLOCA_H=
20460 else
20461 ALLOCA_H=alloca.h
20464 if test -n "$ALLOCA_H"; then
20465 GL_GENERATE_ALLOCA_H_TRUE=
20466 GL_GENERATE_ALLOCA_H_FALSE='#'
20467 else
20468 GL_GENERATE_ALLOCA_H_TRUE='#'
20469 GL_GENERATE_ALLOCA_H_FALSE=
20477 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20478 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20480 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20481 # programs in the package would end up linked with that potentially-shared
20482 # library, inducing unnecessary run-time overhead.
20483 LIB_CLOCK_GETTIME=
20485 gl_saved_libs=$LIBS
20486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20487 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20488 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20489 $as_echo_n "(cached) " >&6
20490 else
20491 ac_func_search_save_LIBS=$LIBS
20492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20493 /* end confdefs.h. */
20495 /* Override any GCC internal prototype to avoid an error.
20496 Use char because int might match the return type of a GCC
20497 builtin and then its argument prototype would still apply. */
20498 #ifdef __cplusplus
20499 extern "C"
20500 #endif
20501 char clock_gettime ();
20503 main ()
20505 return clock_gettime ();
20507 return 0;
20509 _ACEOF
20510 for ac_lib in '' rt posix4; do
20511 if test -z "$ac_lib"; then
20512 ac_res="none required"
20513 else
20514 ac_res=-l$ac_lib
20515 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20517 if ac_fn_c_try_link "$LINENO"; then :
20518 ac_cv_search_clock_gettime=$ac_res
20520 rm -f core conftest.err conftest.$ac_objext \
20521 conftest$ac_exeext
20522 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20523 break
20525 done
20526 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20528 else
20529 ac_cv_search_clock_gettime=no
20531 rm conftest.$ac_ext
20532 LIBS=$ac_func_search_save_LIBS
20534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20535 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20536 ac_res=$ac_cv_search_clock_gettime
20537 if test "$ac_res" != no; then :
20538 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20539 test "$ac_cv_search_clock_gettime" = "none required" ||
20540 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20543 for ac_func in clock_gettime clock_settime
20544 do :
20545 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20546 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20547 eval as_val=\$$as_ac_var
20548 if test "x$as_val" = x""yes; then :
20549 cat >>confdefs.h <<_ACEOF
20550 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20551 _ACEOF
20554 done
20556 LIBS=$gl_saved_libs
20563 cat >>confdefs.h <<_ACEOF
20564 #define GNULIB_CLOSE_STREAM 1
20565 _ACEOF
20588 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20591 if test $HAVE_DUP2 = 1; then
20592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20593 $as_echo_n "checking whether dup2 works... " >&6; }
20594 if test "${gl_cv_func_dup2_works+set}" = set; then :
20595 $as_echo_n "(cached) " >&6
20596 else
20597 if test "$cross_compiling" = yes; then :
20598 case "$host_os" in
20599 mingw*) # on this platform, dup2 always returns 0 for success
20600 gl_cv_func_dup2_works="guessing no" ;;
20601 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20602 gl_cv_func_dup2_works="guessing no" ;;
20603 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20604 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20605 gl_cv_func_dup2_works="guessing no" ;;
20606 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20607 gl_cv_func_dup2_works="guessing no" ;;
20608 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20609 gl_cv_func_dup2_works="guessing no" ;;
20610 *) gl_cv_func_dup2_works="guessing yes" ;;
20611 esac
20612 else
20613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20614 /* end confdefs.h. */
20616 #include <unistd.h>
20617 #include <fcntl.h>
20618 #include <errno.h>
20620 main ()
20622 int result = 0;
20623 #ifdef FD_CLOEXEC
20624 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20625 result |= 1;
20626 #endif
20627 if (dup2 (1, 1) == 0)
20628 result |= 2;
20629 #ifdef FD_CLOEXEC
20630 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20631 result |= 4;
20632 #endif
20633 close (0);
20634 if (dup2 (0, 0) != -1)
20635 result |= 8;
20636 /* Many gnulib modules require POSIX conformance of EBADF. */
20637 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20638 result |= 16;
20639 return result;
20642 return 0;
20645 _ACEOF
20646 if ac_fn_c_try_run "$LINENO"; then :
20647 gl_cv_func_dup2_works=yes
20648 else
20649 gl_cv_func_dup2_works=no
20651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20652 conftest.$ac_objext conftest.beam conftest.$ac_ext
20657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20658 $as_echo "$gl_cv_func_dup2_works" >&6; }
20659 case "$gl_cv_func_dup2_works" in
20660 *yes) ;;
20662 REPLACE_DUP2=1
20664 esac
20668 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20677 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20686 GNULIB_DUP2=1
20698 GNULIB_ENVIRON=1
20707 LIB_EXECINFO=''
20708 EXECINFO_H='execinfo.h'
20710 if test $ac_cv_header_execinfo_h = yes; then
20711 gl_saved_libs=$LIBS
20712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20713 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20714 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20715 $as_echo_n "(cached) " >&6
20716 else
20717 ac_func_search_save_LIBS=$LIBS
20718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20719 /* end confdefs.h. */
20721 /* Override any GCC internal prototype to avoid an error.
20722 Use char because int might match the return type of a GCC
20723 builtin and then its argument prototype would still apply. */
20724 #ifdef __cplusplus
20725 extern "C"
20726 #endif
20727 char backtrace_symbols_fd ();
20729 main ()
20731 return backtrace_symbols_fd ();
20733 return 0;
20735 _ACEOF
20736 for ac_lib in '' execinfo; do
20737 if test -z "$ac_lib"; then
20738 ac_res="none required"
20739 else
20740 ac_res=-l$ac_lib
20741 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20743 if ac_fn_c_try_link "$LINENO"; then :
20744 ac_cv_search_backtrace_symbols_fd=$ac_res
20746 rm -f core conftest.err conftest.$ac_objext \
20747 conftest$ac_exeext
20748 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20749 break
20751 done
20752 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20754 else
20755 ac_cv_search_backtrace_symbols_fd=no
20757 rm conftest.$ac_ext
20758 LIBS=$ac_func_search_save_LIBS
20760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20761 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20762 ac_res=$ac_cv_search_backtrace_symbols_fd
20763 if test "$ac_res" != no; then :
20764 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20765 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20766 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20769 LIBS=$gl_saved_libs
20770 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20773 if test -n "$EXECINFO_H"; then
20782 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20788 if test -n "$EXECINFO_H"; then
20789 GL_GENERATE_EXECINFO_H_TRUE=
20790 GL_GENERATE_EXECINFO_H_FALSE='#'
20791 else
20792 GL_GENERATE_EXECINFO_H_TRUE='#'
20793 GL_GENERATE_EXECINFO_H_FALSE=
20804 if test $ac_cv_func_faccessat = no; then
20805 HAVE_FACCESSAT=0
20808 if test $HAVE_FACCESSAT = 0; then
20817 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
20820 for ac_func in access
20821 do :
20822 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
20823 if test "x$ac_cv_func_access" = x""yes; then :
20824 cat >>confdefs.h <<_ACEOF
20825 #define HAVE_ACCESS 1
20826 _ACEOF
20829 done
20835 cat >>confdefs.h <<_ACEOF
20836 #define GNULIB_FACCESSAT 1
20837 _ACEOF
20845 GNULIB_FACCESSAT=1
20862 if test $gl_cv_have_include_next = yes; then
20863 gl_cv_next_fcntl_h='<'fcntl.h'>'
20864 else
20865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
20866 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
20867 if test "${gl_cv_next_fcntl_h+set}" = set; then :
20868 $as_echo_n "(cached) " >&6
20869 else
20871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20872 /* end confdefs.h. */
20873 #include <fcntl.h>
20875 _ACEOF
20876 case "$host_os" in
20877 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20878 *) gl_absname_cpp="$ac_cpp" ;;
20879 esac
20881 case "$host_os" in
20882 mingw*)
20883 gl_dirsep_regex='[/\\]'
20886 gl_dirsep_regex='\/'
20888 esac
20889 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20891 gl_header_literal_regex=`echo 'fcntl.h' \
20892 | sed -e "$gl_make_literal_regex_sed"`
20893 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20894 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20895 s|^/[^/]|//&|
20899 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20900 sed -n "$gl_absolute_header_sed"`'"'
20904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
20905 $as_echo "$gl_cv_next_fcntl_h" >&6; }
20907 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
20909 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20910 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20911 gl_next_as_first_directive='<'fcntl.h'>'
20912 else
20913 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20914 gl_next_as_first_directive=$gl_cv_next_fcntl_h
20916 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
20935 fp_headers='
20936 # include <stdio.h>
20937 # if HAVE_STDIO_EXT_H
20938 # include <stdio_ext.h>
20939 # endif
20941 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
20943 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
20944 ac_have_decl=1
20945 else
20946 ac_have_decl=0
20949 cat >>confdefs.h <<_ACEOF
20950 #define HAVE_DECL___FPENDING $ac_have_decl
20951 _ACEOF
20954 if test $ac_cv_func___fpending = no; then
20963 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
20966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
20967 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
20968 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
20969 $as_echo_n "(cached) " >&6
20970 else
20972 for ac_expr in \
20974 '# glibc2' \
20975 'fp->_IO_write_ptr - fp->_IO_write_base' \
20977 '# traditional Unix' \
20978 'fp->_ptr - fp->_base' \
20980 '# BSD' \
20981 'fp->_p - fp->_bf._base' \
20983 '# SCO, Unixware' \
20984 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
20986 '# QNX' \
20987 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
20989 '# old glibc?' \
20990 'fp->__bufp - fp->__buffer' \
20992 '# old glibc iostream?' \
20993 'fp->_pptr - fp->_pbase' \
20995 '# emx+gcc' \
20996 'fp->_ptr - fp->_buffer' \
20998 '# Minix' \
20999 'fp->_ptr - fp->_buf' \
21001 '# Plan9' \
21002 'fp->wp - fp->buf' \
21004 '# VMS' \
21005 '(*fp)->_ptr - (*fp)->_base' \
21007 '# e.g., DGUX R4.11; the info is not available' \
21009 ; do
21011 # Skip each embedded comment.
21012 case "$ac_expr" in '#'*) continue;; esac
21014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21015 /* end confdefs.h. */
21016 #include <stdio.h>
21018 main ()
21020 FILE *fp = stdin; (void) ($ac_expr);
21022 return 0;
21024 _ACEOF
21025 if ac_fn_c_try_compile "$LINENO"; then :
21026 fp_done=yes
21029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21030 test "$fp_done" = yes && break
21031 done
21033 ac_cv_sys_pending_output_n_bytes=$ac_expr
21037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
21038 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
21040 cat >>confdefs.h <<_ACEOF
21041 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
21042 _ACEOF
21048 # Persuade glibc <stdlib.h> to declare getloadavg().
21051 gl_save_LIBS=$LIBS
21053 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
21054 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
21055 HAVE_GETLOADAVG=1
21056 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
21057 if test "x$ac_cv_func_getloadavg" = x""yes; then :
21059 else
21060 gl_func_getloadavg_done=no
21062 # Some systems with -lutil have (and need) -lkvm as well, some do not.
21063 # On Solaris, -lkvm requires nlist from -lelf, so check that first
21064 # to get the right answer into the cache.
21065 # For kstat on solaris, we need to test for libelf and libkvm to force the
21066 # definition of SVR4 below.
21067 if test $gl_func_getloadavg_done = no; then
21068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
21069 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
21070 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
21071 $as_echo_n "(cached) " >&6
21072 else
21073 ac_check_lib_save_LIBS=$LIBS
21074 LIBS="-lelf $LIBS"
21075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21076 /* end confdefs.h. */
21078 /* Override any GCC internal prototype to avoid an error.
21079 Use char because int might match the return type of a GCC
21080 builtin and then its argument prototype would still apply. */
21081 #ifdef __cplusplus
21082 extern "C"
21083 #endif
21084 char elf_begin ();
21086 main ()
21088 return elf_begin ();
21090 return 0;
21092 _ACEOF
21093 if ac_fn_c_try_link "$LINENO"; then :
21094 ac_cv_lib_elf_elf_begin=yes
21095 else
21096 ac_cv_lib_elf_elf_begin=no
21098 rm -f core conftest.err conftest.$ac_objext \
21099 conftest$ac_exeext conftest.$ac_ext
21100 LIBS=$ac_check_lib_save_LIBS
21102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
21103 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
21104 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
21105 LIBS="-lelf $LIBS"
21108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
21109 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
21110 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
21111 $as_echo_n "(cached) " >&6
21112 else
21113 ac_check_lib_save_LIBS=$LIBS
21114 LIBS="-lkvm $LIBS"
21115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21116 /* end confdefs.h. */
21118 /* Override any GCC internal prototype to avoid an error.
21119 Use char because int might match the return type of a GCC
21120 builtin and then its argument prototype would still apply. */
21121 #ifdef __cplusplus
21122 extern "C"
21123 #endif
21124 char kvm_open ();
21126 main ()
21128 return kvm_open ();
21130 return 0;
21132 _ACEOF
21133 if ac_fn_c_try_link "$LINENO"; then :
21134 ac_cv_lib_kvm_kvm_open=yes
21135 else
21136 ac_cv_lib_kvm_kvm_open=no
21138 rm -f core conftest.err conftest.$ac_objext \
21139 conftest$ac_exeext conftest.$ac_ext
21140 LIBS=$ac_check_lib_save_LIBS
21142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
21143 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
21144 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
21145 LIBS="-lkvm $LIBS"
21148 # Check for the 4.4BSD definition of getloadavg.
21149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
21150 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
21151 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
21152 $as_echo_n "(cached) " >&6
21153 else
21154 ac_check_lib_save_LIBS=$LIBS
21155 LIBS="-lutil $LIBS"
21156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21157 /* end confdefs.h. */
21159 /* Override any GCC internal prototype to avoid an error.
21160 Use char because int might match the return type of a GCC
21161 builtin and then its argument prototype would still apply. */
21162 #ifdef __cplusplus
21163 extern "C"
21164 #endif
21165 char getloadavg ();
21167 main ()
21169 return getloadavg ();
21171 return 0;
21173 _ACEOF
21174 if ac_fn_c_try_link "$LINENO"; then :
21175 ac_cv_lib_util_getloadavg=yes
21176 else
21177 ac_cv_lib_util_getloadavg=no
21179 rm -f core conftest.err conftest.$ac_objext \
21180 conftest$ac_exeext conftest.$ac_ext
21181 LIBS=$ac_check_lib_save_LIBS
21183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
21184 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
21185 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
21186 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
21191 if test $gl_func_getloadavg_done = no; then
21192 # There is a commonly available library for RS/6000 AIX.
21193 # Since it is not a standard part of AIX, it might be installed locally.
21194 gl_getloadavg_LIBS=$LIBS
21195 LIBS="-L/usr/local/lib $LIBS"
21196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
21197 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
21198 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
21199 $as_echo_n "(cached) " >&6
21200 else
21201 ac_check_lib_save_LIBS=$LIBS
21202 LIBS="-lgetloadavg $LIBS"
21203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21204 /* end confdefs.h. */
21206 /* Override any GCC internal prototype to avoid an error.
21207 Use char because int might match the return type of a GCC
21208 builtin and then its argument prototype would still apply. */
21209 #ifdef __cplusplus
21210 extern "C"
21211 #endif
21212 char getloadavg ();
21214 main ()
21216 return getloadavg ();
21218 return 0;
21220 _ACEOF
21221 if ac_fn_c_try_link "$LINENO"; then :
21222 ac_cv_lib_getloadavg_getloadavg=yes
21223 else
21224 ac_cv_lib_getloadavg_getloadavg=no
21226 rm -f core conftest.err conftest.$ac_objext \
21227 conftest$ac_exeext conftest.$ac_ext
21228 LIBS=$ac_check_lib_save_LIBS
21230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
21231 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
21232 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
21233 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
21234 else
21235 LIBS=$gl_getloadavg_LIBS
21240 # Set up the replacement function if necessary.
21241 if test $gl_func_getloadavg_done = no; then
21242 HAVE_GETLOADAVG=0
21244 # Solaris has libkstat which does not require root.
21245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
21246 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
21247 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
21248 $as_echo_n "(cached) " >&6
21249 else
21250 ac_check_lib_save_LIBS=$LIBS
21251 LIBS="-lkstat $LIBS"
21252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21253 /* end confdefs.h. */
21255 /* Override any GCC internal prototype to avoid an error.
21256 Use char because int might match the return type of a GCC
21257 builtin and then its argument prototype would still apply. */
21258 #ifdef __cplusplus
21259 extern "C"
21260 #endif
21261 char kstat_open ();
21263 main ()
21265 return kstat_open ();
21267 return 0;
21269 _ACEOF
21270 if ac_fn_c_try_link "$LINENO"; then :
21271 ac_cv_lib_kstat_kstat_open=yes
21272 else
21273 ac_cv_lib_kstat_kstat_open=no
21275 rm -f core conftest.err conftest.$ac_objext \
21276 conftest$ac_exeext conftest.$ac_ext
21277 LIBS=$ac_check_lib_save_LIBS
21279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
21280 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
21281 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
21282 cat >>confdefs.h <<_ACEOF
21283 #define HAVE_LIBKSTAT 1
21284 _ACEOF
21286 LIBS="-lkstat $LIBS"
21290 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
21292 # AIX has libperfstat which does not require root
21293 if test $gl_func_getloadavg_done = no; then
21294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
21295 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
21296 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
21297 $as_echo_n "(cached) " >&6
21298 else
21299 ac_check_lib_save_LIBS=$LIBS
21300 LIBS="-lperfstat $LIBS"
21301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21302 /* end confdefs.h. */
21304 /* Override any GCC internal prototype to avoid an error.
21305 Use char because int might match the return type of a GCC
21306 builtin and then its argument prototype would still apply. */
21307 #ifdef __cplusplus
21308 extern "C"
21309 #endif
21310 char perfstat_cpu_total ();
21312 main ()
21314 return perfstat_cpu_total ();
21316 return 0;
21318 _ACEOF
21319 if ac_fn_c_try_link "$LINENO"; then :
21320 ac_cv_lib_perfstat_perfstat_cpu_total=yes
21321 else
21322 ac_cv_lib_perfstat_perfstat_cpu_total=no
21324 rm -f core conftest.err conftest.$ac_objext \
21325 conftest$ac_exeext conftest.$ac_ext
21326 LIBS=$ac_check_lib_save_LIBS
21328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
21329 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
21330 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
21331 cat >>confdefs.h <<_ACEOF
21332 #define HAVE_LIBPERFSTAT 1
21333 _ACEOF
21335 LIBS="-lperfstat $LIBS"
21339 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
21342 if test $gl_func_getloadavg_done = no; then
21343 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
21344 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
21345 gl_func_getloadavg_done=yes
21347 $as_echo "#define DGUX 1" >>confdefs.h
21349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
21350 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
21351 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
21352 $as_echo_n "(cached) " >&6
21353 else
21354 ac_check_lib_save_LIBS=$LIBS
21355 LIBS="-ldgc $LIBS"
21356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21357 /* end confdefs.h. */
21359 /* Override any GCC internal prototype to avoid an error.
21360 Use char because int might match the return type of a GCC
21361 builtin and then its argument prototype would still apply. */
21362 #ifdef __cplusplus
21363 extern "C"
21364 #endif
21365 char dg_sys_info ();
21367 main ()
21369 return dg_sys_info ();
21371 return 0;
21373 _ACEOF
21374 if ac_fn_c_try_link "$LINENO"; then :
21375 ac_cv_lib_dgc_dg_sys_info=yes
21376 else
21377 ac_cv_lib_dgc_dg_sys_info=no
21379 rm -f core conftest.err conftest.$ac_objext \
21380 conftest$ac_exeext conftest.$ac_ext
21381 LIBS=$ac_check_lib_save_LIBS
21383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
21384 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
21385 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
21386 cat >>confdefs.h <<_ACEOF
21387 #define HAVE_LIBDGC 1
21388 _ACEOF
21390 LIBS="-ldgc $LIBS"
21402 if test "x$gl_save_LIBS" = x; then
21403 GETLOADAVG_LIBS=$LIBS
21404 else
21405 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
21407 LIBS=$gl_save_LIBS
21410 # Test whether the system declares getloadavg. Solaris has the function
21411 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
21412 for ac_header in sys/loadavg.h
21413 do :
21414 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
21415 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
21416 cat >>confdefs.h <<_ACEOF
21417 #define HAVE_SYS_LOADAVG_H 1
21418 _ACEOF
21422 done
21424 if test $ac_cv_header_sys_loadavg_h = yes; then
21425 HAVE_SYS_LOADAVG_H=1
21426 else
21427 HAVE_SYS_LOADAVG_H=0
21429 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
21430 # include <sys/loadavg.h>
21431 #endif
21432 #include <stdlib.h>
21434 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
21436 else
21437 HAVE_DECL_GETLOADAVG=0
21441 if test $HAVE_GETLOADAVG = 0; then
21450 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
21453 # Figure out what our getloadavg.c needs.
21457 # On HPUX9, an unprivileged user can get load averages this way.
21458 if test $gl_func_getloadavg_done = no; then
21459 for ac_func in pstat_getdynamic
21460 do :
21461 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
21462 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
21463 cat >>confdefs.h <<_ACEOF
21464 #define HAVE_PSTAT_GETDYNAMIC 1
21465 _ACEOF
21466 gl_func_getloadavg_done=yes
21468 done
21472 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
21473 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
21474 # Irix 4.0.5F has the header but not the library.
21475 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
21476 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
21477 gl_func_getloadavg_done=yes
21479 $as_echo "#define SVR4 1" >>confdefs.h
21483 if test $gl_func_getloadavg_done = no; then
21484 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
21485 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
21486 gl_func_getloadavg_done=yes
21488 $as_echo "#define UMAX 1" >>confdefs.h
21491 $as_echo "#define UMAX4_3 1" >>confdefs.h
21498 if test $gl_func_getloadavg_done = no; then
21499 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
21500 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
21501 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
21508 if test $gl_func_getloadavg_done = no; then
21509 for ac_header in mach/mach.h
21510 do :
21511 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
21512 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
21513 cat >>confdefs.h <<_ACEOF
21514 #define HAVE_MACH_MACH_H 1
21515 _ACEOF
21519 done
21523 for ac_header in nlist.h
21524 do :
21525 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
21526 if test "x$ac_cv_header_nlist_h" = x""yes; then :
21527 cat >>confdefs.h <<_ACEOF
21528 #define HAVE_NLIST_H 1
21529 _ACEOF
21530 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
21532 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
21534 cat >>confdefs.h <<_ACEOF
21535 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
21536 _ACEOF
21541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21542 /* end confdefs.h. */
21543 #include <nlist.h>
21545 main ()
21547 struct nlist x;
21548 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
21549 x.n_un.n_name = "";
21550 #else
21551 x.n_name = "";
21552 #endif
21554 return 0;
21556 _ACEOF
21557 if ac_fn_c_try_link "$LINENO"; then :
21559 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
21562 rm -f core conftest.err conftest.$ac_objext \
21563 conftest$ac_exeext conftest.$ac_ext
21567 done
21575 GNULIB_GETLOADAVG=1
21586 if test $REPLACE_GETOPT = 1; then
21595 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21605 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21610 GNULIB_GL_UNISTD_H_GETOPT=1
21619 REPLACE_GETOPT=0
21620 if test -n "$gl_replace_getopt"; then
21621 REPLACE_GETOPT=1
21624 if test $REPLACE_GETOPT = 1; then
21626 GETOPT_H=getopt.h
21628 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
21634 if test $REPLACE_GETOPT = 1; then
21643 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21653 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21658 GNULIB_GL_UNISTD_H_GETOPT=1
21672 gl_gettimeofday_timezone=void
21673 if test $ac_cv_func_gettimeofday != yes; then
21674 HAVE_GETTIMEOFDAY=0
21675 else
21679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21680 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21681 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21682 $as_echo_n "(cached) " >&6
21683 else
21684 if test "$cross_compiling" = yes; then :
21685 # When cross-compiling:
21686 case "$host_os" in
21687 # Guess all is fine on glibc systems.
21688 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21689 # If we don't know, assume the worst.
21690 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21691 esac
21693 else
21694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21695 /* end confdefs.h. */
21696 #include <string.h>
21697 #include <sys/time.h>
21698 #include <time.h>
21699 #include <stdlib.h>
21702 main ()
21705 time_t t = 0;
21706 struct tm *lt;
21707 struct tm saved_lt;
21708 struct timeval tv;
21709 lt = localtime (&t);
21710 saved_lt = *lt;
21711 gettimeofday (&tv, NULL);
21712 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21715 return 0;
21717 _ACEOF
21718 if ac_fn_c_try_run "$LINENO"; then :
21719 gl_cv_func_gettimeofday_clobber=no
21720 else
21721 gl_cv_func_gettimeofday_clobber=yes
21723 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21724 conftest.$ac_objext conftest.beam conftest.$ac_ext
21728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21729 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21731 case "$gl_cv_func_gettimeofday_clobber" in
21732 *yes)
21733 REPLACE_GETTIMEOFDAY=1
21736 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21739 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21743 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21746 esac
21748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21749 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21750 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21751 $as_echo_n "(cached) " >&6
21752 else
21753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21754 /* end confdefs.h. */
21755 #include <sys/time.h>
21756 struct timeval c;
21757 int gettimeofday (struct timeval *restrict, void *restrict);
21760 main ()
21762 /* glibc uses struct timezone * rather than the POSIX void *
21763 if _GNU_SOURCE is defined. However, since the only portable
21764 use of gettimeofday uses NULL as the second parameter, and
21765 since the glibc definition is actually more typesafe, it is
21766 not worth wrapping this to get a compliant signature. */
21767 int (*f) (struct timeval *restrict, void *restrict)
21768 = gettimeofday;
21769 int x = f (&c, 0);
21770 return !(x | c.tv_sec | c.tv_usec);
21773 return 0;
21775 _ACEOF
21776 if ac_fn_c_try_compile "$LINENO"; then :
21777 gl_cv_func_gettimeofday_posix_signature=yes
21778 else
21779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21780 /* end confdefs.h. */
21781 #include <sys/time.h>
21782 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21785 main ()
21789 return 0;
21791 _ACEOF
21792 if ac_fn_c_try_compile "$LINENO"; then :
21793 gl_cv_func_gettimeofday_posix_signature=almost
21794 else
21795 gl_cv_func_gettimeofday_posix_signature=no
21797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21802 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21803 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21804 gl_gettimeofday_timezone='struct timezone'
21805 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21806 REPLACE_GETTIMEOFDAY=1
21808 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21809 REPLACE_GETTIMEOFDAY=1
21814 cat >>confdefs.h <<_ACEOF
21815 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21816 _ACEOF
21819 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21828 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21831 for ac_header in sys/timeb.h
21832 do :
21833 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21834 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21835 cat >>confdefs.h <<_ACEOF
21836 #define HAVE_SYS_TIMEB_H 1
21837 _ACEOF
21841 done
21843 for ac_func in _ftime
21844 do :
21845 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21846 if test "x$ac_cv_func__ftime" = x""yes; then :
21847 cat >>confdefs.h <<_ACEOF
21848 #define HAVE__FTIME 1
21849 _ACEOF
21852 done
21861 GNULIB_GETTIMEOFDAY=1
21872 if test $ac_cv_func_lstat = yes; then
21874 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21875 *no)
21876 REPLACE_LSTAT=1
21878 esac
21879 else
21880 HAVE_LSTAT=0
21883 if test $REPLACE_LSTAT = 1; then
21892 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21901 GNULIB_LSTAT=1
21913 if test $APPLE_UNIVERSAL_BUILD = 1; then
21914 # A universal build on Apple Mac OS X platforms.
21915 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21916 # But we need a configuration result that is valid in both modes.
21917 gl_cv_func_working_mktime=no
21919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21920 $as_echo_n "checking for working mktime... " >&6; }
21921 if test "${gl_cv_func_working_mktime+set}" = set; then :
21922 $as_echo_n "(cached) " >&6
21923 else
21924 if test "$cross_compiling" = yes; then :
21925 gl_cv_func_working_mktime=no
21926 else
21927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21928 /* end confdefs.h. */
21929 /* Test program from Paul Eggert and Tony Leneis. */
21930 #include <limits.h>
21931 #include <stdlib.h>
21932 #include <time.h>
21934 #ifdef HAVE_UNISTD_H
21935 # include <unistd.h>
21936 #endif
21938 #ifndef HAVE_ALARM
21939 # define alarm(X) /* empty */
21940 #endif
21942 /* Work around redefinition to rpl_putenv by other config tests. */
21943 #undef putenv
21945 static time_t time_t_max;
21946 static time_t time_t_min;
21948 /* Values we'll use to set the TZ environment variable. */
21949 static char *tz_strings[] = {
21950 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21951 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21953 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21955 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21956 Based on a problem report from Andreas Jaeger. */
21957 static int
21958 spring_forward_gap ()
21960 /* glibc (up to about 1998-10-07) failed this test. */
21961 struct tm tm;
21963 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21964 instead of "TZ=America/Vancouver" in order to detect the bug even
21965 on systems that don't support the Olson extension, or don't have the
21966 full zoneinfo tables installed. */
21967 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21969 tm.tm_year = 98;
21970 tm.tm_mon = 3;
21971 tm.tm_mday = 5;
21972 tm.tm_hour = 2;
21973 tm.tm_min = 0;
21974 tm.tm_sec = 0;
21975 tm.tm_isdst = -1;
21976 return mktime (&tm) != (time_t) -1;
21979 static int
21980 mktime_test1 (time_t now)
21982 struct tm *lt;
21983 return ! (lt = localtime (&now)) || mktime (lt) == now;
21986 static int
21987 mktime_test (time_t now)
21989 return (mktime_test1 (now)
21990 && mktime_test1 ((time_t) (time_t_max - now))
21991 && mktime_test1 ((time_t) (time_t_min + now)));
21994 static int
21995 irix_6_4_bug ()
21997 /* Based on code from Ariel Faigon. */
21998 struct tm tm;
21999 tm.tm_year = 96;
22000 tm.tm_mon = 3;
22001 tm.tm_mday = 0;
22002 tm.tm_hour = 0;
22003 tm.tm_min = 0;
22004 tm.tm_sec = 0;
22005 tm.tm_isdst = -1;
22006 mktime (&tm);
22007 return tm.tm_mon == 2 && tm.tm_mday == 31;
22010 static int
22011 bigtime_test (int j)
22013 struct tm tm;
22014 time_t now;
22015 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
22016 now = mktime (&tm);
22017 if (now != (time_t) -1)
22019 struct tm *lt = localtime (&now);
22020 if (! (lt
22021 && lt->tm_year == tm.tm_year
22022 && lt->tm_mon == tm.tm_mon
22023 && lt->tm_mday == tm.tm_mday
22024 && lt->tm_hour == tm.tm_hour
22025 && lt->tm_min == tm.tm_min
22026 && lt->tm_sec == tm.tm_sec
22027 && lt->tm_yday == tm.tm_yday
22028 && lt->tm_wday == tm.tm_wday
22029 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
22030 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
22031 return 0;
22033 return 1;
22036 static int
22037 year_2050_test ()
22039 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
22040 ignoring leap seconds. */
22041 unsigned long int answer = 2527315200UL;
22043 struct tm tm;
22044 time_t t;
22045 tm.tm_year = 2050 - 1900;
22046 tm.tm_mon = 2 - 1;
22047 tm.tm_mday = 1;
22048 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
22049 tm.tm_isdst = -1;
22051 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
22052 instead of "TZ=America/Vancouver" in order to detect the bug even
22053 on systems that don't support the Olson extension, or don't have the
22054 full zoneinfo tables installed. */
22055 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
22057 t = mktime (&tm);
22059 /* Check that the result is either a failure, or close enough
22060 to the correct answer that we can assume the discrepancy is
22061 due to leap seconds. */
22062 return (t == (time_t) -1
22063 || (0 < t && answer - 120 <= t && t <= answer + 120));
22067 main ()
22069 int result = 0;
22070 time_t t, delta;
22071 int i, j;
22072 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
22073 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
22075 /* This test makes some buggy mktime implementations loop.
22076 Give up after 60 seconds; a mktime slower than that
22077 isn't worth using anyway. */
22078 alarm (60);
22080 time_t_max = (! time_t_signed
22081 ? (time_t) -1
22082 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
22083 * 2 + 1));
22084 time_t_min = (! time_t_signed
22085 ? (time_t) 0
22086 : time_t_signed_magnitude
22087 ? ~ (time_t) 0
22088 : ~ time_t_max);
22090 delta = time_t_max / 997; /* a suitable prime number */
22091 for (i = 0; i < N_STRINGS; i++)
22093 if (tz_strings[i])
22094 putenv (tz_strings[i]);
22096 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
22097 if (! mktime_test (t))
22098 result |= 1;
22099 if ((result & 2) == 0
22100 && ! (mktime_test ((time_t) 1)
22101 && mktime_test ((time_t) (60 * 60))
22102 && mktime_test ((time_t) (60 * 60 * 24))))
22103 result |= 2;
22105 for (j = 1; (result & 4) == 0; j <<= 1)
22107 if (! bigtime_test (j))
22108 result |= 4;
22109 if (INT_MAX / 2 < j)
22110 break;
22112 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
22113 result |= 8;
22115 if (! irix_6_4_bug ())
22116 result |= 16;
22117 if (! spring_forward_gap ())
22118 result |= 32;
22119 if (! year_2050_test ())
22120 result |= 64;
22121 return result;
22123 _ACEOF
22124 if ac_fn_c_try_run "$LINENO"; then :
22125 gl_cv_func_working_mktime=yes
22126 else
22127 gl_cv_func_working_mktime=no
22129 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22130 conftest.$ac_objext conftest.beam conftest.$ac_ext
22135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
22136 $as_echo "$gl_cv_func_working_mktime" >&6; }
22138 if test $gl_cv_func_working_mktime = no; then
22139 REPLACE_MKTIME=1
22140 else
22141 REPLACE_MKTIME=0
22144 if test $REPLACE_MKTIME = 1; then
22153 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
22162 GNULIB_MKTIME=1
22174 if test $ac_cv_func_pselect = yes; then
22175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
22176 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
22177 if test "${gl_cv_sig_pselect+set}" = set; then :
22178 $as_echo_n "(cached) " >&6
22179 else
22180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22181 /* end confdefs.h. */
22182 #include <sys/select.h>
22185 main ()
22187 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
22188 struct timespec const *restrict,
22189 sigset_t const *restrict) = pselect;
22190 return !p;
22192 return 0;
22194 _ACEOF
22195 if ac_fn_c_try_link "$LINENO"; then :
22196 gl_cv_sig_pselect=yes
22197 else
22198 gl_cv_sig_pselect=no
22200 rm -f core conftest.err conftest.$ac_objext \
22201 conftest$ac_exeext conftest.$ac_ext
22203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
22204 $as_echo "$gl_cv_sig_pselect" >&6; }
22206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
22207 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
22208 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
22209 $as_echo_n "(cached) " >&6
22210 else
22212 if test "$cross_compiling" = yes; then :
22214 case "$host_os" in
22215 # Guess yes on glibc systems.
22216 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
22217 # If we don't know, assume the worst.
22218 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
22219 esac
22221 else
22222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22223 /* end confdefs.h. */
22225 #include <sys/types.h>
22226 #include <sys/time.h>
22227 #if HAVE_SYS_SELECT_H
22228 # include <sys/select.h>
22229 #endif
22230 #include <unistd.h>
22231 #include <errno.h>
22234 main ()
22237 fd_set set;
22238 dup2(0, 16);
22239 FD_ZERO(&set);
22240 FD_SET(16, &set);
22241 close(16);
22242 struct timespec timeout;
22243 timeout.tv_sec = 0;
22244 timeout.tv_nsec = 5000;
22245 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
22248 return 0;
22250 _ACEOF
22251 if ac_fn_c_try_run "$LINENO"; then :
22252 gl_cv_func_pselect_detects_ebadf=yes
22253 else
22254 gl_cv_func_pselect_detects_ebadf=no
22256 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22257 conftest.$ac_objext conftest.beam conftest.$ac_ext
22262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
22263 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
22264 case $gl_cv_func_pselect_detects_ebadf in
22265 *yes) ;;
22266 *) REPLACE_PSELECT=1 ;;
22267 esac
22270 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
22271 REPLACE_PSELECT=1
22274 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
22283 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
22291 GNULIB_PSELECT=1
22301 LIB_PTHREAD_SIGMASK=
22306 if test "$gl_threads_api" = posix; then
22307 if test $ac_cv_func_pthread_sigmask = yes; then
22309 else
22310 if test -n "$LIBMULTITHREAD"; then
22311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
22312 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
22313 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
22314 $as_echo_n "(cached) " >&6
22315 else
22316 gl_save_LIBS="$LIBS"
22317 LIBS="$LIBS $LIBMULTITHREAD"
22318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22319 /* end confdefs.h. */
22320 #include <pthread.h>
22321 #include <signal.h>
22324 main ()
22326 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
22328 return 0;
22331 _ACEOF
22332 if ac_fn_c_try_link "$LINENO"; then :
22333 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
22334 else
22335 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
22337 rm -f core conftest.err conftest.$ac_objext \
22338 conftest$ac_exeext conftest.$ac_ext
22339 LIBS="$gl_save_LIBS"
22342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
22343 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
22344 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
22345 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
22346 else
22347 HAVE_PTHREAD_SIGMASK=0
22349 else
22350 HAVE_PTHREAD_SIGMASK=0
22353 else
22354 if test $ac_cv_func_pthread_sigmask = yes; then
22355 REPLACE_PTHREAD_SIGMASK=1
22356 else
22357 HAVE_PTHREAD_SIGMASK=0
22364 if test $HAVE_PTHREAD_SIGMASK = 1; then
22367 if test -z "$LIB_PTHREAD_SIGMASK"; then
22368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
22369 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
22370 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
22371 $as_echo_n "(cached) " >&6
22372 else
22374 if test "$cross_compiling" = yes; then :
22376 case "$host_os" in
22377 freebsd* | hpux* | solaris | solaris2.[2-9]*)
22378 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
22380 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
22381 esac
22383 else
22384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22385 /* end confdefs.h. */
22387 #include <pthread.h>
22388 #include <signal.h>
22389 #include <stddef.h>
22390 int main ()
22392 sigset_t set;
22393 sigemptyset (&set);
22394 return pthread_sigmask (1729, &set, NULL) != 0;
22396 _ACEOF
22397 if ac_fn_c_try_run "$LINENO"; then :
22398 gl_cv_func_pthread_sigmask_in_libc_works=no
22399 else
22400 gl_cv_func_pthread_sigmask_in_libc_works=yes
22402 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22403 conftest.$ac_objext conftest.beam conftest.$ac_ext
22408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
22409 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
22410 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
22411 *no)
22412 REPLACE_PTHREAD_SIGMASK=1
22414 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
22417 esac
22420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
22421 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
22422 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
22423 $as_echo_n "(cached) " >&6
22424 else
22426 gl_save_LIBS="$LIBS"
22427 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
22428 if test "$cross_compiling" = yes; then :
22429 case "$host_os" in
22430 cygwin*)
22431 gl_cv_func_pthread_sigmask_return_works="guessing no";;
22433 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
22434 esac
22436 else
22437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22438 /* end confdefs.h. */
22440 #include <pthread.h>
22441 #include <signal.h>
22442 #include <stddef.h>
22443 int main ()
22445 sigset_t set;
22446 sigemptyset (&set);
22447 if (pthread_sigmask (1729, &set, NULL) == -1)
22448 return 1;
22449 return 0;
22451 _ACEOF
22452 if ac_fn_c_try_run "$LINENO"; then :
22453 gl_cv_func_pthread_sigmask_return_works=yes
22454 else
22455 gl_cv_func_pthread_sigmask_return_works=no
22457 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22458 conftest.$ac_objext conftest.beam conftest.$ac_ext
22461 LIBS="$gl_save_LIBS"
22464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
22465 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
22466 case "$gl_cv_func_pthread_sigmask_return_works" in
22467 *no)
22468 REPLACE_PTHREAD_SIGMASK=1
22470 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
22473 esac
22475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
22476 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
22477 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
22478 $as_echo_n "(cached) " >&6
22479 else
22481 case "$host_os" in
22482 irix*)
22483 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
22485 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
22486 esac
22487 gl_save_LIBS="$LIBS"
22488 LIBS="$LIBS $LIBMULTITHREAD"
22489 if test "$cross_compiling" = yes; then :
22491 else
22492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22493 /* end confdefs.h. */
22495 #include <pthread.h>
22496 #include <signal.h>
22497 #include <stdio.h>
22498 #include <stdlib.h>
22499 #include <unistd.h>
22500 static volatile int sigint_occurred;
22501 static void
22502 sigint_handler (int sig)
22504 sigint_occurred++;
22506 int main ()
22508 sigset_t set;
22509 int pid = getpid ();
22510 char command[80];
22511 signal (SIGINT, sigint_handler);
22512 sigemptyset (&set);
22513 sigaddset (&set, SIGINT);
22514 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
22515 return 1;
22516 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
22517 if (!(system (command) == 0))
22518 return 2;
22519 sleep (2);
22520 if (!(sigint_occurred == 0))
22521 return 3;
22522 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
22523 return 4;
22524 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
22525 return 5;
22526 return 0;
22528 _ACEOF
22529 if ac_fn_c_try_run "$LINENO"; then :
22531 else
22532 gl_cv_func_pthread_sigmask_unblock_works=no
22534 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22535 conftest.$ac_objext conftest.beam conftest.$ac_ext
22538 LIBS="$gl_save_LIBS"
22541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
22542 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
22543 case "$gl_cv_func_pthread_sigmask_unblock_works" in
22544 *no)
22545 REPLACE_PTHREAD_SIGMASK=1
22547 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
22550 esac
22553 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22562 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
22565 if test $HAVE_PTHREAD_SIGMASK = 1; then
22567 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
22577 GNULIB_PTHREAD_SIGMASK=1
22585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
22586 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
22587 if test "${gl_cv_func_svid_putenv+set}" = set; then :
22588 $as_echo_n "(cached) " >&6
22589 else
22590 if test "$cross_compiling" = yes; then :
22591 case "$host_os" in
22592 # Guess yes on glibc systems.
22593 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
22594 # If we don't know, assume the worst.
22595 *) gl_cv_func_svid_putenv="guessing no" ;;
22596 esac
22598 else
22599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22600 /* end confdefs.h. */
22601 $ac_includes_default
22603 main ()
22606 /* Put it in env. */
22607 if (putenv ("CONFTEST_putenv=val"))
22608 return 1;
22610 /* Try to remove it. */
22611 if (putenv ("CONFTEST_putenv"))
22612 return 2;
22614 /* Make sure it was deleted. */
22615 if (getenv ("CONFTEST_putenv") != 0)
22616 return 3;
22618 return 0;
22621 return 0;
22623 _ACEOF
22624 if ac_fn_c_try_run "$LINENO"; then :
22625 gl_cv_func_svid_putenv=yes
22626 else
22627 gl_cv_func_svid_putenv=no
22629 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22630 conftest.$ac_objext conftest.beam conftest.$ac_ext
22635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
22636 $as_echo "$gl_cv_func_svid_putenv" >&6; }
22637 case "$gl_cv_func_svid_putenv" in
22638 *yes) ;;
22640 REPLACE_PUTENV=1
22642 esac
22644 if test $REPLACE_PUTENV = 1; then
22653 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
22661 GNULIB_PUTENV=1
22670 if test $ac_cv_func_readlink = no; then
22671 HAVE_READLINK=0
22672 else
22673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
22674 $as_echo_n "checking whether readlink signature is correct... " >&6; }
22675 if test "${gl_cv_decl_readlink_works+set}" = set; then :
22676 $as_echo_n "(cached) " >&6
22677 else
22678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22679 /* end confdefs.h. */
22680 #include <unistd.h>
22681 /* Cause compilation failure if original declaration has wrong type. */
22682 ssize_t readlink (const char *, char *, size_t);
22684 main ()
22688 return 0;
22690 _ACEOF
22691 if ac_fn_c_try_compile "$LINENO"; then :
22692 gl_cv_decl_readlink_works=yes
22693 else
22694 gl_cv_decl_readlink_works=no
22696 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
22699 $as_echo "$gl_cv_decl_readlink_works" >&6; }
22700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
22701 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
22702 if test "${gl_cv_func_readlink_works+set}" = set; then :
22703 $as_echo_n "(cached) " >&6
22704 else
22705 # We have readlink, so assume ln -s works.
22706 ln -s conftest.no-such conftest.link
22707 ln -s conftest.link conftest.lnk2
22708 if test "$cross_compiling" = yes; then :
22709 case "$host_os" in
22710 # Guess yes on glibc systems.
22711 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
22712 # If we don't know, assume the worst.
22713 *) gl_cv_func_readlink_works="guessing no" ;;
22714 esac
22716 else
22717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22718 /* end confdefs.h. */
22719 #include <unistd.h>
22722 main ()
22724 char buf[20];
22725 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
22727 return 0;
22729 _ACEOF
22730 if ac_fn_c_try_run "$LINENO"; then :
22731 gl_cv_func_readlink_works=yes
22732 else
22733 gl_cv_func_readlink_works=no
22735 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22736 conftest.$ac_objext conftest.beam conftest.$ac_ext
22739 rm -f conftest.link conftest.lnk2
22741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
22742 $as_echo "$gl_cv_func_readlink_works" >&6; }
22743 case "$gl_cv_func_readlink_works" in
22744 *yes)
22745 if test "$gl_cv_decl_readlink_works" != yes; then
22746 REPLACE_READLINK=1
22751 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
22753 REPLACE_READLINK=1
22755 esac
22758 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22767 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
22778 GNULIB_READLINK=1
22785 for ac_func in sig2str
22786 do :
22787 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
22788 if test "x$ac_cv_func_sig2str" = x""yes; then :
22789 cat >>confdefs.h <<_ACEOF
22790 #define HAVE_SIG2STR 1
22791 _ACEOF
22794 done
22797 if test $ac_cv_func_sig2str = no; then
22806 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
22823 if test $gl_cv_have_include_next = yes; then
22824 gl_cv_next_signal_h='<'signal.h'>'
22825 else
22826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22827 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22828 if test "${gl_cv_next_signal_h+set}" = set; then :
22829 $as_echo_n "(cached) " >&6
22830 else
22832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22833 /* end confdefs.h. */
22834 #include <signal.h>
22836 _ACEOF
22837 case "$host_os" in
22838 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22839 *) gl_absname_cpp="$ac_cpp" ;;
22840 esac
22842 case "$host_os" in
22843 mingw*)
22844 gl_dirsep_regex='[/\\]'
22847 gl_dirsep_regex='\/'
22849 esac
22850 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22852 gl_header_literal_regex=`echo 'signal.h' \
22853 | sed -e "$gl_make_literal_regex_sed"`
22854 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22855 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22856 s|^/[^/]|//&|
22860 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22861 sed -n "$gl_absolute_header_sed"`'"'
22865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22866 $as_echo "$gl_cv_next_signal_h" >&6; }
22868 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22870 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22871 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22872 gl_next_as_first_directive='<'signal.h'>'
22873 else
22874 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22875 gl_next_as_first_directive=$gl_cv_next_signal_h
22877 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22883 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22884 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22885 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22886 #include <signal.h>
22889 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22891 else
22892 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22901 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22902 #include <signal.h>
22905 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22907 else
22908 HAVE_SIGHANDLER_T=0
22914 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22915 /* <sys/types.h> is not needed according to POSIX, but the
22916 <sys/socket.h> in i386-unknown-freebsd4.10 and
22917 powerpc-apple-darwin5.5 required it. */
22918 #include <sys/types.h>
22919 #if HAVE_SYS_SOCKET_H
22920 # include <sys/socket.h>
22921 #elif HAVE_WS2TCPIP_H
22922 # include <ws2tcpip.h>
22923 #endif
22926 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22928 else
22929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22930 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22931 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22932 $as_echo_n "(cached) " >&6
22933 else
22934 # Systems have either "struct sockaddr *" or
22935 # "void *" as the second argument to getpeername
22936 gl_cv_socklen_t_equiv=
22937 for arg2 in "struct sockaddr" void; do
22938 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22940 /* end confdefs.h. */
22941 #include <sys/types.h>
22942 #include <sys/socket.h>
22944 int getpeername (int, $arg2 *, $t *);
22946 main ()
22948 $t len;
22949 getpeername (0, 0, &len);
22951 return 0;
22953 _ACEOF
22954 if ac_fn_c_try_compile "$LINENO"; then :
22955 gl_cv_socklen_t_equiv="$t"
22957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22958 test "$gl_cv_socklen_t_equiv" != "" && break
22959 done
22960 test "$gl_cv_socklen_t_equiv" != "" && break
22961 done
22965 if test "$gl_cv_socklen_t_equiv" = ""; then
22966 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22969 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
22971 cat >>confdefs.h <<_ACEOF
22972 #define socklen_t $gl_cv_socklen_t_equiv
22973 _ACEOF
22978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22979 $as_echo_n "checking for ssize_t... " >&6; }
22980 if test "${gt_cv_ssize_t+set}" = set; then :
22981 $as_echo_n "(cached) " >&6
22982 else
22983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22984 /* end confdefs.h. */
22985 #include <sys/types.h>
22987 main ()
22989 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22990 return !x;
22992 return 0;
22994 _ACEOF
22995 if ac_fn_c_try_compile "$LINENO"; then :
22996 gt_cv_ssize_t=yes
22997 else
22998 gt_cv_ssize_t=no
23000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
23003 $as_echo "$gt_cv_ssize_t" >&6; }
23004 if test $gt_cv_ssize_t = no; then
23006 $as_echo "#define ssize_t int" >>confdefs.h
23014 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>
23015 #include <sys/stat.h>
23017 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
23019 cat >>confdefs.h <<_ACEOF
23020 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
23021 _ACEOF
23023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
23024 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
23025 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
23026 $as_echo_n "(cached) " >&6
23027 else
23028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23029 /* end confdefs.h. */
23031 #include <sys/types.h>
23032 #include <sys/stat.h>
23033 #if HAVE_SYS_TIME_H
23034 # include <sys/time.h>
23035 #endif
23036 #include <time.h>
23037 struct timespec ts;
23038 struct stat st;
23041 main ()
23044 st.st_atim = ts;
23047 return 0;
23049 _ACEOF
23050 if ac_fn_c_try_compile "$LINENO"; then :
23051 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
23052 else
23053 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
23055 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
23058 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
23059 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
23061 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
23064 else
23065 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>
23066 #include <sys/stat.h>
23068 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
23070 cat >>confdefs.h <<_ACEOF
23071 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
23072 _ACEOF
23075 else
23076 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
23077 #include <sys/stat.h>
23079 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
23081 cat >>confdefs.h <<_ACEOF
23082 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
23083 _ACEOF
23086 else
23087 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>
23088 #include <sys/stat.h>
23090 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
23092 cat >>confdefs.h <<_ACEOF
23093 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
23094 _ACEOF
23109 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>
23110 #include <sys/stat.h>
23112 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
23114 cat >>confdefs.h <<_ACEOF
23115 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
23116 _ACEOF
23119 else
23120 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
23121 #include <sys/stat.h>
23123 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
23125 cat >>confdefs.h <<_ACEOF
23126 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
23127 _ACEOF
23130 else
23131 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>
23132 #include <sys/stat.h>
23134 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
23136 cat >>confdefs.h <<_ACEOF
23137 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
23138 _ACEOF
23149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
23150 $as_echo_n "checking for working stdalign.h... " >&6; }
23151 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
23152 $as_echo_n "(cached) " >&6
23153 else
23154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23155 /* end confdefs.h. */
23156 #include <stdalign.h>
23157 #include <stddef.h>
23159 /* Test that alignof yields a result consistent with offsetof.
23160 This catches GCC bug 52023
23161 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
23162 #ifdef __cplusplus
23163 template <class t> struct alignof_helper { char a; t b; };
23164 # define ao(type) offsetof (alignof_helper<type>, b)
23165 #else
23166 # define ao(type) offsetof (struct { char a; type b; }, b)
23167 #endif
23168 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
23169 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
23170 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
23172 /* Test _Alignas only on platforms where gnulib can help. */
23173 #if \
23174 (__GNUC__ || __IBMC__ || __IBMCPP__ \
23175 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
23176 int alignas (8) alignas_int = 1;
23177 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
23178 #endif
23181 main ()
23185 return 0;
23187 _ACEOF
23188 if ac_fn_c_try_compile "$LINENO"; then :
23189 gl_cv_header_working_stdalign_h=yes
23190 else
23191 gl_cv_header_working_stdalign_h=no
23193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
23196 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
23198 if test $gl_cv_header_working_stdalign_h = yes; then
23199 STDALIGN_H=''
23200 else
23201 STDALIGN_H='stdalign.h'
23205 if test -n "$STDALIGN_H"; then
23206 GL_GENERATE_STDALIGN_H_TRUE=
23207 GL_GENERATE_STDALIGN_H_FALSE='#'
23208 else
23209 GL_GENERATE_STDALIGN_H_TRUE='#'
23210 GL_GENERATE_STDALIGN_H_FALSE=
23215 STDARG_H=''
23216 NEXT_STDARG_H='<stdarg.h>'
23217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
23218 $as_echo_n "checking for va_copy... " >&6; }
23219 if test "${gl_cv_func_va_copy+set}" = set; then :
23220 $as_echo_n "(cached) " >&6
23221 else
23223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23224 /* end confdefs.h. */
23225 #include <stdarg.h>
23227 main ()
23230 #ifndef va_copy
23231 void (*func) (va_list, va_list) = va_copy;
23232 #endif
23235 return 0;
23237 _ACEOF
23238 if ac_fn_c_try_compile "$LINENO"; then :
23239 gl_cv_func_va_copy=yes
23240 else
23241 gl_cv_func_va_copy=no
23243 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
23247 $as_echo "$gl_cv_func_va_copy" >&6; }
23248 if test $gl_cv_func_va_copy = no; then
23249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23250 /* end confdefs.h. */
23251 #if defined _AIX && !defined __GNUC__
23252 AIX vaccine
23253 #endif
23255 _ACEOF
23256 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23257 $EGREP "vaccine" >/dev/null 2>&1; then :
23258 gl_aixcc=yes
23259 else
23260 gl_aixcc=no
23262 rm -f conftest*
23264 if test $gl_aixcc = yes; then
23265 STDARG_H=stdarg.h
23274 if test $gl_cv_have_include_next = yes; then
23275 gl_cv_next_stdarg_h='<'stdarg.h'>'
23276 else
23277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
23278 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
23279 if test "${gl_cv_next_stdarg_h+set}" = set; then :
23280 $as_echo_n "(cached) " >&6
23281 else
23283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23284 /* end confdefs.h. */
23285 #include <stdarg.h>
23287 _ACEOF
23288 case "$host_os" in
23289 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23290 *) gl_absname_cpp="$ac_cpp" ;;
23291 esac
23293 case "$host_os" in
23294 mingw*)
23295 gl_dirsep_regex='[/\\]'
23298 gl_dirsep_regex='\/'
23300 esac
23301 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23303 gl_header_literal_regex=`echo 'stdarg.h' \
23304 | sed -e "$gl_make_literal_regex_sed"`
23305 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23306 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23307 s|^/[^/]|//&|
23311 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23312 sed -n "$gl_absolute_header_sed"`'"'
23316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
23317 $as_echo "$gl_cv_next_stdarg_h" >&6; }
23319 NEXT_STDARG_H=$gl_cv_next_stdarg_h
23321 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23322 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23323 gl_next_as_first_directive='<'stdarg.h'>'
23324 else
23325 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23326 gl_next_as_first_directive=$gl_cv_next_stdarg_h
23328 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
23333 if test "$gl_cv_next_stdarg_h" = '""'; then
23334 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
23335 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
23337 else
23339 saved_as_echo_n="$as_echo_n"
23340 as_echo_n=':'
23341 if test "${gl_cv_func___va_copy+set}" = set; then :
23342 $as_echo_n "(cached) " >&6
23343 else
23345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23346 /* end confdefs.h. */
23347 #include <stdarg.h>
23349 main ()
23352 #ifndef __va_copy
23353 error, bail out
23354 #endif
23357 return 0;
23359 _ACEOF
23360 if ac_fn_c_try_compile "$LINENO"; then :
23361 gl_cv_func___va_copy=yes
23362 else
23363 gl_cv_func___va_copy=no
23365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23368 as_echo_n="$saved_as_echo_n"
23370 if test $gl_cv_func___va_copy = yes; then
23372 $as_echo "#define va_copy __va_copy" >>confdefs.h
23374 else
23377 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
23383 if test -n "$STDARG_H"; then
23384 GL_GENERATE_STDARG_H_TRUE=
23385 GL_GENERATE_STDARG_H_FALSE='#'
23386 else
23387 GL_GENERATE_STDARG_H_TRUE='#'
23388 GL_GENERATE_STDARG_H_FALSE=
23396 # Define two additional variables used in the Makefile substitution.
23398 if test "$ac_cv_header_stdbool_h" = yes; then
23399 STDBOOL_H=''
23400 else
23401 STDBOOL_H='stdbool.h'
23404 if test -n "$STDBOOL_H"; then
23405 GL_GENERATE_STDBOOL_H_TRUE=
23406 GL_GENERATE_STDBOOL_H_FALSE='#'
23407 else
23408 GL_GENERATE_STDBOOL_H_TRUE='#'
23409 GL_GENERATE_STDBOOL_H_FALSE=
23413 if test "$ac_cv_type__Bool" = yes; then
23414 HAVE__BOOL=1
23415 else
23416 HAVE__BOOL=0
23423 STDDEF_H=
23424 if test $gt_cv_c_wchar_t = no; then
23425 HAVE_WCHAR_T=0
23426 STDDEF_H=stddef.h
23428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
23429 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
23430 if test "${gl_cv_decl_null_works+set}" = set; then :
23431 $as_echo_n "(cached) " >&6
23432 else
23433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23434 /* end confdefs.h. */
23435 #include <stddef.h>
23436 int test[2 * (sizeof NULL == sizeof (void *)) -1];
23439 main ()
23443 return 0;
23445 _ACEOF
23446 if ac_fn_c_try_compile "$LINENO"; then :
23447 gl_cv_decl_null_works=yes
23448 else
23449 gl_cv_decl_null_works=no
23451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
23454 $as_echo "$gl_cv_decl_null_works" >&6; }
23455 if test $gl_cv_decl_null_works = no; then
23456 REPLACE_NULL=1
23457 STDDEF_H=stddef.h
23460 if test -n "$STDDEF_H"; then
23461 GL_GENERATE_STDDEF_H_TRUE=
23462 GL_GENERATE_STDDEF_H_FALSE='#'
23463 else
23464 GL_GENERATE_STDDEF_H_TRUE='#'
23465 GL_GENERATE_STDDEF_H_FALSE=
23468 if test -n "$STDDEF_H"; then
23477 if test $gl_cv_have_include_next = yes; then
23478 gl_cv_next_stddef_h='<'stddef.h'>'
23479 else
23480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
23481 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
23482 if test "${gl_cv_next_stddef_h+set}" = set; then :
23483 $as_echo_n "(cached) " >&6
23484 else
23486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23487 /* end confdefs.h. */
23488 #include <stddef.h>
23490 _ACEOF
23491 case "$host_os" in
23492 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23493 *) gl_absname_cpp="$ac_cpp" ;;
23494 esac
23496 case "$host_os" in
23497 mingw*)
23498 gl_dirsep_regex='[/\\]'
23501 gl_dirsep_regex='\/'
23503 esac
23504 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23506 gl_header_literal_regex=`echo 'stddef.h' \
23507 | sed -e "$gl_make_literal_regex_sed"`
23508 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23509 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23510 s|^/[^/]|//&|
23514 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23515 sed -n "$gl_absolute_header_sed"`'"'
23519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
23520 $as_echo "$gl_cv_next_stddef_h" >&6; }
23522 NEXT_STDDEF_H=$gl_cv_next_stddef_h
23524 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23525 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23526 gl_next_as_first_directive='<'stddef.h'>'
23527 else
23528 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23529 gl_next_as_first_directive=$gl_cv_next_stddef_h
23531 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
23549 if test $gl_cv_have_include_next = yes; then
23550 gl_cv_next_stdio_h='<'stdio.h'>'
23551 else
23552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
23553 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
23554 if test "${gl_cv_next_stdio_h+set}" = set; then :
23555 $as_echo_n "(cached) " >&6
23556 else
23558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23559 /* end confdefs.h. */
23560 #include <stdio.h>
23562 _ACEOF
23563 case "$host_os" in
23564 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23565 *) gl_absname_cpp="$ac_cpp" ;;
23566 esac
23568 case "$host_os" in
23569 mingw*)
23570 gl_dirsep_regex='[/\\]'
23573 gl_dirsep_regex='\/'
23575 esac
23576 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23578 gl_header_literal_regex=`echo 'stdio.h' \
23579 | sed -e "$gl_make_literal_regex_sed"`
23580 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23581 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23582 s|^/[^/]|//&|
23586 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23587 sed -n "$gl_absolute_header_sed"`'"'
23591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
23592 $as_echo "$gl_cv_next_stdio_h" >&6; }
23594 NEXT_STDIO_H=$gl_cv_next_stdio_h
23596 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23597 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23598 gl_next_as_first_directive='<'stdio.h'>'
23599 else
23600 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23601 gl_next_as_first_directive=$gl_cv_next_stdio_h
23603 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
23609 GNULIB_FSCANF=1
23612 cat >>confdefs.h <<_ACEOF
23613 #define GNULIB_FSCANF 1
23614 _ACEOF
23617 GNULIB_SCANF=1
23620 cat >>confdefs.h <<_ACEOF
23621 #define GNULIB_SCANF 1
23622 _ACEOF
23625 GNULIB_FGETC=1
23626 GNULIB_GETC=1
23627 GNULIB_GETCHAR=1
23628 GNULIB_FGETS=1
23629 GNULIB_FREAD=1
23632 GNULIB_FPRINTF=1
23633 GNULIB_PRINTF=1
23634 GNULIB_VFPRINTF=1
23635 GNULIB_VPRINTF=1
23636 GNULIB_FPUTC=1
23637 GNULIB_PUTC=1
23638 GNULIB_PUTCHAR=1
23639 GNULIB_FPUTS=1
23640 GNULIB_PUTS=1
23641 GNULIB_FWRITE=1
23657 if test $gl_cv_have_include_next = yes; then
23658 gl_cv_next_stdlib_h='<'stdlib.h'>'
23659 else
23660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
23661 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
23662 if test "${gl_cv_next_stdlib_h+set}" = set; then :
23663 $as_echo_n "(cached) " >&6
23664 else
23666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23667 /* end confdefs.h. */
23668 #include <stdlib.h>
23670 _ACEOF
23671 case "$host_os" in
23672 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23673 *) gl_absname_cpp="$ac_cpp" ;;
23674 esac
23676 case "$host_os" in
23677 mingw*)
23678 gl_dirsep_regex='[/\\]'
23681 gl_dirsep_regex='\/'
23683 esac
23684 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23686 gl_header_literal_regex=`echo 'stdlib.h' \
23687 | sed -e "$gl_make_literal_regex_sed"`
23688 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23689 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23690 s|^/[^/]|//&|
23694 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23695 sed -n "$gl_absolute_header_sed"`'"'
23699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
23700 $as_echo "$gl_cv_next_stdlib_h" >&6; }
23702 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
23704 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23705 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23706 gl_next_as_first_directive='<'stdlib.h'>'
23707 else
23708 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23709 gl_next_as_first_directive=$gl_cv_next_stdlib_h
23711 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
23721 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
23729 $as_echo "#define my_strftime nstrftime" >>confdefs.h
23738 if test "$ac_cv_have_decl_strtoimax" != yes; then
23739 HAVE_DECL_STRTOIMAX=0
23742 if test $ac_cv_func_strtoimax = yes; then
23743 HAVE_STRTOIMAX=1
23744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
23745 $as_echo_n "checking whether strtoimax works... " >&6; }
23746 if test "${gl_cv_func_strtoimax+set}" = set; then :
23747 $as_echo_n "(cached) " >&6
23748 else
23749 if test "$cross_compiling" = yes; then :
23750 case "$host_os" in
23751 # Guess no on AIX 5.
23752 aix5*) gl_cv_func_strtoimax="guessing no" ;;
23753 # Guess yes otherwise.
23754 *) gl_cv_func_strtoimax="guessing yes" ;;
23755 esac
23757 else
23758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23759 /* end confdefs.h. */
23761 #include <errno.h>
23762 #include <string.h>
23763 #include <inttypes.h>
23764 int main ()
23766 if (sizeof (intmax_t) > sizeof (int))
23768 const char *s = "4294967295";
23769 char *p;
23770 intmax_t res;
23771 errno = 0;
23772 res = strtoimax (s, &p, 10);
23773 if (p != s + strlen (s))
23774 return 1;
23775 if (errno != 0)
23776 return 2;
23777 if (res != (intmax_t) 65535 * (intmax_t) 65537)
23778 return 3;
23780 else
23782 const char *s = "2147483647";
23783 char *p;
23784 intmax_t res;
23785 errno = 0;
23786 res = strtoimax (s, &p, 10);
23787 if (p != s + strlen (s))
23788 return 1;
23789 if (errno != 0)
23790 return 2;
23791 if (res != 2147483647)
23792 return 3;
23794 return 0;
23797 _ACEOF
23798 if ac_fn_c_try_run "$LINENO"; then :
23799 gl_cv_func_strtoimax=yes
23800 else
23801 gl_cv_func_strtoimax=no
23803 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23804 conftest.$ac_objext conftest.beam conftest.$ac_ext
23809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
23810 $as_echo "$gl_cv_func_strtoimax" >&6; }
23811 case "$gl_cv_func_strtoimax" in
23812 *no) REPLACE_STRTOIMAX=1 ;;
23813 esac
23814 else
23815 HAVE_STRTOIMAX=0
23818 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23827 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
23830 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23831 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
23832 ac_have_decl=1
23833 else
23834 ac_have_decl=0
23837 cat >>confdefs.h <<_ACEOF
23838 #define HAVE_DECL_STRTOLL $ac_have_decl
23839 _ACEOF
23849 GNULIB_STRTOIMAX=1
23859 if test "$ac_cv_have_decl_strtoumax" != yes; then
23860 HAVE_DECL_STRTOUMAX=0
23863 if test $ac_cv_func_strtoumax = no; then
23872 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
23875 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23876 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
23877 ac_have_decl=1
23878 else
23879 ac_have_decl=0
23882 cat >>confdefs.h <<_ACEOF
23883 #define HAVE_DECL_STRTOULL $ac_have_decl
23884 _ACEOF
23894 GNULIB_STRTOUMAX=1
23902 if test $ac_cv_func_symlink = no; then
23903 HAVE_SYMLINK=0
23904 else
23905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23906 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23907 if test "${gl_cv_func_symlink_works+set}" = set; then :
23908 $as_echo_n "(cached) " >&6
23909 else
23910 if test "$cross_compiling" = yes; then :
23911 case "$host_os" in
23912 # Guess yes on glibc systems.
23913 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23914 # If we don't know, assume the worst.
23915 *) gl_cv_func_symlink_works="guessing no" ;;
23916 esac
23918 else
23919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23920 /* end confdefs.h. */
23921 #include <unistd.h>
23924 main ()
23926 int result = 0;
23927 if (!symlink ("a", "conftest.link/"))
23928 result |= 1;
23929 if (symlink ("conftest.f", "conftest.lnk2"))
23930 result |= 2;
23931 else if (!symlink ("a", "conftest.lnk2/"))
23932 result |= 4;
23933 return result;
23936 return 0;
23938 _ACEOF
23939 if ac_fn_c_try_run "$LINENO"; then :
23940 gl_cv_func_symlink_works=yes
23941 else
23942 gl_cv_func_symlink_works=no
23944 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23945 conftest.$ac_objext conftest.beam conftest.$ac_ext
23948 rm -f conftest.f conftest.link conftest.lnk2
23950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23951 $as_echo "$gl_cv_func_symlink_works" >&6; }
23952 case "$gl_cv_func_symlink_works" in
23953 *yes) ;;
23955 REPLACE_SYMLINK=1
23957 esac
23960 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23969 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
23977 GNULIB_SYMLINK=1
23986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
23987 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
23988 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
23989 $as_echo_n "(cached) " >&6
23990 else
23992 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23993 /* end confdefs.h. */
23994 #include <sys/select.h>
23996 main ()
23998 struct timeval b;
24000 return 0;
24002 _ACEOF
24003 if ac_fn_c_try_compile "$LINENO"; then :
24004 gl_cv_header_sys_select_h_selfcontained=yes
24005 else
24006 gl_cv_header_sys_select_h_selfcontained=no
24008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24009 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
24010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24011 /* end confdefs.h. */
24012 #include <sys/select.h>
24014 main ()
24016 int memset; int bzero;
24018 return 0;
24021 _ACEOF
24022 if ac_fn_c_try_compile "$LINENO"; then :
24023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24024 /* end confdefs.h. */
24025 #include <sys/select.h>
24027 main ()
24030 #undef memset
24031 #define memset nonexistent_memset
24032 extern
24033 #ifdef __cplusplus
24035 #endif
24036 void *memset (void *, int, unsigned long);
24037 #undef bzero
24038 #define bzero nonexistent_bzero
24039 extern
24040 #ifdef __cplusplus
24042 #endif
24043 void bzero (void *, unsigned long);
24044 fd_set fds;
24045 FD_ZERO (&fds);
24048 return 0;
24051 _ACEOF
24052 if ac_fn_c_try_link "$LINENO"; then :
24054 else
24055 gl_cv_header_sys_select_h_selfcontained=no
24057 rm -f core conftest.err conftest.$ac_objext \
24058 conftest$ac_exeext conftest.$ac_ext
24061 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
24066 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
24076 if test $gl_cv_have_include_next = yes; then
24077 gl_cv_next_sys_select_h='<'sys/select.h'>'
24078 else
24079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
24080 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
24081 if test "${gl_cv_next_sys_select_h+set}" = set; then :
24082 $as_echo_n "(cached) " >&6
24083 else
24085 if test $ac_cv_header_sys_select_h = yes; then
24088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24089 /* end confdefs.h. */
24090 #include <sys/select.h>
24092 _ACEOF
24093 case "$host_os" in
24094 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24095 *) gl_absname_cpp="$ac_cpp" ;;
24096 esac
24098 case "$host_os" in
24099 mingw*)
24100 gl_dirsep_regex='[/\\]'
24103 gl_dirsep_regex='\/'
24105 esac
24106 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24108 gl_header_literal_regex=`echo 'sys/select.h' \
24109 | sed -e "$gl_make_literal_regex_sed"`
24110 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24111 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24112 s|^/[^/]|//&|
24116 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24117 sed -n "$gl_absolute_header_sed"`'"'
24118 else
24119 gl_cv_next_sys_select_h='<'sys/select.h'>'
24124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
24125 $as_echo "$gl_cv_next_sys_select_h" >&6; }
24127 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
24129 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24130 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24131 gl_next_as_first_directive='<'sys/select.h'>'
24132 else
24133 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24134 gl_next_as_first_directive=$gl_cv_next_sys_select_h
24136 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
24141 if test $ac_cv_header_sys_select_h = yes; then
24142 HAVE_SYS_SELECT_H=1
24143 else
24144 HAVE_SYS_SELECT_H=0
24151 if test $ac_cv_header_sys_socket_h != yes; then
24152 for ac_header in winsock2.h
24153 do :
24154 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
24155 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
24156 cat >>confdefs.h <<_ACEOF
24157 #define HAVE_WINSOCK2_H 1
24158 _ACEOF
24162 done
24165 if test "$ac_cv_header_winsock2_h" = yes; then
24166 HAVE_WINSOCK2_H=1
24167 UNISTD_H_HAVE_WINSOCK2_H=1
24168 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
24169 else
24170 HAVE_WINSOCK2_H=0
24192 if test $gl_cv_have_include_next = yes; then
24193 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24194 else
24195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
24196 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
24197 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
24198 $as_echo_n "(cached) " >&6
24199 else
24201 if test $ac_cv_header_sys_stat_h = yes; then
24204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24205 /* end confdefs.h. */
24206 #include <sys/stat.h>
24208 _ACEOF
24209 case "$host_os" in
24210 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24211 *) gl_absname_cpp="$ac_cpp" ;;
24212 esac
24214 case "$host_os" in
24215 mingw*)
24216 gl_dirsep_regex='[/\\]'
24219 gl_dirsep_regex='\/'
24221 esac
24222 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24224 gl_header_literal_regex=`echo 'sys/stat.h' \
24225 | sed -e "$gl_make_literal_regex_sed"`
24226 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24227 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24228 s|^/[^/]|//&|
24232 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24233 sed -n "$gl_absolute_header_sed"`'"'
24234 else
24235 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
24241 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
24243 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
24245 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24246 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24247 gl_next_as_first_directive='<'sys/stat.h'>'
24248 else
24249 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24250 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
24252 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
24264 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
24266 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
24270 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
24271 #include <sys/stat.h>
24273 if test "x$ac_cv_type_nlink_t" = x""yes; then :
24275 else
24277 $as_echo "#define nlink_t int" >>confdefs.h
24298 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
24300 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
24301 ac_have_decl=1
24302 else
24303 ac_have_decl=0
24306 cat >>confdefs.h <<_ACEOF
24307 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
24308 _ACEOF
24310 if test $ac_cv_have_decl_localtime_r = no; then
24311 HAVE_DECL_LOCALTIME_R=0
24315 if test $ac_cv_func_localtime_r = yes; then
24316 HAVE_LOCALTIME_R=1
24317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
24318 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
24319 if test "${gl_cv_time_r_posix+set}" = set; then :
24320 $as_echo_n "(cached) " >&6
24321 else
24322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24323 /* end confdefs.h. */
24324 #include <time.h>
24326 main ()
24328 /* We don't need to append 'restrict's to the argument types,
24329 even though the POSIX signature has the 'restrict's,
24330 since C99 says they can't affect type compatibility. */
24331 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
24332 if (ptr) return 0;
24333 /* Check the return type is a pointer.
24334 On HP-UX 10 it is 'int'. */
24335 *localtime_r (0, 0);
24337 return 0;
24340 _ACEOF
24341 if ac_fn_c_try_compile "$LINENO"; then :
24342 gl_cv_time_r_posix=yes
24343 else
24344 gl_cv_time_r_posix=no
24346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
24350 $as_echo "$gl_cv_time_r_posix" >&6; }
24351 if test $gl_cv_time_r_posix = yes; then
24352 REPLACE_LOCALTIME_R=0
24353 else
24354 REPLACE_LOCALTIME_R=1
24356 else
24357 HAVE_LOCALTIME_R=0
24360 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
24369 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
24380 GNULIB_TIME_R=1
24391 LIB_TIMER_TIME=
24393 gl_saved_libs=$LIBS
24394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
24395 $as_echo_n "checking for library containing timer_settime... " >&6; }
24396 if test "${ac_cv_search_timer_settime+set}" = set; then :
24397 $as_echo_n "(cached) " >&6
24398 else
24399 ac_func_search_save_LIBS=$LIBS
24400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24401 /* end confdefs.h. */
24403 /* Override any GCC internal prototype to avoid an error.
24404 Use char because int might match the return type of a GCC
24405 builtin and then its argument prototype would still apply. */
24406 #ifdef __cplusplus
24407 extern "C"
24408 #endif
24409 char timer_settime ();
24411 main ()
24413 return timer_settime ();
24415 return 0;
24417 _ACEOF
24418 for ac_lib in '' rt posix4; do
24419 if test -z "$ac_lib"; then
24420 ac_res="none required"
24421 else
24422 ac_res=-l$ac_lib
24423 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
24425 if ac_fn_c_try_link "$LINENO"; then :
24426 ac_cv_search_timer_settime=$ac_res
24428 rm -f core conftest.err conftest.$ac_objext \
24429 conftest$ac_exeext
24430 if test "${ac_cv_search_timer_settime+set}" = set; then :
24431 break
24433 done
24434 if test "${ac_cv_search_timer_settime+set}" = set; then :
24436 else
24437 ac_cv_search_timer_settime=no
24439 rm conftest.$ac_ext
24440 LIBS=$ac_func_search_save_LIBS
24442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
24443 $as_echo "$ac_cv_search_timer_settime" >&6; }
24444 ac_res=$ac_cv_search_timer_settime
24445 if test "$ac_res" != no; then :
24446 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24447 test "$ac_cv_search_timer_settime" = "none required" ||
24448 LIB_TIMER_TIME=$ac_cv_search_timer_settime
24451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24452 /* end confdefs.h. */
24454 #include <features.h>
24455 #ifdef __GNU_LIBRARY__
24456 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
24457 && !defined __UCLIBC__
24458 Thread emulation available
24459 #endif
24460 #endif
24462 _ACEOF
24463 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24464 $EGREP "Thread" >/dev/null 2>&1; then :
24465 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
24467 rm -f conftest*
24469 for ac_func in timer_settime
24470 do :
24471 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
24472 if test "x$ac_cv_func_timer_settime" = x""yes; then :
24473 cat >>confdefs.h <<_ACEOF
24474 #define HAVE_TIMER_SETTIME 1
24475 _ACEOF
24478 done
24480 LIBS=$gl_saved_libs
24495 if test $gl_cv_have_include_next = yes; then
24496 gl_cv_next_unistd_h='<'unistd.h'>'
24497 else
24498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
24499 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
24500 if test "${gl_cv_next_unistd_h+set}" = set; then :
24501 $as_echo_n "(cached) " >&6
24502 else
24504 if test $ac_cv_header_unistd_h = yes; then
24507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24508 /* end confdefs.h. */
24509 #include <unistd.h>
24511 _ACEOF
24512 case "$host_os" in
24513 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24514 *) gl_absname_cpp="$ac_cpp" ;;
24515 esac
24517 case "$host_os" in
24518 mingw*)
24519 gl_dirsep_regex='[/\\]'
24522 gl_dirsep_regex='\/'
24524 esac
24525 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24527 gl_header_literal_regex=`echo 'unistd.h' \
24528 | sed -e "$gl_make_literal_regex_sed"`
24529 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24530 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24531 s|^/[^/]|//&|
24535 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24536 sed -n "$gl_absolute_header_sed"`'"'
24537 else
24538 gl_cv_next_unistd_h='<'unistd.h'>'
24543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
24544 $as_echo "$gl_cv_next_unistd_h" >&6; }
24546 NEXT_UNISTD_H=$gl_cv_next_unistd_h
24548 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24549 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24550 gl_next_as_first_directive='<'unistd.h'>'
24551 else
24552 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24553 gl_next_as_first_directive=$gl_cv_next_unistd_h
24555 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
24560 if test $ac_cv_header_unistd_h = yes; then
24561 HAVE_UNISTD_H=1
24562 else
24563 HAVE_UNISTD_H=0
24576 if test $ac_cv_have_decl_unsetenv = no; then
24577 HAVE_DECL_UNSETENV=0
24579 for ac_func in unsetenv
24580 do :
24581 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
24582 if test "x$ac_cv_func_unsetenv" = x""yes; then :
24583 cat >>confdefs.h <<_ACEOF
24584 #define HAVE_UNSETENV 1
24585 _ACEOF
24588 done
24590 if test $ac_cv_func_unsetenv = no; then
24591 HAVE_UNSETENV=0
24592 else
24593 HAVE_UNSETENV=1
24594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
24595 $as_echo_n "checking for unsetenv() return type... " >&6; }
24596 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
24597 $as_echo_n "(cached) " >&6
24598 else
24599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24600 /* end confdefs.h. */
24602 #undef _BSD
24603 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
24604 #include <stdlib.h>
24605 extern
24606 #ifdef __cplusplus
24608 #endif
24609 int unsetenv (const char *name);
24612 main ()
24616 return 0;
24618 _ACEOF
24619 if ac_fn_c_try_compile "$LINENO"; then :
24620 gt_cv_func_unsetenv_ret='int'
24621 else
24622 gt_cv_func_unsetenv_ret='void'
24624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
24627 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
24628 if test $gt_cv_func_unsetenv_ret = 'void'; then
24630 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
24632 REPLACE_UNSETENV=1
24635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
24636 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
24637 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
24638 $as_echo_n "(cached) " >&6
24639 else
24640 if test "$cross_compiling" = yes; then :
24641 case "$host_os" in
24642 # Guess yes on glibc systems.
24643 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
24644 # If we don't know, assume the worst.
24645 *) gl_cv_func_unsetenv_works="guessing no" ;;
24646 esac
24648 else
24649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24650 /* end confdefs.h. */
24652 #include <stdlib.h>
24653 #include <errno.h>
24654 extern char **environ;
24657 main ()
24660 char entry1[] = "a=1";
24661 char entry2[] = "b=2";
24662 char *env[] = { entry1, entry2, NULL };
24663 if (putenv ((char *) "a=1")) return 1;
24664 if (putenv (entry2)) return 2;
24665 entry2[0] = 'a';
24666 unsetenv ("a");
24667 if (getenv ("a")) return 3;
24668 if (!unsetenv ("") || errno != EINVAL) return 4;
24669 entry2[0] = 'b';
24670 environ = env;
24671 if (!getenv ("a")) return 5;
24672 entry2[0] = 'a';
24673 unsetenv ("a");
24674 if (getenv ("a")) return 6;
24677 return 0;
24679 _ACEOF
24680 if ac_fn_c_try_run "$LINENO"; then :
24681 gl_cv_func_unsetenv_works=yes
24682 else
24683 gl_cv_func_unsetenv_works=no
24685 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24686 conftest.$ac_objext conftest.beam conftest.$ac_ext
24690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
24691 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
24692 case "$gl_cv_func_unsetenv_works" in
24693 *yes) ;;
24695 REPLACE_UNSETENV=1
24697 esac
24700 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
24709 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
24721 GNULIB_UNSETENV=1
24733 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
24734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
24735 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
24736 if test "${gl_cv_func_futimesat_works+set}" = set; then :
24737 $as_echo_n "(cached) " >&6
24738 else
24739 touch conftest.file
24740 if test "$cross_compiling" = yes; then :
24741 case "$host_os" in
24742 # Guess yes on glibc systems.
24743 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
24744 # If we don't know, assume the worst.
24745 *) gl_cv_func_futimesat_works="guessing no" ;;
24746 esac
24748 else
24749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24750 /* end confdefs.h. */
24752 #include <stddef.h>
24753 #include <sys/times.h>
24754 #include <fcntl.h>
24757 main ()
24759 int fd = open ("conftest.file", O_RDWR);
24760 if (fd < 0) return 1;
24761 if (futimesat (fd, NULL, NULL)) return 2;
24764 return 0;
24766 _ACEOF
24767 if ac_fn_c_try_run "$LINENO"; then :
24768 gl_cv_func_futimesat_works=yes
24769 else
24770 gl_cv_func_futimesat_works=no
24772 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24773 conftest.$ac_objext conftest.beam conftest.$ac_ext
24776 rm -f conftest.file
24778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
24779 $as_echo "$gl_cv_func_futimesat_works" >&6; }
24780 case "$gl_cv_func_futimesat_works" in
24781 *yes) ;;
24784 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
24787 esac
24790 gl_gnulib_enabled_dosname=false
24791 gl_gnulib_enabled_euidaccess=false
24792 gl_gnulib_enabled_getgroups=false
24793 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
24794 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
24795 gl_gnulib_enabled_pathmax=false
24796 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
24797 gl_gnulib_enabled_stat=false
24798 gl_gnulib_enabled_strtoll=false
24799 gl_gnulib_enabled_strtoull=false
24800 gl_gnulib_enabled_verify=false
24801 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
24802 func_gl_gnulib_m4code_dosname ()
24804 if ! $gl_gnulib_enabled_dosname; then
24805 gl_gnulib_enabled_dosname=true
24808 func_gl_gnulib_m4code_euidaccess ()
24810 if ! $gl_gnulib_enabled_euidaccess; then
24816 for ac_func in euidaccess
24817 do :
24818 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
24819 if test "x$ac_cv_func_euidaccess" = x""yes; then :
24820 cat >>confdefs.h <<_ACEOF
24821 #define HAVE_EUIDACCESS 1
24822 _ACEOF
24825 done
24827 if test $ac_cv_func_euidaccess = no; then
24828 HAVE_EUIDACCESS=0
24831 if test $HAVE_EUIDACCESS = 0; then
24840 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
24844 for ac_header in libgen.h
24845 do :
24846 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
24847 if test "x$ac_cv_header_libgen_h" = x""yes; then :
24848 cat >>confdefs.h <<_ACEOF
24849 #define HAVE_LIBGEN_H 1
24850 _ACEOF
24854 done
24857 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
24858 if test "x$ac_cv_func_getgroups" = x""yes; then :
24863 # If we don't yet have getgroups, see if it's in -lbsd.
24864 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
24865 ac_save_LIBS=$LIBS
24866 if test $ac_cv_func_getgroups = no; then
24867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
24868 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
24869 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
24870 $as_echo_n "(cached) " >&6
24871 else
24872 ac_check_lib_save_LIBS=$LIBS
24873 LIBS="-lbsd $LIBS"
24874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24875 /* end confdefs.h. */
24877 /* Override any GCC internal prototype to avoid an error.
24878 Use char because int might match the return type of a GCC
24879 builtin and then its argument prototype would still apply. */
24880 #ifdef __cplusplus
24881 extern "C"
24882 #endif
24883 char getgroups ();
24885 main ()
24887 return getgroups ();
24889 return 0;
24891 _ACEOF
24892 if ac_fn_c_try_link "$LINENO"; then :
24893 ac_cv_lib_bsd_getgroups=yes
24894 else
24895 ac_cv_lib_bsd_getgroups=no
24897 rm -f core conftest.err conftest.$ac_objext \
24898 conftest$ac_exeext conftest.$ac_ext
24899 LIBS=$ac_check_lib_save_LIBS
24901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
24902 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
24903 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
24904 GETGROUPS_LIB=-lbsd
24909 # Run the program to test the functionality of the system-supplied
24910 # getgroups function only if there is such a function.
24911 if test $ac_cv_func_getgroups = yes; then
24912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
24913 $as_echo_n "checking for working getgroups... " >&6; }
24914 if test "${ac_cv_func_getgroups_works+set}" = set; then :
24915 $as_echo_n "(cached) " >&6
24916 else
24917 if test "$cross_compiling" = yes; then :
24918 case "$host_os" in # ((
24919 # Guess yes on glibc systems.
24920 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
24921 # If we don't know, assume the worst.
24922 *) ac_cv_func_getgroups_works="guessing no" ;;
24923 esac
24925 else
24926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24927 /* end confdefs.h. */
24928 $ac_includes_default
24930 main ()
24932 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
24933 return getgroups (0, 0) == -1;
24935 return 0;
24938 _ACEOF
24939 if ac_fn_c_try_run "$LINENO"; then :
24940 ac_cv_func_getgroups_works=yes
24941 else
24942 ac_cv_func_getgroups_works=no
24944 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24945 conftest.$ac_objext conftest.beam conftest.$ac_ext
24950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
24951 $as_echo "$ac_cv_func_getgroups_works" >&6; }
24952 else
24953 ac_cv_func_getgroups_works=no
24955 case "$ac_cv_func_getgroups_works" in
24956 *yes)
24958 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
24961 esac
24962 LIBS=$ac_save_LIBS
24965 # Solaris 9 and 10 need -lgen to get the eaccess function.
24966 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
24967 # programs in the package would end up linked with that potentially-shared
24968 # library, inducing unnecessary run-time overhead.
24969 LIB_EACCESS=
24971 gl_saved_libs=$LIBS
24972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
24973 $as_echo_n "checking for library containing eaccess... " >&6; }
24974 if test "${ac_cv_search_eaccess+set}" = set; then :
24975 $as_echo_n "(cached) " >&6
24976 else
24977 ac_func_search_save_LIBS=$LIBS
24978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24979 /* end confdefs.h. */
24981 /* Override any GCC internal prototype to avoid an error.
24982 Use char because int might match the return type of a GCC
24983 builtin and then its argument prototype would still apply. */
24984 #ifdef __cplusplus
24985 extern "C"
24986 #endif
24987 char eaccess ();
24989 main ()
24991 return eaccess ();
24993 return 0;
24995 _ACEOF
24996 for ac_lib in '' gen; do
24997 if test -z "$ac_lib"; then
24998 ac_res="none required"
24999 else
25000 ac_res=-l$ac_lib
25001 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25003 if ac_fn_c_try_link "$LINENO"; then :
25004 ac_cv_search_eaccess=$ac_res
25006 rm -f core conftest.err conftest.$ac_objext \
25007 conftest$ac_exeext
25008 if test "${ac_cv_search_eaccess+set}" = set; then :
25009 break
25011 done
25012 if test "${ac_cv_search_eaccess+set}" = set; then :
25014 else
25015 ac_cv_search_eaccess=no
25017 rm conftest.$ac_ext
25018 LIBS=$ac_func_search_save_LIBS
25020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
25021 $as_echo "$ac_cv_search_eaccess" >&6; }
25022 ac_res=$ac_cv_search_eaccess
25023 if test "$ac_res" != no; then :
25024 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25025 test "$ac_cv_search_eaccess" = "none required" ||
25026 LIB_EACCESS=$ac_cv_search_eaccess
25029 for ac_func in eaccess
25030 do :
25031 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
25032 if test "x$ac_cv_func_eaccess" = x""yes; then :
25033 cat >>confdefs.h <<_ACEOF
25034 #define HAVE_EACCESS 1
25035 _ACEOF
25038 done
25040 LIBS=$gl_saved_libs
25048 GNULIB_EUIDACCESS=1
25054 gl_gnulib_enabled_euidaccess=true
25055 if test $HAVE_EUIDACCESS = 0; then
25056 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
25058 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
25059 if test $HAVE_EUIDACCESS = 0; then
25060 func_gl_gnulib_m4code_stat
25064 func_gl_gnulib_m4code_getgroups ()
25066 if ! $gl_gnulib_enabled_getgroups; then
25072 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
25073 if test "x$ac_cv_func_getgroups" = x""yes; then :
25078 # If we don't yet have getgroups, see if it's in -lbsd.
25079 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
25080 ac_save_LIBS=$LIBS
25081 if test $ac_cv_func_getgroups = no; then
25082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
25083 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
25084 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
25085 $as_echo_n "(cached) " >&6
25086 else
25087 ac_check_lib_save_LIBS=$LIBS
25088 LIBS="-lbsd $LIBS"
25089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25090 /* end confdefs.h. */
25092 /* Override any GCC internal prototype to avoid an error.
25093 Use char because int might match the return type of a GCC
25094 builtin and then its argument prototype would still apply. */
25095 #ifdef __cplusplus
25096 extern "C"
25097 #endif
25098 char getgroups ();
25100 main ()
25102 return getgroups ();
25104 return 0;
25106 _ACEOF
25107 if ac_fn_c_try_link "$LINENO"; then :
25108 ac_cv_lib_bsd_getgroups=yes
25109 else
25110 ac_cv_lib_bsd_getgroups=no
25112 rm -f core conftest.err conftest.$ac_objext \
25113 conftest$ac_exeext conftest.$ac_ext
25114 LIBS=$ac_check_lib_save_LIBS
25116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
25117 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
25118 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
25119 GETGROUPS_LIB=-lbsd
25124 # Run the program to test the functionality of the system-supplied
25125 # getgroups function only if there is such a function.
25126 if test $ac_cv_func_getgroups = yes; then
25127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
25128 $as_echo_n "checking for working getgroups... " >&6; }
25129 if test "${ac_cv_func_getgroups_works+set}" = set; then :
25130 $as_echo_n "(cached) " >&6
25131 else
25132 if test "$cross_compiling" = yes; then :
25133 case "$host_os" in # ((
25134 # Guess yes on glibc systems.
25135 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
25136 # If we don't know, assume the worst.
25137 *) ac_cv_func_getgroups_works="guessing no" ;;
25138 esac
25140 else
25141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25142 /* end confdefs.h. */
25143 $ac_includes_default
25145 main ()
25147 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
25148 return getgroups (0, 0) == -1;
25150 return 0;
25153 _ACEOF
25154 if ac_fn_c_try_run "$LINENO"; then :
25155 ac_cv_func_getgroups_works=yes
25156 else
25157 ac_cv_func_getgroups_works=no
25159 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25160 conftest.$ac_objext conftest.beam conftest.$ac_ext
25165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
25166 $as_echo "$ac_cv_func_getgroups_works" >&6; }
25167 else
25168 ac_cv_func_getgroups_works=no
25170 case "$ac_cv_func_getgroups_works" in
25171 *yes)
25173 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
25176 esac
25177 LIBS=$ac_save_LIBS
25179 if test $ac_cv_func_getgroups != yes; then
25180 HAVE_GETGROUPS=0
25181 else
25182 if test "$ac_cv_type_getgroups" != gid_t \
25183 || { case "$ac_cv_func_getgroups_works" in
25184 *yes) false;;
25185 *) true;;
25186 esac
25187 }; then
25188 REPLACE_GETGROUPS=1
25190 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
25192 else
25193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
25194 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
25195 if test "${gl_cv_func_getgroups_works+set}" = set; then :
25196 $as_echo_n "(cached) " >&6
25197 else
25198 if test "$cross_compiling" = yes; then :
25199 case "$host_os" in
25200 # Guess yes on glibc systems.
25201 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
25202 # If we don't know, assume the worst.
25203 *) gl_cv_func_getgroups_works="guessing no" ;;
25204 esac
25206 else
25207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25208 /* end confdefs.h. */
25209 $ac_includes_default
25211 main ()
25213 int size = getgroups (0, 0);
25214 gid_t *list = malloc (size * sizeof *list);
25215 return getgroups (-1, list) != -1;
25217 return 0;
25219 _ACEOF
25220 if ac_fn_c_try_run "$LINENO"; then :
25221 gl_cv_func_getgroups_works=yes
25222 else
25223 gl_cv_func_getgroups_works=no
25225 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25226 conftest.$ac_objext conftest.beam conftest.$ac_ext
25230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
25231 $as_echo "$gl_cv_func_getgroups_works" >&6; }
25232 case "$gl_cv_func_getgroups_works" in
25233 *yes) ;;
25234 *) REPLACE_GETGROUPS=1 ;;
25235 esac
25238 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
25240 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
25249 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
25257 GNULIB_GETGROUPS=1
25263 gl_gnulib_enabled_getgroups=true
25266 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
25268 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
25271 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
25274 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
25276 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
25282 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
25283 if test "x$ac_cv_func_group_member" = x""yes; then :
25285 else
25287 HAVE_GROUP_MEMBER=0
25292 if test $HAVE_GROUP_MEMBER = 0; then
25301 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
25312 GNULIB_GROUP_MEMBER=1
25318 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
25319 if test $HAVE_GROUP_MEMBER = 0; then
25320 func_gl_gnulib_m4code_getgroups
25322 if test $HAVE_GROUP_MEMBER = 0; then
25323 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
25327 func_gl_gnulib_m4code_pathmax ()
25329 if ! $gl_gnulib_enabled_pathmax; then
25333 gl_gnulib_enabled_pathmax=true
25336 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
25338 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
25339 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
25342 func_gl_gnulib_m4code_stat ()
25344 if ! $gl_gnulib_enabled_stat; then
25348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
25349 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
25350 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
25351 $as_echo_n "(cached) " >&6
25352 else
25353 if test "$cross_compiling" = yes; then :
25354 case $host_os in
25355 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
25356 *) gl_cv_func_stat_dir_slash="guessing yes";;
25357 esac
25358 else
25359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25360 /* end confdefs.h. */
25361 #include <sys/stat.h>
25364 main ()
25366 struct stat st; return stat (".", &st) != stat ("./", &st);
25368 return 0;
25370 _ACEOF
25371 if ac_fn_c_try_run "$LINENO"; then :
25372 gl_cv_func_stat_dir_slash=yes
25373 else
25374 gl_cv_func_stat_dir_slash=no
25376 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25377 conftest.$ac_objext conftest.beam conftest.$ac_ext
25381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
25382 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
25383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
25384 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
25385 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
25386 $as_echo_n "(cached) " >&6
25387 else
25388 touch conftest.tmp
25389 # Assume that if we have lstat, we can also check symlinks.
25390 if test $ac_cv_func_lstat = yes; then
25391 ln -s conftest.tmp conftest.lnk
25393 if test "$cross_compiling" = yes; then :
25394 case "$host_os" in
25395 # Guess yes on glibc systems.
25396 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
25397 # If we don't know, assume the worst.
25398 *) gl_cv_func_stat_file_slash="guessing no" ;;
25399 esac
25401 else
25402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25403 /* end confdefs.h. */
25404 #include <sys/stat.h>
25407 main ()
25409 int result = 0;
25410 struct stat st;
25411 if (!stat ("conftest.tmp/", &st))
25412 result |= 1;
25413 #if HAVE_LSTAT
25414 if (!stat ("conftest.lnk/", &st))
25415 result |= 2;
25416 #endif
25417 return result;
25420 return 0;
25422 _ACEOF
25423 if ac_fn_c_try_run "$LINENO"; then :
25424 gl_cv_func_stat_file_slash=yes
25425 else
25426 gl_cv_func_stat_file_slash=no
25428 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25429 conftest.$ac_objext conftest.beam conftest.$ac_ext
25432 rm -f conftest.tmp conftest.lnk
25434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
25435 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
25436 case $gl_cv_func_stat_dir_slash in
25437 *no) REPLACE_STAT=1
25439 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
25441 esac
25442 case $gl_cv_func_stat_file_slash in
25443 *no) REPLACE_STAT=1
25445 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
25447 esac
25449 if test $REPLACE_STAT = 1; then
25458 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
25467 GNULIB_STAT=1
25473 gl_gnulib_enabled_stat=true
25474 if test $REPLACE_STAT = 1; then
25475 func_gl_gnulib_m4code_dosname
25477 if test $REPLACE_STAT = 1; then
25478 func_gl_gnulib_m4code_pathmax
25480 if test $REPLACE_STAT = 1; then
25481 func_gl_gnulib_m4code_verify
25485 func_gl_gnulib_m4code_strtoll ()
25487 if ! $gl_gnulib_enabled_strtoll; then
25491 if test "$ac_cv_type_long_long_int" = yes; then
25492 for ac_func in strtoll
25493 do :
25494 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
25495 if test "x$ac_cv_func_strtoll" = x""yes; then :
25496 cat >>confdefs.h <<_ACEOF
25497 #define HAVE_STRTOLL 1
25498 _ACEOF
25501 done
25503 if test $ac_cv_func_strtoll = no; then
25504 HAVE_STRTOLL=0
25508 if test $HAVE_STRTOLL = 0; then
25517 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
25528 GNULIB_STRTOLL=1
25534 gl_gnulib_enabled_strtoll=true
25537 func_gl_gnulib_m4code_strtoull ()
25539 if ! $gl_gnulib_enabled_strtoull; then
25543 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
25544 for ac_func in strtoull
25545 do :
25546 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
25547 if test "x$ac_cv_func_strtoull" = x""yes; then :
25548 cat >>confdefs.h <<_ACEOF
25549 #define HAVE_STRTOULL 1
25550 _ACEOF
25553 done
25555 if test $ac_cv_func_strtoull = no; then
25556 HAVE_STRTOULL=0
25560 if test $HAVE_STRTOULL = 0; then
25569 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
25580 GNULIB_STRTOULL=1
25586 gl_gnulib_enabled_strtoull=true
25589 func_gl_gnulib_m4code_verify ()
25591 if ! $gl_gnulib_enabled_verify; then
25592 gl_gnulib_enabled_verify=true
25595 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
25597 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
25598 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
25601 if test $HAVE_FACCESSAT = 0; then
25602 func_gl_gnulib_m4code_dosname
25604 if test $HAVE_FACCESSAT = 0; then
25605 func_gl_gnulib_m4code_euidaccess
25607 if test $REPLACE_GETOPT = 1; then
25608 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
25610 if test $REPLACE_LSTAT = 1; then
25611 func_gl_gnulib_m4code_dosname
25613 if test $REPLACE_LSTAT = 1; then
25614 func_gl_gnulib_m4code_stat
25616 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25617 func_gl_gnulib_m4code_stat
25619 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
25620 func_gl_gnulib_m4code_strtoll
25622 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
25623 func_gl_gnulib_m4code_verify
25625 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
25626 func_gl_gnulib_m4code_strtoull
25628 if test $ac_cv_func_strtoumax = no; then
25629 func_gl_gnulib_m4code_verify
25632 if $gl_gnulib_enabled_dosname; then
25633 gl_GNULIB_ENABLED_dosname_TRUE=
25634 gl_GNULIB_ENABLED_dosname_FALSE='#'
25635 else
25636 gl_GNULIB_ENABLED_dosname_TRUE='#'
25637 gl_GNULIB_ENABLED_dosname_FALSE=
25640 if $gl_gnulib_enabled_euidaccess; then
25641 gl_GNULIB_ENABLED_euidaccess_TRUE=
25642 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
25643 else
25644 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
25645 gl_GNULIB_ENABLED_euidaccess_FALSE=
25648 if $gl_gnulib_enabled_getgroups; then
25649 gl_GNULIB_ENABLED_getgroups_TRUE=
25650 gl_GNULIB_ENABLED_getgroups_FALSE='#'
25651 else
25652 gl_GNULIB_ENABLED_getgroups_TRUE='#'
25653 gl_GNULIB_ENABLED_getgroups_FALSE=
25656 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
25657 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
25658 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
25659 else
25660 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
25661 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
25664 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
25665 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
25666 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
25667 else
25668 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
25669 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
25672 if $gl_gnulib_enabled_pathmax; then
25673 gl_GNULIB_ENABLED_pathmax_TRUE=
25674 gl_GNULIB_ENABLED_pathmax_FALSE='#'
25675 else
25676 gl_GNULIB_ENABLED_pathmax_TRUE='#'
25677 gl_GNULIB_ENABLED_pathmax_FALSE=
25680 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
25681 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
25682 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
25683 else
25684 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
25685 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
25688 if $gl_gnulib_enabled_stat; then
25689 gl_GNULIB_ENABLED_stat_TRUE=
25690 gl_GNULIB_ENABLED_stat_FALSE='#'
25691 else
25692 gl_GNULIB_ENABLED_stat_TRUE='#'
25693 gl_GNULIB_ENABLED_stat_FALSE=
25696 if $gl_gnulib_enabled_strtoll; then
25697 gl_GNULIB_ENABLED_strtoll_TRUE=
25698 gl_GNULIB_ENABLED_strtoll_FALSE='#'
25699 else
25700 gl_GNULIB_ENABLED_strtoll_TRUE='#'
25701 gl_GNULIB_ENABLED_strtoll_FALSE=
25704 if $gl_gnulib_enabled_strtoull; then
25705 gl_GNULIB_ENABLED_strtoull_TRUE=
25706 gl_GNULIB_ENABLED_strtoull_FALSE='#'
25707 else
25708 gl_GNULIB_ENABLED_strtoull_TRUE='#'
25709 gl_GNULIB_ENABLED_strtoull_FALSE=
25712 if $gl_gnulib_enabled_verify; then
25713 gl_GNULIB_ENABLED_verify_TRUE=
25714 gl_GNULIB_ENABLED_verify_FALSE='#'
25715 else
25716 gl_GNULIB_ENABLED_verify_TRUE='#'
25717 gl_GNULIB_ENABLED_verify_FALSE=
25720 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
25721 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
25722 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
25723 else
25724 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
25725 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
25728 # End of code from modules
25738 gltests_libdeps=
25739 gltests_ltlibdeps=
25749 gl_source_base='tests'
25750 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
25752 gl_module_indicator_condition=$gltests_WITNESS
25763 LIBGNU_LIBDEPS="$gl_libdeps"
25765 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
25768 CFLAGS=$SAVE_CFLAGS
25769 LIBS=$SAVE_LIBS
25771 case "$opsys" in
25772 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
25774 darwin)
25775 ## The -headerpad option tells ld (see man page) to leave room at the
25776 ## end of the header for adding load commands. Needed for dumping.
25777 ## 0x690 is the total size of 30 segment load commands (at 56
25778 ## each); under Cocoa 31 commands are required.
25779 if test "$HAVE_NS" = "yes"; then
25780 libs_nsgui="-framework AppKit"
25781 headerpad_extra=6C8
25782 else
25783 libs_nsgui=
25784 headerpad_extra=690
25786 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
25788 ## This is here because src/Makefile.in did some extra fiddling around
25789 ## with LD_SWITCH_SYSTEM. The cpp logic was:
25790 ## #ifndef LD_SWITCH_SYSTEM
25791 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
25792 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
25793 ## not using gcc, darwin.
25794 ## Because this was done in src/Makefile.in, the resulting part of
25795 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
25796 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
25797 ## rather than LD_SWITCH_SYSTEM.
25798 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
25799 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
25802 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
25803 ## find X at run-time.
25804 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
25805 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
25806 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
25807 ## had different values in configure (in ac_link) and src/Makefile.in.
25808 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
25809 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
25811 *) LD_SWITCH_SYSTEM_TEMACS= ;;
25812 esac
25814 if test "$NS_IMPL_GNUSTEP" = "yes"; then
25815 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
25821 LD_FIRSTFLAG=
25822 ORDINARY_LINK=
25823 case "$opsys" in
25824 ## gnu: GNU needs its own crt0.
25825 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
25827 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
25828 ## library search parth, i.e. it won't search /usr/lib for libc and
25829 ## friends. Using -nostartfiles instead avoids this problem, and
25830 ## will also work on earlier NetBSD releases.
25831 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
25833 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
25834 ## MkLinux/LinuxPPC needs this.
25835 ## s390x-* only supports opsys = gnu-linux so it can be added here.
25836 gnu-*)
25837 case "$canonical" in
25838 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
25839 esac
25841 esac
25844 if test "x$ORDINARY_LINK" = "xyes"; then
25846 LD_FIRSTFLAG=""
25848 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
25851 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
25852 ## freebsd, gnu-* not on powerpc*|s390x*.
25853 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
25855 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
25856 ## places that are difficult to figure out at make time. Fortunately,
25857 ## these same versions allow you to pass arbitrary flags on to the
25858 ## linker, so there is no reason not to use it as a linker.
25860 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
25861 ## searching for libraries in its internal directories, so we have to
25862 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
25863 LD_FIRSTFLAG="-nostdlib"
25866 ## FIXME? What setting of EDIT_LDFLAGS should this have?
25867 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
25872 ## FIXME? The logic here is not precisely the same as that above.
25873 ## There is no check here for a pre-defined LD_FIRSTFLAG.
25874 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
25875 LIB_GCC=
25876 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
25878 case "$opsys" in
25879 freebsd|netbsd|openbsd) LIB_GCC= ;;
25881 gnu-*)
25882 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
25883 ## build on ARM EABI under GNU/Linux. (Bug#5518)
25884 case $host_cpu in
25885 arm*)
25886 LIB_GCC="-lgcc_s"
25889 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
25890 ## immediately undefine it again and redefine it to empty.
25891 ## Was the C_SWITCH_X_SITE part really necessary?
25892 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
25893 LIB_GCC=
25895 esac
25898 ## Ask GCC where to find libgcc.a.
25899 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
25900 esac
25903 ## Common for all window systems
25904 if test "$window_system" != "none"; then
25906 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
25908 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
25915 #### Report on what we decided to do.
25916 #### Report GTK as a toolkit, even if it doesn't use Xt.
25917 #### It makes printing result more understandable as using GTK sets
25918 #### toolkit_scroll_bars to yes by default.
25919 if test "${HAVE_GTK}" = "yes"; then
25920 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
25923 echo "
25924 Configured for \`${canonical}'.
25926 Where should the build process find the source code? ${srcdir}
25927 What compiler should emacs be built with? ${CC} ${CFLAGS}
25928 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
25929 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
25930 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
25931 What window system should Emacs use? ${window_system}
25932 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
25934 if test -n "${x_includes}"; then
25935 echo " Where do we find X Windows header files? ${x_includes}"
25936 else
25937 echo " Where do we find X Windows header files? Standard dirs"
25939 if test -n "${x_libraries}"; then
25940 echo " Where do we find X Windows libraries? ${x_libraries}"
25941 else
25942 echo " Where do we find X Windows libraries? Standard dirs"
25945 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
25946 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
25947 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
25948 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
25949 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
25950 echo " Does Emacs use -lpng? ${HAVE_PNG}"
25951 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
25952 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
25954 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
25955 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
25956 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
25957 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
25958 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
25959 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
25960 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
25962 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
25963 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
25964 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
25965 echo " Does Emacs use -lxft? ${HAVE_XFT}"
25967 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
25968 echo
25970 if test -n "${EMACSDATA}"; then
25971 echo " Environment variable EMACSDATA set to: $EMACSDATA"
25973 if test -n "${EMACSDOC}"; then
25974 echo " Environment variable EMACSDOC set to: $EMACSDOC"
25977 echo
25979 if test "$HAVE_NS" = "yes"; then
25980 echo
25981 echo "You must run \"${MAKE-make} install\" in order to test the built application.
25982 The installed application will go to nextstep/Emacs.app and can be
25983 run or moved from there."
25984 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
25985 echo "The application will be fully self-contained."
25986 else
25987 echo "The lisp resources for the application will be installed under ${prefix}.
25988 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
25989 to run if these resources are not installed."
25991 echo
25994 if test "${opsys}" = "cygwin"; then
25995 case `uname -r` in
25996 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
25997 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
25998 echo
26000 esac
26003 # Remove any trailing slashes in these variables.
26004 test "${prefix}" != NONE &&
26005 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
26006 test "${exec_prefix}" != NONE &&
26007 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
26009 if test "$HAVE_NS" = "yes"; then
26010 if test "$NS_IMPL_GNUSTEP" = yes; then
26011 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"
26013 else
26014 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"
26019 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"
26021 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"
26024 opt_makefile=test/automated/Makefile
26026 if test -f "$srcdir/$opt_makefile.in"; then
26027 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
26028 ac_config_files="$ac_config_files test/automated/Makefile"
26033 opt_makefile=admin/unidata/Makefile
26035 if test -f "$srcdir/$opt_makefile.in"; then
26036 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
26037 ac_config_files="$ac_config_files admin/unidata/Makefile"
26042 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
26046 ac_config_commands="$ac_config_commands mkdirs"
26049 ac_config_commands="$ac_config_commands epaths"
26052 ac_config_commands="$ac_config_commands gdbinit"
26055 cat >confcache <<\_ACEOF
26056 # This file is a shell script that caches the results of configure
26057 # tests run on this system so they can be shared between configure
26058 # scripts and configure runs, see configure's option --config-cache.
26059 # It is not useful on other systems. If it contains results you don't
26060 # want to keep, you may remove or edit it.
26062 # config.status only pays attention to the cache file if you give it
26063 # the --recheck option to rerun configure.
26065 # `ac_cv_env_foo' variables (set or unset) will be overridden when
26066 # loading this file, other *unset* `ac_cv_foo' will be assigned the
26067 # following values.
26069 _ACEOF
26071 # The following way of writing the cache mishandles newlines in values,
26072 # but we know of no workaround that is simple, portable, and efficient.
26073 # So, we kill variables containing newlines.
26074 # Ultrix sh set writes to stderr and can't be redirected directly,
26075 # and sets the high bit in the cache file unless we assign to the vars.
26077 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
26078 eval ac_val=\$$ac_var
26079 case $ac_val in #(
26080 *${as_nl}*)
26081 case $ac_var in #(
26082 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
26083 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
26084 esac
26085 case $ac_var in #(
26086 _ | IFS | as_nl) ;; #(
26087 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
26088 *) { eval $ac_var=; unset $ac_var;} ;;
26089 esac ;;
26090 esac
26091 done
26093 (set) 2>&1 |
26094 case $as_nl`(ac_space=' '; set) 2>&1` in #(
26095 *${as_nl}ac_space=\ *)
26096 # `set' does not quote correctly, so add quotes: double-quote
26097 # substitution turns \\\\ into \\, and sed turns \\ into \.
26098 sed -n \
26099 "s/'/'\\\\''/g;
26100 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
26101 ;; #(
26103 # `set' quotes correctly as required by POSIX, so do not add quotes.
26104 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
26106 esac |
26107 sort
26109 sed '
26110 /^ac_cv_env_/b end
26111 t clear
26112 :clear
26113 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26114 t end
26115 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26116 :end' >>confcache
26117 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
26118 if test -w "$cache_file"; then
26119 test "x$cache_file" != "x/dev/null" &&
26120 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
26121 $as_echo "$as_me: updating cache $cache_file" >&6;}
26122 cat confcache >$cache_file
26123 else
26124 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
26125 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
26128 rm -f confcache
26130 test "x$prefix" = xNONE && prefix=$ac_default_prefix
26131 # Let make expand exec_prefix.
26132 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
26134 DEFS=-DHAVE_CONFIG_H
26136 ac_libobjs=
26137 ac_ltlibobjs=
26138 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
26139 # 1. Remove the extension, and $U if already installed.
26140 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
26141 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
26142 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
26143 # will be set to the directory where LIBOBJS objects are built.
26144 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
26145 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
26146 done
26147 LIBOBJS=$ac_libobjs
26149 LTLIBOBJS=$ac_ltlibobjs
26152 if test -n "$EXEEXT"; then
26153 am__EXEEXT_TRUE=
26154 am__EXEEXT_FALSE='#'
26155 else
26156 am__EXEEXT_TRUE='#'
26157 am__EXEEXT_FALSE=
26160 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
26161 as_fn_error "conditional \"AMDEP\" was never defined.
26162 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26164 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
26165 as_fn_error "conditional \"am__fastdepCC\" was never defined.
26166 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26168 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
26169 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
26170 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26172 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
26173 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
26174 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26177 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
26178 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
26179 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26181 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
26182 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
26183 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26185 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
26186 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
26187 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26189 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
26190 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
26191 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26193 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
26194 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
26195 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26197 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
26198 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
26199 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26201 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
26202 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
26203 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26205 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
26206 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
26207 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26209 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
26210 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
26211 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26213 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
26214 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
26215 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26217 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
26218 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
26219 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26221 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
26222 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
26223 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26225 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
26226 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
26227 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26229 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
26230 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
26231 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26233 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
26234 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
26235 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26237 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
26238 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
26239 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26241 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
26242 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
26243 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26245 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
26246 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
26247 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26250 gl_libobjs=
26251 gl_ltlibobjs=
26252 if test -n "$gl_LIBOBJS"; then
26253 # Remove the extension.
26254 sed_drop_objext='s/\.o$//;s/\.obj$//'
26255 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
26256 gl_libobjs="$gl_libobjs $i.$ac_objext"
26257 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
26258 done
26260 gl_LIBOBJS=$gl_libobjs
26262 gl_LTLIBOBJS=$gl_ltlibobjs
26266 gltests_libobjs=
26267 gltests_ltlibobjs=
26268 if test -n "$gltests_LIBOBJS"; then
26269 # Remove the extension.
26270 sed_drop_objext='s/\.o$//;s/\.obj$//'
26271 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
26272 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
26273 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
26274 done
26276 gltests_LIBOBJS=$gltests_libobjs
26278 gltests_LTLIBOBJS=$gltests_ltlibobjs
26282 : ${CONFIG_STATUS=./config.status}
26283 ac_write_fail=0
26284 ac_clean_files_save=$ac_clean_files
26285 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
26286 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
26287 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
26288 as_write_fail=0
26289 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
26290 #! $SHELL
26291 # Generated by $as_me.
26292 # Run this file to recreate the current configuration.
26293 # Compiler output produced by configure, useful for debugging
26294 # configure, is in config.log if it exists.
26296 debug=false
26297 ac_cs_recheck=false
26298 ac_cs_silent=false
26300 SHELL=\${CONFIG_SHELL-$SHELL}
26301 export SHELL
26302 _ASEOF
26303 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
26304 ## -------------------- ##
26305 ## M4sh Initialization. ##
26306 ## -------------------- ##
26308 # Be more Bourne compatible
26309 DUALCASE=1; export DUALCASE # for MKS sh
26310 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
26311 emulate sh
26312 NULLCMD=:
26313 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26314 # is contrary to our usage. Disable this feature.
26315 alias -g '${1+"$@"}'='"$@"'
26316 setopt NO_GLOB_SUBST
26317 else
26318 case `(set -o) 2>/dev/null` in #(
26319 *posix*) :
26320 set -o posix ;; #(
26321 *) :
26323 esac
26327 as_nl='
26329 export as_nl
26330 # Printing a long string crashes Solaris 7 /usr/bin/printf.
26331 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
26332 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
26333 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
26334 # Prefer a ksh shell builtin over an external printf program on Solaris,
26335 # but without wasting forks for bash or zsh.
26336 if test -z "$BASH_VERSION$ZSH_VERSION" \
26337 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
26338 as_echo='print -r --'
26339 as_echo_n='print -rn --'
26340 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
26341 as_echo='printf %s\n'
26342 as_echo_n='printf %s'
26343 else
26344 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
26345 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
26346 as_echo_n='/usr/ucb/echo -n'
26347 else
26348 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
26349 as_echo_n_body='eval
26350 arg=$1;
26351 case $arg in #(
26352 *"$as_nl"*)
26353 expr "X$arg" : "X\\(.*\\)$as_nl";
26354 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
26355 esac;
26356 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
26358 export as_echo_n_body
26359 as_echo_n='sh -c $as_echo_n_body as_echo'
26361 export as_echo_body
26362 as_echo='sh -c $as_echo_body as_echo'
26365 # The user is always right.
26366 if test "${PATH_SEPARATOR+set}" != set; then
26367 PATH_SEPARATOR=:
26368 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26369 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26370 PATH_SEPARATOR=';'
26375 # IFS
26376 # We need space, tab and new line, in precisely that order. Quoting is
26377 # there to prevent editors from complaining about space-tab.
26378 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
26379 # splitting by setting IFS to empty value.)
26380 IFS=" "" $as_nl"
26382 # Find who we are. Look in the path if we contain no directory separator.
26383 case $0 in #((
26384 *[\\/]* ) as_myself=$0 ;;
26385 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26386 for as_dir in $PATH
26388 IFS=$as_save_IFS
26389 test -z "$as_dir" && as_dir=.
26390 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26391 done
26392 IFS=$as_save_IFS
26395 esac
26396 # We did not find ourselves, most probably we were run as `sh COMMAND'
26397 # in which case we are not to be found in the path.
26398 if test "x$as_myself" = x; then
26399 as_myself=$0
26401 if test ! -f "$as_myself"; then
26402 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26403 exit 1
26406 # Unset variables that we do not need and which cause bugs (e.g. in
26407 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
26408 # suppresses any "Segmentation fault" message there. '((' could
26409 # trigger a bug in pdksh 5.2.14.
26410 for as_var in BASH_ENV ENV MAIL MAILPATH
26411 do eval test x\${$as_var+set} = xset \
26412 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
26413 done
26414 PS1='$ '
26415 PS2='> '
26416 PS4='+ '
26418 # NLS nuisances.
26419 LC_ALL=C
26420 export LC_ALL
26421 LANGUAGE=C
26422 export LANGUAGE
26424 # CDPATH.
26425 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
26428 # as_fn_error ERROR [LINENO LOG_FD]
26429 # ---------------------------------
26430 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
26431 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
26432 # script with status $?, using 1 if that was 0.
26433 as_fn_error ()
26435 as_status=$?; test $as_status -eq 0 && as_status=1
26436 if test "$3"; then
26437 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
26438 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
26440 $as_echo "$as_me: error: $1" >&2
26441 as_fn_exit $as_status
26442 } # as_fn_error
26445 # as_fn_set_status STATUS
26446 # -----------------------
26447 # Set $? to STATUS, without forking.
26448 as_fn_set_status ()
26450 return $1
26451 } # as_fn_set_status
26453 # as_fn_exit STATUS
26454 # -----------------
26455 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
26456 as_fn_exit ()
26458 set +e
26459 as_fn_set_status $1
26460 exit $1
26461 } # as_fn_exit
26463 # as_fn_unset VAR
26464 # ---------------
26465 # Portably unset VAR.
26466 as_fn_unset ()
26468 { eval $1=; unset $1;}
26470 as_unset=as_fn_unset
26471 # as_fn_append VAR VALUE
26472 # ----------------------
26473 # Append the text in VALUE to the end of the definition contained in VAR. Take
26474 # advantage of any shell optimizations that allow amortized linear growth over
26475 # repeated appends, instead of the typical quadratic growth present in naive
26476 # implementations.
26477 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
26478 eval 'as_fn_append ()
26480 eval $1+=\$2
26482 else
26483 as_fn_append ()
26485 eval $1=\$$1\$2
26487 fi # as_fn_append
26489 # as_fn_arith ARG...
26490 # ------------------
26491 # Perform arithmetic evaluation on the ARGs, and store the result in the
26492 # global $as_val. Take advantage of shells that can avoid forks. The arguments
26493 # must be portable across $(()) and expr.
26494 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
26495 eval 'as_fn_arith ()
26497 as_val=$(( $* ))
26499 else
26500 as_fn_arith ()
26502 as_val=`expr "$@" || test $? -eq 1`
26504 fi # as_fn_arith
26507 if expr a : '\(a\)' >/dev/null 2>&1 &&
26508 test "X`expr 00001 : '.*\(...\)'`" = X001; then
26509 as_expr=expr
26510 else
26511 as_expr=false
26514 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26515 as_basename=basename
26516 else
26517 as_basename=false
26520 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26521 as_dirname=dirname
26522 else
26523 as_dirname=false
26526 as_me=`$as_basename -- "$0" ||
26527 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26528 X"$0" : 'X\(//\)$' \| \
26529 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26530 $as_echo X/"$0" |
26531 sed '/^.*\/\([^/][^/]*\)\/*$/{
26532 s//\1/
26535 /^X\/\(\/\/\)$/{
26536 s//\1/
26539 /^X\/\(\/\).*/{
26540 s//\1/
26543 s/.*/./; q'`
26545 # Avoid depending upon Character Ranges.
26546 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26547 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26548 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26549 as_cr_digits='0123456789'
26550 as_cr_alnum=$as_cr_Letters$as_cr_digits
26552 ECHO_C= ECHO_N= ECHO_T=
26553 case `echo -n x` in #(((((
26554 -n*)
26555 case `echo 'xy\c'` in
26556 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
26557 xy) ECHO_C='\c';;
26558 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
26559 ECHO_T=' ';;
26560 esac;;
26562 ECHO_N='-n';;
26563 esac
26565 rm -f conf$$ conf$$.exe conf$$.file
26566 if test -d conf$$.dir; then
26567 rm -f conf$$.dir/conf$$.file
26568 else
26569 rm -f conf$$.dir
26570 mkdir conf$$.dir 2>/dev/null
26572 if (echo >conf$$.file) 2>/dev/null; then
26573 if ln -s conf$$.file conf$$ 2>/dev/null; then
26574 as_ln_s='ln -s'
26575 # ... but there are two gotchas:
26576 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26577 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26578 # In both cases, we have to default to `cp -p'.
26579 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26580 as_ln_s='cp -p'
26581 elif ln conf$$.file conf$$ 2>/dev/null; then
26582 as_ln_s=ln
26583 else
26584 as_ln_s='cp -p'
26586 else
26587 as_ln_s='cp -p'
26589 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26590 rmdir conf$$.dir 2>/dev/null
26593 # as_fn_mkdir_p
26594 # -------------
26595 # Create "$as_dir" as a directory, including parents if necessary.
26596 as_fn_mkdir_p ()
26599 case $as_dir in #(
26600 -*) as_dir=./$as_dir;;
26601 esac
26602 test -d "$as_dir" || eval $as_mkdir_p || {
26603 as_dirs=
26604 while :; do
26605 case $as_dir in #(
26606 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
26607 *) as_qdir=$as_dir;;
26608 esac
26609 as_dirs="'$as_qdir' $as_dirs"
26610 as_dir=`$as_dirname -- "$as_dir" ||
26611 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26612 X"$as_dir" : 'X\(//\)[^/]' \| \
26613 X"$as_dir" : 'X\(//\)$' \| \
26614 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26615 $as_echo X"$as_dir" |
26616 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26617 s//\1/
26620 /^X\(\/\/\)[^/].*/{
26621 s//\1/
26624 /^X\(\/\/\)$/{
26625 s//\1/
26628 /^X\(\/\).*/{
26629 s//\1/
26632 s/.*/./; q'`
26633 test -d "$as_dir" && break
26634 done
26635 test -z "$as_dirs" || eval "mkdir $as_dirs"
26636 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
26639 } # as_fn_mkdir_p
26640 if mkdir -p . 2>/dev/null; then
26641 as_mkdir_p='mkdir -p "$as_dir"'
26642 else
26643 test -d ./-p && rmdir ./-p
26644 as_mkdir_p=false
26647 if test -x / >/dev/null 2>&1; then
26648 as_test_x='test -x'
26649 else
26650 if ls -dL / >/dev/null 2>&1; then
26651 as_ls_L_option=L
26652 else
26653 as_ls_L_option=
26655 as_test_x='
26656 eval sh -c '\''
26657 if test -d "$1"; then
26658 test -d "$1/.";
26659 else
26660 case $1 in #(
26661 -*)set "./$1";;
26662 esac;
26663 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
26664 ???[sx]*):;;*)false;;esac;fi
26665 '\'' sh
26668 as_executable_p=$as_test_x
26670 # Sed expression to map a string onto a valid CPP name.
26671 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
26673 # Sed expression to map a string onto a valid variable name.
26674 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
26677 exec 6>&1
26678 ## ----------------------------------- ##
26679 ## Main body of $CONFIG_STATUS script. ##
26680 ## ----------------------------------- ##
26681 _ASEOF
26682 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
26684 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26685 # Save the log message, to keep $0 and so on meaningful, and to
26686 # report actual input values of CONFIG_FILES etc. instead of their
26687 # values after options handling.
26688 ac_log="
26689 This file was extended by emacs $as_me 24.3.50, which was
26690 generated by GNU Autoconf 2.65. Invocation command line was
26692 CONFIG_FILES = $CONFIG_FILES
26693 CONFIG_HEADERS = $CONFIG_HEADERS
26694 CONFIG_LINKS = $CONFIG_LINKS
26695 CONFIG_COMMANDS = $CONFIG_COMMANDS
26696 $ $0 $@
26698 on `(hostname || uname -n) 2>/dev/null | sed 1q`
26701 _ACEOF
26703 case $ac_config_files in *"
26704 "*) set x $ac_config_files; shift; ac_config_files=$*;;
26705 esac
26707 case $ac_config_headers in *"
26708 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
26709 esac
26712 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26713 # Files that config.status was made for.
26714 config_files="$ac_config_files"
26715 config_headers="$ac_config_headers"
26716 config_commands="$ac_config_commands"
26718 _ACEOF
26720 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26721 ac_cs_usage="\
26722 \`$as_me' instantiates files and other configuration actions
26723 from templates according to the current configuration. Unless the files
26724 and actions are specified as TAGs, all are instantiated by default.
26726 Usage: $0 [OPTION]... [TAG]...
26728 -h, --help print this help, then exit
26729 -V, --version print version number and configuration settings, then exit
26730 --config print configuration, then exit
26731 -q, --quiet, --silent
26732 do not print progress messages
26733 -d, --debug don't remove temporary files
26734 --recheck update $as_me by reconfiguring in the same conditions
26735 --file=FILE[:TEMPLATE]
26736 instantiate the configuration file FILE
26737 --header=FILE[:TEMPLATE]
26738 instantiate the configuration header FILE
26740 Configuration files:
26741 $config_files
26743 Configuration headers:
26744 $config_headers
26746 Configuration commands:
26747 $config_commands
26749 Report bugs to the package provider."
26751 _ACEOF
26752 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26753 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
26754 ac_cs_version="\\
26755 emacs config.status 24.3.50
26756 configured by $0, generated by GNU Autoconf 2.65,
26757 with options \\"\$ac_cs_config\\"
26759 Copyright (C) 2009 Free Software Foundation, Inc.
26760 This config.status script is free software; the Free Software Foundation
26761 gives unlimited permission to copy, distribute and modify it."
26763 ac_pwd='$ac_pwd'
26764 srcdir='$srcdir'
26765 INSTALL='$INSTALL'
26766 MKDIR_P='$MKDIR_P'
26767 AWK='$AWK'
26768 test -n "\$AWK" || AWK=awk
26769 _ACEOF
26771 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26772 # The default lists apply if the user does not specify any file.
26773 ac_need_defaults=:
26774 while test $# != 0
26776 case $1 in
26777 --*=*)
26778 ac_option=`expr "X$1" : 'X\([^=]*\)='`
26779 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
26780 ac_shift=:
26783 ac_option=$1
26784 ac_optarg=$2
26785 ac_shift=shift
26787 esac
26789 case $ac_option in
26790 # Handling of the options.
26791 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
26792 ac_cs_recheck=: ;;
26793 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
26794 $as_echo "$ac_cs_version"; exit ;;
26795 --config | --confi | --conf | --con | --co | --c )
26796 $as_echo "$ac_cs_config"; exit ;;
26797 --debug | --debu | --deb | --de | --d | -d )
26798 debug=: ;;
26799 --file | --fil | --fi | --f )
26800 $ac_shift
26801 case $ac_optarg in
26802 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26803 esac
26804 as_fn_append CONFIG_FILES " '$ac_optarg'"
26805 ac_need_defaults=false;;
26806 --header | --heade | --head | --hea )
26807 $ac_shift
26808 case $ac_optarg in
26809 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26810 esac
26811 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
26812 ac_need_defaults=false;;
26813 --he | --h)
26814 # Conflict between --help and --header
26815 as_fn_error "ambiguous option: \`$1'
26816 Try \`$0 --help' for more information.";;
26817 --help | --hel | -h )
26818 $as_echo "$ac_cs_usage"; exit ;;
26819 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
26820 | -silent | --silent | --silen | --sile | --sil | --si | --s)
26821 ac_cs_silent=: ;;
26823 # This is an error.
26824 -*) as_fn_error "unrecognized option: \`$1'
26825 Try \`$0 --help' for more information." ;;
26827 *) as_fn_append ac_config_targets " $1"
26828 ac_need_defaults=false ;;
26830 esac
26831 shift
26832 done
26834 ac_configure_extra_args=
26836 if $ac_cs_silent; then
26837 exec 6>/dev/null
26838 ac_configure_extra_args="$ac_configure_extra_args --silent"
26841 _ACEOF
26842 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26843 if \$ac_cs_recheck; then
26844 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
26845 shift
26846 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
26847 CONFIG_SHELL='$SHELL'
26848 export CONFIG_SHELL
26849 exec "\$@"
26852 _ACEOF
26853 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26854 exec 5>>config.log
26856 echo
26857 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
26858 ## Running $as_me. ##
26859 _ASBOX
26860 $as_echo "$ac_log"
26861 } >&5
26863 _ACEOF
26864 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26866 # INIT-COMMANDS
26868 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
26869 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
26871 _ACEOF
26873 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26875 # Handling of arguments.
26876 for ac_config_target in $ac_config_targets
26878 case $ac_config_target in
26879 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
26880 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
26881 "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" ;;
26882 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
26883 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
26884 "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" ;;
26885 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
26886 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
26887 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
26888 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
26889 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
26890 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
26891 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
26892 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
26893 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
26894 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
26895 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
26896 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
26897 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
26898 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
26899 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
26900 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
26901 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
26902 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
26904 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
26905 esac
26906 done
26909 # If the user did not use the arguments to specify the items to instantiate,
26910 # then the envvar interface is used. Set only those that are not.
26911 # We use the long form for the default assignment because of an extremely
26912 # bizarre bug on SunOS 4.1.3.
26913 if $ac_need_defaults; then
26914 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
26915 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
26916 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
26919 # Have a temporary directory for convenience. Make it in the build tree
26920 # simply because there is no reason against having it here, and in addition,
26921 # creating and moving files from /tmp can sometimes cause problems.
26922 # Hook for its removal unless debugging.
26923 # Note that there is a small window in which the directory will not be cleaned:
26924 # after its creation but before its name has been assigned to `$tmp'.
26925 $debug ||
26927 tmp=
26928 trap 'exit_status=$?
26929 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
26931 trap 'as_fn_exit 1' 1 2 13 15
26933 # Create a (secure) tmp directory for tmp files.
26936 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
26937 test -n "$tmp" && test -d "$tmp"
26938 } ||
26940 tmp=./conf$$-$RANDOM
26941 (umask 077 && mkdir "$tmp")
26942 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
26944 # Set up the scripts for CONFIG_FILES section.
26945 # No need to generate them if there are no CONFIG_FILES.
26946 # This happens for instance with `./config.status config.h'.
26947 if test -n "$CONFIG_FILES"; then
26949 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
26950 ac_cs_awk_getline=:
26951 ac_cs_awk_pipe_init=
26952 ac_cs_awk_read_file='
26953 while ((getline aline < (F[key])) > 0)
26954 print(aline)
26955 close(F[key])'
26956 ac_cs_awk_pipe_fini=
26957 else
26958 ac_cs_awk_getline=false
26959 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
26960 ac_cs_awk_read_file='
26961 print "|#_!!_#|"
26962 print "cat " F[key] " &&"
26963 '$ac_cs_awk_pipe_init
26964 # The final `:' finishes the AND list.
26965 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
26967 ac_cr=`echo X | tr X '\015'`
26968 # On cygwin, bash can eat \r inside `` if the user requested igncr.
26969 # But we know of no other shell where ac_cr would be empty at this
26970 # point, so we can use a bashism as a fallback.
26971 if test "x$ac_cr" = x; then
26972 eval ac_cr=\$\'\\r\'
26974 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
26975 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
26976 ac_cs_awk_cr='\r'
26977 else
26978 ac_cs_awk_cr=$ac_cr
26981 echo 'BEGIN {' >"$tmp/subs1.awk" &&
26982 _ACEOF
26984 # Create commands to substitute file output variables.
26986 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
26987 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
26988 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
26989 echo "_ACAWK" &&
26990 echo "_ACEOF"
26991 } >conf$$files.sh &&
26992 . ./conf$$files.sh ||
26993 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
26994 rm -f conf$$files.sh
26997 echo "cat >conf$$subs.awk <<_ACEOF" &&
26998 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
26999 echo "_ACEOF"
27000 } >conf$$subs.sh ||
27001 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27002 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
27003 ac_delim='%!_!# '
27004 for ac_last_try in false false false false false :; do
27005 . ./conf$$subs.sh ||
27006 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27008 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
27009 if test $ac_delim_n = $ac_delim_num; then
27010 break
27011 elif $ac_last_try; then
27012 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27013 else
27014 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27016 done
27017 rm -f conf$$subs.sh
27019 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27020 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
27021 _ACEOF
27022 sed -n '
27024 s/^/S["/; s/!.*/"]=/
27027 s/^[^!]*!//
27028 :repl
27029 t repl
27030 s/'"$ac_delim"'$//
27031 t delim
27034 s/\(.\{148\}\)..*/\1/
27035 t more1
27036 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
27039 b repl
27040 :more1
27041 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27044 s/.\{148\}//
27045 t nl
27046 :delim
27048 s/\(.\{148\}\)..*/\1/
27049 t more2
27050 s/["\\]/\\&/g; s/^/"/; s/$/"/
27053 :more2
27054 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27057 s/.\{148\}//
27058 t delim
27059 ' <conf$$subs.awk | sed '
27060 /^[^""]/{
27062 s/\n//
27064 ' >>$CONFIG_STATUS || ac_write_fail=1
27065 rm -f conf$$subs.awk
27066 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27067 _ACAWK
27068 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
27069 for (key in S) S_is_set[key] = 1
27070 FS = "\a"
27071 \$ac_cs_awk_pipe_init
27074 line = $ 0
27075 nfields = split(line, field, "@")
27076 substed = 0
27077 len = length(field[1])
27078 for (i = 2; i < nfields; i++) {
27079 key = field[i]
27080 keylen = length(key)
27081 if (S_is_set[key]) {
27082 value = S[key]
27083 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
27084 len += length(value) + length(field[++i])
27085 substed = 1
27086 } else
27087 len += 1 + keylen
27089 if (nfields == 3 && !substed) {
27090 key = field[2]
27091 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
27092 \$ac_cs_awk_read_file
27093 next
27096 print line
27098 \$ac_cs_awk_pipe_fini
27099 _ACAWK
27100 _ACEOF
27101 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27102 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
27103 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
27104 else
27106 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
27107 || as_fn_error "could not setup config files machinery" "$LINENO" 5
27108 _ACEOF
27110 # VPATH may cause trouble with some makes, so we remove $(srcdir),
27111 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
27112 # trailing colons and then remove the whole line if VPATH becomes empty
27113 # (actually we leave an empty line to preserve line numbers).
27114 if test "x$srcdir" = x.; then
27115 ac_vpsub='/^[ ]*VPATH[ ]*=/{
27116 s/:*\$(srcdir):*/:/
27117 s/:*\${srcdir}:*/:/
27118 s/:*@srcdir@:*/:/
27119 s/^\([^=]*=[ ]*\):*/\1/
27120 s/:*$//
27121 s/^[^=]*=[ ]*$//
27125 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27126 fi # test -n "$CONFIG_FILES"
27128 # Set up the scripts for CONFIG_HEADERS section.
27129 # No need to generate them if there are no CONFIG_HEADERS.
27130 # This happens for instance with `./config.status Makefile'.
27131 if test -n "$CONFIG_HEADERS"; then
27132 cat >"$tmp/defines.awk" <<\_ACAWK ||
27133 BEGIN {
27134 _ACEOF
27136 # Transform confdefs.h into an awk script `defines.awk', embedded as
27137 # here-document in config.status, that substitutes the proper values into
27138 # config.h.in to produce config.h.
27140 # Create a delimiter string that does not exist in confdefs.h, to ease
27141 # handling of long lines.
27142 ac_delim='%!_!# '
27143 for ac_last_try in false false :; do
27144 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
27145 if test -z "$ac_t"; then
27146 break
27147 elif $ac_last_try; then
27148 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
27149 else
27150 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27152 done
27154 # For the awk script, D is an array of macro values keyed by name,
27155 # likewise P contains macro parameters if any. Preserve backslash
27156 # newline sequences.
27158 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
27159 sed -n '
27160 s/.\{148\}/&'"$ac_delim"'/g
27161 t rset
27162 :rset
27163 s/^[ ]*#[ ]*define[ ][ ]*/ /
27164 t def
27166 :def
27167 s/\\$//
27168 t bsnl
27169 s/["\\]/\\&/g
27170 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27171 D["\1"]=" \3"/p
27172 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
27174 :bsnl
27175 s/["\\]/\\&/g
27176 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27177 D["\1"]=" \3\\\\\\n"\\/p
27178 t cont
27179 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
27180 t cont
27182 :cont
27184 s/.\{148\}/&'"$ac_delim"'/g
27185 t clear
27186 :clear
27187 s/\\$//
27188 t bsnlc
27189 s/["\\]/\\&/g; s/^/"/; s/$/"/p
27191 :bsnlc
27192 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
27193 b cont
27194 ' <confdefs.h | sed '
27195 s/'"$ac_delim"'/"\\\
27196 "/g' >>$CONFIG_STATUS || ac_write_fail=1
27198 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27199 for (key in D) D_is_set[key] = 1
27200 FS = "\a"
27202 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
27203 line = \$ 0
27204 split(line, arg, " ")
27205 if (arg[1] == "#") {
27206 defundef = arg[2]
27207 mac1 = arg[3]
27208 } else {
27209 defundef = substr(arg[1], 2)
27210 mac1 = arg[2]
27212 split(mac1, mac2, "(") #)
27213 macro = mac2[1]
27214 prefix = substr(line, 1, index(line, defundef) - 1)
27215 if (D_is_set[macro]) {
27216 # Preserve the white space surrounding the "#".
27217 print prefix "define", macro P[macro] D[macro]
27218 next
27219 } else {
27220 # Replace #undef with comments. This is necessary, for example,
27221 # in the case of _POSIX_SOURCE, which is predefined and required
27222 # on some systems where configure will not decide to define it.
27223 if (defundef == "undef") {
27224 print "/*", prefix defundef, macro, "*/"
27225 next
27229 { print }
27230 _ACAWK
27231 _ACEOF
27232 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27233 as_fn_error "could not setup config headers machinery" "$LINENO" 5
27234 fi # test -n "$CONFIG_HEADERS"
27237 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
27238 shift
27239 for ac_tag
27241 case $ac_tag in
27242 :[FHLC]) ac_mode=$ac_tag; continue;;
27243 esac
27244 case $ac_mode$ac_tag in
27245 :[FHL]*:*);;
27246 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
27247 :[FH]-) ac_tag=-:-;;
27248 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
27249 esac
27250 ac_save_IFS=$IFS
27251 IFS=:
27252 set x $ac_tag
27253 IFS=$ac_save_IFS
27254 shift
27255 ac_file=$1
27256 shift
27258 case $ac_mode in
27259 :L) ac_source=$1;;
27260 :[FH])
27261 ac_file_inputs=
27262 for ac_f
27264 case $ac_f in
27265 -) ac_f="$tmp/stdin";;
27266 *) # Look for the file first in the build tree, then in the source tree
27267 # (if the path is not absolute). The absolute path cannot be DOS-style,
27268 # because $ac_f cannot contain `:'.
27269 test -f "$ac_f" ||
27270 case $ac_f in
27271 [\\/$]*) false;;
27272 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
27273 esac ||
27274 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
27275 esac
27276 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
27277 as_fn_append ac_file_inputs " '$ac_f'"
27278 done
27280 # Let's still pretend it is `configure' which instantiates (i.e., don't
27281 # use $as_me), people would be surprised to read:
27282 # /* config.h. Generated by config.status. */
27283 configure_input='Generated from '`
27284 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
27285 `' by configure.'
27286 if test x"$ac_file" != x-; then
27287 configure_input="$ac_file. $configure_input"
27288 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
27289 $as_echo "$as_me: creating $ac_file" >&6;}
27291 # Neutralize special characters interpreted by sed in replacement strings.
27292 case $configure_input in #(
27293 *\&* | *\|* | *\\* )
27294 ac_sed_conf_input=`$as_echo "$configure_input" |
27295 sed 's/[\\\\&|]/\\\\&/g'`;; #(
27296 *) ac_sed_conf_input=$configure_input;;
27297 esac
27299 case $ac_tag in
27300 *:-:* | *:-) cat >"$tmp/stdin" \
27301 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
27302 esac
27304 esac
27306 ac_dir=`$as_dirname -- "$ac_file" ||
27307 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27308 X"$ac_file" : 'X\(//\)[^/]' \| \
27309 X"$ac_file" : 'X\(//\)$' \| \
27310 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
27311 $as_echo X"$ac_file" |
27312 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27313 s//\1/
27316 /^X\(\/\/\)[^/].*/{
27317 s//\1/
27320 /^X\(\/\/\)$/{
27321 s//\1/
27324 /^X\(\/\).*/{
27325 s//\1/
27328 s/.*/./; q'`
27329 as_dir="$ac_dir"; as_fn_mkdir_p
27330 ac_builddir=.
27332 case "$ac_dir" in
27333 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
27335 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
27336 # A ".." for each directory in $ac_dir_suffix.
27337 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
27338 case $ac_top_builddir_sub in
27339 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
27340 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
27341 esac ;;
27342 esac
27343 ac_abs_top_builddir=$ac_pwd
27344 ac_abs_builddir=$ac_pwd$ac_dir_suffix
27345 # for backward compatibility:
27346 ac_top_builddir=$ac_top_build_prefix
27348 case $srcdir in
27349 .) # We are building in place.
27350 ac_srcdir=.
27351 ac_top_srcdir=$ac_top_builddir_sub
27352 ac_abs_top_srcdir=$ac_pwd ;;
27353 [\\/]* | ?:[\\/]* ) # Absolute name.
27354 ac_srcdir=$srcdir$ac_dir_suffix;
27355 ac_top_srcdir=$srcdir
27356 ac_abs_top_srcdir=$srcdir ;;
27357 *) # Relative name.
27358 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
27359 ac_top_srcdir=$ac_top_build_prefix$srcdir
27360 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
27361 esac
27362 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
27365 case $ac_mode in
27368 # CONFIG_FILE
27371 case $INSTALL in
27372 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
27373 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
27374 esac
27375 ac_MKDIR_P=$MKDIR_P
27376 case $MKDIR_P in
27377 [\\/$]* | ?:[\\/]* ) ;;
27378 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
27379 esac
27380 _ACEOF
27382 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27383 # If the template does not know about datarootdir, expand it.
27384 # FIXME: This hack should be removed a few years after 2.60.
27385 ac_datarootdir_hack=; ac_datarootdir_seen=
27386 ac_sed_dataroot='
27387 /datarootdir/ {
27391 /@datadir@/p
27392 /@docdir@/p
27393 /@infodir@/p
27394 /@localedir@/p
27395 /@mandir@/p'
27396 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
27397 *datarootdir*) ac_datarootdir_seen=yes;;
27398 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
27399 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
27400 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
27401 _ACEOF
27402 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27403 ac_datarootdir_hack='
27404 s&@datadir@&$datadir&g
27405 s&@docdir@&$docdir&g
27406 s&@infodir@&$infodir&g
27407 s&@localedir@&$localedir&g
27408 s&@mandir@&$mandir&g
27409 s&\\\${datarootdir}&$datarootdir&g' ;;
27410 esac
27411 _ACEOF
27413 # Neutralize VPATH when `$srcdir' = `.'.
27414 # Shell code in configure.ac might set extrasub.
27415 # FIXME: do we really want to maintain this feature?
27416 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27417 ac_sed_extra="$ac_vpsub
27418 $extrasub
27419 _ACEOF
27420 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27422 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
27423 s|@configure_input@|$ac_sed_conf_input|;t t
27424 s&@top_builddir@&$ac_top_builddir_sub&;t t
27425 s&@top_build_prefix@&$ac_top_build_prefix&;t t
27426 s&@srcdir@&$ac_srcdir&;t t
27427 s&@abs_srcdir@&$ac_abs_srcdir&;t t
27428 s&@top_srcdir@&$ac_top_srcdir&;t t
27429 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
27430 s&@builddir@&$ac_builddir&;t t
27431 s&@abs_builddir@&$ac_abs_builddir&;t t
27432 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
27433 s&@INSTALL@&$ac_INSTALL&;t t
27434 s&@MKDIR_P@&$ac_MKDIR_P&;t t
27435 $ac_datarootdir_hack
27437 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
27438 if $ac_cs_awk_getline; then
27439 $AWK -f "$tmp/subs.awk"
27440 else
27441 $AWK -f "$tmp/subs.awk" | $SHELL
27442 fi >$tmp/out \
27443 || as_fn_error "could not create $ac_file" "$LINENO" 5
27445 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
27446 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
27447 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
27448 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27449 which seems to be undefined. Please make sure it is defined." >&5
27450 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27451 which seems to be undefined. Please make sure it is defined." >&2;}
27453 rm -f "$tmp/stdin"
27454 case $ac_file in
27455 -) cat "$tmp/out" && rm -f "$tmp/out";;
27456 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
27457 esac \
27458 || as_fn_error "could not create $ac_file" "$LINENO" 5
27462 # CONFIG_HEADER
27464 if test x"$ac_file" != x-; then
27466 $as_echo "/* $configure_input */" \
27467 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
27468 } >"$tmp/config.h" \
27469 || as_fn_error "could not create $ac_file" "$LINENO" 5
27470 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
27471 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
27472 $as_echo "$as_me: $ac_file is unchanged" >&6;}
27473 else
27474 rm -f "$ac_file"
27475 mv "$tmp/config.h" "$ac_file" \
27476 || as_fn_error "could not create $ac_file" "$LINENO" 5
27478 else
27479 $as_echo "/* $configure_input */" \
27480 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
27481 || as_fn_error "could not create -" "$LINENO" 5
27483 # Compute "$ac_file"'s index in $config_headers.
27484 _am_arg="$ac_file"
27485 _am_stamp_count=1
27486 for _am_header in $config_headers :; do
27487 case $_am_header in
27488 $_am_arg | $_am_arg:* )
27489 break ;;
27491 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
27492 esac
27493 done
27494 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
27495 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27496 X"$_am_arg" : 'X\(//\)[^/]' \| \
27497 X"$_am_arg" : 'X\(//\)$' \| \
27498 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
27499 $as_echo X"$_am_arg" |
27500 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27501 s//\1/
27504 /^X\(\/\/\)[^/].*/{
27505 s//\1/
27508 /^X\(\/\/\)$/{
27509 s//\1/
27512 /^X\(\/\).*/{
27513 s//\1/
27516 s/.*/./; q'`/stamp-h$_am_stamp_count
27519 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
27520 $as_echo "$as_me: executing $ac_file commands" >&6;}
27522 esac
27525 case $ac_file$ac_mode in
27526 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
27527 # Autoconf 2.62 quotes --file arguments for eval, but not when files
27528 # are listed without --file. Let's play safe and only enable the eval
27529 # if we detect the quoting.
27530 case $CONFIG_FILES in
27531 *\'*) eval set x "$CONFIG_FILES" ;;
27532 *) set x $CONFIG_FILES ;;
27533 esac
27534 shift
27535 for mf
27537 # Strip MF so we end up with the name of the file.
27538 mf=`echo "$mf" | sed -e 's/:.*$//'`
27539 # Check whether this is an Automake generated Makefile or not.
27540 # We used to match only the files named `Makefile.in', but
27541 # some people rename them; so instead we look at the file content.
27542 # Grep'ing the first line is not enough: some people post-process
27543 # each Makefile.in and add a new line on top of each file to say so.
27544 # Grep'ing the whole file is not good either: AIX grep has a line
27545 # limit of 2048, but all sed's we know have understand at least 4000.
27546 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
27547 dirpart=`$as_dirname -- "$mf" ||
27548 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27549 X"$mf" : 'X\(//\)[^/]' \| \
27550 X"$mf" : 'X\(//\)$' \| \
27551 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
27552 $as_echo X"$mf" |
27553 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27554 s//\1/
27557 /^X\(\/\/\)[^/].*/{
27558 s//\1/
27561 /^X\(\/\/\)$/{
27562 s//\1/
27565 /^X\(\/\).*/{
27566 s//\1/
27569 s/.*/./; q'`
27570 else
27571 continue
27573 # Extract the definition of DEPDIR, am__include, and am__quote
27574 # from the Makefile without running `make'.
27575 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
27576 test -z "$DEPDIR" && continue
27577 am__include=`sed -n 's/^am__include = //p' < "$mf"`
27578 test -z "am__include" && continue
27579 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
27580 # When using ansi2knr, U may be empty or an underscore; expand it
27581 U=`sed -n 's/^U = //p' < "$mf"`
27582 # Find all dependency output files, they are included files with
27583 # $(DEPDIR) in their names. We invoke sed twice because it is the
27584 # simplest approach to changing $(DEPDIR) to its actual value in the
27585 # expansion.
27586 for file in `sed -n "
27587 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
27588 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
27589 # Make sure the directory exists.
27590 test -f "$dirpart/$file" && continue
27591 fdir=`$as_dirname -- "$file" ||
27592 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27593 X"$file" : 'X\(//\)[^/]' \| \
27594 X"$file" : 'X\(//\)$' \| \
27595 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
27596 $as_echo X"$file" |
27597 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27598 s//\1/
27601 /^X\(\/\/\)[^/].*/{
27602 s//\1/
27605 /^X\(\/\/\)$/{
27606 s//\1/
27609 /^X\(\/\).*/{
27610 s//\1/
27613 s/.*/./; q'`
27614 as_dir=$dirpart/$fdir; as_fn_mkdir_p
27615 # echo "creating $dirpart/$file"
27616 echo '# dummy' > "$dirpart/$file"
27617 done
27618 done
27621 "mkdirs":C)
27622 for dir in etc lisp ; do
27623 test -d ${dir} || mkdir ${dir}
27624 done
27626 "epaths":C)
27627 echo creating src/epaths.h
27628 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
27630 "gdbinit":C)
27631 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
27632 echo creating src/.gdbinit
27633 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
27637 esac
27638 done # for ac_tag
27641 as_fn_exit 0
27642 _ACEOF
27643 ac_clean_files=$ac_clean_files_save
27645 test $ac_write_fail = 0 ||
27646 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
27649 # configure is writing to config.log, and then calls config.status.
27650 # config.status does its own redirection, appending to config.log.
27651 # Unfortunately, on DOS this fails, as config.log is still kept open
27652 # by configure, so config.status won't be able to write to it; its
27653 # output is simply discarded. So we exec the FD to /dev/null,
27654 # effectively closing config.log, so it can be properly (re)opened and
27655 # appended to by config.status. When coming back to configure, we
27656 # need to make the FD available again.
27657 if test "$no_create" != yes; then
27658 ac_cs_success=:
27659 ac_config_status_args=
27660 test "$silent" = yes &&
27661 ac_config_status_args="$ac_config_status_args --quiet"
27662 exec 5>/dev/null
27663 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
27664 exec 5>>config.log
27665 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27666 # would make configure fail if this is the last instruction.
27667 $ac_cs_success || as_fn_exit $?
27669 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
27670 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
27671 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}