* net/socks.el (socks-nslookup-host): Use string-to-number.
[emacs.git] / autogen / configure
blob889c4cc17d56f7e79745bbade35d4f99ffa06f4c
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 LIBS_GNUSTEP
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_gtk_deprecation_warnings
1415 enable_dependency_tracking
1416 enable_largefile
1417 enable_gcc_warnings
1418 enable_link_time_optimization
1419 with_x
1421 ac_precious_vars='build_alias
1422 host_alias
1423 target_alias
1425 CFLAGS
1426 LDFLAGS
1427 LIBS
1428 CPPFLAGS
1430 XMKMF'
1433 # Initialize some variables set by options.
1434 ac_init_help=
1435 ac_init_version=false
1436 ac_unrecognized_opts=
1437 ac_unrecognized_sep=
1438 # The variables have the same names as the options, with
1439 # dashes changed to underlines.
1440 cache_file=/dev/null
1441 exec_prefix=NONE
1442 no_create=
1443 no_recursion=
1444 prefix=NONE
1445 program_prefix=NONE
1446 program_suffix=NONE
1447 program_transform_name=s,x,x,
1448 silent=
1449 site=
1450 srcdir=
1451 verbose=
1452 x_includes=NONE
1453 x_libraries=NONE
1455 # Installation directory options.
1456 # These are left unexpanded so users can "make install exec_prefix=/foo"
1457 # and all the variables that are supposed to be based on exec_prefix
1458 # by default will actually change.
1459 # Use braces instead of parens because sh, perl, etc. also accept them.
1460 # (The list follows the same order as the GNU Coding Standards.)
1461 bindir='${exec_prefix}/bin'
1462 sbindir='${exec_prefix}/sbin'
1463 libexecdir='${exec_prefix}/libexec'
1464 datarootdir='${prefix}/share'
1465 datadir='${datarootdir}'
1466 sysconfdir='${prefix}/etc'
1467 sharedstatedir='${prefix}/com'
1468 localstatedir='${prefix}/var'
1469 includedir='${prefix}/include'
1470 oldincludedir='/usr/include'
1471 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1472 infodir='${datarootdir}/info'
1473 htmldir='${docdir}'
1474 dvidir='${docdir}'
1475 pdfdir='${docdir}'
1476 psdir='${docdir}'
1477 libdir='${exec_prefix}/lib'
1478 localedir='${datarootdir}/locale'
1479 mandir='${datarootdir}/man'
1481 ac_prev=
1482 ac_dashdash=
1483 for ac_option
1485 # If the previous option needs an argument, assign it.
1486 if test -n "$ac_prev"; then
1487 eval $ac_prev=\$ac_option
1488 ac_prev=
1489 continue
1492 case $ac_option in
1493 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1494 *) ac_optarg=yes ;;
1495 esac
1497 # Accept the important Cygnus configure options, so we can diagnose typos.
1499 case $ac_dashdash$ac_option in
1501 ac_dashdash=yes ;;
1503 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1504 ac_prev=bindir ;;
1505 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1506 bindir=$ac_optarg ;;
1508 -build | --build | --buil | --bui | --bu)
1509 ac_prev=build_alias ;;
1510 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1511 build_alias=$ac_optarg ;;
1513 -cache-file | --cache-file | --cache-fil | --cache-fi \
1514 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1515 ac_prev=cache_file ;;
1516 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1517 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1518 cache_file=$ac_optarg ;;
1520 --config-cache | -C)
1521 cache_file=config.cache ;;
1523 -datadir | --datadir | --datadi | --datad)
1524 ac_prev=datadir ;;
1525 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1526 datadir=$ac_optarg ;;
1528 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1529 | --dataroo | --dataro | --datar)
1530 ac_prev=datarootdir ;;
1531 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1532 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1533 datarootdir=$ac_optarg ;;
1535 -disable-* | --disable-*)
1536 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1537 # Reject names that are not valid shell variable names.
1538 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1539 as_fn_error "invalid feature name: $ac_useropt"
1540 ac_useropt_orig=$ac_useropt
1541 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1542 case $ac_user_opts in
1544 "enable_$ac_useropt"
1545 "*) ;;
1546 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1547 ac_unrecognized_sep=', ';;
1548 esac
1549 eval enable_$ac_useropt=no ;;
1551 -docdir | --docdir | --docdi | --doc | --do)
1552 ac_prev=docdir ;;
1553 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1554 docdir=$ac_optarg ;;
1556 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1557 ac_prev=dvidir ;;
1558 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1559 dvidir=$ac_optarg ;;
1561 -enable-* | --enable-*)
1562 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1563 # Reject names that are not valid shell variable names.
1564 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1565 as_fn_error "invalid feature name: $ac_useropt"
1566 ac_useropt_orig=$ac_useropt
1567 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1568 case $ac_user_opts in
1570 "enable_$ac_useropt"
1571 "*) ;;
1572 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1573 ac_unrecognized_sep=', ';;
1574 esac
1575 eval enable_$ac_useropt=\$ac_optarg ;;
1577 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1578 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1579 | --exec | --exe | --ex)
1580 ac_prev=exec_prefix ;;
1581 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1582 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1583 | --exec=* | --exe=* | --ex=*)
1584 exec_prefix=$ac_optarg ;;
1586 -gas | --gas | --ga | --g)
1587 # Obsolete; use --with-gas.
1588 with_gas=yes ;;
1590 -help | --help | --hel | --he | -h)
1591 ac_init_help=long ;;
1592 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1593 ac_init_help=recursive ;;
1594 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1595 ac_init_help=short ;;
1597 -host | --host | --hos | --ho)
1598 ac_prev=host_alias ;;
1599 -host=* | --host=* | --hos=* | --ho=*)
1600 host_alias=$ac_optarg ;;
1602 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1603 ac_prev=htmldir ;;
1604 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1605 | --ht=*)
1606 htmldir=$ac_optarg ;;
1608 -includedir | --includedir | --includedi | --included | --include \
1609 | --includ | --inclu | --incl | --inc)
1610 ac_prev=includedir ;;
1611 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1612 | --includ=* | --inclu=* | --incl=* | --inc=*)
1613 includedir=$ac_optarg ;;
1615 -infodir | --infodir | --infodi | --infod | --info | --inf)
1616 ac_prev=infodir ;;
1617 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1618 infodir=$ac_optarg ;;
1620 -libdir | --libdir | --libdi | --libd)
1621 ac_prev=libdir ;;
1622 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1623 libdir=$ac_optarg ;;
1625 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1626 | --libexe | --libex | --libe)
1627 ac_prev=libexecdir ;;
1628 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1629 | --libexe=* | --libex=* | --libe=*)
1630 libexecdir=$ac_optarg ;;
1632 -localedir | --localedir | --localedi | --localed | --locale)
1633 ac_prev=localedir ;;
1634 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1635 localedir=$ac_optarg ;;
1637 -localstatedir | --localstatedir | --localstatedi | --localstated \
1638 | --localstate | --localstat | --localsta | --localst | --locals)
1639 ac_prev=localstatedir ;;
1640 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1641 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1642 localstatedir=$ac_optarg ;;
1644 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1645 ac_prev=mandir ;;
1646 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1647 mandir=$ac_optarg ;;
1649 -nfp | --nfp | --nf)
1650 # Obsolete; use --without-fp.
1651 with_fp=no ;;
1653 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1654 | --no-cr | --no-c | -n)
1655 no_create=yes ;;
1657 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1658 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1659 no_recursion=yes ;;
1661 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1662 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1663 | --oldin | --oldi | --old | --ol | --o)
1664 ac_prev=oldincludedir ;;
1665 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1666 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1667 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1668 oldincludedir=$ac_optarg ;;
1670 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1671 ac_prev=prefix ;;
1672 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1673 prefix=$ac_optarg ;;
1675 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1676 | --program-pre | --program-pr | --program-p)
1677 ac_prev=program_prefix ;;
1678 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1679 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1680 program_prefix=$ac_optarg ;;
1682 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1683 | --program-suf | --program-su | --program-s)
1684 ac_prev=program_suffix ;;
1685 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1686 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1687 program_suffix=$ac_optarg ;;
1689 -program-transform-name | --program-transform-name \
1690 | --program-transform-nam | --program-transform-na \
1691 | --program-transform-n | --program-transform- \
1692 | --program-transform | --program-transfor \
1693 | --program-transfo | --program-transf \
1694 | --program-trans | --program-tran \
1695 | --progr-tra | --program-tr | --program-t)
1696 ac_prev=program_transform_name ;;
1697 -program-transform-name=* | --program-transform-name=* \
1698 | --program-transform-nam=* | --program-transform-na=* \
1699 | --program-transform-n=* | --program-transform-=* \
1700 | --program-transform=* | --program-transfor=* \
1701 | --program-transfo=* | --program-transf=* \
1702 | --program-trans=* | --program-tran=* \
1703 | --progr-tra=* | --program-tr=* | --program-t=*)
1704 program_transform_name=$ac_optarg ;;
1706 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1707 ac_prev=pdfdir ;;
1708 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1709 pdfdir=$ac_optarg ;;
1711 -psdir | --psdir | --psdi | --psd | --ps)
1712 ac_prev=psdir ;;
1713 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1714 psdir=$ac_optarg ;;
1716 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1717 | -silent | --silent | --silen | --sile | --sil)
1718 silent=yes ;;
1720 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1721 ac_prev=sbindir ;;
1722 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1723 | --sbi=* | --sb=*)
1724 sbindir=$ac_optarg ;;
1726 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1727 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1728 | --sharedst | --shareds | --shared | --share | --shar \
1729 | --sha | --sh)
1730 ac_prev=sharedstatedir ;;
1731 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1732 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1733 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1734 | --sha=* | --sh=*)
1735 sharedstatedir=$ac_optarg ;;
1737 -site | --site | --sit)
1738 ac_prev=site ;;
1739 -site=* | --site=* | --sit=*)
1740 site=$ac_optarg ;;
1742 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1743 ac_prev=srcdir ;;
1744 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1745 srcdir=$ac_optarg ;;
1747 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1748 | --syscon | --sysco | --sysc | --sys | --sy)
1749 ac_prev=sysconfdir ;;
1750 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1751 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1752 sysconfdir=$ac_optarg ;;
1754 -target | --target | --targe | --targ | --tar | --ta | --t)
1755 ac_prev=target_alias ;;
1756 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1757 target_alias=$ac_optarg ;;
1759 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1760 verbose=yes ;;
1762 -version | --version | --versio | --versi | --vers | -V)
1763 ac_init_version=: ;;
1765 -with-* | --with-*)
1766 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1767 # Reject names that are not valid shell variable names.
1768 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1769 as_fn_error "invalid package name: $ac_useropt"
1770 ac_useropt_orig=$ac_useropt
1771 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1772 case $ac_user_opts in
1774 "with_$ac_useropt"
1775 "*) ;;
1776 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1777 ac_unrecognized_sep=', ';;
1778 esac
1779 eval with_$ac_useropt=\$ac_optarg ;;
1781 -without-* | --without-*)
1782 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1783 # Reject names that are not valid shell variable names.
1784 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1785 as_fn_error "invalid package name: $ac_useropt"
1786 ac_useropt_orig=$ac_useropt
1787 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1788 case $ac_user_opts in
1790 "with_$ac_useropt"
1791 "*) ;;
1792 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1793 ac_unrecognized_sep=', ';;
1794 esac
1795 eval with_$ac_useropt=no ;;
1797 --x)
1798 # Obsolete; use --with-x.
1799 with_x=yes ;;
1801 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1802 | --x-incl | --x-inc | --x-in | --x-i)
1803 ac_prev=x_includes ;;
1804 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1805 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1806 x_includes=$ac_optarg ;;
1808 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1809 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1810 ac_prev=x_libraries ;;
1811 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1812 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1813 x_libraries=$ac_optarg ;;
1815 -*) as_fn_error "unrecognized option: \`$ac_option'
1816 Try \`$0 --help' for more information."
1819 *=*)
1820 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1821 # Reject names that are not valid shell variable names.
1822 case $ac_envvar in #(
1823 '' | [0-9]* | *[!_$as_cr_alnum]* )
1824 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1825 esac
1826 eval $ac_envvar=\$ac_optarg
1827 export $ac_envvar ;;
1830 # FIXME: should be removed in autoconf 3.0.
1831 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1832 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1833 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1834 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1837 esac
1838 done
1840 if test -n "$ac_prev"; then
1841 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1842 as_fn_error "missing argument to $ac_option"
1845 if test -n "$ac_unrecognized_opts"; then
1846 case $enable_option_checking in
1847 no) ;;
1848 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1849 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1850 esac
1853 # Check all directory arguments for consistency.
1854 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1855 datadir sysconfdir sharedstatedir localstatedir includedir \
1856 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1857 libdir localedir mandir
1859 eval ac_val=\$$ac_var
1860 # Remove trailing slashes.
1861 case $ac_val in
1862 */ )
1863 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1864 eval $ac_var=\$ac_val;;
1865 esac
1866 # Be sure to have absolute directory names.
1867 case $ac_val in
1868 [\\/$]* | ?:[\\/]* ) continue;;
1869 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1870 esac
1871 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1872 done
1874 # There might be people who depend on the old broken behavior: `$host'
1875 # used to hold the argument of --host etc.
1876 # FIXME: To remove some day.
1877 build=$build_alias
1878 host=$host_alias
1879 target=$target_alias
1881 # FIXME: To remove some day.
1882 if test "x$host_alias" != x; then
1883 if test "x$build_alias" = x; then
1884 cross_compiling=maybe
1885 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1886 If a cross compiler is detected then cross compile mode will be used." >&2
1887 elif test "x$build_alias" != "x$host_alias"; then
1888 cross_compiling=yes
1892 ac_tool_prefix=
1893 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1895 test "$silent" = yes && exec 6>/dev/null
1898 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1899 ac_ls_di=`ls -di .` &&
1900 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1901 as_fn_error "working directory cannot be determined"
1902 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1903 as_fn_error "pwd does not report name of working directory"
1906 # Find the source files, if location was not specified.
1907 if test -z "$srcdir"; then
1908 ac_srcdir_defaulted=yes
1909 # Try the directory containing this script, then the parent directory.
1910 ac_confdir=`$as_dirname -- "$as_myself" ||
1911 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1912 X"$as_myself" : 'X\(//\)[^/]' \| \
1913 X"$as_myself" : 'X\(//\)$' \| \
1914 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1915 $as_echo X"$as_myself" |
1916 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1917 s//\1/
1920 /^X\(\/\/\)[^/].*/{
1921 s//\1/
1924 /^X\(\/\/\)$/{
1925 s//\1/
1928 /^X\(\/\).*/{
1929 s//\1/
1932 s/.*/./; q'`
1933 srcdir=$ac_confdir
1934 if test ! -r "$srcdir/$ac_unique_file"; then
1935 srcdir=..
1937 else
1938 ac_srcdir_defaulted=no
1940 if test ! -r "$srcdir/$ac_unique_file"; then
1941 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1942 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1944 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1945 ac_abs_confdir=`(
1946 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1947 pwd)`
1948 # When building in place, set srcdir=.
1949 if test "$ac_abs_confdir" = "$ac_pwd"; then
1950 srcdir=.
1952 # Remove unnecessary trailing slashes from srcdir.
1953 # Double slashes in file names in object file debugging info
1954 # mess up M-x gdb in Emacs.
1955 case $srcdir in
1956 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1957 esac
1958 for ac_var in $ac_precious_vars; do
1959 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1960 eval ac_env_${ac_var}_value=\$${ac_var}
1961 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1962 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1963 done
1966 # Report the --help message.
1968 if test "$ac_init_help" = "long"; then
1969 # Omit some internal or obsolete options to make the list less imposing.
1970 # This message is too long to be a string in the A/UX 3.1 sh.
1971 cat <<_ACEOF
1972 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
1974 Usage: $0 [OPTION]... [VAR=VALUE]...
1976 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1977 VAR=VALUE. See below for descriptions of some of the useful variables.
1979 Defaults for the options are specified in brackets.
1981 Configuration:
1982 -h, --help display this help and exit
1983 --help=short display options specific to this package
1984 --help=recursive display the short help of all the included packages
1985 -V, --version display version information and exit
1986 -q, --quiet, --silent do not print \`checking...' messages
1987 --cache-file=FILE cache test results in FILE [disabled]
1988 -C, --config-cache alias for \`--cache-file=config.cache'
1989 -n, --no-create do not create output files
1990 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1992 Installation directories:
1993 --prefix=PREFIX install architecture-independent files in PREFIX
1994 [$ac_default_prefix]
1995 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1996 [PREFIX]
1998 By default, \`make install' will install all the files in
1999 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2000 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2001 for instance \`--prefix=\$HOME'.
2003 For better control, use the options below.
2005 Fine tuning of the installation directories:
2006 --bindir=DIR user executables [EPREFIX/bin]
2007 --sbindir=DIR system admin executables [EPREFIX/sbin]
2008 --libexecdir=DIR program executables [EPREFIX/libexec]
2009 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2010 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2011 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2012 --libdir=DIR object code libraries [EPREFIX/lib]
2013 --includedir=DIR C header files [PREFIX/include]
2014 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2015 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2016 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2017 --infodir=DIR info documentation [DATAROOTDIR/info]
2018 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2019 --mandir=DIR man documentation [DATAROOTDIR/man]
2020 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2021 --htmldir=DIR html documentation [DOCDIR]
2022 --dvidir=DIR dvi documentation [DOCDIR]
2023 --pdfdir=DIR pdf documentation [DOCDIR]
2024 --psdir=DIR ps documentation [DOCDIR]
2025 _ACEOF
2027 cat <<\_ACEOF
2029 Program names:
2030 --program-prefix=PREFIX prepend PREFIX to installed program names
2031 --program-suffix=SUFFIX append SUFFIX to installed program names
2032 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2034 X features:
2035 --x-includes=DIR X include files are in DIR
2036 --x-libraries=DIR X library files are in DIR
2038 System types:
2039 --build=BUILD configure for building on BUILD [guessed]
2040 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2041 _ACEOF
2044 if test -n "$ac_init_help"; then
2045 case $ac_init_help in
2046 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2047 esac
2048 cat <<\_ACEOF
2050 Optional Features:
2051 --disable-option-checking ignore unrecognized --enable/--with options
2052 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2053 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2054 --disable-ns-self-contained
2055 disable self contained build under NeXTstep
2056 --enable-locallisppath=PATH
2057 directories Emacs should search for lisp files
2058 specific to this site
2059 --enable-checking[=LIST]
2060 enable expensive run-time checks. With LIST, enable
2061 only specific categories of checks. Categories are:
2062 all,yes,no. Flags are: stringbytes, stringoverrun,
2063 stringfreelist, xmallocoverrun, conslist, glyphs
2064 --enable-check-lisp-object-type
2065 enable compile time checks for the Lisp_Object data
2066 type. This is useful for development for catching
2067 certain types of bugs.
2068 --enable-profiling build emacs with low-level, gprof profiling support.
2069 Mainly useful for debugging Emacs itself. May not
2070 work on all platforms. Stops profiler.el working.
2071 --enable-autodepend automatically generate dependencies to .h-files.
2072 Requires GNU Make and Gcc. Enabled if GNU Make and
2073 Gcc is found
2074 --enable-gtk-deprecation-warnings
2075 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2076 --disable-dependency-tracking speeds up one-time build
2077 --enable-dependency-tracking do not reject slow dependency extractors
2078 --disable-largefile omit support for large files
2079 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2080 intended for developers, and may generate false
2081 alarms when used with older or non-GNU development
2082 tools.
2083 --enable-link-time-optimization
2084 build emacs with link-time optimization. This is
2085 supported only for GCC since 4.5.0.
2087 Optional Packages:
2088 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2089 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2090 --without-all omit almost all features and build small executable
2091 with minimal dependencies
2092 --without-pop don't support POP mail retrieval with movemail
2093 --with-kerberos support Kerberos-authenticated POP
2094 --with-kerberos5 support Kerberos version 5 authenticated POP
2095 --with-hesiod support Hesiod to get the POP server host
2096 --with-mmdf support MMDF mailboxes
2097 --with-mail-unlink unlink, rather than empty, mail spool after reading
2098 --with-mailhost=HOSTNAME
2099 string giving default POP mail host
2100 --without-sound don't compile with sound support
2101 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2102 gtk3, lucid or athena, motif, no)
2103 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2104 --without-xpm don't compile with XPM image support
2105 --without-jpeg don't compile with JPEG image support
2106 --without-tiff don't compile with TIFF image support
2107 --without-gif don't compile with GIF image support
2108 --without-png don't compile with PNG image support
2109 --without-rsvg don't compile with SVG image support
2110 --without-xml2 don't compile with XML parsing support
2111 --without-imagemagick don't compile with ImageMagick image support
2112 --without-xft don't use XFT for anti aliased fonts
2113 --without-libotf don't use libotf for OpenType font support
2114 --without-m17n-flt don't use m17n-flt for text shaping
2115 --without-toolkit-scroll-bars
2116 don't use Motif or Xaw3d scroll bars
2117 --without-xaw3d don't use Xaw3d
2118 --without-xim don't use X11 XIM
2119 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2120 --with-w32 use native MS Windows GUI
2121 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2122 console
2123 --without-dbus don't compile with D-Bus support
2124 --without-gconf don't compile with GConf support
2125 --without-gsettings don't compile with GSettings support
2126 --without-selinux don't compile with SELinux support
2127 --without-acl don't compile with ACL support
2128 --without-gnutls don't use -lgnutls for SSL/TLS support
2129 --without-inotify don't compile with inotify (file-watch) support
2130 --without-makeinfo don't require makeinfo for building manuals
2131 --without-compress-info don't compress the installed Info pages
2132 --with-pkg-config-prog=FILENAME
2133 file name of pkg-config for finding GTK and librsvg
2134 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2135 /usr/lib, or /usr/lib64 on some platforms.
2136 --with-gameuser=USER user for shared game score files
2137 --with-gnustep-conf=FILENAME
2138 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2139 or /etc/GNUstep/GNUstep.conf
2140 --with-x use the X Window System
2142 Some influential environment variables:
2143 CC C compiler command
2144 CFLAGS C compiler flags
2145 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2146 nonstandard directory <lib dir>
2147 LIBS libraries to pass to the linker, e.g. -l<library>
2148 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2149 you have headers in a nonstandard directory <include dir>
2150 CPP C preprocessor
2151 XMKMF Path to xmkmf, Makefile generator for X Window System
2153 Use these variables to override the choices made by `configure' or to help
2154 it to find libraries and programs with nonstandard names/locations.
2156 Report bugs to the package provider.
2157 _ACEOF
2158 ac_status=$?
2161 if test "$ac_init_help" = "recursive"; then
2162 # If there are subdirs, report their specific --help.
2163 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2164 test -d "$ac_dir" ||
2165 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2166 continue
2167 ac_builddir=.
2169 case "$ac_dir" in
2170 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2172 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2173 # A ".." for each directory in $ac_dir_suffix.
2174 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2175 case $ac_top_builddir_sub in
2176 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2177 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2178 esac ;;
2179 esac
2180 ac_abs_top_builddir=$ac_pwd
2181 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2182 # for backward compatibility:
2183 ac_top_builddir=$ac_top_build_prefix
2185 case $srcdir in
2186 .) # We are building in place.
2187 ac_srcdir=.
2188 ac_top_srcdir=$ac_top_builddir_sub
2189 ac_abs_top_srcdir=$ac_pwd ;;
2190 [\\/]* | ?:[\\/]* ) # Absolute name.
2191 ac_srcdir=$srcdir$ac_dir_suffix;
2192 ac_top_srcdir=$srcdir
2193 ac_abs_top_srcdir=$srcdir ;;
2194 *) # Relative name.
2195 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2196 ac_top_srcdir=$ac_top_build_prefix$srcdir
2197 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2198 esac
2199 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2201 cd "$ac_dir" || { ac_status=$?; continue; }
2202 # Check for guested configure.
2203 if test -f "$ac_srcdir/configure.gnu"; then
2204 echo &&
2205 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2206 elif test -f "$ac_srcdir/configure"; then
2207 echo &&
2208 $SHELL "$ac_srcdir/configure" --help=recursive
2209 else
2210 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2211 fi || ac_status=$?
2212 cd "$ac_pwd" || { ac_status=$?; break; }
2213 done
2216 test -n "$ac_init_help" && exit $ac_status
2217 if $ac_init_version; then
2218 cat <<\_ACEOF
2219 emacs configure 24.3.50
2220 generated by GNU Autoconf 2.65
2222 Copyright (C) 2009 Free Software Foundation, Inc.
2223 This configure script is free software; the Free Software Foundation
2224 gives unlimited permission to copy, distribute and modify it.
2225 _ACEOF
2226 exit
2229 ## ------------------------ ##
2230 ## Autoconf initialization. ##
2231 ## ------------------------ ##
2233 # ac_fn_c_try_compile LINENO
2234 # --------------------------
2235 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2236 ac_fn_c_try_compile ()
2238 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2239 rm -f conftest.$ac_objext
2240 if { { ac_try="$ac_compile"
2241 case "(($ac_try" in
2242 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2243 *) ac_try_echo=$ac_try;;
2244 esac
2245 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2246 $as_echo "$ac_try_echo"; } >&5
2247 (eval "$ac_compile") 2>conftest.err
2248 ac_status=$?
2249 if test -s conftest.err; then
2250 grep -v '^ *+' conftest.err >conftest.er1
2251 cat conftest.er1 >&5
2252 mv -f conftest.er1 conftest.err
2254 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2255 test $ac_status = 0; } && {
2256 test -z "$ac_c_werror_flag" ||
2257 test ! -s conftest.err
2258 } && test -s conftest.$ac_objext; then :
2259 ac_retval=0
2260 else
2261 $as_echo "$as_me: failed program was:" >&5
2262 sed 's/^/| /' conftest.$ac_ext >&5
2264 ac_retval=1
2266 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2267 as_fn_set_status $ac_retval
2269 } # ac_fn_c_try_compile
2271 # ac_fn_c_try_cpp LINENO
2272 # ----------------------
2273 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2274 ac_fn_c_try_cpp ()
2276 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2277 if { { ac_try="$ac_cpp conftest.$ac_ext"
2278 case "(($ac_try" in
2279 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2280 *) ac_try_echo=$ac_try;;
2281 esac
2282 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2283 $as_echo "$ac_try_echo"; } >&5
2284 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2285 ac_status=$?
2286 if test -s conftest.err; then
2287 grep -v '^ *+' conftest.err >conftest.er1
2288 cat conftest.er1 >&5
2289 mv -f conftest.er1 conftest.err
2291 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2292 test $ac_status = 0; } >/dev/null && {
2293 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2294 test ! -s conftest.err
2295 }; then :
2296 ac_retval=0
2297 else
2298 $as_echo "$as_me: failed program was:" >&5
2299 sed 's/^/| /' conftest.$ac_ext >&5
2301 ac_retval=1
2303 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2304 as_fn_set_status $ac_retval
2306 } # ac_fn_c_try_cpp
2308 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2309 # -------------------------------------------------------
2310 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2311 # the include files in INCLUDES and setting the cache variable VAR
2312 # accordingly.
2313 ac_fn_c_check_header_mongrel ()
2315 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2316 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2318 $as_echo_n "checking for $2... " >&6; }
2319 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2320 $as_echo_n "(cached) " >&6
2322 eval ac_res=\$$3
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2324 $as_echo "$ac_res" >&6; }
2325 else
2326 # Is the header compilable?
2327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2328 $as_echo_n "checking $2 usability... " >&6; }
2329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2330 /* end confdefs.h. */
2332 #include <$2>
2333 _ACEOF
2334 if ac_fn_c_try_compile "$LINENO"; then :
2335 ac_header_compiler=yes
2336 else
2337 ac_header_compiler=no
2339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2341 $as_echo "$ac_header_compiler" >&6; }
2343 # Is the header present?
2344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2345 $as_echo_n "checking $2 presence... " >&6; }
2346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2347 /* end confdefs.h. */
2348 #include <$2>
2349 _ACEOF
2350 if ac_fn_c_try_cpp "$LINENO"; then :
2351 ac_header_preproc=yes
2352 else
2353 ac_header_preproc=no
2355 rm -f conftest.err conftest.$ac_ext
2356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2357 $as_echo "$ac_header_preproc" >&6; }
2359 # So? What about this header?
2360 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2361 yes:no: )
2362 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2363 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2364 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2365 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2367 no:yes:* )
2368 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2369 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2370 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2371 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2372 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2373 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2374 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2375 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2376 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2377 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2379 esac
2380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2381 $as_echo_n "checking for $2... " >&6; }
2382 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2383 $as_echo_n "(cached) " >&6
2384 else
2385 eval "$3=\$ac_header_compiler"
2387 eval ac_res=\$$3
2388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2389 $as_echo "$ac_res" >&6; }
2391 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2393 } # ac_fn_c_check_header_mongrel
2395 # ac_fn_c_try_run LINENO
2396 # ----------------------
2397 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2398 # that executables *can* be run.
2399 ac_fn_c_try_run ()
2401 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2402 if { { ac_try="$ac_link"
2403 case "(($ac_try" in
2404 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2405 *) ac_try_echo=$ac_try;;
2406 esac
2407 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2408 $as_echo "$ac_try_echo"; } >&5
2409 (eval "$ac_link") 2>&5
2410 ac_status=$?
2411 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2412 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2413 { { case "(($ac_try" in
2414 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2415 *) ac_try_echo=$ac_try;;
2416 esac
2417 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2418 $as_echo "$ac_try_echo"; } >&5
2419 (eval "$ac_try") 2>&5
2420 ac_status=$?
2421 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2422 test $ac_status = 0; }; }; then :
2423 ac_retval=0
2424 else
2425 $as_echo "$as_me: program exited with status $ac_status" >&5
2426 $as_echo "$as_me: failed program was:" >&5
2427 sed 's/^/| /' conftest.$ac_ext >&5
2429 ac_retval=$ac_status
2431 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2432 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2433 as_fn_set_status $ac_retval
2435 } # ac_fn_c_try_run
2437 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2438 # -------------------------------------------------------
2439 # Tests whether HEADER exists and can be compiled using the include files in
2440 # INCLUDES, setting the cache variable VAR accordingly.
2441 ac_fn_c_check_header_compile ()
2443 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2445 $as_echo_n "checking for $2... " >&6; }
2446 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2447 $as_echo_n "(cached) " >&6
2448 else
2449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2450 /* end confdefs.h. */
2452 #include <$2>
2453 _ACEOF
2454 if ac_fn_c_try_compile "$LINENO"; then :
2455 eval "$3=yes"
2456 else
2457 eval "$3=no"
2459 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2461 eval ac_res=\$$3
2462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2463 $as_echo "$ac_res" >&6; }
2464 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2466 } # ac_fn_c_check_header_compile
2468 # ac_fn_c_try_link LINENO
2469 # -----------------------
2470 # Try to link conftest.$ac_ext, and return whether this succeeded.
2471 ac_fn_c_try_link ()
2473 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2474 rm -f conftest.$ac_objext conftest$ac_exeext
2475 if { { ac_try="$ac_link"
2476 case "(($ac_try" in
2477 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2478 *) ac_try_echo=$ac_try;;
2479 esac
2480 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2481 $as_echo "$ac_try_echo"; } >&5
2482 (eval "$ac_link") 2>conftest.err
2483 ac_status=$?
2484 if test -s conftest.err; then
2485 grep -v '^ *+' conftest.err >conftest.er1
2486 cat conftest.er1 >&5
2487 mv -f conftest.er1 conftest.err
2489 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2490 test $ac_status = 0; } && {
2491 test -z "$ac_c_werror_flag" ||
2492 test ! -s conftest.err
2493 } && test -s conftest$ac_exeext && {
2494 test "$cross_compiling" = yes ||
2495 $as_test_x conftest$ac_exeext
2496 }; then :
2497 ac_retval=0
2498 else
2499 $as_echo "$as_me: failed program was:" >&5
2500 sed 's/^/| /' conftest.$ac_ext >&5
2502 ac_retval=1
2504 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2505 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2506 # interfere with the next link command; also delete a directory that is
2507 # left behind by Apple's compiler. We do this before executing the actions.
2508 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2509 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2510 as_fn_set_status $ac_retval
2512 } # ac_fn_c_try_link
2514 # ac_fn_c_check_decl LINENO SYMBOL VAR
2515 # ------------------------------------
2516 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2517 ac_fn_c_check_decl ()
2519 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2521 $as_echo_n "checking whether $2 is declared... " >&6; }
2522 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2523 $as_echo_n "(cached) " >&6
2524 else
2525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2526 /* end confdefs.h. */
2529 main ()
2531 #ifndef $2
2532 (void) $2;
2533 #endif
2536 return 0;
2538 _ACEOF
2539 if ac_fn_c_try_compile "$LINENO"; then :
2540 eval "$3=yes"
2541 else
2542 eval "$3=no"
2544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2546 eval ac_res=\$$3
2547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2548 $as_echo "$ac_res" >&6; }
2549 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2551 } # ac_fn_c_check_decl
2553 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2554 # ----------------------------------------------
2555 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2556 ac_fn_c_check_header_preproc ()
2558 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2560 $as_echo_n "checking for $2... " >&6; }
2561 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2562 $as_echo_n "(cached) " >&6
2563 else
2564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2565 /* end confdefs.h. */
2566 #include <$2>
2567 _ACEOF
2568 if ac_fn_c_try_cpp "$LINENO"; then :
2569 eval "$3=yes"
2570 else
2571 eval "$3=no"
2573 rm -f conftest.err conftest.$ac_ext
2575 eval ac_res=\$$3
2576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2577 $as_echo "$ac_res" >&6; }
2578 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2580 } # ac_fn_c_check_header_preproc
2582 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2583 # ----------------------------------------------------
2584 # Tries to find if the field MEMBER exists in type AGGR, after including
2585 # INCLUDES, setting cache variable VAR accordingly.
2586 ac_fn_c_check_member ()
2588 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2590 $as_echo_n "checking for $2.$3... " >&6; }
2591 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2592 $as_echo_n "(cached) " >&6
2593 else
2594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2595 /* end confdefs.h. */
2598 main ()
2600 static $2 ac_aggr;
2601 if (ac_aggr.$3)
2602 return 0;
2604 return 0;
2606 _ACEOF
2607 if ac_fn_c_try_compile "$LINENO"; then :
2608 eval "$4=yes"
2609 else
2610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2611 /* end confdefs.h. */
2614 main ()
2616 static $2 ac_aggr;
2617 if (sizeof ac_aggr.$3)
2618 return 0;
2620 return 0;
2622 _ACEOF
2623 if ac_fn_c_try_compile "$LINENO"; then :
2624 eval "$4=yes"
2625 else
2626 eval "$4=no"
2628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2632 eval ac_res=\$$4
2633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2634 $as_echo "$ac_res" >&6; }
2635 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2637 } # ac_fn_c_check_member
2639 # ac_fn_c_check_func LINENO FUNC VAR
2640 # ----------------------------------
2641 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2642 ac_fn_c_check_func ()
2644 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2646 $as_echo_n "checking for $2... " >&6; }
2647 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2648 $as_echo_n "(cached) " >&6
2649 else
2650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2651 /* end confdefs.h. */
2652 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2653 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2654 #define $2 innocuous_$2
2656 /* System header to define __stub macros and hopefully few prototypes,
2657 which can conflict with char $2 (); below.
2658 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2659 <limits.h> exists even on freestanding compilers. */
2661 #ifdef __STDC__
2662 # include <limits.h>
2663 #else
2664 # include <assert.h>
2665 #endif
2667 #undef $2
2669 /* Override any GCC internal prototype to avoid an error.
2670 Use char because int might match the return type of a GCC
2671 builtin and then its argument prototype would still apply. */
2672 #ifdef __cplusplus
2673 extern "C"
2674 #endif
2675 char $2 ();
2676 /* The GNU C library defines this for functions which it implements
2677 to always fail with ENOSYS. Some functions are actually named
2678 something starting with __ and the normal name is an alias. */
2679 #if defined __stub_$2 || defined __stub___$2
2680 choke me
2681 #endif
2684 main ()
2686 return $2 ();
2688 return 0;
2690 _ACEOF
2691 if ac_fn_c_try_link "$LINENO"; then :
2692 eval "$3=yes"
2693 else
2694 eval "$3=no"
2696 rm -f core conftest.err conftest.$ac_objext \
2697 conftest$ac_exeext conftest.$ac_ext
2699 eval ac_res=\$$3
2700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2701 $as_echo "$ac_res" >&6; }
2702 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2704 } # ac_fn_c_check_func
2706 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2707 # -------------------------------------------
2708 # Tests whether TYPE exists after having included INCLUDES, setting cache
2709 # variable VAR accordingly.
2710 ac_fn_c_check_type ()
2712 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2714 $as_echo_n "checking for $2... " >&6; }
2715 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2716 $as_echo_n "(cached) " >&6
2717 else
2718 eval "$3=no"
2719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2720 /* end confdefs.h. */
2723 main ()
2725 if (sizeof ($2))
2726 return 0;
2728 return 0;
2730 _ACEOF
2731 if ac_fn_c_try_compile "$LINENO"; then :
2732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2733 /* end confdefs.h. */
2736 main ()
2738 if (sizeof (($2)))
2739 return 0;
2741 return 0;
2743 _ACEOF
2744 if ac_fn_c_try_compile "$LINENO"; then :
2746 else
2747 eval "$3=yes"
2749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2753 eval ac_res=\$$3
2754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2755 $as_echo "$ac_res" >&6; }
2756 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2758 } # ac_fn_c_check_type
2760 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2761 # --------------------------------------------
2762 # Tries to find the compile-time value of EXPR in a program that includes
2763 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2764 # computed
2765 ac_fn_c_compute_int ()
2767 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2768 if test "$cross_compiling" = yes; then
2769 # Depending upon the size, compute the lo and hi bounds.
2770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2771 /* end confdefs.h. */
2774 main ()
2776 static int test_array [1 - 2 * !(($2) >= 0)];
2777 test_array [0] = 0
2780 return 0;
2782 _ACEOF
2783 if ac_fn_c_try_compile "$LINENO"; then :
2784 ac_lo=0 ac_mid=0
2785 while :; do
2786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2787 /* end confdefs.h. */
2790 main ()
2792 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2793 test_array [0] = 0
2796 return 0;
2798 _ACEOF
2799 if ac_fn_c_try_compile "$LINENO"; then :
2800 ac_hi=$ac_mid; break
2801 else
2802 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2803 if test $ac_lo -le $ac_mid; then
2804 ac_lo= ac_hi=
2805 break
2807 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2809 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2810 done
2811 else
2812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2813 /* end confdefs.h. */
2816 main ()
2818 static int test_array [1 - 2 * !(($2) < 0)];
2819 test_array [0] = 0
2822 return 0;
2824 _ACEOF
2825 if ac_fn_c_try_compile "$LINENO"; then :
2826 ac_hi=-1 ac_mid=-1
2827 while :; do
2828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2829 /* end confdefs.h. */
2832 main ()
2834 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2835 test_array [0] = 0
2838 return 0;
2840 _ACEOF
2841 if ac_fn_c_try_compile "$LINENO"; then :
2842 ac_lo=$ac_mid; break
2843 else
2844 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2845 if test $ac_mid -le $ac_hi; then
2846 ac_lo= ac_hi=
2847 break
2849 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2852 done
2853 else
2854 ac_lo= ac_hi=
2856 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2859 # Binary search between lo and hi bounds.
2860 while test "x$ac_lo" != "x$ac_hi"; do
2861 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2863 /* end confdefs.h. */
2866 main ()
2868 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2869 test_array [0] = 0
2872 return 0;
2874 _ACEOF
2875 if ac_fn_c_try_compile "$LINENO"; then :
2876 ac_hi=$ac_mid
2877 else
2878 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2881 done
2882 case $ac_lo in #((
2883 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2884 '') ac_retval=1 ;;
2885 esac
2886 else
2887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2888 /* end confdefs.h. */
2890 static long int longval () { return $2; }
2891 static unsigned long int ulongval () { return $2; }
2892 #include <stdio.h>
2893 #include <stdlib.h>
2895 main ()
2898 FILE *f = fopen ("conftest.val", "w");
2899 if (! f)
2900 return 1;
2901 if (($2) < 0)
2903 long int i = longval ();
2904 if (i != ($2))
2905 return 1;
2906 fprintf (f, "%ld", i);
2908 else
2910 unsigned long int i = ulongval ();
2911 if (i != ($2))
2912 return 1;
2913 fprintf (f, "%lu", i);
2915 /* Do not output a trailing newline, as this causes \r\n confusion
2916 on some platforms. */
2917 return ferror (f) || fclose (f) != 0;
2920 return 0;
2922 _ACEOF
2923 if ac_fn_c_try_run "$LINENO"; then :
2924 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2925 else
2926 ac_retval=1
2928 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2929 conftest.$ac_objext conftest.beam conftest.$ac_ext
2930 rm -f conftest.val
2933 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2934 as_fn_set_status $ac_retval
2936 } # ac_fn_c_compute_int
2937 cat >config.log <<_ACEOF
2938 This file contains any messages produced by compilers while
2939 running configure, to aid debugging if configure makes a mistake.
2941 It was created by emacs $as_me 24.3.50, which was
2942 generated by GNU Autoconf 2.65. Invocation command line was
2944 $ $0 $@
2946 _ACEOF
2947 exec 5>>config.log
2949 cat <<_ASUNAME
2950 ## --------- ##
2951 ## Platform. ##
2952 ## --------- ##
2954 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2955 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2956 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2957 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2958 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2960 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2961 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2963 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2964 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2965 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2966 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2967 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2968 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2969 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2971 _ASUNAME
2973 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2974 for as_dir in $PATH
2976 IFS=$as_save_IFS
2977 test -z "$as_dir" && as_dir=.
2978 $as_echo "PATH: $as_dir"
2979 done
2980 IFS=$as_save_IFS
2982 } >&5
2984 cat >&5 <<_ACEOF
2987 ## ----------- ##
2988 ## Core tests. ##
2989 ## ----------- ##
2991 _ACEOF
2994 # Keep a trace of the command line.
2995 # Strip out --no-create and --no-recursion so they do not pile up.
2996 # Strip out --silent because we don't want to record it for future runs.
2997 # Also quote any args containing shell meta-characters.
2998 # Make two passes to allow for proper duplicate-argument suppression.
2999 ac_configure_args=
3000 ac_configure_args0=
3001 ac_configure_args1=
3002 ac_must_keep_next=false
3003 for ac_pass in 1 2
3005 for ac_arg
3007 case $ac_arg in
3008 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3009 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3010 | -silent | --silent | --silen | --sile | --sil)
3011 continue ;;
3012 *\'*)
3013 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3014 esac
3015 case $ac_pass in
3016 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3018 as_fn_append ac_configure_args1 " '$ac_arg'"
3019 if test $ac_must_keep_next = true; then
3020 ac_must_keep_next=false # Got value, back to normal.
3021 else
3022 case $ac_arg in
3023 *=* | --config-cache | -C | -disable-* | --disable-* \
3024 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3025 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3026 | -with-* | --with-* | -without-* | --without-* | --x)
3027 case "$ac_configure_args0 " in
3028 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3029 esac
3031 -* ) ac_must_keep_next=true ;;
3032 esac
3034 as_fn_append ac_configure_args " '$ac_arg'"
3036 esac
3037 done
3038 done
3039 { ac_configure_args0=; unset ac_configure_args0;}
3040 { ac_configure_args1=; unset ac_configure_args1;}
3042 # When interrupted or exit'd, cleanup temporary files, and complete
3043 # config.log. We remove comments because anyway the quotes in there
3044 # would cause problems or look ugly.
3045 # WARNING: Use '\'' to represent an apostrophe within the trap.
3046 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3047 trap 'exit_status=$?
3048 # Save into config.log some information that might help in debugging.
3050 echo
3052 cat <<\_ASBOX
3053 ## ---------------- ##
3054 ## Cache variables. ##
3055 ## ---------------- ##
3056 _ASBOX
3057 echo
3058 # The following way of writing the cache mishandles newlines in values,
3060 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3061 eval ac_val=\$$ac_var
3062 case $ac_val in #(
3063 *${as_nl}*)
3064 case $ac_var in #(
3065 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3066 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3067 esac
3068 case $ac_var in #(
3069 _ | IFS | as_nl) ;; #(
3070 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3071 *) { eval $ac_var=; unset $ac_var;} ;;
3072 esac ;;
3073 esac
3074 done
3075 (set) 2>&1 |
3076 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3077 *${as_nl}ac_space=\ *)
3078 sed -n \
3079 "s/'\''/'\''\\\\'\'''\''/g;
3080 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3081 ;; #(
3083 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3085 esac |
3086 sort
3088 echo
3090 cat <<\_ASBOX
3091 ## ----------------- ##
3092 ## Output variables. ##
3093 ## ----------------- ##
3094 _ASBOX
3095 echo
3096 for ac_var in $ac_subst_vars
3098 eval ac_val=\$$ac_var
3099 case $ac_val in
3100 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3101 esac
3102 $as_echo "$ac_var='\''$ac_val'\''"
3103 done | sort
3104 echo
3106 if test -n "$ac_subst_files"; then
3107 cat <<\_ASBOX
3108 ## ------------------- ##
3109 ## File substitutions. ##
3110 ## ------------------- ##
3111 _ASBOX
3112 echo
3113 for ac_var in $ac_subst_files
3115 eval ac_val=\$$ac_var
3116 case $ac_val in
3117 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3118 esac
3119 $as_echo "$ac_var='\''$ac_val'\''"
3120 done | sort
3121 echo
3124 if test -s confdefs.h; then
3125 cat <<\_ASBOX
3126 ## ----------- ##
3127 ## confdefs.h. ##
3128 ## ----------- ##
3129 _ASBOX
3130 echo
3131 cat confdefs.h
3132 echo
3134 test "$ac_signal" != 0 &&
3135 $as_echo "$as_me: caught signal $ac_signal"
3136 $as_echo "$as_me: exit $exit_status"
3137 } >&5
3138 rm -f core *.core core.conftest.* &&
3139 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3140 exit $exit_status
3142 for ac_signal in 1 2 13 15; do
3143 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3144 done
3145 ac_signal=0
3147 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3148 rm -f -r conftest* confdefs.h
3150 $as_echo "/* confdefs.h */" > confdefs.h
3152 # Predefined preprocessor variables.
3154 cat >>confdefs.h <<_ACEOF
3155 #define PACKAGE_NAME "$PACKAGE_NAME"
3156 _ACEOF
3158 cat >>confdefs.h <<_ACEOF
3159 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3160 _ACEOF
3162 cat >>confdefs.h <<_ACEOF
3163 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3164 _ACEOF
3166 cat >>confdefs.h <<_ACEOF
3167 #define PACKAGE_STRING "$PACKAGE_STRING"
3168 _ACEOF
3170 cat >>confdefs.h <<_ACEOF
3171 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3172 _ACEOF
3174 cat >>confdefs.h <<_ACEOF
3175 #define PACKAGE_URL "$PACKAGE_URL"
3176 _ACEOF
3179 # Let the site file select an alternate cache file if it wants to.
3180 # Prefer an explicitly selected file to automatically selected ones.
3181 ac_site_file1=NONE
3182 ac_site_file2=NONE
3183 if test -n "$CONFIG_SITE"; then
3184 ac_site_file1=$CONFIG_SITE
3185 elif test "x$prefix" != xNONE; then
3186 ac_site_file1=$prefix/share/config.site
3187 ac_site_file2=$prefix/etc/config.site
3188 else
3189 ac_site_file1=$ac_default_prefix/share/config.site
3190 ac_site_file2=$ac_default_prefix/etc/config.site
3192 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3194 test "x$ac_site_file" = xNONE && continue
3195 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3196 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3197 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3198 sed 's/^/| /' "$ac_site_file" >&5
3199 . "$ac_site_file"
3201 done
3203 if test -r "$cache_file"; then
3204 # Some versions of bash will fail to source /dev/null (special files
3205 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3206 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3207 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3208 $as_echo "$as_me: loading cache $cache_file" >&6;}
3209 case $cache_file in
3210 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3211 *) . "./$cache_file";;
3212 esac
3214 else
3215 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3216 $as_echo "$as_me: creating cache $cache_file" >&6;}
3217 >$cache_file
3220 as_fn_append ac_header_list " linux/version.h"
3221 as_fn_append ac_header_list " sys/systeminfo.h"
3222 as_fn_append ac_header_list " coff.h"
3223 as_fn_append ac_header_list " pty.h"
3224 as_fn_append ac_header_list " sys/vlimit.h"
3225 as_fn_append ac_header_list " sys/resource.h"
3226 as_fn_append ac_header_list " sys/utsname.h"
3227 as_fn_append ac_header_list " pwd.h"
3228 as_fn_append ac_header_list " utmp.h"
3229 as_fn_append ac_header_list " util.h"
3230 as_fn_append ac_header_list " sys/socket.h"
3231 as_fn_append ac_header_list " stdlib.h"
3232 as_fn_append ac_header_list " unistd.h"
3233 as_fn_append ac_header_list " sys/param.h"
3234 as_fn_append ac_header_list " pthread.h"
3235 as_fn_append ac_header_list " malloc/malloc.h"
3236 as_fn_append ac_header_list " maillock.h"
3237 as_fn_append ac_header_list " sys/un.h"
3238 as_fn_append ac_func_list " tzset"
3239 as_fn_append ac_func_list " readlinkat"
3240 as_fn_append ac_header_list " execinfo.h"
3241 as_fn_append ac_func_list " faccessat"
3242 as_fn_append ac_header_list " stdio_ext.h"
3243 as_fn_append ac_func_list " __fpending"
3244 gl_getopt_required=GNU
3245 as_fn_append ac_header_list " getopt.h"
3246 as_fn_append ac_func_list " gettimeofday"
3247 as_fn_append ac_func_list " nanotime"
3248 as_fn_append ac_header_list " sys/time.h"
3249 as_fn_append ac_header_list " wchar.h"
3250 as_fn_append ac_header_list " stdint.h"
3251 as_fn_append ac_header_list " inttypes.h"
3252 as_fn_append ac_func_list " lstat"
3253 as_fn_append ac_func_list " alarm"
3254 as_fn_append ac_header_list " sys/select.h"
3255 as_fn_append ac_func_list " pselect"
3256 as_fn_append ac_func_list " pthread_sigmask"
3257 as_fn_append ac_func_list " readlink"
3258 as_fn_append ac_func_list " strtoimax"
3259 as_fn_append ac_func_list " strtoumax"
3260 as_fn_append ac_func_list " symlink"
3261 as_fn_append ac_header_list " sys/stat.h"
3262 as_fn_append ac_func_list " localtime_r"
3263 as_fn_append ac_header_list " utime.h"
3264 as_fn_append ac_func_list " futimes"
3265 as_fn_append ac_func_list " futimesat"
3266 as_fn_append ac_func_list " futimens"
3267 as_fn_append ac_func_list " utimensat"
3268 as_fn_append ac_func_list " lutimes"
3269 # Check that the precious variables saved in the cache have kept the same
3270 # value.
3271 ac_cache_corrupted=false
3272 for ac_var in $ac_precious_vars; do
3273 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3274 eval ac_new_set=\$ac_env_${ac_var}_set
3275 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3276 eval ac_new_val=\$ac_env_${ac_var}_value
3277 case $ac_old_set,$ac_new_set in
3278 set,)
3279 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3280 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3281 ac_cache_corrupted=: ;;
3282 ,set)
3283 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3284 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3285 ac_cache_corrupted=: ;;
3286 ,);;
3288 if test "x$ac_old_val" != "x$ac_new_val"; then
3289 # differences in whitespace do not lead to failure.
3290 ac_old_val_w=`echo x $ac_old_val`
3291 ac_new_val_w=`echo x $ac_new_val`
3292 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3293 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3294 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3295 ac_cache_corrupted=:
3296 else
3297 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3298 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3299 eval $ac_var=\$ac_old_val
3301 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3302 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3303 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3304 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3305 fi;;
3306 esac
3307 # Pass precious variables to config.status.
3308 if test "$ac_new_set" = set; then
3309 case $ac_new_val in
3310 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3311 *) ac_arg=$ac_var=$ac_new_val ;;
3312 esac
3313 case " $ac_configure_args " in
3314 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3315 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3316 esac
3318 done
3319 if $ac_cache_corrupted; then
3320 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3321 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3322 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3323 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3324 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3326 ## -------------------- ##
3327 ## Main body of script. ##
3328 ## -------------------- ##
3330 ac_ext=c
3331 ac_cpp='$CPP $CPPFLAGS'
3332 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3333 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3334 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3337 emacs_config_options="$@"
3338 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3341 ac_aux_dir=
3342 for ac_dir in build-aux "$srcdir"/build-aux; do
3343 for ac_t in install-sh install.sh shtool; do
3344 if test -f "$ac_dir/$ac_t"; then
3345 ac_aux_dir=$ac_dir
3346 ac_install_sh="$ac_aux_dir/$ac_t -c"
3347 break 2
3349 done
3350 done
3351 if test -z "$ac_aux_dir"; then
3352 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3355 # These three variables are undocumented and unsupported,
3356 # and are intended to be withdrawn in a future Autoconf release.
3357 # They can cause serious problems if a builder's source tree is in a directory
3358 # whose full name contains unusual characters.
3359 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3360 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3361 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3364 am__api_version='1.11'
3366 # Find a good install program. We prefer a C program (faster),
3367 # so one script is as good as another. But avoid the broken or
3368 # incompatible versions:
3369 # SysV /etc/install, /usr/sbin/install
3370 # SunOS /usr/etc/install
3371 # IRIX /sbin/install
3372 # AIX /bin/install
3373 # AmigaOS /C/install, which installs bootblocks on floppy discs
3374 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3375 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3376 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3377 # OS/2's system install, which has a completely different semantic
3378 # ./install, which can be erroneously created by make from ./install.sh.
3379 # Reject install programs that cannot install multiple files.
3380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3381 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3382 if test -z "$INSTALL"; then
3383 if test "${ac_cv_path_install+set}" = set; then :
3384 $as_echo_n "(cached) " >&6
3385 else
3386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3387 for as_dir in $PATH
3389 IFS=$as_save_IFS
3390 test -z "$as_dir" && as_dir=.
3391 # Account for people who put trailing slashes in PATH elements.
3392 case $as_dir/ in #((
3393 ./ | .// | /[cC]/* | \
3394 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3395 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3396 /usr/ucb/* ) ;;
3398 # OSF1 and SCO ODT 3.0 have their own names for install.
3399 # Don't use installbsd from OSF since it installs stuff as root
3400 # by default.
3401 for ac_prog in ginstall scoinst install; do
3402 for ac_exec_ext in '' $ac_executable_extensions; do
3403 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3404 if test $ac_prog = install &&
3405 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3406 # AIX install. It has an incompatible calling convention.
3408 elif test $ac_prog = install &&
3409 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3410 # program-specific install script used by HP pwplus--don't use.
3412 else
3413 rm -rf conftest.one conftest.two conftest.dir
3414 echo one > conftest.one
3415 echo two > conftest.two
3416 mkdir conftest.dir
3417 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3418 test -s conftest.one && test -s conftest.two &&
3419 test -s conftest.dir/conftest.one &&
3420 test -s conftest.dir/conftest.two
3421 then
3422 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3423 break 3
3427 done
3428 done
3430 esac
3432 done
3433 IFS=$as_save_IFS
3435 rm -rf conftest.one conftest.two conftest.dir
3438 if test "${ac_cv_path_install+set}" = set; then
3439 INSTALL=$ac_cv_path_install
3440 else
3441 # As a last resort, use the slow shell script. Don't cache a
3442 # value for INSTALL within a source directory, because that will
3443 # break other packages using the cache if that directory is
3444 # removed, or if the value is a relative name.
3445 INSTALL=$ac_install_sh
3448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3449 $as_echo "$INSTALL" >&6; }
3451 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3452 # It thinks the first close brace ends the variable substitution.
3453 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3455 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3457 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3460 $as_echo_n "checking whether build environment is sane... " >&6; }
3461 # Just in case
3462 sleep 1
3463 echo timestamp > conftest.file
3464 # Reject unsafe characters in $srcdir or the absolute working directory
3465 # name. Accept space and tab only in the latter.
3466 am_lf='
3468 case `pwd` in
3469 *[\\\"\#\$\&\'\`$am_lf]*)
3470 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3471 esac
3472 case $srcdir in
3473 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3474 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3475 esac
3477 # Do `set' in a subshell so we don't clobber the current shell's
3478 # arguments. Must try -L first in case configure is actually a
3479 # symlink; some systems play weird games with the mod time of symlinks
3480 # (eg FreeBSD returns the mod time of the symlink's containing
3481 # directory).
3482 if (
3483 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3484 if test "$*" = "X"; then
3485 # -L didn't work.
3486 set X `ls -t "$srcdir/configure" conftest.file`
3488 rm -f conftest.file
3489 if test "$*" != "X $srcdir/configure conftest.file" \
3490 && test "$*" != "X conftest.file $srcdir/configure"; then
3492 # If neither matched, then we have a broken ls. This can happen
3493 # if, for instance, CONFIG_SHELL is bash and it inherits a
3494 # broken ls alias from the environment. This has actually
3495 # happened. Such a system could not be considered "sane".
3496 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3497 alias in your environment" "$LINENO" 5
3500 test "$2" = conftest.file
3502 then
3503 # Ok.
3505 else
3506 as_fn_error "newly created file is older than distributed files!
3507 Check your system clock" "$LINENO" 5
3509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3510 $as_echo "yes" >&6; }
3511 test "$program_prefix" != NONE &&
3512 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3513 # Use a double $ so make ignores it.
3514 test "$program_suffix" != NONE &&
3515 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3516 # Double any \ or $.
3517 # By default was `s,x,x', remove it if useless.
3518 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3519 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3521 # expand $ac_aux_dir to an absolute path
3522 am_aux_dir=`cd $ac_aux_dir && pwd`
3524 if test x"${MISSING+set}" != xset; then
3525 case $am_aux_dir in
3526 *\ * | *\ *)
3527 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3529 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3530 esac
3532 # Use eval to expand $SHELL
3533 if eval "$MISSING --run true"; then
3534 am_missing_run="$MISSING --run "
3535 else
3536 am_missing_run=
3537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3538 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3541 if test x"${install_sh}" != xset; then
3542 case $am_aux_dir in
3543 *\ * | *\ *)
3544 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3546 install_sh="\${SHELL} $am_aux_dir/install-sh"
3547 esac
3550 # Installed binaries are usually stripped using `strip' when the user
3551 # run `make install-strip'. However `strip' might not be the right
3552 # tool to use in cross-compilation environments, therefore Automake
3553 # will honor the `STRIP' environment variable to overrule this program.
3554 if test "$cross_compiling" != no; then
3555 if test -n "$ac_tool_prefix"; then
3556 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3557 set dummy ${ac_tool_prefix}strip; ac_word=$2
3558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3559 $as_echo_n "checking for $ac_word... " >&6; }
3560 if test "${ac_cv_prog_STRIP+set}" = set; then :
3561 $as_echo_n "(cached) " >&6
3562 else
3563 if test -n "$STRIP"; then
3564 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3565 else
3566 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3567 for as_dir in $PATH
3569 IFS=$as_save_IFS
3570 test -z "$as_dir" && as_dir=.
3571 for ac_exec_ext in '' $ac_executable_extensions; do
3572 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3573 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3574 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3575 break 2
3577 done
3578 done
3579 IFS=$as_save_IFS
3583 STRIP=$ac_cv_prog_STRIP
3584 if test -n "$STRIP"; then
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3586 $as_echo "$STRIP" >&6; }
3587 else
3588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3589 $as_echo "no" >&6; }
3594 if test -z "$ac_cv_prog_STRIP"; then
3595 ac_ct_STRIP=$STRIP
3596 # Extract the first word of "strip", so it can be a program name with args.
3597 set dummy strip; ac_word=$2
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3599 $as_echo_n "checking for $ac_word... " >&6; }
3600 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3601 $as_echo_n "(cached) " >&6
3602 else
3603 if test -n "$ac_ct_STRIP"; then
3604 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3605 else
3606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3607 for as_dir in $PATH
3609 IFS=$as_save_IFS
3610 test -z "$as_dir" && as_dir=.
3611 for ac_exec_ext in '' $ac_executable_extensions; do
3612 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3613 ac_cv_prog_ac_ct_STRIP="strip"
3614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3615 break 2
3617 done
3618 done
3619 IFS=$as_save_IFS
3623 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3624 if test -n "$ac_ct_STRIP"; then
3625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3626 $as_echo "$ac_ct_STRIP" >&6; }
3627 else
3628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3629 $as_echo "no" >&6; }
3632 if test "x$ac_ct_STRIP" = x; then
3633 STRIP=":"
3634 else
3635 case $cross_compiling:$ac_tool_warned in
3636 yes:)
3637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3638 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3639 ac_tool_warned=yes ;;
3640 esac
3641 STRIP=$ac_ct_STRIP
3643 else
3644 STRIP="$ac_cv_prog_STRIP"
3648 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3651 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3652 if test -z "$MKDIR_P"; then
3653 if test "${ac_cv_path_mkdir+set}" = set; then :
3654 $as_echo_n "(cached) " >&6
3655 else
3656 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3657 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3659 IFS=$as_save_IFS
3660 test -z "$as_dir" && as_dir=.
3661 for ac_prog in mkdir gmkdir; do
3662 for ac_exec_ext in '' $ac_executable_extensions; do
3663 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3664 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3665 'mkdir (GNU coreutils) '* | \
3666 'mkdir (coreutils) '* | \
3667 'mkdir (fileutils) '4.1*)
3668 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3669 break 3;;
3670 esac
3671 done
3672 done
3673 done
3674 IFS=$as_save_IFS
3678 test -d ./--version && rmdir ./--version
3679 if test "${ac_cv_path_mkdir+set}" = set; then
3680 MKDIR_P="$ac_cv_path_mkdir -p"
3681 else
3682 # As a last resort, use the slow shell script. Don't cache a
3683 # value for MKDIR_P within a source directory, because that will
3684 # break other packages using the cache if that directory is
3685 # removed, or if the value is a relative name.
3686 MKDIR_P="$ac_install_sh -d"
3689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3690 $as_echo "$MKDIR_P" >&6; }
3692 mkdir_p="$MKDIR_P"
3693 case $mkdir_p in
3694 [\\/$]* | ?:[\\/]*) ;;
3695 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3696 esac
3698 for ac_prog in gawk mawk nawk awk
3700 # Extract the first word of "$ac_prog", so it can be a program name with args.
3701 set dummy $ac_prog; ac_word=$2
3702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3703 $as_echo_n "checking for $ac_word... " >&6; }
3704 if test "${ac_cv_prog_AWK+set}" = set; then :
3705 $as_echo_n "(cached) " >&6
3706 else
3707 if test -n "$AWK"; then
3708 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3709 else
3710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3711 for as_dir in $PATH
3713 IFS=$as_save_IFS
3714 test -z "$as_dir" && as_dir=.
3715 for ac_exec_ext in '' $ac_executable_extensions; do
3716 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3717 ac_cv_prog_AWK="$ac_prog"
3718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3719 break 2
3721 done
3722 done
3723 IFS=$as_save_IFS
3727 AWK=$ac_cv_prog_AWK
3728 if test -n "$AWK"; then
3729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3730 $as_echo "$AWK" >&6; }
3731 else
3732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3733 $as_echo "no" >&6; }
3737 test -n "$AWK" && break
3738 done
3740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3741 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3742 set x ${MAKE-make}
3743 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3744 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3745 $as_echo_n "(cached) " >&6
3746 else
3747 cat >conftest.make <<\_ACEOF
3748 SHELL = /bin/sh
3749 all:
3750 @echo '@@@%%%=$(MAKE)=@@@%%%'
3751 _ACEOF
3752 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3753 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3754 *@@@%%%=?*=@@@%%%*)
3755 eval ac_cv_prog_make_${ac_make}_set=yes;;
3757 eval ac_cv_prog_make_${ac_make}_set=no;;
3758 esac
3759 rm -f conftest.make
3761 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3763 $as_echo "yes" >&6; }
3764 SET_MAKE=
3765 else
3766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3767 $as_echo "no" >&6; }
3768 SET_MAKE="MAKE=${MAKE-make}"
3771 rm -rf .tst 2>/dev/null
3772 mkdir .tst 2>/dev/null
3773 if test -d .tst; then
3774 am__leading_dot=.
3775 else
3776 am__leading_dot=_
3778 rmdir .tst 2>/dev/null
3780 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3781 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3782 # is not polluted with repeated "-I."
3783 am__isrc=' -I$(srcdir)'
3784 # test to see if srcdir already configured
3785 if test -f $srcdir/config.status; then
3786 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3790 # test whether we have cygpath
3791 if test -z "$CYGPATH_W"; then
3792 if (cygpath --version) >/dev/null 2>/dev/null; then
3793 CYGPATH_W='cygpath -w'
3794 else
3795 CYGPATH_W=echo
3800 # Define the identity of the package.
3801 PACKAGE='emacs'
3802 VERSION='24.3.50'
3805 cat >>confdefs.h <<_ACEOF
3806 #define PACKAGE "$PACKAGE"
3807 _ACEOF
3810 cat >>confdefs.h <<_ACEOF
3811 #define VERSION "$VERSION"
3812 _ACEOF
3814 # Some tools Automake needs.
3816 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3819 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3822 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3825 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3828 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3830 # We need awk for the "check" target. The system "awk" is bad on
3831 # some platforms.
3832 # Always define AMTAR for backward compatibility.
3834 AMTAR=${AMTAR-"${am_missing_run}tar"}
3836 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3845 lispdir='${datadir}/emacs/${version}/lisp'
3846 leimdir='${datadir}/emacs/${version}/leim'
3847 standardlisppath='${lispdir}:${leimdir}'
3848 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3849 '${datadir}/emacs/site-lisp'
3850 lisppath='${locallisppath}:${standardlisppath}'
3851 etcdir='${datadir}/emacs/${version}/etc'
3852 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3853 docdir='${datadir}/emacs/${version}/etc'
3854 gamedir='${localstatedir}/games/emacs'
3857 # Check whether --with-all was given.
3858 if test "${with_all+set}" = set; then :
3859 withval=$with_all; with_features=$withval
3860 else
3861 with_features=yes
3868 # Check whether --with-pop was given.
3869 if test "${with_pop+set}" = set; then :
3870 withval=$with_pop;
3871 else
3872 with_pop=$with_features
3875 if test "$with_pop" = yes; then
3876 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3881 # Check whether --with-kerberos was given.
3882 if test "${with_kerberos+set}" = set; then :
3883 withval=$with_kerberos;
3884 else
3885 with_kerberos=no
3888 if test "$with_kerberos" != no; then
3889 $as_echo "#define KERBEROS 1" >>confdefs.h
3894 # Check whether --with-kerberos5 was given.
3895 if test "${with_kerberos5+set}" = set; then :
3896 withval=$with_kerberos5;
3897 else
3898 with_kerberos5=no
3901 if test "${with_kerberos5}" != no; then
3902 if test "${with_kerberos}" = no; then
3903 with_kerberos=yes
3904 $as_echo "#define KERBEROS 1" >>confdefs.h
3908 $as_echo "#define KERBEROS5 1" >>confdefs.h
3913 # Check whether --with-hesiod was given.
3914 if test "${with_hesiod+set}" = set; then :
3915 withval=$with_hesiod;
3916 else
3917 with_hesiod=no
3920 if test "$with_hesiod" != no; then
3922 $as_echo "#define HESIOD 1" >>confdefs.h
3927 # Check whether --with-mmdf was given.
3928 if test "${with_mmdf+set}" = set; then :
3929 withval=$with_mmdf;
3930 else
3931 with_mmdf=no
3934 if test "$with_mmdf" != no; then
3936 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3941 # Check whether --with-mail-unlink was given.
3942 if test "${with_mail_unlink+set}" = set; then :
3943 withval=$with_mail_unlink;
3944 else
3945 with_mail_unlink=no
3948 if test "$with_mail_unlink" != no; then
3950 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3955 # Check whether --with-mailhost was given.
3956 if test "${with_mailhost+set}" = set; then :
3957 withval=$with_mailhost;
3958 cat >>confdefs.h <<_ACEOF
3959 #define MAILHOST "$withval"
3960 _ACEOF
3966 # Check whether --with-sound was given.
3967 if test "${with_sound+set}" = set; then :
3968 withval=$with_sound;
3969 else
3970 with_sound=$with_features
3975 # Check whether --with-x-toolkit was given.
3976 if test "${with_x_toolkit+set}" = set; then :
3977 withval=$with_x_toolkit; case "${withval}" in
3978 y | ye | yes ) val=gtk ;;
3979 n | no ) val=no ;;
3980 l | lu | luc | luci | lucid ) val=lucid ;;
3981 a | at | ath | athe | athen | athena ) val=athena ;;
3982 m | mo | mot | moti | motif ) val=motif ;;
3983 g | gt | gtk ) val=gtk ;;
3984 gtk2 ) val=gtk2 ;;
3985 gtk3 ) val=gtk3 ;;
3987 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3988 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
3989 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
3990 \`athena' and \`lucid' are synonyms." "$LINENO" 5
3992 esac
3993 with_x_toolkit=$val
3999 # Check whether --with-wide-int was given.
4000 if test "${with_wide_int+set}" = set; then :
4001 withval=$with_wide_int;
4002 else
4003 with_wide_int=no
4006 if test "$with_wide_int" = yes; then
4008 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4013 # Check whether --with-xpm was given.
4014 if test "${with_xpm+set}" = set; then :
4015 withval=$with_xpm;
4016 else
4017 with_xpm=$with_features
4021 # Check whether --with-jpeg was given.
4022 if test "${with_jpeg+set}" = set; then :
4023 withval=$with_jpeg;
4024 else
4025 with_jpeg=$with_features
4029 # Check whether --with-tiff was given.
4030 if test "${with_tiff+set}" = set; then :
4031 withval=$with_tiff;
4032 else
4033 with_tiff=$with_features
4037 # Check whether --with-gif was given.
4038 if test "${with_gif+set}" = set; then :
4039 withval=$with_gif;
4040 else
4041 with_gif=$with_features
4045 # Check whether --with-png was given.
4046 if test "${with_png+set}" = set; then :
4047 withval=$with_png;
4048 else
4049 with_png=$with_features
4053 # Check whether --with-rsvg was given.
4054 if test "${with_rsvg+set}" = set; then :
4055 withval=$with_rsvg;
4056 else
4057 with_rsvg=$with_features
4061 # Check whether --with-xml2 was given.
4062 if test "${with_xml2+set}" = set; then :
4063 withval=$with_xml2;
4064 else
4065 with_xml2=$with_features
4069 # Check whether --with-imagemagick was given.
4070 if test "${with_imagemagick+set}" = set; then :
4071 withval=$with_imagemagick;
4072 else
4073 with_imagemagick=$with_features
4078 # Check whether --with-xft was given.
4079 if test "${with_xft+set}" = set; then :
4080 withval=$with_xft;
4081 else
4082 with_xft=$with_features
4086 # Check whether --with-libotf was given.
4087 if test "${with_libotf+set}" = set; then :
4088 withval=$with_libotf;
4089 else
4090 with_libotf=$with_features
4094 # Check whether --with-m17n-flt was given.
4095 if test "${with_m17n_flt+set}" = set; then :
4096 withval=$with_m17n_flt;
4097 else
4098 with_m17n_flt=$with_features
4103 # Check whether --with-toolkit-scroll-bars was given.
4104 if test "${with_toolkit_scroll_bars+set}" = set; then :
4105 withval=$with_toolkit_scroll_bars;
4106 else
4107 with_toolkit_scroll_bars=$with_features
4111 # Check whether --with-xaw3d was given.
4112 if test "${with_xaw3d+set}" = set; then :
4113 withval=$with_xaw3d;
4114 else
4115 with_xaw3d=$with_features
4119 # Check whether --with-xim was given.
4120 if test "${with_xim+set}" = set; then :
4121 withval=$with_xim;
4122 else
4123 with_xim=$with_features
4127 # Check whether --with-ns was given.
4128 if test "${with_ns+set}" = set; then :
4129 withval=$with_ns;
4130 else
4131 with_ns=no
4135 # Check whether --with-w32 was given.
4136 if test "${with_w32+set}" = set; then :
4137 withval=$with_w32;
4138 else
4139 with_w32=no
4144 # Check whether --with-gpm was given.
4145 if test "${with_gpm+set}" = set; then :
4146 withval=$with_gpm;
4147 else
4148 with_gpm=$with_features
4152 # Check whether --with-dbus was given.
4153 if test "${with_dbus+set}" = set; then :
4154 withval=$with_dbus;
4155 else
4156 with_dbus=$with_features
4160 # Check whether --with-gconf was given.
4161 if test "${with_gconf+set}" = set; then :
4162 withval=$with_gconf;
4163 else
4164 with_gconf=$with_features
4168 # Check whether --with-gsettings was given.
4169 if test "${with_gsettings+set}" = set; then :
4170 withval=$with_gsettings;
4171 else
4172 with_gsettings=$with_features
4176 # Check whether --with-selinux was given.
4177 if test "${with_selinux+set}" = set; then :
4178 withval=$with_selinux;
4179 else
4180 with_selinux=$with_features
4184 # Check whether --with-acl was given.
4185 if test "${with_acl+set}" = set; then :
4186 withval=$with_acl;
4187 else
4188 with_acl=$with_features
4192 # Check whether --with-gnutls was given.
4193 if test "${with_gnutls+set}" = set; then :
4194 withval=$with_gnutls;
4195 else
4196 with_gnutls=$with_features
4200 # Check whether --with-inotify was given.
4201 if test "${with_inotify+set}" = set; then :
4202 withval=$with_inotify;
4203 else
4204 with_inotify=$with_features
4208 ## For the times when you want to build Emacs but don't have
4209 ## a suitable makeinfo, and can live without the manuals.
4211 # Check whether --with-makeinfo was given.
4212 if test "${with_makeinfo+set}" = set; then :
4213 withval=$with_makeinfo;
4214 else
4215 with_makeinfo=$with_features
4219 ## Makefile.in needs the cache file name.
4222 ## This is an option because I do not know if all info/man support
4223 ## compressed files, nor how to test if they do so.
4225 # Check whether --with-compress-info was given.
4226 if test "${with_compress_info+set}" = set; then :
4227 withval=$with_compress_info;
4228 else
4229 with_compress_info=$with_features
4232 if test $with_compress_info = yes; then
4233 GZIP_INFO=yes
4234 else
4235 GZIP_INFO=
4240 # Check whether --with-pkg-config-prog was given.
4241 if test "${with_pkg_config_prog+set}" = set; then :
4242 withval=$with_pkg_config_prog;
4245 if test "X${with_pkg_config_prog}" != X; then
4246 if test "${with_pkg_config_prog}" != yes; then
4247 PKG_CONFIG="${with_pkg_config_prog}"
4251 CRT_DIR=
4253 # Check whether --with-crt-dir was given.
4254 if test "${with_crt_dir+set}" = set; then :
4255 withval=$with_crt_dir;
4258 CRT_DIR="${with_crt_dir}"
4261 # Check whether --with-gameuser was given.
4262 if test "${with_gameuser+set}" = set; then :
4263 withval=$with_gameuser;
4266 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4267 && gameuser="${with_gameuser}"
4268 test "X$gameuser" = X && gameuser=games
4271 # Check whether --with-gnustep-conf was given.
4272 if test "${with_gnustep_conf+set}" = set; then :
4273 withval=$with_gnustep_conf;
4276 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4277 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4278 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4279 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4281 # Check whether --enable-ns-self-contained was given.
4282 if test "${enable_ns_self_contained+set}" = set; then :
4283 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4284 else
4285 EN_NS_SELF_CONTAINED=yes
4289 # Check whether --enable-locallisppath was given.
4290 if test "${enable_locallisppath+set}" = set; then :
4291 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4292 locallisppath=
4293 elif test "${enableval}" != "yes"; then
4294 locallisppath=${enableval}
4299 # Check whether --enable-checking was given.
4300 if test "${enable_checking+set}" = set; then :
4301 enableval=$enable_checking; ac_checking_flags="${enableval}"
4304 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4305 for check in $ac_checking_flags
4307 case $check in
4308 # these set all the flags to specific states
4309 yes) ac_enable_checking=1 ;;
4310 no) ac_enable_checking= ;
4311 ac_gc_check_stringbytes= ;
4312 ac_gc_check_string_overrun= ;
4313 ac_gc_check_string_free_list= ;
4314 ac_xmalloc_overrun= ;
4315 ac_gc_check_cons_list= ;
4316 ac_glyphs_debug= ;;
4317 all) ac_enable_checking=1 ;
4318 ac_gc_check_stringbytes=1 ;
4319 ac_gc_check_string_overrun=1 ;
4320 ac_gc_check_string_free_list=1 ;
4321 ac_xmalloc_overrun=1 ;
4322 ac_gc_check_cons_list=1 ;
4323 ac_glyphs_debug=1 ;;
4324 # these enable particular checks
4325 stringbytes) ac_gc_check_stringbytes=1 ;;
4326 stringoverrun) ac_gc_check_string_overrun=1 ;;
4327 stringfreelist) ac_gc_check_string_free_list=1 ;;
4328 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4329 conslist) ac_gc_check_cons_list=1 ;;
4330 glyphs) ac_glyphs_debug=1 ;;
4331 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4332 esac
4333 done
4334 IFS="$ac_save_IFS"
4336 if test x$ac_enable_checking != x ; then
4338 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4341 if test x$ac_gc_check_stringbytes != x ; then
4343 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4346 if test x$ac_gc_check_string_overrun != x ; then
4348 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4351 if test x$ac_gc_check_string_free_list != x ; then
4353 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4356 if test x$ac_xmalloc_overrun != x ; then
4358 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4361 if test x$ac_gc_check_cons_list != x ; then
4363 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4366 if test x$ac_glyphs_debug != x ; then
4368 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4372 # Check whether --enable-check-lisp-object-type was given.
4373 if test "${enable_check_lisp_object_type+set}" = set; then :
4374 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4376 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4383 # Check whether --enable-profiling was given.
4384 if test "${enable_profiling+set}" = set; then :
4385 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4388 if test x$ac_enable_profiling != x ; then
4389 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4390 else
4391 PROFILING_CFLAGS=
4395 # Check whether --enable-autodepend was given.
4396 if test "${enable_autodepend+set}" = set; then :
4397 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4398 else
4399 ac_enable_autodepend=yes
4403 # Check whether --enable-gtk-deprecation-warnings was given.
4404 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4405 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4409 #### Make srcdir absolute, if it isn't already. It's important to
4410 #### avoid running the file name through pwd unnecessarily, since pwd can
4411 #### give you automounter prefixes, which can go away. We do all this
4412 #### so Emacs can find its files when run uninstalled.
4413 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4414 unset CDPATH
4415 case "${srcdir}" in
4416 /* ) ;;
4418 ## We may be able to use the $PWD environment variable to make this
4419 ## absolute. But sometimes PWD is inaccurate.
4420 ## Note: we used to use $PWD at the end instead of `pwd`,
4421 ## but that tested only for a well-formed and valid PWD,
4422 ## it did not object when PWD was well-formed and valid but just wrong.
4423 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4424 then
4425 srcdir="$PWD"
4426 else
4427 srcdir=`(cd "$srcdir"; pwd)`
4430 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4431 esac
4433 ### Canonicalize the configuration name.
4435 # Make sure we can run config.sub.
4436 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4437 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4440 $as_echo_n "checking build system type... " >&6; }
4441 if test "${ac_cv_build+set}" = set; then :
4442 $as_echo_n "(cached) " >&6
4443 else
4444 ac_build_alias=$build_alias
4445 test "x$ac_build_alias" = x &&
4446 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4447 test "x$ac_build_alias" = x &&
4448 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4449 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4450 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4454 $as_echo "$ac_cv_build" >&6; }
4455 case $ac_cv_build in
4456 *-*-*) ;;
4457 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4458 esac
4459 build=$ac_cv_build
4460 ac_save_IFS=$IFS; IFS='-'
4461 set x $ac_cv_build
4462 shift
4463 build_cpu=$1
4464 build_vendor=$2
4465 shift; shift
4466 # Remember, the first character of IFS is used to create $*,
4467 # except with old shells:
4468 build_os=$*
4469 IFS=$ac_save_IFS
4470 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4474 $as_echo_n "checking host system type... " >&6; }
4475 if test "${ac_cv_host+set}" = set; then :
4476 $as_echo_n "(cached) " >&6
4477 else
4478 if test "x$host_alias" = x; then
4479 ac_cv_host=$ac_cv_build
4480 else
4481 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4482 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4487 $as_echo "$ac_cv_host" >&6; }
4488 case $ac_cv_host in
4489 *-*-*) ;;
4490 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4491 esac
4492 host=$ac_cv_host
4493 ac_save_IFS=$IFS; IFS='-'
4494 set x $ac_cv_host
4495 shift
4496 host_cpu=$1
4497 host_vendor=$2
4498 shift; shift
4499 # Remember, the first character of IFS is used to create $*,
4500 # except with old shells:
4501 host_os=$*
4502 IFS=$ac_save_IFS
4503 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4506 canonical=$host
4507 configuration=${host_alias-${build_alias-$host}}
4511 ### If you add support for a new configuration, add code to this
4512 ### switch statement to recognize your configuration name and select
4513 ### the appropriate operating system file.
4515 ### You would hope that you could choose an s/*.h
4516 ### file based on the operating system portion. However, it turns out
4517 ### that each s/*.h file is pretty manufacturer-specific.
4518 ### So we basically have to have a special case for each
4519 ### configuration name.
4521 ### As far as handling version numbers on operating systems is
4522 ### concerned, make sure things will fail in a fixable way. If
4523 ### /etc/MACHINES doesn't say anything about version numbers, be
4524 ### prepared to handle anything reasonably. If version numbers
4525 ### matter, be sure /etc/MACHINES says something about it.
4527 opsys='' unported=no
4528 case "${canonical}" in
4530 ## GNU/Linux and similar ports
4531 *-*-linux* )
4532 opsys=gnu-linux
4535 ## FreeBSD ports
4536 *-*-freebsd* )
4537 opsys=freebsd
4540 ## FreeBSD kernel + glibc based userland
4541 *-*-kfreebsd*gnu* )
4542 opsys=gnu-kfreebsd
4545 ## NetBSD ports
4546 *-*-netbsd* )
4547 opsys=netbsd
4550 ## OpenBSD ports
4551 *-*-openbsd* )
4552 opsys=openbsd
4555 ## Apple Darwin / Mac OS X
4556 *-apple-darwin* )
4557 case "${canonical}" in
4558 i[3456]86-* ) ;;
4559 powerpc-* ) ;;
4560 x86_64-* ) ;;
4561 * ) unported=yes ;;
4562 esac
4563 opsys=darwin
4564 ## Use fink packages if available.
4565 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4566 ## if test -d /sw/include && test -d /sw/lib; then
4567 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4568 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4569 ## fi
4572 ## HP 9000 series 700 and 800, running HP/UX
4573 hppa*-hp-hpux10.2* )
4574 opsys=hpux10-20
4576 hppa*-hp-hpux1[1-9]* )
4577 opsys=hpux11
4578 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4581 ## IBM machines
4582 rs6000-ibm-aix4.[23]* )
4583 opsys=aix4-2
4585 powerpc-ibm-aix4.[23]* )
4586 opsys=aix4-2
4588 rs6000-ibm-aix[56]* )
4589 opsys=aix4-2
4591 powerpc-ibm-aix[56]* )
4592 opsys=aix4-2
4595 ## Silicon Graphics machines
4596 ## Iris 4D
4597 mips-sgi-irix6.5 )
4598 opsys=irix6-5
4599 # Without defining _LANGUAGE_C, things get masked out in the headers
4600 # so that, for instance, grepping for `free' in stdlib.h fails and
4601 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4602 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4605 ## Suns
4606 *-sun-solaris* \
4607 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4608 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4609 case "${canonical}" in
4610 i[3456]86-*-* ) ;;
4611 amd64-*-*|x86_64-*-*) ;;
4612 sparc* ) ;;
4613 * ) unported=yes ;;
4614 esac
4615 case "${canonical}" in
4616 *-sunos5.6* | *-solaris2.6* )
4617 opsys=sol2-6
4618 RANLIB="ar -ts"
4620 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4621 opsys=sol2-6
4622 emacs_check_sunpro_c=yes
4624 *-sunos5* | *-solaris* )
4625 opsys=sol2-10
4626 emacs_check_sunpro_c=yes
4628 esac
4629 ## Watch out for a compiler that we know will not work.
4630 case "${canonical}" in
4631 *-solaris* | *-sunos5* )
4632 if [ "x$CC" = x/usr/ucb/cc ]; then
4633 ## /usr/ucb/cc doesn't work;
4634 ## we should find some other compiler that does work.
4635 unset CC
4638 *) ;;
4639 esac
4642 ## Intel 386 machines where we don't care about the manufacturer.
4643 i[3456]86-*-* )
4644 case "${canonical}" in
4645 *-cygwin ) opsys=cygwin ;;
4646 *-darwin* ) opsys=darwin ;;
4647 *-sysv4.2uw* ) opsys=unixware ;;
4648 *-sysv5uw* ) opsys=unixware ;;
4649 *-sysv5OpenUNIX* ) opsys=unixware ;;
4650 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4651 esac
4655 unported=yes
4657 esac
4659 ### If the code above didn't choose an operating system, just choose
4660 ### an operating system based on the configuration name. You really
4661 ### only want to use this when you have no idea what the right
4662 ### operating system is; if you know what operating systems a machine
4663 ### runs, it's cleaner to make it explicit in the case statement
4664 ### above.
4665 if test x"${opsys}" = x; then
4666 case "${canonical}" in
4667 *-gnu* ) opsys=gnu ;;
4669 unported=yes
4671 esac
4676 if test $unported = yes; then
4677 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4678 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4682 #### Choose a compiler.
4684 ac_ext=c
4685 ac_cpp='$CPP $CPPFLAGS'
4686 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4687 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4688 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4689 if test -n "$ac_tool_prefix"; then
4690 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4691 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4693 $as_echo_n "checking for $ac_word... " >&6; }
4694 if test "${ac_cv_prog_CC+set}" = set; then :
4695 $as_echo_n "(cached) " >&6
4696 else
4697 if test -n "$CC"; then
4698 ac_cv_prog_CC="$CC" # Let the user override the test.
4699 else
4700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4701 for as_dir in $PATH
4703 IFS=$as_save_IFS
4704 test -z "$as_dir" && as_dir=.
4705 for ac_exec_ext in '' $ac_executable_extensions; do
4706 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4707 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4708 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4709 break 2
4711 done
4712 done
4713 IFS=$as_save_IFS
4717 CC=$ac_cv_prog_CC
4718 if test -n "$CC"; then
4719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4720 $as_echo "$CC" >&6; }
4721 else
4722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4723 $as_echo "no" >&6; }
4728 if test -z "$ac_cv_prog_CC"; then
4729 ac_ct_CC=$CC
4730 # Extract the first word of "gcc", so it can be a program name with args.
4731 set dummy gcc; ac_word=$2
4732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4733 $as_echo_n "checking for $ac_word... " >&6; }
4734 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4735 $as_echo_n "(cached) " >&6
4736 else
4737 if test -n "$ac_ct_CC"; then
4738 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4739 else
4740 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4741 for as_dir in $PATH
4743 IFS=$as_save_IFS
4744 test -z "$as_dir" && as_dir=.
4745 for ac_exec_ext in '' $ac_executable_extensions; do
4746 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4747 ac_cv_prog_ac_ct_CC="gcc"
4748 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4749 break 2
4751 done
4752 done
4753 IFS=$as_save_IFS
4757 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4758 if test -n "$ac_ct_CC"; then
4759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4760 $as_echo "$ac_ct_CC" >&6; }
4761 else
4762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4763 $as_echo "no" >&6; }
4766 if test "x$ac_ct_CC" = x; then
4767 CC=""
4768 else
4769 case $cross_compiling:$ac_tool_warned in
4770 yes:)
4771 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4772 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4773 ac_tool_warned=yes ;;
4774 esac
4775 CC=$ac_ct_CC
4777 else
4778 CC="$ac_cv_prog_CC"
4781 if test -z "$CC"; then
4782 if test -n "$ac_tool_prefix"; then
4783 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4784 set dummy ${ac_tool_prefix}cc; ac_word=$2
4785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4786 $as_echo_n "checking for $ac_word... " >&6; }
4787 if test "${ac_cv_prog_CC+set}" = set; then :
4788 $as_echo_n "(cached) " >&6
4789 else
4790 if test -n "$CC"; then
4791 ac_cv_prog_CC="$CC" # Let the user override the test.
4792 else
4793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4794 for as_dir in $PATH
4796 IFS=$as_save_IFS
4797 test -z "$as_dir" && as_dir=.
4798 for ac_exec_ext in '' $ac_executable_extensions; do
4799 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4800 ac_cv_prog_CC="${ac_tool_prefix}cc"
4801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4802 break 2
4804 done
4805 done
4806 IFS=$as_save_IFS
4810 CC=$ac_cv_prog_CC
4811 if test -n "$CC"; then
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4813 $as_echo "$CC" >&6; }
4814 else
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4816 $as_echo "no" >&6; }
4822 if test -z "$CC"; then
4823 # Extract the first word of "cc", so it can be a program name with args.
4824 set dummy cc; ac_word=$2
4825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4826 $as_echo_n "checking for $ac_word... " >&6; }
4827 if test "${ac_cv_prog_CC+set}" = set; then :
4828 $as_echo_n "(cached) " >&6
4829 else
4830 if test -n "$CC"; then
4831 ac_cv_prog_CC="$CC" # Let the user override the test.
4832 else
4833 ac_prog_rejected=no
4834 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4835 for as_dir in $PATH
4837 IFS=$as_save_IFS
4838 test -z "$as_dir" && as_dir=.
4839 for ac_exec_ext in '' $ac_executable_extensions; do
4840 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4841 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4842 ac_prog_rejected=yes
4843 continue
4845 ac_cv_prog_CC="cc"
4846 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4847 break 2
4849 done
4850 done
4851 IFS=$as_save_IFS
4853 if test $ac_prog_rejected = yes; then
4854 # We found a bogon in the path, so make sure we never use it.
4855 set dummy $ac_cv_prog_CC
4856 shift
4857 if test $# != 0; then
4858 # We chose a different compiler from the bogus one.
4859 # However, it has the same basename, so the bogon will be chosen
4860 # first if we set CC to just the basename; use the full file name.
4861 shift
4862 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4867 CC=$ac_cv_prog_CC
4868 if test -n "$CC"; then
4869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4870 $as_echo "$CC" >&6; }
4871 else
4872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4873 $as_echo "no" >&6; }
4878 if test -z "$CC"; then
4879 if test -n "$ac_tool_prefix"; then
4880 for ac_prog in cl.exe
4882 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4883 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4885 $as_echo_n "checking for $ac_word... " >&6; }
4886 if test "${ac_cv_prog_CC+set}" = set; then :
4887 $as_echo_n "(cached) " >&6
4888 else
4889 if test -n "$CC"; then
4890 ac_cv_prog_CC="$CC" # Let the user override the test.
4891 else
4892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4893 for as_dir in $PATH
4895 IFS=$as_save_IFS
4896 test -z "$as_dir" && as_dir=.
4897 for ac_exec_ext in '' $ac_executable_extensions; do
4898 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4899 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4901 break 2
4903 done
4904 done
4905 IFS=$as_save_IFS
4909 CC=$ac_cv_prog_CC
4910 if test -n "$CC"; then
4911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4912 $as_echo "$CC" >&6; }
4913 else
4914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4915 $as_echo "no" >&6; }
4919 test -n "$CC" && break
4920 done
4922 if test -z "$CC"; then
4923 ac_ct_CC=$CC
4924 for ac_prog in cl.exe
4926 # Extract the first word of "$ac_prog", so it can be a program name with args.
4927 set dummy $ac_prog; ac_word=$2
4928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4929 $as_echo_n "checking for $ac_word... " >&6; }
4930 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4931 $as_echo_n "(cached) " >&6
4932 else
4933 if test -n "$ac_ct_CC"; then
4934 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4935 else
4936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4937 for as_dir in $PATH
4939 IFS=$as_save_IFS
4940 test -z "$as_dir" && as_dir=.
4941 for ac_exec_ext in '' $ac_executable_extensions; do
4942 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4943 ac_cv_prog_ac_ct_CC="$ac_prog"
4944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4945 break 2
4947 done
4948 done
4949 IFS=$as_save_IFS
4953 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4954 if test -n "$ac_ct_CC"; then
4955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4956 $as_echo "$ac_ct_CC" >&6; }
4957 else
4958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4959 $as_echo "no" >&6; }
4963 test -n "$ac_ct_CC" && break
4964 done
4966 if test "x$ac_ct_CC" = x; then
4967 CC=""
4968 else
4969 case $cross_compiling:$ac_tool_warned in
4970 yes:)
4971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4972 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4973 ac_tool_warned=yes ;;
4974 esac
4975 CC=$ac_ct_CC
4982 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4983 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4984 as_fn_error "no acceptable C compiler found in \$PATH
4985 See \`config.log' for more details." "$LINENO" 5; }
4987 # Provide some information about the compiler.
4988 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4989 set X $ac_compile
4990 ac_compiler=$2
4991 for ac_option in --version -v -V -qversion; do
4992 { { ac_try="$ac_compiler $ac_option >&5"
4993 case "(($ac_try" in
4994 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4995 *) ac_try_echo=$ac_try;;
4996 esac
4997 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4998 $as_echo "$ac_try_echo"; } >&5
4999 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5000 ac_status=$?
5001 if test -s conftest.err; then
5002 sed '10a\
5003 ... rest of stderr output deleted ...
5004 10q' conftest.err >conftest.er1
5005 cat conftest.er1 >&5
5007 rm -f conftest.er1 conftest.err
5008 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5009 test $ac_status = 0; }
5010 done
5012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5013 /* end confdefs.h. */
5016 main ()
5020 return 0;
5022 _ACEOF
5023 ac_clean_files_save=$ac_clean_files
5024 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5025 # Try to create an executable without -o first, disregard a.out.
5026 # It will help us diagnose broken compilers, and finding out an intuition
5027 # of exeext.
5028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5029 $as_echo_n "checking whether the C compiler works... " >&6; }
5030 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5032 # The possible output files:
5033 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5035 ac_rmfiles=
5036 for ac_file in $ac_files
5038 case $ac_file in
5039 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5040 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5041 esac
5042 done
5043 rm -f $ac_rmfiles
5045 if { { ac_try="$ac_link_default"
5046 case "(($ac_try" in
5047 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5048 *) ac_try_echo=$ac_try;;
5049 esac
5050 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5051 $as_echo "$ac_try_echo"; } >&5
5052 (eval "$ac_link_default") 2>&5
5053 ac_status=$?
5054 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5055 test $ac_status = 0; }; then :
5056 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5057 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5058 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5059 # so that the user can short-circuit this test for compilers unknown to
5060 # Autoconf.
5061 for ac_file in $ac_files ''
5063 test -f "$ac_file" || continue
5064 case $ac_file in
5065 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5067 [ab].out )
5068 # We found the default executable, but exeext='' is most
5069 # certainly right.
5070 break;;
5071 *.* )
5072 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5073 then :; else
5074 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5076 # We set ac_cv_exeext here because the later test for it is not
5077 # safe: cross compilers may not add the suffix if given an `-o'
5078 # argument, so we may need to know it at that point already.
5079 # Even if this section looks crufty: it has the advantage of
5080 # actually working.
5081 break;;
5083 break;;
5084 esac
5085 done
5086 test "$ac_cv_exeext" = no && ac_cv_exeext=
5088 else
5089 ac_file=''
5091 if test -z "$ac_file"; then :
5092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5093 $as_echo "no" >&6; }
5094 $as_echo "$as_me: failed program was:" >&5
5095 sed 's/^/| /' conftest.$ac_ext >&5
5097 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5098 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5099 { as_fn_set_status 77
5100 as_fn_error "C compiler cannot create executables
5101 See \`config.log' for more details." "$LINENO" 5; }; }
5102 else
5103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5104 $as_echo "yes" >&6; }
5106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5107 $as_echo_n "checking for C compiler default output file name... " >&6; }
5108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5109 $as_echo "$ac_file" >&6; }
5110 ac_exeext=$ac_cv_exeext
5112 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5113 ac_clean_files=$ac_clean_files_save
5114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5115 $as_echo_n "checking for suffix of executables... " >&6; }
5116 if { { ac_try="$ac_link"
5117 case "(($ac_try" in
5118 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5119 *) ac_try_echo=$ac_try;;
5120 esac
5121 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5122 $as_echo "$ac_try_echo"; } >&5
5123 (eval "$ac_link") 2>&5
5124 ac_status=$?
5125 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5126 test $ac_status = 0; }; then :
5127 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5128 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5129 # work properly (i.e., refer to `conftest.exe'), while it won't with
5130 # `rm'.
5131 for ac_file in conftest.exe conftest conftest.*; do
5132 test -f "$ac_file" || continue
5133 case $ac_file in
5134 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5135 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5136 break;;
5137 * ) break;;
5138 esac
5139 done
5140 else
5141 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5142 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5143 as_fn_error "cannot compute suffix of executables: cannot compile and link
5144 See \`config.log' for more details." "$LINENO" 5; }
5146 rm -f conftest conftest$ac_cv_exeext
5147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5148 $as_echo "$ac_cv_exeext" >&6; }
5150 rm -f conftest.$ac_ext
5151 EXEEXT=$ac_cv_exeext
5152 ac_exeext=$EXEEXT
5153 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5154 /* end confdefs.h. */
5155 #include <stdio.h>
5157 main ()
5159 FILE *f = fopen ("conftest.out", "w");
5160 return ferror (f) || fclose (f) != 0;
5163 return 0;
5165 _ACEOF
5166 ac_clean_files="$ac_clean_files conftest.out"
5167 # Check that the compiler produces executables we can run. If not, either
5168 # the compiler is broken, or we cross compile.
5169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5170 $as_echo_n "checking whether we are cross compiling... " >&6; }
5171 if test "$cross_compiling" != yes; then
5172 { { ac_try="$ac_link"
5173 case "(($ac_try" in
5174 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5175 *) ac_try_echo=$ac_try;;
5176 esac
5177 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5178 $as_echo "$ac_try_echo"; } >&5
5179 (eval "$ac_link") 2>&5
5180 ac_status=$?
5181 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5182 test $ac_status = 0; }
5183 if { ac_try='./conftest$ac_cv_exeext'
5184 { { case "(($ac_try" in
5185 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5186 *) ac_try_echo=$ac_try;;
5187 esac
5188 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5189 $as_echo "$ac_try_echo"; } >&5
5190 (eval "$ac_try") 2>&5
5191 ac_status=$?
5192 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5193 test $ac_status = 0; }; }; then
5194 cross_compiling=no
5195 else
5196 if test "$cross_compiling" = maybe; then
5197 cross_compiling=yes
5198 else
5199 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5200 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5201 as_fn_error "cannot run C compiled programs.
5202 If you meant to cross compile, use \`--host'.
5203 See \`config.log' for more details." "$LINENO" 5; }
5207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5208 $as_echo "$cross_compiling" >&6; }
5210 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5211 ac_clean_files=$ac_clean_files_save
5212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5213 $as_echo_n "checking for suffix of object files... " >&6; }
5214 if test "${ac_cv_objext+set}" = set; then :
5215 $as_echo_n "(cached) " >&6
5216 else
5217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5218 /* end confdefs.h. */
5221 main ()
5225 return 0;
5227 _ACEOF
5228 rm -f conftest.o conftest.obj
5229 if { { ac_try="$ac_compile"
5230 case "(($ac_try" in
5231 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5232 *) ac_try_echo=$ac_try;;
5233 esac
5234 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5235 $as_echo "$ac_try_echo"; } >&5
5236 (eval "$ac_compile") 2>&5
5237 ac_status=$?
5238 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5239 test $ac_status = 0; }; then :
5240 for ac_file in conftest.o conftest.obj conftest.*; do
5241 test -f "$ac_file" || continue;
5242 case $ac_file in
5243 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5244 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5245 break;;
5246 esac
5247 done
5248 else
5249 $as_echo "$as_me: failed program was:" >&5
5250 sed 's/^/| /' conftest.$ac_ext >&5
5252 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5253 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5254 as_fn_error "cannot compute suffix of object files: cannot compile
5255 See \`config.log' for more details." "$LINENO" 5; }
5257 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5260 $as_echo "$ac_cv_objext" >&6; }
5261 OBJEXT=$ac_cv_objext
5262 ac_objext=$OBJEXT
5263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5264 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5265 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5266 $as_echo_n "(cached) " >&6
5267 else
5268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5269 /* end confdefs.h. */
5272 main ()
5274 #ifndef __GNUC__
5275 choke me
5276 #endif
5279 return 0;
5281 _ACEOF
5282 if ac_fn_c_try_compile "$LINENO"; then :
5283 ac_compiler_gnu=yes
5284 else
5285 ac_compiler_gnu=no
5287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5288 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5292 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5293 if test $ac_compiler_gnu = yes; then
5294 GCC=yes
5295 else
5296 GCC=
5298 ac_test_CFLAGS=${CFLAGS+set}
5299 ac_save_CFLAGS=$CFLAGS
5300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5301 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5302 if test "${ac_cv_prog_cc_g+set}" = set; then :
5303 $as_echo_n "(cached) " >&6
5304 else
5305 ac_save_c_werror_flag=$ac_c_werror_flag
5306 ac_c_werror_flag=yes
5307 ac_cv_prog_cc_g=no
5308 CFLAGS="-g"
5309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5310 /* end confdefs.h. */
5313 main ()
5317 return 0;
5319 _ACEOF
5320 if ac_fn_c_try_compile "$LINENO"; then :
5321 ac_cv_prog_cc_g=yes
5322 else
5323 CFLAGS=""
5324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5325 /* end confdefs.h. */
5328 main ()
5332 return 0;
5334 _ACEOF
5335 if ac_fn_c_try_compile "$LINENO"; then :
5337 else
5338 ac_c_werror_flag=$ac_save_c_werror_flag
5339 CFLAGS="-g"
5340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5341 /* end confdefs.h. */
5344 main ()
5348 return 0;
5350 _ACEOF
5351 if ac_fn_c_try_compile "$LINENO"; then :
5352 ac_cv_prog_cc_g=yes
5354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5359 ac_c_werror_flag=$ac_save_c_werror_flag
5361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5362 $as_echo "$ac_cv_prog_cc_g" >&6; }
5363 if test "$ac_test_CFLAGS" = set; then
5364 CFLAGS=$ac_save_CFLAGS
5365 elif test $ac_cv_prog_cc_g = yes; then
5366 if test "$GCC" = yes; then
5367 CFLAGS="-g -O2"
5368 else
5369 CFLAGS="-g"
5371 else
5372 if test "$GCC" = yes; then
5373 CFLAGS="-O2"
5374 else
5375 CFLAGS=
5378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5379 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5380 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5381 $as_echo_n "(cached) " >&6
5382 else
5383 ac_cv_prog_cc_c89=no
5384 ac_save_CC=$CC
5385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5386 /* end confdefs.h. */
5387 #include <stdarg.h>
5388 #include <stdio.h>
5389 #include <sys/types.h>
5390 #include <sys/stat.h>
5391 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5392 struct buf { int x; };
5393 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5394 static char *e (p, i)
5395 char **p;
5396 int i;
5398 return p[i];
5400 static char *f (char * (*g) (char **, int), char **p, ...)
5402 char *s;
5403 va_list v;
5404 va_start (v,p);
5405 s = g (p, va_arg (v,int));
5406 va_end (v);
5407 return s;
5410 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5411 function prototypes and stuff, but not '\xHH' hex character constants.
5412 These don't provoke an error unfortunately, instead are silently treated
5413 as 'x'. The following induces an error, until -std is added to get
5414 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5415 array size at least. It's necessary to write '\x00'==0 to get something
5416 that's true only with -std. */
5417 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5419 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5420 inside strings and character constants. */
5421 #define FOO(x) 'x'
5422 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5424 int test (int i, double x);
5425 struct s1 {int (*f) (int a);};
5426 struct s2 {int (*f) (double a);};
5427 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5428 int argc;
5429 char **argv;
5431 main ()
5433 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5435 return 0;
5437 _ACEOF
5438 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5439 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5441 CC="$ac_save_CC $ac_arg"
5442 if ac_fn_c_try_compile "$LINENO"; then :
5443 ac_cv_prog_cc_c89=$ac_arg
5445 rm -f core conftest.err conftest.$ac_objext
5446 test "x$ac_cv_prog_cc_c89" != "xno" && break
5447 done
5448 rm -f conftest.$ac_ext
5449 CC=$ac_save_CC
5452 # AC_CACHE_VAL
5453 case "x$ac_cv_prog_cc_c89" in
5455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5456 $as_echo "none needed" >&6; } ;;
5457 xno)
5458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5459 $as_echo "unsupported" >&6; } ;;
5461 CC="$CC $ac_cv_prog_cc_c89"
5462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5463 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5464 esac
5465 if test "x$ac_cv_prog_cc_c89" != xno; then :
5469 ac_ext=c
5470 ac_cpp='$CPP $CPPFLAGS'
5471 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5472 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5473 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5474 DEPDIR="${am__leading_dot}deps"
5476 ac_config_commands="$ac_config_commands depfiles"
5479 am_make=${MAKE-make}
5480 cat > confinc << 'END'
5481 am__doit:
5482 @echo this is the am__doit target
5483 .PHONY: am__doit
5485 # If we don't find an include directive, just comment out the code.
5486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5487 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5488 am__include="#"
5489 am__quote=
5490 _am_result=none
5491 # First try GNU make style include.
5492 echo "include confinc" > confmf
5493 # Ignore all kinds of additional output from `make'.
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=GNU
5500 esac
5501 # Now try BSD make style include.
5502 if test "$am__include" = "#"; then
5503 echo '.include "confinc"' > confmf
5504 case `$am_make -s -f confmf 2> /dev/null` in #(
5505 *the\ am__doit\ target*)
5506 am__include=.include
5507 am__quote="\""
5508 _am_result=BSD
5510 esac
5514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5515 $as_echo "$_am_result" >&6; }
5516 rm -f confinc confmf
5518 # Check whether --enable-dependency-tracking was given.
5519 if test "${enable_dependency_tracking+set}" = set; then :
5520 enableval=$enable_dependency_tracking;
5523 if test "x$enable_dependency_tracking" != xno; then
5524 am_depcomp="$ac_aux_dir/depcomp"
5525 AMDEPBACKSLASH='\'
5527 if test "x$enable_dependency_tracking" != xno; then
5528 AMDEP_TRUE=
5529 AMDEP_FALSE='#'
5530 else
5531 AMDEP_TRUE='#'
5532 AMDEP_FALSE=
5537 depcc="$CC" am_compiler_list=
5539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5540 $as_echo_n "checking dependency style of $depcc... " >&6; }
5541 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5542 $as_echo_n "(cached) " >&6
5543 else
5544 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5545 # We make a subdir and do the tests there. Otherwise we can end up
5546 # making bogus files that we don't know about and never remove. For
5547 # instance it was reported that on HP-UX the gcc test will end up
5548 # making a dummy file named `D' -- because `-MD' means `put the output
5549 # in D'.
5550 mkdir conftest.dir
5551 # Copy depcomp to subdir because otherwise we won't find it if we're
5552 # using a relative directory.
5553 cp "$am_depcomp" conftest.dir
5554 cd conftest.dir
5555 # We will build objects and dependencies in a subdirectory because
5556 # it helps to detect inapplicable dependency modes. For instance
5557 # both Tru64's cc and ICC support -MD to output dependencies as a
5558 # side effect of compilation, but ICC will put the dependencies in
5559 # the current directory while Tru64 will put them in the object
5560 # directory.
5561 mkdir sub
5563 am_cv_CC_dependencies_compiler_type=none
5564 if test "$am_compiler_list" = ""; then
5565 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5567 am__universal=false
5568 case " $depcc " in #(
5569 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5570 esac
5572 for depmode in $am_compiler_list; do
5573 # Setup a source with many dependencies, because some compilers
5574 # like to wrap large dependency lists on column 80 (with \), and
5575 # we should not choose a depcomp mode which is confused by this.
5577 # We need to recreate these files for each test, as the compiler may
5578 # overwrite some of them when testing with obscure command lines.
5579 # This happens at least with the AIX C compiler.
5580 : > sub/conftest.c
5581 for i in 1 2 3 4 5 6; do
5582 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5583 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5584 # Solaris 8's {/usr,}/bin/sh.
5585 touch sub/conftst$i.h
5586 done
5587 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5589 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5590 # mode. It turns out that the SunPro C++ compiler does not properly
5591 # handle `-M -o', and we need to detect this. Also, some Intel
5592 # versions had trouble with output in subdirs
5593 am__obj=sub/conftest.${OBJEXT-o}
5594 am__minus_obj="-o $am__obj"
5595 case $depmode in
5596 gcc)
5597 # This depmode causes a compiler race in universal mode.
5598 test "$am__universal" = false || continue
5600 nosideeffect)
5601 # after this tag, mechanisms are not by side-effect, so they'll
5602 # only be used when explicitly requested
5603 if test "x$enable_dependency_tracking" = xyes; then
5604 continue
5605 else
5606 break
5609 msvisualcpp | msvcmsys)
5610 # This compiler won't grok `-c -o', but also, the minuso test has
5611 # not run yet. These depmodes are late enough in the game, and
5612 # so weak that their functioning should not be impacted.
5613 am__obj=conftest.${OBJEXT-o}
5614 am__minus_obj=
5616 none) break ;;
5617 esac
5618 if depmode=$depmode \
5619 source=sub/conftest.c object=$am__obj \
5620 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5621 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5622 >/dev/null 2>conftest.err &&
5623 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5624 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5625 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5626 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5627 # icc doesn't choke on unknown options, it will just issue warnings
5628 # or remarks (even with -Werror). So we grep stderr for any message
5629 # that says an option was ignored or not supported.
5630 # When given -MP, icc 7.0 and 7.1 complain thusly:
5631 # icc: Command line warning: ignoring option '-M'; no argument required
5632 # The diagnosis changed in icc 8.0:
5633 # icc: Command line remark: option '-MP' not supported
5634 if (grep 'ignoring option' conftest.err ||
5635 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5636 am_cv_CC_dependencies_compiler_type=$depmode
5637 break
5640 done
5642 cd ..
5643 rm -rf conftest.dir
5644 else
5645 am_cv_CC_dependencies_compiler_type=none
5649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5650 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5651 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5654 test "x$enable_dependency_tracking" != xno \
5655 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5656 am__fastdepCC_TRUE=
5657 am__fastdepCC_FALSE='#'
5658 else
5659 am__fastdepCC_TRUE='#'
5660 am__fastdepCC_FALSE=
5664 if test "x$CC" != xcc; then
5665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5666 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5667 else
5668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5669 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5671 set dummy $CC; ac_cc=`$as_echo "$2" |
5672 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5673 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5674 $as_echo_n "(cached) " >&6
5675 else
5676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5677 /* end confdefs.h. */
5680 main ()
5684 return 0;
5686 _ACEOF
5687 # Make sure it works both with $CC and with simple cc.
5688 # We do the test twice because some compilers refuse to overwrite an
5689 # existing .o file with -o, though they will create one.
5690 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5691 rm -f conftest2.*
5692 if { { 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 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5703 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5704 *) ac_try_echo=$ac_try;;
5705 esac
5706 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5707 $as_echo "$ac_try_echo"; } >&5
5708 (eval "$ac_try") 2>&5
5709 ac_status=$?
5710 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5711 test $ac_status = 0; };
5712 then
5713 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5714 if test "x$CC" != xcc; then
5715 # Test first that cc exists at all.
5716 if { ac_try='cc -c conftest.$ac_ext >&5'
5717 { { case "(($ac_try" in
5718 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5719 *) ac_try_echo=$ac_try;;
5720 esac
5721 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5722 $as_echo "$ac_try_echo"; } >&5
5723 (eval "$ac_try") 2>&5
5724 ac_status=$?
5725 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5726 test $ac_status = 0; }; }; then
5727 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5728 rm -f conftest2.*
5729 if { { 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 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5740 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5741 *) ac_try_echo=$ac_try;;
5742 esac
5743 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5744 $as_echo "$ac_try_echo"; } >&5
5745 (eval "$ac_try") 2>&5
5746 ac_status=$?
5747 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5748 test $ac_status = 0; };
5749 then
5750 # cc works too.
5752 else
5753 # cc exists but doesn't like -o.
5754 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5758 else
5759 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5761 rm -f core conftest*
5764 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5766 $as_echo "yes" >&6; }
5767 else
5768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5769 $as_echo "no" >&6; }
5771 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5775 # FIXME: we rely on the cache variable name because
5776 # there is no other way.
5777 set dummy $CC
5778 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5779 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5780 if test "$am_t" != yes; then
5781 # Losing compiler, so override with the script.
5782 # FIXME: It is wrong to rewrite CC.
5783 # But if we don't then we get into trouble of one sort or another.
5784 # A longer-term fix would be to have automake use am__CC in this case,
5785 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5786 CC="$am_aux_dir/compile $CC"
5791 if test x$GCC = xyes; then
5792 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5793 else
5794 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5797 # Avoid gnulib's tests for O_NOATIME and O_NOFOLLOW, as we don't use them.
5799 # Avoid gnulib's threadlib module, as we do threads our own way.
5802 # Initialize gnulib right after choosing the compiler.
5804 ac_ext=c
5805 ac_cpp='$CPP $CPPFLAGS'
5806 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5807 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5808 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5810 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5811 # On Suns, sometimes $CPP names a directory.
5812 if test -n "$CPP" && test -d "$CPP"; then
5813 CPP=
5815 if test -z "$CPP"; then
5816 if test "${ac_cv_prog_CPP+set}" = set; then :
5817 $as_echo_n "(cached) " >&6
5818 else
5819 # Double quotes because CPP needs to be expanded
5820 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5822 ac_preproc_ok=false
5823 for ac_c_preproc_warn_flag in '' yes
5825 # Use a header file that comes with gcc, so configuring glibc
5826 # with a fresh cross-compiler works.
5827 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5828 # <limits.h> exists even on freestanding compilers.
5829 # On the NeXT, cc -E runs the code through the compiler's parser,
5830 # not just through cpp. "Syntax error" is here to catch this case.
5831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5832 /* end confdefs.h. */
5833 #ifdef __STDC__
5834 # include <limits.h>
5835 #else
5836 # include <assert.h>
5837 #endif
5838 Syntax error
5839 _ACEOF
5840 if ac_fn_c_try_cpp "$LINENO"; then :
5842 else
5843 # Broken: fails on valid input.
5844 continue
5846 rm -f conftest.err conftest.$ac_ext
5848 # OK, works on sane cases. Now check whether nonexistent headers
5849 # can be detected and how.
5850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5851 /* end confdefs.h. */
5852 #include <ac_nonexistent.h>
5853 _ACEOF
5854 if ac_fn_c_try_cpp "$LINENO"; then :
5855 # Broken: success on invalid input.
5856 continue
5857 else
5858 # Passes both tests.
5859 ac_preproc_ok=:
5860 break
5862 rm -f conftest.err conftest.$ac_ext
5864 done
5865 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5866 rm -f conftest.err conftest.$ac_ext
5867 if $ac_preproc_ok; then :
5868 break
5871 done
5872 ac_cv_prog_CPP=$CPP
5875 CPP=$ac_cv_prog_CPP
5876 else
5877 ac_cv_prog_CPP=$CPP
5879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5880 $as_echo "$CPP" >&6; }
5881 ac_preproc_ok=false
5882 for ac_c_preproc_warn_flag in '' yes
5884 # Use a header file that comes with gcc, so configuring glibc
5885 # with a fresh cross-compiler works.
5886 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5887 # <limits.h> exists even on freestanding compilers.
5888 # On the NeXT, cc -E runs the code through the compiler's parser,
5889 # not just through cpp. "Syntax error" is here to catch this case.
5890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5891 /* end confdefs.h. */
5892 #ifdef __STDC__
5893 # include <limits.h>
5894 #else
5895 # include <assert.h>
5896 #endif
5897 Syntax error
5898 _ACEOF
5899 if ac_fn_c_try_cpp "$LINENO"; then :
5901 else
5902 # Broken: fails on valid input.
5903 continue
5905 rm -f conftest.err conftest.$ac_ext
5907 # OK, works on sane cases. Now check whether nonexistent headers
5908 # can be detected and how.
5909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5910 /* end confdefs.h. */
5911 #include <ac_nonexistent.h>
5912 _ACEOF
5913 if ac_fn_c_try_cpp "$LINENO"; then :
5914 # Broken: success on invalid input.
5915 continue
5916 else
5917 # Passes both tests.
5918 ac_preproc_ok=:
5919 break
5921 rm -f conftest.err conftest.$ac_ext
5923 done
5924 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5925 rm -f conftest.err conftest.$ac_ext
5926 if $ac_preproc_ok; then :
5928 else
5929 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5930 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5931 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5932 See \`config.log' for more details." "$LINENO" 5; }
5935 ac_ext=c
5936 ac_cpp='$CPP $CPPFLAGS'
5937 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5938 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5939 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5943 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5944 if test "${ac_cv_path_GREP+set}" = set; then :
5945 $as_echo_n "(cached) " >&6
5946 else
5947 if test -z "$GREP"; then
5948 ac_path_GREP_found=false
5949 # Loop through the user's path and test for each of PROGNAME-LIST
5950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5951 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5953 IFS=$as_save_IFS
5954 test -z "$as_dir" && as_dir=.
5955 for ac_prog in grep ggrep; do
5956 for ac_exec_ext in '' $ac_executable_extensions; do
5957 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5958 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5959 # Check for GNU ac_path_GREP and select it if it is found.
5960 # Check for GNU $ac_path_GREP
5961 case `"$ac_path_GREP" --version 2>&1` in
5962 *GNU*)
5963 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5965 ac_count=0
5966 $as_echo_n 0123456789 >"conftest.in"
5967 while :
5969 cat "conftest.in" "conftest.in" >"conftest.tmp"
5970 mv "conftest.tmp" "conftest.in"
5971 cp "conftest.in" "conftest.nl"
5972 $as_echo 'GREP' >> "conftest.nl"
5973 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5974 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5975 as_fn_arith $ac_count + 1 && ac_count=$as_val
5976 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5977 # Best one so far, save it but keep looking for a better one
5978 ac_cv_path_GREP="$ac_path_GREP"
5979 ac_path_GREP_max=$ac_count
5981 # 10*(2^10) chars as input seems more than enough
5982 test $ac_count -gt 10 && break
5983 done
5984 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5985 esac
5987 $ac_path_GREP_found && break 3
5988 done
5989 done
5990 done
5991 IFS=$as_save_IFS
5992 if test -z "$ac_cv_path_GREP"; then
5993 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5995 else
5996 ac_cv_path_GREP=$GREP
6000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6001 $as_echo "$ac_cv_path_GREP" >&6; }
6002 GREP="$ac_cv_path_GREP"
6005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6006 $as_echo_n "checking for egrep... " >&6; }
6007 if test "${ac_cv_path_EGREP+set}" = set; then :
6008 $as_echo_n "(cached) " >&6
6009 else
6010 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6011 then ac_cv_path_EGREP="$GREP -E"
6012 else
6013 if test -z "$EGREP"; then
6014 ac_path_EGREP_found=false
6015 # Loop through the user's path and test for each of PROGNAME-LIST
6016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6017 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6019 IFS=$as_save_IFS
6020 test -z "$as_dir" && as_dir=.
6021 for ac_prog in egrep; do
6022 for ac_exec_ext in '' $ac_executable_extensions; do
6023 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6024 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6025 # Check for GNU ac_path_EGREP and select it if it is found.
6026 # Check for GNU $ac_path_EGREP
6027 case `"$ac_path_EGREP" --version 2>&1` in
6028 *GNU*)
6029 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6031 ac_count=0
6032 $as_echo_n 0123456789 >"conftest.in"
6033 while :
6035 cat "conftest.in" "conftest.in" >"conftest.tmp"
6036 mv "conftest.tmp" "conftest.in"
6037 cp "conftest.in" "conftest.nl"
6038 $as_echo 'EGREP' >> "conftest.nl"
6039 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6040 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6041 as_fn_arith $ac_count + 1 && ac_count=$as_val
6042 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6043 # Best one so far, save it but keep looking for a better one
6044 ac_cv_path_EGREP="$ac_path_EGREP"
6045 ac_path_EGREP_max=$ac_count
6047 # 10*(2^10) chars as input seems more than enough
6048 test $ac_count -gt 10 && break
6049 done
6050 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6051 esac
6053 $ac_path_EGREP_found && break 3
6054 done
6055 done
6056 done
6057 IFS=$as_save_IFS
6058 if test -z "$ac_cv_path_EGREP"; then
6059 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6061 else
6062 ac_cv_path_EGREP=$EGREP
6067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6068 $as_echo "$ac_cv_path_EGREP" >&6; }
6069 EGREP="$ac_cv_path_EGREP"
6074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6075 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6076 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6077 $as_echo_n "(cached) " >&6
6078 else
6080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6081 /* end confdefs.h. */
6083 #ifdef __ACK__
6084 Amsterdam
6085 #endif
6087 _ACEOF
6088 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6089 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6090 gl_cv_c_amsterdam_compiler=yes
6091 else
6092 gl_cv_c_amsterdam_compiler=no
6094 rm -f conftest*
6098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6099 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6100 if test -z "$AR"; then
6101 if test $gl_cv_c_amsterdam_compiler = yes; then
6102 AR='cc -c.a'
6103 if test -z "$ARFLAGS"; then
6104 ARFLAGS='-o'
6106 else
6107 if test -n "$ac_tool_prefix"; then
6108 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6109 set dummy ${ac_tool_prefix}ar; ac_word=$2
6110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6111 $as_echo_n "checking for $ac_word... " >&6; }
6112 if test "${ac_cv_prog_AR+set}" = set; then :
6113 $as_echo_n "(cached) " >&6
6114 else
6115 if test -n "$AR"; then
6116 ac_cv_prog_AR="$AR" # Let the user override the test.
6117 else
6118 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6119 for as_dir in $PATH
6121 IFS=$as_save_IFS
6122 test -z "$as_dir" && as_dir=.
6123 for ac_exec_ext in '' $ac_executable_extensions; do
6124 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6125 ac_cv_prog_AR="${ac_tool_prefix}ar"
6126 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6127 break 2
6129 done
6130 done
6131 IFS=$as_save_IFS
6135 AR=$ac_cv_prog_AR
6136 if test -n "$AR"; then
6137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6138 $as_echo "$AR" >&6; }
6139 else
6140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6141 $as_echo "no" >&6; }
6146 if test -z "$ac_cv_prog_AR"; then
6147 ac_ct_AR=$AR
6148 # Extract the first word of "ar", so it can be a program name with args.
6149 set dummy ar; ac_word=$2
6150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6151 $as_echo_n "checking for $ac_word... " >&6; }
6152 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6153 $as_echo_n "(cached) " >&6
6154 else
6155 if test -n "$ac_ct_AR"; then
6156 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6157 else
6158 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6159 for as_dir in $PATH
6161 IFS=$as_save_IFS
6162 test -z "$as_dir" && as_dir=.
6163 for ac_exec_ext in '' $ac_executable_extensions; do
6164 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6165 ac_cv_prog_ac_ct_AR="ar"
6166 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6167 break 2
6169 done
6170 done
6171 IFS=$as_save_IFS
6175 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6176 if test -n "$ac_ct_AR"; then
6177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6178 $as_echo "$ac_ct_AR" >&6; }
6179 else
6180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6181 $as_echo "no" >&6; }
6184 if test "x$ac_ct_AR" = x; then
6185 AR="ar"
6186 else
6187 case $cross_compiling:$ac_tool_warned in
6188 yes:)
6189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6190 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6191 ac_tool_warned=yes ;;
6192 esac
6193 AR=$ac_ct_AR
6195 else
6196 AR="$ac_cv_prog_AR"
6199 if test -z "$ARFLAGS"; then
6200 ARFLAGS='cru'
6203 else
6204 if test -z "$ARFLAGS"; then
6205 ARFLAGS='cru'
6210 if test -z "$RANLIB"; then
6211 if test $gl_cv_c_amsterdam_compiler = yes; then
6212 RANLIB=':'
6213 else
6214 if test -n "$ac_tool_prefix"; then
6215 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6216 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6218 $as_echo_n "checking for $ac_word... " >&6; }
6219 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6220 $as_echo_n "(cached) " >&6
6221 else
6222 if test -n "$RANLIB"; then
6223 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6224 else
6225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6226 for as_dir in $PATH
6228 IFS=$as_save_IFS
6229 test -z "$as_dir" && as_dir=.
6230 for ac_exec_ext in '' $ac_executable_extensions; do
6231 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6232 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6233 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6234 break 2
6236 done
6237 done
6238 IFS=$as_save_IFS
6242 RANLIB=$ac_cv_prog_RANLIB
6243 if test -n "$RANLIB"; then
6244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6245 $as_echo "$RANLIB" >&6; }
6246 else
6247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6248 $as_echo "no" >&6; }
6253 if test -z "$ac_cv_prog_RANLIB"; then
6254 ac_ct_RANLIB=$RANLIB
6255 # Extract the first word of "ranlib", so it can be a program name with args.
6256 set dummy ranlib; ac_word=$2
6257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6258 $as_echo_n "checking for $ac_word... " >&6; }
6259 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6260 $as_echo_n "(cached) " >&6
6261 else
6262 if test -n "$ac_ct_RANLIB"; then
6263 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6264 else
6265 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6266 for as_dir in $PATH
6268 IFS=$as_save_IFS
6269 test -z "$as_dir" && as_dir=.
6270 for ac_exec_ext in '' $ac_executable_extensions; do
6271 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6272 ac_cv_prog_ac_ct_RANLIB="ranlib"
6273 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6274 break 2
6276 done
6277 done
6278 IFS=$as_save_IFS
6282 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6283 if test -n "$ac_ct_RANLIB"; then
6284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6285 $as_echo "$ac_ct_RANLIB" >&6; }
6286 else
6287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6288 $as_echo "no" >&6; }
6291 if test "x$ac_ct_RANLIB" = x; then
6292 RANLIB=":"
6293 else
6294 case $cross_compiling:$ac_tool_warned in
6295 yes:)
6296 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6297 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6298 ac_tool_warned=yes ;;
6299 esac
6300 RANLIB=$ac_ct_RANLIB
6302 else
6303 RANLIB="$ac_cv_prog_RANLIB"
6310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6311 $as_echo_n "checking for ANSI C header files... " >&6; }
6312 if test "${ac_cv_header_stdc+set}" = set; then :
6313 $as_echo_n "(cached) " >&6
6314 else
6315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6316 /* end confdefs.h. */
6317 #include <stdlib.h>
6318 #include <stdarg.h>
6319 #include <string.h>
6320 #include <float.h>
6323 main ()
6327 return 0;
6329 _ACEOF
6330 if ac_fn_c_try_compile "$LINENO"; then :
6331 ac_cv_header_stdc=yes
6332 else
6333 ac_cv_header_stdc=no
6335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6337 if test $ac_cv_header_stdc = yes; then
6338 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6340 /* end confdefs.h. */
6341 #include <string.h>
6343 _ACEOF
6344 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6345 $EGREP "memchr" >/dev/null 2>&1; then :
6347 else
6348 ac_cv_header_stdc=no
6350 rm -f conftest*
6354 if test $ac_cv_header_stdc = yes; then
6355 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6357 /* end confdefs.h. */
6358 #include <stdlib.h>
6360 _ACEOF
6361 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6362 $EGREP "free" >/dev/null 2>&1; then :
6364 else
6365 ac_cv_header_stdc=no
6367 rm -f conftest*
6371 if test $ac_cv_header_stdc = yes; then
6372 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6373 if test "$cross_compiling" = yes; then :
6375 else
6376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6377 /* end confdefs.h. */
6378 #include <ctype.h>
6379 #include <stdlib.h>
6380 #if ((' ' & 0x0FF) == 0x020)
6381 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6382 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6383 #else
6384 # define ISLOWER(c) \
6385 (('a' <= (c) && (c) <= 'i') \
6386 || ('j' <= (c) && (c) <= 'r') \
6387 || ('s' <= (c) && (c) <= 'z'))
6388 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6389 #endif
6391 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6393 main ()
6395 int i;
6396 for (i = 0; i < 256; i++)
6397 if (XOR (islower (i), ISLOWER (i))
6398 || toupper (i) != TOUPPER (i))
6399 return 2;
6400 return 0;
6402 _ACEOF
6403 if ac_fn_c_try_run "$LINENO"; then :
6405 else
6406 ac_cv_header_stdc=no
6408 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6409 conftest.$ac_objext conftest.beam conftest.$ac_ext
6414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6415 $as_echo "$ac_cv_header_stdc" >&6; }
6416 if test $ac_cv_header_stdc = yes; then
6418 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6422 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6423 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6424 inttypes.h stdint.h unistd.h
6425 do :
6426 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6427 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6429 eval as_val=\$$as_ac_Header
6430 if test "x$as_val" = x""yes; then :
6431 cat >>confdefs.h <<_ACEOF
6432 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6433 _ACEOF
6437 done
6443 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6444 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6445 MINIX=yes
6446 else
6447 MINIX=
6451 if test "$MINIX" = yes; then
6453 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6456 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6459 $as_echo "#define _MINIX 1" >>confdefs.h
6463 case "$host_os" in
6464 hpux*)
6466 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6469 esac
6472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6473 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6474 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6475 $as_echo_n "(cached) " >&6
6476 else
6477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6478 /* end confdefs.h. */
6480 # define __EXTENSIONS__ 1
6481 $ac_includes_default
6483 main ()
6487 return 0;
6489 _ACEOF
6490 if ac_fn_c_try_compile "$LINENO"; then :
6491 ac_cv_safe_to_define___extensions__=yes
6492 else
6493 ac_cv_safe_to_define___extensions__=no
6495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6498 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6499 test $ac_cv_safe_to_define___extensions__ = yes &&
6500 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6502 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6504 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6506 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6508 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6510 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6519 # Check whether --enable-largefile was given.
6520 if test "${enable_largefile+set}" = set; then :
6521 enableval=$enable_largefile;
6524 if test "$enable_largefile" != no; then
6526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6527 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6528 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6529 $as_echo_n "(cached) " >&6
6530 else
6531 ac_cv_sys_largefile_CC=no
6532 if test "$GCC" != yes; then
6533 ac_save_CC=$CC
6534 while :; do
6535 # IRIX 6.2 and later do not support large files by default,
6536 # so use the C compiler's -n32 option if that helps.
6537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6538 /* end confdefs.h. */
6539 #include <sys/types.h>
6540 /* Check that off_t can represent 2**63 - 1 correctly.
6541 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6542 since some C++ compilers masquerading as C compilers
6543 incorrectly reject 9223372036854775807. */
6544 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6545 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6546 && LARGE_OFF_T % 2147483647 == 1)
6547 ? 1 : -1];
6549 main ()
6553 return 0;
6555 _ACEOF
6556 if ac_fn_c_try_compile "$LINENO"; then :
6557 break
6559 rm -f core conftest.err conftest.$ac_objext
6560 CC="$CC -n32"
6561 if ac_fn_c_try_compile "$LINENO"; then :
6562 ac_cv_sys_largefile_CC=' -n32'; break
6564 rm -f core conftest.err conftest.$ac_objext
6565 break
6566 done
6567 CC=$ac_save_CC
6568 rm -f conftest.$ac_ext
6571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6572 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6573 if test "$ac_cv_sys_largefile_CC" != no; then
6574 CC=$CC$ac_cv_sys_largefile_CC
6577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6578 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6579 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6580 $as_echo_n "(cached) " >&6
6581 else
6582 while :; do
6583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6584 /* end confdefs.h. */
6585 #include <sys/types.h>
6586 /* Check that off_t can represent 2**63 - 1 correctly.
6587 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6588 since some C++ compilers masquerading as C compilers
6589 incorrectly reject 9223372036854775807. */
6590 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6591 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6592 && LARGE_OFF_T % 2147483647 == 1)
6593 ? 1 : -1];
6595 main ()
6599 return 0;
6601 _ACEOF
6602 if ac_fn_c_try_compile "$LINENO"; then :
6603 ac_cv_sys_file_offset_bits=no; break
6605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6607 /* end confdefs.h. */
6608 #define _FILE_OFFSET_BITS 64
6609 #include <sys/types.h>
6610 /* Check that off_t can represent 2**63 - 1 correctly.
6611 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6612 since some C++ compilers masquerading as C compilers
6613 incorrectly reject 9223372036854775807. */
6614 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6615 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6616 && LARGE_OFF_T % 2147483647 == 1)
6617 ? 1 : -1];
6619 main ()
6623 return 0;
6625 _ACEOF
6626 if ac_fn_c_try_compile "$LINENO"; then :
6627 ac_cv_sys_file_offset_bits=64; break
6629 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6630 ac_cv_sys_file_offset_bits=unknown
6631 break
6632 done
6634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6635 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6636 case $ac_cv_sys_file_offset_bits in #(
6637 no | unknown) ;;
6639 cat >>confdefs.h <<_ACEOF
6640 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6641 _ACEOF
6643 esac
6644 rm -rf conftest*
6645 if test $ac_cv_sys_file_offset_bits = unknown; then
6646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6647 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6648 if test "${ac_cv_sys_large_files+set}" = set; then :
6649 $as_echo_n "(cached) " >&6
6650 else
6651 while :; do
6652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6653 /* end confdefs.h. */
6654 #include <sys/types.h>
6655 /* Check that off_t can represent 2**63 - 1 correctly.
6656 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6657 since some C++ compilers masquerading as C compilers
6658 incorrectly reject 9223372036854775807. */
6659 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6660 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6661 && LARGE_OFF_T % 2147483647 == 1)
6662 ? 1 : -1];
6664 main ()
6668 return 0;
6670 _ACEOF
6671 if ac_fn_c_try_compile "$LINENO"; then :
6672 ac_cv_sys_large_files=no; break
6674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6676 /* end confdefs.h. */
6677 #define _LARGE_FILES 1
6678 #include <sys/types.h>
6679 /* Check that off_t can represent 2**63 - 1 correctly.
6680 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6681 since some C++ compilers masquerading as C compilers
6682 incorrectly reject 9223372036854775807. */
6683 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6684 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6685 && LARGE_OFF_T % 2147483647 == 1)
6686 ? 1 : -1];
6688 main ()
6692 return 0;
6694 _ACEOF
6695 if ac_fn_c_try_compile "$LINENO"; then :
6696 ac_cv_sys_large_files=1; break
6698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6699 ac_cv_sys_large_files=unknown
6700 break
6701 done
6703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6704 $as_echo "$ac_cv_sys_large_files" >&6; }
6705 case $ac_cv_sys_large_files in #(
6706 no | unknown) ;;
6708 cat >>confdefs.h <<_ACEOF
6709 #define _LARGE_FILES $ac_cv_sys_large_files
6710 _ACEOF
6712 esac
6713 rm -rf conftest*
6717 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6721 case $ac_cv_prog_cc_stdc in #(
6722 no) :
6723 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6724 *) :
6725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6726 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6727 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6728 $as_echo_n "(cached) " >&6
6729 else
6730 ac_cv_prog_cc_c99=no
6731 ac_save_CC=$CC
6732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6733 /* end confdefs.h. */
6734 #include <stdarg.h>
6735 #include <stdbool.h>
6736 #include <stdlib.h>
6737 #include <wchar.h>
6738 #include <stdio.h>
6740 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6741 #define debug(...) fprintf (stderr, __VA_ARGS__)
6742 #define showlist(...) puts (#__VA_ARGS__)
6743 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6744 static void
6745 test_varargs_macros (void)
6747 int x = 1234;
6748 int y = 5678;
6749 debug ("Flag");
6750 debug ("X = %d\n", x);
6751 showlist (The first, second, and third items.);
6752 report (x>y, "x is %d but y is %d", x, y);
6755 // Check long long types.
6756 #define BIG64 18446744073709551615ull
6757 #define BIG32 4294967295ul
6758 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6759 #if !BIG_OK
6760 your preprocessor is broken;
6761 #endif
6762 #if BIG_OK
6763 #else
6764 your preprocessor is broken;
6765 #endif
6766 static long long int bignum = -9223372036854775807LL;
6767 static unsigned long long int ubignum = BIG64;
6769 struct incomplete_array
6771 int datasize;
6772 double data[];
6775 struct named_init {
6776 int number;
6777 const wchar_t *name;
6778 double average;
6781 typedef const char *ccp;
6783 static inline int
6784 test_restrict (ccp restrict text)
6786 // See if C++-style comments work.
6787 // Iterate through items via the restricted pointer.
6788 // Also check for declarations in for loops.
6789 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6790 continue;
6791 return 0;
6794 // Check varargs and va_copy.
6795 static void
6796 test_varargs (const char *format, ...)
6798 va_list args;
6799 va_start (args, format);
6800 va_list args_copy;
6801 va_copy (args_copy, args);
6803 const char *str;
6804 int number;
6805 float fnumber;
6807 while (*format)
6809 switch (*format++)
6811 case 's': // string
6812 str = va_arg (args_copy, const char *);
6813 break;
6814 case 'd': // int
6815 number = va_arg (args_copy, int);
6816 break;
6817 case 'f': // float
6818 fnumber = va_arg (args_copy, double);
6819 break;
6820 default:
6821 break;
6824 va_end (args_copy);
6825 va_end (args);
6829 main ()
6832 // Check bool.
6833 _Bool success = false;
6835 // Check restrict.
6836 if (test_restrict ("String literal") == 0)
6837 success = true;
6838 char *restrict newvar = "Another string";
6840 // Check varargs.
6841 test_varargs ("s, d' f .", "string", 65, 34.234);
6842 test_varargs_macros ();
6844 // Check flexible array members.
6845 struct incomplete_array *ia =
6846 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6847 ia->datasize = 10;
6848 for (int i = 0; i < ia->datasize; ++i)
6849 ia->data[i] = i * 1.234;
6851 // Check named initializers.
6852 struct named_init ni = {
6853 .number = 34,
6854 .name = L"Test wide string",
6855 .average = 543.34343,
6858 ni.number = 58;
6860 int dynamic_array[ni.number];
6861 dynamic_array[ni.number - 1] = 543;
6863 // work around unused variable warnings
6864 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6865 || dynamic_array[ni.number - 1] != 543);
6868 return 0;
6870 _ACEOF
6871 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6873 CC="$ac_save_CC $ac_arg"
6874 if ac_fn_c_try_compile "$LINENO"; then :
6875 ac_cv_prog_cc_c99=$ac_arg
6877 rm -f core conftest.err conftest.$ac_objext
6878 test "x$ac_cv_prog_cc_c99" != "xno" && break
6879 done
6880 rm -f conftest.$ac_ext
6881 CC=$ac_save_CC
6884 # AC_CACHE_VAL
6885 case "x$ac_cv_prog_cc_c99" in
6887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6888 $as_echo "none needed" >&6; } ;;
6889 xno)
6890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6891 $as_echo "unsupported" >&6; } ;;
6893 CC="$CC $ac_cv_prog_cc_c99"
6894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6895 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6896 esac
6897 if test "x$ac_cv_prog_cc_c99" != xno; then :
6898 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6899 else
6900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6901 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6902 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6903 $as_echo_n "(cached) " >&6
6904 else
6905 ac_cv_prog_cc_c89=no
6906 ac_save_CC=$CC
6907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6908 /* end confdefs.h. */
6909 #include <stdarg.h>
6910 #include <stdio.h>
6911 #include <sys/types.h>
6912 #include <sys/stat.h>
6913 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6914 struct buf { int x; };
6915 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6916 static char *e (p, i)
6917 char **p;
6918 int i;
6920 return p[i];
6922 static char *f (char * (*g) (char **, int), char **p, ...)
6924 char *s;
6925 va_list v;
6926 va_start (v,p);
6927 s = g (p, va_arg (v,int));
6928 va_end (v);
6929 return s;
6932 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6933 function prototypes and stuff, but not '\xHH' hex character constants.
6934 These don't provoke an error unfortunately, instead are silently treated
6935 as 'x'. The following induces an error, until -std is added to get
6936 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6937 array size at least. It's necessary to write '\x00'==0 to get something
6938 that's true only with -std. */
6939 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6941 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6942 inside strings and character constants. */
6943 #define FOO(x) 'x'
6944 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6946 int test (int i, double x);
6947 struct s1 {int (*f) (int a);};
6948 struct s2 {int (*f) (double a);};
6949 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6950 int argc;
6951 char **argv;
6953 main ()
6955 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6957 return 0;
6959 _ACEOF
6960 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6961 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6963 CC="$ac_save_CC $ac_arg"
6964 if ac_fn_c_try_compile "$LINENO"; then :
6965 ac_cv_prog_cc_c89=$ac_arg
6967 rm -f core conftest.err conftest.$ac_objext
6968 test "x$ac_cv_prog_cc_c89" != "xno" && break
6969 done
6970 rm -f conftest.$ac_ext
6971 CC=$ac_save_CC
6974 # AC_CACHE_VAL
6975 case "x$ac_cv_prog_cc_c89" in
6977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6978 $as_echo "none needed" >&6; } ;;
6979 xno)
6980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6981 $as_echo "unsupported" >&6; } ;;
6983 CC="$CC $ac_cv_prog_cc_c89"
6984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6985 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6986 esac
6987 if test "x$ac_cv_prog_cc_c89" != xno; then :
6988 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6989 else
6990 ac_cv_prog_cc_stdc=no
6995 esac
6996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6997 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6998 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6999 $as_echo_n "(cached) " >&6
7002 case $ac_cv_prog_cc_stdc in #(
7003 no) :
7004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7005 $as_echo "unsupported" >&6; } ;; #(
7006 '') :
7007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7008 $as_echo "none needed" >&6; } ;; #(
7009 *) :
7010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7011 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7012 esac
7016 # Code from module alloca-opt:
7017 # Code from module allocator:
7018 # Code from module c-ctype:
7019 # Code from module c-strcase:
7020 # Code from module careadlinkat:
7021 # Code from module clock-time:
7022 # Code from module close-stream:
7023 # Code from module crypto/md5:
7024 # Code from module crypto/sha1:
7025 # Code from module crypto/sha256:
7026 # Code from module crypto/sha512:
7027 # Code from module dosname:
7028 # Code from module dtoastr:
7029 # Code from module dtotimespec:
7030 # Code from module dup2:
7031 # Code from module environ:
7032 # Code from module euidaccess:
7033 # Code from module execinfo:
7034 # Code from module extensions:
7036 # Code from module extern-inline:
7037 # Code from module faccessat:
7038 # Code from module fcntl-h:
7039 # Code from module filemode:
7040 # Code from module fpending:
7041 # Code from module getgroups:
7042 # Code from module getloadavg:
7043 # Code from module getopt-gnu:
7044 # Code from module getopt-posix:
7045 # Code from module gettext-h:
7046 # Code from module gettime:
7047 # Code from module gettimeofday:
7048 # Code from module group-member:
7049 # Code from module ignore-value:
7050 # Code from module include_next:
7051 # Code from module intprops:
7052 # Code from module inttypes-incomplete:
7053 # Code from module largefile:
7055 # Code from module lstat:
7056 # Code from module manywarnings:
7057 # Code from module mktime:
7058 # Code from module multiarch:
7059 # Code from module nocrash:
7060 # Code from module pathmax:
7061 # Code from module pselect:
7062 # Code from module pthread_sigmask:
7063 # Code from module putenv:
7064 # Code from module readlink:
7065 # Code from module root-uid:
7066 # Code from module sig2str:
7067 # Code from module signal-h:
7068 # Code from module snippet/_Noreturn:
7069 # Code from module snippet/arg-nonnull:
7070 # Code from module snippet/c++defs:
7071 # Code from module snippet/warn-on-use:
7072 # Code from module socklen:
7073 # Code from module ssize_t:
7074 # Code from module stat:
7075 # Code from module stat-time:
7076 # Code from module stdalign:
7077 # Code from module stdarg:
7081 # Code from module stdbool:
7082 # Code from module stddef:
7083 # Code from module stdint:
7084 # Code from module stdio:
7085 # Code from module stdlib:
7086 # Code from module strftime:
7087 # Code from module strtoimax:
7088 # Code from module strtoll:
7089 # Code from module strtoull:
7090 # Code from module strtoumax:
7091 # Code from module symlink:
7092 # Code from module sys_select:
7093 # Code from module sys_stat:
7094 # Code from module sys_time:
7095 # Code from module time:
7096 # Code from module time_r:
7097 # Code from module timer-time:
7098 # Code from module timespec:
7099 # Code from module timespec-add:
7100 # Code from module timespec-sub:
7101 # Code from module u64:
7102 # Code from module unistd:
7103 # Code from module unsetenv:
7104 # Code from module utimens:
7105 # Code from module verify:
7106 # Code from module warnings:
7107 # Code from module xalloc-oversized:
7110 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7111 # if -g3 works and the user does not specify CFLAGS.
7112 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7113 if test "$ac_test_CFLAGS" != set; then
7114 case $CFLAGS in
7115 '-g')
7116 emacs_g3_CFLAGS='-g3';;
7117 '-g -O2')
7118 emacs_g3_CFLAGS='-g3 -O2';;
7120 emacs_g3_CFLAGS='';;
7121 esac
7122 if test -n "$emacs_g3_CFLAGS"; then
7123 emacs_save_CFLAGS=$CFLAGS
7124 CFLAGS=$emacs_g3_CFLAGS
7125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7126 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7127 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7128 $as_echo_n "(cached) " >&6
7129 else
7130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7131 /* end confdefs.h. */
7134 main ()
7138 return 0;
7140 _ACEOF
7141 if ac_fn_c_try_link "$LINENO"; then :
7142 emacs_cv_prog_cc_g3=yes
7143 else
7144 emacs_cv_prog_cc_g3=no
7146 rm -f core conftest.err conftest.$ac_objext \
7147 conftest$ac_exeext conftest.$ac_ext
7149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7150 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7151 if test $emacs_cv_prog_cc_g3 = yes; then
7152 CFLAGS=$emacs_g3_CFLAGS
7153 else
7154 CFLAGS=$emacs_save_CFLAGS
7159 # Check whether --enable-gcc-warnings was given.
7160 if test "${enable_gcc_warnings+set}" = set; then :
7161 enableval=$enable_gcc_warnings; case $enableval in
7162 yes|no) ;;
7163 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7164 esac
7165 gl_gcc_warnings=$enableval
7166 else
7167 gl_gcc_warnings=no
7172 # Check whether --enable-link-time-optimization was given.
7173 if test "${enable_link_time_optimization+set}" = set; then :
7174 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7176 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7177 ac_lto_supported=no
7178 if test x$GCC = xyes; then
7179 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7180 if test x$CPUS != x; then
7181 LTO="-flto=$CPUS"
7182 else
7183 LTO="-flto"
7185 old_CFLAGS=$CFLAGS
7186 CFLAGS="$CFLAGS $LTO"
7187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7188 /* end confdefs.h. */
7191 main ()
7195 return 0;
7197 _ACEOF
7198 if ac_fn_c_try_compile "$LINENO"; then :
7199 ac_lto_supported=yes
7200 else
7201 ac_lto_supported=no
7203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7204 CFLAGS="$old_CFLAGS"
7206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7207 $as_echo "$ac_lto_supported" >&6; }
7208 if test "$ac_lto_supported" = "yes"; then
7209 CFLAGS="$CFLAGS $LTO"
7215 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7216 # ------------------------------------------------
7217 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7218 # Otherwise, run RUN-IF-NOT-FOUND.
7221 # When compiling with GCC, prefer -isystem to -I when including system
7222 # include files, to avoid generating useless diagnostics for the files.
7223 if test "$gl_gcc_warnings" != yes; then
7224 isystem='-I'
7225 else
7226 isystem='-isystem '
7228 # This, $nw, is the list of warnings we disable.
7231 case $with_x_toolkit in
7232 lucid | athena | motif)
7233 # Old toolkits mishandle 'const'.
7234 nw="$nw -Wwrite-strings"
7237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7238 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7239 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7240 $as_echo_n "(cached) " >&6
7241 else
7243 gl_save_compiler_FLAGS="$CFLAGS"
7244 as_fn_append CFLAGS " -Werror"
7245 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7246 /* end confdefs.h. */
7249 main ()
7253 return 0;
7255 _ACEOF
7256 if ac_fn_c_try_compile "$LINENO"; then :
7257 gl_cv_warn_c__Werror=yes
7258 else
7259 gl_cv_warn_c__Werror=no
7261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7262 CFLAGS="$gl_save_compiler_FLAGS"
7265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7266 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7267 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7268 as_fn_append WERROR_CFLAGS " -Werror"
7273 esac
7276 nw="$nw -Waggregate-return" # anachronistic
7277 nw="$nw -Wlong-long" # C90 is anachronistic
7278 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7279 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7280 nw="$nw -Wtraditional" # Warns on #elif which we use often
7281 nw="$nw -Wcast-qual" # Too many warnings for now
7282 nw="$nw -Wconversion" # Too many warnings for now
7283 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7284 nw="$nw -Wsign-conversion" # Too many warnings for now
7285 nw="$nw -Woverlength-strings" # Not a problem these days
7286 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7287 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7288 nw="$nw -Wpadded" # Our structs are not padded
7289 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7290 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7291 nw="$nw -Wformat-nonliteral" # we do this a lot
7292 nw="$nw -Wvla" # warnings in gettext.h
7293 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7294 nw="$nw -Wswitch-enum" # Too many warnings for now
7295 nw="$nw -Wswitch-default" # Too many warnings for now
7296 nw="$nw -Wfloat-equal" # warns about high-quality code
7297 nw="$nw -Winline" # OK to ignore 'inline'
7298 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7299 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7300 # signed overflow has undefined behavior
7301 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7302 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7304 # Emacs doesn't care about shadowing; see
7305 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7306 nw="$nw -Wshadow"
7308 # Emacs's use of alloca inhibits protecting the stack.
7309 nw="$nw -Wstack-protector"
7311 # The following line should be removable at some point.
7312 nw="$nw -Wsuggest-attribute=pure"
7316 if test -n "$GCC"; then
7318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7319 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7320 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7321 $as_echo_n "(cached) " >&6
7322 else
7324 gl_save_CFLAGS="$CFLAGS"
7325 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7327 /* end confdefs.h. */
7330 main ()
7334 return 0;
7336 _ACEOF
7337 if ac_fn_c_try_compile "$LINENO"; then :
7338 gl_cv_cc_nomfi_supported=yes
7339 else
7340 gl_cv_cc_nomfi_supported=no
7342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7343 CFLAGS="$gl_save_CFLAGS"
7346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7347 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7349 if test "$gl_cv_cc_nomfi_supported" = yes; then
7350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7351 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7352 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7353 $as_echo_n "(cached) " >&6
7354 else
7356 gl_save_CFLAGS="$CFLAGS"
7357 CFLAGS="$CFLAGS -W -Werror"
7358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7359 /* end confdefs.h. */
7360 void f (void)
7362 typedef struct { int a; int b; } s_t;
7363 s_t s1 = { 0, };
7367 main ()
7371 return 0;
7373 _ACEOF
7374 if ac_fn_c_try_compile "$LINENO"; then :
7375 gl_cv_cc_nomfi_needed=no
7376 else
7377 gl_cv_cc_nomfi_needed=yes
7379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7380 CFLAGS="$gl_save_CFLAGS"
7384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7385 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7389 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7390 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7391 $as_echo_n "(cached) " >&6
7392 else
7394 gl_save_CFLAGS="$CFLAGS"
7395 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7397 /* end confdefs.h. */
7400 main ()
7404 return 0;
7406 _ACEOF
7407 if ac_fn_c_try_compile "$LINENO"; then :
7408 gl_cv_cc_uninitialized_supported=yes
7409 else
7410 gl_cv_cc_uninitialized_supported=no
7412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7413 CFLAGS="$gl_save_CFLAGS"
7416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7417 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7421 # List all gcc warning categories.
7422 gl_manywarn_set=
7423 for gl_manywarn_item in \
7424 -W \
7425 -Wabi \
7426 -Waddress \
7427 -Wall \
7428 -Warray-bounds \
7429 -Wattributes \
7430 -Wbad-function-cast \
7431 -Wbuiltin-macro-redefined \
7432 -Wcast-align \
7433 -Wchar-subscripts \
7434 -Wclobbered \
7435 -Wcomment \
7436 -Wcomments \
7437 -Wcoverage-mismatch \
7438 -Wcpp \
7439 -Wdeprecated \
7440 -Wdeprecated-declarations \
7441 -Wdisabled-optimization \
7442 -Wdiv-by-zero \
7443 -Wdouble-promotion \
7444 -Wempty-body \
7445 -Wendif-labels \
7446 -Wenum-compare \
7447 -Wextra \
7448 -Wformat-contains-nul \
7449 -Wformat-extra-args \
7450 -Wformat-nonliteral \
7451 -Wformat-security \
7452 -Wformat-y2k \
7453 -Wformat-zero-length \
7454 -Wformat=2 \
7455 -Wfree-nonheap-object \
7456 -Wignored-qualifiers \
7457 -Wimplicit \
7458 -Wimplicit-function-declaration \
7459 -Wimplicit-int \
7460 -Winit-self \
7461 -Winline \
7462 -Wint-to-pointer-cast \
7463 -Winvalid-memory-model \
7464 -Winvalid-pch \
7465 -Wjump-misses-init \
7466 -Wlogical-op \
7467 -Wmain \
7468 -Wmaybe-uninitialized \
7469 -Wmissing-braces \
7470 -Wmissing-declarations \
7471 -Wmissing-field-initializers \
7472 -Wmissing-format-attribute \
7473 -Wmissing-include-dirs \
7474 -Wmissing-noreturn \
7475 -Wmissing-parameter-type \
7476 -Wmissing-prototypes \
7477 -Wmudflap \
7478 -Wmultichar \
7479 -Wnarrowing \
7480 -Wnested-externs \
7481 -Wnonnull \
7482 -Wnormalized=nfc \
7483 -Wold-style-declaration \
7484 -Wold-style-definition \
7485 -Woverflow \
7486 -Woverlength-strings \
7487 -Woverride-init \
7488 -Wpacked \
7489 -Wpacked-bitfield-compat \
7490 -Wparentheses \
7491 -Wpointer-arith \
7492 -Wpointer-sign \
7493 -Wpointer-to-int-cast \
7494 -Wpragmas \
7495 -Wreturn-type \
7496 -Wsequence-point \
7497 -Wshadow \
7498 -Wsizeof-pointer-memaccess \
7499 -Wstack-protector \
7500 -Wstrict-aliasing \
7501 -Wstrict-overflow \
7502 -Wstrict-prototypes \
7503 -Wsuggest-attribute=const \
7504 -Wsuggest-attribute=format \
7505 -Wsuggest-attribute=noreturn \
7506 -Wsuggest-attribute=pure \
7507 -Wswitch \
7508 -Wswitch-default \
7509 -Wsync-nand \
7510 -Wsystem-headers \
7511 -Wtrampolines \
7512 -Wtrigraphs \
7513 -Wtype-limits \
7514 -Wuninitialized \
7515 -Wunknown-pragmas \
7516 -Wunreachable-code \
7517 -Wunsafe-loop-optimizations \
7518 -Wunused \
7519 -Wunused-but-set-parameter \
7520 -Wunused-but-set-variable \
7521 -Wunused-function \
7522 -Wunused-label \
7523 -Wunused-local-typedefs \
7524 -Wunused-macros \
7525 -Wunused-parameter \
7526 -Wunused-result \
7527 -Wunused-value \
7528 -Wunused-variable \
7529 -Wvarargs \
7530 -Wvariadic-macros \
7531 -Wvector-operation-performance \
7532 -Wvla \
7533 -Wvolatile-register-var \
7534 -Wwrite-strings \
7536 ; do
7537 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7538 done
7540 # Disable specific options as needed.
7541 if test "$gl_cv_cc_nomfi_needed" = yes; then
7542 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7545 if test "$gl_cv_cc_uninitialized_supported" = no; then
7546 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7549 ws=$gl_manywarn_set
7552 gl_warn_set=
7553 set x $ws; shift
7554 for gl_warn_item
7556 case " $nw " in
7557 *" $gl_warn_item "*)
7560 gl_warn_set="$gl_warn_set $gl_warn_item"
7562 esac
7563 done
7564 ws=$gl_warn_set
7566 for w in $ws; do
7567 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7569 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7570 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7571 $as_echo_n "(cached) " >&6
7572 else
7574 gl_save_compiler_FLAGS="$CFLAGS"
7575 as_fn_append CFLAGS " $w"
7576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7577 /* end confdefs.h. */
7580 main ()
7584 return 0;
7586 _ACEOF
7587 if ac_fn_c_try_compile "$LINENO"; then :
7588 eval "$as_gl_Warn=yes"
7589 else
7590 eval "$as_gl_Warn=no"
7592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7593 CFLAGS="$gl_save_compiler_FLAGS"
7596 eval ac_res=\$$as_gl_Warn
7597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7598 $as_echo "$ac_res" >&6; }
7599 eval as_val=\$$as_gl_Warn
7600 if test "x$as_val" = x""yes; then :
7601 as_fn_append WARN_CFLAGS " $w"
7605 done
7606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7607 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7608 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7609 $as_echo_n "(cached) " >&6
7610 else
7612 gl_save_compiler_FLAGS="$CFLAGS"
7613 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7615 /* end confdefs.h. */
7618 main ()
7622 return 0;
7624 _ACEOF
7625 if ac_fn_c_try_compile "$LINENO"; then :
7626 gl_cv_warn_c__Wno_missing_field_initializers=yes
7627 else
7628 gl_cv_warn_c__Wno_missing_field_initializers=no
7630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7631 CFLAGS="$gl_save_compiler_FLAGS"
7634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7635 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7636 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7637 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7640 # We need this one
7641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7642 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7643 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7644 $as_echo_n "(cached) " >&6
7645 else
7647 gl_save_compiler_FLAGS="$CFLAGS"
7648 as_fn_append CFLAGS " -Wno-sign-compare"
7649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7650 /* end confdefs.h. */
7653 main ()
7657 return 0;
7659 _ACEOF
7660 if ac_fn_c_try_compile "$LINENO"; then :
7661 gl_cv_warn_c__Wno_sign_compare=yes
7662 else
7663 gl_cv_warn_c__Wno_sign_compare=no
7665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7666 CFLAGS="$gl_save_compiler_FLAGS"
7669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7670 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7671 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7672 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7675 # Too many warnings for now
7676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7677 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7678 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7679 $as_echo_n "(cached) " >&6
7680 else
7682 gl_save_compiler_FLAGS="$CFLAGS"
7683 as_fn_append CFLAGS " -Wno-type-limits"
7684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7685 /* end confdefs.h. */
7688 main ()
7692 return 0;
7694 _ACEOF
7695 if ac_fn_c_try_compile "$LINENO"; then :
7696 gl_cv_warn_c__Wno_type_limits=yes
7697 else
7698 gl_cv_warn_c__Wno_type_limits=no
7700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7701 CFLAGS="$gl_save_compiler_FLAGS"
7704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7705 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7706 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7707 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7710 # Too many warnings for now
7711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7712 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7713 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7714 $as_echo_n "(cached) " >&6
7715 else
7717 gl_save_compiler_FLAGS="$CFLAGS"
7718 as_fn_append CFLAGS " -Wno-switch"
7719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7720 /* end confdefs.h. */
7723 main ()
7727 return 0;
7729 _ACEOF
7730 if ac_fn_c_try_compile "$LINENO"; then :
7731 gl_cv_warn_c__Wno_switch=yes
7732 else
7733 gl_cv_warn_c__Wno_switch=no
7735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7736 CFLAGS="$gl_save_compiler_FLAGS"
7739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7740 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7741 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7742 as_fn_append WARN_CFLAGS " -Wno-switch"
7745 # Too many warnings for now
7746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7747 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7748 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7749 $as_echo_n "(cached) " >&6
7750 else
7752 gl_save_compiler_FLAGS="$CFLAGS"
7753 as_fn_append CFLAGS " -Wno-unused-parameter"
7754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7755 /* end confdefs.h. */
7758 main ()
7762 return 0;
7764 _ACEOF
7765 if ac_fn_c_try_compile "$LINENO"; then :
7766 gl_cv_warn_c__Wno_unused_parameter=yes
7767 else
7768 gl_cv_warn_c__Wno_unused_parameter=no
7770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7771 CFLAGS="$gl_save_compiler_FLAGS"
7774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7775 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7776 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7777 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7780 # Too many warnings for now
7781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7782 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7783 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7784 $as_echo_n "(cached) " >&6
7785 else
7787 gl_save_compiler_FLAGS="$CFLAGS"
7788 as_fn_append CFLAGS " -Wno-format-nonliteral"
7789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7790 /* end confdefs.h. */
7793 main ()
7797 return 0;
7799 _ACEOF
7800 if ac_fn_c_try_compile "$LINENO"; then :
7801 gl_cv_warn_c__Wno_format_nonliteral=yes
7802 else
7803 gl_cv_warn_c__Wno_format_nonliteral=no
7805 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7806 CFLAGS="$gl_save_compiler_FLAGS"
7809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7810 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7811 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7812 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7817 # In spite of excluding -Wlogical-op above, it is enabled, as of
7818 # gcc 4.5.0 20090517.
7819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7820 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7821 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7822 $as_echo_n "(cached) " >&6
7823 else
7825 gl_save_compiler_FLAGS="$CFLAGS"
7826 as_fn_append CFLAGS " -Wno-logical-op"
7827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7828 /* end confdefs.h. */
7831 main ()
7835 return 0;
7837 _ACEOF
7838 if ac_fn_c_try_compile "$LINENO"; then :
7839 gl_cv_warn_c__Wno_logical_op=yes
7840 else
7841 gl_cv_warn_c__Wno_logical_op=no
7843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7844 CFLAGS="$gl_save_compiler_FLAGS"
7847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7848 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7849 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7850 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7856 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7857 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7858 $as_echo_n "(cached) " >&6
7859 else
7861 gl_save_compiler_FLAGS="$CFLAGS"
7862 as_fn_append CFLAGS " -fdiagnostics-show-option"
7863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7864 /* end confdefs.h. */
7867 main ()
7871 return 0;
7873 _ACEOF
7874 if ac_fn_c_try_compile "$LINENO"; then :
7875 gl_cv_warn_c__fdiagnostics_show_option=yes
7876 else
7877 gl_cv_warn_c__fdiagnostics_show_option=no
7879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7880 CFLAGS="$gl_save_compiler_FLAGS"
7883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7884 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7885 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7886 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7891 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7892 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7893 $as_echo_n "(cached) " >&6
7894 else
7896 gl_save_compiler_FLAGS="$CFLAGS"
7897 as_fn_append CFLAGS " -funit-at-a-time"
7898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7899 /* end confdefs.h. */
7902 main ()
7906 return 0;
7908 _ACEOF
7909 if ac_fn_c_try_compile "$LINENO"; then :
7910 gl_cv_warn_c__funit_at_a_time=yes
7911 else
7912 gl_cv_warn_c__funit_at_a_time=no
7914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7915 CFLAGS="$gl_save_compiler_FLAGS"
7918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7919 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7920 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7921 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7927 $as_echo "#define lint 1" >>confdefs.h
7931 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7934 # We use a slightly smaller set of warning options for lib/.
7935 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7937 nw="$nw -Wunused-macros"
7940 gl_warn_set=
7941 set x $WARN_CFLAGS; shift
7942 for gl_warn_item
7944 case " $nw " in
7945 *" $gl_warn_item "*)
7948 gl_warn_set="$gl_warn_set $gl_warn_item"
7950 esac
7951 done
7952 GNULIB_WARN_CFLAGS=$gl_warn_set
7959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7960 $as_echo_n "checking whether ln -s works... " >&6; }
7961 LN_S=$as_ln_s
7962 if test "$LN_S" = "ln -s"; then
7963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7964 $as_echo "yes" >&6; }
7965 else
7966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7967 $as_echo "no, using $LN_S" >&6; }
7971 # Extract the first word of "install-info", so it can be a program name with args.
7972 set dummy install-info; ac_word=$2
7973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7974 $as_echo_n "checking for $ac_word... " >&6; }
7975 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7976 $as_echo_n "(cached) " >&6
7977 else
7978 case $INSTALL_INFO in
7979 [\\/]* | ?:[\\/]*)
7980 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7983 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7984 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7986 IFS=$as_save_IFS
7987 test -z "$as_dir" && as_dir=.
7988 for ac_exec_ext in '' $ac_executable_extensions; do
7989 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7990 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7991 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7992 break 2
7994 done
7995 done
7996 IFS=$as_save_IFS
7998 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8000 esac
8002 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8003 if test -n "$INSTALL_INFO"; then
8004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8005 $as_echo "$INSTALL_INFO" >&6; }
8006 else
8007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8008 $as_echo "no" >&6; }
8012 # Extract the first word of "gzip", so it can be a program name with args.
8013 set dummy gzip; ac_word=$2
8014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8015 $as_echo_n "checking for $ac_word... " >&6; }
8016 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8017 $as_echo_n "(cached) " >&6
8018 else
8019 case $GZIP_PROG in
8020 [\\/]* | ?:[\\/]*)
8021 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8025 for as_dir in $PATH
8027 IFS=$as_save_IFS
8028 test -z "$as_dir" && as_dir=.
8029 for ac_exec_ext in '' $ac_executable_extensions; do
8030 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8031 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8033 break 2
8035 done
8036 done
8037 IFS=$as_save_IFS
8040 esac
8042 GZIP_PROG=$ac_cv_path_GZIP_PROG
8043 if test -n "$GZIP_PROG"; then
8044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8045 $as_echo "$GZIP_PROG" >&6; }
8046 else
8047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8048 $as_echo "no" >&6; }
8053 if test $opsys = gnu-linux; then
8054 # Extract the first word of "paxctl", so it can be a program name with args.
8055 set dummy paxctl; ac_word=$2
8056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8057 $as_echo_n "checking for $ac_word... " >&6; }
8058 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8059 $as_echo_n "(cached) " >&6
8060 else
8061 case $PAXCTL in
8062 [\\/]* | ?:[\\/]*)
8063 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8066 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8067 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8069 IFS=$as_save_IFS
8070 test -z "$as_dir" && as_dir=.
8071 for ac_exec_ext in '' $ac_executable_extensions; do
8072 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8073 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8074 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8075 break 2
8077 done
8078 done
8079 IFS=$as_save_IFS
8082 esac
8084 PAXCTL=$ac_cv_path_PAXCTL
8085 if test -n "$PAXCTL"; then
8086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8087 $as_echo "$PAXCTL" >&6; }
8088 else
8089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8090 $as_echo "no" >&6; }
8094 if test "X$PAXCTL" != X; then
8095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8096 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8098 /* end confdefs.h. */
8101 main ()
8105 return 0;
8107 _ACEOF
8108 if ac_fn_c_try_link "$LINENO"; then :
8109 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8110 $as_echo "yes" >&6; }
8111 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8112 $as_echo "no" >&6; }; PAXCTL=""; fi
8114 rm -f core conftest.err conftest.$ac_objext \
8115 conftest$ac_exeext conftest.$ac_ext
8119 ## Need makeinfo >= 4.7 (?) to build the manuals.
8120 # Extract the first word of "makeinfo", so it can be a program name with args.
8121 set dummy makeinfo; ac_word=$2
8122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8123 $as_echo_n "checking for $ac_word... " >&6; }
8124 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8125 $as_echo_n "(cached) " >&6
8126 else
8127 case $MAKEINFO in
8128 [\\/]* | ?:[\\/]*)
8129 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8133 for as_dir in $PATH
8135 IFS=$as_save_IFS
8136 test -z "$as_dir" && as_dir=.
8137 for ac_exec_ext in '' $ac_executable_extensions; do
8138 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8139 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8140 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8141 break 2
8143 done
8144 done
8145 IFS=$as_save_IFS
8147 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8149 esac
8151 MAKEINFO=$ac_cv_path_MAKEINFO
8152 if test -n "$MAKEINFO"; then
8153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8154 $as_echo "$MAKEINFO" >&6; }
8155 else
8156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8157 $as_echo "no" >&6; }
8161 if test "$MAKEINFO" != "no"; then
8162 case `
8163 $MAKEINFO --version 2> /dev/null |
8164 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8165 ` in
8166 '') MAKEINFO=no;;
8167 esac
8170 ## Makeinfo is unusual. For a released Emacs, the manuals are
8171 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8172 ## therefore in the category of "special tools" not normally required, which
8173 ## configure does not have to check for (eg autoconf itself).
8174 ## In a Bazaar checkout on the other hand, the manuals are not included.
8175 ## So makeinfo is a requirement to build from Bazaar, and configure
8176 ## should test for it as it does for any other build requirement.
8177 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8178 ## with pre-built manuals, from a Bazaar checkout.
8179 HAVE_MAKEINFO=yes
8181 if test "$MAKEINFO" = "no"; then
8182 MAKEINFO=makeinfo
8183 if test "x${with_makeinfo}" = "xno"; then
8184 HAVE_MAKEINFO=no
8185 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8186 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8187 source tree does not seem to have pre-built manuals in the \`info' directory.
8188 Either install a suitable version of makeinfo, or re-run configure
8189 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8194 INFO_EXT=.info
8195 INFO_OPTS=--no-split
8200 if test x$GCC = xyes; then
8201 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8202 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8203 else
8204 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8205 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8209 late_LDFLAGS=$LDFLAGS
8210 if test x$GCC = xyes; then
8211 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8212 else
8213 LDFLAGS="$LDFLAGS -znocombreloc"
8216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8217 $as_echo_n "checking for -znocombreloc... " >&6; }
8218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8219 /* end confdefs.h. */
8222 main ()
8226 return 0;
8228 _ACEOF
8229 if ac_fn_c_try_link "$LINENO"; then :
8230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8231 $as_echo "yes" >&6; }
8232 else
8233 LDFLAGS=$late_LDFLAGS
8234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8235 $as_echo "no" >&6; }
8237 rm -f core conftest.err conftest.$ac_objext \
8238 conftest$ac_exeext conftest.$ac_ext
8241 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8242 case "$opsys" in
8243 your-opsys-here) CANNOT_DUMP=yes ;;
8244 esac
8246 test "$CANNOT_DUMP" = "yes" && \
8248 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8254 UNEXEC_OBJ=unexelf.o
8255 case "$opsys" in
8256 # MSDOS uses unexcoff.o
8257 # MSWindows uses unexw32.o
8258 aix4-2)
8259 UNEXEC_OBJ=unexaix.o
8261 cygwin)
8262 UNEXEC_OBJ=unexcw.o
8264 darwin)
8265 UNEXEC_OBJ=unexmacosx.o
8267 hpux10-20 | hpux11)
8268 UNEXEC_OBJ=unexhp9k800.o
8270 sol2-10)
8271 # Use the Solaris dldump() function, called from unexsol.c, to dump
8272 # emacs, instead of the generic ELF dump code found in unexelf.c.
8273 # The resulting binary has a complete symbol table, and is better
8274 # for debugging and other observability tools (debuggers, pstack, etc).
8276 # If you encounter a problem using dldump(), please consider sending
8277 # a message to the OpenSolaris tools-linking mailing list:
8278 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8280 # It is likely that dldump() works with older Solaris too, but this has
8281 # not been tested, so for now this change is for Solaris 10 or newer.
8282 UNEXEC_OBJ=unexsol.o
8284 esac
8286 LD_SWITCH_SYSTEM=
8287 case "$opsys" in
8288 freebsd)
8289 ## Let `ld' find image libs and similar things in /usr/local/lib.
8290 ## The system compiler, GCC, has apparently been modified to not
8291 ## look there, contrary to what a stock GCC would do.
8292 ### It's not our place to do this. See bug#10313#17.
8293 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8297 gnu-linux)
8298 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8299 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8302 netbsd)
8303 ### It's not our place to do this. See bug#10313#17.
8304 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8308 openbsd)
8309 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8310 ## otherwise Emacs dumps core on elf systems.
8311 LD_SWITCH_SYSTEM="-Z"
8313 esac
8316 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8318 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8319 ## which has not been defined yet. When this was handled with cpp,
8320 ## it was expanded to null when configure sourced the s/*.h file.
8321 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8322 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8323 ## (or somesuch), but because it is supposed to go at the _front_
8324 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8325 ## Compare with the gnu-linux case below, which added to the end
8326 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8327 ## LD_SWITCH_SYSTEM_TEMACS.
8328 case "$opsys" in
8329 netbsd|openbsd)
8330 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8331 esac
8334 C_SWITCH_MACHINE=
8335 case $canonical in
8336 alpha*)
8337 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8338 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8342 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8343 ## With ELF, make sure that all common symbols get allocated to in the
8344 ## data section. Otherwise, the dump of temacs may miss variables in
8345 ## the shared library that have been initialized. For example, with
8346 ## GNU libc, __malloc_initialized would normally be resolved to the
8347 ## shared library's .bss section, which is fatal.
8348 if test "x$GCC" = "xyes"; then
8349 C_SWITCH_MACHINE="-fno-common"
8350 else
8351 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8353 else
8354 UNEXEC_OBJ=unexalpha.o
8357 esac
8362 C_SWITCH_SYSTEM=
8363 ## Some programs in src produce warnings saying certain subprograms
8364 ## are too complex and need a MAXMEM value greater than 2000 for
8365 ## additional optimization. --nils@exp-math.uni-essen.de
8366 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8367 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8368 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8369 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8373 LIBS_SYSTEM=
8374 case "$opsys" in
8375 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8376 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8378 freebsd) LIBS_SYSTEM="-lutil" ;;
8380 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8382 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8384 ## Motif needs -lgen.
8385 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8386 esac
8390 ### Make sure subsequent tests use flags consistent with the build flags.
8392 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8393 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8394 else
8395 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8398 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8400 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8404 LIB_MATH=-lm
8405 LIB_STANDARD=
8406 START_FILES=
8407 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8409 case $opsys in
8410 cygwin )
8411 LIB_MATH=
8412 START_FILES='pre-crt0.o'
8414 darwin )
8415 ## Adding -lm confuses the dynamic linker, so omit it.
8416 LIB_MATH=
8417 START_FILES='pre-crt0.o'
8419 freebsd )
8420 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8421 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8422 SYSTEM_TYPE=berkeley-unix
8424 gnu-linux | gnu-kfreebsd )
8425 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8426 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8428 hpux10-20 | hpux11 )
8429 LIB_STANDARD=-lc
8430 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8432 netbsd | openbsd )
8433 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8434 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8435 SYSTEM_TYPE=berkeley-unix
8438 sol2* | unixware )
8439 SYSTEM_TYPE=usg-unix-v
8442 esac
8447 cat >>confdefs.h <<_ACEOF
8448 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8449 _ACEOF
8452 crt_files=
8454 for file in x $LIB_STANDARD $START_FILES; do
8455 case "$file" in
8456 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8457 esac
8458 done
8460 if test "x$crt_files" != x; then
8462 ## If user specified a crt-dir, use that unconditionally.
8463 crt_gcc=no
8465 if test "X$CRT_DIR" = "X"; then
8467 CRT_DIR=/usr/lib # default
8469 case "$canonical" in
8470 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8471 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8472 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8473 ## For anything else (eg /usr/lib32), it is up the user to specify
8474 ## the location (bug#5655).
8475 ## Test for crtn.o, not just the directory, because sometimes the
8476 ## directory exists but does not have the relevant files (bug#1287).
8477 ## FIXME better to test for binary compatibility somehow.
8478 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8481 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8482 esac
8484 case "$opsys" in
8485 hpux10-20) CRT_DIR=/lib ;;
8486 esac
8488 test "x${GCC}" = xyes && crt_gcc=yes
8490 fi # CRT_DIR = ""
8492 crt_missing=
8494 for file in $crt_files; do
8496 ## If we're using gcc, try to determine it automatically by asking
8497 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8498 ## system-dependent default from above.]
8499 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8501 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8502 case "$crt_file" in
8503 */*)
8504 CRT_DIR=`$as_dirname -- "$crt_file" ||
8505 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8506 X"$crt_file" : 'X\(//\)[^/]' \| \
8507 X"$crt_file" : 'X\(//\)$' \| \
8508 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8509 $as_echo X"$crt_file" |
8510 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8511 s//\1/
8514 /^X\(\/\/\)[^/].*/{
8515 s//\1/
8518 /^X\(\/\/\)$/{
8519 s//\1/
8522 /^X\(\/\).*/{
8523 s//\1/
8526 s/.*/./; q'`
8528 esac
8531 crt_gcc=no
8533 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8534 done # $crt_files
8536 test "x$crt_missing" = x || \
8537 as_fn_error "Required file(s) not found:$crt_missing
8538 Try using the --with-crt-dir option." "$LINENO" 5
8540 fi # crt_files != ""
8544 case $opsys in
8545 netbsd | openbsd )
8546 if test -f $CRT_DIR/crti.o; then
8548 test -f $CRT_DIR/crtn.o || \
8549 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8551 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8552 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8555 esac
8558 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8559 pre_PKG_CONFIG_LIBS=$LIBS
8561 # Extract the first word of "pkg-config", so it can be a program name with args.
8562 set dummy pkg-config; ac_word=$2
8563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8564 $as_echo_n "checking for $ac_word... " >&6; }
8565 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8566 $as_echo_n "(cached) " >&6
8567 else
8568 case $PKG_CONFIG in
8569 [\\/]* | ?:[\\/]*)
8570 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8574 for as_dir in $PATH
8576 IFS=$as_save_IFS
8577 test -z "$as_dir" && as_dir=.
8578 for ac_exec_ext in '' $ac_executable_extensions; do
8579 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8580 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8581 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8582 break 2
8584 done
8585 done
8586 IFS=$as_save_IFS
8588 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8590 esac
8592 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8593 if test -n "$PKG_CONFIG"; then
8594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8595 $as_echo "$PKG_CONFIG" >&6; }
8596 else
8597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8598 $as_echo "no" >&6; }
8606 if test "${with_sound}" != "no"; then
8607 # Sound support for GNU/Linux and the free BSDs.
8608 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8609 do :
8610 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8611 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8612 eval as_val=\$$as_ac_Header
8613 if test "x$as_val" = x""yes; then :
8614 cat >>confdefs.h <<_ACEOF
8615 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8616 _ACEOF
8617 have_sound_header=yes
8620 done
8622 # Emulation library used on NetBSD.
8623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8624 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8625 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8626 $as_echo_n "(cached) " >&6
8627 else
8628 ac_check_lib_save_LIBS=$LIBS
8629 LIBS="-lossaudio $LIBS"
8630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8631 /* end confdefs.h. */
8633 /* Override any GCC internal prototype to avoid an error.
8634 Use char because int might match the return type of a GCC
8635 builtin and then its argument prototype would still apply. */
8636 #ifdef __cplusplus
8637 extern "C"
8638 #endif
8639 char _oss_ioctl ();
8641 main ()
8643 return _oss_ioctl ();
8645 return 0;
8647 _ACEOF
8648 if ac_fn_c_try_link "$LINENO"; then :
8649 ac_cv_lib_ossaudio__oss_ioctl=yes
8650 else
8651 ac_cv_lib_ossaudio__oss_ioctl=no
8653 rm -f core conftest.err conftest.$ac_objext \
8654 conftest$ac_exeext conftest.$ac_ext
8655 LIBS=$ac_check_lib_save_LIBS
8657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8658 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8659 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8660 LIBSOUND=-lossaudio
8661 else
8662 LIBSOUND=
8667 ALSA_REQUIRED=1.0.0
8668 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8670 succeeded=no
8672 if test "$PKG_CONFIG" = "no" ; then
8673 HAVE_ALSA=no
8674 else
8675 PKG_CONFIG_MIN_VERSION=0.9.0
8676 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8678 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8680 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
8681 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
8682 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
8683 edit_cflags="
8684 s,///*,/,g
8685 s/^/ /
8686 s/ -I/ $isystem/g
8687 s/^ //
8689 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8690 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8692 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8693 succeeded=yes
8694 else
8695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8696 $as_echo "no" >&6; }
8697 ALSA_CFLAGS=""
8698 ALSA_LIBS=""
8699 ## If we have a custom action on failure, don't print errors, but
8700 ## do set a variable so people can do so. Do it in a subshell
8701 ## to capture any diagnostics in invoking pkg-config.
8702 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
8708 else
8709 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8710 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8714 if test $succeeded = yes; then
8715 HAVE_ALSA=yes
8716 else
8717 HAVE_ALSA=no
8720 if test $HAVE_ALSA = yes; then
8721 SAVE_CFLAGS="$CFLAGS"
8722 SAVE_LIBS="$LIBS"
8723 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8724 LIBS="$ALSA_LIBS $LIBS"
8725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8726 /* end confdefs.h. */
8727 #include <asoundlib.h>
8729 main ()
8731 snd_lib_error_set_handler (0);
8733 return 0;
8735 _ACEOF
8736 if ac_fn_c_try_compile "$LINENO"; then :
8737 emacs_alsa_normal=yes
8738 else
8739 emacs_alsa_normal=no
8741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8742 if test "$emacs_alsa_normal" != yes; then
8743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8744 /* end confdefs.h. */
8745 #include <alsa/asoundlib.h>
8747 main ()
8749 snd_lib_error_set_handler (0);
8751 return 0;
8753 _ACEOF
8754 if ac_fn_c_try_compile "$LINENO"; then :
8755 emacs_alsa_subdir=yes
8756 else
8757 emacs_alsa_subdir=no
8759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8760 if test "$emacs_alsa_subdir" != yes; then
8761 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8763 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8766 CFLAGS="$SAVE_CFLAGS"
8767 LIBS="$SAVE_LIBS"
8768 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8769 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8771 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8775 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8776 case "$opsys" in
8777 gnu-linux|freebsd|netbsd)
8779 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8782 esac
8791 for ac_header in $ac_header_list
8792 do :
8793 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8794 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8796 eval as_val=\$$as_ac_Header
8797 if test "x$as_val" = x""yes; then :
8798 cat >>confdefs.h <<_ACEOF
8799 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8800 _ACEOF
8804 done
8828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8829 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8831 /* end confdefs.h. */
8832 #include <sys/personality.h>
8834 main ()
8836 personality (PER_LINUX32)
8838 return 0;
8840 _ACEOF
8841 if ac_fn_c_try_compile "$LINENO"; then :
8842 emacs_cv_personality_linux32=yes
8843 else
8844 emacs_cv_personality_linux32=no
8846 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8848 $as_echo "$emacs_cv_personality_linux32" >&6; }
8850 if test $emacs_cv_personality_linux32 = yes; then
8852 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8856 for ac_header in term.h
8857 do :
8858 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8859 if test "x$ac_cv_header_term_h" = x""yes; then :
8860 cat >>confdefs.h <<_ACEOF
8861 #define HAVE_TERM_H 1
8862 _ACEOF
8866 done
8868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8869 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8870 if test "${ac_cv_header_time+set}" = set; then :
8871 $as_echo_n "(cached) " >&6
8872 else
8873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8874 /* end confdefs.h. */
8875 #include <sys/types.h>
8876 #include <sys/time.h>
8877 #include <time.h>
8880 main ()
8882 if ((struct tm *) 0)
8883 return 0;
8885 return 0;
8887 _ACEOF
8888 if ac_fn_c_try_compile "$LINENO"; then :
8889 ac_cv_header_time=yes
8890 else
8891 ac_cv_header_time=no
8893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8896 $as_echo "$ac_cv_header_time" >&6; }
8897 if test $ac_cv_header_time = yes; then
8899 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8903 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
8906 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8907 ac_have_decl=1
8908 else
8909 ac_have_decl=0
8912 cat >>confdefs.h <<_ACEOF
8913 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8914 _ACEOF
8916 if test $ac_cv_have_decl_sys_siglist != yes; then
8917 # For Tru64, at least:
8918 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
8921 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8922 ac_have_decl=1
8923 else
8924 ac_have_decl=0
8927 cat >>confdefs.h <<_ACEOF
8928 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8929 _ACEOF
8931 if test $ac_cv_have_decl___sys_siglist = yes; then
8933 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8938 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8939 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8940 $as_echo_n "(cached) " >&6
8941 else
8942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8943 /* end confdefs.h. */
8944 #include <sys/types.h>
8945 #include <sys/wait.h>
8946 #ifndef WEXITSTATUS
8947 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8948 #endif
8949 #ifndef WIFEXITED
8950 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8951 #endif
8954 main ()
8956 int s;
8957 wait (&s);
8958 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8960 return 0;
8962 _ACEOF
8963 if ac_fn_c_try_compile "$LINENO"; then :
8964 ac_cv_header_sys_wait_h=yes
8965 else
8966 ac_cv_header_sys_wait_h=no
8968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8971 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8972 if test $ac_cv_header_sys_wait_h = yes; then
8974 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8980 $as_echo_n "checking for speed_t... " >&6; }
8981 if test "${emacs_cv_speed_t+set}" = set; then :
8982 $as_echo_n "(cached) " >&6
8983 else
8984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8985 /* end confdefs.h. */
8986 #include <termios.h>
8988 main ()
8990 speed_t x = 1;
8992 return 0;
8994 _ACEOF
8995 if ac_fn_c_try_compile "$LINENO"; then :
8996 emacs_cv_speed_t=yes
8997 else
8998 emacs_cv_speed_t=no
9000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
9003 $as_echo "$emacs_cv_speed_t" >&6; }
9004 if test $emacs_cv_speed_t = yes; then
9006 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
9013 for ac_header in net/if.h
9014 do :
9015 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9016 #if HAVE_SYS_SOCKET_H
9017 #include <sys/socket.h>
9018 #endif
9020 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9021 cat >>confdefs.h <<_ACEOF
9022 #define HAVE_NET_IF_H 1
9023 _ACEOF
9027 done
9029 for ac_header in ifaddrs.h
9030 do :
9031 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9032 #if HAVE_SYS_SOCKET_H
9033 #include <sys/socket.h>
9034 #endif
9036 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9037 cat >>confdefs.h <<_ACEOF
9038 #define HAVE_IFADDRS_H 1
9039 _ACEOF
9043 done
9045 for ac_header in net/if_dl.h
9046 do :
9047 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9048 #if HAVE_SYS_SOCKET_H
9049 #include <sys/socket.h>
9050 #endif
9052 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9053 cat >>confdefs.h <<_ACEOF
9054 #define HAVE_NET_IF_DL_H 1
9055 _ACEOF
9059 done
9062 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9063 #if HAVE_SYS_SOCKET_H
9064 #include <sys/socket.h>
9065 #endif
9066 #if HAVE_NET_IF_H
9067 #include <net/if.h>
9068 #endif
9070 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9072 cat >>confdefs.h <<_ACEOF
9073 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9074 _ACEOF
9078 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9079 #if HAVE_SYS_SOCKET_H
9080 #include <sys/socket.h>
9081 #endif
9082 #if HAVE_NET_IF_H
9083 #include <net/if.h>
9084 #endif
9086 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9088 cat >>confdefs.h <<_ACEOF
9089 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9090 _ACEOF
9094 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9095 #if HAVE_SYS_SOCKET_H
9096 #include <sys/socket.h>
9097 #endif
9098 #if HAVE_NET_IF_H
9099 #include <net/if.h>
9100 #endif
9102 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9104 cat >>confdefs.h <<_ACEOF
9105 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9106 _ACEOF
9110 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9111 #if HAVE_SYS_SOCKET_H
9112 #include <sys/socket.h>
9113 #endif
9114 #if HAVE_NET_IF_H
9115 #include <net/if.h>
9116 #endif
9118 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9120 cat >>confdefs.h <<_ACEOF
9121 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9122 _ACEOF
9126 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9127 #if HAVE_SYS_SOCKET_H
9128 #include <sys/socket.h>
9129 #endif
9130 #if HAVE_NET_IF_H
9131 #include <net/if.h>
9132 #endif
9134 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9136 cat >>confdefs.h <<_ACEOF
9137 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9138 _ACEOF
9142 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9143 #if HAVE_SYS_SOCKET_H
9144 #include <sys/socket.h>
9145 #endif
9146 #if HAVE_NET_IF_H
9147 #include <net/if.h>
9148 #endif
9150 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9152 cat >>confdefs.h <<_ACEOF
9153 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9154 _ACEOF
9162 DEPFLAGS=
9163 MKDEPDIR=":"
9164 deps_frag=deps.mk
9165 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9167 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9168 HAVE_GNU_MAKE=no
9169 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9170 if test "x$testval" != x; then
9171 HAVE_GNU_MAKE=yes
9172 else
9173 ac_enable_autodepend=no
9175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9176 $as_echo "$HAVE_GNU_MAKE" >&6; }
9177 if test $HAVE_GNU_MAKE = yes; then
9178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9179 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9180 SAVE_CFLAGS="$CFLAGS"
9181 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9183 /* end confdefs.h. */
9186 main ()
9190 return 0;
9192 _ACEOF
9193 if ac_fn_c_try_compile "$LINENO"; then :
9195 else
9196 ac_enable_autodepend=no
9198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9199 CFLAGS="$SAVE_CFLAGS"
9200 test -f deps.d || ac_enable_autodepend=no
9201 rm -rf deps.d
9202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9203 $as_echo "$ac_enable_autodepend" >&6; }
9205 if test $ac_enable_autodepend = yes; then
9206 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9207 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9208 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9209 deps_frag=autodeps.mk
9212 deps_frag=$srcdir/src/$deps_frag
9218 lisp_frag=$srcdir/src/lisp.mk
9222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9223 $as_echo_n "checking for long file names... " >&6; }
9224 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9225 $as_echo_n "(cached) " >&6
9226 else
9227 ac_cv_sys_long_file_names=yes
9228 # Test for long file names in all the places we know might matter:
9229 # . the current directory, where building will happen
9230 # $prefix/lib where we will be installing things
9231 # $exec_prefix/lib likewise
9232 # $TMPDIR if set, where it might want to write temporary files
9233 # /tmp where it might want to write temporary files
9234 # /var/tmp likewise
9235 # /usr/tmp likewise
9236 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9237 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9238 # in the usual case where exec_prefix is '${prefix}'.
9239 case $ac_dir in #(
9240 . | /* | ?:[\\/]*) ;; #(
9241 *) continue;;
9242 esac
9243 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9244 ac_xdir=$ac_dir/cf$$
9245 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9246 ac_tf1=$ac_xdir/conftest9012345
9247 ac_tf2=$ac_xdir/conftest9012346
9248 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9249 ac_cv_sys_long_file_names=no
9250 rm -f -r "$ac_xdir" 2>/dev/null
9251 test $ac_cv_sys_long_file_names = no && break
9252 done
9254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9255 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9256 if test $ac_cv_sys_long_file_names = yes; then
9258 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9263 #### Choose a window system.
9265 ## We leave window_system equal to none if
9266 ## we end up building without one. Any new window system should
9267 ## set window_system to an appropriate value and add objects to
9268 ## window-system-specific substs.
9270 window_system=none
9271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9272 $as_echo_n "checking for X... " >&6; }
9275 # Check whether --with-x was given.
9276 if test "${with_x+set}" = set; then :
9277 withval=$with_x;
9280 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9281 if test "x$with_x" = xno; then
9282 # The user explicitly disabled X.
9283 have_x=disabled
9284 else
9285 case $x_includes,$x_libraries in #(
9286 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9287 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9288 $as_echo_n "(cached) " >&6
9289 else
9290 # One or both of the vars are not set, and there is no cached value.
9291 ac_x_includes=no ac_x_libraries=no
9292 rm -f -r conftest.dir
9293 if mkdir conftest.dir; then
9294 cd conftest.dir
9295 cat >Imakefile <<'_ACEOF'
9296 incroot:
9297 @echo incroot='${INCROOT}'
9298 usrlibdir:
9299 @echo usrlibdir='${USRLIBDIR}'
9300 libdir:
9301 @echo libdir='${LIBDIR}'
9302 _ACEOF
9303 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9304 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9305 for ac_var in incroot usrlibdir libdir; do
9306 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9307 done
9308 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9309 for ac_extension in a so sl dylib la dll; do
9310 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9311 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9312 ac_im_usrlibdir=$ac_im_libdir; break
9314 done
9315 # Screen out bogus values from the imake configuration. They are
9316 # bogus both because they are the default anyway, and because
9317 # using them would break gcc on systems where it needs fixed includes.
9318 case $ac_im_incroot in
9319 /usr/include) ac_x_includes= ;;
9320 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9321 esac
9322 case $ac_im_usrlibdir in
9323 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9324 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9325 esac
9327 cd ..
9328 rm -f -r conftest.dir
9331 # Standard set of common directories for X headers.
9332 # Check X11 before X11Rn because it is often a symlink to the current release.
9333 ac_x_header_dirs='
9334 /usr/X11/include
9335 /usr/X11R7/include
9336 /usr/X11R6/include
9337 /usr/X11R5/include
9338 /usr/X11R4/include
9340 /usr/include/X11
9341 /usr/include/X11R7
9342 /usr/include/X11R6
9343 /usr/include/X11R5
9344 /usr/include/X11R4
9346 /usr/local/X11/include
9347 /usr/local/X11R7/include
9348 /usr/local/X11R6/include
9349 /usr/local/X11R5/include
9350 /usr/local/X11R4/include
9352 /usr/local/include/X11
9353 /usr/local/include/X11R7
9354 /usr/local/include/X11R6
9355 /usr/local/include/X11R5
9356 /usr/local/include/X11R4
9358 /usr/X386/include
9359 /usr/x386/include
9360 /usr/XFree86/include/X11
9362 /usr/include
9363 /usr/local/include
9364 /usr/unsupported/include
9365 /usr/athena/include
9366 /usr/local/x11r5/include
9367 /usr/lpp/Xamples/include
9369 /usr/openwin/include
9370 /usr/openwin/share/include'
9372 if test "$ac_x_includes" = no; then
9373 # Guess where to find include files, by looking for Xlib.h.
9374 # First, try using that file with no special directory specified.
9375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9376 /* end confdefs.h. */
9377 #include <X11/Xlib.h>
9378 _ACEOF
9379 if ac_fn_c_try_cpp "$LINENO"; then :
9380 # We can compile using X headers with no special include directory.
9381 ac_x_includes=
9382 else
9383 for ac_dir in $ac_x_header_dirs; do
9384 if test -r "$ac_dir/X11/Xlib.h"; then
9385 ac_x_includes=$ac_dir
9386 break
9388 done
9390 rm -f conftest.err conftest.$ac_ext
9391 fi # $ac_x_includes = no
9393 if test "$ac_x_libraries" = no; then
9394 # Check for the libraries.
9395 # See if we find them without any special options.
9396 # Don't add to $LIBS permanently.
9397 ac_save_LIBS=$LIBS
9398 LIBS="-lX11 $LIBS"
9399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9400 /* end confdefs.h. */
9401 #include <X11/Xlib.h>
9403 main ()
9405 XrmInitialize ()
9407 return 0;
9409 _ACEOF
9410 if ac_fn_c_try_link "$LINENO"; then :
9411 LIBS=$ac_save_LIBS
9412 # We can link X programs with no special library path.
9413 ac_x_libraries=
9414 else
9415 LIBS=$ac_save_LIBS
9416 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9418 # Don't even attempt the hair of trying to link an X program!
9419 for ac_extension in a so sl dylib la dll; do
9420 if test -r "$ac_dir/libX11.$ac_extension"; then
9421 ac_x_libraries=$ac_dir
9422 break 2
9424 done
9425 done
9427 rm -f core conftest.err conftest.$ac_objext \
9428 conftest$ac_exeext conftest.$ac_ext
9429 fi # $ac_x_libraries = no
9431 case $ac_x_includes,$ac_x_libraries in #(
9432 no,* | *,no | *\'*)
9433 # Didn't find X, or a directory has "'" in its name.
9434 ac_cv_have_x="have_x=no";; #(
9436 # Record where we found X for the cache.
9437 ac_cv_have_x="have_x=yes\
9438 ac_x_includes='$ac_x_includes'\
9439 ac_x_libraries='$ac_x_libraries'"
9440 esac
9442 ;; #(
9443 *) have_x=yes;;
9444 esac
9445 eval "$ac_cv_have_x"
9446 fi # $with_x != no
9448 if test "$have_x" != yes; then
9449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9450 $as_echo "$have_x" >&6; }
9451 no_x=yes
9452 else
9453 # If each of the values was on the command line, it overrides each guess.
9454 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9455 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9456 # Update the cache value to reflect the command line values.
9457 ac_cv_have_x="have_x=yes\
9458 ac_x_includes='$x_includes'\
9459 ac_x_libraries='$x_libraries'"
9460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9461 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9464 if test "$no_x" != yes; then
9465 window_system=x11
9468 LD_SWITCH_X_SITE_RPATH=
9469 if test "${x_libraries}" != NONE; then
9470 if test -n "${x_libraries}"; then
9471 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9472 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9474 x_default_search_path=""
9475 x_search_path=${x_libraries}
9476 if test -z "${x_search_path}"; then
9477 x_search_path=/usr/lib
9479 for x_library in `echo ${x_search_path}: | \
9480 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9481 x_search_path="\
9482 ${x_library}/X11/%L/%T/%N%C%S:\
9483 ${x_library}/X11/%l/%T/%N%C%S:\
9484 ${x_library}/X11/%T/%N%C%S:\
9485 ${x_library}/X11/%L/%T/%N%S:\
9486 ${x_library}/X11/%l/%T/%N%S:\
9487 ${x_library}/X11/%T/%N%S"
9488 if test x"${x_default_search_path}" = x; then
9489 x_default_search_path=${x_search_path}
9490 else
9491 x_default_search_path="${x_search_path}:${x_default_search_path}"
9493 done
9497 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9498 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9501 if test x"${x_includes}" = x; then
9502 bitmapdir=/usr/include/X11/bitmaps
9503 else
9504 # accumulate include directories that have X11 bitmap subdirectories
9505 bmd_acc="dummyval"
9506 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9507 if test -d "${bmd}/X11/bitmaps"; then
9508 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9510 if test -d "${bmd}/bitmaps"; then
9511 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9513 done
9514 if test ${bmd_acc} != "dummyval"; then
9515 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9519 HAVE_NS=no
9520 NS_IMPL_COCOA=no
9521 NS_IMPL_GNUSTEP=no
9522 tmp_CPPFLAGS="$CPPFLAGS"
9523 tmp_CFLAGS="$CFLAGS"
9524 CPPFLAGS="$CPPFLAGS -x objective-c"
9525 CFLAGS="$CFLAGS -x objective-c"
9526 GNU_OBJC_CFLAGS=
9527 LIBS_GNUSTEP=
9528 if test "${with_ns}" != no; then
9529 if test "${opsys}" = darwin; then
9530 NS_IMPL_COCOA=yes
9531 ns_appdir=`pwd`/nextstep/Emacs.app
9532 ns_appbindir=${ns_appdir}/Contents/MacOS
9533 ns_appresdir=${ns_appdir}/Contents/Resources
9534 ns_appsrc=Cocoa/Emacs.base
9535 elif test -f $GNUSTEP_CONFIG_FILE; then
9536 NS_IMPL_GNUSTEP=yes
9537 ns_appdir=`pwd`/nextstep/Emacs.app
9538 ns_appbindir=${ns_appdir}
9539 ns_appresdir=${ns_appdir}/Resources
9540 ns_appsrc=GNUstep/Emacs.base
9541 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9542 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9543 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9544 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9545 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9546 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9547 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9548 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9549 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9550 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9551 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9552 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
9553 LIB_STANDARD=
9554 START_FILES=
9555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9556 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9557 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9558 $as_echo_n "(cached) " >&6
9559 else
9560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9561 /* end confdefs.h. */
9562 #include <GNUstepBase/GSConfig.h>
9564 main ()
9566 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9568 #else
9569 fail;
9570 #endif
9572 return 0;
9574 _ACEOF
9575 if ac_fn_c_try_compile "$LINENO"; then :
9576 emacs_cv_objc_exceptions=yes
9577 else
9578 emacs_cv_objc_exceptions=no
9580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9583 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9584 if test $emacs_cv_objc_exceptions = yes; then
9586 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9588 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9592 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9594 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9595 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9596 HAVE_NS=yes
9597 else
9598 as_fn_error "\`--with-ns' was specified, but the include
9599 files are missing or cannot be compiled." "$LINENO" 5
9604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9605 /* end confdefs.h. */
9606 #include <AppKit/AppKit.h>
9608 main ()
9611 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9612 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
9613 ; /* OK */
9614 #else
9615 #error "OSX 10.4 or newer required"
9616 #endif
9617 #endif
9620 return 0;
9622 _ACEOF
9623 if ac_fn_c_try_compile "$LINENO"; then :
9624 ns_osx_have_104=yes
9625 else
9626 ns_osx_have_104=no
9628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9630 /* end confdefs.h. */
9631 #include <Foundation/NSObjCRuntime.h>
9633 main ()
9635 NSInteger i;
9637 return 0;
9639 _ACEOF
9640 if ac_fn_c_try_compile "$LINENO"; then :
9641 ns_have_nsinteger=yes
9642 else
9643 ns_have_nsinteger=no
9645 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9646 if test $ns_osx_have_104 = no; then
9647 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
9649 if test $ns_have_nsinteger = yes; then
9651 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9658 INSTALL_ARCH_INDEP_EXTRA=install-etc
9659 ns_self_contained=no
9660 NS_OBJ=
9661 NS_OBJC_OBJ=
9662 if test "${HAVE_NS}" = yes; then
9663 if test "$with_toolkit_scroll_bars" = "no"; then
9664 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9667 window_system=nextstep
9668 # set up packaging dirs
9669 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9670 ns_self_contained=yes
9671 prefix=${ns_appresdir}
9672 exec_prefix=${ns_appbindir}
9673 libexecdir="\${ns_appbindir}/libexec"
9674 archlibdir="\${ns_appbindir}/libexec"
9675 docdir="\${ns_appresdir}/etc"
9676 etcdir="\${ns_appresdir}/etc"
9677 infodir="\${ns_appresdir}/info"
9678 mandir="\${ns_appresdir}/man"
9679 lispdir="\${ns_appresdir}/lisp"
9680 leimdir="\${ns_appresdir}/leim"
9681 INSTALL_ARCH_INDEP_EXTRA=
9683 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9685 CFLAGS="$tmp_CFLAGS"
9686 CPPFLAGS="$tmp_CPPFLAGS"
9693 HAVE_W32=no
9694 W32_OBJ=
9695 W32_LIBS=
9696 W32_RES=
9697 W32_RES_LINK=
9698 if test "${with_w32}" != no; then
9699 if test "${opsys}" != "cygwin"; then
9700 as_fn_error "Using w32 with an autotools build is only supported for Cygwin." "$LINENO" 5
9702 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
9703 if test "x$ac_cv_header_windows_h" = x""yes; then :
9704 HAVE_W32=yes
9705 else
9706 as_fn_error "\`--with-w32' was specified, but windows.h
9707 cannot be found." "$LINENO" 5
9712 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
9714 if test -n "$ac_tool_prefix"; then
9715 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
9716 set dummy ${ac_tool_prefix}windres; ac_word=$2
9717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9718 $as_echo_n "checking for $ac_word... " >&6; }
9719 if test "${ac_cv_prog_WINDRES+set}" = set; then :
9720 $as_echo_n "(cached) " >&6
9721 else
9722 if test -n "$WINDRES"; then
9723 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
9724 else
9725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9726 for as_dir in $PATH
9728 IFS=$as_save_IFS
9729 test -z "$as_dir" && as_dir=.
9730 for ac_exec_ext in '' $ac_executable_extensions; do
9731 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9732 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
9733 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9734 break 2
9736 done
9737 done
9738 IFS=$as_save_IFS
9742 WINDRES=$ac_cv_prog_WINDRES
9743 if test -n "$WINDRES"; then
9744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
9745 $as_echo "$WINDRES" >&6; }
9746 else
9747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9748 $as_echo "no" >&6; }
9753 if test -z "$ac_cv_prog_WINDRES"; then
9754 ac_ct_WINDRES=$WINDRES
9755 # Extract the first word of "windres", so it can be a program name with args.
9756 set dummy windres; ac_word=$2
9757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9758 $as_echo_n "checking for $ac_word... " >&6; }
9759 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
9760 $as_echo_n "(cached) " >&6
9761 else
9762 if test -n "$ac_ct_WINDRES"; then
9763 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
9764 else
9765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9766 for as_dir in $PATH
9768 IFS=$as_save_IFS
9769 test -z "$as_dir" && as_dir=.
9770 for ac_exec_ext in '' $ac_executable_extensions; do
9771 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9772 ac_cv_prog_ac_ct_WINDRES="windres"
9773 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9774 break 2
9776 done
9777 done
9778 IFS=$as_save_IFS
9782 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
9783 if test -n "$ac_ct_WINDRES"; then
9784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
9785 $as_echo "$ac_ct_WINDRES" >&6; }
9786 else
9787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9788 $as_echo "no" >&6; }
9791 if test "x$ac_ct_WINDRES" = x; then
9792 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
9793 else
9794 case $cross_compiling:$ac_tool_warned in
9795 yes:)
9796 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9797 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9798 ac_tool_warned=yes ;;
9799 esac
9800 WINDRES=$ac_ct_WINDRES
9802 else
9803 WINDRES="$ac_cv_prog_WINDRES"
9806 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
9807 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
9808 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
9809 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
9810 W32_RES="emacs.res"
9811 # Tell the linker that emacs.res is an object (which we compile from
9812 # the rc file), not a linker script.
9813 W32_RES_LINK="-Wl,-bpe-i386 -Wl,emacs.res"
9820 if test "${HAVE_W32}" = "yes"; then
9821 window_system=w32
9822 with_xft=no
9825 ## $window_system is now set to the window system we will
9826 ## ultimately use.
9828 term_header=
9829 HAVE_X_WINDOWS=no
9830 HAVE_X11=no
9831 USE_X_TOOLKIT=none
9833 case "${window_system}" in
9834 x11 )
9835 HAVE_X_WINDOWS=yes
9836 HAVE_X11=yes
9837 term_header=xterm.h
9838 case "${with_x_toolkit}" in
9839 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9840 motif ) USE_X_TOOLKIT=MOTIF ;;
9841 gtk ) with_gtk=yes
9842 term_header=gtkutil.h
9843 USE_X_TOOLKIT=none ;;
9844 gtk2 ) with_gtk2=yes
9845 term_header=gtkutil.h
9846 USE_X_TOOLKIT=none ;;
9847 gtk3 ) with_gtk3=yes
9848 term_header=gtkutil.h
9849 USE_X_TOOLKIT=none ;;
9850 no ) USE_X_TOOLKIT=none ;;
9851 * ) USE_X_TOOLKIT=maybe ;;
9852 esac
9854 nextstep )
9855 term_header=nsterm.h
9857 w32 )
9858 term_header=w32term.h
9860 esac
9862 if test -n "${term_header}"; then
9864 cat >>confdefs.h <<_ACEOF
9865 #define TERM_HEADER "${term_header}"
9866 _ACEOF
9870 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9871 # Extract the first word of "X", so it can be a program name with args.
9872 set dummy X; ac_word=$2
9873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9874 $as_echo_n "checking for $ac_word... " >&6; }
9875 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9876 $as_echo_n "(cached) " >&6
9877 else
9878 if test -n "$HAVE_XSERVER"; then
9879 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9880 else
9881 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9882 for as_dir in $PATH
9884 IFS=$as_save_IFS
9885 test -z "$as_dir" && as_dir=.
9886 for ac_exec_ext in '' $ac_executable_extensions; do
9887 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9888 ac_cv_prog_HAVE_XSERVER="true"
9889 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9890 break 2
9892 done
9893 done
9894 IFS=$as_save_IFS
9896 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9899 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9900 if test -n "$HAVE_XSERVER"; then
9901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9902 $as_echo "$HAVE_XSERVER" >&6; }
9903 else
9904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9905 $as_echo "no" >&6; }
9909 if test "$HAVE_XSERVER" = true ||
9910 test -n "$DISPLAY" ||
9911 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9912 as_fn_error "You seem to be running X, but no X development libraries
9913 were found. You should install the relevant development files for X
9914 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9915 sure you have development files for image handling, i.e.
9916 tiff, gif, jpeg, png and xpm.
9917 If you are sure you want Emacs compiled without X window support, pass
9918 --without-x
9919 to configure." "$LINENO" 5
9923 ### If we're using X11, we should use the X menu package.
9924 HAVE_MENUS=no
9925 case ${HAVE_X11} in
9926 yes ) HAVE_MENUS=yes ;;
9927 esac
9929 # Does the opsystem file prohibit the use of the GNU malloc?
9930 # Assume not, until told otherwise.
9931 GNU_MALLOC=yes
9933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9934 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9935 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9936 $as_echo_n "(cached) " >&6
9937 else
9938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9939 /* end confdefs.h. */
9940 #include <malloc.h>
9941 static void hook (void) {}
9943 main ()
9945 malloc_set_state (malloc_get_state ());
9946 __after_morecore_hook = hook;
9947 __malloc_initialize_hook = hook;
9949 return 0;
9951 _ACEOF
9952 if ac_fn_c_try_link "$LINENO"; then :
9953 emacs_cv_var_doug_lea_malloc=yes
9954 else
9955 emacs_cv_var_doug_lea_malloc=no
9957 rm -f core conftest.err conftest.$ac_objext \
9958 conftest$ac_exeext conftest.$ac_ext
9960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9961 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9962 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9965 system_malloc=no
9966 case "$opsys" in
9967 ## darwin ld insists on the use of malloc routines in the System framework.
9968 darwin|sol2-10) system_malloc=yes ;;
9969 esac
9971 if test "${system_malloc}" = "yes"; then
9973 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9975 GNU_MALLOC=no
9976 GNU_MALLOC_reason="
9977 (The GNU allocators don't work with this system configuration.)"
9978 GMALLOC_OBJ=
9979 VMLIMIT_OBJ=
9980 else
9981 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9982 VMLIMIT_OBJ=vm-limit.o
9987 if test "$doug_lea_malloc" = "yes" ; then
9988 if test "$GNU_MALLOC" = yes ; then
9989 GNU_MALLOC_reason="
9990 (Using Doug Lea's new malloc from the GNU C Library.)"
9993 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9996 ## Use mmap directly for allocating larger buffers.
9997 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9998 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9999 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10000 case "$opsys" in
10001 gnu*) REL_ALLOC=no ;;
10002 esac
10005 if test x"${REL_ALLOC}" = x; then
10006 REL_ALLOC=${GNU_MALLOC}
10009 use_mmap_for_buffers=no
10010 case "$opsys" in
10011 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10012 esac
10021 for ac_func in getpagesize
10022 do :
10023 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10024 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10025 cat >>confdefs.h <<_ACEOF
10026 #define HAVE_GETPAGESIZE 1
10027 _ACEOF
10030 done
10032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10033 $as_echo_n "checking for working mmap... " >&6; }
10034 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10035 $as_echo_n "(cached) " >&6
10036 else
10037 if test "$cross_compiling" = yes; then :
10038 ac_cv_func_mmap_fixed_mapped=no
10039 else
10040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10041 /* end confdefs.h. */
10042 $ac_includes_default
10043 /* malloc might have been renamed as rpl_malloc. */
10044 #undef malloc
10046 /* Thanks to Mike Haertel and Jim Avera for this test.
10047 Here is a matrix of mmap possibilities:
10048 mmap private not fixed
10049 mmap private fixed at somewhere currently unmapped
10050 mmap private fixed at somewhere already mapped
10051 mmap shared not fixed
10052 mmap shared fixed at somewhere currently unmapped
10053 mmap shared fixed at somewhere already mapped
10054 For private mappings, we should verify that changes cannot be read()
10055 back from the file, nor mmap's back from the file at a different
10056 address. (There have been systems where private was not correctly
10057 implemented like the infamous i386 svr4.0, and systems where the
10058 VM page cache was not coherent with the file system buffer cache
10059 like early versions of FreeBSD and possibly contemporary NetBSD.)
10060 For shared mappings, we should conversely verify that changes get
10061 propagated back to all the places they're supposed to be.
10063 Grep wants private fixed already mapped.
10064 The main things grep needs to know about mmap are:
10065 * does it exist and is it safe to write into the mmap'd area
10066 * how to use it (BSD variants) */
10068 #include <fcntl.h>
10069 #include <sys/mman.h>
10071 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10072 char *malloc ();
10073 #endif
10075 /* This mess was copied from the GNU getpagesize.h. */
10076 #ifndef HAVE_GETPAGESIZE
10077 # ifdef _SC_PAGESIZE
10078 # define getpagesize() sysconf(_SC_PAGESIZE)
10079 # else /* no _SC_PAGESIZE */
10080 # ifdef HAVE_SYS_PARAM_H
10081 # include <sys/param.h>
10082 # ifdef EXEC_PAGESIZE
10083 # define getpagesize() EXEC_PAGESIZE
10084 # else /* no EXEC_PAGESIZE */
10085 # ifdef NBPG
10086 # define getpagesize() NBPG * CLSIZE
10087 # ifndef CLSIZE
10088 # define CLSIZE 1
10089 # endif /* no CLSIZE */
10090 # else /* no NBPG */
10091 # ifdef NBPC
10092 # define getpagesize() NBPC
10093 # else /* no NBPC */
10094 # ifdef PAGESIZE
10095 # define getpagesize() PAGESIZE
10096 # endif /* PAGESIZE */
10097 # endif /* no NBPC */
10098 # endif /* no NBPG */
10099 # endif /* no EXEC_PAGESIZE */
10100 # else /* no HAVE_SYS_PARAM_H */
10101 # define getpagesize() 8192 /* punt totally */
10102 # endif /* no HAVE_SYS_PARAM_H */
10103 # endif /* no _SC_PAGESIZE */
10105 #endif /* no HAVE_GETPAGESIZE */
10108 main ()
10110 char *data, *data2, *data3;
10111 const char *cdata2;
10112 int i, pagesize;
10113 int fd, fd2;
10115 pagesize = getpagesize ();
10117 /* First, make a file with some known garbage in it. */
10118 data = (char *) malloc (pagesize);
10119 if (!data)
10120 return 1;
10121 for (i = 0; i < pagesize; ++i)
10122 *(data + i) = rand ();
10123 umask (0);
10124 fd = creat ("conftest.mmap", 0600);
10125 if (fd < 0)
10126 return 2;
10127 if (write (fd, data, pagesize) != pagesize)
10128 return 3;
10129 close (fd);
10131 /* Next, check that the tail of a page is zero-filled. File must have
10132 non-zero length, otherwise we risk SIGBUS for entire page. */
10133 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10134 if (fd2 < 0)
10135 return 4;
10136 cdata2 = "";
10137 if (write (fd2, cdata2, 1) != 1)
10138 return 5;
10139 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10140 if (data2 == MAP_FAILED)
10141 return 6;
10142 for (i = 0; i < pagesize; ++i)
10143 if (*(data2 + i))
10144 return 7;
10145 close (fd2);
10146 if (munmap (data2, pagesize))
10147 return 8;
10149 /* Next, try to mmap the file at a fixed address which already has
10150 something else allocated at it. If we can, also make sure that
10151 we see the same garbage. */
10152 fd = open ("conftest.mmap", O_RDWR);
10153 if (fd < 0)
10154 return 9;
10155 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10156 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10157 return 10;
10158 for (i = 0; i < pagesize; ++i)
10159 if (*(data + i) != *(data2 + i))
10160 return 11;
10162 /* Finally, make sure that changes to the mapped area do not
10163 percolate back to the file as seen by read(). (This is a bug on
10164 some variants of i386 svr4.0.) */
10165 for (i = 0; i < pagesize; ++i)
10166 *(data2 + i) = *(data2 + i) + 1;
10167 data3 = (char *) malloc (pagesize);
10168 if (!data3)
10169 return 12;
10170 if (read (fd, data3, pagesize) != pagesize)
10171 return 13;
10172 for (i = 0; i < pagesize; ++i)
10173 if (*(data + i) != *(data3 + i))
10174 return 14;
10175 close (fd);
10176 return 0;
10178 _ACEOF
10179 if ac_fn_c_try_run "$LINENO"; then :
10180 ac_cv_func_mmap_fixed_mapped=yes
10181 else
10182 ac_cv_func_mmap_fixed_mapped=no
10184 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10185 conftest.$ac_objext conftest.beam conftest.$ac_ext
10189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10190 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10191 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10193 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10196 rm -f conftest.mmap conftest.txt
10198 if test $use_mmap_for_buffers = yes; then
10200 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10202 REL_ALLOC=no
10205 LIBS="$LIBS_SYSTEM $LIBS"
10207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10208 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10209 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10210 $as_echo_n "(cached) " >&6
10211 else
10212 ac_check_lib_save_LIBS=$LIBS
10213 LIBS="-ldnet $LIBS"
10214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10215 /* end confdefs.h. */
10217 /* Override any GCC internal prototype to avoid an error.
10218 Use char because int might match the return type of a GCC
10219 builtin and then its argument prototype would still apply. */
10220 #ifdef __cplusplus
10221 extern "C"
10222 #endif
10223 char dnet_ntoa ();
10225 main ()
10227 return dnet_ntoa ();
10229 return 0;
10231 _ACEOF
10232 if ac_fn_c_try_link "$LINENO"; then :
10233 ac_cv_lib_dnet_dnet_ntoa=yes
10234 else
10235 ac_cv_lib_dnet_dnet_ntoa=no
10237 rm -f core conftest.err conftest.$ac_objext \
10238 conftest$ac_exeext conftest.$ac_ext
10239 LIBS=$ac_check_lib_save_LIBS
10241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10242 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10243 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10244 cat >>confdefs.h <<_ACEOF
10245 #define HAVE_LIBDNET 1
10246 _ACEOF
10248 LIBS="-ldnet $LIBS"
10253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10254 $as_echo_n "checking for main in -lXbsd... " >&6; }
10255 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10256 $as_echo_n "(cached) " >&6
10257 else
10258 ac_check_lib_save_LIBS=$LIBS
10259 LIBS="-lXbsd $LIBS"
10260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10261 /* end confdefs.h. */
10265 main ()
10267 return main ();
10269 return 0;
10271 _ACEOF
10272 if ac_fn_c_try_link "$LINENO"; then :
10273 ac_cv_lib_Xbsd_main=yes
10274 else
10275 ac_cv_lib_Xbsd_main=no
10277 rm -f core conftest.err conftest.$ac_objext \
10278 conftest$ac_exeext conftest.$ac_ext
10279 LIBS=$ac_check_lib_save_LIBS
10281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10282 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10283 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10284 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10288 LIB_PTHREAD=
10292 if test "$ac_cv_header_pthread_h"; then
10293 if test "$GMALLOC_OBJ" = gmalloc.o; then
10294 emacs_pthread_function=pthread_atfork
10295 else
10296 emacs_pthread_function=pthread_self
10298 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10300 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10301 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10302 $as_echo_n "(cached) " >&6
10303 else
10304 ac_check_lib_save_LIBS=$LIBS
10305 LIBS="-lpthread $LIBS"
10306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10307 /* end confdefs.h. */
10309 /* Override any GCC internal prototype to avoid an error.
10310 Use char because int might match the return type of a GCC
10311 builtin and then its argument prototype would still apply. */
10312 #ifdef __cplusplus
10313 extern "C"
10314 #endif
10315 char $emacs_pthread_function ();
10317 main ()
10319 return $emacs_pthread_function ();
10321 return 0;
10323 _ACEOF
10324 if ac_fn_c_try_link "$LINENO"; then :
10325 eval "$as_ac_Lib=yes"
10326 else
10327 eval "$as_ac_Lib=no"
10329 rm -f core conftest.err conftest.$ac_objext \
10330 conftest$ac_exeext conftest.$ac_ext
10331 LIBS=$ac_check_lib_save_LIBS
10333 eval ac_res=\$$as_ac_Lib
10334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10335 $as_echo "$ac_res" >&6; }
10336 eval as_val=\$$as_ac_Lib
10337 if test "x$as_val" = x""yes; then :
10338 HAVE_PTHREAD=yes
10342 if test "$HAVE_PTHREAD" = yes; then
10343 case "${canonical}" in
10344 *-hpux*) ;;
10345 *) LIB_PTHREAD="-lpthread"
10346 LIBS="$LIB_PTHREAD $LIBS" ;;
10347 esac
10349 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10355 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10356 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10357 $as_echo_n "(cached) " >&6
10358 else
10359 ac_check_lib_save_LIBS=$LIBS
10360 LIBS="-lpthreads $LIBS"
10361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10362 /* end confdefs.h. */
10364 /* Override any GCC internal prototype to avoid an error.
10365 Use char because int might match the return type of a GCC
10366 builtin and then its argument prototype would still apply. */
10367 #ifdef __cplusplus
10368 extern "C"
10369 #endif
10370 char cma_open ();
10372 main ()
10374 return cma_open ();
10376 return 0;
10378 _ACEOF
10379 if ac_fn_c_try_link "$LINENO"; then :
10380 ac_cv_lib_pthreads_cma_open=yes
10381 else
10382 ac_cv_lib_pthreads_cma_open=no
10384 rm -f core conftest.err conftest.$ac_objext \
10385 conftest$ac_exeext conftest.$ac_ext
10386 LIBS=$ac_check_lib_save_LIBS
10388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10389 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10390 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10391 cat >>confdefs.h <<_ACEOF
10392 #define HAVE_LIBPTHREADS 1
10393 _ACEOF
10395 LIBS="-lpthreads $LIBS"
10400 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10401 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10402 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10403 ## added to LIBS in configure would never contain the pthreads part,
10404 ## but the value used in Makefiles might. FIXME?
10406 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10407 ## be harmless on older versions of X where it happens to exist.
10408 test "$opsys" = "aix4-2" && \
10409 test $ac_cv_lib_pthreads_cma_open = yes && \
10410 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10413 case ${host_os} in
10414 aix*)
10415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10416 $as_echo_n "checking for -bbigtoc option... " >&6; }
10417 if test "${gdb_cv_bigtoc+set}" = set; then :
10418 $as_echo_n "(cached) " >&6
10419 else
10421 case $GCC in
10422 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10423 *) gdb_cv_bigtoc=-bbigtoc ;;
10424 esac
10426 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10428 /* end confdefs.h. */
10431 main ()
10433 int i;
10435 return 0;
10437 _ACEOF
10438 if ac_fn_c_try_link "$LINENO"; then :
10440 else
10441 gdb_cv_bigtoc=
10443 rm -f core conftest.err conftest.$ac_objext \
10444 conftest$ac_exeext conftest.$ac_ext
10447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10448 $as_echo "$gdb_cv_bigtoc" >&6; }
10450 esac
10452 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10453 # used for the tests that follow. We set them back to REAL_CFLAGS and
10454 # REAL_CPPFLAGS later on.
10456 REAL_CFLAGS="$CFLAGS"
10457 REAL_CPPFLAGS="$CPPFLAGS"
10459 if test "${HAVE_X11}" = "yes"; then
10460 DEFS="$C_SWITCH_X_SITE $DEFS"
10461 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10462 LIBS="-lX11 $LIBS"
10463 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10464 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10466 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10467 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10468 # but it's more convenient here to set LD_RUN_PATH since this
10469 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10470 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10471 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10472 export LD_RUN_PATH
10475 if test "${opsys}" = "gnu-linux"; then
10476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10477 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10479 /* end confdefs.h. */
10482 main ()
10484 XOpenDisplay ("foo");
10486 return 0;
10488 _ACEOF
10489 if ac_fn_c_try_link "$LINENO"; then :
10490 xgnu_linux_first_failure=no
10491 else
10492 xgnu_linux_first_failure=yes
10494 rm -f core conftest.err conftest.$ac_objext \
10495 conftest$ac_exeext conftest.$ac_ext
10496 if test "${xgnu_linux_first_failure}" = "yes"; then
10497 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10498 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10499 OLD_CPPFLAGS="$CPPFLAGS"
10500 OLD_LIBS="$LIBS"
10501 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10502 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10503 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10504 LIBS="$LIBS -b i486-linuxaout"
10505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10506 /* end confdefs.h. */
10509 main ()
10511 XOpenDisplay ("foo");
10513 return 0;
10515 _ACEOF
10516 if ac_fn_c_try_link "$LINENO"; then :
10517 xgnu_linux_second_failure=no
10518 else
10519 xgnu_linux_second_failure=yes
10521 rm -f core conftest.err conftest.$ac_objext \
10522 conftest$ac_exeext conftest.$ac_ext
10523 if test "${xgnu_linux_second_failure}" = "yes"; then
10524 # If we get the same failure with -b, there is no use adding -b.
10525 # So take it out. This plays safe.
10526 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10527 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10528 CPPFLAGS="$OLD_CPPFLAGS"
10529 LIBS="$OLD_LIBS"
10530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10531 $as_echo "no" >&6; }
10532 else
10533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10534 $as_echo "yes" >&6; }
10536 else
10537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10538 $as_echo "no" >&6; }
10542 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10543 # header files included from there.
10544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10545 $as_echo_n "checking for Xkb... " >&6; }
10546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10547 /* end confdefs.h. */
10548 #include <X11/Xlib.h>
10549 #include <X11/XKBlib.h>
10551 main ()
10553 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10555 return 0;
10557 _ACEOF
10558 if ac_fn_c_try_link "$LINENO"; then :
10559 emacs_xkb=yes
10560 else
10561 emacs_xkb=no
10563 rm -f core conftest.err conftest.$ac_objext \
10564 conftest$ac_exeext conftest.$ac_ext
10565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10566 $as_echo "$emacs_xkb" >&6; }
10567 if test $emacs_xkb = yes; then
10569 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10573 for ac_func in XrmSetDatabase XScreenResourceString \
10574 XScreenNumberOfScreen
10575 do :
10576 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10577 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10578 eval as_val=\$$as_ac_var
10579 if test "x$as_val" = x""yes; then :
10580 cat >>confdefs.h <<_ACEOF
10581 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10582 _ACEOF
10585 done
10589 if test "${window_system}" = "x11"; then
10590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10591 $as_echo_n "checking X11 version 6... " >&6; }
10592 if test "${emacs_cv_x11_version_6+set}" = set; then :
10593 $as_echo_n "(cached) " >&6
10594 else
10595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10596 /* end confdefs.h. */
10597 #include <X11/Xlib.h>
10599 main ()
10601 #if XlibSpecificationRelease < 6
10602 fail;
10603 #endif
10606 return 0;
10608 _ACEOF
10609 if ac_fn_c_try_link "$LINENO"; then :
10610 emacs_cv_x11_version_6=yes
10611 else
10612 emacs_cv_x11_version_6=no
10614 rm -f core conftest.err conftest.$ac_objext \
10615 conftest$ac_exeext conftest.$ac_ext
10618 if test $emacs_cv_x11_version_6 = yes; then
10619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10620 $as_echo "6 or newer" >&6; }
10622 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10625 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10627 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10628 ## XIM support.
10629 case "$opsys" in
10630 sol2-*) : ;;
10632 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10635 esac
10636 else
10637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10638 $as_echo "before 6" >&6; }
10643 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10644 HAVE_RSVG=no
10645 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10646 if test "${with_rsvg}" != "no"; then
10647 RSVG_REQUIRED=2.11.0
10648 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10651 succeeded=no
10653 if test "$PKG_CONFIG" = "no" ; then
10655 else
10656 PKG_CONFIG_MIN_VERSION=0.9.0
10657 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10659 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10661 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
10662 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
10663 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
10664 edit_cflags="
10665 s,///*,/,g
10666 s/^/ /
10667 s/ -I/ $isystem/g
10668 s/^ //
10670 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10671 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10673 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10674 succeeded=yes
10675 else
10676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10677 $as_echo "no" >&6; }
10678 RSVG_CFLAGS=""
10679 RSVG_LIBS=""
10680 ## If we have a custom action on failure, don't print errors, but
10681 ## do set a variable so people can do so. Do it in a subshell
10682 ## to capture any diagnostics in invoking pkg-config.
10683 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
10689 else
10690 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10691 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10695 if test $succeeded = yes; then
10696 HAVE_RSVG=yes
10697 else
10704 if test $HAVE_RSVG = yes; then
10706 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10708 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10709 LIBS="$RSVG_LIBS $LIBS"
10714 HAVE_IMAGEMAGICK=no
10715 if test "${HAVE_X11}" = "yes"; then
10716 if test "${with_imagemagick}" != "no"; then
10717 ## 6.2.8 is the earliest version known to work, but earlier versions
10718 ## might work - let us know if you find one.
10719 ## 6.0.7 does not work. See bug#7955.
10720 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10722 succeeded=no
10724 if test "$PKG_CONFIG" = "no" ; then
10726 else
10727 PKG_CONFIG_MIN_VERSION=0.9.0
10728 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10730 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10732 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10733 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10734 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10735 edit_cflags="
10736 s,///*,/,g
10737 s/^/ /
10738 s/ -I/ $isystem/g
10739 s/^ //
10741 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10742 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10744 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10745 succeeded=yes
10746 else
10747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10748 $as_echo "no" >&6; }
10749 IMAGEMAGICK_CFLAGS=""
10750 IMAGEMAGICK_LIBS=""
10751 ## If we have a custom action on failure, don't print errors, but
10752 ## do set a variable so people can do so. Do it in a subshell
10753 ## to capture any diagnostics in invoking pkg-config.
10754 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
10760 else
10761 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10762 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10766 if test $succeeded = yes; then
10767 HAVE_IMAGEMAGICK=yes
10768 else
10775 if test $HAVE_IMAGEMAGICK = yes; then
10777 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10779 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10780 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10781 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10782 do :
10783 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10784 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10785 eval as_val=\$$as_ac_var
10786 if test "x$as_val" = x""yes; then :
10787 cat >>confdefs.h <<_ACEOF
10788 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10789 _ACEOF
10792 done
10799 HAVE_GTK=no
10800 GTK_OBJ=
10801 check_gtk2=no
10802 gtk3_pkg_errors=
10803 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10804 GLIB_REQUIRED=2.28
10805 GTK_REQUIRED=3.0
10806 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10809 succeeded=no
10811 if test "$PKG_CONFIG" = "no" ; then
10812 pkg_check_gtk=no
10813 else
10814 PKG_CONFIG_MIN_VERSION=0.9.0
10815 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10817 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10819 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
10820 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
10821 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
10822 edit_cflags="
10823 s,///*,/,g
10824 s/^/ /
10825 s/ -I/ $isystem/g
10826 s/^ //
10828 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10829 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10831 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10832 succeeded=yes
10833 else
10834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10835 $as_echo "no" >&6; }
10836 GTK_CFLAGS=""
10837 GTK_LIBS=""
10838 ## If we have a custom action on failure, don't print errors, but
10839 ## do set a variable so people can do so. Do it in a subshell
10840 ## to capture any diagnostics in invoking pkg-config.
10841 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
10847 else
10848 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10849 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10853 if test $succeeded = yes; then
10854 pkg_check_gtk=yes
10855 else
10856 pkg_check_gtk=no
10859 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
10860 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10862 if test "$pkg_check_gtk" = "yes"; then
10864 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10866 GTK_OBJ=emacsgtkfixed.o
10867 term_header=gtkutil.h
10868 USE_GTK_TOOLKIT="GTK3"
10869 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
10870 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
10872 else
10873 check_gtk2=yes
10874 gtk3_pkg_errors="$GTK_PKG_ERRORS "
10878 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
10879 GLIB_REQUIRED=2.10
10880 GTK_REQUIRED=2.10
10881 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10884 succeeded=no
10886 if test "$PKG_CONFIG" = "no" ; then
10887 pkg_check_gtk=no
10888 else
10889 PKG_CONFIG_MIN_VERSION=0.9.0
10890 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10892 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10894 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
10895 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
10896 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
10897 edit_cflags="
10898 s,///*,/,g
10899 s/^/ /
10900 s/ -I/ $isystem/g
10901 s/^ //
10903 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10904 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10906 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10907 succeeded=yes
10908 else
10909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10910 $as_echo "no" >&6; }
10911 GTK_CFLAGS=""
10912 GTK_LIBS=""
10913 ## If we have a custom action on failure, don't print errors, but
10914 ## do set a variable so people can do so. Do it in a subshell
10915 ## to capture any diagnostics in invoking pkg-config.
10916 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
10922 else
10923 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10924 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10928 if test $succeeded = yes; then
10929 pkg_check_gtk=yes
10930 else
10931 pkg_check_gtk=no
10934 if test "$pkg_check_gtk" = "no" &&
10935 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
10936 then
10937 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
10939 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
10942 if test x"$pkg_check_gtk" = xyes; then
10946 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10947 CFLAGS="$CFLAGS $GTK_CFLAGS"
10948 LIBS="$GTK_LIBS $LIBS"
10949 GTK_COMPILES=no
10950 for ac_func in gtk_main
10951 do :
10952 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10953 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10954 cat >>confdefs.h <<_ACEOF
10955 #define HAVE_GTK_MAIN 1
10956 _ACEOF
10957 GTK_COMPILES=yes
10959 done
10961 if test "${GTK_COMPILES}" != "yes"; then
10962 if test "$USE_X_TOOLKIT" != "maybe"; then
10963 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10965 else
10966 HAVE_GTK=yes
10968 $as_echo "#define USE_GTK 1" >>confdefs.h
10970 GTK_OBJ="gtkutil.o $GTK_OBJ"
10971 USE_X_TOOLKIT=none
10972 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
10974 else
10975 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10976 closing open displays. This is no problem if you just use
10977 one display, but if you use more than one and close one of them
10978 Emacs may crash." >&5
10979 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10980 closing open displays. This is no problem if you just use
10981 one display, but if you use more than one and close one of them
10982 Emacs may crash." >&2;}
10983 sleep 3
10991 if test "${HAVE_GTK}" = "yes"; then
10993 if test "$with_toolkit_scroll_bars" != no; then
10994 with_toolkit_scroll_bars=yes
10997 HAVE_GTK_FILE_SELECTION=no
10998 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10999 #include <gtk/gtk.h>
11001 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11002 HAVE_GTK_FILE_SELECTION=yes
11003 else
11004 HAVE_GTK_FILE_SELECTION=no
11007 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11008 for ac_func in gtk_file_selection_new
11009 do :
11010 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11011 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11012 cat >>confdefs.h <<_ACEOF
11013 #define HAVE_GTK_FILE_SELECTION_NEW 1
11014 _ACEOF
11017 done
11021 HAVE_GTK_HANDLE_BOX=no
11022 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11023 #include <gtk/gtk.h>
11025 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11026 HAVE_GTK_HANDLE_BOX=yes
11027 else
11028 HAVE_GTK_HANDLE_BOX=no
11031 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11032 for ac_func in gtk_handle_box_new
11033 do :
11034 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11035 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11036 cat >>confdefs.h <<_ACEOF
11037 #define HAVE_GTK_HANDLE_BOX_NEW 1
11038 _ACEOF
11041 done
11045 HAVE_GTK_TEAROFF_MENU_ITEM=no
11046 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11047 #include <gtk/gtk.h>
11049 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11050 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11051 else
11052 HAVE_GTK_TEAROFF_MENU_ITEM=no
11055 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11056 for ac_func in gtk_tearoff_menu_item_new
11057 do :
11058 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11059 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11060 cat >>confdefs.h <<_ACEOF
11061 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11062 _ACEOF
11065 done
11069 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11070 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11071 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11072 gtk_orientable_set_orientation \
11073 gtk_window_set_has_resize_grip
11074 do :
11075 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11076 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11077 eval as_val=\$$as_ac_var
11078 if test "x$as_val" = x""yes; then :
11079 cat >>confdefs.h <<_ACEOF
11080 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11081 _ACEOF
11084 done
11087 term_header=gtkutil.h
11090 HAVE_DBUS=no
11091 DBUS_OBJ=
11092 if test "${with_dbus}" = "yes"; then
11094 succeeded=no
11096 if test "$PKG_CONFIG" = "no" ; then
11097 HAVE_DBUS=no
11098 else
11099 PKG_CONFIG_MIN_VERSION=0.9.0
11100 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11102 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11104 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11105 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11106 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11107 edit_cflags="
11108 s,///*,/,g
11109 s/^/ /
11110 s/ -I/ $isystem/g
11111 s/^ //
11113 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11114 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11116 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11117 succeeded=yes
11118 else
11119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11120 $as_echo "no" >&6; }
11121 DBUS_CFLAGS=""
11122 DBUS_LIBS=""
11123 ## If we have a custom action on failure, don't print errors, but
11124 ## do set a variable so people can do so. Do it in a subshell
11125 ## to capture any diagnostics in invoking pkg-config.
11126 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11132 else
11133 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11134 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11138 if test $succeeded = yes; then
11139 HAVE_DBUS=yes
11140 else
11141 HAVE_DBUS=no
11144 if test "$HAVE_DBUS" = yes; then
11145 LIBS="$LIBS $DBUS_LIBS"
11147 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11149 for ac_func in dbus_watch_get_unix_fd \
11150 dbus_type_is_valid \
11151 dbus_validate_bus_name \
11152 dbus_validate_path \
11153 dbus_validate_interface \
11154 dbus_validate_member
11155 do :
11156 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11157 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11158 eval as_val=\$$as_ac_var
11159 if test "x$as_val" = x""yes; then :
11160 cat >>confdefs.h <<_ACEOF
11161 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11162 _ACEOF
11165 done
11167 DBUS_OBJ=dbusbind.o
11172 HAVE_GSETTINGS=no
11173 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11175 succeeded=no
11177 if test "$PKG_CONFIG" = "no" ; then
11178 HAVE_GSETTINGS=no
11179 else
11180 PKG_CONFIG_MIN_VERSION=0.9.0
11181 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11183 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11185 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11186 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11187 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11188 edit_cflags="
11189 s,///*,/,g
11190 s/^/ /
11191 s/ -I/ $isystem/g
11192 s/^ //
11194 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11195 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11197 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11198 succeeded=yes
11199 else
11200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11201 $as_echo "no" >&6; }
11202 GSETTINGS_CFLAGS=""
11203 GSETTINGS_LIBS=""
11204 ## If we have a custom action on failure, don't print errors, but
11205 ## do set a variable so people can do so. Do it in a subshell
11206 ## to capture any diagnostics in invoking pkg-config.
11207 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11213 else
11214 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11215 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11219 if test $succeeded = yes; then
11220 HAVE_GSETTINGS=yes
11221 else
11222 HAVE_GSETTINGS=no
11225 if test "$HAVE_GSETTINGS" = "yes"; then
11227 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11229 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11230 SETTINGS_LIBS="$GSETTINGS_LIBS"
11234 HAVE_GCONF=no
11235 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11237 succeeded=no
11239 if test "$PKG_CONFIG" = "no" ; then
11240 HAVE_GCONF=no
11241 else
11242 PKG_CONFIG_MIN_VERSION=0.9.0
11243 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11245 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11247 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
11248 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11249 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
11250 edit_cflags="
11251 s,///*,/,g
11252 s/^/ /
11253 s/ -I/ $isystem/g
11254 s/^ //
11256 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11257 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11259 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11260 succeeded=yes
11261 else
11262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11263 $as_echo "no" >&6; }
11264 GCONF_CFLAGS=""
11265 GCONF_LIBS=""
11266 ## If we have a custom action on failure, don't print errors, but
11267 ## do set a variable so people can do so. Do it in a subshell
11268 ## to capture any diagnostics in invoking pkg-config.
11269 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
11275 else
11276 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11277 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11281 if test $succeeded = yes; then
11282 HAVE_GCONF=yes
11283 else
11284 HAVE_GCONF=no
11287 if test "$HAVE_GCONF" = yes; then
11289 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11291 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11292 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11296 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11298 succeeded=no
11300 if test "$PKG_CONFIG" = "no" ; then
11301 HAVE_GOBJECT=no
11302 else
11303 PKG_CONFIG_MIN_VERSION=0.9.0
11304 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11306 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11308 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
11309 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11310 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
11311 edit_cflags="
11312 s,///*,/,g
11313 s/^/ /
11314 s/ -I/ $isystem/g
11315 s/^ //
11317 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11318 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11320 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11321 succeeded=yes
11322 else
11323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11324 $as_echo "no" >&6; }
11325 GOBJECT_CFLAGS=""
11326 GOBJECT_LIBS=""
11327 ## If we have a custom action on failure, don't print errors, but
11328 ## do set a variable so people can do so. Do it in a subshell
11329 ## to capture any diagnostics in invoking pkg-config.
11330 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
11336 else
11337 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11338 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11342 if test $succeeded = yes; then
11343 HAVE_GOBJECT=yes
11344 else
11345 HAVE_GOBJECT=no
11348 if test "$HAVE_GOBJECT" = "yes"; then
11349 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11350 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11352 SAVE_CFLAGS="$CFLAGS"
11353 SAVE_LIBS="$LIBS"
11354 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11355 LIBS="$SETTINGS_LIBS $LIBS"
11356 for ac_func in g_type_init
11357 do :
11358 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11359 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11360 cat >>confdefs.h <<_ACEOF
11361 #define HAVE_G_TYPE_INIT 1
11362 _ACEOF
11365 done
11367 CFLAGS="$SAVE_CFLAGS"
11368 LIBS="$SAVE_LIBS"
11374 HAVE_LIBSELINUX=no
11375 LIBSELINUX_LIBS=
11376 if test "${with_selinux}" = "yes"; then
11377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11378 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11379 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11380 $as_echo_n "(cached) " >&6
11381 else
11382 ac_check_lib_save_LIBS=$LIBS
11383 LIBS="-lselinux $LIBS"
11384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11385 /* end confdefs.h. */
11387 /* Override any GCC internal prototype to avoid an error.
11388 Use char because int might match the return type of a GCC
11389 builtin and then its argument prototype would still apply. */
11390 #ifdef __cplusplus
11391 extern "C"
11392 #endif
11393 char lgetfilecon ();
11395 main ()
11397 return lgetfilecon ();
11399 return 0;
11401 _ACEOF
11402 if ac_fn_c_try_link "$LINENO"; then :
11403 ac_cv_lib_selinux_lgetfilecon=yes
11404 else
11405 ac_cv_lib_selinux_lgetfilecon=no
11407 rm -f core conftest.err conftest.$ac_objext \
11408 conftest$ac_exeext conftest.$ac_ext
11409 LIBS=$ac_check_lib_save_LIBS
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11412 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11413 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11414 HAVE_LIBSELINUX=yes
11415 else
11416 HAVE_LIBSELINUX=no
11419 if test "$HAVE_LIBSELINUX" = yes; then
11421 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11423 LIBSELINUX_LIBS=-lselinux
11428 HAVE_GNUTLS=no
11429 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11430 if test "${with_gnutls}" = "yes" ; then
11432 succeeded=no
11434 if test "$PKG_CONFIG" = "no" ; then
11435 HAVE_GNUTLS=no
11436 else
11437 PKG_CONFIG_MIN_VERSION=0.9.0
11438 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11440 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11442 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
11443 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
11444 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
11445 edit_cflags="
11446 s,///*,/,g
11447 s/^/ /
11448 s/ -I/ $isystem/g
11449 s/^ //
11451 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11452 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11454 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11455 succeeded=yes
11456 else
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11458 $as_echo "no" >&6; }
11459 LIBGNUTLS_CFLAGS=""
11460 LIBGNUTLS_LIBS=""
11461 ## If we have a custom action on failure, don't print errors, but
11462 ## do set a variable so people can do so. Do it in a subshell
11463 ## to capture any diagnostics in invoking pkg-config.
11464 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
11470 else
11471 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11472 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11476 if test $succeeded = yes; then
11477 HAVE_GNUTLS=yes
11478 else
11479 HAVE_GNUTLS=no
11482 if test "${HAVE_GNUTLS}" = "yes"; then
11484 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11488 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11489 LIBS="$LIBGNUTLS_LIBS $LIBS"
11490 for ac_func in gnutls_certificate_set_verify_function
11491 do :
11492 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11493 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11494 cat >>confdefs.h <<_ACEOF
11495 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11496 _ACEOF
11497 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11499 done
11502 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11504 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11512 if test "${with_inotify}" = "yes"; then
11513 for ac_header in sys/inotify.h
11514 do :
11515 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
11516 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
11517 cat >>confdefs.h <<_ACEOF
11518 #define HAVE_SYS_INOTIFY_H 1
11519 _ACEOF
11523 done
11525 if test "$ac_cv_header_sys_inotify_h" = yes ; then
11526 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
11527 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
11533 if test "$ac_cv_func_inotify_init1" = yes; then
11535 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
11539 HAVE_POSIX_ACL=no
11540 LIBACL_LIBS=
11541 if test "${with_acl}" = "yes"; then
11542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for acl_set_file in -lacl" >&5
11543 $as_echo_n "checking for acl_set_file in -lacl... " >&6; }
11544 if test "${ac_cv_lib_acl_acl_set_file+set}" = set; then :
11545 $as_echo_n "(cached) " >&6
11546 else
11547 ac_check_lib_save_LIBS=$LIBS
11548 LIBS="-lacl $LIBS"
11549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11550 /* end confdefs.h. */
11552 /* Override any GCC internal prototype to avoid an error.
11553 Use char because int might match the return type of a GCC
11554 builtin and then its argument prototype would still apply. */
11555 #ifdef __cplusplus
11556 extern "C"
11557 #endif
11558 char acl_set_file ();
11560 main ()
11562 return acl_set_file ();
11564 return 0;
11566 _ACEOF
11567 if ac_fn_c_try_link "$LINENO"; then :
11568 ac_cv_lib_acl_acl_set_file=yes
11569 else
11570 ac_cv_lib_acl_acl_set_file=no
11572 rm -f core conftest.err conftest.$ac_objext \
11573 conftest$ac_exeext conftest.$ac_ext
11574 LIBS=$ac_check_lib_save_LIBS
11576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_acl_acl_set_file" >&5
11577 $as_echo "$ac_cv_lib_acl_acl_set_file" >&6; }
11578 if test "x$ac_cv_lib_acl_acl_set_file" = x""yes; then :
11579 HAVE_POSIX_ACL=yes
11580 else
11581 HAVE_POSIX_ACL=no
11584 if test "$HAVE_POSIX_ACL" = yes; then
11586 $as_echo "#define HAVE_POSIX_ACL 1" >>confdefs.h
11588 LIBACL_LIBS=-lacl
11589 else
11590 ac_fn_c_check_func "$LINENO" "acl_set_file" "ac_cv_func_acl_set_file"
11591 if test "x$ac_cv_func_acl_set_file" = x""yes; then :
11592 HAVE_POSIX_ACL=yes
11593 else
11594 HAVE_POSIX_ACL=no
11597 if test "$HAVE_POSIX_ACL" = yes; then
11599 $as_echo "#define HAVE_POSIX_ACL 1" >>confdefs.h
11606 HAVE_XAW3D=no
11607 LUCID_LIBW=
11608 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11609 if test "$with_xaw3d" != no; then
11610 if test "${emacs_cv_xaw3d+set}" = set; then :
11611 $as_echo_n "(cached) " >&6
11612 else
11613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11614 /* end confdefs.h. */
11616 #include <X11/Intrinsic.h>
11617 #include <X11/Xaw3d/Simple.h>
11619 main ()
11623 return 0;
11625 _ACEOF
11626 if ac_fn_c_try_link "$LINENO"; then :
11627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11628 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11629 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11630 $as_echo_n "(cached) " >&6
11631 else
11632 ac_check_lib_save_LIBS=$LIBS
11633 LIBS="-lXaw3d $LIBS"
11634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11635 /* end confdefs.h. */
11637 /* Override any GCC internal prototype to avoid an error.
11638 Use char because int might match the return type of a GCC
11639 builtin and then its argument prototype would still apply. */
11640 #ifdef __cplusplus
11641 extern "C"
11642 #endif
11643 char XawScrollbarSetThumb ();
11645 main ()
11647 return XawScrollbarSetThumb ();
11649 return 0;
11651 _ACEOF
11652 if ac_fn_c_try_link "$LINENO"; then :
11653 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11654 else
11655 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11657 rm -f core conftest.err conftest.$ac_objext \
11658 conftest$ac_exeext conftest.$ac_ext
11659 LIBS=$ac_check_lib_save_LIBS
11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11662 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11663 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11664 emacs_cv_xaw3d=yes
11665 else
11666 emacs_cv_xaw3d=no
11669 else
11670 emacs_cv_xaw3d=no
11672 rm -f core conftest.err conftest.$ac_objext \
11673 conftest$ac_exeext conftest.$ac_ext
11676 else
11677 emacs_cv_xaw3d=no
11679 if test $emacs_cv_xaw3d = yes; then
11680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11681 $as_echo_n "checking for xaw3d... " >&6; }
11682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11683 $as_echo "yes; using Lucid toolkit" >&6; }
11684 USE_X_TOOLKIT=LUCID
11685 HAVE_XAW3D=yes
11686 LUCID_LIBW=-lXaw3d
11688 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11690 else
11691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11692 $as_echo_n "checking for xaw3d... " >&6; }
11693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11694 $as_echo "no" >&6; }
11695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11696 $as_echo_n "checking for libXaw... " >&6; }
11697 if test "${emacs_cv_xaw+set}" = set; then :
11698 $as_echo_n "(cached) " >&6
11699 else
11700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11701 /* end confdefs.h. */
11703 #include <X11/Intrinsic.h>
11704 #include <X11/Xaw/Simple.h>
11706 main ()
11710 return 0;
11712 _ACEOF
11713 if ac_fn_c_try_link "$LINENO"; then :
11714 emacs_cv_xaw=yes
11715 else
11716 emacs_cv_xaw=no
11718 rm -f core conftest.err conftest.$ac_objext \
11719 conftest$ac_exeext conftest.$ac_ext
11722 if test $emacs_cv_xaw = yes; then
11723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11724 $as_echo "yes; using Lucid toolkit" >&6; }
11725 USE_X_TOOLKIT=LUCID
11726 LUCID_LIBW=-lXaw
11727 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11728 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11729 else
11730 as_fn_error "No X toolkit could be found.
11731 If you are sure you want Emacs compiled without an X toolkit, pass
11732 --with-x-toolkit=no
11733 to configure. Otherwise, install the development libraries for the toolkit
11734 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11739 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11741 LIBXTR6=
11742 if test "${USE_X_TOOLKIT}" != "none"; then
11743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11744 $as_echo_n "checking X11 toolkit version... " >&6; }
11745 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11746 $as_echo_n "(cached) " >&6
11747 else
11748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11749 /* end confdefs.h. */
11750 #include <X11/Intrinsic.h>
11752 main ()
11754 #if XtSpecificationRelease < 6
11755 fail;
11756 #endif
11759 return 0;
11761 _ACEOF
11762 if ac_fn_c_try_link "$LINENO"; then :
11763 emacs_cv_x11_toolkit_version_6=yes
11764 else
11765 emacs_cv_x11_toolkit_version_6=no
11767 rm -f core conftest.err conftest.$ac_objext \
11768 conftest$ac_exeext conftest.$ac_ext
11771 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11772 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11774 $as_echo "6 or newer" >&6; }
11776 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11778 LIBXTR6="-lSM -lICE"
11779 case "$opsys" in
11780 ## Use libw.a along with X11R6 Xt.
11781 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11782 esac
11783 else
11784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11785 $as_echo "before 6" >&6; }
11788 OLDLIBS="$LIBS"
11789 if test x$HAVE_X11XTR6 = xyes; then
11790 LIBS="-lXt -lSM -lICE $LIBS"
11791 else
11792 LIBS="-lXt $LIBS"
11794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11795 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11796 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11797 $as_echo_n "(cached) " >&6
11798 else
11799 ac_check_lib_save_LIBS=$LIBS
11800 LIBS="-lXmu $LIBS"
11801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11802 /* end confdefs.h. */
11804 /* Override any GCC internal prototype to avoid an error.
11805 Use char because int might match the return type of a GCC
11806 builtin and then its argument prototype would still apply. */
11807 #ifdef __cplusplus
11808 extern "C"
11809 #endif
11810 char XmuConvertStandardSelection ();
11812 main ()
11814 return XmuConvertStandardSelection ();
11816 return 0;
11818 _ACEOF
11819 if ac_fn_c_try_link "$LINENO"; then :
11820 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11821 else
11822 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11824 rm -f core conftest.err conftest.$ac_objext \
11825 conftest$ac_exeext conftest.$ac_ext
11826 LIBS=$ac_check_lib_save_LIBS
11828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11829 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11830 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11831 cat >>confdefs.h <<_ACEOF
11832 #define HAVE_LIBXMU 1
11833 _ACEOF
11835 LIBS="-lXmu $LIBS"
11839 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11843 LIBXMU=-lXmu
11844 case $opsys in
11845 ## These systems don't supply Xmu.
11846 hpux* | aix4-2 )
11847 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11849 esac
11852 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11853 if test "${HAVE_X11}" = "yes"; then
11854 if test "${USE_X_TOOLKIT}" != "none"; then
11855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11856 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11857 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11858 $as_echo_n "(cached) " >&6
11859 else
11860 ac_check_lib_save_LIBS=$LIBS
11861 LIBS="-lXext $LIBS"
11862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11863 /* end confdefs.h. */
11865 /* Override any GCC internal prototype to avoid an error.
11866 Use char because int might match the return type of a GCC
11867 builtin and then its argument prototype would still apply. */
11868 #ifdef __cplusplus
11869 extern "C"
11870 #endif
11871 char XShapeQueryExtension ();
11873 main ()
11875 return XShapeQueryExtension ();
11877 return 0;
11879 _ACEOF
11880 if ac_fn_c_try_link "$LINENO"; then :
11881 ac_cv_lib_Xext_XShapeQueryExtension=yes
11882 else
11883 ac_cv_lib_Xext_XShapeQueryExtension=no
11885 rm -f core conftest.err conftest.$ac_objext \
11886 conftest$ac_exeext conftest.$ac_ext
11887 LIBS=$ac_check_lib_save_LIBS
11889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11890 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11891 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11892 cat >>confdefs.h <<_ACEOF
11893 #define HAVE_LIBXEXT 1
11894 _ACEOF
11896 LIBS="-lXext $LIBS"
11903 LIBXP=
11904 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11905 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11906 if test -d /usr/include/openmotif; then
11907 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11908 emacs_cv_openmotif=yes
11909 case "$canonical" in
11910 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11911 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11914 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11915 esac
11916 else
11917 emacs_cv_openmotif=no
11919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11920 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11921 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11922 $as_echo_n "(cached) " >&6
11923 else
11924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11925 /* end confdefs.h. */
11926 #include <Xm/Xm.h>
11928 main ()
11930 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11931 int x = 5;
11932 #else
11933 Motif version prior to 2.1.
11934 #endif
11936 return 0;
11938 _ACEOF
11939 if ac_fn_c_try_compile "$LINENO"; then :
11940 emacs_cv_motif_version_2_1=yes
11941 else
11942 emacs_cv_motif_version_2_1=no
11944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11947 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11948 if test $emacs_cv_motif_version_2_1 = yes; then
11949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11950 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11951 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11952 $as_echo_n "(cached) " >&6
11953 else
11954 ac_check_lib_save_LIBS=$LIBS
11955 LIBS="-lXp $LIBS"
11956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11957 /* end confdefs.h. */
11959 /* Override any GCC internal prototype to avoid an error.
11960 Use char because int might match the return type of a GCC
11961 builtin and then its argument prototype would still apply. */
11962 #ifdef __cplusplus
11963 extern "C"
11964 #endif
11965 char XpCreateContext ();
11967 main ()
11969 return XpCreateContext ();
11971 return 0;
11973 _ACEOF
11974 if ac_fn_c_try_link "$LINENO"; then :
11975 ac_cv_lib_Xp_XpCreateContext=yes
11976 else
11977 ac_cv_lib_Xp_XpCreateContext=no
11979 rm -f core conftest.err conftest.$ac_objext \
11980 conftest$ac_exeext conftest.$ac_ext
11981 LIBS=$ac_check_lib_save_LIBS
11983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11984 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11985 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11986 LIBXP=-lXp
11989 if test x$emacs_cv_openmotif = xyes; then
11990 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11992 else
11993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11994 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11995 if test "${emacs_cv_lesstif+set}" = set; then :
11996 $as_echo_n "(cached) " >&6
11997 else
11998 # We put this in CFLAGS temporarily to precede other -I options
11999 # that might be in CFLAGS temporarily.
12000 # We put this in CPPFLAGS where it precedes the other -I options.
12001 OLD_CPPFLAGS=$CPPFLAGS
12002 OLD_CFLAGS=$CFLAGS
12003 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12004 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12006 /* end confdefs.h. */
12007 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12009 main ()
12011 int x = 5;
12013 return 0;
12015 _ACEOF
12016 if ac_fn_c_try_compile "$LINENO"; then :
12017 emacs_cv_lesstif=yes
12018 else
12019 emacs_cv_lesstif=no
12021 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12024 $as_echo "$emacs_cv_lesstif" >&6; }
12025 if test $emacs_cv_lesstif = yes; then
12026 # Make sure this -I option remains in CPPFLAGS after it is set
12027 # back to REAL_CPPFLAGS.
12028 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12029 # have those other -I options anyway. Ultimately, having this
12030 # directory ultimately in CPPFLAGS will be enough.
12031 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12032 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12033 else
12034 CFLAGS=$OLD_CFLAGS
12035 CPPFLAGS=$OLD_CPPFLAGS
12038 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12039 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12041 else
12042 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12049 USE_TOOLKIT_SCROLL_BARS=no
12050 if test "${with_toolkit_scroll_bars}" != "no"; then
12051 if test "${USE_X_TOOLKIT}" != "none"; then
12052 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12053 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12055 HAVE_XAW3D=no
12056 USE_TOOLKIT_SCROLL_BARS=yes
12057 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12058 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12060 USE_TOOLKIT_SCROLL_BARS=yes
12062 elif test "${HAVE_GTK}" = "yes"; then
12063 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12065 USE_TOOLKIT_SCROLL_BARS=yes
12066 elif test "${HAVE_NS}" = "yes"; then
12067 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12069 USE_TOOLKIT_SCROLL_BARS=yes
12070 elif test "${HAVE_W32}" = "yes"; then
12071 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12073 USE_TOOLKIT_SCROLL_BARS=yes
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 XIMProc callback;
12087 return 0;
12089 _ACEOF
12090 if ac_fn_c_try_compile "$LINENO"; then :
12091 HAVE_XIM=yes
12093 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12095 else
12096 HAVE_XIM=no
12098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12101 if test "${with_xim}" != "no"; then
12103 $as_echo "#define USE_XIM 1" >>confdefs.h
12108 if test "${HAVE_XIM}" != "no"; then
12109 late_CFLAGS=$CFLAGS
12110 if test "$GCC" = yes; then
12111 CFLAGS="$CFLAGS --pedantic-errors"
12113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12114 /* end confdefs.h. */
12116 #include <X11/Xlib.h>
12117 #include <X11/Xresource.h>
12119 main ()
12121 Display *display;
12122 XrmDatabase db;
12123 char *res_name;
12124 char *res_class;
12125 XIMProc callback;
12126 XPointer *client_data;
12127 #ifndef __GNUC__
12128 /* If we're not using GCC, it's probably not XFree86, and this is
12129 probably right, but we can't use something like --pedantic-errors. */
12130 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12131 char*, XIMProc, XPointer*);
12132 #endif
12133 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12134 client_data);
12136 return 0;
12138 _ACEOF
12139 if ac_fn_c_try_compile "$LINENO"; then :
12140 emacs_cv_arg6_star=yes
12142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12143 if test "$emacs_cv_arg6_star" = yes; then
12144 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12146 else
12147 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12150 CFLAGS=$late_CFLAGS
12153 ### Start of font-backend (under any platform) section.
12154 # (nothing here yet -- this is a placeholder)
12155 ### End of font-backend (under any platform) section.
12157 ### Start of font-backend (under X11) section.
12158 if test "${HAVE_X11}" = "yes"; then
12160 succeeded=no
12162 if test "$PKG_CONFIG" = "no" ; then
12163 HAVE_FC=no
12164 else
12165 PKG_CONFIG_MIN_VERSION=0.9.0
12166 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12168 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12170 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12171 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12172 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12173 edit_cflags="
12174 s,///*,/,g
12175 s/^/ /
12176 s/ -I/ $isystem/g
12177 s/^ //
12179 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12180 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12182 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12183 succeeded=yes
12184 else
12185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12186 $as_echo "no" >&6; }
12187 FONTCONFIG_CFLAGS=""
12188 FONTCONFIG_LIBS=""
12189 ## If we have a custom action on failure, don't print errors, but
12190 ## do set a variable so people can do so. Do it in a subshell
12191 ## to capture any diagnostics in invoking pkg-config.
12192 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12198 else
12199 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12200 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12204 if test $succeeded = yes; then
12205 HAVE_FC=yes
12206 else
12207 HAVE_FC=no
12211 ## Use -lXft if available, unless `--with-xft=no'.
12212 HAVE_XFT=maybe
12213 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12214 with_xft="no";
12216 if test "x${with_xft}" != "xno"; then
12219 succeeded=no
12221 if test "$PKG_CONFIG" = "no" ; then
12222 HAVE_XFT=no
12223 else
12224 PKG_CONFIG_MIN_VERSION=0.9.0
12225 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12227 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12229 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
12230 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
12231 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
12232 edit_cflags="
12233 s,///*,/,g
12234 s/^/ /
12235 s/ -I/ $isystem/g
12236 s/^ //
12238 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
12239 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12241 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12242 succeeded=yes
12243 else
12244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12245 $as_echo "no" >&6; }
12246 XFT_CFLAGS=""
12247 XFT_LIBS=""
12248 ## If we have a custom action on failure, don't print errors, but
12249 ## do set a variable so people can do so. Do it in a subshell
12250 ## to capture any diagnostics in invoking pkg-config.
12251 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
12257 else
12258 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12259 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12263 if test $succeeded = yes; then
12265 else
12266 HAVE_XFT=no
12269 ## Because xftfont.c uses XRenderQueryExtension, we also
12270 ## need to link to -lXrender.
12271 HAVE_XRENDER=no
12272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12273 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12274 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12275 $as_echo_n "(cached) " >&6
12276 else
12277 ac_check_lib_save_LIBS=$LIBS
12278 LIBS="-lXrender $LIBS"
12279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12280 /* end confdefs.h. */
12282 /* Override any GCC internal prototype to avoid an error.
12283 Use char because int might match the return type of a GCC
12284 builtin and then its argument prototype would still apply. */
12285 #ifdef __cplusplus
12286 extern "C"
12287 #endif
12288 char XRenderQueryExtension ();
12290 main ()
12292 return XRenderQueryExtension ();
12294 return 0;
12296 _ACEOF
12297 if ac_fn_c_try_link "$LINENO"; then :
12298 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12299 else
12300 ac_cv_lib_Xrender_XRenderQueryExtension=no
12302 rm -f core conftest.err conftest.$ac_objext \
12303 conftest$ac_exeext conftest.$ac_ext
12304 LIBS=$ac_check_lib_save_LIBS
12306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12307 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12308 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12309 HAVE_XRENDER=yes
12312 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12313 OLD_CPPFLAGS="$CPPFLAGS"
12314 OLD_CFLAGS="$CFLAGS"
12315 OLD_LIBS="$LIBS"
12316 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12317 CFLAGS="$CFLAGS $XFT_CFLAGS"
12318 XFT_LIBS="-lXrender $XFT_LIBS"
12319 LIBS="$XFT_LIBS $LIBS"
12320 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12321 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12323 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12324 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12325 $as_echo_n "(cached) " >&6
12326 else
12327 ac_check_lib_save_LIBS=$LIBS
12328 LIBS="-lXft $XFT_LIBS $LIBS"
12329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12330 /* end confdefs.h. */
12332 /* Override any GCC internal prototype to avoid an error.
12333 Use char because int might match the return type of a GCC
12334 builtin and then its argument prototype would still apply. */
12335 #ifdef __cplusplus
12336 extern "C"
12337 #endif
12338 char XftFontOpen ();
12340 main ()
12342 return XftFontOpen ();
12344 return 0;
12346 _ACEOF
12347 if ac_fn_c_try_link "$LINENO"; then :
12348 ac_cv_lib_Xft_XftFontOpen=yes
12349 else
12350 ac_cv_lib_Xft_XftFontOpen=no
12352 rm -f core conftest.err conftest.$ac_objext \
12353 conftest$ac_exeext conftest.$ac_ext
12354 LIBS=$ac_check_lib_save_LIBS
12356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12357 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12358 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12359 HAVE_XFT=yes
12366 if test "${HAVE_XFT}" = "yes"; then
12368 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12371 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12372 else
12373 CPPFLAGS="$OLD_CPPFLAGS"
12374 CFLAGS="$OLD_CFLAGS"
12375 LIBS="$OLD_LIBS"
12376 fi # "${HAVE_XFT}" = "yes"
12377 fi # "$HAVE_XFT" != no
12378 fi # "x${with_xft}" != "xno"
12380 ## We used to allow building with FreeType and without Xft.
12381 ## However, the ftx font backend driver is not in good shape.
12382 if test "$HAVE_XFT" != "yes"; then
12383 HAVE_XFT=no
12384 HAVE_FREETYPE=no
12385 else
12387 succeeded=no
12389 if test "$PKG_CONFIG" = "no" ; then
12390 HAVE_FREETYPE=no
12391 else
12392 PKG_CONFIG_MIN_VERSION=0.9.0
12393 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12395 $as_echo_n "checking for freetype2... " >&6; }
12397 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
12398 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
12399 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
12400 edit_cflags="
12401 s,///*,/,g
12402 s/^/ /
12403 s/ -I/ $isystem/g
12404 s/^ //
12406 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12407 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12409 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12410 succeeded=yes
12411 else
12412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12413 $as_echo "no" >&6; }
12414 FREETYPE_CFLAGS=""
12415 FREETYPE_LIBS=""
12416 ## If we have a custom action on failure, don't print errors, but
12417 ## do set a variable so people can do so. Do it in a subshell
12418 ## to capture any diagnostics in invoking pkg-config.
12419 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
12425 else
12426 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12427 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12431 if test $succeeded = yes; then
12432 HAVE_FREETYPE=yes
12433 else
12434 HAVE_FREETYPE=no
12438 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12441 HAVE_LIBOTF=no
12442 if test "${HAVE_FREETYPE}" = "yes"; then
12444 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12446 if test "${with_libotf}" != "no"; then
12448 succeeded=no
12450 if test "$PKG_CONFIG" = "no" ; then
12451 HAVE_LIBOTF=no
12452 else
12453 PKG_CONFIG_MIN_VERSION=0.9.0
12454 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12456 $as_echo_n "checking for libotf... " >&6; }
12458 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
12459 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
12460 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
12461 edit_cflags="
12462 s,///*,/,g
12463 s/^/ /
12464 s/ -I/ $isystem/g
12465 s/^ //
12467 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12468 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12470 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12471 succeeded=yes
12472 else
12473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12474 $as_echo "no" >&6; }
12475 LIBOTF_CFLAGS=""
12476 LIBOTF_LIBS=""
12477 ## If we have a custom action on failure, don't print errors, but
12478 ## do set a variable so people can do so. Do it in a subshell
12479 ## to capture any diagnostics in invoking pkg-config.
12480 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
12486 else
12487 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12488 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12492 if test $succeeded = yes; then
12493 HAVE_LIBOTF=yes
12494 else
12495 HAVE_LIBOTF=no
12498 if test "$HAVE_LIBOTF" = "yes"; then
12500 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12503 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12504 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12505 $as_echo_n "(cached) " >&6
12506 else
12507 ac_check_lib_save_LIBS=$LIBS
12508 LIBS="-lotf $LIBS"
12509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12510 /* end confdefs.h. */
12512 /* Override any GCC internal prototype to avoid an error.
12513 Use char because int might match the return type of a GCC
12514 builtin and then its argument prototype would still apply. */
12515 #ifdef __cplusplus
12516 extern "C"
12517 #endif
12518 char OTF_get_variation_glyphs ();
12520 main ()
12522 return OTF_get_variation_glyphs ();
12524 return 0;
12526 _ACEOF
12527 if ac_fn_c_try_link "$LINENO"; then :
12528 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12529 else
12530 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12532 rm -f core conftest.err conftest.$ac_objext \
12533 conftest$ac_exeext conftest.$ac_ext
12534 LIBS=$ac_check_lib_save_LIBS
12536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12537 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12538 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12539 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12540 else
12541 HAVE_OTF_GET_VARIATION_GLYPHS=no
12544 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12546 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12553 HAVE_M17N_FLT=no
12554 if test "${HAVE_LIBOTF}" = yes; then
12555 if test "${with_m17n_flt}" != "no"; then
12557 succeeded=no
12559 if test "$PKG_CONFIG" = "no" ; then
12560 HAVE_M17N_FLT=no
12561 else
12562 PKG_CONFIG_MIN_VERSION=0.9.0
12563 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12565 $as_echo_n "checking for m17n-flt... " >&6; }
12567 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
12568 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
12569 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
12570 edit_cflags="
12571 s,///*,/,g
12572 s/^/ /
12573 s/ -I/ $isystem/g
12574 s/^ //
12576 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12577 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12579 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12580 succeeded=yes
12581 else
12582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12583 $as_echo "no" >&6; }
12584 M17N_FLT_CFLAGS=""
12585 M17N_FLT_LIBS=""
12586 ## If we have a custom action on failure, don't print errors, but
12587 ## do set a variable so people can do so. Do it in a subshell
12588 ## to capture any diagnostics in invoking pkg-config.
12589 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
12595 else
12596 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12597 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12601 if test $succeeded = yes; then
12602 HAVE_M17N_FLT=yes
12603 else
12604 HAVE_M17N_FLT=no
12607 if test "$HAVE_M17N_FLT" = "yes"; then
12609 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12614 else
12615 HAVE_XFT=no
12616 HAVE_FREETYPE=no
12617 HAVE_LIBOTF=no
12618 HAVE_M17N_FLT=no
12621 ### End of font-backend (under X11) section.
12632 ### Use -lXpm if available, unless `--with-xpm=no'.
12633 HAVE_XPM=no
12634 LIBXPM=
12636 if test "${HAVE_W32}" = "yes"; then
12637 if test "${with_xpm}" != "no"; then
12638 SAVE_CPPFLAGS="$CPPFLAGS"
12639 SAVE_LDFLAGS="$LDFLAGS"
12640 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
12641 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
12642 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12643 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
12645 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
12646 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
12647 $as_echo_n "(cached) " >&6
12648 else
12649 ac_check_lib_save_LIBS=$LIBS
12650 LIBS="-lXpm $LIBS"
12651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12652 /* end confdefs.h. */
12654 /* Override any GCC internal prototype to avoid an error.
12655 Use char because int might match the return type of a GCC
12656 builtin and then its argument prototype would still apply. */
12657 #ifdef __cplusplus
12658 extern "C"
12659 #endif
12660 char XpmReadFileToImage ();
12662 main ()
12664 return XpmReadFileToImage ();
12666 return 0;
12668 _ACEOF
12669 if ac_fn_c_try_link "$LINENO"; then :
12670 ac_cv_lib_Xpm_XpmReadFileToImage=yes
12671 else
12672 ac_cv_lib_Xpm_XpmReadFileToImage=no
12674 rm -f core conftest.err conftest.$ac_objext \
12675 conftest$ac_exeext conftest.$ac_ext
12676 LIBS=$ac_check_lib_save_LIBS
12678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
12679 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
12680 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
12681 HAVE_XPM=yes
12687 if test "${HAVE_XPM}" = "yes"; then
12688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12689 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12691 /* end confdefs.h. */
12692 #include "X11/xpm.h"
12693 #ifndef XpmReturnAllocPixels
12694 no_return_alloc_pixels
12695 #endif
12697 _ACEOF
12698 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12699 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12700 HAVE_XPM=no
12701 else
12702 HAVE_XPM=yes
12704 rm -f conftest*
12707 if test "${HAVE_XPM}" = "yes"; then
12708 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
12709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12710 $as_echo "yes" >&6; }
12711 else
12712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12713 $as_echo "no" >&6; }
12714 CPPFLAGS="$SAVE_CPPFLAGS"
12715 LDFLAGS="$SAVE_LDFLAGS"
12720 if test "${HAVE_XPM}" = "yes"; then
12722 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12724 LIBXPM=-lXpm
12728 if test "${HAVE_X11}" = "yes"; then
12729 if test "${with_xpm}" != "no"; then
12730 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12731 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12733 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12734 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12735 $as_echo_n "(cached) " >&6
12736 else
12737 ac_check_lib_save_LIBS=$LIBS
12738 LIBS="-lXpm -lX11 $LIBS"
12739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12740 /* end confdefs.h. */
12742 /* Override any GCC internal prototype to avoid an error.
12743 Use char because int might match the return type of a GCC
12744 builtin and then its argument prototype would still apply. */
12745 #ifdef __cplusplus
12746 extern "C"
12747 #endif
12748 char XpmReadFileToPixmap ();
12750 main ()
12752 return XpmReadFileToPixmap ();
12754 return 0;
12756 _ACEOF
12757 if ac_fn_c_try_link "$LINENO"; then :
12758 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12759 else
12760 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12762 rm -f core conftest.err conftest.$ac_objext \
12763 conftest$ac_exeext conftest.$ac_ext
12764 LIBS=$ac_check_lib_save_LIBS
12766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12767 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12768 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12769 HAVE_XPM=yes
12775 if test "${HAVE_XPM}" = "yes"; then
12776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12777 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12779 /* end confdefs.h. */
12780 #include "X11/xpm.h"
12781 #ifndef XpmReturnAllocPixels
12782 no_return_alloc_pixels
12783 #endif
12785 _ACEOF
12786 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12787 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12788 HAVE_XPM=no
12789 else
12790 HAVE_XPM=yes
12792 rm -f conftest*
12795 if test "${HAVE_XPM}" = "yes"; then
12796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12797 $as_echo "yes" >&6; }
12798 else
12799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12800 $as_echo "no" >&6; }
12805 if test "${HAVE_XPM}" = "yes"; then
12807 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12809 LIBXPM=-lXpm
12815 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12816 HAVE_JPEG=no
12817 LIBJPEG=
12818 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12819 if test "${with_jpeg}" != "no"; then
12820 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12821 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12823 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12824 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12825 $as_echo_n "(cached) " >&6
12826 else
12827 ac_check_lib_save_LIBS=$LIBS
12828 LIBS="-ljpeg $LIBS"
12829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12830 /* end confdefs.h. */
12832 /* Override any GCC internal prototype to avoid an error.
12833 Use char because int might match the return type of a GCC
12834 builtin and then its argument prototype would still apply. */
12835 #ifdef __cplusplus
12836 extern "C"
12837 #endif
12838 char jpeg_destroy_compress ();
12840 main ()
12842 return jpeg_destroy_compress ();
12844 return 0;
12846 _ACEOF
12847 if ac_fn_c_try_link "$LINENO"; then :
12848 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12849 else
12850 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12852 rm -f core conftest.err conftest.$ac_objext \
12853 conftest$ac_exeext conftest.$ac_ext
12854 LIBS=$ac_check_lib_save_LIBS
12856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12857 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12858 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12859 HAVE_JPEG=yes
12867 if test "${HAVE_JPEG}" = "yes"; then
12868 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12871 /* end confdefs.h. */
12872 #include <jpeglib.h>
12873 version=JPEG_LIB_VERSION
12875 _ACEOF
12876 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12877 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12878 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12880 else
12881 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12882 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12883 HAVE_JPEG=no
12885 rm -f conftest*
12888 if test "${HAVE_JPEG}" = "yes"; then
12889 LIBJPEG=-ljpeg
12894 ### Use -lpng if available, unless `--with-png=no'.
12895 HAVE_PNG=no
12896 LIBPNG=
12897 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12898 if test "${with_png}" != "no"; then
12899 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12900 # in /usr/include/libpng.
12901 for ac_header in png.h libpng/png.h
12902 do :
12903 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12904 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12905 eval as_val=\$$as_ac_Header
12906 if test "x$as_val" = x""yes; then :
12907 cat >>confdefs.h <<_ACEOF
12908 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12909 _ACEOF
12910 break
12913 done
12915 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12917 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12918 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12919 $as_echo_n "(cached) " >&6
12920 else
12921 ac_check_lib_save_LIBS=$LIBS
12922 LIBS="-lpng -lz -lm $LIBS"
12923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12924 /* end confdefs.h. */
12926 /* Override any GCC internal prototype to avoid an error.
12927 Use char because int might match the return type of a GCC
12928 builtin and then its argument prototype would still apply. */
12929 #ifdef __cplusplus
12930 extern "C"
12931 #endif
12932 char png_get_channels ();
12934 main ()
12936 return png_get_channels ();
12938 return 0;
12940 _ACEOF
12941 if ac_fn_c_try_link "$LINENO"; then :
12942 ac_cv_lib_png_png_get_channels=yes
12943 else
12944 ac_cv_lib_png_png_get_channels=no
12946 rm -f core conftest.err conftest.$ac_objext \
12947 conftest$ac_exeext conftest.$ac_ext
12948 LIBS=$ac_check_lib_save_LIBS
12950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12951 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12952 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12953 HAVE_PNG=yes
12959 if test "${HAVE_PNG}" = "yes"; then
12961 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12963 LIBPNG="-lpng -lz -lm"
12965 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12966 # include <libpng/png.h>
12967 #else
12968 # include <png.h>
12969 #endif
12972 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12974 else
12976 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12984 ### Use -ltiff if available, unless `--with-tiff=no'.
12985 HAVE_TIFF=no
12986 LIBTIFF=
12987 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12988 if test "${with_tiff}" != "no"; then
12989 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12990 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12991 tifflibs="-lz -lm"
12992 # At least one tiff package requires the jpeg library.
12993 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12995 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12996 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12997 $as_echo_n "(cached) " >&6
12998 else
12999 ac_check_lib_save_LIBS=$LIBS
13000 LIBS="-ltiff $tifflibs $LIBS"
13001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13002 /* end confdefs.h. */
13004 /* Override any GCC internal prototype to avoid an error.
13005 Use char because int might match the return type of a GCC
13006 builtin and then its argument prototype would still apply. */
13007 #ifdef __cplusplus
13008 extern "C"
13009 #endif
13010 char TIFFGetVersion ();
13012 main ()
13014 return TIFFGetVersion ();
13016 return 0;
13018 _ACEOF
13019 if ac_fn_c_try_link "$LINENO"; then :
13020 ac_cv_lib_tiff_TIFFGetVersion=yes
13021 else
13022 ac_cv_lib_tiff_TIFFGetVersion=no
13024 rm -f core conftest.err conftest.$ac_objext \
13025 conftest$ac_exeext conftest.$ac_ext
13026 LIBS=$ac_check_lib_save_LIBS
13028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13029 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13030 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13031 HAVE_TIFF=yes
13039 if test "${HAVE_TIFF}" = "yes"; then
13041 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13043 LIBTIFF=-ltiff
13048 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13049 HAVE_GIF=no
13050 LIBGIF=
13051 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
13052 || test "${HAVE_W32}" = "yes"; then
13053 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13054 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13055 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13056 # Earlier versions can crash Emacs.
13057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13058 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13059 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13060 $as_echo_n "(cached) " >&6
13061 else
13062 ac_check_lib_save_LIBS=$LIBS
13063 LIBS="-lgif $LIBS"
13064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13065 /* end confdefs.h. */
13067 /* Override any GCC internal prototype to avoid an error.
13068 Use char because int might match the return type of a GCC
13069 builtin and then its argument prototype would still apply. */
13070 #ifdef __cplusplus
13071 extern "C"
13072 #endif
13073 char EGifPutExtensionLast ();
13075 main ()
13077 return EGifPutExtensionLast ();
13079 return 0;
13081 _ACEOF
13082 if ac_fn_c_try_link "$LINENO"; then :
13083 ac_cv_lib_gif_EGifPutExtensionLast=yes
13084 else
13085 ac_cv_lib_gif_EGifPutExtensionLast=no
13087 rm -f core conftest.err conftest.$ac_objext \
13088 conftest$ac_exeext conftest.$ac_ext
13089 LIBS=$ac_check_lib_save_LIBS
13091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13092 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13093 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13094 HAVE_GIF=yes
13095 else
13096 HAVE_GIF=maybe
13103 if test "$HAVE_GIF" = yes; then
13104 LIBGIF=-lgif
13105 elif test "$HAVE_GIF" = maybe; then
13106 # If gif_lib.h but no libgif, try libungif.
13107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13108 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13109 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13110 $as_echo_n "(cached) " >&6
13111 else
13112 ac_check_lib_save_LIBS=$LIBS
13113 LIBS="-lungif $LIBS"
13114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13115 /* end confdefs.h. */
13117 /* Override any GCC internal prototype to avoid an error.
13118 Use char because int might match the return type of a GCC
13119 builtin and then its argument prototype would still apply. */
13120 #ifdef __cplusplus
13121 extern "C"
13122 #endif
13123 char EGifPutExtensionLast ();
13125 main ()
13127 return EGifPutExtensionLast ();
13129 return 0;
13131 _ACEOF
13132 if ac_fn_c_try_link "$LINENO"; then :
13133 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13134 else
13135 ac_cv_lib_ungif_EGifPutExtensionLast=no
13137 rm -f core conftest.err conftest.$ac_objext \
13138 conftest$ac_exeext conftest.$ac_ext
13139 LIBS=$ac_check_lib_save_LIBS
13141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13142 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13143 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13144 HAVE_GIF=yes
13145 else
13146 HAVE_GIF=no
13149 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13152 if test "${HAVE_GIF}" = "yes"; then
13154 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13160 if test "${HAVE_X11}" = "yes"; then
13161 MISSING=""
13162 WITH_NO=""
13163 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13164 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13165 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13166 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13167 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13168 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13169 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13170 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13171 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13172 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13174 if test "X${MISSING}" != X; then
13175 as_fn_error "The following required libraries were not found:
13176 $MISSING
13177 Maybe some development libraries/packages are missing?
13178 If you don't want to link with them give
13179 $WITH_NO
13180 as options to configure" "$LINENO" 5
13184 ### Use -lgpm if available, unless `--with-gpm=no'.
13185 HAVE_GPM=no
13186 LIBGPM=
13187 if test "${with_gpm}" != "no"; then
13188 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13189 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13191 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13192 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13193 $as_echo_n "(cached) " >&6
13194 else
13195 ac_check_lib_save_LIBS=$LIBS
13196 LIBS="-lgpm $LIBS"
13197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13198 /* end confdefs.h. */
13200 /* Override any GCC internal prototype to avoid an error.
13201 Use char because int might match the return type of a GCC
13202 builtin and then its argument prototype would still apply. */
13203 #ifdef __cplusplus
13204 extern "C"
13205 #endif
13206 char Gpm_Open ();
13208 main ()
13210 return Gpm_Open ();
13212 return 0;
13214 _ACEOF
13215 if ac_fn_c_try_link "$LINENO"; then :
13216 ac_cv_lib_gpm_Gpm_Open=yes
13217 else
13218 ac_cv_lib_gpm_Gpm_Open=no
13220 rm -f core conftest.err conftest.$ac_objext \
13221 conftest$ac_exeext conftest.$ac_ext
13222 LIBS=$ac_check_lib_save_LIBS
13224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13225 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13226 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13227 HAVE_GPM=yes
13234 if test "${HAVE_GPM}" = "yes"; then
13236 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13238 LIBGPM=-lgpm
13247 GNUSTEP_CFLAGS=
13248 ### Use NeXTstep API to implement GUI.
13249 if test "${HAVE_NS}" = "yes"; then
13251 $as_echo "#define HAVE_NS 1" >>confdefs.h
13253 if test "${NS_IMPL_COCOA}" = "yes"; then
13255 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13258 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13260 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13262 # See also .m.o rule in Makefile.in */
13263 # FIXME: are all these flags really needed? Document here why. */
13264 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
13265 ## Extra CFLAGS applied to src/*.m files.
13266 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"
13268 # We also have mouse menus.
13269 HAVE_MENUS=yes
13270 OTHER_FILES=ns-app
13273 if test "${HAVE_W32}" = "yes"; then
13274 HAVE_MENUS=yes
13277 ### Use session management (-lSM -lICE) if available
13278 HAVE_X_SM=no
13279 LIBXSM=
13280 if test "${HAVE_X11}" = "yes"; then
13281 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13282 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13284 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13285 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13286 $as_echo_n "(cached) " >&6
13287 else
13288 ac_check_lib_save_LIBS=$LIBS
13289 LIBS="-lSM -lICE $LIBS"
13290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13291 /* end confdefs.h. */
13293 /* Override any GCC internal prototype to avoid an error.
13294 Use char because int might match the return type of a GCC
13295 builtin and then its argument prototype would still apply. */
13296 #ifdef __cplusplus
13297 extern "C"
13298 #endif
13299 char SmcOpenConnection ();
13301 main ()
13303 return SmcOpenConnection ();
13305 return 0;
13307 _ACEOF
13308 if ac_fn_c_try_link "$LINENO"; then :
13309 ac_cv_lib_SM_SmcOpenConnection=yes
13310 else
13311 ac_cv_lib_SM_SmcOpenConnection=no
13313 rm -f core conftest.err conftest.$ac_objext \
13314 conftest$ac_exeext conftest.$ac_ext
13315 LIBS=$ac_check_lib_save_LIBS
13317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13318 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13319 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13320 HAVE_X_SM=yes
13327 if test "${HAVE_X_SM}" = "yes"; then
13329 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13331 LIBXSM="-lSM -lICE"
13332 case "$LIBS" in
13333 *-lSM*) ;;
13334 *) LIBS="$LIBXSM $LIBS" ;;
13335 esac
13340 ### Use libxml (-lxml2) if available
13341 HAVE_LIBXML2=no
13342 if test "${with_xml2}" != "no"; then
13343 ### I'm not sure what the version number should be, so I just guessed.
13345 succeeded=no
13347 if test "$PKG_CONFIG" = "no" ; then
13348 HAVE_LIBXML2=no
13349 else
13350 PKG_CONFIG_MIN_VERSION=0.9.0
13351 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13353 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13355 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
13356 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
13357 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
13358 edit_cflags="
13359 s,///*,/,g
13360 s/^/ /
13361 s/ -I/ $isystem/g
13362 s/^ //
13364 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
13365 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
13366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
13367 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
13368 succeeded=yes
13369 else
13370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13371 $as_echo "no" >&6; }
13372 LIBXML2_CFLAGS=""
13373 LIBXML2_LIBS=""
13374 ## If we have a custom action on failure, don't print errors, but
13375 ## do set a variable so people can do so. Do it in a subshell
13376 ## to capture any diagnostics in invoking pkg-config.
13377 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
13383 else
13384 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13385 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13389 if test $succeeded = yes; then
13390 HAVE_LIBXML2=yes
13391 else
13392 HAVE_LIBXML2=no
13395 if test "${HAVE_LIBXML2}" = "yes"; then
13396 LIBS="$LIBXML2_LIBS $LIBS"
13397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13398 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13399 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13400 $as_echo_n "(cached) " >&6
13401 else
13402 ac_check_lib_save_LIBS=$LIBS
13403 LIBS="-lxml2 $LIBS"
13404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13405 /* end confdefs.h. */
13407 /* Override any GCC internal prototype to avoid an error.
13408 Use char because int might match the return type of a GCC
13409 builtin and then its argument prototype would still apply. */
13410 #ifdef __cplusplus
13411 extern "C"
13412 #endif
13413 char htmlReadMemory ();
13415 main ()
13417 return htmlReadMemory ();
13419 return 0;
13421 _ACEOF
13422 if ac_fn_c_try_link "$LINENO"; then :
13423 ac_cv_lib_xml2_htmlReadMemory=yes
13424 else
13425 ac_cv_lib_xml2_htmlReadMemory=no
13427 rm -f core conftest.err conftest.$ac_objext \
13428 conftest$ac_exeext conftest.$ac_ext
13429 LIBS=$ac_check_lib_save_LIBS
13431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13432 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13433 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13434 HAVE_LIBXML2=yes
13435 else
13436 HAVE_LIBXML2=no
13439 if test "${HAVE_LIBXML2}" = "yes"; then
13441 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13443 else
13444 LIBXML2_LIBS=""
13445 LIBXML2_CFLAGS=""
13452 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13454 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13455 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13456 $as_echo_n "(cached) " >&6
13457 else
13458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13459 /* end confdefs.h. */
13460 #include <netdb.h>
13462 main ()
13464 return h_errno;
13466 return 0;
13468 _ACEOF
13469 if ac_fn_c_try_link "$LINENO"; then :
13470 emacs_cv_netdb_declares_h_errno=yes
13471 else
13472 emacs_cv_netdb_declares_h_errno=no
13474 rm -f core conftest.err conftest.$ac_objext \
13475 conftest$ac_exeext conftest.$ac_ext
13477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13478 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13479 if test $emacs_cv_netdb_declares_h_errno = yes; then
13481 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13485 # sqrt and other floating-point functions such as fmod and frexp
13486 # are found in -lm on most systems.
13487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13488 $as_echo_n "checking for sqrt in -lm... " >&6; }
13489 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13490 $as_echo_n "(cached) " >&6
13491 else
13492 ac_check_lib_save_LIBS=$LIBS
13493 LIBS="-lm $LIBS"
13494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13495 /* end confdefs.h. */
13497 /* Override any GCC internal prototype to avoid an error.
13498 Use char because int might match the return type of a GCC
13499 builtin and then its argument prototype would still apply. */
13500 #ifdef __cplusplus
13501 extern "C"
13502 #endif
13503 char sqrt ();
13505 main ()
13507 return sqrt ();
13509 return 0;
13511 _ACEOF
13512 if ac_fn_c_try_link "$LINENO"; then :
13513 ac_cv_lib_m_sqrt=yes
13514 else
13515 ac_cv_lib_m_sqrt=no
13517 rm -f core conftest.err conftest.$ac_objext \
13518 conftest$ac_exeext conftest.$ac_ext
13519 LIBS=$ac_check_lib_save_LIBS
13521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13522 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13523 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13524 cat >>confdefs.h <<_ACEOF
13525 #define HAVE_LIBM 1
13526 _ACEOF
13528 LIBS="-lm $LIBS"
13533 # Check for mail-locking functions in a "mail" library. Probably this should
13534 # have the same check as for liblockfile below.
13535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13536 $as_echo_n "checking for maillock in -lmail... " >&6; }
13537 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13538 $as_echo_n "(cached) " >&6
13539 else
13540 ac_check_lib_save_LIBS=$LIBS
13541 LIBS="-lmail $LIBS"
13542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13543 /* end confdefs.h. */
13545 /* Override any GCC internal prototype to avoid an error.
13546 Use char because int might match the return type of a GCC
13547 builtin and then its argument prototype would still apply. */
13548 #ifdef __cplusplus
13549 extern "C"
13550 #endif
13551 char maillock ();
13553 main ()
13555 return maillock ();
13557 return 0;
13559 _ACEOF
13560 if ac_fn_c_try_link "$LINENO"; then :
13561 ac_cv_lib_mail_maillock=yes
13562 else
13563 ac_cv_lib_mail_maillock=no
13565 rm -f core conftest.err conftest.$ac_objext \
13566 conftest$ac_exeext conftest.$ac_ext
13567 LIBS=$ac_check_lib_save_LIBS
13569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13570 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13571 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13572 have_mail=yes
13573 else
13574 have_mail=no
13577 if test $have_mail = yes; then
13578 LIBS_MAIL=-lmail
13579 LIBS="$LIBS_MAIL $LIBS"
13581 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13583 else
13584 LIBS_MAIL=
13586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13587 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13588 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13589 $as_echo_n "(cached) " >&6
13590 else
13591 ac_check_lib_save_LIBS=$LIBS
13592 LIBS="-llockfile $LIBS"
13593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13594 /* end confdefs.h. */
13596 /* Override any GCC internal prototype to avoid an error.
13597 Use char because int might match the return type of a GCC
13598 builtin and then its argument prototype would still apply. */
13599 #ifdef __cplusplus
13600 extern "C"
13601 #endif
13602 char maillock ();
13604 main ()
13606 return maillock ();
13608 return 0;
13610 _ACEOF
13611 if ac_fn_c_try_link "$LINENO"; then :
13612 ac_cv_lib_lockfile_maillock=yes
13613 else
13614 ac_cv_lib_lockfile_maillock=no
13616 rm -f core conftest.err conftest.$ac_objext \
13617 conftest$ac_exeext conftest.$ac_ext
13618 LIBS=$ac_check_lib_save_LIBS
13620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13621 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13622 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13623 have_lockfile=yes
13624 else
13625 have_lockfile=no
13628 if test $have_lockfile = yes; then
13629 LIBS_MAIL=-llockfile
13630 LIBS="$LIBS_MAIL $LIBS"
13632 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13634 else
13635 # If we have the shared liblockfile, assume we must use it for mail
13636 # locking (e.g. Debian). If we couldn't link against liblockfile
13637 # (no liblockfile.a installed), ensure that we don't need to.
13638 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13639 set dummy liblockfile.so; ac_word=$2
13640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13641 $as_echo_n "checking for $ac_word... " >&6; }
13642 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13643 $as_echo_n "(cached) " >&6
13644 else
13645 if test -n "$liblockfile"; then
13646 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13647 else
13648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13649 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13650 for as_dir in $as_dummy
13652 IFS=$as_save_IFS
13653 test -z "$as_dir" && as_dir=.
13654 for ac_exec_ext in '' $ac_executable_extensions; do
13655 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13656 ac_cv_prog_liblockfile="yes"
13657 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13658 break 2
13660 done
13661 done
13662 IFS=$as_save_IFS
13664 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13667 liblockfile=$ac_cv_prog_liblockfile
13668 if test -n "$liblockfile"; then
13669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13670 $as_echo "$liblockfile" >&6; }
13671 else
13672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13673 $as_echo "no" >&6; }
13677 if test $ac_cv_prog_liblockfile = yes; then
13678 as_fn_error "Shared liblockfile found but can't link against it.
13679 This probably means that movemail could lose mail.
13680 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13688 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13689 ## interlock access to the mail spool. The alternative is a lock file named
13690 ## /usr/spool/mail/$USER.lock.
13691 mail_lock=no
13692 case "$opsys" in
13693 aix4-2) mail_lock="lockf" ;;
13695 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13697 ## On GNU/Linux systems, both methods are used by various mail programs.
13698 ## I assume most people are using newer mailers that have heard of flock.
13699 ## Change this if you need to.
13700 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13701 ## configure gets the right answers, and that means *NOT* using flock.
13702 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13703 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13704 ## Debian maintainer hasn't provided a clean fix for Emacs.
13705 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13706 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13707 ## correct logic. -- fx
13708 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13709 ## liblockfile is a Free Software replacement for libmail, used on
13710 ## Debian systems and elsewhere. -rfr.
13711 gnu-*)
13712 mail_lock="flock"
13713 if test $have_mail = yes || test $have_lockfile = yes; then
13714 test $ac_cv_header_maillock_h = yes && mail_lock=no
13717 esac
13719 BLESSMAIL_TARGET=
13720 case "$mail_lock" in
13721 flock)
13722 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13725 lockf)
13726 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13729 *) BLESSMAIL_TARGET="need-blessmail" ;;
13730 esac
13734 for ac_func in gethostname \
13735 getrusage get_current_dir_name \
13736 lrand48 \
13737 select getpagesize setlocale \
13738 utimes getrlimit setrlimit shutdown getaddrinfo \
13739 strsignal setitimer \
13740 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13741 gai_strerror mkstemp getline getdelim fsync sync \
13742 difftime posix_memalign \
13743 getpwent endpwent getgrent endgrent \
13744 touchlock \
13745 cfmakeraw cfsetspeed copysign __executable_start
13746 do :
13747 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13748 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13749 eval as_val=\$$as_ac_var
13750 if test "x$as_val" = x""yes; then :
13751 cat >>confdefs.h <<_ACEOF
13752 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13753 _ACEOF
13756 done
13759 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13760 ## has a broken `rint' in some library versions including math library
13761 ## version number A.09.05.
13762 ## You can fix the math library by installing patch number PHSS_4630.
13763 ## But we can fix it more reliably for Emacs by just not using rint.
13764 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13765 case $opsys in
13766 hpux*) : ;;
13767 *) for ac_func in random rint
13768 do :
13769 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13770 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13771 eval as_val=\$$as_ac_var
13772 if test "x$as_val" = x""yes; then :
13773 cat >>confdefs.h <<_ACEOF
13774 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13775 _ACEOF
13778 done
13780 esac
13782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13783 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13784 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13785 $as_echo_n "(cached) " >&6
13786 else
13787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13788 /* end confdefs.h. */
13791 main ()
13793 __builtin_unwind_init ();
13795 return 0;
13797 _ACEOF
13798 if ac_fn_c_try_link "$LINENO"; then :
13799 emacs_cv_func___builtin_unwind_init=yes
13800 else
13801 emacs_cv_func___builtin_unwind_init=no
13803 rm -f core conftest.err conftest.$ac_objext \
13804 conftest$ac_exeext conftest.$ac_ext
13806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13807 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13808 if test $emacs_cv_func___builtin_unwind_init = yes; then
13810 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13819 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13820 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13821 $as_echo_n "(cached) " >&6
13822 else
13823 while :; do
13824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13825 /* end confdefs.h. */
13826 #include <sys/types.h> /* for off_t */
13827 #include <stdio.h>
13829 main ()
13831 int (*fp) (FILE *, off_t, int) = fseeko;
13832 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13834 return 0;
13836 _ACEOF
13837 if ac_fn_c_try_link "$LINENO"; then :
13838 ac_cv_sys_largefile_source=no; break
13840 rm -f core conftest.err conftest.$ac_objext \
13841 conftest$ac_exeext conftest.$ac_ext
13842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13843 /* end confdefs.h. */
13844 #define _LARGEFILE_SOURCE 1
13845 #include <sys/types.h> /* for off_t */
13846 #include <stdio.h>
13848 main ()
13850 int (*fp) (FILE *, off_t, int) = fseeko;
13851 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13853 return 0;
13855 _ACEOF
13856 if ac_fn_c_try_link "$LINENO"; then :
13857 ac_cv_sys_largefile_source=1; break
13859 rm -f core conftest.err conftest.$ac_objext \
13860 conftest$ac_exeext conftest.$ac_ext
13861 ac_cv_sys_largefile_source=unknown
13862 break
13863 done
13865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13866 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13867 case $ac_cv_sys_largefile_source in #(
13868 no | unknown) ;;
13870 cat >>confdefs.h <<_ACEOF
13871 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13872 _ACEOF
13874 esac
13875 rm -rf conftest*
13877 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13878 # in glibc 2.1.3, but that breaks too many other things.
13879 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13880 if test $ac_cv_sys_largefile_source != unknown; then
13882 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13887 # UNIX98 PTYs.
13888 for ac_func in grantpt
13889 do :
13890 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13891 if test "x$ac_cv_func_grantpt" = x""yes; then :
13892 cat >>confdefs.h <<_ACEOF
13893 #define HAVE_GRANTPT 1
13894 _ACEOF
13897 done
13900 # PTY-related GNU extensions.
13901 for ac_func in getpt posix_openpt
13902 do :
13903 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13904 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13905 eval as_val=\$$as_ac_var
13906 if test "x$as_val" = x""yes; then :
13907 cat >>confdefs.h <<_ACEOF
13908 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13909 _ACEOF
13912 done
13915 # Check this now, so that we will NOT find the above functions in ncurses.
13916 # That is because we have not set up to link ncurses in lib-src.
13917 # It's better to believe a function is not available
13918 # than to expect to find it in ncurses.
13919 # Also we need tputs and friends to be able to build at all.
13920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13921 $as_echo_n "checking for library containing tputs... " >&6; }
13922 # Run a test program that contains a call to tputs, a call that is
13923 # never executed. This tests whether a pre-'main' dynamic linker
13924 # works with the library. It's too much trouble to actually call
13925 # tputs in the test program, due to portability hassles. When
13926 # cross-compiling, assume the test program will run if it links.
13928 # Maybe curses should be tried earlier?
13929 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13930 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13931 OLIBS=$LIBS
13932 if test -z "$tputs_library"; then
13933 LIBS_TERMCAP=
13934 msg='none required'
13935 else
13936 LIBS_TERMCAP=-l$tputs_library
13937 msg=$LIBS_TERMCAP
13938 LIBS="$LIBS_TERMCAP $LIBS"
13940 if test "$cross_compiling" = yes; then :
13941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13942 /* end confdefs.h. */
13944 extern void tputs (const char *, int, int (*)(int));
13945 int main (int argc, char **argv)
13947 if (argc == 10000)
13948 tputs (argv[0], 0, 0);
13949 return 0;
13952 _ACEOF
13953 if ac_fn_c_try_link "$LINENO"; then :
13955 else
13956 msg=no
13958 rm -f core conftest.err conftest.$ac_objext \
13959 conftest$ac_exeext conftest.$ac_ext
13960 else
13961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13962 /* end confdefs.h. */
13964 extern void tputs (const char *, int, int (*)(int));
13965 int main (int argc, char **argv)
13967 if (argc == 10000)
13968 tputs (argv[0], 0, 0);
13969 return 0;
13972 _ACEOF
13973 if ac_fn_c_try_run "$LINENO"; then :
13975 else
13976 msg=no
13978 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13979 conftest.$ac_objext conftest.beam conftest.$ac_ext
13982 LIBS=$OLIBS
13983 if test "X$msg" != Xno; then
13984 break
13986 done
13987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13988 $as_echo "$msg" >&6; }
13989 if test "X$msg" = Xno; then
13990 as_fn_error "The required function \`tputs' was not found in any library.
13991 The following libraries were tried (in order):
13992 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13993 Please try installing whichever of these libraries is most appropriate
13994 for your system, together with its header files.
13995 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13998 ## Use termcap instead of terminfo?
13999 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
14000 TERMINFO=yes
14001 ## FIXME? In the cases below where we unconditionally set
14002 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
14003 ## if that was found above to have tputs.
14004 ## Should we use the gnu* logic everywhere?
14005 case "$opsys" in
14006 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
14007 ## The ncurses library has been moved out of the System framework in
14008 ## Mac OS X 10.2. So if configure detects it, set the command-line
14009 ## option to use it.
14010 darwin) LIBS_TERMCAP="-lncurses" ;;
14012 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
14014 freebsd)
14015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
14016 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
14017 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
14018 $as_echo_n "(cached) " >&6
14019 else
14020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14021 /* end confdefs.h. */
14022 #include <osreldate.h>
14024 main ()
14026 #if __FreeBSD_version < 400000
14027 fail;
14028 #endif
14031 return 0;
14033 _ACEOF
14034 if ac_fn_c_try_link "$LINENO"; then :
14035 emacs_cv_freebsd_terminfo=yes
14036 else
14037 emacs_cv_freebsd_terminfo=no
14039 rm -f core conftest.err conftest.$ac_objext \
14040 conftest$ac_exeext conftest.$ac_ext
14044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
14045 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
14047 if test $emacs_cv_freebsd_terminfo = yes; then
14048 LIBS_TERMCAP="-lncurses"
14049 else
14050 TERMINFO=no
14051 LIBS_TERMCAP="-ltermcap"
14055 netbsd)
14056 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
14057 TERMINFO=no
14058 LIBS_TERMCAP="-ltermcap"
14062 openbsd) LIBS_TERMCAP="-lncurses" ;;
14064 ## hpux: Make sure we get select from libc rather than from libcurses
14065 ## because libcurses on HPUX 10.10 has a broken version of select.
14066 ## We used to use -lc -lcurses, but this may be cleaner.
14067 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
14068 # set that way, now it uses the default). Isn't this a contradiction?
14069 hpux*) LIBS_TERMCAP="-ltermcap" ;;
14071 esac
14073 TERMCAP_OBJ=tparam.o
14074 if test $TERMINFO = yes; then
14076 $as_echo "#define TERMINFO 1" >>confdefs.h
14078 TERMCAP_OBJ=terminfo.o
14084 # Do we have res_init, for detecting changes in /etc/resolv.conf?
14085 # On Darwin, res_init appears not to be useful: see bug#562 and
14086 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
14087 resolv=no
14089 if test $opsys != darwin; then
14091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14092 /* end confdefs.h. */
14093 #include <netinet/in.h>
14094 #include <arpa/nameser.h>
14095 #include <resolv.h>
14097 main ()
14099 return res_init();
14101 return 0;
14103 _ACEOF
14104 if ac_fn_c_try_link "$LINENO"; then :
14105 have_res_init=yes
14106 else
14107 have_res_init=no
14109 rm -f core conftest.err conftest.$ac_objext \
14110 conftest$ac_exeext conftest.$ac_ext
14111 if test "$have_res_init" = no; then
14112 OLIBS="$LIBS"
14113 LIBS="$LIBS -lresolv"
14114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
14115 $as_echo_n "checking for res_init with -lresolv... " >&6; }
14116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14117 /* end confdefs.h. */
14118 #include <netinet/in.h>
14119 #include <arpa/nameser.h>
14120 #include <resolv.h>
14122 main ()
14124 return res_init();
14126 return 0;
14128 _ACEOF
14129 if ac_fn_c_try_link "$LINENO"; then :
14130 have_res_init=yes
14131 else
14132 have_res_init=no
14134 rm -f core conftest.err conftest.$ac_objext \
14135 conftest$ac_exeext conftest.$ac_ext
14136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
14137 $as_echo "$have_res_init" >&6; }
14138 if test "$have_res_init" = yes ; then
14139 resolv=yes
14141 LIBS="$OLIBS"
14144 if test "$have_res_init" = yes; then
14146 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
14150 # Do we need the Hesiod library to provide the support routines?
14151 LIBHESIOD=
14152 if test "$with_hesiod" != no ; then
14153 # Don't set $LIBS here -- see comments above. FIXME which comments?
14154 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
14155 if test "x$ac_cv_func_res_send" = x""yes; then :
14157 else
14158 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
14159 if test "x$ac_cv_func___res_send" = x""yes; then :
14161 else
14162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
14163 $as_echo_n "checking for res_send in -lresolv... " >&6; }
14164 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
14165 $as_echo_n "(cached) " >&6
14166 else
14167 ac_check_lib_save_LIBS=$LIBS
14168 LIBS="-lresolv $LIBS"
14169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14170 /* end confdefs.h. */
14172 /* Override any GCC internal prototype to avoid an error.
14173 Use char because int might match the return type of a GCC
14174 builtin and then its argument prototype would still apply. */
14175 #ifdef __cplusplus
14176 extern "C"
14177 #endif
14178 char res_send ();
14180 main ()
14182 return res_send ();
14184 return 0;
14186 _ACEOF
14187 if ac_fn_c_try_link "$LINENO"; then :
14188 ac_cv_lib_resolv_res_send=yes
14189 else
14190 ac_cv_lib_resolv_res_send=no
14192 rm -f core conftest.err conftest.$ac_objext \
14193 conftest$ac_exeext conftest.$ac_ext
14194 LIBS=$ac_check_lib_save_LIBS
14196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
14197 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
14198 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
14199 resolv=yes
14200 else
14201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
14202 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
14203 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
14204 $as_echo_n "(cached) " >&6
14205 else
14206 ac_check_lib_save_LIBS=$LIBS
14207 LIBS="-lresolv $LIBS"
14208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14209 /* end confdefs.h. */
14211 /* Override any GCC internal prototype to avoid an error.
14212 Use char because int might match the return type of a GCC
14213 builtin and then its argument prototype would still apply. */
14214 #ifdef __cplusplus
14215 extern "C"
14216 #endif
14217 char __res_send ();
14219 main ()
14221 return __res_send ();
14223 return 0;
14225 _ACEOF
14226 if ac_fn_c_try_link "$LINENO"; then :
14227 ac_cv_lib_resolv___res_send=yes
14228 else
14229 ac_cv_lib_resolv___res_send=no
14231 rm -f core conftest.err conftest.$ac_objext \
14232 conftest$ac_exeext conftest.$ac_ext
14233 LIBS=$ac_check_lib_save_LIBS
14235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
14236 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
14237 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
14238 resolv=yes
14247 if test "$resolv" = yes ; then
14248 RESOLVLIB=-lresolv
14249 else
14250 RESOLVLIB=
14252 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
14253 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
14255 else
14256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
14257 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
14258 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
14259 $as_echo_n "(cached) " >&6
14260 else
14261 ac_check_lib_save_LIBS=$LIBS
14262 LIBS="-lhesiod $RESOLVLIB $LIBS"
14263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14264 /* end confdefs.h. */
14266 /* Override any GCC internal prototype to avoid an error.
14267 Use char because int might match the return type of a GCC
14268 builtin and then its argument prototype would still apply. */
14269 #ifdef __cplusplus
14270 extern "C"
14271 #endif
14272 char hes_getmailhost ();
14274 main ()
14276 return hes_getmailhost ();
14278 return 0;
14280 _ACEOF
14281 if ac_fn_c_try_link "$LINENO"; then :
14282 ac_cv_lib_hesiod_hes_getmailhost=yes
14283 else
14284 ac_cv_lib_hesiod_hes_getmailhost=no
14286 rm -f core conftest.err conftest.$ac_objext \
14287 conftest$ac_exeext conftest.$ac_ext
14288 LIBS=$ac_check_lib_save_LIBS
14290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
14291 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
14292 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
14293 hesiod=yes
14294 else
14301 if test x"$hesiod" = xyes; then
14303 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14305 LIBHESIOD=-lhesiod
14310 # Do we need libresolv (due to res_init or Hesiod)?
14311 if test "$resolv" = yes && test $opsys != darwin; then
14313 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14315 LIBRESOLV=-lresolv
14316 else
14317 LIBRESOLV=
14321 # These tell us which Kerberos-related libraries to use.
14322 COM_ERRLIB=
14323 CRYPTOLIB=
14324 KRB5LIB=
14325 DESLIB=
14326 KRB4LIB=
14328 if test "${with_kerberos}" != no; then
14329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14330 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
14331 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
14332 $as_echo_n "(cached) " >&6
14333 else
14334 ac_check_lib_save_LIBS=$LIBS
14335 LIBS="-lcom_err $LIBS"
14336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14337 /* end confdefs.h. */
14339 /* Override any GCC internal prototype to avoid an error.
14340 Use char because int might match the return type of a GCC
14341 builtin and then its argument prototype would still apply. */
14342 #ifdef __cplusplus
14343 extern "C"
14344 #endif
14345 char com_err ();
14347 main ()
14349 return com_err ();
14351 return 0;
14353 _ACEOF
14354 if ac_fn_c_try_link "$LINENO"; then :
14355 ac_cv_lib_com_err_com_err=yes
14356 else
14357 ac_cv_lib_com_err_com_err=no
14359 rm -f core conftest.err conftest.$ac_objext \
14360 conftest$ac_exeext conftest.$ac_ext
14361 LIBS=$ac_check_lib_save_LIBS
14363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14364 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
14365 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
14366 have_com_err=yes
14367 else
14368 have_com_err=no
14371 if test $have_com_err = yes; then
14372 COM_ERRLIB=-lcom_err
14373 LIBS="$COM_ERRLIB $LIBS"
14375 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
14378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14379 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
14380 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
14381 $as_echo_n "(cached) " >&6
14382 else
14383 ac_check_lib_save_LIBS=$LIBS
14384 LIBS="-lcrypto $LIBS"
14385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14386 /* end confdefs.h. */
14388 /* Override any GCC internal prototype to avoid an error.
14389 Use char because int might match the return type of a GCC
14390 builtin and then its argument prototype would still apply. */
14391 #ifdef __cplusplus
14392 extern "C"
14393 #endif
14394 char mit_des_cbc_encrypt ();
14396 main ()
14398 return mit_des_cbc_encrypt ();
14400 return 0;
14402 _ACEOF
14403 if ac_fn_c_try_link "$LINENO"; then :
14404 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14405 else
14406 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14408 rm -f core conftest.err conftest.$ac_objext \
14409 conftest$ac_exeext conftest.$ac_ext
14410 LIBS=$ac_check_lib_save_LIBS
14412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14413 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
14414 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
14415 have_crypto=yes
14416 else
14417 have_crypto=no
14420 if test $have_crypto = yes; then
14421 CRYPTOLIB=-lcrypto
14422 LIBS="$CRYPTOLIB $LIBS"
14424 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
14427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14428 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
14429 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
14430 $as_echo_n "(cached) " >&6
14431 else
14432 ac_check_lib_save_LIBS=$LIBS
14433 LIBS="-lk5crypto $LIBS"
14434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14435 /* end confdefs.h. */
14437 /* Override any GCC internal prototype to avoid an error.
14438 Use char because int might match the return type of a GCC
14439 builtin and then its argument prototype would still apply. */
14440 #ifdef __cplusplus
14441 extern "C"
14442 #endif
14443 char mit_des_cbc_encrypt ();
14445 main ()
14447 return mit_des_cbc_encrypt ();
14449 return 0;
14451 _ACEOF
14452 if ac_fn_c_try_link "$LINENO"; then :
14453 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14454 else
14455 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14457 rm -f core conftest.err conftest.$ac_objext \
14458 conftest$ac_exeext conftest.$ac_ext
14459 LIBS=$ac_check_lib_save_LIBS
14461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14462 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
14463 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
14464 have_k5crypto=yes
14465 else
14466 have_k5crypto=no
14469 if test $have_k5crypto = yes; then
14470 CRYPTOLIB=-lk5crypto
14471 LIBS="$CRYPTOLIB $LIBS"
14473 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14477 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14478 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14479 $as_echo_n "(cached) " >&6
14480 else
14481 ac_check_lib_save_LIBS=$LIBS
14482 LIBS="-lkrb5 $LIBS"
14483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14484 /* end confdefs.h. */
14486 /* Override any GCC internal prototype to avoid an error.
14487 Use char because int might match the return type of a GCC
14488 builtin and then its argument prototype would still apply. */
14489 #ifdef __cplusplus
14490 extern "C"
14491 #endif
14492 char krb5_init_context ();
14494 main ()
14496 return krb5_init_context ();
14498 return 0;
14500 _ACEOF
14501 if ac_fn_c_try_link "$LINENO"; then :
14502 ac_cv_lib_krb5_krb5_init_context=yes
14503 else
14504 ac_cv_lib_krb5_krb5_init_context=no
14506 rm -f core conftest.err conftest.$ac_objext \
14507 conftest$ac_exeext conftest.$ac_ext
14508 LIBS=$ac_check_lib_save_LIBS
14510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14511 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14512 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14513 have_krb5=yes
14514 else
14515 have_krb5=no
14518 if test $have_krb5=yes; then
14519 KRB5LIB=-lkrb5
14520 LIBS="$KRB5LIB $LIBS"
14522 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14525 if test "${with_kerberos5}" = no; then
14526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14527 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14528 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14529 $as_echo_n "(cached) " >&6
14530 else
14531 ac_check_lib_save_LIBS=$LIBS
14532 LIBS="-ldes425 $LIBS"
14533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14534 /* end confdefs.h. */
14536 /* Override any GCC internal prototype to avoid an error.
14537 Use char because int might match the return type of a GCC
14538 builtin and then its argument prototype would still apply. */
14539 #ifdef __cplusplus
14540 extern "C"
14541 #endif
14542 char des_cbc_encrypt ();
14544 main ()
14546 return des_cbc_encrypt ();
14548 return 0;
14550 _ACEOF
14551 if ac_fn_c_try_link "$LINENO"; then :
14552 ac_cv_lib_des425_des_cbc_encrypt=yes
14553 else
14554 ac_cv_lib_des425_des_cbc_encrypt=no
14556 rm -f core conftest.err conftest.$ac_objext \
14557 conftest$ac_exeext conftest.$ac_ext
14558 LIBS=$ac_check_lib_save_LIBS
14560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14561 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14562 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14563 have_des425=yes
14564 else
14565 have_des425=no
14568 if test $have_des425 = yes; then
14569 DESLIB=-ldes425
14570 LIBS="$DESLIB $LIBS"
14572 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14574 else
14575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14576 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14577 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14578 $as_echo_n "(cached) " >&6
14579 else
14580 ac_check_lib_save_LIBS=$LIBS
14581 LIBS="-ldes $LIBS"
14582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14583 /* end confdefs.h. */
14585 /* Override any GCC internal prototype to avoid an error.
14586 Use char because int might match the return type of a GCC
14587 builtin and then its argument prototype would still apply. */
14588 #ifdef __cplusplus
14589 extern "C"
14590 #endif
14591 char des_cbc_encrypt ();
14593 main ()
14595 return des_cbc_encrypt ();
14597 return 0;
14599 _ACEOF
14600 if ac_fn_c_try_link "$LINENO"; then :
14601 ac_cv_lib_des_des_cbc_encrypt=yes
14602 else
14603 ac_cv_lib_des_des_cbc_encrypt=no
14605 rm -f core conftest.err conftest.$ac_objext \
14606 conftest$ac_exeext conftest.$ac_ext
14607 LIBS=$ac_check_lib_save_LIBS
14609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14610 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14611 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14612 have_des=yes
14613 else
14614 have_des=no
14617 if test $have_des = yes; then
14618 DESLIB=-ldes
14619 LIBS="$DESLIB $LIBS"
14621 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14626 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14627 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14628 $as_echo_n "(cached) " >&6
14629 else
14630 ac_check_lib_save_LIBS=$LIBS
14631 LIBS="-lkrb4 $LIBS"
14632 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14633 /* end confdefs.h. */
14635 /* Override any GCC internal prototype to avoid an error.
14636 Use char because int might match the return type of a GCC
14637 builtin and then its argument prototype would still apply. */
14638 #ifdef __cplusplus
14639 extern "C"
14640 #endif
14641 char krb_get_cred ();
14643 main ()
14645 return krb_get_cred ();
14647 return 0;
14649 _ACEOF
14650 if ac_fn_c_try_link "$LINENO"; then :
14651 ac_cv_lib_krb4_krb_get_cred=yes
14652 else
14653 ac_cv_lib_krb4_krb_get_cred=no
14655 rm -f core conftest.err conftest.$ac_objext \
14656 conftest$ac_exeext conftest.$ac_ext
14657 LIBS=$ac_check_lib_save_LIBS
14659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14660 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14661 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14662 have_krb4=yes
14663 else
14664 have_krb4=no
14667 if test $have_krb4 = yes; then
14668 KRB4LIB=-lkrb4
14669 LIBS="$KRB4LIB $LIBS"
14671 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14673 else
14674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14675 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14676 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14677 $as_echo_n "(cached) " >&6
14678 else
14679 ac_check_lib_save_LIBS=$LIBS
14680 LIBS="-lkrb $LIBS"
14681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14682 /* end confdefs.h. */
14684 /* Override any GCC internal prototype to avoid an error.
14685 Use char because int might match the return type of a GCC
14686 builtin and then its argument prototype would still apply. */
14687 #ifdef __cplusplus
14688 extern "C"
14689 #endif
14690 char krb_get_cred ();
14692 main ()
14694 return krb_get_cred ();
14696 return 0;
14698 _ACEOF
14699 if ac_fn_c_try_link "$LINENO"; then :
14700 ac_cv_lib_krb_krb_get_cred=yes
14701 else
14702 ac_cv_lib_krb_krb_get_cred=no
14704 rm -f core conftest.err conftest.$ac_objext \
14705 conftest$ac_exeext conftest.$ac_ext
14706 LIBS=$ac_check_lib_save_LIBS
14708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14709 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14710 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14711 have_krb=yes
14712 else
14713 have_krb=no
14716 if test $have_krb = yes; then
14717 KRB4LIB=-lkrb
14718 LIBS="$KRB4LIB $LIBS"
14720 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14726 if test "${with_kerberos5}" != no; then
14727 for ac_header in krb5.h
14728 do :
14729 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14730 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14731 cat >>confdefs.h <<_ACEOF
14732 #define HAVE_KRB5_H 1
14733 _ACEOF
14734 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14736 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14738 cat >>confdefs.h <<_ACEOF
14739 #define HAVE_KRB5_ERROR_TEXT 1
14740 _ACEOF
14744 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14746 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14748 cat >>confdefs.h <<_ACEOF
14749 #define HAVE_KRB5_ERROR_E_TEXT 1
14750 _ACEOF
14757 done
14759 else
14760 for ac_header in des.h
14761 do :
14762 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14763 if test "x$ac_cv_header_des_h" = x""yes; then :
14764 cat >>confdefs.h <<_ACEOF
14765 #define HAVE_DES_H 1
14766 _ACEOF
14768 else
14769 for ac_header in kerberosIV/des.h
14770 do :
14771 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14772 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14773 cat >>confdefs.h <<_ACEOF
14774 #define HAVE_KERBEROSIV_DES_H 1
14775 _ACEOF
14777 else
14778 for ac_header in kerberos/des.h
14779 do :
14780 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14781 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14782 cat >>confdefs.h <<_ACEOF
14783 #define HAVE_KERBEROS_DES_H 1
14784 _ACEOF
14788 done
14792 done
14796 done
14798 for ac_header in krb.h
14799 do :
14800 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14801 if test "x$ac_cv_header_krb_h" = x""yes; then :
14802 cat >>confdefs.h <<_ACEOF
14803 #define HAVE_KRB_H 1
14804 _ACEOF
14806 else
14807 for ac_header in kerberosIV/krb.h
14808 do :
14809 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14810 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14811 cat >>confdefs.h <<_ACEOF
14812 #define HAVE_KERBEROSIV_KRB_H 1
14813 _ACEOF
14815 else
14816 for ac_header in kerberos/krb.h
14817 do :
14818 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14819 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14820 cat >>confdefs.h <<_ACEOF
14821 #define HAVE_KERBEROS_KRB_H 1
14822 _ACEOF
14826 done
14830 done
14834 done
14837 for ac_header in com_err.h
14838 do :
14839 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14840 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14841 cat >>confdefs.h <<_ACEOF
14842 #define HAVE_COM_ERR_H 1
14843 _ACEOF
14847 done
14860 for ac_func in $ac_func_list
14861 do :
14862 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14863 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14864 eval as_val=\$$as_ac_var
14865 if test "x$as_val" = x""yes; then :
14866 cat >>confdefs.h <<_ACEOF
14867 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14868 _ACEOF
14871 done
14876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14877 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14878 if test "${emacs_cv_localtime_cache+set}" = set; then :
14879 $as_echo_n "(cached) " >&6
14880 else
14881 if test x$ac_cv_func_tzset = xyes; then
14882 if test "$cross_compiling" = yes; then :
14883 # If we have tzset, assume the worst when cross-compiling.
14884 emacs_cv_localtime_cache=yes
14885 else
14886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14887 /* end confdefs.h. */
14888 #include <time.h>
14889 char TZ_GMT0[] = "TZ=GMT0";
14890 char TZ_PST8[] = "TZ=PST8";
14891 main()
14893 time_t now = time ((time_t *) 0);
14894 int hour_GMT0, hour_unset;
14895 if (putenv (TZ_GMT0) != 0)
14896 exit (1);
14897 hour_GMT0 = localtime (&now)->tm_hour;
14898 unsetenv("TZ");
14899 hour_unset = localtime (&now)->tm_hour;
14900 if (putenv (TZ_PST8) != 0)
14901 exit (1);
14902 if (localtime (&now)->tm_hour == hour_GMT0)
14903 exit (1);
14904 unsetenv("TZ");
14905 if (localtime (&now)->tm_hour != hour_unset)
14906 exit (1);
14907 exit (0);
14909 _ACEOF
14910 if ac_fn_c_try_run "$LINENO"; then :
14911 emacs_cv_localtime_cache=no
14912 else
14913 emacs_cv_localtime_cache=yes
14915 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14916 conftest.$ac_objext conftest.beam conftest.$ac_ext
14919 else
14920 # If we lack tzset, report that localtime does not cache TZ,
14921 # since we can't invalidate the cache if we don't have tzset.
14922 emacs_cv_localtime_cache=no
14925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14926 $as_echo "$emacs_cv_localtime_cache" >&6; }
14927 if test $emacs_cv_localtime_cache = yes; then
14929 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14933 ok_so_far=yes
14934 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14935 if test "x$ac_cv_func_socket" = x""yes; then :
14937 else
14938 ok_so_far=no
14941 if test $ok_so_far = yes; then
14942 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14943 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14945 else
14946 ok_so_far=no
14951 if test $ok_so_far = yes; then
14952 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14953 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14955 else
14956 ok_so_far=no
14961 if test $ok_so_far = yes; then
14963 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14967 if test -f /usr/lpp/X11/bin/smt.exp; then
14969 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14974 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14975 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14977 $as_echo "yes" >&6; }
14979 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14981 else
14982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14983 $as_echo "no" >&6; }
14986 case $canonical in
14987 *-solaris2.4 | *-solaris2.4.*)
14988 : ${ac_cv_func_vfork_works=no};;
14989 esac
14991 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14992 if test "x$ac_cv_type_pid_t" = x""yes; then :
14994 else
14996 cat >>confdefs.h <<_ACEOF
14997 #define pid_t int
14998 _ACEOF
15002 for ac_header in vfork.h
15003 do :
15004 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15005 if test "x$ac_cv_header_vfork_h" = x""yes; then :
15006 cat >>confdefs.h <<_ACEOF
15007 #define HAVE_VFORK_H 1
15008 _ACEOF
15012 done
15014 for ac_func in fork vfork
15015 do :
15016 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15017 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15018 eval as_val=\$$as_ac_var
15019 if test "x$as_val" = x""yes; then :
15020 cat >>confdefs.h <<_ACEOF
15021 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15022 _ACEOF
15025 done
15027 if test "x$ac_cv_func_fork" = xyes; then
15028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15029 $as_echo_n "checking for working fork... " >&6; }
15030 if test "${ac_cv_func_fork_works+set}" = set; then :
15031 $as_echo_n "(cached) " >&6
15032 else
15033 if test "$cross_compiling" = yes; then :
15034 ac_cv_func_fork_works=cross
15035 else
15036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15037 /* end confdefs.h. */
15038 $ac_includes_default
15040 main ()
15043 /* By Ruediger Kuhlmann. */
15044 return fork () < 0;
15047 return 0;
15049 _ACEOF
15050 if ac_fn_c_try_run "$LINENO"; then :
15051 ac_cv_func_fork_works=yes
15052 else
15053 ac_cv_func_fork_works=no
15055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15056 conftest.$ac_objext conftest.beam conftest.$ac_ext
15060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15061 $as_echo "$ac_cv_func_fork_works" >&6; }
15063 else
15064 ac_cv_func_fork_works=$ac_cv_func_fork
15066 if test "x$ac_cv_func_fork_works" = xcross; then
15067 case $host in
15068 *-*-amigaos* | *-*-msdosdjgpp*)
15069 # Override, as these systems have only a dummy fork() stub
15070 ac_cv_func_fork_works=no
15073 ac_cv_func_fork_works=yes
15075 esac
15076 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15077 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15079 ac_cv_func_vfork_works=$ac_cv_func_vfork
15080 if test "x$ac_cv_func_vfork" = xyes; then
15081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15082 $as_echo_n "checking for working vfork... " >&6; }
15083 if test "${ac_cv_func_vfork_works+set}" = set; then :
15084 $as_echo_n "(cached) " >&6
15085 else
15086 if test "$cross_compiling" = yes; then :
15087 ac_cv_func_vfork_works=cross
15088 else
15089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15090 /* end confdefs.h. */
15091 /* Thanks to Paul Eggert for this test. */
15092 $ac_includes_default
15093 #include <sys/wait.h>
15094 #ifdef HAVE_VFORK_H
15095 # include <vfork.h>
15096 #endif
15097 /* On some sparc systems, changes by the child to local and incoming
15098 argument registers are propagated back to the parent. The compiler
15099 is told about this with #include <vfork.h>, but some compilers
15100 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15101 static variable whose address is put into a register that is
15102 clobbered by the vfork. */
15103 static void
15104 #ifdef __cplusplus
15105 sparc_address_test (int arg)
15106 # else
15107 sparc_address_test (arg) int arg;
15108 #endif
15110 static pid_t child;
15111 if (!child) {
15112 child = vfork ();
15113 if (child < 0) {
15114 perror ("vfork");
15115 _exit(2);
15117 if (!child) {
15118 arg = getpid();
15119 write(-1, "", 0);
15120 _exit (arg);
15126 main ()
15128 pid_t parent = getpid ();
15129 pid_t child;
15131 sparc_address_test (0);
15133 child = vfork ();
15135 if (child == 0) {
15136 /* Here is another test for sparc vfork register problems. This
15137 test uses lots of local variables, at least as many local
15138 variables as main has allocated so far including compiler
15139 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
15140 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
15141 reuse the register of parent for one of the local variables,
15142 since it will think that parent can't possibly be used any more
15143 in this routine. Assigning to the local variable will thus
15144 munge parent in the parent process. */
15145 pid_t
15146 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15147 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15148 /* Convince the compiler that p..p7 are live; otherwise, it might
15149 use the same hardware register for all 8 local variables. */
15150 if (p != p1 || p != p2 || p != p3 || p != p4
15151 || p != p5 || p != p6 || p != p7)
15152 _exit(1);
15154 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15155 from child file descriptors. If the child closes a descriptor
15156 before it execs or exits, this munges the parent's descriptor
15157 as well. Test for this by closing stdout in the child. */
15158 _exit(close(fileno(stdout)) != 0);
15159 } else {
15160 int status;
15161 struct stat st;
15163 while (wait(&status) != child)
15165 return (
15166 /* Was there some problem with vforking? */
15167 child < 0
15169 /* Did the child fail? (This shouldn't happen.) */
15170 || status
15172 /* Did the vfork/compiler bug occur? */
15173 || parent != getpid()
15175 /* Did the file descriptor bug occur? */
15176 || fstat(fileno(stdout), &st) != 0
15180 _ACEOF
15181 if ac_fn_c_try_run "$LINENO"; then :
15182 ac_cv_func_vfork_works=yes
15183 else
15184 ac_cv_func_vfork_works=no
15186 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15187 conftest.$ac_objext conftest.beam conftest.$ac_ext
15191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15192 $as_echo "$ac_cv_func_vfork_works" >&6; }
15195 if test "x$ac_cv_func_fork_works" = xcross; then
15196 ac_cv_func_vfork_works=$ac_cv_func_vfork
15197 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15198 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15201 if test "x$ac_cv_func_vfork_works" = xyes; then
15203 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15205 else
15207 $as_echo "#define vfork fork" >>confdefs.h
15210 if test "x$ac_cv_func_fork_works" = xyes; then
15212 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15217 for ac_func in snprintf
15218 do :
15219 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
15220 if test "x$ac_cv_func_snprintf" = x""yes; then :
15221 cat >>confdefs.h <<_ACEOF
15222 #define HAVE_SNPRINTF 1
15223 _ACEOF
15226 done
15229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
15230 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
15231 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
15232 $as_echo_n "(cached) " >&6
15233 else
15234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15235 /* end confdefs.h. */
15236 #include <langinfo.h>
15238 main ()
15240 char* cs = nl_langinfo(CODESET);
15242 return 0;
15244 _ACEOF
15245 if ac_fn_c_try_link "$LINENO"; then :
15246 emacs_cv_langinfo_codeset=yes
15247 else
15248 emacs_cv_langinfo_codeset=no
15250 rm -f core conftest.err conftest.$ac_objext \
15251 conftest$ac_exeext conftest.$ac_ext
15254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
15255 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
15256 if test $emacs_cv_langinfo_codeset = yes; then
15258 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
15262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
15263 $as_echo_n "checking for mbstate_t... " >&6; }
15264 if test "${ac_cv_type_mbstate_t+set}" = set; then :
15265 $as_echo_n "(cached) " >&6
15266 else
15267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15268 /* end confdefs.h. */
15269 $ac_includes_default
15270 # include <wchar.h>
15272 main ()
15274 mbstate_t x; return sizeof x;
15276 return 0;
15278 _ACEOF
15279 if ac_fn_c_try_compile "$LINENO"; then :
15280 ac_cv_type_mbstate_t=yes
15281 else
15282 ac_cv_type_mbstate_t=no
15284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
15287 $as_echo "$ac_cv_type_mbstate_t" >&6; }
15288 if test $ac_cv_type_mbstate_t = yes; then
15290 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
15292 else
15294 $as_echo "#define mbstate_t int" >>confdefs.h
15298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15299 $as_echo_n "checking for C restricted array declarations... " >&6; }
15300 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
15301 $as_echo_n "(cached) " >&6
15302 else
15303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15304 /* end confdefs.h. */
15305 void fred (int x[__restrict]);
15307 main ()
15311 return 0;
15313 _ACEOF
15314 if ac_fn_c_try_compile "$LINENO"; then :
15315 emacs_cv_c_restrict_arr=yes
15316 else
15317 emacs_cv_c_restrict_arr=no
15319 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15322 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
15323 if test "$emacs_cv_c_restrict_arr" = yes; then
15325 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
15331 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
15335 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
15338 ## Note: PTYs are broken on darwin <6. Use at your own risk.
15340 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
15344 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
15350 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
15354 $as_echo "#define SEPCHAR ':'" >>confdefs.h
15358 $as_echo "#define subprocesses 1" >>confdefs.h
15362 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
15367 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
15373 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
15377 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
15381 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
15387 case $opsys in
15388 aix4-2)
15389 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
15390 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15395 hpux*)
15396 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15399 esac
15402 case $opsys in
15403 irix6-5 | sol2* | unixware )
15405 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
15408 esac
15410 emacs_broken_SIGIO=no
15412 case $opsys in
15413 hpux* | irix6-5 | openbsd | sol2* | unixware )
15414 emacs_broken_SIGIO=yes
15417 aix4-2)
15419 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
15423 freebsd)
15425 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
15428 esac
15430 case $opsys in
15431 gnu-* | sol2-10 )
15433 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
15436 esac
15438 case $opsys in
15439 darwin | freebsd | netbsd | openbsd )
15441 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
15444 esac
15446 case $opsys in
15447 netbsd | openbsd) sound_device="/dev/audio" ;;
15448 *) sound_device="/dev/dsp" ;;
15449 esac
15452 cat >>confdefs.h <<_ACEOF
15453 #define DEFAULT_SOUND_DEVICE "$sound_device"
15454 _ACEOF
15458 case $opsys in
15459 darwin | gnu-linux | gnu-kfreebsd )
15461 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
15464 esac
15467 case $opsys in
15468 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
15470 $as_echo "#define NARROWPROTO 1" >>confdefs.h
15473 esac
15482 case $opsys in
15483 aix4-2 )
15484 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
15486 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
15488 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
15492 cygwin )
15493 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15495 $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
15497 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15499 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15503 darwin )
15504 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15506 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15508 $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
15510 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15512 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15516 gnu | openbsd )
15517 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15521 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15522 if test "x$ac_cv_func_grantpt" = xyes; then
15524 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15526 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15528 $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
15530 if test "x$ac_cv_func_posix_openpt" = xyes; then
15531 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15533 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15535 elif test "x$ac_cv_func_getpt" = xyes; then
15536 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15538 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15540 else
15541 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15544 else
15545 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15550 hpux*)
15551 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15553 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15555 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15559 irix6-5 )
15560 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15562 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15564 $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
15566 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15568 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15572 sol2* )
15573 $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
15577 unixware )
15578 $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
15581 esac
15584 case $opsys in
15585 sol2* | unixware )
15586 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15588 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15591 $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
15594 esac
15599 case $opsys in
15600 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd | darwin )
15601 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15605 gnu-linux | gnu-kfreebsd )
15607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15608 $as_echo_n "checking for signals via characters... " >&6; }
15609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15610 /* end confdefs.h. */
15612 #include <linux/version.h>
15613 #if LINUX_VERSION_CODE < 0x20400
15614 # error "Linux version too old"
15615 #endif
15618 main ()
15622 return 0;
15624 _ACEOF
15625 if ac_fn_c_try_cpp "$LINENO"; then :
15626 emacs_signals_via_chars=yes
15627 else
15628 emacs_signals_via_chars=no
15630 rm -f conftest.err conftest.$ac_ext
15632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15633 $as_echo "$emacs_signals_via_chars" >&6; }
15634 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15637 esac
15643 case $opsys in
15644 gnu)
15645 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15649 hpux*)
15650 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15652 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15655 irix6-5)
15656 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15658 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15661 esac
15666 case $opsys in
15667 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15670 gnu | freebsd | netbsd | openbsd )
15672 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15674 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15678 gnu-linux | gnu-kfreebsd )
15679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15680 /* end confdefs.h. */
15682 #ifndef __ia64__
15683 # error "not ia64"
15684 #endif
15687 main ()
15691 return 0;
15693 _ACEOF
15694 if ac_fn_c_try_cpp "$LINENO"; then :
15696 $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
15699 rm -f conftest.err conftest.$ac_ext
15702 hpux*)
15704 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15707 esac
15713 case $opsys in
15714 gnu-linux | gnu-kfreebsd )
15715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15716 /* end confdefs.h. */
15718 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15719 || defined __alpha__ || defined __mips__ || defined __s390__ \
15720 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15721 || defined __ia64__ || defined __sh__
15722 /* ok */
15723 #else
15724 # error "setjmp not known to work on this arch"
15725 #endif
15728 main ()
15732 return 0;
15734 _ACEOF
15735 if ac_fn_c_try_cpp "$LINENO"; then :
15736 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15739 rm -f conftest.err conftest.$ac_ext
15741 esac
15744 if test x$GCC = xyes; then
15745 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15747 else
15748 case $opsys in
15749 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15750 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15753 esac
15755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15756 $as_echo_n "checking for _setjmp... " >&6; }
15757 if test "${emacs_cv_func__setjmp+set}" = set; then :
15758 $as_echo_n "(cached) " >&6
15759 else
15760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15761 /* end confdefs.h. */
15762 #include <setjmp.h>
15765 main ()
15767 jmp_buf j;
15768 if (! _setjmp (j))
15769 _longjmp (j, 1);
15771 return 0;
15773 _ACEOF
15774 if ac_fn_c_try_link "$LINENO"; then :
15775 emacs_cv_func__setjmp=yes
15776 else
15777 emacs_cv_func__setjmp=no
15779 rm -f core conftest.err conftest.$ac_objext \
15780 conftest$ac_exeext conftest.$ac_ext
15782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15783 $as_echo "$emacs_cv_func__setjmp" >&6; }
15784 if test $emacs_cv_func__setjmp = yes; then
15786 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
15788 else
15789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
15790 $as_echo_n "checking for sigsetjmp... " >&6; }
15791 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
15792 $as_echo_n "(cached) " >&6
15793 else
15794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15795 /* end confdefs.h. */
15796 #include <setjmp.h>
15799 main ()
15801 sigjmp_buf j;
15802 if (! sigsetjmp (j, 1))
15803 siglongjmp (j, 1);
15805 return 0;
15807 _ACEOF
15808 if ac_fn_c_try_link "$LINENO"; then :
15809 emacs_cv_func_sigsetjmp=yes
15810 else
15811 emacs_cv_func_sigsetjmp=no
15813 rm -f core conftest.err conftest.$ac_objext \
15814 conftest$ac_exeext conftest.$ac_ext
15816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
15817 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
15818 if test $emacs_cv_func_sigsetjmp = yes; then
15820 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
15825 case $opsys in
15826 sol2* | unixware )
15828 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15831 esac
15834 case $opsys in
15835 hpux* | sol2* )
15837 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15840 esac
15850 case $opsys in
15851 aix4-2)
15852 $as_echo "#define USG /**/" >>confdefs.h
15854 $as_echo "#define USG5 /**/" >>confdefs.h
15856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15857 /* end confdefs.h. */
15859 #ifndef _AIX
15860 # error "_AIX not defined"
15861 #endif
15864 main ()
15868 return 0;
15870 _ACEOF
15871 if ac_fn_c_try_cpp "$LINENO"; then :
15873 else
15875 $as_echo "#define _AIX /**/" >>confdefs.h
15878 rm -f conftest.err conftest.$ac_ext
15881 cygwin)
15883 $as_echo "#define CYGWIN 1" >>confdefs.h
15887 darwin)
15888 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15891 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15895 freebsd)
15897 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15901 gnu | netbsd | openbsd )
15902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15903 /* end confdefs.h. */
15905 #ifndef BSD_SYSTEM
15906 # error "BSD_SYSTEM not defined"
15907 #endif
15910 main ()
15914 return 0;
15916 _ACEOF
15917 if ac_fn_c_try_cpp "$LINENO"; then :
15919 else
15920 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15923 rm -f conftest.err conftest.$ac_ext
15926 gnu-linux | gnu-kfreebsd )
15927 $as_echo "#define USG /**/" >>confdefs.h
15930 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15934 hpux*)
15935 $as_echo "#define USG /**/" >>confdefs.h
15937 $as_echo "#define USG5 /**/" >>confdefs.h
15940 $as_echo "#define HPUX /**/" >>confdefs.h
15944 irix6-5)
15945 $as_echo "#define USG /**/" >>confdefs.h
15947 $as_echo "#define USG5 /**/" >>confdefs.h
15949 $as_echo "#define USG5_4 /**/" >>confdefs.h
15952 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15956 sol2*)
15957 $as_echo "#define USG /**/" >>confdefs.h
15959 $as_echo "#define USG5 /**/" >>confdefs.h
15961 $as_echo "#define USG5_4 /**/" >>confdefs.h
15964 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15968 unixware)
15969 $as_echo "#define USG /**/" >>confdefs.h
15971 $as_echo "#define USG5 /**/" >>confdefs.h
15973 $as_echo "#define USG5_4 /**/" >>confdefs.h
15976 esac
15978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
15979 $as_echo_n "checking for usable FIONREAD... " >&6; }
15980 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
15981 $as_echo_n "(cached) " >&6
15982 else
15983 case $opsys in
15984 aix4-2)
15985 emacs_cv_usable_FIONREAD=no
15989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15990 /* end confdefs.h. */
15991 #include <sys/types.h>
15992 #include <sys/ioctl.h>
15993 #ifdef USG5_4
15994 # include <sys/filio.h>
15995 #endif
15998 main ()
16000 int foo = ioctl (0, FIONREAD, &foo);
16002 return 0;
16004 _ACEOF
16005 if ac_fn_c_try_compile "$LINENO"; then :
16006 emacs_cv_usable_FIONREAD=yes
16007 else
16008 emacs_cv_usable_FIONREAD=no
16010 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16012 esac
16014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
16015 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
16016 if test $emacs_cv_usable_FIONREAD = yes; then
16018 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
16021 if test $emacs_broken_SIGIO = no; then
16022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
16023 $as_echo_n "checking for usable SIGIO... " >&6; }
16024 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
16025 $as_echo_n "(cached) " >&6
16026 else
16027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16028 /* end confdefs.h. */
16029 #include <fcntl.h>
16030 #include <signal.h>
16033 main ()
16035 int foo = SIGIO | F_SETFL | FASYNC;
16037 return 0;
16039 _ACEOF
16040 if ac_fn_c_try_compile "$LINENO"; then :
16041 emacs_cv_usable_SIGIO=yes
16042 else
16043 emacs_cv_usable_SIGIO=no
16045 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
16048 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
16049 if test $emacs_cv_usable_SIGIO = yes; then
16051 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
16058 case $opsys in
16059 cygwin)
16061 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
16065 hpux11)
16067 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
16071 irix6-5)
16073 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
16077 sol2-10)
16079 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
16082 esac
16084 # Set up the CFLAGS for real compilation, so we can substitute it.
16085 CFLAGS="$REAL_CFLAGS"
16086 CPPFLAGS="$REAL_CPPFLAGS"
16088 ## Hack to detect a buggy GCC version.
16089 if test "x$GCC" = xyes \
16090 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
16091 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
16092 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
16093 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
16096 version=$PACKAGE_VERSION
16098 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
16100 cat >>confdefs.h <<_ACEOF
16101 #define COPYRIGHT "$copyright"
16102 _ACEOF
16106 ### Specify what sort of things we'll be editing into Makefile and config.h.
16107 ### Use configuration here uncanonicalized to avoid exceeding size limits.
16110 ## Unused?
16133 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
16134 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
16135 ## end of LIBX_BASE, but nothing ever set it.
16140 ## Used in lwlib/Makefile.in.
16149 if test -n "${term_header}"; then
16151 cat >>confdefs.h <<_ACEOF
16152 #define TERM_HEADER "${term_header}"
16153 _ACEOF
16158 cat >>confdefs.h <<_ACEOF
16159 #define EMACS_CONFIGURATION "${canonical}"
16160 _ACEOF
16162 emacs_config_options=`echo "$emacs_config_options" | sed -e "s/\"/'/g"`
16164 cat >>confdefs.h <<_ACEOF
16165 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
16166 _ACEOF
16170 XMENU_OBJ=
16171 XOBJ=
16172 FONT_OBJ=
16173 if test "${HAVE_X_WINDOWS}" = "yes" ; then
16175 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
16177 XMENU_OBJ=xmenu.o
16178 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
16179 FONT_OBJ=xfont.o
16180 if test "$HAVE_XFT" = "yes"; then
16181 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
16182 elif test "$HAVE_FREETYPE" = "yes"; then
16183 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
16191 WIDGET_OBJ=
16192 MOTIF_LIBW=
16193 if test "${USE_X_TOOLKIT}" != "none" ; then
16194 WIDGET_OBJ=widget.o
16196 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
16198 if test "${USE_X_TOOLKIT}" = "LUCID"; then
16200 $as_echo "#define USE_LUCID 1" >>confdefs.h
16202 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
16204 $as_echo "#define USE_MOTIF 1" >>confdefs.h
16206 MOTIF_LIBW=-lXm
16207 case "$opsys" in
16208 gnu-linux)
16209 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
16210 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
16213 unixware)
16214 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
16215 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
16216 MOTIF_LIBW="MOTIF_LIBW -lXimp"
16219 aix4-2)
16220 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
16221 MOTIF_LIBW="$MOTIF_LIBW -li18n"
16223 esac
16224 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
16229 TOOLKIT_LIBW=
16230 case "$USE_X_TOOLKIT" in
16231 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
16232 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
16233 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
16234 esac
16237 if test "$USE_X_TOOLKIT" = "none"; then
16238 LIBXT_OTHER="\$(LIBXSM)"
16239 OLDXMENU_TARGET="really-oldXMenu"
16240 else
16241 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
16242 OLDXMENU_TARGET="really-lwlib"
16246 ## The X Menu stuff is present in the X10 distribution, but missing
16247 ## from X11. If we have X10, just use the installed library;
16248 ## otherwise, use our own copy.
16249 if test "${HAVE_X11}" = "yes" ; then
16251 $as_echo "#define HAVE_X11 1" >>confdefs.h
16254 if test "$USE_X_TOOLKIT" = "none"; then
16255 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
16256 else
16257 OLDXMENU="\${lwlibdir}/liblw.a"
16259 LIBXMENU="\$(OLDXMENU)"
16260 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
16261 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
16262 else
16263 ## For a syntactically valid Makefile; not actually used for anything.
16264 ## See comments in src/Makefile.in.
16265 OLDXMENU=nothing
16266 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
16267 if test "${HAVE_X_WINDOWS}" = "yes"; then
16268 LIBXMENU="-lXMenu"
16269 else
16270 LIBXMENU=
16272 LIBX_OTHER=
16273 OLDXMENU_DEPS=
16276 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
16277 OLDXMENU_TARGET=
16278 OLDXMENU=nothing
16279 LIBXMENU=
16280 OLDXMENU_DEPS=
16289 if test "${HAVE_MENUS}" = "yes" ; then
16291 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
16295 if test "${GNU_MALLOC}" = "yes" ; then
16297 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
16301 RALLOC_OBJ=
16302 if test "${REL_ALLOC}" = "yes" ; then
16304 $as_echo "#define REL_ALLOC 1" >>confdefs.h
16307 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
16311 if test "$opsys" = "cygwin"; then
16312 CYGWIN_OBJ="sheap.o cygw32.o"
16313 ## Cygwin differs because of its unexec().
16314 PRE_ALLOC_OBJ=
16315 POST_ALLOC_OBJ=lastfile.o
16316 else
16317 CYGWIN_OBJ=
16318 PRE_ALLOC_OBJ=lastfile.o
16319 POST_ALLOC_OBJ=
16325 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
16326 # it temporarily reverts them to their pre-pkg-config values,
16327 # because gnulib needs to work with both src (which uses the
16328 # pkg-config stuff) and lib-src (which does not). For example, gnulib
16329 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
16330 # and it therefore needs to run in an environment where LIBS does not
16331 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
16332 # for some package unrelated to lib-src.
16333 SAVE_CFLAGS=$CFLAGS
16334 SAVE_LIBS=$LIBS
16335 CFLAGS=$pre_PKG_CONFIG_CFLAGS
16336 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
16348 LIBC_FATAL_STDERR_=1
16349 export LIBC_FATAL_STDERR_
16351 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
16352 # for constant arguments. Useless!
16353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
16354 $as_echo_n "checking for working alloca.h... " >&6; }
16355 if test "${ac_cv_working_alloca_h+set}" = set; then :
16356 $as_echo_n "(cached) " >&6
16357 else
16358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16359 /* end confdefs.h. */
16360 #include <alloca.h>
16362 main ()
16364 char *p = (char *) alloca (2 * sizeof (int));
16365 if (p) return 0;
16367 return 0;
16369 _ACEOF
16370 if ac_fn_c_try_link "$LINENO"; then :
16371 ac_cv_working_alloca_h=yes
16372 else
16373 ac_cv_working_alloca_h=no
16375 rm -f core conftest.err conftest.$ac_objext \
16376 conftest$ac_exeext conftest.$ac_ext
16378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16379 $as_echo "$ac_cv_working_alloca_h" >&6; }
16380 if test $ac_cv_working_alloca_h = yes; then
16382 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16387 $as_echo_n "checking for alloca... " >&6; }
16388 if test "${ac_cv_func_alloca_works+set}" = set; then :
16389 $as_echo_n "(cached) " >&6
16390 else
16391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16392 /* end confdefs.h. */
16393 #ifdef __GNUC__
16394 # define alloca __builtin_alloca
16395 #else
16396 # ifdef _MSC_VER
16397 # include <malloc.h>
16398 # define alloca _alloca
16399 # else
16400 # ifdef HAVE_ALLOCA_H
16401 # include <alloca.h>
16402 # else
16403 # ifdef _AIX
16404 #pragma alloca
16405 # else
16406 # ifndef alloca /* predefined by HP cc +Olibcalls */
16407 char *alloca ();
16408 # endif
16409 # endif
16410 # endif
16411 # endif
16412 #endif
16415 main ()
16417 char *p = (char *) alloca (1);
16418 if (p) return 0;
16420 return 0;
16422 _ACEOF
16423 if ac_fn_c_try_link "$LINENO"; then :
16424 ac_cv_func_alloca_works=yes
16425 else
16426 ac_cv_func_alloca_works=no
16428 rm -f core conftest.err conftest.$ac_objext \
16429 conftest$ac_exeext conftest.$ac_ext
16431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16432 $as_echo "$ac_cv_func_alloca_works" >&6; }
16434 if test $ac_cv_func_alloca_works = yes; then
16436 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16438 else
16439 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16440 # that cause trouble. Some versions do not even contain alloca or
16441 # contain a buggy version. If you still want to use their alloca,
16442 # use ar to extract alloca.o from them instead of compiling alloca.c.
16448 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16450 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16454 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16455 if test "${ac_cv_os_cray+set}" = set; then :
16456 $as_echo_n "(cached) " >&6
16457 else
16458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16459 /* end confdefs.h. */
16460 #if defined CRAY && ! defined CRAY2
16461 webecray
16462 #else
16463 wenotbecray
16464 #endif
16466 _ACEOF
16467 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16468 $EGREP "webecray" >/dev/null 2>&1; then :
16469 ac_cv_os_cray=yes
16470 else
16471 ac_cv_os_cray=no
16473 rm -f conftest*
16476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16477 $as_echo "$ac_cv_os_cray" >&6; }
16478 if test $ac_cv_os_cray = yes; then
16479 for ac_func in _getb67 GETB67 getb67; do
16480 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16481 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16482 eval as_val=\$$as_ac_var
16483 if test "x$as_val" = x""yes; then :
16485 cat >>confdefs.h <<_ACEOF
16486 #define CRAY_STACKSEG_END $ac_func
16487 _ACEOF
16489 break
16492 done
16495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16496 $as_echo_n "checking stack direction for C alloca... " >&6; }
16497 if test "${ac_cv_c_stack_direction+set}" = set; then :
16498 $as_echo_n "(cached) " >&6
16499 else
16500 if test "$cross_compiling" = yes; then :
16501 ac_cv_c_stack_direction=0
16502 else
16503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16504 /* end confdefs.h. */
16505 $ac_includes_default
16507 find_stack_direction (int *addr, int depth)
16509 int dir, dummy = 0;
16510 if (! addr)
16511 addr = &dummy;
16512 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16513 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16514 return dir + dummy;
16518 main (int argc, char **argv)
16520 return find_stack_direction (0, argc + !argv + 20) < 0;
16522 _ACEOF
16523 if ac_fn_c_try_run "$LINENO"; then :
16524 ac_cv_c_stack_direction=1
16525 else
16526 ac_cv_c_stack_direction=-1
16528 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16529 conftest.$ac_objext conftest.beam conftest.$ac_ext
16533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16534 $as_echo "$ac_cv_c_stack_direction" >&6; }
16535 cat >>confdefs.h <<_ACEOF
16536 #define STACK_DIRECTION $ac_cv_c_stack_direction
16537 _ACEOF
16545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16546 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16547 if test "${ac_cv_c_bigendian+set}" = set; then :
16548 $as_echo_n "(cached) " >&6
16549 else
16550 ac_cv_c_bigendian=unknown
16551 # See if we're dealing with a universal compiler.
16552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16553 /* end confdefs.h. */
16554 #ifndef __APPLE_CC__
16555 not a universal capable compiler
16556 #endif
16557 typedef int dummy;
16559 _ACEOF
16560 if ac_fn_c_try_compile "$LINENO"; then :
16562 # Check for potential -arch flags. It is not universal unless
16563 # there are at least two -arch flags with different values.
16564 ac_arch=
16565 ac_prev=
16566 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16567 if test -n "$ac_prev"; then
16568 case $ac_word in
16569 i?86 | x86_64 | ppc | ppc64)
16570 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16571 ac_arch=$ac_word
16572 else
16573 ac_cv_c_bigendian=universal
16574 break
16577 esac
16578 ac_prev=
16579 elif test "x$ac_word" = "x-arch"; then
16580 ac_prev=arch
16582 done
16584 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16585 if test $ac_cv_c_bigendian = unknown; then
16586 # See if sys/param.h defines the BYTE_ORDER macro.
16587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16588 /* end confdefs.h. */
16589 #include <sys/types.h>
16590 #include <sys/param.h>
16593 main ()
16595 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16596 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16597 && LITTLE_ENDIAN)
16598 bogus endian macros
16599 #endif
16602 return 0;
16604 _ACEOF
16605 if ac_fn_c_try_compile "$LINENO"; then :
16606 # It does; now see whether it defined to BIG_ENDIAN or not.
16607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16608 /* end confdefs.h. */
16609 #include <sys/types.h>
16610 #include <sys/param.h>
16613 main ()
16615 #if BYTE_ORDER != BIG_ENDIAN
16616 not big endian
16617 #endif
16620 return 0;
16622 _ACEOF
16623 if ac_fn_c_try_compile "$LINENO"; then :
16624 ac_cv_c_bigendian=yes
16625 else
16626 ac_cv_c_bigendian=no
16628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16632 if test $ac_cv_c_bigendian = unknown; then
16633 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16635 /* end confdefs.h. */
16636 #include <limits.h>
16639 main ()
16641 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16642 bogus endian macros
16643 #endif
16646 return 0;
16648 _ACEOF
16649 if ac_fn_c_try_compile "$LINENO"; then :
16650 # It does; now see whether it defined to _BIG_ENDIAN or not.
16651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16652 /* end confdefs.h. */
16653 #include <limits.h>
16656 main ()
16658 #ifndef _BIG_ENDIAN
16659 not big endian
16660 #endif
16663 return 0;
16665 _ACEOF
16666 if ac_fn_c_try_compile "$LINENO"; then :
16667 ac_cv_c_bigendian=yes
16668 else
16669 ac_cv_c_bigendian=no
16671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16673 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16675 if test $ac_cv_c_bigendian = unknown; then
16676 # Compile a test program.
16677 if test "$cross_compiling" = yes; then :
16678 # Try to guess by grepping values from an object file.
16679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16680 /* end confdefs.h. */
16681 short int ascii_mm[] =
16682 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16683 short int ascii_ii[] =
16684 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16685 int use_ascii (int i) {
16686 return ascii_mm[i] + ascii_ii[i];
16688 short int ebcdic_ii[] =
16689 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16690 short int ebcdic_mm[] =
16691 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16692 int use_ebcdic (int i) {
16693 return ebcdic_mm[i] + ebcdic_ii[i];
16695 extern int foo;
16698 main ()
16700 return use_ascii (foo) == use_ebcdic (foo);
16702 return 0;
16704 _ACEOF
16705 if ac_fn_c_try_compile "$LINENO"; then :
16706 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16707 ac_cv_c_bigendian=yes
16709 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16710 if test "$ac_cv_c_bigendian" = unknown; then
16711 ac_cv_c_bigendian=no
16712 else
16713 # finding both strings is unlikely to happen, but who knows?
16714 ac_cv_c_bigendian=unknown
16718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16719 else
16720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16721 /* end confdefs.h. */
16722 $ac_includes_default
16724 main ()
16727 /* Are we little or big endian? From Harbison&Steele. */
16728 union
16730 long int l;
16731 char c[sizeof (long int)];
16732 } u;
16733 u.l = 1;
16734 return u.c[sizeof (long int) - 1] == 1;
16737 return 0;
16739 _ACEOF
16740 if ac_fn_c_try_run "$LINENO"; then :
16741 ac_cv_c_bigendian=no
16742 else
16743 ac_cv_c_bigendian=yes
16745 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16746 conftest.$ac_objext conftest.beam conftest.$ac_ext
16751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16752 $as_echo "$ac_cv_c_bigendian" >&6; }
16753 case $ac_cv_c_bigendian in #(
16754 yes)
16755 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16756 ;; #(
16758 ;; #(
16759 universal)
16761 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16763 ;; #(
16765 as_fn_error "unknown endianness
16766 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16767 esac
16771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16772 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16773 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16774 $as_echo_n "(cached) " >&6
16775 else
16776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16777 /* end confdefs.h. */
16778 /* On HP-UX before 11.23, strtold returns a struct instead of
16779 long double. Reject implementations like that, by requiring
16780 compatibility with the C99 prototype. */
16781 #include <stdlib.h>
16782 static long double (*p) (char const *, char **) = strtold;
16783 static long double
16784 test (char const *nptr, char **endptr)
16786 long double r;
16787 r = strtold (nptr, endptr);
16788 return r;
16791 main ()
16793 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16795 return 0;
16797 _ACEOF
16798 if ac_fn_c_try_link "$LINENO"; then :
16799 gl_cv_func_c99_strtold=yes
16800 else
16801 gl_cv_func_c99_strtold=no
16803 rm -f core conftest.err conftest.$ac_objext \
16804 conftest$ac_exeext conftest.$ac_ext
16806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16807 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16808 if test $gl_cv_func_c99_strtold = yes; then
16810 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16815 GNULIB_CHDIR=0;
16816 GNULIB_CHOWN=0;
16817 GNULIB_CLOSE=0;
16818 GNULIB_DUP=0;
16819 GNULIB_DUP2=0;
16820 GNULIB_DUP3=0;
16821 GNULIB_ENVIRON=0;
16822 GNULIB_EUIDACCESS=0;
16823 GNULIB_FACCESSAT=0;
16824 GNULIB_FCHDIR=0;
16825 GNULIB_FCHOWNAT=0;
16826 GNULIB_FDATASYNC=0;
16827 GNULIB_FSYNC=0;
16828 GNULIB_FTRUNCATE=0;
16829 GNULIB_GETCWD=0;
16830 GNULIB_GETDOMAINNAME=0;
16831 GNULIB_GETDTABLESIZE=0;
16832 GNULIB_GETGROUPS=0;
16833 GNULIB_GETHOSTNAME=0;
16834 GNULIB_GETLOGIN=0;
16835 GNULIB_GETLOGIN_R=0;
16836 GNULIB_GETPAGESIZE=0;
16837 GNULIB_GETUSERSHELL=0;
16838 GNULIB_GROUP_MEMBER=0;
16839 GNULIB_ISATTY=0;
16840 GNULIB_LCHOWN=0;
16841 GNULIB_LINK=0;
16842 GNULIB_LINKAT=0;
16843 GNULIB_LSEEK=0;
16844 GNULIB_PIPE=0;
16845 GNULIB_PIPE2=0;
16846 GNULIB_PREAD=0;
16847 GNULIB_PWRITE=0;
16848 GNULIB_READ=0;
16849 GNULIB_READLINK=0;
16850 GNULIB_READLINKAT=0;
16851 GNULIB_RMDIR=0;
16852 GNULIB_SETHOSTNAME=0;
16853 GNULIB_SLEEP=0;
16854 GNULIB_SYMLINK=0;
16855 GNULIB_SYMLINKAT=0;
16856 GNULIB_TTYNAME_R=0;
16857 GNULIB_UNISTD_H_NONBLOCKING=0;
16858 GNULIB_UNISTD_H_SIGPIPE=0;
16859 GNULIB_UNLINK=0;
16860 GNULIB_UNLINKAT=0;
16861 GNULIB_USLEEP=0;
16862 GNULIB_WRITE=0;
16863 HAVE_CHOWN=1;
16864 HAVE_DUP2=1;
16865 HAVE_DUP3=1;
16866 HAVE_EUIDACCESS=1;
16867 HAVE_FACCESSAT=1;
16868 HAVE_FCHDIR=1;
16869 HAVE_FCHOWNAT=1;
16870 HAVE_FDATASYNC=1;
16871 HAVE_FSYNC=1;
16872 HAVE_FTRUNCATE=1;
16873 HAVE_GETDTABLESIZE=1;
16874 HAVE_GETGROUPS=1;
16875 HAVE_GETHOSTNAME=1;
16876 HAVE_GETLOGIN=1;
16877 HAVE_GETPAGESIZE=1;
16878 HAVE_GROUP_MEMBER=1;
16879 HAVE_LCHOWN=1;
16880 HAVE_LINK=1;
16881 HAVE_LINKAT=1;
16882 HAVE_PIPE=1;
16883 HAVE_PIPE2=1;
16884 HAVE_PREAD=1;
16885 HAVE_PWRITE=1;
16886 HAVE_READLINK=1;
16887 HAVE_READLINKAT=1;
16888 HAVE_SETHOSTNAME=1;
16889 HAVE_SLEEP=1;
16890 HAVE_SYMLINK=1;
16891 HAVE_SYMLINKAT=1;
16892 HAVE_UNLINKAT=1;
16893 HAVE_USLEEP=1;
16894 HAVE_DECL_ENVIRON=1;
16895 HAVE_DECL_FCHDIR=1;
16896 HAVE_DECL_FDATASYNC=1;
16897 HAVE_DECL_GETDOMAINNAME=1;
16898 HAVE_DECL_GETLOGIN_R=1;
16899 HAVE_DECL_GETPAGESIZE=1;
16900 HAVE_DECL_GETUSERSHELL=1;
16901 HAVE_DECL_SETHOSTNAME=1;
16902 HAVE_DECL_TTYNAME_R=1;
16903 HAVE_OS_H=0;
16904 HAVE_SYS_PARAM_H=0;
16905 REPLACE_CHOWN=0;
16906 REPLACE_CLOSE=0;
16907 REPLACE_DUP=0;
16908 REPLACE_DUP2=0;
16909 REPLACE_FCHOWNAT=0;
16910 REPLACE_FTRUNCATE=0;
16911 REPLACE_GETCWD=0;
16912 REPLACE_GETDOMAINNAME=0;
16913 REPLACE_GETLOGIN_R=0;
16914 REPLACE_GETGROUPS=0;
16915 REPLACE_GETPAGESIZE=0;
16916 REPLACE_ISATTY=0;
16917 REPLACE_LCHOWN=0;
16918 REPLACE_LINK=0;
16919 REPLACE_LINKAT=0;
16920 REPLACE_LSEEK=0;
16921 REPLACE_PREAD=0;
16922 REPLACE_PWRITE=0;
16923 REPLACE_READ=0;
16924 REPLACE_READLINK=0;
16925 REPLACE_RMDIR=0;
16926 REPLACE_SLEEP=0;
16927 REPLACE_SYMLINK=0;
16928 REPLACE_TTYNAME_R=0;
16929 REPLACE_UNLINK=0;
16930 REPLACE_UNLINKAT=0;
16931 REPLACE_USLEEP=0;
16932 REPLACE_WRITE=0;
16933 UNISTD_H_HAVE_WINSOCK2_H=0;
16934 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16945 $as_echo_n "checking if environ is properly declared... " >&6; }
16946 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16947 $as_echo_n "(cached) " >&6
16948 else
16950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16951 /* end confdefs.h. */
16952 #if HAVE_UNISTD_H
16953 #include <unistd.h>
16954 #endif
16955 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16956 #include <stdlib.h>
16958 extern struct { int foo; } environ;
16960 main ()
16962 environ.foo = 1;
16964 return 0;
16966 _ACEOF
16967 if ac_fn_c_try_compile "$LINENO"; then :
16968 gt_cv_var_environ_declaration=no
16969 else
16970 gt_cv_var_environ_declaration=yes
16972 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16976 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16977 if test $gt_cv_var_environ_declaration = yes; then
16979 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16984 if test $gt_cv_var_environ_declaration != yes; then
16985 HAVE_DECL_ENVIRON=0
16996 GNULIB_FCNTL=0;
16997 GNULIB_NONBLOCKING=0;
16998 GNULIB_OPEN=0;
16999 GNULIB_OPENAT=0;
17000 HAVE_FCNTL=1;
17001 HAVE_OPENAT=1;
17002 REPLACE_FCNTL=0;
17003 REPLACE_OPEN=0;
17004 REPLACE_OPENAT=0;
17009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
17010 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
17011 if test "${gl_cv_have_include_next+set}" = set; then :
17012 $as_echo_n "(cached) " >&6
17013 else
17014 rm -rf conftestd1a conftestd1b conftestd2
17015 mkdir conftestd1a conftestd1b conftestd2
17016 cat <<EOF > conftestd1a/conftest.h
17017 #define DEFINED_IN_CONFTESTD1
17018 #include_next <conftest.h>
17019 #ifdef DEFINED_IN_CONFTESTD2
17020 int foo;
17021 #else
17022 #error "include_next doesn't work"
17023 #endif
17025 cat <<EOF > conftestd1b/conftest.h
17026 #define DEFINED_IN_CONFTESTD1
17027 #include <stdio.h>
17028 #include_next <conftest.h>
17029 #ifdef DEFINED_IN_CONFTESTD2
17030 int foo;
17031 #else
17032 #error "include_next doesn't work"
17033 #endif
17035 cat <<EOF > conftestd2/conftest.h
17036 #ifndef DEFINED_IN_CONFTESTD1
17037 #error "include_next test doesn't work"
17038 #endif
17039 #define DEFINED_IN_CONFTESTD2
17041 gl_save_CPPFLAGS="$CPPFLAGS"
17042 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17044 /* end confdefs.h. */
17045 #include <conftest.h>
17046 _ACEOF
17047 if ac_fn_c_try_compile "$LINENO"; then :
17048 gl_cv_have_include_next=yes
17049 else
17050 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
17051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17052 /* end confdefs.h. */
17053 #include <conftest.h>
17054 _ACEOF
17055 if ac_fn_c_try_compile "$LINENO"; then :
17056 gl_cv_have_include_next=buggy
17057 else
17058 gl_cv_have_include_next=no
17060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17063 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17064 CPPFLAGS="$gl_save_CPPFLAGS"
17065 rm -rf conftestd1a conftestd1b conftestd2
17068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
17069 $as_echo "$gl_cv_have_include_next" >&6; }
17070 PRAGMA_SYSTEM_HEADER=
17071 if test $gl_cv_have_include_next = yes; then
17072 INCLUDE_NEXT=include_next
17073 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17074 if test -n "$GCC"; then
17075 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
17077 else
17078 if test $gl_cv_have_include_next = buggy; then
17079 INCLUDE_NEXT=include
17080 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17081 else
17082 INCLUDE_NEXT=include
17083 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
17089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
17090 $as_echo_n "checking whether system header files limit the line length... " >&6; }
17091 if test "${gl_cv_pragma_columns+set}" = set; then :
17092 $as_echo_n "(cached) " >&6
17093 else
17094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17095 /* end confdefs.h. */
17097 #ifdef __TANDEM
17098 choke me
17099 #endif
17101 _ACEOF
17102 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17103 $EGREP "choke me" >/dev/null 2>&1; then :
17104 gl_cv_pragma_columns=yes
17105 else
17106 gl_cv_pragma_columns=no
17108 rm -f conftest*
17112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
17113 $as_echo "$gl_cv_pragma_columns" >&6; }
17114 if test $gl_cv_pragma_columns = yes; then
17115 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
17116 else
17117 PRAGMA_COLUMNS=
17121 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
17122 if test "x$ac_cv_type_mode_t" = x""yes; then :
17124 else
17126 cat >>confdefs.h <<_ACEOF
17127 #define mode_t int
17128 _ACEOF
17132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
17133 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
17134 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
17135 $as_echo_n "(cached) " >&6
17136 else
17137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17138 /* end confdefs.h. */
17140 #include <sys/types.h>
17141 #include <sys/stat.h>
17143 main ()
17145 struct stat s; s.st_dm_mode;
17147 return 0;
17149 _ACEOF
17150 if ac_fn_c_try_compile "$LINENO"; then :
17151 ac_cv_struct_st_dm_mode=yes
17152 else
17153 ac_cv_struct_st_dm_mode=no
17155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
17158 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
17160 if test $ac_cv_struct_st_dm_mode = yes; then
17162 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
17167 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
17168 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
17169 ac_have_decl=1
17170 else
17171 ac_have_decl=0
17174 cat >>confdefs.h <<_ACEOF
17175 #define HAVE_DECL_STRMODE $ac_have_decl
17176 _ACEOF
17183 GNULIB__EXIT=0;
17184 GNULIB_ATOLL=0;
17185 GNULIB_CALLOC_POSIX=0;
17186 GNULIB_CANONICALIZE_FILE_NAME=0;
17187 GNULIB_GETLOADAVG=0;
17188 GNULIB_GETSUBOPT=0;
17189 GNULIB_GRANTPT=0;
17190 GNULIB_MALLOC_POSIX=0;
17191 GNULIB_MBTOWC=0;
17192 GNULIB_MKDTEMP=0;
17193 GNULIB_MKOSTEMP=0;
17194 GNULIB_MKOSTEMPS=0;
17195 GNULIB_MKSTEMP=0;
17196 GNULIB_MKSTEMPS=0;
17197 GNULIB_POSIX_OPENPT=0;
17198 GNULIB_PTSNAME=0;
17199 GNULIB_PTSNAME_R=0;
17200 GNULIB_PUTENV=0;
17201 GNULIB_RANDOM=0;
17202 GNULIB_RANDOM_R=0;
17203 GNULIB_REALLOC_POSIX=0;
17204 GNULIB_REALPATH=0;
17205 GNULIB_RPMATCH=0;
17206 GNULIB_SETENV=0;
17207 GNULIB_STRTOD=0;
17208 GNULIB_STRTOLL=0;
17209 GNULIB_STRTOULL=0;
17210 GNULIB_SYSTEM_POSIX=0;
17211 GNULIB_UNLOCKPT=0;
17212 GNULIB_UNSETENV=0;
17213 GNULIB_WCTOMB=0;
17214 HAVE__EXIT=1;
17215 HAVE_ATOLL=1;
17216 HAVE_CANONICALIZE_FILE_NAME=1;
17217 HAVE_DECL_GETLOADAVG=1;
17218 HAVE_GETSUBOPT=1;
17219 HAVE_GRANTPT=1;
17220 HAVE_MKDTEMP=1;
17221 HAVE_MKOSTEMP=1;
17222 HAVE_MKOSTEMPS=1;
17223 HAVE_MKSTEMP=1;
17224 HAVE_MKSTEMPS=1;
17225 HAVE_POSIX_OPENPT=1;
17226 HAVE_PTSNAME=1;
17227 HAVE_PTSNAME_R=1;
17228 HAVE_RANDOM=1;
17229 HAVE_RANDOM_H=1;
17230 HAVE_RANDOM_R=1;
17231 HAVE_REALPATH=1;
17232 HAVE_RPMATCH=1;
17233 HAVE_SETENV=1;
17234 HAVE_DECL_SETENV=1;
17235 HAVE_STRTOD=1;
17236 HAVE_STRTOLL=1;
17237 HAVE_STRTOULL=1;
17238 HAVE_STRUCT_RANDOM_DATA=1;
17239 HAVE_SYS_LOADAVG_H=0;
17240 HAVE_UNLOCKPT=1;
17241 HAVE_DECL_UNSETENV=1;
17242 REPLACE_CALLOC=0;
17243 REPLACE_CANONICALIZE_FILE_NAME=0;
17244 REPLACE_MALLOC=0;
17245 REPLACE_MBTOWC=0;
17246 REPLACE_MKSTEMP=0;
17247 REPLACE_PTSNAME=0;
17248 REPLACE_PTSNAME_R=0;
17249 REPLACE_PUTENV=0;
17250 REPLACE_RANDOM_R=0;
17251 REPLACE_REALLOC=0;
17252 REPLACE_REALPATH=0;
17253 REPLACE_SETENV=0;
17254 REPLACE_STRTOD=0;
17255 REPLACE_UNSETENV=0;
17256 REPLACE_WCTOMB=0;
17273 if test $gl_cv_have_include_next = yes; then
17274 gl_cv_next_getopt_h='<'getopt.h'>'
17275 else
17276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
17277 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
17278 if test "${gl_cv_next_getopt_h+set}" = set; then :
17279 $as_echo_n "(cached) " >&6
17280 else
17282 if test $ac_cv_header_getopt_h = yes; then
17285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17286 /* end confdefs.h. */
17287 #include <getopt.h>
17289 _ACEOF
17290 case "$host_os" in
17291 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17292 *) gl_absname_cpp="$ac_cpp" ;;
17293 esac
17295 case "$host_os" in
17296 mingw*)
17297 gl_dirsep_regex='[/\\]'
17300 gl_dirsep_regex='\/'
17302 esac
17303 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17305 gl_header_literal_regex=`echo 'getopt.h' \
17306 | sed -e "$gl_make_literal_regex_sed"`
17307 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17308 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17309 s|^/[^/]|//&|
17313 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17314 sed -n "$gl_absolute_header_sed"`'"'
17315 else
17316 gl_cv_next_getopt_h='<'getopt.h'>'
17321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
17322 $as_echo "$gl_cv_next_getopt_h" >&6; }
17324 NEXT_GETOPT_H=$gl_cv_next_getopt_h
17326 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17327 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17328 gl_next_as_first_directive='<'getopt.h'>'
17329 else
17330 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17331 gl_next_as_first_directive=$gl_cv_next_getopt_h
17333 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
17338 if test $ac_cv_header_getopt_h = yes; then
17339 HAVE_GETOPT_H=1
17340 else
17341 HAVE_GETOPT_H=0
17345 gl_replace_getopt=
17347 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17348 for ac_header in getopt.h
17349 do :
17350 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
17351 if test "x$ac_cv_header_getopt_h" = x""yes; then :
17352 cat >>confdefs.h <<_ACEOF
17353 #define HAVE_GETOPT_H 1
17354 _ACEOF
17356 else
17357 gl_replace_getopt=yes
17360 done
17364 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17365 for ac_func in getopt_long_only
17366 do :
17367 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
17368 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
17369 cat >>confdefs.h <<_ACEOF
17370 #define HAVE_GETOPT_LONG_ONLY 1
17371 _ACEOF
17373 else
17374 gl_replace_getopt=yes
17376 done
17380 if test -z "$gl_replace_getopt"; then
17381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17382 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17383 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17384 $as_echo_n "(cached) " >&6
17385 else
17387 if test $cross_compiling = no; then
17388 if test "$cross_compiling" = yes; then :
17389 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17390 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17391 as_fn_error "cannot run test program while cross compiling
17392 See \`config.log' for more details." "$LINENO" 5; }
17393 else
17394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17395 /* end confdefs.h. */
17397 #include <unistd.h>
17398 #include <stdlib.h>
17399 #include <string.h>
17402 main ()
17404 static char program[] = "program";
17405 static char a[] = "-a";
17406 static char foo[] = "foo";
17407 static char bar[] = "bar";
17408 char *argv[] = { program, a, foo, bar, NULL };
17409 int c;
17411 c = getopt (4, argv, "ab");
17412 if (!(c == 'a'))
17413 return 1;
17414 c = getopt (4, argv, "ab");
17415 if (!(c == -1))
17416 return 2;
17417 if (!(optind == 2))
17418 return 3;
17419 return 0;
17422 _ACEOF
17423 if ac_fn_c_try_run "$LINENO"; then :
17424 gl_cv_func_getopt_posix=maybe
17425 else
17426 gl_cv_func_getopt_posix=no
17428 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17429 conftest.$ac_objext conftest.beam conftest.$ac_ext
17432 if test $gl_cv_func_getopt_posix = maybe; then
17433 if test "$cross_compiling" = yes; then :
17434 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17435 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17436 as_fn_error "cannot run test program while cross compiling
17437 See \`config.log' for more details." "$LINENO" 5; }
17438 else
17439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17440 /* end confdefs.h. */
17442 #include <unistd.h>
17443 #include <stdlib.h>
17444 #include <string.h>
17447 main ()
17449 static char program[] = "program";
17450 static char donald[] = "donald";
17451 static char p[] = "-p";
17452 static char billy[] = "billy";
17453 static char duck[] = "duck";
17454 static char a[] = "-a";
17455 static char bar[] = "bar";
17456 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17457 int c;
17459 c = getopt (7, argv, "+abp:q:");
17460 if (!(c == -1))
17461 return 4;
17462 if (!(strcmp (argv[0], "program") == 0))
17463 return 5;
17464 if (!(strcmp (argv[1], "donald") == 0))
17465 return 6;
17466 if (!(strcmp (argv[2], "-p") == 0))
17467 return 7;
17468 if (!(strcmp (argv[3], "billy") == 0))
17469 return 8;
17470 if (!(strcmp (argv[4], "duck") == 0))
17471 return 9;
17472 if (!(strcmp (argv[5], "-a") == 0))
17473 return 10;
17474 if (!(strcmp (argv[6], "bar") == 0))
17475 return 11;
17476 if (!(optind == 1))
17477 return 12;
17478 return 0;
17481 _ACEOF
17482 if ac_fn_c_try_run "$LINENO"; then :
17483 gl_cv_func_getopt_posix=maybe
17484 else
17485 gl_cv_func_getopt_posix=no
17487 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17488 conftest.$ac_objext conftest.beam conftest.$ac_ext
17492 if test $gl_cv_func_getopt_posix = maybe; then
17493 if test "$cross_compiling" = yes; then :
17494 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17495 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17496 as_fn_error "cannot run test program while cross compiling
17497 See \`config.log' for more details." "$LINENO" 5; }
17498 else
17499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17500 /* end confdefs.h. */
17502 #include <unistd.h>
17503 #include <stdlib.h>
17504 #include <string.h>
17507 main ()
17509 static char program[] = "program";
17510 static char ab[] = "-ab";
17511 char *argv[3] = { program, ab, NULL };
17512 if (getopt (2, argv, "ab:") != 'a')
17513 return 13;
17514 if (getopt (2, argv, "ab:") != '?')
17515 return 14;
17516 if (optopt != 'b')
17517 return 15;
17518 if (optind != 2)
17519 return 16;
17520 return 0;
17523 _ACEOF
17524 if ac_fn_c_try_run "$LINENO"; then :
17525 gl_cv_func_getopt_posix=yes
17526 else
17527 gl_cv_func_getopt_posix=no
17529 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17530 conftest.$ac_objext conftest.beam conftest.$ac_ext
17534 else
17535 case "$host_os" in
17536 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17537 *) gl_cv_func_getopt_posix="guessing yes";;
17538 esac
17542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17543 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17544 case "$gl_cv_func_getopt_posix" in
17545 *no) gl_replace_getopt=yes ;;
17546 esac
17549 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17551 $as_echo_n "checking for working GNU getopt function... " >&6; }
17552 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17553 $as_echo_n "(cached) " >&6
17554 else
17555 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17556 # optstring is necessary for programs like m4 that have POSIX-mandated
17557 # semantics for supporting options interspersed with files.
17558 # Also, since getopt_long is a GNU extension, we require optind=0.
17559 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17560 # so take care to revert to the correct (non-)export state.
17561 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17562 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17563 xx) gl_had_POSIXLY_CORRECT=exported ;;
17564 x) gl_had_POSIXLY_CORRECT=yes ;;
17565 *) gl_had_POSIXLY_CORRECT= ;;
17566 esac
17567 POSIXLY_CORRECT=1
17568 export POSIXLY_CORRECT
17569 if test "$cross_compiling" = yes; then :
17570 gl_cv_func_getopt_gnu="guessing no"
17572 else
17573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17574 /* end confdefs.h. */
17575 #include <getopt.h>
17576 #include <stddef.h>
17577 #include <string.h>
17579 #include <stdlib.h>
17580 #if defined __MACH__ && defined __APPLE__
17581 /* Avoid a crash on Mac OS X. */
17582 #include <mach/mach.h>
17583 #include <mach/mach_error.h>
17584 #include <mach/thread_status.h>
17585 #include <mach/exception.h>
17586 #include <mach/task.h>
17587 #include <pthread.h>
17588 /* The exception port on which our thread listens. */
17589 static mach_port_t our_exception_port;
17590 /* The main function of the thread listening for exceptions of type
17591 EXC_BAD_ACCESS. */
17592 static void *
17593 mach_exception_thread (void *arg)
17595 /* Buffer for a message to be received. */
17596 struct {
17597 mach_msg_header_t head;
17598 mach_msg_body_t msgh_body;
17599 char data[1024];
17600 } msg;
17601 mach_msg_return_t retval;
17602 /* Wait for a message on the exception port. */
17603 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17604 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17605 if (retval != MACH_MSG_SUCCESS)
17606 abort ();
17607 exit (1);
17609 static void
17610 nocrash_init (void)
17612 mach_port_t self = mach_task_self ();
17613 /* Allocate a port on which the thread shall listen for exceptions. */
17614 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17615 == KERN_SUCCESS) {
17616 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17617 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17618 MACH_MSG_TYPE_MAKE_SEND)
17619 == KERN_SUCCESS) {
17620 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17621 for us. */
17622 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17623 /* Create the thread listening on the exception port. */
17624 pthread_attr_t attr;
17625 pthread_t thread;
17626 if (pthread_attr_init (&attr) == 0
17627 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17628 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17629 pthread_attr_destroy (&attr);
17630 /* Replace the exception port info for these exceptions with our own.
17631 Note that we replace the exception port for the entire task, not only
17632 for a particular thread. This has the effect that when our exception
17633 port gets the message, the thread specific exception port has already
17634 been asked, and we don't need to bother about it.
17635 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17636 task_set_exception_ports (self, mask, our_exception_port,
17637 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17642 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17643 /* Avoid a crash on native Windows. */
17644 #define WIN32_LEAN_AND_MEAN
17645 #include <windows.h>
17646 #include <winerror.h>
17647 static LONG WINAPI
17648 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17650 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17652 case EXCEPTION_ACCESS_VIOLATION:
17653 case EXCEPTION_IN_PAGE_ERROR:
17654 case EXCEPTION_STACK_OVERFLOW:
17655 case EXCEPTION_GUARD_PAGE:
17656 case EXCEPTION_PRIV_INSTRUCTION:
17657 case EXCEPTION_ILLEGAL_INSTRUCTION:
17658 case EXCEPTION_DATATYPE_MISALIGNMENT:
17659 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17660 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17661 exit (1);
17663 return EXCEPTION_CONTINUE_SEARCH;
17665 static void
17666 nocrash_init (void)
17668 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17670 #else
17671 /* Avoid a crash on POSIX systems. */
17672 #include <signal.h>
17673 /* A POSIX signal handler. */
17674 static void
17675 exception_handler (int sig)
17677 exit (1);
17679 static void
17680 nocrash_init (void)
17682 #ifdef SIGSEGV
17683 signal (SIGSEGV, exception_handler);
17684 #endif
17685 #ifdef SIGBUS
17686 signal (SIGBUS, exception_handler);
17687 #endif
17689 #endif
17693 main ()
17696 int result = 0;
17698 nocrash_init();
17700 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17701 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17702 OSF/1 5.1, Solaris 10. */
17704 static char conftest[] = "conftest";
17705 static char plus[] = "-+";
17706 char *argv[3] = { conftest, plus, NULL };
17707 opterr = 0;
17708 if (getopt (2, argv, "+a") != '?')
17709 result |= 1;
17711 /* This code succeeds on glibc 2.8, mingw,
17712 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17713 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17715 static char program[] = "program";
17716 static char p[] = "-p";
17717 static char foo[] = "foo";
17718 static char bar[] = "bar";
17719 char *argv[] = { program, p, foo, bar, NULL };
17721 optind = 1;
17722 if (getopt (4, argv, "p::") != 'p')
17723 result |= 2;
17724 else if (optarg != NULL)
17725 result |= 4;
17726 else if (getopt (4, argv, "p::") != -1)
17727 result |= 6;
17728 else if (optind != 2)
17729 result |= 8;
17731 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17733 static char program[] = "program";
17734 static char foo[] = "foo";
17735 static char p[] = "-p";
17736 char *argv[] = { program, foo, p, NULL };
17737 optind = 0;
17738 if (getopt (3, argv, "-p") != 1)
17739 result |= 16;
17740 else if (getopt (3, argv, "-p") != 'p')
17741 result |= 16;
17743 /* This code fails on glibc 2.11. */
17745 static char program[] = "program";
17746 static char b[] = "-b";
17747 static char a[] = "-a";
17748 char *argv[] = { program, b, a, NULL };
17749 optind = opterr = 0;
17750 if (getopt (3, argv, "+:a:b") != 'b')
17751 result |= 32;
17752 else if (getopt (3, argv, "+:a:b") != ':')
17753 result |= 32;
17755 /* This code dumps core on glibc 2.14. */
17757 static char program[] = "program";
17758 static char w[] = "-W";
17759 static char dummy[] = "dummy";
17760 char *argv[] = { program, w, dummy, NULL };
17761 optind = opterr = 1;
17762 if (getopt (3, argv, "W;") != 'W')
17763 result |= 64;
17765 return result;
17768 return 0;
17770 _ACEOF
17771 if ac_fn_c_try_run "$LINENO"; then :
17772 gl_cv_func_getopt_gnu=yes
17773 else
17774 gl_cv_func_getopt_gnu=no
17776 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17777 conftest.$ac_objext conftest.beam conftest.$ac_ext
17780 case $gl_had_POSIXLY_CORRECT in
17781 exported) ;;
17782 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17783 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17784 esac
17787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17788 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17789 if test "$gl_cv_func_getopt_gnu" != yes; then
17790 gl_replace_getopt=yes
17791 else
17792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17793 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17794 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17795 $as_echo_n "(cached) " >&6
17796 else
17797 if test "$cross_compiling" = yes; then :
17798 case "$host_os" in
17799 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17800 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17801 esac
17803 else
17804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17805 /* end confdefs.h. */
17806 #include <getopt.h>
17807 #include <stddef.h>
17808 #include <string.h>
17811 main ()
17813 static const struct option long_options[] =
17815 { "xtremely-",no_argument, NULL, 1003 },
17816 { "xtra", no_argument, NULL, 1001 },
17817 { "xtreme", no_argument, NULL, 1002 },
17818 { "xtremely", no_argument, NULL, 1003 },
17819 { NULL, 0, NULL, 0 }
17821 /* This code fails on OpenBSD 5.0. */
17823 static char program[] = "program";
17824 static char xtremel[] = "--xtremel";
17825 char *argv[] = { program, xtremel, NULL };
17826 int option_index;
17827 optind = 1; opterr = 0;
17828 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17829 return 1;
17831 return 0;
17834 return 0;
17836 _ACEOF
17837 if ac_fn_c_try_run "$LINENO"; then :
17838 gl_cv_func_getopt_long_gnu=yes
17839 else
17840 gl_cv_func_getopt_long_gnu=no
17842 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17843 conftest.$ac_objext conftest.beam conftest.$ac_ext
17848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17849 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17850 case "$gl_cv_func_getopt_long_gnu" in
17851 *yes) ;;
17852 *) gl_replace_getopt=yes ;;
17853 esac
17862 REPLACE_GETOPT=0
17863 if test -n "$gl_replace_getopt"; then
17864 REPLACE_GETOPT=1
17867 if test $REPLACE_GETOPT = 1; then
17869 GETOPT_H=getopt.h
17871 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17877 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17878 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17879 ac_have_decl=1
17880 else
17881 ac_have_decl=0
17884 cat >>confdefs.h <<_ACEOF
17885 #define HAVE_DECL_GETENV $ac_have_decl
17886 _ACEOF
17893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17894 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17895 if test "${ac_cv_c_restrict+set}" = set; then :
17896 $as_echo_n "(cached) " >&6
17897 else
17898 ac_cv_c_restrict=no
17899 # The order here caters to the fact that C++ does not require restrict.
17900 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17902 /* end confdefs.h. */
17903 typedef int * int_ptr;
17904 int foo (int_ptr $ac_kw ip) {
17905 return ip[0];
17908 main ()
17910 int s[1];
17911 int * $ac_kw t = s;
17912 t[0] = 0;
17913 return foo(t)
17915 return 0;
17917 _ACEOF
17918 if ac_fn_c_try_compile "$LINENO"; then :
17919 ac_cv_c_restrict=$ac_kw
17921 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17922 test "$ac_cv_c_restrict" != no && break
17923 done
17926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17927 $as_echo "$ac_cv_c_restrict" >&6; }
17929 case $ac_cv_c_restrict in
17930 restrict) ;;
17931 no) $as_echo "#define restrict /**/" >>confdefs.h
17933 *) cat >>confdefs.h <<_ACEOF
17934 #define restrict $ac_cv_c_restrict
17935 _ACEOF
17937 esac
17940 GNULIB_GETTIMEOFDAY=0;
17941 HAVE_GETTIMEOFDAY=1;
17942 HAVE_STRUCT_TIMEVAL=1;
17943 HAVE_SYS_TIME_H=1;
17944 REPLACE_GETTIMEOFDAY=0;
17945 REPLACE_STRUCT_TIMEVAL=0;
17962 if test $gl_cv_have_include_next = yes; then
17963 gl_cv_next_sys_time_h='<'sys/time.h'>'
17964 else
17965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17966 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17967 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17968 $as_echo_n "(cached) " >&6
17969 else
17971 if test $ac_cv_header_sys_time_h = yes; then
17974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17975 /* end confdefs.h. */
17976 #include <sys/time.h>
17978 _ACEOF
17979 case "$host_os" in
17980 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17981 *) gl_absname_cpp="$ac_cpp" ;;
17982 esac
17984 case "$host_os" in
17985 mingw*)
17986 gl_dirsep_regex='[/\\]'
17989 gl_dirsep_regex='\/'
17991 esac
17992 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17994 gl_header_literal_regex=`echo 'sys/time.h' \
17995 | sed -e "$gl_make_literal_regex_sed"`
17996 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17997 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17998 s|^/[^/]|//&|
18002 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18003 sed -n "$gl_absolute_header_sed"`'"'
18004 else
18005 gl_cv_next_sys_time_h='<'sys/time.h'>'
18010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
18011 $as_echo "$gl_cv_next_sys_time_h" >&6; }
18013 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
18015 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18016 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18017 gl_next_as_first_directive='<'sys/time.h'>'
18018 else
18019 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18020 gl_next_as_first_directive=$gl_cv_next_sys_time_h
18022 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
18028 if test $ac_cv_header_sys_time_h != yes; then
18029 HAVE_SYS_TIME_H=0
18036 if test $ac_cv_header_sys_socket_h != yes; then
18037 for ac_header in winsock2.h
18038 do :
18039 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
18040 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
18041 cat >>confdefs.h <<_ACEOF
18042 #define HAVE_WINSOCK2_H 1
18043 _ACEOF
18047 done
18050 if test "$ac_cv_header_winsock2_h" = yes; then
18051 HAVE_WINSOCK2_H=1
18052 UNISTD_H_HAVE_WINSOCK2_H=1
18053 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
18054 else
18055 HAVE_WINSOCK2_H=0
18059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
18060 $as_echo_n "checking for struct timeval... " >&6; }
18061 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
18062 $as_echo_n "(cached) " >&6
18063 else
18064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18065 /* end confdefs.h. */
18066 #if HAVE_SYS_TIME_H
18067 #include <sys/time.h>
18068 #endif
18069 #include <time.h>
18070 #if HAVE_WINSOCK2_H
18071 # include <winsock2.h>
18072 #endif
18075 main ()
18077 static struct timeval x; x.tv_sec = x.tv_usec;
18079 return 0;
18081 _ACEOF
18082 if ac_fn_c_try_compile "$LINENO"; then :
18083 gl_cv_sys_struct_timeval=yes
18084 else
18085 gl_cv_sys_struct_timeval=no
18087 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
18091 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
18092 if test $gl_cv_sys_struct_timeval != yes; then
18093 HAVE_STRUCT_TIMEVAL=0
18094 else
18095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
18096 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
18097 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
18098 $as_echo_n "(cached) " >&6
18099 else
18100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18101 /* end confdefs.h. */
18102 #if HAVE_SYS_TIME_H
18103 #include <sys/time.h>
18104 #endif
18105 #include <time.h>
18106 #if HAVE_WINSOCK2_H
18107 # include <winsock2.h>
18108 #endif
18111 main ()
18113 static struct timeval x;
18114 typedef int verify_tv_sec_type[
18115 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
18119 return 0;
18121 _ACEOF
18122 if ac_fn_c_try_compile "$LINENO"; then :
18123 gl_cv_sys_struct_timeval_tv_sec=yes
18124 else
18125 gl_cv_sys_struct_timeval_tv_sec=no
18127 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
18131 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
18132 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
18133 REPLACE_STRUCT_TIMEVAL=1
18143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
18144 $as_echo_n "checking for unsigned long long int... " >&6; }
18145 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
18146 $as_echo_n "(cached) " >&6
18147 else
18148 ac_cv_type_unsigned_long_long_int=yes
18149 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18151 /* end confdefs.h. */
18153 /* For now, do not test the preprocessor; as of 2007 there are too many
18154 implementations with broken preprocessors. Perhaps this can
18155 be revisited in 2012. In the meantime, code should not expect
18156 #if to work with literals wider than 32 bits. */
18157 /* Test literals. */
18158 long long int ll = 9223372036854775807ll;
18159 long long int nll = -9223372036854775807LL;
18160 unsigned long long int ull = 18446744073709551615ULL;
18161 /* Test constant expressions. */
18162 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
18163 ? 1 : -1)];
18164 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
18165 ? 1 : -1)];
18166 int i = 63;
18168 main ()
18170 /* Test availability of runtime routines for shift and division. */
18171 long long int llmax = 9223372036854775807ll;
18172 unsigned long long int ullmax = 18446744073709551615ull;
18173 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
18174 | (llmax / ll) | (llmax % ll)
18175 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
18176 | (ullmax / ull) | (ullmax % ull));
18178 return 0;
18181 _ACEOF
18182 if ac_fn_c_try_link "$LINENO"; then :
18184 else
18185 ac_cv_type_unsigned_long_long_int=no
18187 rm -f core conftest.err conftest.$ac_objext \
18188 conftest$ac_exeext conftest.$ac_ext
18191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
18192 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
18193 if test $ac_cv_type_unsigned_long_long_int = yes; then
18195 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
18201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
18202 $as_echo_n "checking for long long int... " >&6; }
18203 if test "${ac_cv_type_long_long_int+set}" = set; then :
18204 $as_echo_n "(cached) " >&6
18205 else
18206 ac_cv_type_long_long_int=yes
18207 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18208 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
18209 if test $ac_cv_type_long_long_int = yes; then
18210 if test "$cross_compiling" = yes; then :
18212 else
18213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18214 /* end confdefs.h. */
18215 #include <limits.h>
18216 #ifndef LLONG_MAX
18217 # define HALF \
18218 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
18219 # define LLONG_MAX (HALF - 1 + HALF)
18220 #endif
18222 main ()
18224 long long int n = 1;
18225 int i;
18226 for (i = 0; ; i++)
18228 long long int m = n << i;
18229 if (m >> i != n)
18230 return 1;
18231 if (LLONG_MAX / 2 < m)
18232 break;
18234 return 0;
18236 return 0;
18238 _ACEOF
18239 if ac_fn_c_try_run "$LINENO"; then :
18241 else
18242 ac_cv_type_long_long_int=no
18244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18245 conftest.$ac_objext conftest.beam conftest.$ac_ext
18251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
18252 $as_echo "$ac_cv_type_long_long_int" >&6; }
18253 if test $ac_cv_type_long_long_int = yes; then
18255 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
18264 gl_cv_c_multiarch=no
18265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18266 /* end confdefs.h. */
18267 #ifndef __APPLE_CC__
18268 not a universal capable compiler
18269 #endif
18270 typedef int dummy;
18272 _ACEOF
18273 if ac_fn_c_try_compile "$LINENO"; then :
18275 arch=
18276 prev=
18277 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
18278 if test -n "$prev"; then
18279 case $word in
18280 i?86 | x86_64 | ppc | ppc64)
18281 if test -z "$arch" || test "$arch" = "$word"; then
18282 arch="$word"
18283 else
18284 gl_cv_c_multiarch=yes
18287 esac
18288 prev=
18289 else
18290 if test "x$word" = "x-arch"; then
18291 prev=arch
18294 done
18297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18298 if test $gl_cv_c_multiarch = yes; then
18299 APPLE_UNIVERSAL_BUILD=1
18300 else
18301 APPLE_UNIVERSAL_BUILD=0
18308 if test $ac_cv_type_long_long_int = yes; then
18309 HAVE_LONG_LONG_INT=1
18310 else
18311 HAVE_LONG_LONG_INT=0
18315 if test $ac_cv_type_unsigned_long_long_int = yes; then
18316 HAVE_UNSIGNED_LONG_LONG_INT=1
18317 else
18318 HAVE_UNSIGNED_LONG_LONG_INT=0
18323 if test $ac_cv_header_wchar_h = yes; then
18324 HAVE_WCHAR_H=1
18325 else
18326 HAVE_WCHAR_H=0
18330 if test $ac_cv_header_inttypes_h = yes; then
18331 HAVE_INTTYPES_H=1
18332 else
18333 HAVE_INTTYPES_H=0
18337 if test $ac_cv_header_sys_types_h = yes; then
18338 HAVE_SYS_TYPES_H=1
18339 else
18340 HAVE_SYS_TYPES_H=0
18353 if test $gl_cv_have_include_next = yes; then
18354 gl_cv_next_stdint_h='<'stdint.h'>'
18355 else
18356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
18357 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
18358 if test "${gl_cv_next_stdint_h+set}" = set; then :
18359 $as_echo_n "(cached) " >&6
18360 else
18362 if test $ac_cv_header_stdint_h = yes; then
18365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18366 /* end confdefs.h. */
18367 #include <stdint.h>
18369 _ACEOF
18370 case "$host_os" in
18371 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18372 *) gl_absname_cpp="$ac_cpp" ;;
18373 esac
18375 case "$host_os" in
18376 mingw*)
18377 gl_dirsep_regex='[/\\]'
18380 gl_dirsep_regex='\/'
18382 esac
18383 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18385 gl_header_literal_regex=`echo 'stdint.h' \
18386 | sed -e "$gl_make_literal_regex_sed"`
18387 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18388 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18389 s|^/[^/]|//&|
18393 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18394 sed -n "$gl_absolute_header_sed"`'"'
18395 else
18396 gl_cv_next_stdint_h='<'stdint.h'>'
18401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18402 $as_echo "$gl_cv_next_stdint_h" >&6; }
18404 NEXT_STDINT_H=$gl_cv_next_stdint_h
18406 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18407 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18408 gl_next_as_first_directive='<'stdint.h'>'
18409 else
18410 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18411 gl_next_as_first_directive=$gl_cv_next_stdint_h
18413 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18418 if test $ac_cv_header_stdint_h = yes; then
18419 HAVE_STDINT_H=1
18420 else
18421 HAVE_STDINT_H=0
18425 if test $ac_cv_header_stdint_h = yes; then
18426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18427 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18428 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18429 $as_echo_n "(cached) " >&6
18430 else
18431 gl_cv_header_working_stdint_h=no
18432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18433 /* end confdefs.h. */
18436 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18437 #include <stdint.h>
18438 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18439 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18440 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18441 #endif
18444 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18445 included before <wchar.h>. */
18446 #include <stddef.h>
18447 #include <signal.h>
18448 #if HAVE_WCHAR_H
18449 # include <stdio.h>
18450 # include <time.h>
18451 # include <wchar.h>
18452 #endif
18455 #ifdef INT8_MAX
18456 int8_t a1 = INT8_MAX;
18457 int8_t a1min = INT8_MIN;
18458 #endif
18459 #ifdef INT16_MAX
18460 int16_t a2 = INT16_MAX;
18461 int16_t a2min = INT16_MIN;
18462 #endif
18463 #ifdef INT32_MAX
18464 int32_t a3 = INT32_MAX;
18465 int32_t a3min = INT32_MIN;
18466 #endif
18467 #ifdef INT64_MAX
18468 int64_t a4 = INT64_MAX;
18469 int64_t a4min = INT64_MIN;
18470 #endif
18471 #ifdef UINT8_MAX
18472 uint8_t b1 = UINT8_MAX;
18473 #else
18474 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18475 #endif
18476 #ifdef UINT16_MAX
18477 uint16_t b2 = UINT16_MAX;
18478 #endif
18479 #ifdef UINT32_MAX
18480 uint32_t b3 = UINT32_MAX;
18481 #endif
18482 #ifdef UINT64_MAX
18483 uint64_t b4 = UINT64_MAX;
18484 #endif
18485 int_least8_t c1 = INT8_C (0x7f);
18486 int_least8_t c1max = INT_LEAST8_MAX;
18487 int_least8_t c1min = INT_LEAST8_MIN;
18488 int_least16_t c2 = INT16_C (0x7fff);
18489 int_least16_t c2max = INT_LEAST16_MAX;
18490 int_least16_t c2min = INT_LEAST16_MIN;
18491 int_least32_t c3 = INT32_C (0x7fffffff);
18492 int_least32_t c3max = INT_LEAST32_MAX;
18493 int_least32_t c3min = INT_LEAST32_MIN;
18494 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18495 int_least64_t c4max = INT_LEAST64_MAX;
18496 int_least64_t c4min = INT_LEAST64_MIN;
18497 uint_least8_t d1 = UINT8_C (0xff);
18498 uint_least8_t d1max = UINT_LEAST8_MAX;
18499 uint_least16_t d2 = UINT16_C (0xffff);
18500 uint_least16_t d2max = UINT_LEAST16_MAX;
18501 uint_least32_t d3 = UINT32_C (0xffffffff);
18502 uint_least32_t d3max = UINT_LEAST32_MAX;
18503 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18504 uint_least64_t d4max = UINT_LEAST64_MAX;
18505 int_fast8_t e1 = INT_FAST8_MAX;
18506 int_fast8_t e1min = INT_FAST8_MIN;
18507 int_fast16_t e2 = INT_FAST16_MAX;
18508 int_fast16_t e2min = INT_FAST16_MIN;
18509 int_fast32_t e3 = INT_FAST32_MAX;
18510 int_fast32_t e3min = INT_FAST32_MIN;
18511 int_fast64_t e4 = INT_FAST64_MAX;
18512 int_fast64_t e4min = INT_FAST64_MIN;
18513 uint_fast8_t f1 = UINT_FAST8_MAX;
18514 uint_fast16_t f2 = UINT_FAST16_MAX;
18515 uint_fast32_t f3 = UINT_FAST32_MAX;
18516 uint_fast64_t f4 = UINT_FAST64_MAX;
18517 #ifdef INTPTR_MAX
18518 intptr_t g = INTPTR_MAX;
18519 intptr_t gmin = INTPTR_MIN;
18520 #endif
18521 #ifdef UINTPTR_MAX
18522 uintptr_t h = UINTPTR_MAX;
18523 #endif
18524 intmax_t i = INTMAX_MAX;
18525 uintmax_t j = UINTMAX_MAX;
18527 #include <limits.h> /* for CHAR_BIT */
18528 #define TYPE_MINIMUM(t) \
18529 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18530 #define TYPE_MAXIMUM(t) \
18531 ((t) ((t) 0 < (t) -1 \
18532 ? (t) -1 \
18533 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18534 struct s {
18535 int check_PTRDIFF:
18536 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18537 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18538 ? 1 : -1;
18539 /* Detect bug in FreeBSD 6.0 / ia64. */
18540 int check_SIG_ATOMIC:
18541 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18542 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18543 ? 1 : -1;
18544 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18545 int check_WCHAR:
18546 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18547 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18548 ? 1 : -1;
18549 /* Detect bug in mingw. */
18550 int check_WINT:
18551 WINT_MIN == TYPE_MINIMUM (wint_t)
18552 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18553 ? 1 : -1;
18555 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18556 int check_UINT8_C:
18557 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18558 int check_UINT16_C:
18559 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18561 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18562 #ifdef UINT8_MAX
18563 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18564 #endif
18565 #ifdef UINT16_MAX
18566 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18567 #endif
18568 #ifdef UINT32_MAX
18569 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18570 #endif
18571 #ifdef UINT64_MAX
18572 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18573 #endif
18574 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18575 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18576 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18577 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18578 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18579 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18580 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18581 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18582 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18583 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18584 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18588 main ()
18592 return 0;
18594 _ACEOF
18595 if ac_fn_c_try_compile "$LINENO"; then :
18596 if test "$cross_compiling" = yes; then :
18597 gl_cv_header_working_stdint_h=yes
18599 else
18600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18601 /* end confdefs.h. */
18604 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18605 #include <stdint.h>
18608 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18609 included before <wchar.h>. */
18610 #include <stddef.h>
18611 #include <signal.h>
18612 #if HAVE_WCHAR_H
18613 # include <stdio.h>
18614 # include <time.h>
18615 # include <wchar.h>
18616 #endif
18619 #include <stdio.h>
18620 #include <string.h>
18621 #define MVAL(macro) MVAL1(macro)
18622 #define MVAL1(expression) #expression
18623 static const char *macro_values[] =
18625 #ifdef INT8_MAX
18626 MVAL (INT8_MAX),
18627 #endif
18628 #ifdef INT16_MAX
18629 MVAL (INT16_MAX),
18630 #endif
18631 #ifdef INT32_MAX
18632 MVAL (INT32_MAX),
18633 #endif
18634 #ifdef INT64_MAX
18635 MVAL (INT64_MAX),
18636 #endif
18637 #ifdef UINT8_MAX
18638 MVAL (UINT8_MAX),
18639 #endif
18640 #ifdef UINT16_MAX
18641 MVAL (UINT16_MAX),
18642 #endif
18643 #ifdef UINT32_MAX
18644 MVAL (UINT32_MAX),
18645 #endif
18646 #ifdef UINT64_MAX
18647 MVAL (UINT64_MAX),
18648 #endif
18649 NULL
18653 main ()
18656 const char **mv;
18657 for (mv = macro_values; *mv != NULL; mv++)
18659 const char *value = *mv;
18660 /* Test whether it looks like a cast expression. */
18661 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18662 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18663 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18664 || strncmp (value, "((int)"/*)*/, 6) == 0
18665 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18666 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18667 return mv - macro_values + 1;
18669 return 0;
18672 return 0;
18674 _ACEOF
18675 if ac_fn_c_try_run "$LINENO"; then :
18676 gl_cv_header_working_stdint_h=yes
18678 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18679 conftest.$ac_objext conftest.beam conftest.$ac_ext
18684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18688 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18690 if test "$gl_cv_header_working_stdint_h" = yes; then
18691 STDINT_H=
18692 else
18693 for ac_header in sys/inttypes.h sys/bitypes.h
18694 do :
18695 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18696 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18697 eval as_val=\$$as_ac_Header
18698 if test "x$as_val" = x""yes; then :
18699 cat >>confdefs.h <<_ACEOF
18700 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18701 _ACEOF
18705 done
18707 if test $ac_cv_header_sys_inttypes_h = yes; then
18708 HAVE_SYS_INTTYPES_H=1
18709 else
18710 HAVE_SYS_INTTYPES_H=0
18713 if test $ac_cv_header_sys_bitypes_h = yes; then
18714 HAVE_SYS_BITYPES_H=1
18715 else
18716 HAVE_SYS_BITYPES_H=0
18722 if test $APPLE_UNIVERSAL_BUILD = 0; then
18725 for gltype in ptrdiff_t size_t ; do
18726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18727 $as_echo_n "checking for bit size of $gltype... " >&6; }
18728 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18729 $as_echo_n "(cached) " >&6
18730 else
18731 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18732 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18733 included before <wchar.h>. */
18734 #include <stddef.h>
18735 #include <signal.h>
18736 #if HAVE_WCHAR_H
18737 # include <stdio.h>
18738 # include <time.h>
18739 # include <wchar.h>
18740 #endif
18742 #include <limits.h>"; then :
18744 else
18745 result=unknown
18748 eval gl_cv_bitsizeof_${gltype}=\$result
18751 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18753 $as_echo "$ac_res" >&6; }
18754 eval result=\$gl_cv_bitsizeof_${gltype}
18755 if test $result = unknown; then
18756 result=0
18758 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18759 cat >>confdefs.h <<_ACEOF
18760 #define BITSIZEOF_${GLTYPE} $result
18761 _ACEOF
18763 eval BITSIZEOF_${GLTYPE}=\$result
18764 done
18770 for gltype in sig_atomic_t wchar_t wint_t ; do
18771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18772 $as_echo_n "checking for bit size of $gltype... " >&6; }
18773 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18774 $as_echo_n "(cached) " >&6
18775 else
18776 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18777 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18778 included before <wchar.h>. */
18779 #include <stddef.h>
18780 #include <signal.h>
18781 #if HAVE_WCHAR_H
18782 # include <stdio.h>
18783 # include <time.h>
18784 # include <wchar.h>
18785 #endif
18787 #include <limits.h>"; then :
18789 else
18790 result=unknown
18793 eval gl_cv_bitsizeof_${gltype}=\$result
18796 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18798 $as_echo "$ac_res" >&6; }
18799 eval result=\$gl_cv_bitsizeof_${gltype}
18800 if test $result = unknown; then
18801 result=0
18803 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18804 cat >>confdefs.h <<_ACEOF
18805 #define BITSIZEOF_${GLTYPE} $result
18806 _ACEOF
18808 eval BITSIZEOF_${GLTYPE}=\$result
18809 done
18814 for gltype in sig_atomic_t wchar_t wint_t ; do
18815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18816 $as_echo_n "checking whether $gltype is signed... " >&6; }
18817 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18818 $as_echo_n "(cached) " >&6
18819 else
18820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18821 /* end confdefs.h. */
18823 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18824 included before <wchar.h>. */
18825 #include <stddef.h>
18826 #include <signal.h>
18827 #if HAVE_WCHAR_H
18828 # include <stdio.h>
18829 # include <time.h>
18830 # include <wchar.h>
18831 #endif
18833 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18835 main ()
18839 return 0;
18841 _ACEOF
18842 if ac_fn_c_try_compile "$LINENO"; then :
18843 result=yes
18844 else
18845 result=no
18847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18848 eval gl_cv_type_${gltype}_signed=\$result
18851 eval ac_res=\$gl_cv_type_${gltype}_signed
18852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18853 $as_echo "$ac_res" >&6; }
18854 eval result=\$gl_cv_type_${gltype}_signed
18855 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18856 if test "$result" = yes; then
18857 cat >>confdefs.h <<_ACEOF
18858 #define HAVE_SIGNED_${GLTYPE} 1
18859 _ACEOF
18861 eval HAVE_SIGNED_${GLTYPE}=1
18862 else
18863 eval HAVE_SIGNED_${GLTYPE}=0
18865 done
18868 gl_cv_type_ptrdiff_t_signed=yes
18869 gl_cv_type_size_t_signed=no
18870 if test $APPLE_UNIVERSAL_BUILD = 0; then
18873 for gltype in ptrdiff_t size_t ; do
18874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18875 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18876 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18877 $as_echo_n "(cached) " >&6
18878 else
18879 eval gl_cv_type_${gltype}_suffix=no
18880 eval result=\$gl_cv_type_${gltype}_signed
18881 if test "$result" = yes; then
18882 glsufu=
18883 else
18884 glsufu=u
18886 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18887 case $glsuf in
18888 '') gltype1='int';;
18889 l) gltype1='long int';;
18890 ll) gltype1='long long int';;
18891 i64) gltype1='__int64';;
18892 u) gltype1='unsigned int';;
18893 ul) gltype1='unsigned long int';;
18894 ull) gltype1='unsigned long long int';;
18895 ui64)gltype1='unsigned __int64';;
18896 esac
18897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18898 /* end confdefs.h. */
18900 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18901 included before <wchar.h>. */
18902 #include <stddef.h>
18903 #include <signal.h>
18904 #if HAVE_WCHAR_H
18905 # include <stdio.h>
18906 # include <time.h>
18907 # include <wchar.h>
18908 #endif
18910 extern $gltype foo;
18911 extern $gltype1 foo;
18913 main ()
18917 return 0;
18919 _ACEOF
18920 if ac_fn_c_try_compile "$LINENO"; then :
18921 eval gl_cv_type_${gltype}_suffix=\$glsuf
18923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18924 eval result=\$gl_cv_type_${gltype}_suffix
18925 test "$result" != no && break
18926 done
18928 eval ac_res=\$gl_cv_type_${gltype}_suffix
18929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18930 $as_echo "$ac_res" >&6; }
18931 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18932 eval result=\$gl_cv_type_${gltype}_suffix
18933 test "$result" = no && result=
18934 eval ${GLTYPE}_SUFFIX=\$result
18935 cat >>confdefs.h <<_ACEOF
18936 #define ${GLTYPE}_SUFFIX $result
18937 _ACEOF
18939 done
18945 for gltype in sig_atomic_t wchar_t wint_t ; do
18946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18947 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18948 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18949 $as_echo_n "(cached) " >&6
18950 else
18951 eval gl_cv_type_${gltype}_suffix=no
18952 eval result=\$gl_cv_type_${gltype}_signed
18953 if test "$result" = yes; then
18954 glsufu=
18955 else
18956 glsufu=u
18958 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18959 case $glsuf in
18960 '') gltype1='int';;
18961 l) gltype1='long int';;
18962 ll) gltype1='long long int';;
18963 i64) gltype1='__int64';;
18964 u) gltype1='unsigned int';;
18965 ul) gltype1='unsigned long int';;
18966 ull) gltype1='unsigned long long int';;
18967 ui64)gltype1='unsigned __int64';;
18968 esac
18969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18970 /* end confdefs.h. */
18972 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18973 included before <wchar.h>. */
18974 #include <stddef.h>
18975 #include <signal.h>
18976 #if HAVE_WCHAR_H
18977 # include <stdio.h>
18978 # include <time.h>
18979 # include <wchar.h>
18980 #endif
18982 extern $gltype foo;
18983 extern $gltype1 foo;
18985 main ()
18989 return 0;
18991 _ACEOF
18992 if ac_fn_c_try_compile "$LINENO"; then :
18993 eval gl_cv_type_${gltype}_suffix=\$glsuf
18995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18996 eval result=\$gl_cv_type_${gltype}_suffix
18997 test "$result" != no && break
18998 done
19000 eval ac_res=\$gl_cv_type_${gltype}_suffix
19001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
19002 $as_echo "$ac_res" >&6; }
19003 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
19004 eval result=\$gl_cv_type_${gltype}_suffix
19005 test "$result" = no && result=
19006 eval ${GLTYPE}_SUFFIX=\$result
19007 cat >>confdefs.h <<_ACEOF
19008 #define ${GLTYPE}_SUFFIX $result
19009 _ACEOF
19011 done
19015 if test $BITSIZEOF_WINT_T -lt 32; then
19016 BITSIZEOF_WINT_T=32
19019 STDINT_H=stdint.h
19022 if test -n "$STDINT_H"; then
19023 GL_GENERATE_STDINT_H_TRUE=
19024 GL_GENERATE_STDINT_H_FALSE='#'
19025 else
19026 GL_GENERATE_STDINT_H_TRUE='#'
19027 GL_GENERATE_STDINT_H_FALSE=
19034 GNULIB_IMAXABS=0;
19035 GNULIB_IMAXDIV=0;
19036 GNULIB_STRTOIMAX=0;
19037 GNULIB_STRTOUMAX=0;
19038 HAVE_DECL_IMAXABS=1;
19039 HAVE_DECL_IMAXDIV=1;
19040 HAVE_DECL_STRTOIMAX=1;
19041 HAVE_DECL_STRTOUMAX=1;
19042 REPLACE_STRTOIMAX=0;
19043 INT32_MAX_LT_INTMAX_MAX=1;
19044 INT64_MAX_EQ_LONG_MAX='defined _LP64';
19045 PRI_MACROS_BROKEN=0;
19046 PRIPTR_PREFIX=__PRIPTR_PREFIX;
19047 UINT32_MAX_LT_UINTMAX_MAX=1;
19048 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
19064 if test $gl_cv_have_include_next = yes; then
19065 gl_cv_next_inttypes_h='<'inttypes.h'>'
19066 else
19067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
19068 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
19069 if test "${gl_cv_next_inttypes_h+set}" = set; then :
19070 $as_echo_n "(cached) " >&6
19071 else
19073 if test $ac_cv_header_inttypes_h = yes; then
19076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19077 /* end confdefs.h. */
19078 #include <inttypes.h>
19080 _ACEOF
19081 case "$host_os" in
19082 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19083 *) gl_absname_cpp="$ac_cpp" ;;
19084 esac
19086 case "$host_os" in
19087 mingw*)
19088 gl_dirsep_regex='[/\\]'
19091 gl_dirsep_regex='\/'
19093 esac
19094 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19096 gl_header_literal_regex=`echo 'inttypes.h' \
19097 | sed -e "$gl_make_literal_regex_sed"`
19098 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19099 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19100 s|^/[^/]|//&|
19104 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19105 sed -n "$gl_absolute_header_sed"`'"'
19106 else
19107 gl_cv_next_inttypes_h='<'inttypes.h'>'
19112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
19113 $as_echo "$gl_cv_next_inttypes_h" >&6; }
19115 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
19117 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19118 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19119 gl_next_as_first_directive='<'inttypes.h'>'
19120 else
19121 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19122 gl_next_as_first_directive=$gl_cv_next_inttypes_h
19124 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
19136 case "$host_os" in
19137 mingw*)
19138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
19139 $as_echo_n "checking for 64-bit off_t... " >&6; }
19140 if test "${gl_cv_type_off_t_64+set}" = set; then :
19141 $as_echo_n "(cached) " >&6
19142 else
19143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19144 /* end confdefs.h. */
19145 #include <sys/types.h>
19146 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
19149 main ()
19153 return 0;
19155 _ACEOF
19156 if ac_fn_c_try_compile "$LINENO"; then :
19157 gl_cv_type_off_t_64=yes
19158 else
19159 gl_cv_type_off_t_64=no
19161 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
19165 $as_echo "$gl_cv_type_off_t_64" >&6; }
19166 if test $gl_cv_type_off_t_64 = no; then
19167 WINDOWS_64_BIT_OFF_T=1
19168 else
19169 WINDOWS_64_BIT_OFF_T=0
19171 WINDOWS_64_BIT_ST_SIZE=1
19174 WINDOWS_64_BIT_OFF_T=0
19175 WINDOWS_64_BIT_ST_SIZE=0
19177 esac
19180 GNULIB_FCHMODAT=0;
19181 GNULIB_FSTAT=0;
19182 GNULIB_FSTATAT=0;
19183 GNULIB_FUTIMENS=0;
19184 GNULIB_LCHMOD=0;
19185 GNULIB_LSTAT=0;
19186 GNULIB_MKDIRAT=0;
19187 GNULIB_MKFIFO=0;
19188 GNULIB_MKFIFOAT=0;
19189 GNULIB_MKNOD=0;
19190 GNULIB_MKNODAT=0;
19191 GNULIB_STAT=0;
19192 GNULIB_UTIMENSAT=0;
19193 HAVE_FCHMODAT=1;
19194 HAVE_FSTATAT=1;
19195 HAVE_FUTIMENS=1;
19196 HAVE_LCHMOD=1;
19197 HAVE_LSTAT=1;
19198 HAVE_MKDIRAT=1;
19199 HAVE_MKFIFO=1;
19200 HAVE_MKFIFOAT=1;
19201 HAVE_MKNOD=1;
19202 HAVE_MKNODAT=1;
19203 HAVE_UTIMENSAT=1;
19204 REPLACE_FSTAT=0;
19205 REPLACE_FSTATAT=0;
19206 REPLACE_FUTIMENS=0;
19207 REPLACE_LSTAT=0;
19208 REPLACE_MKDIR=0;
19209 REPLACE_MKFIFO=0;
19210 REPLACE_MKNOD=0;
19211 REPLACE_STAT=0;
19212 REPLACE_UTIMENSAT=0;
19217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
19218 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
19219 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
19220 $as_echo_n "(cached) " >&6
19221 else
19222 rm -f conftest.sym conftest.file
19223 echo >conftest.file
19224 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
19225 if test "$cross_compiling" = yes; then :
19226 case "$host_os" in
19227 # Guess yes on glibc systems.
19228 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
19229 # If we don't know, assume the worst.
19230 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
19231 esac
19233 else
19234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19235 /* end confdefs.h. */
19236 $ac_includes_default
19238 main ()
19240 struct stat sbuf;
19241 /* Linux will dereference the symlink and fail, as required by
19242 POSIX. That is better in the sense that it means we will not
19243 have to compile and use the lstat wrapper. */
19244 return lstat ("conftest.sym/", &sbuf) == 0;
19247 return 0;
19249 _ACEOF
19250 if ac_fn_c_try_run "$LINENO"; then :
19251 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19252 else
19253 gl_cv_func_lstat_dereferences_slashed_symlink=no
19255 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19256 conftest.$ac_objext conftest.beam conftest.$ac_ext
19259 else
19260 # If the 'ln -s' command failed, then we probably don't even
19261 # have an lstat function.
19262 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19264 rm -f conftest.sym conftest.file
19267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19268 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19269 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19270 *yes)
19272 cat >>confdefs.h <<_ACEOF
19273 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19274 _ACEOF
19277 esac
19280 GNULIB_MKTIME=0;
19281 GNULIB_NANOSLEEP=0;
19282 GNULIB_STRPTIME=0;
19283 GNULIB_TIMEGM=0;
19284 GNULIB_TIME_R=0;
19285 HAVE_DECL_LOCALTIME_R=1;
19286 HAVE_NANOSLEEP=1;
19287 HAVE_STRPTIME=1;
19288 HAVE_TIMEGM=1;
19289 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
19290 REPLACE_MKTIME=GNULIB_PORTCHECK;
19291 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
19292 REPLACE_TIMEGM=GNULIB_PORTCHECK;
19297 GNULIB_PSELECT=0;
19298 GNULIB_SELECT=0;
19299 HAVE_PSELECT=1;
19300 REPLACE_PSELECT=0;
19301 REPLACE_SELECT=0;
19308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
19309 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
19310 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
19311 $as_echo_n "(cached) " >&6
19312 else
19314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19315 /* end confdefs.h. */
19316 #include <sys/select.h>
19318 main ()
19320 struct timeval b;
19322 return 0;
19324 _ACEOF
19325 if ac_fn_c_try_compile "$LINENO"; then :
19326 gl_cv_header_sys_select_h_selfcontained=yes
19327 else
19328 gl_cv_header_sys_select_h_selfcontained=no
19330 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19331 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
19332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19333 /* end confdefs.h. */
19334 #include <sys/select.h>
19336 main ()
19338 int memset; int bzero;
19340 return 0;
19343 _ACEOF
19344 if ac_fn_c_try_compile "$LINENO"; then :
19345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19346 /* end confdefs.h. */
19347 #include <sys/select.h>
19349 main ()
19352 #undef memset
19353 #define memset nonexistent_memset
19354 extern
19355 #ifdef __cplusplus
19357 #endif
19358 void *memset (void *, int, unsigned long);
19359 #undef bzero
19360 #define bzero nonexistent_bzero
19361 extern
19362 #ifdef __cplusplus
19364 #endif
19365 void bzero (void *, unsigned long);
19366 fd_set fds;
19367 FD_ZERO (&fds);
19370 return 0;
19373 _ACEOF
19374 if ac_fn_c_try_link "$LINENO"; then :
19376 else
19377 gl_cv_header_sys_select_h_selfcontained=no
19379 rm -f core conftest.err conftest.$ac_objext \
19380 conftest$ac_exeext conftest.$ac_ext
19383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19388 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19398 if test $gl_cv_have_include_next = yes; then
19399 gl_cv_next_sys_select_h='<'sys/select.h'>'
19400 else
19401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19402 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19403 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19404 $as_echo_n "(cached) " >&6
19405 else
19407 if test $ac_cv_header_sys_select_h = yes; then
19410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19411 /* end confdefs.h. */
19412 #include <sys/select.h>
19414 _ACEOF
19415 case "$host_os" in
19416 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19417 *) gl_absname_cpp="$ac_cpp" ;;
19418 esac
19420 case "$host_os" in
19421 mingw*)
19422 gl_dirsep_regex='[/\\]'
19425 gl_dirsep_regex='\/'
19427 esac
19428 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19430 gl_header_literal_regex=`echo 'sys/select.h' \
19431 | sed -e "$gl_make_literal_regex_sed"`
19432 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19433 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19434 s|^/[^/]|//&|
19438 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19439 sed -n "$gl_absolute_header_sed"`'"'
19440 else
19441 gl_cv_next_sys_select_h='<'sys/select.h'>'
19446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19447 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19449 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19451 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19452 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19453 gl_next_as_first_directive='<'sys/select.h'>'
19454 else
19455 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19456 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19458 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19463 if test $ac_cv_header_sys_select_h = yes; then
19464 HAVE_SYS_SELECT_H=1
19465 else
19466 HAVE_SYS_SELECT_H=0
19473 if test $ac_cv_header_sys_socket_h != yes; then
19474 for ac_header in winsock2.h
19475 do :
19476 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19477 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19478 cat >>confdefs.h <<_ACEOF
19479 #define HAVE_WINSOCK2_H 1
19480 _ACEOF
19484 done
19487 if test "$ac_cv_header_winsock2_h" = yes; then
19488 HAVE_WINSOCK2_H=1
19489 UNISTD_H_HAVE_WINSOCK2_H=1
19490 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19491 else
19492 HAVE_WINSOCK2_H=0
19502 GNULIB_PTHREAD_SIGMASK=0;
19503 GNULIB_RAISE=0;
19504 GNULIB_SIGNAL_H_SIGPIPE=0;
19505 GNULIB_SIGPROCMASK=0;
19506 GNULIB_SIGACTION=0;
19507 HAVE_POSIX_SIGNALBLOCKING=1;
19508 HAVE_PTHREAD_SIGMASK=1;
19509 HAVE_RAISE=1;
19510 HAVE_SIGSET_T=1;
19511 HAVE_SIGINFO_T=1;
19512 HAVE_SIGACTION=1;
19513 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19515 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19517 HAVE_SIGHANDLER_T=1;
19518 REPLACE_PTHREAD_SIGMASK=0;
19519 REPLACE_RAISE=0;
19527 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19528 #include <signal.h>
19529 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19530 #include <sys/types.h>
19533 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19535 cat >>confdefs.h <<_ACEOF
19536 #define HAVE_SIGSET_T 1
19537 _ACEOF
19539 gl_cv_type_sigset_t=yes
19540 else
19541 gl_cv_type_sigset_t=no
19544 if test $gl_cv_type_sigset_t != yes; then
19545 HAVE_SIGSET_T=0
19550 if test $ac_cv_header_sys_socket_h = no; then
19551 for ac_header in ws2tcpip.h
19552 do :
19553 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19554 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19555 cat >>confdefs.h <<_ACEOF
19556 #define HAVE_WS2TCPIP_H 1
19557 _ACEOF
19561 done
19565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19566 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19567 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19568 $as_echo_n "(cached) " >&6
19569 else
19570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19571 /* end confdefs.h. */
19573 #include <stdbool.h>
19574 #ifndef bool
19575 "error: bool is not defined"
19576 #endif
19577 #ifndef false
19578 "error: false is not defined"
19579 #endif
19580 #if false
19581 "error: false is not 0"
19582 #endif
19583 #ifndef true
19584 "error: true is not defined"
19585 #endif
19586 #if true != 1
19587 "error: true is not 1"
19588 #endif
19589 #ifndef __bool_true_false_are_defined
19590 "error: __bool_true_false_are_defined is not defined"
19591 #endif
19593 struct s { _Bool s: 1; _Bool t; } s;
19595 char a[true == 1 ? 1 : -1];
19596 char b[false == 0 ? 1 : -1];
19597 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19598 char d[(bool) 0.5 == true ? 1 : -1];
19599 /* See body of main program for 'e'. */
19600 char f[(_Bool) 0.0 == false ? 1 : -1];
19601 char g[true];
19602 char h[sizeof (_Bool)];
19603 char i[sizeof s.t];
19604 enum { j = false, k = true, l = false * true, m = true * 256 };
19605 /* The following fails for
19606 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19607 _Bool n[m];
19608 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19609 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19610 /* Catch a bug in an HP-UX C compiler. See
19611 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19612 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19614 _Bool q = true;
19615 _Bool *pq = &q;
19618 main ()
19621 bool e = &s;
19622 *pq |= q;
19623 *pq |= ! q;
19624 /* Refer to every declared value, to avoid compiler optimizations. */
19625 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19626 + !m + !n + !o + !p + !q + !pq);
19629 return 0;
19631 _ACEOF
19632 if ac_fn_c_try_compile "$LINENO"; then :
19633 ac_cv_header_stdbool_h=yes
19634 else
19635 ac_cv_header_stdbool_h=no
19637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19640 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19641 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19642 if test "x$ac_cv_type__Bool" = x""yes; then :
19644 cat >>confdefs.h <<_ACEOF
19645 #define HAVE__BOOL 1
19646 _ACEOF
19653 REPLACE_NULL=0;
19654 HAVE_WCHAR_T=1;
19657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19658 $as_echo_n "checking for wchar_t... " >&6; }
19659 if test "${gt_cv_c_wchar_t+set}" = set; then :
19660 $as_echo_n "(cached) " >&6
19661 else
19662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19663 /* end confdefs.h. */
19664 #include <stddef.h>
19665 wchar_t foo = (wchar_t)'\0';
19667 main ()
19671 return 0;
19673 _ACEOF
19674 if ac_fn_c_try_compile "$LINENO"; then :
19675 gt_cv_c_wchar_t=yes
19676 else
19677 gt_cv_c_wchar_t=no
19679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19682 $as_echo "$gt_cv_c_wchar_t" >&6; }
19683 if test $gt_cv_c_wchar_t = yes; then
19685 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19690 GNULIB_DPRINTF=0;
19691 GNULIB_FCLOSE=0;
19692 GNULIB_FDOPEN=0;
19693 GNULIB_FFLUSH=0;
19694 GNULIB_FGETC=0;
19695 GNULIB_FGETS=0;
19696 GNULIB_FOPEN=0;
19697 GNULIB_FPRINTF=0;
19698 GNULIB_FPRINTF_POSIX=0;
19699 GNULIB_FPURGE=0;
19700 GNULIB_FPUTC=0;
19701 GNULIB_FPUTS=0;
19702 GNULIB_FREAD=0;
19703 GNULIB_FREOPEN=0;
19704 GNULIB_FSCANF=0;
19705 GNULIB_FSEEK=0;
19706 GNULIB_FSEEKO=0;
19707 GNULIB_FTELL=0;
19708 GNULIB_FTELLO=0;
19709 GNULIB_FWRITE=0;
19710 GNULIB_GETC=0;
19711 GNULIB_GETCHAR=0;
19712 GNULIB_GETDELIM=0;
19713 GNULIB_GETLINE=0;
19714 GNULIB_OBSTACK_PRINTF=0;
19715 GNULIB_OBSTACK_PRINTF_POSIX=0;
19716 GNULIB_PCLOSE=0;
19717 GNULIB_PERROR=0;
19718 GNULIB_POPEN=0;
19719 GNULIB_PRINTF=0;
19720 GNULIB_PRINTF_POSIX=0;
19721 GNULIB_PUTC=0;
19722 GNULIB_PUTCHAR=0;
19723 GNULIB_PUTS=0;
19724 GNULIB_REMOVE=0;
19725 GNULIB_RENAME=0;
19726 GNULIB_RENAMEAT=0;
19727 GNULIB_SCANF=0;
19728 GNULIB_SNPRINTF=0;
19729 GNULIB_SPRINTF_POSIX=0;
19730 GNULIB_STDIO_H_NONBLOCKING=0;
19731 GNULIB_STDIO_H_SIGPIPE=0;
19732 GNULIB_TMPFILE=0;
19733 GNULIB_VASPRINTF=0;
19734 GNULIB_VFSCANF=0;
19735 GNULIB_VSCANF=0;
19736 GNULIB_VDPRINTF=0;
19737 GNULIB_VFPRINTF=0;
19738 GNULIB_VFPRINTF_POSIX=0;
19739 GNULIB_VPRINTF=0;
19740 GNULIB_VPRINTF_POSIX=0;
19741 GNULIB_VSNPRINTF=0;
19742 GNULIB_VSPRINTF_POSIX=0;
19743 HAVE_DECL_FPURGE=1;
19744 HAVE_DECL_FSEEKO=1;
19745 HAVE_DECL_FTELLO=1;
19746 HAVE_DECL_GETDELIM=1;
19747 HAVE_DECL_GETLINE=1;
19748 HAVE_DECL_OBSTACK_PRINTF=1;
19749 HAVE_DECL_SNPRINTF=1;
19750 HAVE_DECL_VSNPRINTF=1;
19751 HAVE_DPRINTF=1;
19752 HAVE_FSEEKO=1;
19753 HAVE_FTELLO=1;
19754 HAVE_PCLOSE=1;
19755 HAVE_POPEN=1;
19756 HAVE_RENAMEAT=1;
19757 HAVE_VASPRINTF=1;
19758 HAVE_VDPRINTF=1;
19759 REPLACE_DPRINTF=0;
19760 REPLACE_FCLOSE=0;
19761 REPLACE_FDOPEN=0;
19762 REPLACE_FFLUSH=0;
19763 REPLACE_FOPEN=0;
19764 REPLACE_FPRINTF=0;
19765 REPLACE_FPURGE=0;
19766 REPLACE_FREOPEN=0;
19767 REPLACE_FSEEK=0;
19768 REPLACE_FSEEKO=0;
19769 REPLACE_FTELL=0;
19770 REPLACE_FTELLO=0;
19771 REPLACE_GETDELIM=0;
19772 REPLACE_GETLINE=0;
19773 REPLACE_OBSTACK_PRINTF=0;
19774 REPLACE_PERROR=0;
19775 REPLACE_POPEN=0;
19776 REPLACE_PRINTF=0;
19777 REPLACE_REMOVE=0;
19778 REPLACE_RENAME=0;
19779 REPLACE_RENAMEAT=0;
19780 REPLACE_SNPRINTF=0;
19781 REPLACE_SPRINTF=0;
19782 REPLACE_STDIO_READ_FUNCS=0;
19783 REPLACE_STDIO_WRITE_FUNCS=0;
19784 REPLACE_TMPFILE=0;
19785 REPLACE_VASPRINTF=0;
19786 REPLACE_VDPRINTF=0;
19787 REPLACE_VFPRINTF=0;
19788 REPLACE_VPRINTF=0;
19789 REPLACE_VSNPRINTF=0;
19790 REPLACE_VSPRINTF=0;
19792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19793 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19794 if test "${ac_cv_struct_tm+set}" = set; then :
19795 $as_echo_n "(cached) " >&6
19796 else
19797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19798 /* end confdefs.h. */
19799 #include <sys/types.h>
19800 #include <time.h>
19803 main ()
19805 struct tm tm;
19806 int *p = &tm.tm_sec;
19807 return !p;
19809 return 0;
19811 _ACEOF
19812 if ac_fn_c_try_compile "$LINENO"; then :
19813 ac_cv_struct_tm=time.h
19814 else
19815 ac_cv_struct_tm=sys/time.h
19817 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19820 $as_echo "$ac_cv_struct_tm" >&6; }
19821 if test $ac_cv_struct_tm = sys/time.h; then
19823 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19827 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19828 #include <$ac_cv_struct_tm>
19831 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19833 cat >>confdefs.h <<_ACEOF
19834 #define HAVE_STRUCT_TM_TM_ZONE 1
19835 _ACEOF
19840 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19842 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19844 else
19845 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19847 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19848 ac_have_decl=1
19849 else
19850 ac_have_decl=0
19853 cat >>confdefs.h <<_ACEOF
19854 #define HAVE_DECL_TZNAME $ac_have_decl
19855 _ACEOF
19857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19858 $as_echo_n "checking for tzname... " >&6; }
19859 if test "${ac_cv_var_tzname+set}" = set; then :
19860 $as_echo_n "(cached) " >&6
19861 else
19862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19863 /* end confdefs.h. */
19864 #include <time.h>
19865 #if !HAVE_DECL_TZNAME
19866 extern char *tzname[];
19867 #endif
19870 main ()
19872 return tzname[0][0];
19874 return 0;
19876 _ACEOF
19877 if ac_fn_c_try_link "$LINENO"; then :
19878 ac_cv_var_tzname=yes
19879 else
19880 ac_cv_var_tzname=no
19882 rm -f core conftest.err conftest.$ac_objext \
19883 conftest$ac_exeext conftest.$ac_ext
19885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19886 $as_echo "$ac_cv_var_tzname" >&6; }
19887 if test $ac_cv_var_tzname = yes; then
19889 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19895 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19897 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19899 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19906 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19907 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19908 ac_have_decl=1
19909 else
19910 ac_have_decl=0
19913 cat >>confdefs.h <<_ACEOF
19914 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19915 _ACEOF
19919 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19920 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19921 ac_have_decl=1
19922 else
19923 ac_have_decl=0
19926 cat >>confdefs.h <<_ACEOF
19927 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19928 _ACEOF
19932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19933 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19934 if test "${ac_cv_header_stat_broken+set}" = set; then :
19935 $as_echo_n "(cached) " >&6
19936 else
19937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19938 /* end confdefs.h. */
19939 #include <sys/types.h>
19940 #include <sys/stat.h>
19942 #if defined S_ISBLK && defined S_IFDIR
19943 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19944 #endif
19946 #if defined S_ISBLK && defined S_IFCHR
19947 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19948 #endif
19950 #if defined S_ISLNK && defined S_IFREG
19951 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19952 #endif
19954 #if defined S_ISSOCK && defined S_IFREG
19955 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19956 #endif
19958 _ACEOF
19959 if ac_fn_c_try_compile "$LINENO"; then :
19960 ac_cv_header_stat_broken=no
19961 else
19962 ac_cv_header_stat_broken=yes
19964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19967 $as_echo "$ac_cv_header_stat_broken" >&6; }
19968 if test $ac_cv_header_stat_broken = yes; then
19970 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19979 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19980 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19981 $as_echo_n "(cached) " >&6
19982 else
19983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19984 /* end confdefs.h. */
19985 #include <time.h>
19988 main ()
19990 static struct timespec x; x.tv_sec = x.tv_nsec;
19992 return 0;
19994 _ACEOF
19995 if ac_fn_c_try_compile "$LINENO"; then :
19996 gl_cv_sys_struct_timespec_in_time_h=yes
19997 else
19998 gl_cv_sys_struct_timespec_in_time_h=no
20000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
20003 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
20005 TIME_H_DEFINES_STRUCT_TIMESPEC=0
20006 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
20007 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
20008 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
20009 TIME_H_DEFINES_STRUCT_TIMESPEC=1
20010 else
20011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
20012 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
20013 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
20014 $as_echo_n "(cached) " >&6
20015 else
20016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20017 /* end confdefs.h. */
20018 #include <sys/time.h>
20021 main ()
20023 static struct timespec x; x.tv_sec = x.tv_nsec;
20025 return 0;
20027 _ACEOF
20028 if ac_fn_c_try_compile "$LINENO"; then :
20029 gl_cv_sys_struct_timespec_in_sys_time_h=yes
20030 else
20031 gl_cv_sys_struct_timespec_in_sys_time_h=no
20033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
20036 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
20037 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
20038 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
20039 else
20040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
20041 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
20042 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
20043 $as_echo_n "(cached) " >&6
20044 else
20045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20046 /* end confdefs.h. */
20047 #include <pthread.h>
20050 main ()
20052 static struct timespec x; x.tv_sec = x.tv_nsec;
20054 return 0;
20056 _ACEOF
20057 if ac_fn_c_try_compile "$LINENO"; then :
20058 gl_cv_sys_struct_timespec_in_pthread_h=yes
20059 else
20060 gl_cv_sys_struct_timespec_in_pthread_h=no
20062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
20065 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
20066 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
20067 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
20086 if test $gl_cv_have_include_next = yes; then
20087 gl_cv_next_time_h='<'time.h'>'
20088 else
20089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
20090 $as_echo_n "checking absolute name of <time.h>... " >&6; }
20091 if test "${gl_cv_next_time_h+set}" = set; then :
20092 $as_echo_n "(cached) " >&6
20093 else
20095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20096 /* end confdefs.h. */
20097 #include <time.h>
20099 _ACEOF
20100 case "$host_os" in
20101 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20102 *) gl_absname_cpp="$ac_cpp" ;;
20103 esac
20105 case "$host_os" in
20106 mingw*)
20107 gl_dirsep_regex='[/\\]'
20110 gl_dirsep_regex='\/'
20112 esac
20113 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20115 gl_header_literal_regex=`echo 'time.h' \
20116 | sed -e "$gl_make_literal_regex_sed"`
20117 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20118 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20119 s|^/[^/]|//&|
20123 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20124 sed -n "$gl_absolute_header_sed"`'"'
20128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
20129 $as_echo "$gl_cv_next_time_h" >&6; }
20131 NEXT_TIME_H=$gl_cv_next_time_h
20133 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20134 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20135 gl_next_as_first_directive='<'time.h'>'
20136 else
20137 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20138 gl_next_as_first_directive=$gl_cv_next_time_h
20140 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
20155 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
20156 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
20157 ac_have_decl=1
20158 else
20159 ac_have_decl=0
20162 cat >>confdefs.h <<_ACEOF
20163 #define HAVE_DECL_UNSETENV $ac_have_decl
20164 _ACEOF
20167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
20168 $as_echo_n "checking whether the utimes function works... " >&6; }
20169 if test "${gl_cv_func_working_utimes+set}" = set; then :
20170 $as_echo_n "(cached) " >&6
20171 else
20173 if test "$cross_compiling" = yes; then :
20174 gl_cv_func_working_utimes=no
20175 else
20176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20177 /* end confdefs.h. */
20179 #include <sys/types.h>
20180 #include <sys/stat.h>
20181 #include <fcntl.h>
20182 #include <sys/time.h>
20183 #include <time.h>
20184 #include <unistd.h>
20185 #include <stdlib.h>
20186 #include <stdio.h>
20187 #include <utime.h>
20189 static int
20190 inorder (time_t a, time_t b, time_t c)
20192 return a <= b && b <= c;
20196 main ()
20198 int result = 0;
20199 char const *file = "conftest.utimes";
20200 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
20202 /* Test whether utimes() essentially works. */
20204 struct stat sbuf;
20205 FILE *f = fopen (file, "w");
20206 if (f == NULL)
20207 result |= 1;
20208 else if (fclose (f) != 0)
20209 result |= 1;
20210 else if (utimes (file, timeval) != 0)
20211 result |= 2;
20212 else if (lstat (file, &sbuf) != 0)
20213 result |= 1;
20214 else if (!(sbuf.st_atime == timeval[0].tv_sec
20215 && sbuf.st_mtime == timeval[1].tv_sec))
20216 result |= 4;
20217 if (unlink (file) != 0)
20218 result |= 1;
20221 /* Test whether utimes() with a NULL argument sets the file's timestamp
20222 to the current time. Use 'fstat' as well as 'time' to
20223 determine the "current" time, to accommodate NFS file systems
20224 if there is a time skew between the host and the NFS server. */
20226 int fd = open (file, O_WRONLY|O_CREAT, 0644);
20227 if (fd < 0)
20228 result |= 1;
20229 else
20231 time_t t0, t2;
20232 struct stat st0, st1, st2;
20233 if (time (&t0) == (time_t) -1)
20234 result |= 1;
20235 else if (fstat (fd, &st0) != 0)
20236 result |= 1;
20237 else if (utimes (file, timeval) != 0)
20238 result |= 2;
20239 else if (utimes (file, NULL) != 0)
20240 result |= 8;
20241 else if (fstat (fd, &st1) != 0)
20242 result |= 1;
20243 else if (write (fd, "\n", 1) != 1)
20244 result |= 1;
20245 else if (fstat (fd, &st2) != 0)
20246 result |= 1;
20247 else if (time (&t2) == (time_t) -1)
20248 result |= 1;
20249 else
20251 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
20252 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
20253 if (! (st1.st_atime == st1.st_mtime))
20254 result |= 16;
20255 if (! (m_ok_POSIX || m_ok_NFS))
20256 result |= 32;
20258 if (close (fd) != 0)
20259 result |= 1;
20261 if (unlink (file) != 0)
20262 result |= 1;
20265 /* Test whether utimes() with a NULL argument works on read-only files. */
20267 int fd = open (file, O_WRONLY|O_CREAT, 0444);
20268 if (fd < 0)
20269 result |= 1;
20270 else if (close (fd) != 0)
20271 result |= 1;
20272 else if (utimes (file, NULL) != 0)
20273 result |= 64;
20274 if (unlink (file) != 0)
20275 result |= 1;
20278 return result;
20281 _ACEOF
20282 if ac_fn_c_try_run "$LINENO"; then :
20283 gl_cv_func_working_utimes=yes
20284 else
20285 gl_cv_func_working_utimes=no
20287 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20288 conftest.$ac_objext conftest.beam conftest.$ac_ext
20292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
20293 $as_echo "$gl_cv_func_working_utimes" >&6; }
20295 if test $gl_cv_func_working_utimes = yes; then
20297 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
20305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
20306 $as_echo_n "checking for struct utimbuf... " >&6; }
20307 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
20308 $as_echo_n "(cached) " >&6
20309 else
20310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20311 /* end confdefs.h. */
20312 #if HAVE_SYS_TIME_H
20313 #include <sys/time.h>
20314 #endif
20315 #include <time.h>
20316 #ifdef HAVE_UTIME_H
20317 #include <utime.h>
20318 #endif
20321 main ()
20323 static struct utimbuf x; x.actime = x.modtime;
20325 return 0;
20327 _ACEOF
20328 if ac_fn_c_try_compile "$LINENO"; then :
20329 gl_cv_sys_struct_utimbuf=yes
20330 else
20331 gl_cv_sys_struct_utimbuf=no
20333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
20336 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
20338 if test $gl_cv_sys_struct_utimbuf = yes; then
20340 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
20354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
20355 $as_echo_n "checking type of array argument to getgroups... " >&6; }
20356 if test "${ac_cv_type_getgroups+set}" = set; then :
20357 $as_echo_n "(cached) " >&6
20358 else
20359 if test "$cross_compiling" = yes; then :
20360 ac_cv_type_getgroups=cross
20361 else
20362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20363 /* end confdefs.h. */
20364 /* Thanks to Mike Rendell for this test. */
20365 $ac_includes_default
20366 #define NGID 256
20367 #undef MAX
20368 #define MAX(x, y) ((x) > (y) ? (x) : (y))
20371 main ()
20373 gid_t gidset[NGID];
20374 int i, n;
20375 union { gid_t gval; long int lval; } val;
20377 val.lval = -1;
20378 for (i = 0; i < NGID; i++)
20379 gidset[i] = val.gval;
20380 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
20381 gidset);
20382 /* Exit non-zero if getgroups seems to require an array of ints. This
20383 happens when gid_t is short int but getgroups modifies an array
20384 of ints. */
20385 return n > 0 && gidset[n] != val.gval;
20387 _ACEOF
20388 if ac_fn_c_try_run "$LINENO"; then :
20389 ac_cv_type_getgroups=gid_t
20390 else
20391 ac_cv_type_getgroups=int
20393 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20394 conftest.$ac_objext conftest.beam conftest.$ac_ext
20397 if test $ac_cv_type_getgroups = cross; then
20398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20399 /* end confdefs.h. */
20400 #include <unistd.h>
20402 _ACEOF
20403 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20404 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
20405 ac_cv_type_getgroups=gid_t
20406 else
20407 ac_cv_type_getgroups=int
20409 rm -f conftest*
20413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
20414 $as_echo "$ac_cv_type_getgroups" >&6; }
20416 cat >>confdefs.h <<_ACEOF
20417 #define GETGROUPS_T $ac_cv_type_getgroups
20418 _ACEOF
20423 if false; then
20424 GL_COND_LIBTOOL_TRUE=
20425 GL_COND_LIBTOOL_FALSE='#'
20426 else
20427 GL_COND_LIBTOOL_TRUE='#'
20428 GL_COND_LIBTOOL_FALSE=
20431 gl_cond_libtool=false
20432 gl_libdeps=
20433 gl_ltlibdeps=
20434 gl_m4_base='m4'
20444 gl_source_base='lib'
20447 if test $ac_cv_func_alloca_works = no; then
20451 # Define an additional variable used in the Makefile substitution.
20452 if test $ac_cv_working_alloca_h = yes; then
20453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20454 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20455 if test "${gl_cv_rpl_alloca+set}" = set; then :
20456 $as_echo_n "(cached) " >&6
20457 else
20459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20460 /* end confdefs.h. */
20462 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20463 Need own alloca
20464 #endif
20466 _ACEOF
20467 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20468 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20469 gl_cv_rpl_alloca=yes
20470 else
20471 gl_cv_rpl_alloca=no
20473 rm -f conftest*
20477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20478 $as_echo "$gl_cv_rpl_alloca" >&6; }
20479 if test $gl_cv_rpl_alloca = yes; then
20481 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20483 ALLOCA_H=alloca.h
20484 else
20485 ALLOCA_H=
20487 else
20488 ALLOCA_H=alloca.h
20491 if test -n "$ALLOCA_H"; then
20492 GL_GENERATE_ALLOCA_H_TRUE=
20493 GL_GENERATE_ALLOCA_H_FALSE='#'
20494 else
20495 GL_GENERATE_ALLOCA_H_TRUE='#'
20496 GL_GENERATE_ALLOCA_H_FALSE=
20504 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20505 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20507 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20508 # programs in the package would end up linked with that potentially-shared
20509 # library, inducing unnecessary run-time overhead.
20510 LIB_CLOCK_GETTIME=
20512 gl_saved_libs=$LIBS
20513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20514 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20515 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20516 $as_echo_n "(cached) " >&6
20517 else
20518 ac_func_search_save_LIBS=$LIBS
20519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20520 /* end confdefs.h. */
20522 /* Override any GCC internal prototype to avoid an error.
20523 Use char because int might match the return type of a GCC
20524 builtin and then its argument prototype would still apply. */
20525 #ifdef __cplusplus
20526 extern "C"
20527 #endif
20528 char clock_gettime ();
20530 main ()
20532 return clock_gettime ();
20534 return 0;
20536 _ACEOF
20537 for ac_lib in '' rt posix4; do
20538 if test -z "$ac_lib"; then
20539 ac_res="none required"
20540 else
20541 ac_res=-l$ac_lib
20542 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20544 if ac_fn_c_try_link "$LINENO"; then :
20545 ac_cv_search_clock_gettime=$ac_res
20547 rm -f core conftest.err conftest.$ac_objext \
20548 conftest$ac_exeext
20549 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20550 break
20552 done
20553 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20555 else
20556 ac_cv_search_clock_gettime=no
20558 rm conftest.$ac_ext
20559 LIBS=$ac_func_search_save_LIBS
20561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20562 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20563 ac_res=$ac_cv_search_clock_gettime
20564 if test "$ac_res" != no; then :
20565 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20566 test "$ac_cv_search_clock_gettime" = "none required" ||
20567 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20570 for ac_func in clock_gettime clock_settime
20571 do :
20572 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20573 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20574 eval as_val=\$$as_ac_var
20575 if test "x$as_val" = x""yes; then :
20576 cat >>confdefs.h <<_ACEOF
20577 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20578 _ACEOF
20581 done
20583 LIBS=$gl_saved_libs
20590 cat >>confdefs.h <<_ACEOF
20591 #define GNULIB_CLOSE_STREAM 1
20592 _ACEOF
20615 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20618 if test $HAVE_DUP2 = 1; then
20619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20620 $as_echo_n "checking whether dup2 works... " >&6; }
20621 if test "${gl_cv_func_dup2_works+set}" = set; then :
20622 $as_echo_n "(cached) " >&6
20623 else
20624 if test "$cross_compiling" = yes; then :
20625 case "$host_os" in
20626 mingw*) # on this platform, dup2 always returns 0 for success
20627 gl_cv_func_dup2_works="guessing no" ;;
20628 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20629 gl_cv_func_dup2_works="guessing no" ;;
20630 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20631 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20632 gl_cv_func_dup2_works="guessing no" ;;
20633 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20634 gl_cv_func_dup2_works="guessing no" ;;
20635 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20636 gl_cv_func_dup2_works="guessing no" ;;
20637 *) gl_cv_func_dup2_works="guessing yes" ;;
20638 esac
20639 else
20640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20641 /* end confdefs.h. */
20643 #include <unistd.h>
20644 #include <fcntl.h>
20645 #include <errno.h>
20647 main ()
20649 int result = 0;
20650 #ifdef FD_CLOEXEC
20651 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20652 result |= 1;
20653 #endif
20654 if (dup2 (1, 1) == 0)
20655 result |= 2;
20656 #ifdef FD_CLOEXEC
20657 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20658 result |= 4;
20659 #endif
20660 close (0);
20661 if (dup2 (0, 0) != -1)
20662 result |= 8;
20663 /* Many gnulib modules require POSIX conformance of EBADF. */
20664 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20665 result |= 16;
20666 /* Flush out a cygwin core dump. */
20667 if (dup2 (2, -1) != -1 || errno != EBADF)
20668 result |= 32;
20669 return result;
20672 return 0;
20675 _ACEOF
20676 if ac_fn_c_try_run "$LINENO"; then :
20677 gl_cv_func_dup2_works=yes
20678 else
20679 gl_cv_func_dup2_works=no
20681 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20682 conftest.$ac_objext conftest.beam conftest.$ac_ext
20687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20688 $as_echo "$gl_cv_func_dup2_works" >&6; }
20689 case "$gl_cv_func_dup2_works" in
20690 *yes) ;;
20692 REPLACE_DUP2=1
20694 esac
20698 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20707 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20716 GNULIB_DUP2=1
20728 GNULIB_ENVIRON=1
20737 LIB_EXECINFO=''
20738 EXECINFO_H='execinfo.h'
20740 if test $ac_cv_header_execinfo_h = yes; then
20741 gl_saved_libs=$LIBS
20742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20743 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20744 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20745 $as_echo_n "(cached) " >&6
20746 else
20747 ac_func_search_save_LIBS=$LIBS
20748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20749 /* end confdefs.h. */
20751 /* Override any GCC internal prototype to avoid an error.
20752 Use char because int might match the return type of a GCC
20753 builtin and then its argument prototype would still apply. */
20754 #ifdef __cplusplus
20755 extern "C"
20756 #endif
20757 char backtrace_symbols_fd ();
20759 main ()
20761 return backtrace_symbols_fd ();
20763 return 0;
20765 _ACEOF
20766 for ac_lib in '' execinfo; do
20767 if test -z "$ac_lib"; then
20768 ac_res="none required"
20769 else
20770 ac_res=-l$ac_lib
20771 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20773 if ac_fn_c_try_link "$LINENO"; then :
20774 ac_cv_search_backtrace_symbols_fd=$ac_res
20776 rm -f core conftest.err conftest.$ac_objext \
20777 conftest$ac_exeext
20778 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20779 break
20781 done
20782 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20784 else
20785 ac_cv_search_backtrace_symbols_fd=no
20787 rm conftest.$ac_ext
20788 LIBS=$ac_func_search_save_LIBS
20790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20791 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20792 ac_res=$ac_cv_search_backtrace_symbols_fd
20793 if test "$ac_res" != no; then :
20794 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20795 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20796 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20799 LIBS=$gl_saved_libs
20800 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20803 if test -n "$EXECINFO_H"; then
20812 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20818 if test -n "$EXECINFO_H"; then
20819 GL_GENERATE_EXECINFO_H_TRUE=
20820 GL_GENERATE_EXECINFO_H_FALSE='#'
20821 else
20822 GL_GENERATE_EXECINFO_H_TRUE='#'
20823 GL_GENERATE_EXECINFO_H_FALSE=
20834 if test $ac_cv_func_faccessat = no; then
20835 HAVE_FACCESSAT=0
20838 if test $HAVE_FACCESSAT = 0; then
20847 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
20850 for ac_func in access
20851 do :
20852 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
20853 if test "x$ac_cv_func_access" = x""yes; then :
20854 cat >>confdefs.h <<_ACEOF
20855 #define HAVE_ACCESS 1
20856 _ACEOF
20859 done
20865 cat >>confdefs.h <<_ACEOF
20866 #define GNULIB_FACCESSAT 1
20867 _ACEOF
20875 GNULIB_FACCESSAT=1
20892 if test $gl_cv_have_include_next = yes; then
20893 gl_cv_next_fcntl_h='<'fcntl.h'>'
20894 else
20895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
20896 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
20897 if test "${gl_cv_next_fcntl_h+set}" = set; then :
20898 $as_echo_n "(cached) " >&6
20899 else
20901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20902 /* end confdefs.h. */
20903 #include <fcntl.h>
20905 _ACEOF
20906 case "$host_os" in
20907 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20908 *) gl_absname_cpp="$ac_cpp" ;;
20909 esac
20911 case "$host_os" in
20912 mingw*)
20913 gl_dirsep_regex='[/\\]'
20916 gl_dirsep_regex='\/'
20918 esac
20919 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20921 gl_header_literal_regex=`echo 'fcntl.h' \
20922 | sed -e "$gl_make_literal_regex_sed"`
20923 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20924 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20925 s|^/[^/]|//&|
20929 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20930 sed -n "$gl_absolute_header_sed"`'"'
20934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
20935 $as_echo "$gl_cv_next_fcntl_h" >&6; }
20937 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
20939 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20940 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20941 gl_next_as_first_directive='<'fcntl.h'>'
20942 else
20943 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20944 gl_next_as_first_directive=$gl_cv_next_fcntl_h
20946 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
20965 fp_headers='
20966 # include <stdio.h>
20967 # if HAVE_STDIO_EXT_H
20968 # include <stdio_ext.h>
20969 # endif
20971 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
20973 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
20974 ac_have_decl=1
20975 else
20976 ac_have_decl=0
20979 cat >>confdefs.h <<_ACEOF
20980 #define HAVE_DECL___FPENDING $ac_have_decl
20981 _ACEOF
20984 if test $ac_cv_func___fpending = no; then
20993 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
20996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
20997 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
20998 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
20999 $as_echo_n "(cached) " >&6
21000 else
21002 for ac_expr in \
21004 '# glibc2' \
21005 'fp->_IO_write_ptr - fp->_IO_write_base' \
21007 '# traditional Unix' \
21008 'fp->_ptr - fp->_base' \
21010 '# BSD' \
21011 'fp->_p - fp->_bf._base' \
21013 '# SCO, Unixware' \
21014 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
21016 '# QNX' \
21017 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
21019 '# old glibc?' \
21020 'fp->__bufp - fp->__buffer' \
21022 '# old glibc iostream?' \
21023 'fp->_pptr - fp->_pbase' \
21025 '# emx+gcc' \
21026 'fp->_ptr - fp->_buffer' \
21028 '# Minix' \
21029 'fp->_ptr - fp->_buf' \
21031 '# Plan9' \
21032 'fp->wp - fp->buf' \
21034 '# VMS' \
21035 '(*fp)->_ptr - (*fp)->_base' \
21037 '# e.g., DGUX R4.11; the info is not available' \
21039 ; do
21041 # Skip each embedded comment.
21042 case "$ac_expr" in '#'*) continue;; esac
21044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21045 /* end confdefs.h. */
21046 #include <stdio.h>
21048 main ()
21050 FILE *fp = stdin; (void) ($ac_expr);
21052 return 0;
21054 _ACEOF
21055 if ac_fn_c_try_compile "$LINENO"; then :
21056 fp_done=yes
21059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21060 test "$fp_done" = yes && break
21061 done
21063 ac_cv_sys_pending_output_n_bytes=$ac_expr
21067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
21068 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
21070 cat >>confdefs.h <<_ACEOF
21071 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
21072 _ACEOF
21078 # Persuade glibc <stdlib.h> to declare getloadavg().
21081 gl_save_LIBS=$LIBS
21083 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
21084 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
21085 HAVE_GETLOADAVG=1
21086 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
21087 if test "x$ac_cv_func_getloadavg" = x""yes; then :
21089 else
21090 gl_func_getloadavg_done=no
21092 # Some systems with -lutil have (and need) -lkvm as well, some do not.
21093 # On Solaris, -lkvm requires nlist from -lelf, so check that first
21094 # to get the right answer into the cache.
21095 # For kstat on solaris, we need to test for libelf and libkvm to force the
21096 # definition of SVR4 below.
21097 if test $gl_func_getloadavg_done = no; then
21098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
21099 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
21100 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
21101 $as_echo_n "(cached) " >&6
21102 else
21103 ac_check_lib_save_LIBS=$LIBS
21104 LIBS="-lelf $LIBS"
21105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21106 /* end confdefs.h. */
21108 /* Override any GCC internal prototype to avoid an error.
21109 Use char because int might match the return type of a GCC
21110 builtin and then its argument prototype would still apply. */
21111 #ifdef __cplusplus
21112 extern "C"
21113 #endif
21114 char elf_begin ();
21116 main ()
21118 return elf_begin ();
21120 return 0;
21122 _ACEOF
21123 if ac_fn_c_try_link "$LINENO"; then :
21124 ac_cv_lib_elf_elf_begin=yes
21125 else
21126 ac_cv_lib_elf_elf_begin=no
21128 rm -f core conftest.err conftest.$ac_objext \
21129 conftest$ac_exeext conftest.$ac_ext
21130 LIBS=$ac_check_lib_save_LIBS
21132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
21133 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
21134 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
21135 LIBS="-lelf $LIBS"
21138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
21139 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
21140 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
21141 $as_echo_n "(cached) " >&6
21142 else
21143 ac_check_lib_save_LIBS=$LIBS
21144 LIBS="-lkvm $LIBS"
21145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21146 /* end confdefs.h. */
21148 /* Override any GCC internal prototype to avoid an error.
21149 Use char because int might match the return type of a GCC
21150 builtin and then its argument prototype would still apply. */
21151 #ifdef __cplusplus
21152 extern "C"
21153 #endif
21154 char kvm_open ();
21156 main ()
21158 return kvm_open ();
21160 return 0;
21162 _ACEOF
21163 if ac_fn_c_try_link "$LINENO"; then :
21164 ac_cv_lib_kvm_kvm_open=yes
21165 else
21166 ac_cv_lib_kvm_kvm_open=no
21168 rm -f core conftest.err conftest.$ac_objext \
21169 conftest$ac_exeext conftest.$ac_ext
21170 LIBS=$ac_check_lib_save_LIBS
21172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
21173 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
21174 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
21175 LIBS="-lkvm $LIBS"
21178 # Check for the 4.4BSD definition of getloadavg.
21179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
21180 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
21181 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
21182 $as_echo_n "(cached) " >&6
21183 else
21184 ac_check_lib_save_LIBS=$LIBS
21185 LIBS="-lutil $LIBS"
21186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21187 /* end confdefs.h. */
21189 /* Override any GCC internal prototype to avoid an error.
21190 Use char because int might match the return type of a GCC
21191 builtin and then its argument prototype would still apply. */
21192 #ifdef __cplusplus
21193 extern "C"
21194 #endif
21195 char getloadavg ();
21197 main ()
21199 return getloadavg ();
21201 return 0;
21203 _ACEOF
21204 if ac_fn_c_try_link "$LINENO"; then :
21205 ac_cv_lib_util_getloadavg=yes
21206 else
21207 ac_cv_lib_util_getloadavg=no
21209 rm -f core conftest.err conftest.$ac_objext \
21210 conftest$ac_exeext conftest.$ac_ext
21211 LIBS=$ac_check_lib_save_LIBS
21213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
21214 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
21215 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
21216 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
21221 if test $gl_func_getloadavg_done = no; then
21222 # There is a commonly available library for RS/6000 AIX.
21223 # Since it is not a standard part of AIX, it might be installed locally.
21224 gl_getloadavg_LIBS=$LIBS
21225 LIBS="-L/usr/local/lib $LIBS"
21226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
21227 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
21228 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
21229 $as_echo_n "(cached) " >&6
21230 else
21231 ac_check_lib_save_LIBS=$LIBS
21232 LIBS="-lgetloadavg $LIBS"
21233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21234 /* end confdefs.h. */
21236 /* Override any GCC internal prototype to avoid an error.
21237 Use char because int might match the return type of a GCC
21238 builtin and then its argument prototype would still apply. */
21239 #ifdef __cplusplus
21240 extern "C"
21241 #endif
21242 char getloadavg ();
21244 main ()
21246 return getloadavg ();
21248 return 0;
21250 _ACEOF
21251 if ac_fn_c_try_link "$LINENO"; then :
21252 ac_cv_lib_getloadavg_getloadavg=yes
21253 else
21254 ac_cv_lib_getloadavg_getloadavg=no
21256 rm -f core conftest.err conftest.$ac_objext \
21257 conftest$ac_exeext conftest.$ac_ext
21258 LIBS=$ac_check_lib_save_LIBS
21260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
21261 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
21262 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
21263 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
21264 else
21265 LIBS=$gl_getloadavg_LIBS
21270 # Set up the replacement function if necessary.
21271 if test $gl_func_getloadavg_done = no; then
21272 HAVE_GETLOADAVG=0
21274 # Solaris has libkstat which does not require root.
21275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
21276 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
21277 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
21278 $as_echo_n "(cached) " >&6
21279 else
21280 ac_check_lib_save_LIBS=$LIBS
21281 LIBS="-lkstat $LIBS"
21282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21283 /* end confdefs.h. */
21285 /* Override any GCC internal prototype to avoid an error.
21286 Use char because int might match the return type of a GCC
21287 builtin and then its argument prototype would still apply. */
21288 #ifdef __cplusplus
21289 extern "C"
21290 #endif
21291 char kstat_open ();
21293 main ()
21295 return kstat_open ();
21297 return 0;
21299 _ACEOF
21300 if ac_fn_c_try_link "$LINENO"; then :
21301 ac_cv_lib_kstat_kstat_open=yes
21302 else
21303 ac_cv_lib_kstat_kstat_open=no
21305 rm -f core conftest.err conftest.$ac_objext \
21306 conftest$ac_exeext conftest.$ac_ext
21307 LIBS=$ac_check_lib_save_LIBS
21309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
21310 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
21311 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
21312 cat >>confdefs.h <<_ACEOF
21313 #define HAVE_LIBKSTAT 1
21314 _ACEOF
21316 LIBS="-lkstat $LIBS"
21320 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
21322 # AIX has libperfstat which does not require root
21323 if test $gl_func_getloadavg_done = no; then
21324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
21325 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
21326 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
21327 $as_echo_n "(cached) " >&6
21328 else
21329 ac_check_lib_save_LIBS=$LIBS
21330 LIBS="-lperfstat $LIBS"
21331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21332 /* end confdefs.h. */
21334 /* Override any GCC internal prototype to avoid an error.
21335 Use char because int might match the return type of a GCC
21336 builtin and then its argument prototype would still apply. */
21337 #ifdef __cplusplus
21338 extern "C"
21339 #endif
21340 char perfstat_cpu_total ();
21342 main ()
21344 return perfstat_cpu_total ();
21346 return 0;
21348 _ACEOF
21349 if ac_fn_c_try_link "$LINENO"; then :
21350 ac_cv_lib_perfstat_perfstat_cpu_total=yes
21351 else
21352 ac_cv_lib_perfstat_perfstat_cpu_total=no
21354 rm -f core conftest.err conftest.$ac_objext \
21355 conftest$ac_exeext conftest.$ac_ext
21356 LIBS=$ac_check_lib_save_LIBS
21358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
21359 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
21360 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
21361 cat >>confdefs.h <<_ACEOF
21362 #define HAVE_LIBPERFSTAT 1
21363 _ACEOF
21365 LIBS="-lperfstat $LIBS"
21369 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
21372 if test $gl_func_getloadavg_done = no; then
21373 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
21374 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
21375 gl_func_getloadavg_done=yes
21377 $as_echo "#define DGUX 1" >>confdefs.h
21379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
21380 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
21381 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
21382 $as_echo_n "(cached) " >&6
21383 else
21384 ac_check_lib_save_LIBS=$LIBS
21385 LIBS="-ldgc $LIBS"
21386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21387 /* end confdefs.h. */
21389 /* Override any GCC internal prototype to avoid an error.
21390 Use char because int might match the return type of a GCC
21391 builtin and then its argument prototype would still apply. */
21392 #ifdef __cplusplus
21393 extern "C"
21394 #endif
21395 char dg_sys_info ();
21397 main ()
21399 return dg_sys_info ();
21401 return 0;
21403 _ACEOF
21404 if ac_fn_c_try_link "$LINENO"; then :
21405 ac_cv_lib_dgc_dg_sys_info=yes
21406 else
21407 ac_cv_lib_dgc_dg_sys_info=no
21409 rm -f core conftest.err conftest.$ac_objext \
21410 conftest$ac_exeext conftest.$ac_ext
21411 LIBS=$ac_check_lib_save_LIBS
21413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
21414 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
21415 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
21416 cat >>confdefs.h <<_ACEOF
21417 #define HAVE_LIBDGC 1
21418 _ACEOF
21420 LIBS="-ldgc $LIBS"
21432 if test "x$gl_save_LIBS" = x; then
21433 GETLOADAVG_LIBS=$LIBS
21434 else
21435 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
21437 LIBS=$gl_save_LIBS
21440 # Test whether the system declares getloadavg. Solaris has the function
21441 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
21442 for ac_header in sys/loadavg.h
21443 do :
21444 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
21445 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
21446 cat >>confdefs.h <<_ACEOF
21447 #define HAVE_SYS_LOADAVG_H 1
21448 _ACEOF
21452 done
21454 if test $ac_cv_header_sys_loadavg_h = yes; then
21455 HAVE_SYS_LOADAVG_H=1
21456 else
21457 HAVE_SYS_LOADAVG_H=0
21459 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
21460 # include <sys/loadavg.h>
21461 #endif
21462 #include <stdlib.h>
21464 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
21466 else
21467 HAVE_DECL_GETLOADAVG=0
21471 if test $HAVE_GETLOADAVG = 0; then
21480 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
21483 # Figure out what our getloadavg.c needs.
21487 # On HPUX9, an unprivileged user can get load averages this way.
21488 if test $gl_func_getloadavg_done = no; then
21489 for ac_func in pstat_getdynamic
21490 do :
21491 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
21492 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
21493 cat >>confdefs.h <<_ACEOF
21494 #define HAVE_PSTAT_GETDYNAMIC 1
21495 _ACEOF
21496 gl_func_getloadavg_done=yes
21498 done
21502 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
21503 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
21504 # Irix 4.0.5F has the header but not the library.
21505 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
21506 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
21507 gl_func_getloadavg_done=yes
21509 $as_echo "#define SVR4 1" >>confdefs.h
21513 if test $gl_func_getloadavg_done = no; then
21514 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
21515 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
21516 gl_func_getloadavg_done=yes
21518 $as_echo "#define UMAX 1" >>confdefs.h
21521 $as_echo "#define UMAX4_3 1" >>confdefs.h
21528 if test $gl_func_getloadavg_done = no; then
21529 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
21530 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
21531 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
21538 if test $gl_func_getloadavg_done = no; then
21539 for ac_header in mach/mach.h
21540 do :
21541 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
21542 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
21543 cat >>confdefs.h <<_ACEOF
21544 #define HAVE_MACH_MACH_H 1
21545 _ACEOF
21549 done
21553 for ac_header in nlist.h
21554 do :
21555 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
21556 if test "x$ac_cv_header_nlist_h" = x""yes; then :
21557 cat >>confdefs.h <<_ACEOF
21558 #define HAVE_NLIST_H 1
21559 _ACEOF
21560 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
21562 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
21564 cat >>confdefs.h <<_ACEOF
21565 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
21566 _ACEOF
21571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21572 /* end confdefs.h. */
21573 #include <nlist.h>
21575 main ()
21577 struct nlist x;
21578 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
21579 x.n_un.n_name = "";
21580 #else
21581 x.n_name = "";
21582 #endif
21584 return 0;
21586 _ACEOF
21587 if ac_fn_c_try_link "$LINENO"; then :
21589 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
21592 rm -f core conftest.err conftest.$ac_objext \
21593 conftest$ac_exeext conftest.$ac_ext
21597 done
21605 GNULIB_GETLOADAVG=1
21616 if test $REPLACE_GETOPT = 1; then
21625 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21635 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21640 GNULIB_GL_UNISTD_H_GETOPT=1
21649 REPLACE_GETOPT=0
21650 if test -n "$gl_replace_getopt"; then
21651 REPLACE_GETOPT=1
21654 if test $REPLACE_GETOPT = 1; then
21656 GETOPT_H=getopt.h
21658 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
21664 if test $REPLACE_GETOPT = 1; then
21673 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21683 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21688 GNULIB_GL_UNISTD_H_GETOPT=1
21702 gl_gettimeofday_timezone=void
21703 if test $ac_cv_func_gettimeofday != yes; then
21704 HAVE_GETTIMEOFDAY=0
21705 else
21709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21710 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21711 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21712 $as_echo_n "(cached) " >&6
21713 else
21714 if test "$cross_compiling" = yes; then :
21715 # When cross-compiling:
21716 case "$host_os" in
21717 # Guess all is fine on glibc systems.
21718 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21719 # If we don't know, assume the worst.
21720 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21721 esac
21723 else
21724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21725 /* end confdefs.h. */
21726 #include <string.h>
21727 #include <sys/time.h>
21728 #include <time.h>
21729 #include <stdlib.h>
21732 main ()
21735 time_t t = 0;
21736 struct tm *lt;
21737 struct tm saved_lt;
21738 struct timeval tv;
21739 lt = localtime (&t);
21740 saved_lt = *lt;
21741 gettimeofday (&tv, NULL);
21742 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21745 return 0;
21747 _ACEOF
21748 if ac_fn_c_try_run "$LINENO"; then :
21749 gl_cv_func_gettimeofday_clobber=no
21750 else
21751 gl_cv_func_gettimeofday_clobber=yes
21753 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21754 conftest.$ac_objext conftest.beam conftest.$ac_ext
21758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21759 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21761 case "$gl_cv_func_gettimeofday_clobber" in
21762 *yes)
21763 REPLACE_GETTIMEOFDAY=1
21766 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21769 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21773 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21776 esac
21778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21779 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21780 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21781 $as_echo_n "(cached) " >&6
21782 else
21783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21784 /* end confdefs.h. */
21785 #include <sys/time.h>
21786 struct timeval c;
21787 int gettimeofday (struct timeval *restrict, void *restrict);
21790 main ()
21792 /* glibc uses struct timezone * rather than the POSIX void *
21793 if _GNU_SOURCE is defined. However, since the only portable
21794 use of gettimeofday uses NULL as the second parameter, and
21795 since the glibc definition is actually more typesafe, it is
21796 not worth wrapping this to get a compliant signature. */
21797 int (*f) (struct timeval *restrict, void *restrict)
21798 = gettimeofday;
21799 int x = f (&c, 0);
21800 return !(x | c.tv_sec | c.tv_usec);
21803 return 0;
21805 _ACEOF
21806 if ac_fn_c_try_compile "$LINENO"; then :
21807 gl_cv_func_gettimeofday_posix_signature=yes
21808 else
21809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21810 /* end confdefs.h. */
21811 #include <sys/time.h>
21812 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21815 main ()
21819 return 0;
21821 _ACEOF
21822 if ac_fn_c_try_compile "$LINENO"; then :
21823 gl_cv_func_gettimeofday_posix_signature=almost
21824 else
21825 gl_cv_func_gettimeofday_posix_signature=no
21827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21832 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21833 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21834 gl_gettimeofday_timezone='struct timezone'
21835 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21836 REPLACE_GETTIMEOFDAY=1
21838 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21839 REPLACE_GETTIMEOFDAY=1
21844 cat >>confdefs.h <<_ACEOF
21845 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21846 _ACEOF
21849 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21858 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21861 for ac_header in sys/timeb.h
21862 do :
21863 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21864 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21865 cat >>confdefs.h <<_ACEOF
21866 #define HAVE_SYS_TIMEB_H 1
21867 _ACEOF
21871 done
21873 for ac_func in _ftime
21874 do :
21875 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21876 if test "x$ac_cv_func__ftime" = x""yes; then :
21877 cat >>confdefs.h <<_ACEOF
21878 #define HAVE__FTIME 1
21879 _ACEOF
21882 done
21891 GNULIB_GETTIMEOFDAY=1
21902 if test $ac_cv_func_lstat = yes; then
21904 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21905 *no)
21906 REPLACE_LSTAT=1
21908 esac
21909 else
21910 HAVE_LSTAT=0
21913 if test $REPLACE_LSTAT = 1; then
21922 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21931 GNULIB_LSTAT=1
21943 if test $APPLE_UNIVERSAL_BUILD = 1; then
21944 # A universal build on Apple Mac OS X platforms.
21945 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21946 # But we need a configuration result that is valid in both modes.
21947 gl_cv_func_working_mktime=no
21949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21950 $as_echo_n "checking for working mktime... " >&6; }
21951 if test "${gl_cv_func_working_mktime+set}" = set; then :
21952 $as_echo_n "(cached) " >&6
21953 else
21954 if test "$cross_compiling" = yes; then :
21955 gl_cv_func_working_mktime=no
21956 else
21957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21958 /* end confdefs.h. */
21959 /* Test program from Paul Eggert and Tony Leneis. */
21960 #include <limits.h>
21961 #include <stdlib.h>
21962 #include <time.h>
21964 #ifdef HAVE_UNISTD_H
21965 # include <unistd.h>
21966 #endif
21968 #ifndef HAVE_ALARM
21969 # define alarm(X) /* empty */
21970 #endif
21972 /* Work around redefinition to rpl_putenv by other config tests. */
21973 #undef putenv
21975 static time_t time_t_max;
21976 static time_t time_t_min;
21978 /* Values we'll use to set the TZ environment variable. */
21979 static char *tz_strings[] = {
21980 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21981 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21983 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21985 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21986 Based on a problem report from Andreas Jaeger. */
21987 static int
21988 spring_forward_gap ()
21990 /* glibc (up to about 1998-10-07) failed this test. */
21991 struct tm tm;
21993 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21994 instead of "TZ=America/Vancouver" in order to detect the bug even
21995 on systems that don't support the Olson extension, or don't have the
21996 full zoneinfo tables installed. */
21997 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21999 tm.tm_year = 98;
22000 tm.tm_mon = 3;
22001 tm.tm_mday = 5;
22002 tm.tm_hour = 2;
22003 tm.tm_min = 0;
22004 tm.tm_sec = 0;
22005 tm.tm_isdst = -1;
22006 return mktime (&tm) != (time_t) -1;
22009 static int
22010 mktime_test1 (time_t now)
22012 struct tm *lt;
22013 return ! (lt = localtime (&now)) || mktime (lt) == now;
22016 static int
22017 mktime_test (time_t now)
22019 return (mktime_test1 (now)
22020 && mktime_test1 ((time_t) (time_t_max - now))
22021 && mktime_test1 ((time_t) (time_t_min + now)));
22024 static int
22025 irix_6_4_bug ()
22027 /* Based on code from Ariel Faigon. */
22028 struct tm tm;
22029 tm.tm_year = 96;
22030 tm.tm_mon = 3;
22031 tm.tm_mday = 0;
22032 tm.tm_hour = 0;
22033 tm.tm_min = 0;
22034 tm.tm_sec = 0;
22035 tm.tm_isdst = -1;
22036 mktime (&tm);
22037 return tm.tm_mon == 2 && tm.tm_mday == 31;
22040 static int
22041 bigtime_test (int j)
22043 struct tm tm;
22044 time_t now;
22045 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
22046 now = mktime (&tm);
22047 if (now != (time_t) -1)
22049 struct tm *lt = localtime (&now);
22050 if (! (lt
22051 && lt->tm_year == tm.tm_year
22052 && lt->tm_mon == tm.tm_mon
22053 && lt->tm_mday == tm.tm_mday
22054 && lt->tm_hour == tm.tm_hour
22055 && lt->tm_min == tm.tm_min
22056 && lt->tm_sec == tm.tm_sec
22057 && lt->tm_yday == tm.tm_yday
22058 && lt->tm_wday == tm.tm_wday
22059 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
22060 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
22061 return 0;
22063 return 1;
22066 static int
22067 year_2050_test ()
22069 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
22070 ignoring leap seconds. */
22071 unsigned long int answer = 2527315200UL;
22073 struct tm tm;
22074 time_t t;
22075 tm.tm_year = 2050 - 1900;
22076 tm.tm_mon = 2 - 1;
22077 tm.tm_mday = 1;
22078 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
22079 tm.tm_isdst = -1;
22081 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
22082 instead of "TZ=America/Vancouver" in order to detect the bug even
22083 on systems that don't support the Olson extension, or don't have the
22084 full zoneinfo tables installed. */
22085 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
22087 t = mktime (&tm);
22089 /* Check that the result is either a failure, or close enough
22090 to the correct answer that we can assume the discrepancy is
22091 due to leap seconds. */
22092 return (t == (time_t) -1
22093 || (0 < t && answer - 120 <= t && t <= answer + 120));
22097 main ()
22099 int result = 0;
22100 time_t t, delta;
22101 int i, j;
22102 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
22103 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
22105 /* This test makes some buggy mktime implementations loop.
22106 Give up after 60 seconds; a mktime slower than that
22107 isn't worth using anyway. */
22108 alarm (60);
22110 time_t_max = (! time_t_signed
22111 ? (time_t) -1
22112 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
22113 * 2 + 1));
22114 time_t_min = (! time_t_signed
22115 ? (time_t) 0
22116 : time_t_signed_magnitude
22117 ? ~ (time_t) 0
22118 : ~ time_t_max);
22120 delta = time_t_max / 997; /* a suitable prime number */
22121 for (i = 0; i < N_STRINGS; i++)
22123 if (tz_strings[i])
22124 putenv (tz_strings[i]);
22126 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
22127 if (! mktime_test (t))
22128 result |= 1;
22129 if ((result & 2) == 0
22130 && ! (mktime_test ((time_t) 1)
22131 && mktime_test ((time_t) (60 * 60))
22132 && mktime_test ((time_t) (60 * 60 * 24))))
22133 result |= 2;
22135 for (j = 1; (result & 4) == 0; j <<= 1)
22137 if (! bigtime_test (j))
22138 result |= 4;
22139 if (INT_MAX / 2 < j)
22140 break;
22142 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
22143 result |= 8;
22145 if (! irix_6_4_bug ())
22146 result |= 16;
22147 if (! spring_forward_gap ())
22148 result |= 32;
22149 if (! year_2050_test ())
22150 result |= 64;
22151 return result;
22153 _ACEOF
22154 if ac_fn_c_try_run "$LINENO"; then :
22155 gl_cv_func_working_mktime=yes
22156 else
22157 gl_cv_func_working_mktime=no
22159 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22160 conftest.$ac_objext conftest.beam conftest.$ac_ext
22165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
22166 $as_echo "$gl_cv_func_working_mktime" >&6; }
22168 if test $gl_cv_func_working_mktime = no; then
22169 REPLACE_MKTIME=1
22170 else
22171 REPLACE_MKTIME=0
22174 if test $REPLACE_MKTIME = 1; then
22183 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
22192 GNULIB_MKTIME=1
22204 if test $ac_cv_func_pselect = yes; then
22205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
22206 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
22207 if test "${gl_cv_sig_pselect+set}" = set; then :
22208 $as_echo_n "(cached) " >&6
22209 else
22210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22211 /* end confdefs.h. */
22212 #include <sys/select.h>
22215 main ()
22217 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
22218 struct timespec const *restrict,
22219 sigset_t const *restrict) = pselect;
22220 return !p;
22222 return 0;
22224 _ACEOF
22225 if ac_fn_c_try_link "$LINENO"; then :
22226 gl_cv_sig_pselect=yes
22227 else
22228 gl_cv_sig_pselect=no
22230 rm -f core conftest.err conftest.$ac_objext \
22231 conftest$ac_exeext conftest.$ac_ext
22233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
22234 $as_echo "$gl_cv_sig_pselect" >&6; }
22236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
22237 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
22238 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
22239 $as_echo_n "(cached) " >&6
22240 else
22242 if test "$cross_compiling" = yes; then :
22244 case "$host_os" in
22245 # Guess yes on glibc systems.
22246 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
22247 # If we don't know, assume the worst.
22248 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
22249 esac
22251 else
22252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22253 /* end confdefs.h. */
22255 #include <sys/types.h>
22256 #include <sys/time.h>
22257 #if HAVE_SYS_SELECT_H
22258 # include <sys/select.h>
22259 #endif
22260 #include <unistd.h>
22261 #include <errno.h>
22264 main ()
22267 fd_set set;
22268 dup2(0, 16);
22269 FD_ZERO(&set);
22270 FD_SET(16, &set);
22271 close(16);
22272 struct timespec timeout;
22273 timeout.tv_sec = 0;
22274 timeout.tv_nsec = 5000;
22275 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
22278 return 0;
22280 _ACEOF
22281 if ac_fn_c_try_run "$LINENO"; then :
22282 gl_cv_func_pselect_detects_ebadf=yes
22283 else
22284 gl_cv_func_pselect_detects_ebadf=no
22286 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22287 conftest.$ac_objext conftest.beam conftest.$ac_ext
22292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
22293 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
22294 case $gl_cv_func_pselect_detects_ebadf in
22295 *yes) ;;
22296 *) REPLACE_PSELECT=1 ;;
22297 esac
22300 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
22301 REPLACE_PSELECT=1
22304 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
22313 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
22321 GNULIB_PSELECT=1
22331 LIB_PTHREAD_SIGMASK=
22336 if test "$gl_threads_api" = posix; then
22337 if test $ac_cv_func_pthread_sigmask = yes; then
22339 else
22340 if test -n "$LIBMULTITHREAD"; then
22341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
22342 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
22343 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
22344 $as_echo_n "(cached) " >&6
22345 else
22346 gl_save_LIBS="$LIBS"
22347 LIBS="$LIBS $LIBMULTITHREAD"
22348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22349 /* end confdefs.h. */
22350 #include <pthread.h>
22351 #include <signal.h>
22354 main ()
22356 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
22358 return 0;
22361 _ACEOF
22362 if ac_fn_c_try_link "$LINENO"; then :
22363 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
22364 else
22365 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
22367 rm -f core conftest.err conftest.$ac_objext \
22368 conftest$ac_exeext conftest.$ac_ext
22369 LIBS="$gl_save_LIBS"
22372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
22373 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
22374 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
22375 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
22376 else
22377 HAVE_PTHREAD_SIGMASK=0
22379 else
22380 HAVE_PTHREAD_SIGMASK=0
22383 else
22384 if test $ac_cv_func_pthread_sigmask = yes; then
22385 REPLACE_PTHREAD_SIGMASK=1
22386 else
22387 HAVE_PTHREAD_SIGMASK=0
22394 if test $HAVE_PTHREAD_SIGMASK = 1; then
22397 if test -z "$LIB_PTHREAD_SIGMASK"; then
22398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
22399 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
22400 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
22401 $as_echo_n "(cached) " >&6
22402 else
22404 if test "$cross_compiling" = yes; then :
22406 case "$host_os" in
22407 freebsd* | hpux* | solaris | solaris2.[2-9]*)
22408 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
22410 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
22411 esac
22413 else
22414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22415 /* end confdefs.h. */
22417 #include <pthread.h>
22418 #include <signal.h>
22419 #include <stddef.h>
22420 int main ()
22422 sigset_t set;
22423 sigemptyset (&set);
22424 return pthread_sigmask (1729, &set, NULL) != 0;
22426 _ACEOF
22427 if ac_fn_c_try_run "$LINENO"; then :
22428 gl_cv_func_pthread_sigmask_in_libc_works=no
22429 else
22430 gl_cv_func_pthread_sigmask_in_libc_works=yes
22432 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22433 conftest.$ac_objext conftest.beam conftest.$ac_ext
22438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
22439 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
22440 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
22441 *no)
22442 REPLACE_PTHREAD_SIGMASK=1
22444 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
22447 esac
22450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
22451 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
22452 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
22453 $as_echo_n "(cached) " >&6
22454 else
22456 gl_save_LIBS="$LIBS"
22457 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
22458 if test "$cross_compiling" = yes; then :
22459 case "$host_os" in
22460 cygwin*)
22461 gl_cv_func_pthread_sigmask_return_works="guessing no";;
22463 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
22464 esac
22466 else
22467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22468 /* end confdefs.h. */
22470 #include <pthread.h>
22471 #include <signal.h>
22472 #include <stddef.h>
22473 int main ()
22475 sigset_t set;
22476 sigemptyset (&set);
22477 if (pthread_sigmask (1729, &set, NULL) == -1)
22478 return 1;
22479 return 0;
22481 _ACEOF
22482 if ac_fn_c_try_run "$LINENO"; then :
22483 gl_cv_func_pthread_sigmask_return_works=yes
22484 else
22485 gl_cv_func_pthread_sigmask_return_works=no
22487 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22488 conftest.$ac_objext conftest.beam conftest.$ac_ext
22491 LIBS="$gl_save_LIBS"
22494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
22495 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
22496 case "$gl_cv_func_pthread_sigmask_return_works" in
22497 *no)
22498 REPLACE_PTHREAD_SIGMASK=1
22500 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
22503 esac
22505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
22506 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
22507 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
22508 $as_echo_n "(cached) " >&6
22509 else
22511 case "$host_os" in
22512 irix*)
22513 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
22515 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
22516 esac
22517 gl_save_LIBS="$LIBS"
22518 LIBS="$LIBS $LIBMULTITHREAD"
22519 if test "$cross_compiling" = yes; then :
22521 else
22522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22523 /* end confdefs.h. */
22525 #include <pthread.h>
22526 #include <signal.h>
22527 #include <stdio.h>
22528 #include <stdlib.h>
22529 #include <unistd.h>
22530 static volatile int sigint_occurred;
22531 static void
22532 sigint_handler (int sig)
22534 sigint_occurred++;
22536 int main ()
22538 sigset_t set;
22539 int pid = getpid ();
22540 char command[80];
22541 signal (SIGINT, sigint_handler);
22542 sigemptyset (&set);
22543 sigaddset (&set, SIGINT);
22544 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
22545 return 1;
22546 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
22547 if (!(system (command) == 0))
22548 return 2;
22549 sleep (2);
22550 if (!(sigint_occurred == 0))
22551 return 3;
22552 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
22553 return 4;
22554 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
22555 return 5;
22556 return 0;
22558 _ACEOF
22559 if ac_fn_c_try_run "$LINENO"; then :
22561 else
22562 gl_cv_func_pthread_sigmask_unblock_works=no
22564 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22565 conftest.$ac_objext conftest.beam conftest.$ac_ext
22568 LIBS="$gl_save_LIBS"
22571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
22572 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
22573 case "$gl_cv_func_pthread_sigmask_unblock_works" in
22574 *no)
22575 REPLACE_PTHREAD_SIGMASK=1
22577 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
22580 esac
22583 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22592 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
22595 if test $HAVE_PTHREAD_SIGMASK = 1; then
22597 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
22607 GNULIB_PTHREAD_SIGMASK=1
22615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
22616 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
22617 if test "${gl_cv_func_svid_putenv+set}" = set; then :
22618 $as_echo_n "(cached) " >&6
22619 else
22620 if test "$cross_compiling" = yes; then :
22621 case "$host_os" in
22622 # Guess yes on glibc systems.
22623 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
22624 # If we don't know, assume the worst.
22625 *) gl_cv_func_svid_putenv="guessing no" ;;
22626 esac
22628 else
22629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22630 /* end confdefs.h. */
22631 $ac_includes_default
22633 main ()
22636 /* Put it in env. */
22637 if (putenv ("CONFTEST_putenv=val"))
22638 return 1;
22640 /* Try to remove it. */
22641 if (putenv ("CONFTEST_putenv"))
22642 return 2;
22644 /* Make sure it was deleted. */
22645 if (getenv ("CONFTEST_putenv") != 0)
22646 return 3;
22648 return 0;
22651 return 0;
22653 _ACEOF
22654 if ac_fn_c_try_run "$LINENO"; then :
22655 gl_cv_func_svid_putenv=yes
22656 else
22657 gl_cv_func_svid_putenv=no
22659 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22660 conftest.$ac_objext conftest.beam conftest.$ac_ext
22665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
22666 $as_echo "$gl_cv_func_svid_putenv" >&6; }
22667 case "$gl_cv_func_svid_putenv" in
22668 *yes) ;;
22670 REPLACE_PUTENV=1
22672 esac
22674 if test $REPLACE_PUTENV = 1; then
22683 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
22691 GNULIB_PUTENV=1
22700 if test $ac_cv_func_readlink = no; then
22701 HAVE_READLINK=0
22702 else
22703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
22704 $as_echo_n "checking whether readlink signature is correct... " >&6; }
22705 if test "${gl_cv_decl_readlink_works+set}" = set; then :
22706 $as_echo_n "(cached) " >&6
22707 else
22708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22709 /* end confdefs.h. */
22710 #include <unistd.h>
22711 /* Cause compilation failure if original declaration has wrong type. */
22712 ssize_t readlink (const char *, char *, size_t);
22714 main ()
22718 return 0;
22720 _ACEOF
22721 if ac_fn_c_try_compile "$LINENO"; then :
22722 gl_cv_decl_readlink_works=yes
22723 else
22724 gl_cv_decl_readlink_works=no
22726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
22729 $as_echo "$gl_cv_decl_readlink_works" >&6; }
22730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
22731 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
22732 if test "${gl_cv_func_readlink_works+set}" = set; then :
22733 $as_echo_n "(cached) " >&6
22734 else
22735 # We have readlink, so assume ln -s works.
22736 ln -s conftest.no-such conftest.link
22737 ln -s conftest.link conftest.lnk2
22738 if test "$cross_compiling" = yes; then :
22739 case "$host_os" in
22740 # Guess yes on glibc systems.
22741 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
22742 # If we don't know, assume the worst.
22743 *) gl_cv_func_readlink_works="guessing no" ;;
22744 esac
22746 else
22747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22748 /* end confdefs.h. */
22749 #include <unistd.h>
22752 main ()
22754 char buf[20];
22755 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
22757 return 0;
22759 _ACEOF
22760 if ac_fn_c_try_run "$LINENO"; then :
22761 gl_cv_func_readlink_works=yes
22762 else
22763 gl_cv_func_readlink_works=no
22765 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22766 conftest.$ac_objext conftest.beam conftest.$ac_ext
22769 rm -f conftest.link conftest.lnk2
22771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
22772 $as_echo "$gl_cv_func_readlink_works" >&6; }
22773 case "$gl_cv_func_readlink_works" in
22774 *yes)
22775 if test "$gl_cv_decl_readlink_works" != yes; then
22776 REPLACE_READLINK=1
22781 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
22783 REPLACE_READLINK=1
22785 esac
22788 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22797 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
22808 GNULIB_READLINK=1
22815 for ac_func in sig2str
22816 do :
22817 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
22818 if test "x$ac_cv_func_sig2str" = x""yes; then :
22819 cat >>confdefs.h <<_ACEOF
22820 #define HAVE_SIG2STR 1
22821 _ACEOF
22824 done
22827 if test $ac_cv_func_sig2str = no; then
22836 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
22853 if test $gl_cv_have_include_next = yes; then
22854 gl_cv_next_signal_h='<'signal.h'>'
22855 else
22856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22857 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22858 if test "${gl_cv_next_signal_h+set}" = set; then :
22859 $as_echo_n "(cached) " >&6
22860 else
22862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22863 /* end confdefs.h. */
22864 #include <signal.h>
22866 _ACEOF
22867 case "$host_os" in
22868 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22869 *) gl_absname_cpp="$ac_cpp" ;;
22870 esac
22872 case "$host_os" in
22873 mingw*)
22874 gl_dirsep_regex='[/\\]'
22877 gl_dirsep_regex='\/'
22879 esac
22880 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22882 gl_header_literal_regex=`echo 'signal.h' \
22883 | sed -e "$gl_make_literal_regex_sed"`
22884 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22885 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22886 s|^/[^/]|//&|
22890 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22891 sed -n "$gl_absolute_header_sed"`'"'
22895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22896 $as_echo "$gl_cv_next_signal_h" >&6; }
22898 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22900 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22901 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22902 gl_next_as_first_directive='<'signal.h'>'
22903 else
22904 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22905 gl_next_as_first_directive=$gl_cv_next_signal_h
22907 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22913 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22914 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22915 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22916 #include <signal.h>
22919 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22921 else
22922 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22931 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22932 #include <signal.h>
22935 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22937 else
22938 HAVE_SIGHANDLER_T=0
22944 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22945 /* <sys/types.h> is not needed according to POSIX, but the
22946 <sys/socket.h> in i386-unknown-freebsd4.10 and
22947 powerpc-apple-darwin5.5 required it. */
22948 #include <sys/types.h>
22949 #if HAVE_SYS_SOCKET_H
22950 # include <sys/socket.h>
22951 #elif HAVE_WS2TCPIP_H
22952 # include <ws2tcpip.h>
22953 #endif
22956 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22958 else
22959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22960 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22961 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22962 $as_echo_n "(cached) " >&6
22963 else
22964 # Systems have either "struct sockaddr *" or
22965 # "void *" as the second argument to getpeername
22966 gl_cv_socklen_t_equiv=
22967 for arg2 in "struct sockaddr" void; do
22968 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22970 /* end confdefs.h. */
22971 #include <sys/types.h>
22972 #include <sys/socket.h>
22974 int getpeername (int, $arg2 *, $t *);
22976 main ()
22978 $t len;
22979 getpeername (0, 0, &len);
22981 return 0;
22983 _ACEOF
22984 if ac_fn_c_try_compile "$LINENO"; then :
22985 gl_cv_socklen_t_equiv="$t"
22987 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22988 test "$gl_cv_socklen_t_equiv" != "" && break
22989 done
22990 test "$gl_cv_socklen_t_equiv" != "" && break
22991 done
22995 if test "$gl_cv_socklen_t_equiv" = ""; then
22996 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22999 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
23001 cat >>confdefs.h <<_ACEOF
23002 #define socklen_t $gl_cv_socklen_t_equiv
23003 _ACEOF
23008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
23009 $as_echo_n "checking for ssize_t... " >&6; }
23010 if test "${gt_cv_ssize_t+set}" = set; then :
23011 $as_echo_n "(cached) " >&6
23012 else
23013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23014 /* end confdefs.h. */
23015 #include <sys/types.h>
23017 main ()
23019 int x = sizeof (ssize_t *) + sizeof (ssize_t);
23020 return !x;
23022 return 0;
23024 _ACEOF
23025 if ac_fn_c_try_compile "$LINENO"; then :
23026 gt_cv_ssize_t=yes
23027 else
23028 gt_cv_ssize_t=no
23030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
23033 $as_echo "$gt_cv_ssize_t" >&6; }
23034 if test $gt_cv_ssize_t = no; then
23036 $as_echo "#define ssize_t int" >>confdefs.h
23044 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>
23045 #include <sys/stat.h>
23047 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
23049 cat >>confdefs.h <<_ACEOF
23050 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
23051 _ACEOF
23053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
23054 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
23055 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
23056 $as_echo_n "(cached) " >&6
23057 else
23058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23059 /* end confdefs.h. */
23061 #include <sys/types.h>
23062 #include <sys/stat.h>
23063 #if HAVE_SYS_TIME_H
23064 # include <sys/time.h>
23065 #endif
23066 #include <time.h>
23067 struct timespec ts;
23068 struct stat st;
23071 main ()
23074 st.st_atim = ts;
23077 return 0;
23079 _ACEOF
23080 if ac_fn_c_try_compile "$LINENO"; then :
23081 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
23082 else
23083 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
23085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
23088 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
23089 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
23091 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
23094 else
23095 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>
23096 #include <sys/stat.h>
23098 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
23100 cat >>confdefs.h <<_ACEOF
23101 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
23102 _ACEOF
23105 else
23106 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
23107 #include <sys/stat.h>
23109 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
23111 cat >>confdefs.h <<_ACEOF
23112 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
23113 _ACEOF
23116 else
23117 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>
23118 #include <sys/stat.h>
23120 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
23122 cat >>confdefs.h <<_ACEOF
23123 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
23124 _ACEOF
23139 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>
23140 #include <sys/stat.h>
23142 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
23144 cat >>confdefs.h <<_ACEOF
23145 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
23146 _ACEOF
23149 else
23150 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
23151 #include <sys/stat.h>
23153 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
23155 cat >>confdefs.h <<_ACEOF
23156 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
23157 _ACEOF
23160 else
23161 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>
23162 #include <sys/stat.h>
23164 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
23166 cat >>confdefs.h <<_ACEOF
23167 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
23168 _ACEOF
23179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
23180 $as_echo_n "checking for working stdalign.h... " >&6; }
23181 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
23182 $as_echo_n "(cached) " >&6
23183 else
23184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23185 /* end confdefs.h. */
23186 #include <stdalign.h>
23187 #include <stddef.h>
23189 /* Test that alignof yields a result consistent with offsetof.
23190 This catches GCC bug 52023
23191 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
23192 #ifdef __cplusplus
23193 template <class t> struct alignof_helper { char a; t b; };
23194 # define ao(type) offsetof (alignof_helper<type>, b)
23195 #else
23196 # define ao(type) offsetof (struct { char a; type b; }, b)
23197 #endif
23198 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
23199 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
23200 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
23202 /* Test _Alignas only on platforms where gnulib can help. */
23203 #if \
23204 (__GNUC__ || __IBMC__ || __IBMCPP__ \
23205 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
23206 int alignas (8) alignas_int = 1;
23207 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
23208 #endif
23211 main ()
23215 return 0;
23217 _ACEOF
23218 if ac_fn_c_try_compile "$LINENO"; then :
23219 gl_cv_header_working_stdalign_h=yes
23220 else
23221 gl_cv_header_working_stdalign_h=no
23223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
23226 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
23228 if test $gl_cv_header_working_stdalign_h = yes; then
23229 STDALIGN_H=''
23230 else
23231 STDALIGN_H='stdalign.h'
23235 if test -n "$STDALIGN_H"; then
23236 GL_GENERATE_STDALIGN_H_TRUE=
23237 GL_GENERATE_STDALIGN_H_FALSE='#'
23238 else
23239 GL_GENERATE_STDALIGN_H_TRUE='#'
23240 GL_GENERATE_STDALIGN_H_FALSE=
23245 STDARG_H=''
23246 NEXT_STDARG_H='<stdarg.h>'
23247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
23248 $as_echo_n "checking for va_copy... " >&6; }
23249 if test "${gl_cv_func_va_copy+set}" = set; then :
23250 $as_echo_n "(cached) " >&6
23251 else
23253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23254 /* end confdefs.h. */
23255 #include <stdarg.h>
23257 main ()
23260 #ifndef va_copy
23261 void (*func) (va_list, va_list) = va_copy;
23262 #endif
23265 return 0;
23267 _ACEOF
23268 if ac_fn_c_try_compile "$LINENO"; then :
23269 gl_cv_func_va_copy=yes
23270 else
23271 gl_cv_func_va_copy=no
23273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
23277 $as_echo "$gl_cv_func_va_copy" >&6; }
23278 if test $gl_cv_func_va_copy = no; then
23279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23280 /* end confdefs.h. */
23281 #if defined _AIX && !defined __GNUC__
23282 AIX vaccine
23283 #endif
23285 _ACEOF
23286 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23287 $EGREP "vaccine" >/dev/null 2>&1; then :
23288 gl_aixcc=yes
23289 else
23290 gl_aixcc=no
23292 rm -f conftest*
23294 if test $gl_aixcc = yes; then
23295 STDARG_H=stdarg.h
23304 if test $gl_cv_have_include_next = yes; then
23305 gl_cv_next_stdarg_h='<'stdarg.h'>'
23306 else
23307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
23308 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
23309 if test "${gl_cv_next_stdarg_h+set}" = set; then :
23310 $as_echo_n "(cached) " >&6
23311 else
23313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23314 /* end confdefs.h. */
23315 #include <stdarg.h>
23317 _ACEOF
23318 case "$host_os" in
23319 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23320 *) gl_absname_cpp="$ac_cpp" ;;
23321 esac
23323 case "$host_os" in
23324 mingw*)
23325 gl_dirsep_regex='[/\\]'
23328 gl_dirsep_regex='\/'
23330 esac
23331 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23333 gl_header_literal_regex=`echo 'stdarg.h' \
23334 | sed -e "$gl_make_literal_regex_sed"`
23335 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23336 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23337 s|^/[^/]|//&|
23341 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23342 sed -n "$gl_absolute_header_sed"`'"'
23346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
23347 $as_echo "$gl_cv_next_stdarg_h" >&6; }
23349 NEXT_STDARG_H=$gl_cv_next_stdarg_h
23351 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23352 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23353 gl_next_as_first_directive='<'stdarg.h'>'
23354 else
23355 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23356 gl_next_as_first_directive=$gl_cv_next_stdarg_h
23358 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
23363 if test "$gl_cv_next_stdarg_h" = '""'; then
23364 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
23365 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
23367 else
23369 saved_as_echo_n="$as_echo_n"
23370 as_echo_n=':'
23371 if test "${gl_cv_func___va_copy+set}" = set; then :
23372 $as_echo_n "(cached) " >&6
23373 else
23375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23376 /* end confdefs.h. */
23377 #include <stdarg.h>
23379 main ()
23382 #ifndef __va_copy
23383 error, bail out
23384 #endif
23387 return 0;
23389 _ACEOF
23390 if ac_fn_c_try_compile "$LINENO"; then :
23391 gl_cv_func___va_copy=yes
23392 else
23393 gl_cv_func___va_copy=no
23395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23398 as_echo_n="$saved_as_echo_n"
23400 if test $gl_cv_func___va_copy = yes; then
23402 $as_echo "#define va_copy __va_copy" >>confdefs.h
23404 else
23407 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
23413 if test -n "$STDARG_H"; then
23414 GL_GENERATE_STDARG_H_TRUE=
23415 GL_GENERATE_STDARG_H_FALSE='#'
23416 else
23417 GL_GENERATE_STDARG_H_TRUE='#'
23418 GL_GENERATE_STDARG_H_FALSE=
23426 # Define two additional variables used in the Makefile substitution.
23428 if test "$ac_cv_header_stdbool_h" = yes; then
23429 STDBOOL_H=''
23430 else
23431 STDBOOL_H='stdbool.h'
23434 if test -n "$STDBOOL_H"; then
23435 GL_GENERATE_STDBOOL_H_TRUE=
23436 GL_GENERATE_STDBOOL_H_FALSE='#'
23437 else
23438 GL_GENERATE_STDBOOL_H_TRUE='#'
23439 GL_GENERATE_STDBOOL_H_FALSE=
23443 if test "$ac_cv_type__Bool" = yes; then
23444 HAVE__BOOL=1
23445 else
23446 HAVE__BOOL=0
23453 STDDEF_H=
23454 if test $gt_cv_c_wchar_t = no; then
23455 HAVE_WCHAR_T=0
23456 STDDEF_H=stddef.h
23458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
23459 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
23460 if test "${gl_cv_decl_null_works+set}" = set; then :
23461 $as_echo_n "(cached) " >&6
23462 else
23463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23464 /* end confdefs.h. */
23465 #include <stddef.h>
23466 int test[2 * (sizeof NULL == sizeof (void *)) -1];
23469 main ()
23473 return 0;
23475 _ACEOF
23476 if ac_fn_c_try_compile "$LINENO"; then :
23477 gl_cv_decl_null_works=yes
23478 else
23479 gl_cv_decl_null_works=no
23481 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
23484 $as_echo "$gl_cv_decl_null_works" >&6; }
23485 if test $gl_cv_decl_null_works = no; then
23486 REPLACE_NULL=1
23487 STDDEF_H=stddef.h
23490 if test -n "$STDDEF_H"; then
23491 GL_GENERATE_STDDEF_H_TRUE=
23492 GL_GENERATE_STDDEF_H_FALSE='#'
23493 else
23494 GL_GENERATE_STDDEF_H_TRUE='#'
23495 GL_GENERATE_STDDEF_H_FALSE=
23498 if test -n "$STDDEF_H"; then
23507 if test $gl_cv_have_include_next = yes; then
23508 gl_cv_next_stddef_h='<'stddef.h'>'
23509 else
23510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
23511 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
23512 if test "${gl_cv_next_stddef_h+set}" = set; then :
23513 $as_echo_n "(cached) " >&6
23514 else
23516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23517 /* end confdefs.h. */
23518 #include <stddef.h>
23520 _ACEOF
23521 case "$host_os" in
23522 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23523 *) gl_absname_cpp="$ac_cpp" ;;
23524 esac
23526 case "$host_os" in
23527 mingw*)
23528 gl_dirsep_regex='[/\\]'
23531 gl_dirsep_regex='\/'
23533 esac
23534 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23536 gl_header_literal_regex=`echo 'stddef.h' \
23537 | sed -e "$gl_make_literal_regex_sed"`
23538 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23539 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23540 s|^/[^/]|//&|
23544 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23545 sed -n "$gl_absolute_header_sed"`'"'
23549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
23550 $as_echo "$gl_cv_next_stddef_h" >&6; }
23552 NEXT_STDDEF_H=$gl_cv_next_stddef_h
23554 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23555 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23556 gl_next_as_first_directive='<'stddef.h'>'
23557 else
23558 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23559 gl_next_as_first_directive=$gl_cv_next_stddef_h
23561 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
23579 if test $gl_cv_have_include_next = yes; then
23580 gl_cv_next_stdio_h='<'stdio.h'>'
23581 else
23582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
23583 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
23584 if test "${gl_cv_next_stdio_h+set}" = set; then :
23585 $as_echo_n "(cached) " >&6
23586 else
23588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23589 /* end confdefs.h. */
23590 #include <stdio.h>
23592 _ACEOF
23593 case "$host_os" in
23594 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23595 *) gl_absname_cpp="$ac_cpp" ;;
23596 esac
23598 case "$host_os" in
23599 mingw*)
23600 gl_dirsep_regex='[/\\]'
23603 gl_dirsep_regex='\/'
23605 esac
23606 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23608 gl_header_literal_regex=`echo 'stdio.h' \
23609 | sed -e "$gl_make_literal_regex_sed"`
23610 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23611 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23612 s|^/[^/]|//&|
23616 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23617 sed -n "$gl_absolute_header_sed"`'"'
23621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
23622 $as_echo "$gl_cv_next_stdio_h" >&6; }
23624 NEXT_STDIO_H=$gl_cv_next_stdio_h
23626 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23627 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23628 gl_next_as_first_directive='<'stdio.h'>'
23629 else
23630 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23631 gl_next_as_first_directive=$gl_cv_next_stdio_h
23633 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
23639 GNULIB_FSCANF=1
23642 cat >>confdefs.h <<_ACEOF
23643 #define GNULIB_FSCANF 1
23644 _ACEOF
23647 GNULIB_SCANF=1
23650 cat >>confdefs.h <<_ACEOF
23651 #define GNULIB_SCANF 1
23652 _ACEOF
23655 GNULIB_FGETC=1
23656 GNULIB_GETC=1
23657 GNULIB_GETCHAR=1
23658 GNULIB_FGETS=1
23659 GNULIB_FREAD=1
23662 GNULIB_FPRINTF=1
23663 GNULIB_PRINTF=1
23664 GNULIB_VFPRINTF=1
23665 GNULIB_VPRINTF=1
23666 GNULIB_FPUTC=1
23667 GNULIB_PUTC=1
23668 GNULIB_PUTCHAR=1
23669 GNULIB_FPUTS=1
23670 GNULIB_PUTS=1
23671 GNULIB_FWRITE=1
23687 if test $gl_cv_have_include_next = yes; then
23688 gl_cv_next_stdlib_h='<'stdlib.h'>'
23689 else
23690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
23691 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
23692 if test "${gl_cv_next_stdlib_h+set}" = set; then :
23693 $as_echo_n "(cached) " >&6
23694 else
23696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23697 /* end confdefs.h. */
23698 #include <stdlib.h>
23700 _ACEOF
23701 case "$host_os" in
23702 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23703 *) gl_absname_cpp="$ac_cpp" ;;
23704 esac
23706 case "$host_os" in
23707 mingw*)
23708 gl_dirsep_regex='[/\\]'
23711 gl_dirsep_regex='\/'
23713 esac
23714 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23716 gl_header_literal_regex=`echo 'stdlib.h' \
23717 | sed -e "$gl_make_literal_regex_sed"`
23718 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23719 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23720 s|^/[^/]|//&|
23724 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23725 sed -n "$gl_absolute_header_sed"`'"'
23729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
23730 $as_echo "$gl_cv_next_stdlib_h" >&6; }
23732 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
23734 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23735 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23736 gl_next_as_first_directive='<'stdlib.h'>'
23737 else
23738 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23739 gl_next_as_first_directive=$gl_cv_next_stdlib_h
23741 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
23751 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
23759 $as_echo "#define my_strftime nstrftime" >>confdefs.h
23768 if test "$ac_cv_have_decl_strtoimax" != yes; then
23769 HAVE_DECL_STRTOIMAX=0
23772 if test $ac_cv_func_strtoimax = yes; then
23773 HAVE_STRTOIMAX=1
23774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
23775 $as_echo_n "checking whether strtoimax works... " >&6; }
23776 if test "${gl_cv_func_strtoimax+set}" = set; then :
23777 $as_echo_n "(cached) " >&6
23778 else
23779 if test "$cross_compiling" = yes; then :
23780 case "$host_os" in
23781 # Guess no on AIX 5.
23782 aix5*) gl_cv_func_strtoimax="guessing no" ;;
23783 # Guess yes otherwise.
23784 *) gl_cv_func_strtoimax="guessing yes" ;;
23785 esac
23787 else
23788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23789 /* end confdefs.h. */
23791 #include <errno.h>
23792 #include <string.h>
23793 #include <inttypes.h>
23794 int main ()
23796 if (sizeof (intmax_t) > sizeof (int))
23798 const char *s = "4294967295";
23799 char *p;
23800 intmax_t res;
23801 errno = 0;
23802 res = strtoimax (s, &p, 10);
23803 if (p != s + strlen (s))
23804 return 1;
23805 if (errno != 0)
23806 return 2;
23807 if (res != (intmax_t) 65535 * (intmax_t) 65537)
23808 return 3;
23810 else
23812 const char *s = "2147483647";
23813 char *p;
23814 intmax_t res;
23815 errno = 0;
23816 res = strtoimax (s, &p, 10);
23817 if (p != s + strlen (s))
23818 return 1;
23819 if (errno != 0)
23820 return 2;
23821 if (res != 2147483647)
23822 return 3;
23824 return 0;
23827 _ACEOF
23828 if ac_fn_c_try_run "$LINENO"; then :
23829 gl_cv_func_strtoimax=yes
23830 else
23831 gl_cv_func_strtoimax=no
23833 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23834 conftest.$ac_objext conftest.beam conftest.$ac_ext
23839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
23840 $as_echo "$gl_cv_func_strtoimax" >&6; }
23841 case "$gl_cv_func_strtoimax" in
23842 *no) REPLACE_STRTOIMAX=1 ;;
23843 esac
23844 else
23845 HAVE_STRTOIMAX=0
23848 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23857 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
23860 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23861 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
23862 ac_have_decl=1
23863 else
23864 ac_have_decl=0
23867 cat >>confdefs.h <<_ACEOF
23868 #define HAVE_DECL_STRTOLL $ac_have_decl
23869 _ACEOF
23879 GNULIB_STRTOIMAX=1
23889 if test "$ac_cv_have_decl_strtoumax" != yes; then
23890 HAVE_DECL_STRTOUMAX=0
23893 if test $ac_cv_func_strtoumax = no; then
23902 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
23905 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23906 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
23907 ac_have_decl=1
23908 else
23909 ac_have_decl=0
23912 cat >>confdefs.h <<_ACEOF
23913 #define HAVE_DECL_STRTOULL $ac_have_decl
23914 _ACEOF
23924 GNULIB_STRTOUMAX=1
23932 if test $ac_cv_func_symlink = no; then
23933 HAVE_SYMLINK=0
23934 else
23935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23936 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23937 if test "${gl_cv_func_symlink_works+set}" = set; then :
23938 $as_echo_n "(cached) " >&6
23939 else
23940 if test "$cross_compiling" = yes; then :
23941 case "$host_os" in
23942 # Guess yes on glibc systems.
23943 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23944 # If we don't know, assume the worst.
23945 *) gl_cv_func_symlink_works="guessing no" ;;
23946 esac
23948 else
23949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23950 /* end confdefs.h. */
23951 #include <unistd.h>
23954 main ()
23956 int result = 0;
23957 if (!symlink ("a", "conftest.link/"))
23958 result |= 1;
23959 if (symlink ("conftest.f", "conftest.lnk2"))
23960 result |= 2;
23961 else if (!symlink ("a", "conftest.lnk2/"))
23962 result |= 4;
23963 return result;
23966 return 0;
23968 _ACEOF
23969 if ac_fn_c_try_run "$LINENO"; then :
23970 gl_cv_func_symlink_works=yes
23971 else
23972 gl_cv_func_symlink_works=no
23974 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23975 conftest.$ac_objext conftest.beam conftest.$ac_ext
23978 rm -f conftest.f conftest.link conftest.lnk2
23980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23981 $as_echo "$gl_cv_func_symlink_works" >&6; }
23982 case "$gl_cv_func_symlink_works" in
23983 *yes) ;;
23985 REPLACE_SYMLINK=1
23987 esac
23990 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23999 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
24007 GNULIB_SYMLINK=1
24016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
24017 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
24018 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
24019 $as_echo_n "(cached) " >&6
24020 else
24022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24023 /* end confdefs.h. */
24024 #include <sys/select.h>
24026 main ()
24028 struct timeval b;
24030 return 0;
24032 _ACEOF
24033 if ac_fn_c_try_compile "$LINENO"; then :
24034 gl_cv_header_sys_select_h_selfcontained=yes
24035 else
24036 gl_cv_header_sys_select_h_selfcontained=no
24038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24039 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
24040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24041 /* end confdefs.h. */
24042 #include <sys/select.h>
24044 main ()
24046 int memset; int bzero;
24048 return 0;
24051 _ACEOF
24052 if ac_fn_c_try_compile "$LINENO"; then :
24053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24054 /* end confdefs.h. */
24055 #include <sys/select.h>
24057 main ()
24060 #undef memset
24061 #define memset nonexistent_memset
24062 extern
24063 #ifdef __cplusplus
24065 #endif
24066 void *memset (void *, int, unsigned long);
24067 #undef bzero
24068 #define bzero nonexistent_bzero
24069 extern
24070 #ifdef __cplusplus
24072 #endif
24073 void bzero (void *, unsigned long);
24074 fd_set fds;
24075 FD_ZERO (&fds);
24078 return 0;
24081 _ACEOF
24082 if ac_fn_c_try_link "$LINENO"; then :
24084 else
24085 gl_cv_header_sys_select_h_selfcontained=no
24087 rm -f core conftest.err conftest.$ac_objext \
24088 conftest$ac_exeext conftest.$ac_ext
24091 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
24096 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
24106 if test $gl_cv_have_include_next = yes; then
24107 gl_cv_next_sys_select_h='<'sys/select.h'>'
24108 else
24109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
24110 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
24111 if test "${gl_cv_next_sys_select_h+set}" = set; then :
24112 $as_echo_n "(cached) " >&6
24113 else
24115 if test $ac_cv_header_sys_select_h = yes; then
24118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24119 /* end confdefs.h. */
24120 #include <sys/select.h>
24122 _ACEOF
24123 case "$host_os" in
24124 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24125 *) gl_absname_cpp="$ac_cpp" ;;
24126 esac
24128 case "$host_os" in
24129 mingw*)
24130 gl_dirsep_regex='[/\\]'
24133 gl_dirsep_regex='\/'
24135 esac
24136 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24138 gl_header_literal_regex=`echo 'sys/select.h' \
24139 | sed -e "$gl_make_literal_regex_sed"`
24140 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24141 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24142 s|^/[^/]|//&|
24146 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24147 sed -n "$gl_absolute_header_sed"`'"'
24148 else
24149 gl_cv_next_sys_select_h='<'sys/select.h'>'
24154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
24155 $as_echo "$gl_cv_next_sys_select_h" >&6; }
24157 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
24159 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24160 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24161 gl_next_as_first_directive='<'sys/select.h'>'
24162 else
24163 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24164 gl_next_as_first_directive=$gl_cv_next_sys_select_h
24166 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
24171 if test $ac_cv_header_sys_select_h = yes; then
24172 HAVE_SYS_SELECT_H=1
24173 else
24174 HAVE_SYS_SELECT_H=0
24181 if test $ac_cv_header_sys_socket_h != yes; then
24182 for ac_header in winsock2.h
24183 do :
24184 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
24185 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
24186 cat >>confdefs.h <<_ACEOF
24187 #define HAVE_WINSOCK2_H 1
24188 _ACEOF
24192 done
24195 if test "$ac_cv_header_winsock2_h" = yes; then
24196 HAVE_WINSOCK2_H=1
24197 UNISTD_H_HAVE_WINSOCK2_H=1
24198 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
24199 else
24200 HAVE_WINSOCK2_H=0
24222 if test $gl_cv_have_include_next = yes; then
24223 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24224 else
24225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
24226 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
24227 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
24228 $as_echo_n "(cached) " >&6
24229 else
24231 if test $ac_cv_header_sys_stat_h = yes; then
24234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24235 /* end confdefs.h. */
24236 #include <sys/stat.h>
24238 _ACEOF
24239 case "$host_os" in
24240 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24241 *) gl_absname_cpp="$ac_cpp" ;;
24242 esac
24244 case "$host_os" in
24245 mingw*)
24246 gl_dirsep_regex='[/\\]'
24249 gl_dirsep_regex='\/'
24251 esac
24252 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24254 gl_header_literal_regex=`echo 'sys/stat.h' \
24255 | sed -e "$gl_make_literal_regex_sed"`
24256 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24257 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24258 s|^/[^/]|//&|
24262 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24263 sed -n "$gl_absolute_header_sed"`'"'
24264 else
24265 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
24270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
24271 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
24273 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
24275 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24276 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24277 gl_next_as_first_directive='<'sys/stat.h'>'
24278 else
24279 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24280 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
24282 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
24294 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
24296 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
24300 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
24301 #include <sys/stat.h>
24303 if test "x$ac_cv_type_nlink_t" = x""yes; then :
24305 else
24307 $as_echo "#define nlink_t int" >>confdefs.h
24328 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
24330 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
24331 ac_have_decl=1
24332 else
24333 ac_have_decl=0
24336 cat >>confdefs.h <<_ACEOF
24337 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
24338 _ACEOF
24340 if test $ac_cv_have_decl_localtime_r = no; then
24341 HAVE_DECL_LOCALTIME_R=0
24345 if test $ac_cv_func_localtime_r = yes; then
24346 HAVE_LOCALTIME_R=1
24347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
24348 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
24349 if test "${gl_cv_time_r_posix+set}" = set; then :
24350 $as_echo_n "(cached) " >&6
24351 else
24352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24353 /* end confdefs.h. */
24354 #include <time.h>
24356 main ()
24358 /* We don't need to append 'restrict's to the argument types,
24359 even though the POSIX signature has the 'restrict's,
24360 since C99 says they can't affect type compatibility. */
24361 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
24362 if (ptr) return 0;
24363 /* Check the return type is a pointer.
24364 On HP-UX 10 it is 'int'. */
24365 *localtime_r (0, 0);
24367 return 0;
24370 _ACEOF
24371 if ac_fn_c_try_compile "$LINENO"; then :
24372 gl_cv_time_r_posix=yes
24373 else
24374 gl_cv_time_r_posix=no
24376 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
24380 $as_echo "$gl_cv_time_r_posix" >&6; }
24381 if test $gl_cv_time_r_posix = yes; then
24382 REPLACE_LOCALTIME_R=0
24383 else
24384 REPLACE_LOCALTIME_R=1
24386 else
24387 HAVE_LOCALTIME_R=0
24390 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
24399 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
24410 GNULIB_TIME_R=1
24421 LIB_TIMER_TIME=
24423 gl_saved_libs=$LIBS
24424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
24425 $as_echo_n "checking for library containing timer_settime... " >&6; }
24426 if test "${ac_cv_search_timer_settime+set}" = set; then :
24427 $as_echo_n "(cached) " >&6
24428 else
24429 ac_func_search_save_LIBS=$LIBS
24430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24431 /* end confdefs.h. */
24433 /* Override any GCC internal prototype to avoid an error.
24434 Use char because int might match the return type of a GCC
24435 builtin and then its argument prototype would still apply. */
24436 #ifdef __cplusplus
24437 extern "C"
24438 #endif
24439 char timer_settime ();
24441 main ()
24443 return timer_settime ();
24445 return 0;
24447 _ACEOF
24448 for ac_lib in '' rt posix4; do
24449 if test -z "$ac_lib"; then
24450 ac_res="none required"
24451 else
24452 ac_res=-l$ac_lib
24453 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
24455 if ac_fn_c_try_link "$LINENO"; then :
24456 ac_cv_search_timer_settime=$ac_res
24458 rm -f core conftest.err conftest.$ac_objext \
24459 conftest$ac_exeext
24460 if test "${ac_cv_search_timer_settime+set}" = set; then :
24461 break
24463 done
24464 if test "${ac_cv_search_timer_settime+set}" = set; then :
24466 else
24467 ac_cv_search_timer_settime=no
24469 rm conftest.$ac_ext
24470 LIBS=$ac_func_search_save_LIBS
24472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
24473 $as_echo "$ac_cv_search_timer_settime" >&6; }
24474 ac_res=$ac_cv_search_timer_settime
24475 if test "$ac_res" != no; then :
24476 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24477 test "$ac_cv_search_timer_settime" = "none required" ||
24478 LIB_TIMER_TIME=$ac_cv_search_timer_settime
24481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24482 /* end confdefs.h. */
24484 #include <features.h>
24485 #ifdef __GNU_LIBRARY__
24486 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
24487 && !defined __UCLIBC__
24488 Thread emulation available
24489 #endif
24490 #endif
24492 _ACEOF
24493 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24494 $EGREP "Thread" >/dev/null 2>&1; then :
24495 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
24497 rm -f conftest*
24499 for ac_func in timer_settime
24500 do :
24501 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
24502 if test "x$ac_cv_func_timer_settime" = x""yes; then :
24503 cat >>confdefs.h <<_ACEOF
24504 #define HAVE_TIMER_SETTIME 1
24505 _ACEOF
24508 done
24510 LIBS=$gl_saved_libs
24525 if test $gl_cv_have_include_next = yes; then
24526 gl_cv_next_unistd_h='<'unistd.h'>'
24527 else
24528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
24529 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
24530 if test "${gl_cv_next_unistd_h+set}" = set; then :
24531 $as_echo_n "(cached) " >&6
24532 else
24534 if test $ac_cv_header_unistd_h = yes; then
24537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24538 /* end confdefs.h. */
24539 #include <unistd.h>
24541 _ACEOF
24542 case "$host_os" in
24543 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24544 *) gl_absname_cpp="$ac_cpp" ;;
24545 esac
24547 case "$host_os" in
24548 mingw*)
24549 gl_dirsep_regex='[/\\]'
24552 gl_dirsep_regex='\/'
24554 esac
24555 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24557 gl_header_literal_regex=`echo 'unistd.h' \
24558 | sed -e "$gl_make_literal_regex_sed"`
24559 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24560 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24561 s|^/[^/]|//&|
24565 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24566 sed -n "$gl_absolute_header_sed"`'"'
24567 else
24568 gl_cv_next_unistd_h='<'unistd.h'>'
24573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
24574 $as_echo "$gl_cv_next_unistd_h" >&6; }
24576 NEXT_UNISTD_H=$gl_cv_next_unistd_h
24578 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24579 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24580 gl_next_as_first_directive='<'unistd.h'>'
24581 else
24582 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24583 gl_next_as_first_directive=$gl_cv_next_unistd_h
24585 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
24590 if test $ac_cv_header_unistd_h = yes; then
24591 HAVE_UNISTD_H=1
24592 else
24593 HAVE_UNISTD_H=0
24606 if test $ac_cv_have_decl_unsetenv = no; then
24607 HAVE_DECL_UNSETENV=0
24609 for ac_func in unsetenv
24610 do :
24611 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
24612 if test "x$ac_cv_func_unsetenv" = x""yes; then :
24613 cat >>confdefs.h <<_ACEOF
24614 #define HAVE_UNSETENV 1
24615 _ACEOF
24618 done
24620 if test $ac_cv_func_unsetenv = no; then
24621 HAVE_UNSETENV=0
24622 else
24623 HAVE_UNSETENV=1
24624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
24625 $as_echo_n "checking for unsetenv() return type... " >&6; }
24626 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
24627 $as_echo_n "(cached) " >&6
24628 else
24629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24630 /* end confdefs.h. */
24632 #undef _BSD
24633 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
24634 #include <stdlib.h>
24635 extern
24636 #ifdef __cplusplus
24638 #endif
24639 int unsetenv (const char *name);
24642 main ()
24646 return 0;
24648 _ACEOF
24649 if ac_fn_c_try_compile "$LINENO"; then :
24650 gt_cv_func_unsetenv_ret='int'
24651 else
24652 gt_cv_func_unsetenv_ret='void'
24654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
24657 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
24658 if test $gt_cv_func_unsetenv_ret = 'void'; then
24660 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
24662 REPLACE_UNSETENV=1
24665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
24666 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
24667 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
24668 $as_echo_n "(cached) " >&6
24669 else
24670 if test "$cross_compiling" = yes; then :
24671 case "$host_os" in
24672 # Guess yes on glibc systems.
24673 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
24674 # If we don't know, assume the worst.
24675 *) gl_cv_func_unsetenv_works="guessing no" ;;
24676 esac
24678 else
24679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24680 /* end confdefs.h. */
24682 #include <stdlib.h>
24683 #include <errno.h>
24684 extern char **environ;
24687 main ()
24690 char entry1[] = "a=1";
24691 char entry2[] = "b=2";
24692 char *env[] = { entry1, entry2, NULL };
24693 if (putenv ((char *) "a=1")) return 1;
24694 if (putenv (entry2)) return 2;
24695 entry2[0] = 'a';
24696 unsetenv ("a");
24697 if (getenv ("a")) return 3;
24698 if (!unsetenv ("") || errno != EINVAL) return 4;
24699 entry2[0] = 'b';
24700 environ = env;
24701 if (!getenv ("a")) return 5;
24702 entry2[0] = 'a';
24703 unsetenv ("a");
24704 if (getenv ("a")) return 6;
24707 return 0;
24709 _ACEOF
24710 if ac_fn_c_try_run "$LINENO"; then :
24711 gl_cv_func_unsetenv_works=yes
24712 else
24713 gl_cv_func_unsetenv_works=no
24715 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24716 conftest.$ac_objext conftest.beam conftest.$ac_ext
24720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
24721 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
24722 case "$gl_cv_func_unsetenv_works" in
24723 *yes) ;;
24725 REPLACE_UNSETENV=1
24727 esac
24730 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
24739 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
24751 GNULIB_UNSETENV=1
24763 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
24764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
24765 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
24766 if test "${gl_cv_func_futimesat_works+set}" = set; then :
24767 $as_echo_n "(cached) " >&6
24768 else
24769 touch conftest.file
24770 if test "$cross_compiling" = yes; then :
24771 case "$host_os" in
24772 # Guess yes on glibc systems.
24773 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
24774 # If we don't know, assume the worst.
24775 *) gl_cv_func_futimesat_works="guessing no" ;;
24776 esac
24778 else
24779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24780 /* end confdefs.h. */
24782 #include <stddef.h>
24783 #include <sys/times.h>
24784 #include <fcntl.h>
24787 main ()
24789 int fd = open ("conftest.file", O_RDWR);
24790 if (fd < 0) return 1;
24791 if (futimesat (fd, NULL, NULL)) return 2;
24794 return 0;
24796 _ACEOF
24797 if ac_fn_c_try_run "$LINENO"; then :
24798 gl_cv_func_futimesat_works=yes
24799 else
24800 gl_cv_func_futimesat_works=no
24802 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24803 conftest.$ac_objext conftest.beam conftest.$ac_ext
24806 rm -f conftest.file
24808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
24809 $as_echo "$gl_cv_func_futimesat_works" >&6; }
24810 case "$gl_cv_func_futimesat_works" in
24811 *yes) ;;
24814 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
24817 esac
24820 gl_gnulib_enabled_dosname=false
24821 gl_gnulib_enabled_euidaccess=false
24822 gl_gnulib_enabled_getgroups=false
24823 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
24824 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
24825 gl_gnulib_enabled_pathmax=false
24826 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
24827 gl_gnulib_enabled_stat=false
24828 gl_gnulib_enabled_strtoll=false
24829 gl_gnulib_enabled_strtoull=false
24830 gl_gnulib_enabled_verify=false
24831 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
24832 func_gl_gnulib_m4code_dosname ()
24834 if ! $gl_gnulib_enabled_dosname; then
24835 gl_gnulib_enabled_dosname=true
24838 func_gl_gnulib_m4code_euidaccess ()
24840 if ! $gl_gnulib_enabled_euidaccess; then
24846 for ac_func in euidaccess
24847 do :
24848 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
24849 if test "x$ac_cv_func_euidaccess" = x""yes; then :
24850 cat >>confdefs.h <<_ACEOF
24851 #define HAVE_EUIDACCESS 1
24852 _ACEOF
24855 done
24857 if test $ac_cv_func_euidaccess = no; then
24858 HAVE_EUIDACCESS=0
24861 if test $HAVE_EUIDACCESS = 0; then
24870 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
24874 for ac_header in libgen.h
24875 do :
24876 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
24877 if test "x$ac_cv_header_libgen_h" = x""yes; then :
24878 cat >>confdefs.h <<_ACEOF
24879 #define HAVE_LIBGEN_H 1
24880 _ACEOF
24884 done
24887 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
24888 if test "x$ac_cv_func_getgroups" = x""yes; then :
24893 # If we don't yet have getgroups, see if it's in -lbsd.
24894 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
24895 ac_save_LIBS=$LIBS
24896 if test $ac_cv_func_getgroups = no; then
24897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
24898 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
24899 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
24900 $as_echo_n "(cached) " >&6
24901 else
24902 ac_check_lib_save_LIBS=$LIBS
24903 LIBS="-lbsd $LIBS"
24904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24905 /* end confdefs.h. */
24907 /* Override any GCC internal prototype to avoid an error.
24908 Use char because int might match the return type of a GCC
24909 builtin and then its argument prototype would still apply. */
24910 #ifdef __cplusplus
24911 extern "C"
24912 #endif
24913 char getgroups ();
24915 main ()
24917 return getgroups ();
24919 return 0;
24921 _ACEOF
24922 if ac_fn_c_try_link "$LINENO"; then :
24923 ac_cv_lib_bsd_getgroups=yes
24924 else
24925 ac_cv_lib_bsd_getgroups=no
24927 rm -f core conftest.err conftest.$ac_objext \
24928 conftest$ac_exeext conftest.$ac_ext
24929 LIBS=$ac_check_lib_save_LIBS
24931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
24932 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
24933 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
24934 GETGROUPS_LIB=-lbsd
24939 # Run the program to test the functionality of the system-supplied
24940 # getgroups function only if there is such a function.
24941 if test $ac_cv_func_getgroups = yes; then
24942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
24943 $as_echo_n "checking for working getgroups... " >&6; }
24944 if test "${ac_cv_func_getgroups_works+set}" = set; then :
24945 $as_echo_n "(cached) " >&6
24946 else
24947 if test "$cross_compiling" = yes; then :
24948 case "$host_os" in # ((
24949 # Guess yes on glibc systems.
24950 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
24951 # If we don't know, assume the worst.
24952 *) ac_cv_func_getgroups_works="guessing no" ;;
24953 esac
24955 else
24956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24957 /* end confdefs.h. */
24958 $ac_includes_default
24960 main ()
24962 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
24963 return getgroups (0, 0) == -1;
24965 return 0;
24968 _ACEOF
24969 if ac_fn_c_try_run "$LINENO"; then :
24970 ac_cv_func_getgroups_works=yes
24971 else
24972 ac_cv_func_getgroups_works=no
24974 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24975 conftest.$ac_objext conftest.beam conftest.$ac_ext
24980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
24981 $as_echo "$ac_cv_func_getgroups_works" >&6; }
24982 else
24983 ac_cv_func_getgroups_works=no
24985 case "$ac_cv_func_getgroups_works" in
24986 *yes)
24988 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
24991 esac
24992 LIBS=$ac_save_LIBS
24995 # Solaris 9 and 10 need -lgen to get the eaccess function.
24996 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
24997 # programs in the package would end up linked with that potentially-shared
24998 # library, inducing unnecessary run-time overhead.
24999 LIB_EACCESS=
25001 gl_saved_libs=$LIBS
25002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
25003 $as_echo_n "checking for library containing eaccess... " >&6; }
25004 if test "${ac_cv_search_eaccess+set}" = set; then :
25005 $as_echo_n "(cached) " >&6
25006 else
25007 ac_func_search_save_LIBS=$LIBS
25008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25009 /* end confdefs.h. */
25011 /* Override any GCC internal prototype to avoid an error.
25012 Use char because int might match the return type of a GCC
25013 builtin and then its argument prototype would still apply. */
25014 #ifdef __cplusplus
25015 extern "C"
25016 #endif
25017 char eaccess ();
25019 main ()
25021 return eaccess ();
25023 return 0;
25025 _ACEOF
25026 for ac_lib in '' gen; do
25027 if test -z "$ac_lib"; then
25028 ac_res="none required"
25029 else
25030 ac_res=-l$ac_lib
25031 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25033 if ac_fn_c_try_link "$LINENO"; then :
25034 ac_cv_search_eaccess=$ac_res
25036 rm -f core conftest.err conftest.$ac_objext \
25037 conftest$ac_exeext
25038 if test "${ac_cv_search_eaccess+set}" = set; then :
25039 break
25041 done
25042 if test "${ac_cv_search_eaccess+set}" = set; then :
25044 else
25045 ac_cv_search_eaccess=no
25047 rm conftest.$ac_ext
25048 LIBS=$ac_func_search_save_LIBS
25050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
25051 $as_echo "$ac_cv_search_eaccess" >&6; }
25052 ac_res=$ac_cv_search_eaccess
25053 if test "$ac_res" != no; then :
25054 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25055 test "$ac_cv_search_eaccess" = "none required" ||
25056 LIB_EACCESS=$ac_cv_search_eaccess
25059 for ac_func in eaccess
25060 do :
25061 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
25062 if test "x$ac_cv_func_eaccess" = x""yes; then :
25063 cat >>confdefs.h <<_ACEOF
25064 #define HAVE_EACCESS 1
25065 _ACEOF
25068 done
25070 LIBS=$gl_saved_libs
25078 GNULIB_EUIDACCESS=1
25084 gl_gnulib_enabled_euidaccess=true
25085 if test $HAVE_EUIDACCESS = 0; then
25086 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
25088 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
25089 if test $HAVE_EUIDACCESS = 0; then
25090 func_gl_gnulib_m4code_stat
25094 func_gl_gnulib_m4code_getgroups ()
25096 if ! $gl_gnulib_enabled_getgroups; then
25102 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
25103 if test "x$ac_cv_func_getgroups" = x""yes; then :
25108 # If we don't yet have getgroups, see if it's in -lbsd.
25109 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
25110 ac_save_LIBS=$LIBS
25111 if test $ac_cv_func_getgroups = no; then
25112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
25113 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
25114 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
25115 $as_echo_n "(cached) " >&6
25116 else
25117 ac_check_lib_save_LIBS=$LIBS
25118 LIBS="-lbsd $LIBS"
25119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25120 /* end confdefs.h. */
25122 /* Override any GCC internal prototype to avoid an error.
25123 Use char because int might match the return type of a GCC
25124 builtin and then its argument prototype would still apply. */
25125 #ifdef __cplusplus
25126 extern "C"
25127 #endif
25128 char getgroups ();
25130 main ()
25132 return getgroups ();
25134 return 0;
25136 _ACEOF
25137 if ac_fn_c_try_link "$LINENO"; then :
25138 ac_cv_lib_bsd_getgroups=yes
25139 else
25140 ac_cv_lib_bsd_getgroups=no
25142 rm -f core conftest.err conftest.$ac_objext \
25143 conftest$ac_exeext conftest.$ac_ext
25144 LIBS=$ac_check_lib_save_LIBS
25146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
25147 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
25148 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
25149 GETGROUPS_LIB=-lbsd
25154 # Run the program to test the functionality of the system-supplied
25155 # getgroups function only if there is such a function.
25156 if test $ac_cv_func_getgroups = yes; then
25157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
25158 $as_echo_n "checking for working getgroups... " >&6; }
25159 if test "${ac_cv_func_getgroups_works+set}" = set; then :
25160 $as_echo_n "(cached) " >&6
25161 else
25162 if test "$cross_compiling" = yes; then :
25163 case "$host_os" in # ((
25164 # Guess yes on glibc systems.
25165 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
25166 # If we don't know, assume the worst.
25167 *) ac_cv_func_getgroups_works="guessing no" ;;
25168 esac
25170 else
25171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25172 /* end confdefs.h. */
25173 $ac_includes_default
25175 main ()
25177 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
25178 return getgroups (0, 0) == -1;
25180 return 0;
25183 _ACEOF
25184 if ac_fn_c_try_run "$LINENO"; then :
25185 ac_cv_func_getgroups_works=yes
25186 else
25187 ac_cv_func_getgroups_works=no
25189 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25190 conftest.$ac_objext conftest.beam conftest.$ac_ext
25195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
25196 $as_echo "$ac_cv_func_getgroups_works" >&6; }
25197 else
25198 ac_cv_func_getgroups_works=no
25200 case "$ac_cv_func_getgroups_works" in
25201 *yes)
25203 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
25206 esac
25207 LIBS=$ac_save_LIBS
25209 if test $ac_cv_func_getgroups != yes; then
25210 HAVE_GETGROUPS=0
25211 else
25212 if test "$ac_cv_type_getgroups" != gid_t \
25213 || { case "$ac_cv_func_getgroups_works" in
25214 *yes) false;;
25215 *) true;;
25216 esac
25217 }; then
25218 REPLACE_GETGROUPS=1
25220 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
25222 else
25223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
25224 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
25225 if test "${gl_cv_func_getgroups_works+set}" = set; then :
25226 $as_echo_n "(cached) " >&6
25227 else
25228 if test "$cross_compiling" = yes; then :
25229 case "$host_os" in
25230 # Guess yes on glibc systems.
25231 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
25232 # If we don't know, assume the worst.
25233 *) gl_cv_func_getgroups_works="guessing no" ;;
25234 esac
25236 else
25237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25238 /* end confdefs.h. */
25239 $ac_includes_default
25241 main ()
25243 int size = getgroups (0, 0);
25244 gid_t *list = malloc (size * sizeof *list);
25245 return getgroups (-1, list) != -1;
25247 return 0;
25249 _ACEOF
25250 if ac_fn_c_try_run "$LINENO"; then :
25251 gl_cv_func_getgroups_works=yes
25252 else
25253 gl_cv_func_getgroups_works=no
25255 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25256 conftest.$ac_objext conftest.beam conftest.$ac_ext
25260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
25261 $as_echo "$gl_cv_func_getgroups_works" >&6; }
25262 case "$gl_cv_func_getgroups_works" in
25263 *yes) ;;
25264 *) REPLACE_GETGROUPS=1 ;;
25265 esac
25268 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
25270 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
25279 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
25287 GNULIB_GETGROUPS=1
25293 gl_gnulib_enabled_getgroups=true
25296 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
25298 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
25301 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
25304 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
25306 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
25312 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
25313 if test "x$ac_cv_func_group_member" = x""yes; then :
25315 else
25317 HAVE_GROUP_MEMBER=0
25322 if test $HAVE_GROUP_MEMBER = 0; then
25331 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
25342 GNULIB_GROUP_MEMBER=1
25348 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
25349 if test $HAVE_GROUP_MEMBER = 0; then
25350 func_gl_gnulib_m4code_getgroups
25352 if test $HAVE_GROUP_MEMBER = 0; then
25353 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
25357 func_gl_gnulib_m4code_pathmax ()
25359 if ! $gl_gnulib_enabled_pathmax; then
25363 gl_gnulib_enabled_pathmax=true
25366 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
25368 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
25369 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
25372 func_gl_gnulib_m4code_stat ()
25374 if ! $gl_gnulib_enabled_stat; then
25378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
25379 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
25380 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
25381 $as_echo_n "(cached) " >&6
25382 else
25383 if test "$cross_compiling" = yes; then :
25384 case $host_os in
25385 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
25386 *) gl_cv_func_stat_dir_slash="guessing yes";;
25387 esac
25388 else
25389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25390 /* end confdefs.h. */
25391 #include <sys/stat.h>
25394 main ()
25396 struct stat st; return stat (".", &st) != stat ("./", &st);
25398 return 0;
25400 _ACEOF
25401 if ac_fn_c_try_run "$LINENO"; then :
25402 gl_cv_func_stat_dir_slash=yes
25403 else
25404 gl_cv_func_stat_dir_slash=no
25406 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25407 conftest.$ac_objext conftest.beam conftest.$ac_ext
25411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
25412 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
25413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
25414 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
25415 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
25416 $as_echo_n "(cached) " >&6
25417 else
25418 touch conftest.tmp
25419 # Assume that if we have lstat, we can also check symlinks.
25420 if test $ac_cv_func_lstat = yes; then
25421 ln -s conftest.tmp conftest.lnk
25423 if test "$cross_compiling" = yes; then :
25424 case "$host_os" in
25425 # Guess yes on glibc systems.
25426 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
25427 # If we don't know, assume the worst.
25428 *) gl_cv_func_stat_file_slash="guessing no" ;;
25429 esac
25431 else
25432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25433 /* end confdefs.h. */
25434 #include <sys/stat.h>
25437 main ()
25439 int result = 0;
25440 struct stat st;
25441 if (!stat ("conftest.tmp/", &st))
25442 result |= 1;
25443 #if HAVE_LSTAT
25444 if (!stat ("conftest.lnk/", &st))
25445 result |= 2;
25446 #endif
25447 return result;
25450 return 0;
25452 _ACEOF
25453 if ac_fn_c_try_run "$LINENO"; then :
25454 gl_cv_func_stat_file_slash=yes
25455 else
25456 gl_cv_func_stat_file_slash=no
25458 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25459 conftest.$ac_objext conftest.beam conftest.$ac_ext
25462 rm -f conftest.tmp conftest.lnk
25464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
25465 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
25466 case $gl_cv_func_stat_dir_slash in
25467 *no) REPLACE_STAT=1
25469 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
25471 esac
25472 case $gl_cv_func_stat_file_slash in
25473 *no) REPLACE_STAT=1
25475 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
25477 esac
25479 if test $REPLACE_STAT = 1; then
25488 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
25497 GNULIB_STAT=1
25503 gl_gnulib_enabled_stat=true
25504 if test $REPLACE_STAT = 1; then
25505 func_gl_gnulib_m4code_dosname
25507 if test $REPLACE_STAT = 1; then
25508 func_gl_gnulib_m4code_pathmax
25510 if test $REPLACE_STAT = 1; then
25511 func_gl_gnulib_m4code_verify
25515 func_gl_gnulib_m4code_strtoll ()
25517 if ! $gl_gnulib_enabled_strtoll; then
25521 if test "$ac_cv_type_long_long_int" = yes; then
25522 for ac_func in strtoll
25523 do :
25524 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
25525 if test "x$ac_cv_func_strtoll" = x""yes; then :
25526 cat >>confdefs.h <<_ACEOF
25527 #define HAVE_STRTOLL 1
25528 _ACEOF
25531 done
25533 if test $ac_cv_func_strtoll = no; then
25534 HAVE_STRTOLL=0
25538 if test $HAVE_STRTOLL = 0; then
25547 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
25558 GNULIB_STRTOLL=1
25564 gl_gnulib_enabled_strtoll=true
25567 func_gl_gnulib_m4code_strtoull ()
25569 if ! $gl_gnulib_enabled_strtoull; then
25573 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
25574 for ac_func in strtoull
25575 do :
25576 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
25577 if test "x$ac_cv_func_strtoull" = x""yes; then :
25578 cat >>confdefs.h <<_ACEOF
25579 #define HAVE_STRTOULL 1
25580 _ACEOF
25583 done
25585 if test $ac_cv_func_strtoull = no; then
25586 HAVE_STRTOULL=0
25590 if test $HAVE_STRTOULL = 0; then
25599 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
25610 GNULIB_STRTOULL=1
25616 gl_gnulib_enabled_strtoull=true
25619 func_gl_gnulib_m4code_verify ()
25621 if ! $gl_gnulib_enabled_verify; then
25622 gl_gnulib_enabled_verify=true
25625 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
25627 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
25628 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
25631 if test $HAVE_FACCESSAT = 0; then
25632 func_gl_gnulib_m4code_dosname
25634 if test $HAVE_FACCESSAT = 0; then
25635 func_gl_gnulib_m4code_euidaccess
25637 if test $REPLACE_GETOPT = 1; then
25638 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
25640 if test $REPLACE_LSTAT = 1; then
25641 func_gl_gnulib_m4code_dosname
25643 if test $REPLACE_LSTAT = 1; then
25644 func_gl_gnulib_m4code_stat
25646 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25647 func_gl_gnulib_m4code_stat
25649 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
25650 func_gl_gnulib_m4code_strtoll
25652 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
25653 func_gl_gnulib_m4code_verify
25655 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
25656 func_gl_gnulib_m4code_strtoull
25658 if test $ac_cv_func_strtoumax = no; then
25659 func_gl_gnulib_m4code_verify
25662 if $gl_gnulib_enabled_dosname; then
25663 gl_GNULIB_ENABLED_dosname_TRUE=
25664 gl_GNULIB_ENABLED_dosname_FALSE='#'
25665 else
25666 gl_GNULIB_ENABLED_dosname_TRUE='#'
25667 gl_GNULIB_ENABLED_dosname_FALSE=
25670 if $gl_gnulib_enabled_euidaccess; then
25671 gl_GNULIB_ENABLED_euidaccess_TRUE=
25672 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
25673 else
25674 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
25675 gl_GNULIB_ENABLED_euidaccess_FALSE=
25678 if $gl_gnulib_enabled_getgroups; then
25679 gl_GNULIB_ENABLED_getgroups_TRUE=
25680 gl_GNULIB_ENABLED_getgroups_FALSE='#'
25681 else
25682 gl_GNULIB_ENABLED_getgroups_TRUE='#'
25683 gl_GNULIB_ENABLED_getgroups_FALSE=
25686 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
25687 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
25688 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
25689 else
25690 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
25691 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
25694 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
25695 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
25696 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
25697 else
25698 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
25699 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
25702 if $gl_gnulib_enabled_pathmax; then
25703 gl_GNULIB_ENABLED_pathmax_TRUE=
25704 gl_GNULIB_ENABLED_pathmax_FALSE='#'
25705 else
25706 gl_GNULIB_ENABLED_pathmax_TRUE='#'
25707 gl_GNULIB_ENABLED_pathmax_FALSE=
25710 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
25711 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
25712 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
25713 else
25714 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
25715 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
25718 if $gl_gnulib_enabled_stat; then
25719 gl_GNULIB_ENABLED_stat_TRUE=
25720 gl_GNULIB_ENABLED_stat_FALSE='#'
25721 else
25722 gl_GNULIB_ENABLED_stat_TRUE='#'
25723 gl_GNULIB_ENABLED_stat_FALSE=
25726 if $gl_gnulib_enabled_strtoll; then
25727 gl_GNULIB_ENABLED_strtoll_TRUE=
25728 gl_GNULIB_ENABLED_strtoll_FALSE='#'
25729 else
25730 gl_GNULIB_ENABLED_strtoll_TRUE='#'
25731 gl_GNULIB_ENABLED_strtoll_FALSE=
25734 if $gl_gnulib_enabled_strtoull; then
25735 gl_GNULIB_ENABLED_strtoull_TRUE=
25736 gl_GNULIB_ENABLED_strtoull_FALSE='#'
25737 else
25738 gl_GNULIB_ENABLED_strtoull_TRUE='#'
25739 gl_GNULIB_ENABLED_strtoull_FALSE=
25742 if $gl_gnulib_enabled_verify; then
25743 gl_GNULIB_ENABLED_verify_TRUE=
25744 gl_GNULIB_ENABLED_verify_FALSE='#'
25745 else
25746 gl_GNULIB_ENABLED_verify_TRUE='#'
25747 gl_GNULIB_ENABLED_verify_FALSE=
25750 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
25751 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
25752 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
25753 else
25754 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
25755 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
25758 # End of code from modules
25768 gltests_libdeps=
25769 gltests_ltlibdeps=
25779 gl_source_base='tests'
25780 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
25782 gl_module_indicator_condition=$gltests_WITNESS
25793 LIBGNU_LIBDEPS="$gl_libdeps"
25795 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
25798 CFLAGS=$SAVE_CFLAGS
25799 LIBS=$SAVE_LIBS
25801 case "$opsys" in
25802 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
25804 darwin)
25805 ## The -headerpad option tells ld (see man page) to leave room at the
25806 ## end of the header for adding load commands. Needed for dumping.
25807 ## 0x690 is the total size of 30 segment load commands (at 56
25808 ## each); under Cocoa 31 commands are required.
25809 if test "$HAVE_NS" = "yes"; then
25810 libs_nsgui="-framework AppKit"
25811 headerpad_extra=6C8
25812 else
25813 libs_nsgui=
25814 headerpad_extra=690
25816 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
25818 ## This is here because src/Makefile.in did some extra fiddling around
25819 ## with LD_SWITCH_SYSTEM. The cpp logic was:
25820 ## #ifndef LD_SWITCH_SYSTEM
25821 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
25822 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
25823 ## not using gcc, darwin.
25824 ## Because this was done in src/Makefile.in, the resulting part of
25825 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
25826 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
25827 ## rather than LD_SWITCH_SYSTEM.
25828 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
25829 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
25832 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
25833 ## find X at run-time.
25834 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
25835 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
25836 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
25837 ## had different values in configure (in ac_link) and src/Makefile.in.
25838 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
25839 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
25841 *) LD_SWITCH_SYSTEM_TEMACS= ;;
25842 esac
25847 LD_FIRSTFLAG=
25848 ORDINARY_LINK=
25849 case "$opsys" in
25850 ## gnu: GNU needs its own crt0.
25851 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
25853 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
25854 ## library search parth, i.e. it won't search /usr/lib for libc and
25855 ## friends. Using -nostartfiles instead avoids this problem, and
25856 ## will also work on earlier NetBSD releases.
25857 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
25859 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
25860 ## MkLinux/LinuxPPC needs this.
25861 ## s390x-* only supports opsys = gnu-linux so it can be added here.
25862 gnu-*)
25863 case "$canonical" in
25864 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
25865 esac
25867 esac
25870 if test "x$ORDINARY_LINK" = "xyes"; then
25872 LD_FIRSTFLAG=""
25874 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
25877 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
25878 ## freebsd, gnu-* not on powerpc*|s390x*.
25879 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
25881 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
25882 ## places that are difficult to figure out at make time. Fortunately,
25883 ## these same versions allow you to pass arbitrary flags on to the
25884 ## linker, so there is no reason not to use it as a linker.
25886 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
25887 ## searching for libraries in its internal directories, so we have to
25888 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
25889 LD_FIRSTFLAG="-nostdlib"
25892 ## FIXME? What setting of EDIT_LDFLAGS should this have?
25893 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
25898 ## FIXME? The logic here is not precisely the same as that above.
25899 ## There is no check here for a pre-defined LD_FIRSTFLAG.
25900 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
25901 LIB_GCC=
25902 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
25904 case "$opsys" in
25905 freebsd|netbsd|openbsd) LIB_GCC= ;;
25907 gnu-*)
25908 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
25909 ## build on ARM EABI under GNU/Linux. (Bug#5518)
25910 case $host_cpu in
25911 arm*)
25912 LIB_GCC="-lgcc_s"
25915 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
25916 ## immediately undefine it again and redefine it to empty.
25917 ## Was the C_SWITCH_X_SITE part really necessary?
25918 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
25919 LIB_GCC=
25921 esac
25924 ## Ask GCC where to find libgcc.a.
25925 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
25926 esac
25929 ## Common for all window systems
25930 if test "$window_system" != "none"; then
25932 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
25934 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
25941 #### Report on what we decided to do.
25942 #### Report GTK as a toolkit, even if it doesn't use Xt.
25943 #### It makes printing result more understandable as using GTK sets
25944 #### toolkit_scroll_bars to yes by default.
25945 if test "${HAVE_GTK}" = "yes"; then
25946 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
25949 echo "
25950 Configured for \`${canonical}'.
25952 Where should the build process find the source code? ${srcdir}
25953 What compiler should emacs be built with? ${CC} ${CFLAGS}
25954 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
25955 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
25956 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
25957 What window system should Emacs use? ${window_system}
25958 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
25960 if test -n "${x_includes}"; then
25961 echo " Where do we find X Windows header files? ${x_includes}"
25962 else
25963 echo " Where do we find X Windows header files? Standard dirs"
25965 if test -n "${x_libraries}"; then
25966 echo " Where do we find X Windows libraries? ${x_libraries}"
25967 else
25968 echo " Where do we find X Windows libraries? Standard dirs"
25971 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
25972 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
25973 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
25974 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
25975 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
25976 echo " Does Emacs use -lpng? ${HAVE_PNG}"
25977 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
25978 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
25980 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
25981 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
25982 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
25983 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
25984 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
25985 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
25986 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
25988 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
25989 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
25990 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
25991 echo " Does Emacs use -lxft? ${HAVE_XFT}"
25993 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
25994 echo
25996 if test -n "${EMACSDATA}"; then
25997 echo " Environment variable EMACSDATA set to: $EMACSDATA"
25999 if test -n "${EMACSDOC}"; then
26000 echo " Environment variable EMACSDOC set to: $EMACSDOC"
26003 echo
26005 if test "$HAVE_NS" = "yes"; then
26006 echo
26007 echo "You must run \"${MAKE-make} install\" in order to test the built application.
26008 The installed application will go to nextstep/Emacs.app and can be
26009 run or moved from there."
26010 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
26011 echo "The application will be fully self-contained."
26012 else
26013 echo "The lisp resources for the application will be installed under ${prefix}.
26014 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
26015 to run if these resources are not installed."
26017 echo
26020 if test "${opsys}" = "cygwin"; then
26021 case `uname -r` in
26022 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
26023 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
26024 echo
26026 esac
26029 # Remove any trailing slashes in these variables.
26030 test "${prefix}" != NONE &&
26031 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
26032 test "${exec_prefix}" != NONE &&
26033 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
26035 if test "$HAVE_NS" = "yes"; then
26036 if test "$NS_IMPL_GNUSTEP" = yes; then
26037 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"
26039 else
26040 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"
26045 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"
26047 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"
26050 opt_makefile=test/automated/Makefile
26052 if test -f "$srcdir/$opt_makefile.in"; then
26053 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
26054 ac_config_files="$ac_config_files test/automated/Makefile"
26059 opt_makefile=admin/unidata/Makefile
26061 if test -f "$srcdir/$opt_makefile.in"; then
26062 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
26063 ac_config_files="$ac_config_files admin/unidata/Makefile"
26068 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
26072 ac_config_commands="$ac_config_commands mkdirs"
26075 ac_config_commands="$ac_config_commands epaths"
26078 ac_config_commands="$ac_config_commands gdbinit"
26081 cat >confcache <<\_ACEOF
26082 # This file is a shell script that caches the results of configure
26083 # tests run on this system so they can be shared between configure
26084 # scripts and configure runs, see configure's option --config-cache.
26085 # It is not useful on other systems. If it contains results you don't
26086 # want to keep, you may remove or edit it.
26088 # config.status only pays attention to the cache file if you give it
26089 # the --recheck option to rerun configure.
26091 # `ac_cv_env_foo' variables (set or unset) will be overridden when
26092 # loading this file, other *unset* `ac_cv_foo' will be assigned the
26093 # following values.
26095 _ACEOF
26097 # The following way of writing the cache mishandles newlines in values,
26098 # but we know of no workaround that is simple, portable, and efficient.
26099 # So, we kill variables containing newlines.
26100 # Ultrix sh set writes to stderr and can't be redirected directly,
26101 # and sets the high bit in the cache file unless we assign to the vars.
26103 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
26104 eval ac_val=\$$ac_var
26105 case $ac_val in #(
26106 *${as_nl}*)
26107 case $ac_var in #(
26108 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
26109 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
26110 esac
26111 case $ac_var in #(
26112 _ | IFS | as_nl) ;; #(
26113 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
26114 *) { eval $ac_var=; unset $ac_var;} ;;
26115 esac ;;
26116 esac
26117 done
26119 (set) 2>&1 |
26120 case $as_nl`(ac_space=' '; set) 2>&1` in #(
26121 *${as_nl}ac_space=\ *)
26122 # `set' does not quote correctly, so add quotes: double-quote
26123 # substitution turns \\\\ into \\, and sed turns \\ into \.
26124 sed -n \
26125 "s/'/'\\\\''/g;
26126 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
26127 ;; #(
26129 # `set' quotes correctly as required by POSIX, so do not add quotes.
26130 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
26132 esac |
26133 sort
26135 sed '
26136 /^ac_cv_env_/b end
26137 t clear
26138 :clear
26139 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26140 t end
26141 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26142 :end' >>confcache
26143 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
26144 if test -w "$cache_file"; then
26145 test "x$cache_file" != "x/dev/null" &&
26146 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
26147 $as_echo "$as_me: updating cache $cache_file" >&6;}
26148 cat confcache >$cache_file
26149 else
26150 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
26151 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
26154 rm -f confcache
26156 test "x$prefix" = xNONE && prefix=$ac_default_prefix
26157 # Let make expand exec_prefix.
26158 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
26160 DEFS=-DHAVE_CONFIG_H
26162 ac_libobjs=
26163 ac_ltlibobjs=
26164 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
26165 # 1. Remove the extension, and $U if already installed.
26166 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
26167 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
26168 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
26169 # will be set to the directory where LIBOBJS objects are built.
26170 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
26171 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
26172 done
26173 LIBOBJS=$ac_libobjs
26175 LTLIBOBJS=$ac_ltlibobjs
26178 if test -n "$EXEEXT"; then
26179 am__EXEEXT_TRUE=
26180 am__EXEEXT_FALSE='#'
26181 else
26182 am__EXEEXT_TRUE='#'
26183 am__EXEEXT_FALSE=
26186 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
26187 as_fn_error "conditional \"AMDEP\" was never defined.
26188 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26190 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
26191 as_fn_error "conditional \"am__fastdepCC\" was never defined.
26192 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26194 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
26195 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
26196 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26198 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
26199 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
26200 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26203 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
26204 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
26205 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26207 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
26208 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
26209 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26211 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
26212 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
26213 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26215 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
26216 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
26217 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26219 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
26220 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
26221 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26223 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
26224 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
26225 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26227 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
26228 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
26229 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26231 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
26232 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
26233 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26235 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
26236 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
26237 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26239 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
26240 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
26241 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26243 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
26244 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
26245 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26247 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
26248 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
26249 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26251 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
26252 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
26253 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26255 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
26256 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
26257 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26259 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
26260 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
26261 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26263 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
26264 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
26265 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26267 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
26268 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
26269 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26271 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
26272 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
26273 Usually this means the macro was only invoked conditionally." "$LINENO" 5
26276 gl_libobjs=
26277 gl_ltlibobjs=
26278 if test -n "$gl_LIBOBJS"; then
26279 # Remove the extension.
26280 sed_drop_objext='s/\.o$//;s/\.obj$//'
26281 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
26282 gl_libobjs="$gl_libobjs $i.$ac_objext"
26283 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
26284 done
26286 gl_LIBOBJS=$gl_libobjs
26288 gl_LTLIBOBJS=$gl_ltlibobjs
26292 gltests_libobjs=
26293 gltests_ltlibobjs=
26294 if test -n "$gltests_LIBOBJS"; then
26295 # Remove the extension.
26296 sed_drop_objext='s/\.o$//;s/\.obj$//'
26297 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
26298 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
26299 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
26300 done
26302 gltests_LIBOBJS=$gltests_libobjs
26304 gltests_LTLIBOBJS=$gltests_ltlibobjs
26308 : ${CONFIG_STATUS=./config.status}
26309 ac_write_fail=0
26310 ac_clean_files_save=$ac_clean_files
26311 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
26312 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
26313 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
26314 as_write_fail=0
26315 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
26316 #! $SHELL
26317 # Generated by $as_me.
26318 # Run this file to recreate the current configuration.
26319 # Compiler output produced by configure, useful for debugging
26320 # configure, is in config.log if it exists.
26322 debug=false
26323 ac_cs_recheck=false
26324 ac_cs_silent=false
26326 SHELL=\${CONFIG_SHELL-$SHELL}
26327 export SHELL
26328 _ASEOF
26329 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
26330 ## -------------------- ##
26331 ## M4sh Initialization. ##
26332 ## -------------------- ##
26334 # Be more Bourne compatible
26335 DUALCASE=1; export DUALCASE # for MKS sh
26336 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
26337 emulate sh
26338 NULLCMD=:
26339 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26340 # is contrary to our usage. Disable this feature.
26341 alias -g '${1+"$@"}'='"$@"'
26342 setopt NO_GLOB_SUBST
26343 else
26344 case `(set -o) 2>/dev/null` in #(
26345 *posix*) :
26346 set -o posix ;; #(
26347 *) :
26349 esac
26353 as_nl='
26355 export as_nl
26356 # Printing a long string crashes Solaris 7 /usr/bin/printf.
26357 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
26358 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
26359 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
26360 # Prefer a ksh shell builtin over an external printf program on Solaris,
26361 # but without wasting forks for bash or zsh.
26362 if test -z "$BASH_VERSION$ZSH_VERSION" \
26363 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
26364 as_echo='print -r --'
26365 as_echo_n='print -rn --'
26366 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
26367 as_echo='printf %s\n'
26368 as_echo_n='printf %s'
26369 else
26370 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
26371 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
26372 as_echo_n='/usr/ucb/echo -n'
26373 else
26374 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
26375 as_echo_n_body='eval
26376 arg=$1;
26377 case $arg in #(
26378 *"$as_nl"*)
26379 expr "X$arg" : "X\\(.*\\)$as_nl";
26380 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
26381 esac;
26382 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
26384 export as_echo_n_body
26385 as_echo_n='sh -c $as_echo_n_body as_echo'
26387 export as_echo_body
26388 as_echo='sh -c $as_echo_body as_echo'
26391 # The user is always right.
26392 if test "${PATH_SEPARATOR+set}" != set; then
26393 PATH_SEPARATOR=:
26394 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26395 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26396 PATH_SEPARATOR=';'
26401 # IFS
26402 # We need space, tab and new line, in precisely that order. Quoting is
26403 # there to prevent editors from complaining about space-tab.
26404 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
26405 # splitting by setting IFS to empty value.)
26406 IFS=" "" $as_nl"
26408 # Find who we are. Look in the path if we contain no directory separator.
26409 case $0 in #((
26410 *[\\/]* ) as_myself=$0 ;;
26411 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26412 for as_dir in $PATH
26414 IFS=$as_save_IFS
26415 test -z "$as_dir" && as_dir=.
26416 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26417 done
26418 IFS=$as_save_IFS
26421 esac
26422 # We did not find ourselves, most probably we were run as `sh COMMAND'
26423 # in which case we are not to be found in the path.
26424 if test "x$as_myself" = x; then
26425 as_myself=$0
26427 if test ! -f "$as_myself"; then
26428 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
26429 exit 1
26432 # Unset variables that we do not need and which cause bugs (e.g. in
26433 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
26434 # suppresses any "Segmentation fault" message there. '((' could
26435 # trigger a bug in pdksh 5.2.14.
26436 for as_var in BASH_ENV ENV MAIL MAILPATH
26437 do eval test x\${$as_var+set} = xset \
26438 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
26439 done
26440 PS1='$ '
26441 PS2='> '
26442 PS4='+ '
26444 # NLS nuisances.
26445 LC_ALL=C
26446 export LC_ALL
26447 LANGUAGE=C
26448 export LANGUAGE
26450 # CDPATH.
26451 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
26454 # as_fn_error ERROR [LINENO LOG_FD]
26455 # ---------------------------------
26456 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
26457 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
26458 # script with status $?, using 1 if that was 0.
26459 as_fn_error ()
26461 as_status=$?; test $as_status -eq 0 && as_status=1
26462 if test "$3"; then
26463 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
26464 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
26466 $as_echo "$as_me: error: $1" >&2
26467 as_fn_exit $as_status
26468 } # as_fn_error
26471 # as_fn_set_status STATUS
26472 # -----------------------
26473 # Set $? to STATUS, without forking.
26474 as_fn_set_status ()
26476 return $1
26477 } # as_fn_set_status
26479 # as_fn_exit STATUS
26480 # -----------------
26481 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
26482 as_fn_exit ()
26484 set +e
26485 as_fn_set_status $1
26486 exit $1
26487 } # as_fn_exit
26489 # as_fn_unset VAR
26490 # ---------------
26491 # Portably unset VAR.
26492 as_fn_unset ()
26494 { eval $1=; unset $1;}
26496 as_unset=as_fn_unset
26497 # as_fn_append VAR VALUE
26498 # ----------------------
26499 # Append the text in VALUE to the end of the definition contained in VAR. Take
26500 # advantage of any shell optimizations that allow amortized linear growth over
26501 # repeated appends, instead of the typical quadratic growth present in naive
26502 # implementations.
26503 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
26504 eval 'as_fn_append ()
26506 eval $1+=\$2
26508 else
26509 as_fn_append ()
26511 eval $1=\$$1\$2
26513 fi # as_fn_append
26515 # as_fn_arith ARG...
26516 # ------------------
26517 # Perform arithmetic evaluation on the ARGs, and store the result in the
26518 # global $as_val. Take advantage of shells that can avoid forks. The arguments
26519 # must be portable across $(()) and expr.
26520 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
26521 eval 'as_fn_arith ()
26523 as_val=$(( $* ))
26525 else
26526 as_fn_arith ()
26528 as_val=`expr "$@" || test $? -eq 1`
26530 fi # as_fn_arith
26533 if expr a : '\(a\)' >/dev/null 2>&1 &&
26534 test "X`expr 00001 : '.*\(...\)'`" = X001; then
26535 as_expr=expr
26536 else
26537 as_expr=false
26540 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26541 as_basename=basename
26542 else
26543 as_basename=false
26546 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26547 as_dirname=dirname
26548 else
26549 as_dirname=false
26552 as_me=`$as_basename -- "$0" ||
26553 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26554 X"$0" : 'X\(//\)$' \| \
26555 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
26556 $as_echo X/"$0" |
26557 sed '/^.*\/\([^/][^/]*\)\/*$/{
26558 s//\1/
26561 /^X\/\(\/\/\)$/{
26562 s//\1/
26565 /^X\/\(\/\).*/{
26566 s//\1/
26569 s/.*/./; q'`
26571 # Avoid depending upon Character Ranges.
26572 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26573 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26574 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26575 as_cr_digits='0123456789'
26576 as_cr_alnum=$as_cr_Letters$as_cr_digits
26578 ECHO_C= ECHO_N= ECHO_T=
26579 case `echo -n x` in #(((((
26580 -n*)
26581 case `echo 'xy\c'` in
26582 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
26583 xy) ECHO_C='\c';;
26584 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
26585 ECHO_T=' ';;
26586 esac;;
26588 ECHO_N='-n';;
26589 esac
26591 rm -f conf$$ conf$$.exe conf$$.file
26592 if test -d conf$$.dir; then
26593 rm -f conf$$.dir/conf$$.file
26594 else
26595 rm -f conf$$.dir
26596 mkdir conf$$.dir 2>/dev/null
26598 if (echo >conf$$.file) 2>/dev/null; then
26599 if ln -s conf$$.file conf$$ 2>/dev/null; then
26600 as_ln_s='ln -s'
26601 # ... but there are two gotchas:
26602 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26603 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26604 # In both cases, we have to default to `cp -p'.
26605 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26606 as_ln_s='cp -p'
26607 elif ln conf$$.file conf$$ 2>/dev/null; then
26608 as_ln_s=ln
26609 else
26610 as_ln_s='cp -p'
26612 else
26613 as_ln_s='cp -p'
26615 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26616 rmdir conf$$.dir 2>/dev/null
26619 # as_fn_mkdir_p
26620 # -------------
26621 # Create "$as_dir" as a directory, including parents if necessary.
26622 as_fn_mkdir_p ()
26625 case $as_dir in #(
26626 -*) as_dir=./$as_dir;;
26627 esac
26628 test -d "$as_dir" || eval $as_mkdir_p || {
26629 as_dirs=
26630 while :; do
26631 case $as_dir in #(
26632 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
26633 *) as_qdir=$as_dir;;
26634 esac
26635 as_dirs="'$as_qdir' $as_dirs"
26636 as_dir=`$as_dirname -- "$as_dir" ||
26637 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26638 X"$as_dir" : 'X\(//\)[^/]' \| \
26639 X"$as_dir" : 'X\(//\)$' \| \
26640 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
26641 $as_echo X"$as_dir" |
26642 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26643 s//\1/
26646 /^X\(\/\/\)[^/].*/{
26647 s//\1/
26650 /^X\(\/\/\)$/{
26651 s//\1/
26654 /^X\(\/\).*/{
26655 s//\1/
26658 s/.*/./; q'`
26659 test -d "$as_dir" && break
26660 done
26661 test -z "$as_dirs" || eval "mkdir $as_dirs"
26662 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
26665 } # as_fn_mkdir_p
26666 if mkdir -p . 2>/dev/null; then
26667 as_mkdir_p='mkdir -p "$as_dir"'
26668 else
26669 test -d ./-p && rmdir ./-p
26670 as_mkdir_p=false
26673 if test -x / >/dev/null 2>&1; then
26674 as_test_x='test -x'
26675 else
26676 if ls -dL / >/dev/null 2>&1; then
26677 as_ls_L_option=L
26678 else
26679 as_ls_L_option=
26681 as_test_x='
26682 eval sh -c '\''
26683 if test -d "$1"; then
26684 test -d "$1/.";
26685 else
26686 case $1 in #(
26687 -*)set "./$1";;
26688 esac;
26689 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
26690 ???[sx]*):;;*)false;;esac;fi
26691 '\'' sh
26694 as_executable_p=$as_test_x
26696 # Sed expression to map a string onto a valid CPP name.
26697 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
26699 # Sed expression to map a string onto a valid variable name.
26700 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
26703 exec 6>&1
26704 ## ----------------------------------- ##
26705 ## Main body of $CONFIG_STATUS script. ##
26706 ## ----------------------------------- ##
26707 _ASEOF
26708 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
26710 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26711 # Save the log message, to keep $0 and so on meaningful, and to
26712 # report actual input values of CONFIG_FILES etc. instead of their
26713 # values after options handling.
26714 ac_log="
26715 This file was extended by emacs $as_me 24.3.50, which was
26716 generated by GNU Autoconf 2.65. Invocation command line was
26718 CONFIG_FILES = $CONFIG_FILES
26719 CONFIG_HEADERS = $CONFIG_HEADERS
26720 CONFIG_LINKS = $CONFIG_LINKS
26721 CONFIG_COMMANDS = $CONFIG_COMMANDS
26722 $ $0 $@
26724 on `(hostname || uname -n) 2>/dev/null | sed 1q`
26727 _ACEOF
26729 case $ac_config_files in *"
26730 "*) set x $ac_config_files; shift; ac_config_files=$*;;
26731 esac
26733 case $ac_config_headers in *"
26734 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
26735 esac
26738 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26739 # Files that config.status was made for.
26740 config_files="$ac_config_files"
26741 config_headers="$ac_config_headers"
26742 config_commands="$ac_config_commands"
26744 _ACEOF
26746 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26747 ac_cs_usage="\
26748 \`$as_me' instantiates files and other configuration actions
26749 from templates according to the current configuration. Unless the files
26750 and actions are specified as TAGs, all are instantiated by default.
26752 Usage: $0 [OPTION]... [TAG]...
26754 -h, --help print this help, then exit
26755 -V, --version print version number and configuration settings, then exit
26756 --config print configuration, then exit
26757 -q, --quiet, --silent
26758 do not print progress messages
26759 -d, --debug don't remove temporary files
26760 --recheck update $as_me by reconfiguring in the same conditions
26761 --file=FILE[:TEMPLATE]
26762 instantiate the configuration file FILE
26763 --header=FILE[:TEMPLATE]
26764 instantiate the configuration header FILE
26766 Configuration files:
26767 $config_files
26769 Configuration headers:
26770 $config_headers
26772 Configuration commands:
26773 $config_commands
26775 Report bugs to the package provider."
26777 _ACEOF
26778 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26779 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
26780 ac_cs_version="\\
26781 emacs config.status 24.3.50
26782 configured by $0, generated by GNU Autoconf 2.65,
26783 with options \\"\$ac_cs_config\\"
26785 Copyright (C) 2009 Free Software Foundation, Inc.
26786 This config.status script is free software; the Free Software Foundation
26787 gives unlimited permission to copy, distribute and modify it."
26789 ac_pwd='$ac_pwd'
26790 srcdir='$srcdir'
26791 INSTALL='$INSTALL'
26792 MKDIR_P='$MKDIR_P'
26793 AWK='$AWK'
26794 test -n "\$AWK" || AWK=awk
26795 _ACEOF
26797 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26798 # The default lists apply if the user does not specify any file.
26799 ac_need_defaults=:
26800 while test $# != 0
26802 case $1 in
26803 --*=*)
26804 ac_option=`expr "X$1" : 'X\([^=]*\)='`
26805 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
26806 ac_shift=:
26809 ac_option=$1
26810 ac_optarg=$2
26811 ac_shift=shift
26813 esac
26815 case $ac_option in
26816 # Handling of the options.
26817 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
26818 ac_cs_recheck=: ;;
26819 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
26820 $as_echo "$ac_cs_version"; exit ;;
26821 --config | --confi | --conf | --con | --co | --c )
26822 $as_echo "$ac_cs_config"; exit ;;
26823 --debug | --debu | --deb | --de | --d | -d )
26824 debug=: ;;
26825 --file | --fil | --fi | --f )
26826 $ac_shift
26827 case $ac_optarg in
26828 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26829 esac
26830 as_fn_append CONFIG_FILES " '$ac_optarg'"
26831 ac_need_defaults=false;;
26832 --header | --heade | --head | --hea )
26833 $ac_shift
26834 case $ac_optarg in
26835 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26836 esac
26837 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
26838 ac_need_defaults=false;;
26839 --he | --h)
26840 # Conflict between --help and --header
26841 as_fn_error "ambiguous option: \`$1'
26842 Try \`$0 --help' for more information.";;
26843 --help | --hel | -h )
26844 $as_echo "$ac_cs_usage"; exit ;;
26845 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
26846 | -silent | --silent | --silen | --sile | --sil | --si | --s)
26847 ac_cs_silent=: ;;
26849 # This is an error.
26850 -*) as_fn_error "unrecognized option: \`$1'
26851 Try \`$0 --help' for more information." ;;
26853 *) as_fn_append ac_config_targets " $1"
26854 ac_need_defaults=false ;;
26856 esac
26857 shift
26858 done
26860 ac_configure_extra_args=
26862 if $ac_cs_silent; then
26863 exec 6>/dev/null
26864 ac_configure_extra_args="$ac_configure_extra_args --silent"
26867 _ACEOF
26868 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26869 if \$ac_cs_recheck; then
26870 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
26871 shift
26872 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
26873 CONFIG_SHELL='$SHELL'
26874 export CONFIG_SHELL
26875 exec "\$@"
26878 _ACEOF
26879 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26880 exec 5>>config.log
26882 echo
26883 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
26884 ## Running $as_me. ##
26885 _ASBOX
26886 $as_echo "$ac_log"
26887 } >&5
26889 _ACEOF
26890 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26892 # INIT-COMMANDS
26894 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
26895 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
26897 _ACEOF
26899 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26901 # Handling of arguments.
26902 for ac_config_target in $ac_config_targets
26904 case $ac_config_target in
26905 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
26906 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
26907 "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" ;;
26908 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
26909 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
26910 "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" ;;
26911 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
26912 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
26913 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
26914 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
26915 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
26916 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
26917 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
26918 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
26919 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
26920 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
26921 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
26922 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
26923 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
26924 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
26925 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
26926 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
26927 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
26928 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
26930 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
26931 esac
26932 done
26935 # If the user did not use the arguments to specify the items to instantiate,
26936 # then the envvar interface is used. Set only those that are not.
26937 # We use the long form for the default assignment because of an extremely
26938 # bizarre bug on SunOS 4.1.3.
26939 if $ac_need_defaults; then
26940 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
26941 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
26942 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
26945 # Have a temporary directory for convenience. Make it in the build tree
26946 # simply because there is no reason against having it here, and in addition,
26947 # creating and moving files from /tmp can sometimes cause problems.
26948 # Hook for its removal unless debugging.
26949 # Note that there is a small window in which the directory will not be cleaned:
26950 # after its creation but before its name has been assigned to `$tmp'.
26951 $debug ||
26953 tmp=
26954 trap 'exit_status=$?
26955 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
26957 trap 'as_fn_exit 1' 1 2 13 15
26959 # Create a (secure) tmp directory for tmp files.
26962 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
26963 test -n "$tmp" && test -d "$tmp"
26964 } ||
26966 tmp=./conf$$-$RANDOM
26967 (umask 077 && mkdir "$tmp")
26968 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
26970 # Set up the scripts for CONFIG_FILES section.
26971 # No need to generate them if there are no CONFIG_FILES.
26972 # This happens for instance with `./config.status config.h'.
26973 if test -n "$CONFIG_FILES"; then
26975 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
26976 ac_cs_awk_getline=:
26977 ac_cs_awk_pipe_init=
26978 ac_cs_awk_read_file='
26979 while ((getline aline < (F[key])) > 0)
26980 print(aline)
26981 close(F[key])'
26982 ac_cs_awk_pipe_fini=
26983 else
26984 ac_cs_awk_getline=false
26985 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
26986 ac_cs_awk_read_file='
26987 print "|#_!!_#|"
26988 print "cat " F[key] " &&"
26989 '$ac_cs_awk_pipe_init
26990 # The final `:' finishes the AND list.
26991 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
26993 ac_cr=`echo X | tr X '\015'`
26994 # On cygwin, bash can eat \r inside `` if the user requested igncr.
26995 # But we know of no other shell where ac_cr would be empty at this
26996 # point, so we can use a bashism as a fallback.
26997 if test "x$ac_cr" = x; then
26998 eval ac_cr=\$\'\\r\'
27000 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
27001 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
27002 ac_cs_awk_cr='\r'
27003 else
27004 ac_cs_awk_cr=$ac_cr
27007 echo 'BEGIN {' >"$tmp/subs1.awk" &&
27008 _ACEOF
27010 # Create commands to substitute file output variables.
27012 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
27013 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
27014 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
27015 echo "_ACAWK" &&
27016 echo "_ACEOF"
27017 } >conf$$files.sh &&
27018 . ./conf$$files.sh ||
27019 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27020 rm -f conf$$files.sh
27023 echo "cat >conf$$subs.awk <<_ACEOF" &&
27024 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
27025 echo "_ACEOF"
27026 } >conf$$subs.sh ||
27027 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27028 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
27029 ac_delim='%!_!# '
27030 for ac_last_try in false false false false false :; do
27031 . ./conf$$subs.sh ||
27032 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27034 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
27035 if test $ac_delim_n = $ac_delim_num; then
27036 break
27037 elif $ac_last_try; then
27038 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
27039 else
27040 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27042 done
27043 rm -f conf$$subs.sh
27045 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27046 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
27047 _ACEOF
27048 sed -n '
27050 s/^/S["/; s/!.*/"]=/
27053 s/^[^!]*!//
27054 :repl
27055 t repl
27056 s/'"$ac_delim"'$//
27057 t delim
27060 s/\(.\{148\}\)..*/\1/
27061 t more1
27062 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
27065 b repl
27066 :more1
27067 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27070 s/.\{148\}//
27071 t nl
27072 :delim
27074 s/\(.\{148\}\)..*/\1/
27075 t more2
27076 s/["\\]/\\&/g; s/^/"/; s/$/"/
27079 :more2
27080 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
27083 s/.\{148\}//
27084 t delim
27085 ' <conf$$subs.awk | sed '
27086 /^[^""]/{
27088 s/\n//
27090 ' >>$CONFIG_STATUS || ac_write_fail=1
27091 rm -f conf$$subs.awk
27092 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27093 _ACAWK
27094 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
27095 for (key in S) S_is_set[key] = 1
27096 FS = "\a"
27097 \$ac_cs_awk_pipe_init
27100 line = $ 0
27101 nfields = split(line, field, "@")
27102 substed = 0
27103 len = length(field[1])
27104 for (i = 2; i < nfields; i++) {
27105 key = field[i]
27106 keylen = length(key)
27107 if (S_is_set[key]) {
27108 value = S[key]
27109 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
27110 len += length(value) + length(field[++i])
27111 substed = 1
27112 } else
27113 len += 1 + keylen
27115 if (nfields == 3 && !substed) {
27116 key = field[2]
27117 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
27118 \$ac_cs_awk_read_file
27119 next
27122 print line
27124 \$ac_cs_awk_pipe_fini
27125 _ACAWK
27126 _ACEOF
27127 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27128 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
27129 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
27130 else
27132 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
27133 || as_fn_error "could not setup config files machinery" "$LINENO" 5
27134 _ACEOF
27136 # VPATH may cause trouble with some makes, so we remove $(srcdir),
27137 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
27138 # trailing colons and then remove the whole line if VPATH becomes empty
27139 # (actually we leave an empty line to preserve line numbers).
27140 if test "x$srcdir" = x.; then
27141 ac_vpsub='/^[ ]*VPATH[ ]*=/{
27142 s/:*\$(srcdir):*/:/
27143 s/:*\${srcdir}:*/:/
27144 s/:*@srcdir@:*/:/
27145 s/^\([^=]*=[ ]*\):*/\1/
27146 s/:*$//
27147 s/^[^=]*=[ ]*$//
27151 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27152 fi # test -n "$CONFIG_FILES"
27154 # Set up the scripts for CONFIG_HEADERS section.
27155 # No need to generate them if there are no CONFIG_HEADERS.
27156 # This happens for instance with `./config.status Makefile'.
27157 if test -n "$CONFIG_HEADERS"; then
27158 cat >"$tmp/defines.awk" <<\_ACAWK ||
27159 BEGIN {
27160 _ACEOF
27162 # Transform confdefs.h into an awk script `defines.awk', embedded as
27163 # here-document in config.status, that substitutes the proper values into
27164 # config.h.in to produce config.h.
27166 # Create a delimiter string that does not exist in confdefs.h, to ease
27167 # handling of long lines.
27168 ac_delim='%!_!# '
27169 for ac_last_try in false false :; do
27170 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
27171 if test -z "$ac_t"; then
27172 break
27173 elif $ac_last_try; then
27174 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
27175 else
27176 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
27178 done
27180 # For the awk script, D is an array of macro values keyed by name,
27181 # likewise P contains macro parameters if any. Preserve backslash
27182 # newline sequences.
27184 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
27185 sed -n '
27186 s/.\{148\}/&'"$ac_delim"'/g
27187 t rset
27188 :rset
27189 s/^[ ]*#[ ]*define[ ][ ]*/ /
27190 t def
27192 :def
27193 s/\\$//
27194 t bsnl
27195 s/["\\]/\\&/g
27196 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27197 D["\1"]=" \3"/p
27198 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
27200 :bsnl
27201 s/["\\]/\\&/g
27202 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27203 D["\1"]=" \3\\\\\\n"\\/p
27204 t cont
27205 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
27206 t cont
27208 :cont
27210 s/.\{148\}/&'"$ac_delim"'/g
27211 t clear
27212 :clear
27213 s/\\$//
27214 t bsnlc
27215 s/["\\]/\\&/g; s/^/"/; s/$/"/p
27217 :bsnlc
27218 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
27219 b cont
27220 ' <confdefs.h | sed '
27221 s/'"$ac_delim"'/"\\\
27222 "/g' >>$CONFIG_STATUS || ac_write_fail=1
27224 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27225 for (key in D) D_is_set[key] = 1
27226 FS = "\a"
27228 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
27229 line = \$ 0
27230 split(line, arg, " ")
27231 if (arg[1] == "#") {
27232 defundef = arg[2]
27233 mac1 = arg[3]
27234 } else {
27235 defundef = substr(arg[1], 2)
27236 mac1 = arg[2]
27238 split(mac1, mac2, "(") #)
27239 macro = mac2[1]
27240 prefix = substr(line, 1, index(line, defundef) - 1)
27241 if (D_is_set[macro]) {
27242 # Preserve the white space surrounding the "#".
27243 print prefix "define", macro P[macro] D[macro]
27244 next
27245 } else {
27246 # Replace #undef with comments. This is necessary, for example,
27247 # in the case of _POSIX_SOURCE, which is predefined and required
27248 # on some systems where configure will not decide to define it.
27249 if (defundef == "undef") {
27250 print "/*", prefix defundef, macro, "*/"
27251 next
27255 { print }
27256 _ACAWK
27257 _ACEOF
27258 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27259 as_fn_error "could not setup config headers machinery" "$LINENO" 5
27260 fi # test -n "$CONFIG_HEADERS"
27263 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
27264 shift
27265 for ac_tag
27267 case $ac_tag in
27268 :[FHLC]) ac_mode=$ac_tag; continue;;
27269 esac
27270 case $ac_mode$ac_tag in
27271 :[FHL]*:*);;
27272 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
27273 :[FH]-) ac_tag=-:-;;
27274 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
27275 esac
27276 ac_save_IFS=$IFS
27277 IFS=:
27278 set x $ac_tag
27279 IFS=$ac_save_IFS
27280 shift
27281 ac_file=$1
27282 shift
27284 case $ac_mode in
27285 :L) ac_source=$1;;
27286 :[FH])
27287 ac_file_inputs=
27288 for ac_f
27290 case $ac_f in
27291 -) ac_f="$tmp/stdin";;
27292 *) # Look for the file first in the build tree, then in the source tree
27293 # (if the path is not absolute). The absolute path cannot be DOS-style,
27294 # because $ac_f cannot contain `:'.
27295 test -f "$ac_f" ||
27296 case $ac_f in
27297 [\\/$]*) false;;
27298 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
27299 esac ||
27300 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
27301 esac
27302 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
27303 as_fn_append ac_file_inputs " '$ac_f'"
27304 done
27306 # Let's still pretend it is `configure' which instantiates (i.e., don't
27307 # use $as_me), people would be surprised to read:
27308 # /* config.h. Generated by config.status. */
27309 configure_input='Generated from '`
27310 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
27311 `' by configure.'
27312 if test x"$ac_file" != x-; then
27313 configure_input="$ac_file. $configure_input"
27314 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
27315 $as_echo "$as_me: creating $ac_file" >&6;}
27317 # Neutralize special characters interpreted by sed in replacement strings.
27318 case $configure_input in #(
27319 *\&* | *\|* | *\\* )
27320 ac_sed_conf_input=`$as_echo "$configure_input" |
27321 sed 's/[\\\\&|]/\\\\&/g'`;; #(
27322 *) ac_sed_conf_input=$configure_input;;
27323 esac
27325 case $ac_tag in
27326 *:-:* | *:-) cat >"$tmp/stdin" \
27327 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
27328 esac
27330 esac
27332 ac_dir=`$as_dirname -- "$ac_file" ||
27333 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27334 X"$ac_file" : 'X\(//\)[^/]' \| \
27335 X"$ac_file" : 'X\(//\)$' \| \
27336 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
27337 $as_echo X"$ac_file" |
27338 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27339 s//\1/
27342 /^X\(\/\/\)[^/].*/{
27343 s//\1/
27346 /^X\(\/\/\)$/{
27347 s//\1/
27350 /^X\(\/\).*/{
27351 s//\1/
27354 s/.*/./; q'`
27355 as_dir="$ac_dir"; as_fn_mkdir_p
27356 ac_builddir=.
27358 case "$ac_dir" in
27359 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
27361 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
27362 # A ".." for each directory in $ac_dir_suffix.
27363 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
27364 case $ac_top_builddir_sub in
27365 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
27366 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
27367 esac ;;
27368 esac
27369 ac_abs_top_builddir=$ac_pwd
27370 ac_abs_builddir=$ac_pwd$ac_dir_suffix
27371 # for backward compatibility:
27372 ac_top_builddir=$ac_top_build_prefix
27374 case $srcdir in
27375 .) # We are building in place.
27376 ac_srcdir=.
27377 ac_top_srcdir=$ac_top_builddir_sub
27378 ac_abs_top_srcdir=$ac_pwd ;;
27379 [\\/]* | ?:[\\/]* ) # Absolute name.
27380 ac_srcdir=$srcdir$ac_dir_suffix;
27381 ac_top_srcdir=$srcdir
27382 ac_abs_top_srcdir=$srcdir ;;
27383 *) # Relative name.
27384 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
27385 ac_top_srcdir=$ac_top_build_prefix$srcdir
27386 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
27387 esac
27388 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
27391 case $ac_mode in
27394 # CONFIG_FILE
27397 case $INSTALL in
27398 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
27399 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
27400 esac
27401 ac_MKDIR_P=$MKDIR_P
27402 case $MKDIR_P in
27403 [\\/$]* | ?:[\\/]* ) ;;
27404 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
27405 esac
27406 _ACEOF
27408 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27409 # If the template does not know about datarootdir, expand it.
27410 # FIXME: This hack should be removed a few years after 2.60.
27411 ac_datarootdir_hack=; ac_datarootdir_seen=
27412 ac_sed_dataroot='
27413 /datarootdir/ {
27417 /@datadir@/p
27418 /@docdir@/p
27419 /@infodir@/p
27420 /@localedir@/p
27421 /@mandir@/p'
27422 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
27423 *datarootdir*) ac_datarootdir_seen=yes;;
27424 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
27425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
27426 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
27427 _ACEOF
27428 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27429 ac_datarootdir_hack='
27430 s&@datadir@&$datadir&g
27431 s&@docdir@&$docdir&g
27432 s&@infodir@&$infodir&g
27433 s&@localedir@&$localedir&g
27434 s&@mandir@&$mandir&g
27435 s&\\\${datarootdir}&$datarootdir&g' ;;
27436 esac
27437 _ACEOF
27439 # Neutralize VPATH when `$srcdir' = `.'.
27440 # Shell code in configure.ac might set extrasub.
27441 # FIXME: do we really want to maintain this feature?
27442 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27443 ac_sed_extra="$ac_vpsub
27444 $extrasub
27445 _ACEOF
27446 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27448 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
27449 s|@configure_input@|$ac_sed_conf_input|;t t
27450 s&@top_builddir@&$ac_top_builddir_sub&;t t
27451 s&@top_build_prefix@&$ac_top_build_prefix&;t t
27452 s&@srcdir@&$ac_srcdir&;t t
27453 s&@abs_srcdir@&$ac_abs_srcdir&;t t
27454 s&@top_srcdir@&$ac_top_srcdir&;t t
27455 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
27456 s&@builddir@&$ac_builddir&;t t
27457 s&@abs_builddir@&$ac_abs_builddir&;t t
27458 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
27459 s&@INSTALL@&$ac_INSTALL&;t t
27460 s&@MKDIR_P@&$ac_MKDIR_P&;t t
27461 $ac_datarootdir_hack
27463 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
27464 if $ac_cs_awk_getline; then
27465 $AWK -f "$tmp/subs.awk"
27466 else
27467 $AWK -f "$tmp/subs.awk" | $SHELL
27468 fi >$tmp/out \
27469 || as_fn_error "could not create $ac_file" "$LINENO" 5
27471 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
27472 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
27473 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
27474 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27475 which seems to be undefined. Please make sure it is defined." >&5
27476 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
27477 which seems to be undefined. Please make sure it is defined." >&2;}
27479 rm -f "$tmp/stdin"
27480 case $ac_file in
27481 -) cat "$tmp/out" && rm -f "$tmp/out";;
27482 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
27483 esac \
27484 || as_fn_error "could not create $ac_file" "$LINENO" 5
27488 # CONFIG_HEADER
27490 if test x"$ac_file" != x-; then
27492 $as_echo "/* $configure_input */" \
27493 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
27494 } >"$tmp/config.h" \
27495 || as_fn_error "could not create $ac_file" "$LINENO" 5
27496 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
27497 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
27498 $as_echo "$as_me: $ac_file is unchanged" >&6;}
27499 else
27500 rm -f "$ac_file"
27501 mv "$tmp/config.h" "$ac_file" \
27502 || as_fn_error "could not create $ac_file" "$LINENO" 5
27504 else
27505 $as_echo "/* $configure_input */" \
27506 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
27507 || as_fn_error "could not create -" "$LINENO" 5
27509 # Compute "$ac_file"'s index in $config_headers.
27510 _am_arg="$ac_file"
27511 _am_stamp_count=1
27512 for _am_header in $config_headers :; do
27513 case $_am_header in
27514 $_am_arg | $_am_arg:* )
27515 break ;;
27517 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
27518 esac
27519 done
27520 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
27521 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27522 X"$_am_arg" : 'X\(//\)[^/]' \| \
27523 X"$_am_arg" : 'X\(//\)$' \| \
27524 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
27525 $as_echo X"$_am_arg" |
27526 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27527 s//\1/
27530 /^X\(\/\/\)[^/].*/{
27531 s//\1/
27534 /^X\(\/\/\)$/{
27535 s//\1/
27538 /^X\(\/\).*/{
27539 s//\1/
27542 s/.*/./; q'`/stamp-h$_am_stamp_count
27545 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
27546 $as_echo "$as_me: executing $ac_file commands" >&6;}
27548 esac
27551 case $ac_file$ac_mode in
27552 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
27553 # Autoconf 2.62 quotes --file arguments for eval, but not when files
27554 # are listed without --file. Let's play safe and only enable the eval
27555 # if we detect the quoting.
27556 case $CONFIG_FILES in
27557 *\'*) eval set x "$CONFIG_FILES" ;;
27558 *) set x $CONFIG_FILES ;;
27559 esac
27560 shift
27561 for mf
27563 # Strip MF so we end up with the name of the file.
27564 mf=`echo "$mf" | sed -e 's/:.*$//'`
27565 # Check whether this is an Automake generated Makefile or not.
27566 # We used to match only the files named `Makefile.in', but
27567 # some people rename them; so instead we look at the file content.
27568 # Grep'ing the first line is not enough: some people post-process
27569 # each Makefile.in and add a new line on top of each file to say so.
27570 # Grep'ing the whole file is not good either: AIX grep has a line
27571 # limit of 2048, but all sed's we know have understand at least 4000.
27572 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
27573 dirpart=`$as_dirname -- "$mf" ||
27574 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27575 X"$mf" : 'X\(//\)[^/]' \| \
27576 X"$mf" : 'X\(//\)$' \| \
27577 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
27578 $as_echo X"$mf" |
27579 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27580 s//\1/
27583 /^X\(\/\/\)[^/].*/{
27584 s//\1/
27587 /^X\(\/\/\)$/{
27588 s//\1/
27591 /^X\(\/\).*/{
27592 s//\1/
27595 s/.*/./; q'`
27596 else
27597 continue
27599 # Extract the definition of DEPDIR, am__include, and am__quote
27600 # from the Makefile without running `make'.
27601 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
27602 test -z "$DEPDIR" && continue
27603 am__include=`sed -n 's/^am__include = //p' < "$mf"`
27604 test -z "am__include" && continue
27605 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
27606 # When using ansi2knr, U may be empty or an underscore; expand it
27607 U=`sed -n 's/^U = //p' < "$mf"`
27608 # Find all dependency output files, they are included files with
27609 # $(DEPDIR) in their names. We invoke sed twice because it is the
27610 # simplest approach to changing $(DEPDIR) to its actual value in the
27611 # expansion.
27612 for file in `sed -n "
27613 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
27614 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
27615 # Make sure the directory exists.
27616 test -f "$dirpart/$file" && continue
27617 fdir=`$as_dirname -- "$file" ||
27618 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27619 X"$file" : 'X\(//\)[^/]' \| \
27620 X"$file" : 'X\(//\)$' \| \
27621 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
27622 $as_echo X"$file" |
27623 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27624 s//\1/
27627 /^X\(\/\/\)[^/].*/{
27628 s//\1/
27631 /^X\(\/\/\)$/{
27632 s//\1/
27635 /^X\(\/\).*/{
27636 s//\1/
27639 s/.*/./; q'`
27640 as_dir=$dirpart/$fdir; as_fn_mkdir_p
27641 # echo "creating $dirpart/$file"
27642 echo '# dummy' > "$dirpart/$file"
27643 done
27644 done
27647 "mkdirs":C)
27648 for dir in etc lisp ; do
27649 test -d ${dir} || mkdir ${dir}
27650 done
27652 "epaths":C)
27653 echo creating src/epaths.h
27654 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
27656 "gdbinit":C)
27657 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
27658 echo creating src/.gdbinit
27659 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
27663 esac
27664 done # for ac_tag
27667 as_fn_exit 0
27668 _ACEOF
27669 ac_clean_files=$ac_clean_files_save
27671 test $ac_write_fail = 0 ||
27672 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
27675 # configure is writing to config.log, and then calls config.status.
27676 # config.status does its own redirection, appending to config.log.
27677 # Unfortunately, on DOS this fails, as config.log is still kept open
27678 # by configure, so config.status won't be able to write to it; its
27679 # output is simply discarded. So we exec the FD to /dev/null,
27680 # effectively closing config.log, so it can be properly (re)opened and
27681 # appended to by config.status. When coming back to configure, we
27682 # need to make the FD available again.
27683 if test "$no_create" != yes; then
27684 ac_cs_success=:
27685 ac_config_status_args=
27686 test "$silent" = yes &&
27687 ac_config_status_args="$ac_config_status_args --quiet"
27688 exec 5>/dev/null
27689 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
27690 exec 5>>config.log
27691 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27692 # would make configure fail if this is the last instruction.
27693 $ac_cs_success || as_fn_exit $?
27695 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
27696 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
27697 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}