Auto-commit of generated files.
[emacs.git] / autogen / configure
blob08577d9efef4efddb1766fa1d55496227578aaf7
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.3.50.
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
32 esac
36 as_nl='
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
150 esac
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
166 else
167 exitcode=1; echo positional parameters were not saved.
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
236 exit 1
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
254 { eval $1=; unset $1;}
256 as_unset=as_fn_unset
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
263 return $1
264 } # as_fn_set_status
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
307 /^X\(\/\/\)$/{
308 s//\1/
311 /^X\(\/\).*/{
312 s//\1/
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
332 eval $1+=\$2
334 else
335 as_fn_append ()
337 eval $1=\$$1\$2
339 fi # as_fn_append
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
349 as_val=$(( $* ))
351 else
352 as_fn_arith ()
354 as_val=`expr "$@" || test $? -eq 1`
356 fi # as_fn_arith
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
403 /^X\/\(\/\/\)$/{
404 s//\1/
407 /^X\/\(\/\).*/{
408 s//\1/
411 s/.*/./; q'`
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
434 :lineno
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
462 ECHO_N='-n';;
463 esac
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
486 else
487 as_ln_s='cp -p'
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
520 as_executable_p=$as_test_x
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
538 # Initializations.
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.3.50'
553 PACKAGE_STRING='emacs 24.3.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 ns_check_file
608 WINDOW_SYSTEM_OBJ
609 EMACS_HEAPSIZE
610 TEMACS_POST_LINK
611 ADDSECTION
612 LD_SWITCH_SYSTEM_TEMACS
613 LIBGNU_LTLIBDEPS
614 LIBGNU_LIBDEPS
615 gltests_WITNESS
616 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE
617 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE
618 gl_GNULIB_ENABLED_tempname_FALSE
619 gl_GNULIB_ENABLED_tempname_TRUE
620 gl_GNULIB_ENABLED_strtoull_FALSE
621 gl_GNULIB_ENABLED_strtoull_TRUE
622 gl_GNULIB_ENABLED_strtoll_FALSE
623 gl_GNULIB_ENABLED_strtoll_TRUE
624 gl_GNULIB_ENABLED_stat_FALSE
625 gl_GNULIB_ENABLED_stat_TRUE
626 gl_GNULIB_ENABLED_secure_getenv_FALSE
627 gl_GNULIB_ENABLED_secure_getenv_TRUE
628 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
629 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
630 gl_GNULIB_ENABLED_pathmax_FALSE
631 gl_GNULIB_ENABLED_pathmax_TRUE
632 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
633 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
634 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
635 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
636 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
637 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
638 gl_GNULIB_ENABLED_getgroups_FALSE
639 gl_GNULIB_ENABLED_getgroups_TRUE
640 gl_GNULIB_ENABLED_getdtablesize_FALSE
641 gl_GNULIB_ENABLED_getdtablesize_TRUE
642 gl_GNULIB_ENABLED_euidaccess_FALSE
643 gl_GNULIB_ENABLED_euidaccess_TRUE
644 gl_GNULIB_ENABLED_dosname_FALSE
645 gl_GNULIB_ENABLED_dosname_TRUE
646 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE
647 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE
648 LTLIBINTL
649 LIBINTL
650 LIB_EACCESS
651 WINDOWS_64_BIT_OFF_T
652 HAVE_UNISTD_H
653 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
654 NEXT_UNISTD_H
655 LIB_TIMER_TIME
656 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
657 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
658 TIME_H_DEFINES_STRUCT_TIMESPEC
659 NEXT_AS_FIRST_DIRECTIVE_TIME_H
660 NEXT_TIME_H
661 WINDOWS_64_BIT_ST_SIZE
662 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
663 NEXT_SYS_STAT_H
664 NEXT_AS_FIRST_DIRECTIVE_STRING_H
665 NEXT_STRING_H
666 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
667 NEXT_STDLIB_H
668 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
669 NEXT_STDIO_H
670 REPLACE_VSPRINTF
671 REPLACE_VSNPRINTF
672 REPLACE_VPRINTF
673 REPLACE_VFPRINTF
674 REPLACE_VDPRINTF
675 REPLACE_VASPRINTF
676 REPLACE_TMPFILE
677 REPLACE_STDIO_WRITE_FUNCS
678 REPLACE_STDIO_READ_FUNCS
679 REPLACE_SPRINTF
680 REPLACE_SNPRINTF
681 REPLACE_RENAMEAT
682 REPLACE_RENAME
683 REPLACE_REMOVE
684 REPLACE_PRINTF
685 REPLACE_POPEN
686 REPLACE_PERROR
687 REPLACE_OBSTACK_PRINTF
688 REPLACE_GETLINE
689 REPLACE_GETDELIM
690 REPLACE_FTELLO
691 REPLACE_FTELL
692 REPLACE_FSEEKO
693 REPLACE_FSEEK
694 REPLACE_FREOPEN
695 REPLACE_FPURGE
696 REPLACE_FPRINTF
697 REPLACE_FOPEN
698 REPLACE_FFLUSH
699 REPLACE_FDOPEN
700 REPLACE_FCLOSE
701 REPLACE_DPRINTF
702 HAVE_VDPRINTF
703 HAVE_VASPRINTF
704 HAVE_RENAMEAT
705 HAVE_POPEN
706 HAVE_PCLOSE
707 HAVE_FTELLO
708 HAVE_FSEEKO
709 HAVE_DPRINTF
710 HAVE_DECL_VSNPRINTF
711 HAVE_DECL_SNPRINTF
712 HAVE_DECL_OBSTACK_PRINTF
713 HAVE_DECL_GETLINE
714 HAVE_DECL_GETDELIM
715 HAVE_DECL_FTELLO
716 HAVE_DECL_FSEEKO
717 HAVE_DECL_FPURGE
718 GNULIB_VSPRINTF_POSIX
719 GNULIB_VSNPRINTF
720 GNULIB_VPRINTF_POSIX
721 GNULIB_VPRINTF
722 GNULIB_VFPRINTF_POSIX
723 GNULIB_VFPRINTF
724 GNULIB_VDPRINTF
725 GNULIB_VSCANF
726 GNULIB_VFSCANF
727 GNULIB_VASPRINTF
728 GNULIB_TMPFILE
729 GNULIB_STDIO_H_SIGPIPE
730 GNULIB_STDIO_H_NONBLOCKING
731 GNULIB_SPRINTF_POSIX
732 GNULIB_SNPRINTF
733 GNULIB_SCANF
734 GNULIB_RENAMEAT
735 GNULIB_RENAME
736 GNULIB_REMOVE
737 GNULIB_PUTS
738 GNULIB_PUTCHAR
739 GNULIB_PUTC
740 GNULIB_PRINTF_POSIX
741 GNULIB_PRINTF
742 GNULIB_POPEN
743 GNULIB_PERROR
744 GNULIB_PCLOSE
745 GNULIB_OBSTACK_PRINTF_POSIX
746 GNULIB_OBSTACK_PRINTF
747 GNULIB_GETLINE
748 GNULIB_GETDELIM
749 GNULIB_GETCHAR
750 GNULIB_GETC
751 GNULIB_FWRITE
752 GNULIB_FTELLO
753 GNULIB_FTELL
754 GNULIB_FSEEKO
755 GNULIB_FSEEK
756 GNULIB_FSCANF
757 GNULIB_FREOPEN
758 GNULIB_FREAD
759 GNULIB_FPUTS
760 GNULIB_FPUTC
761 GNULIB_FPURGE
762 GNULIB_FPRINTF_POSIX
763 GNULIB_FPRINTF
764 GNULIB_FOPEN
765 GNULIB_FGETS
766 GNULIB_FGETC
767 GNULIB_FFLUSH
768 GNULIB_FDOPEN
769 GNULIB_FCLOSE
770 GNULIB_DPRINTF
771 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
772 NEXT_STDDEF_H
773 GL_GENERATE_STDDEF_H_FALSE
774 GL_GENERATE_STDDEF_H_TRUE
775 STDDEF_H
776 HAVE_WCHAR_T
777 REPLACE_NULL
778 HAVE__BOOL
779 GL_GENERATE_STDBOOL_H_FALSE
780 GL_GENERATE_STDBOOL_H_TRUE
781 STDBOOL_H
782 GL_GENERATE_STDARG_H_FALSE
783 GL_GENERATE_STDARG_H_TRUE
784 STDARG_H
785 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
786 NEXT_STDARG_H
787 GL_GENERATE_STDALIGN_H_FALSE
788 GL_GENERATE_STDALIGN_H_TRUE
789 STDALIGN_H
790 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
791 NEXT_SIGNAL_H
792 USE_ACL
793 LIB_ACL
794 LIB_PTHREAD_SIGMASK
795 REPLACE_RAISE
796 REPLACE_PTHREAD_SIGMASK
797 HAVE_SIGHANDLER_T
798 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
799 HAVE_STRUCT_SIGACTION_SA_SIGACTION
800 HAVE_SIGACTION
801 HAVE_SIGINFO_T
802 HAVE_SIGSET_T
803 HAVE_RAISE
804 HAVE_PTHREAD_SIGMASK
805 HAVE_POSIX_SIGNALBLOCKING
806 GNULIB_SIGACTION
807 GNULIB_SIGPROCMASK
808 GNULIB_SIGNAL_H_SIGPIPE
809 GNULIB_RAISE
810 GNULIB_PTHREAD_SIGMASK
811 HAVE_SYS_SELECT_H
812 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
813 NEXT_SYS_SELECT_H
814 REPLACE_SELECT
815 REPLACE_PSELECT
816 HAVE_PSELECT
817 GNULIB_SELECT
818 GNULIB_PSELECT
819 REPLACE_TIMEGM
820 REPLACE_NANOSLEEP
821 REPLACE_MKTIME
822 REPLACE_LOCALTIME_R
823 HAVE_TIMEGM
824 HAVE_STRPTIME
825 HAVE_NANOSLEEP
826 HAVE_DECL_LOCALTIME_R
827 GNULIB_TIME_R
828 GNULIB_TIMEGM
829 GNULIB_STRPTIME
830 GNULIB_NANOSLEEP
831 GNULIB_MKTIME
832 UNDEFINE_STRTOK_R
833 REPLACE_STRTOK_R
834 REPLACE_STRSIGNAL
835 REPLACE_STRNLEN
836 REPLACE_STRNDUP
837 REPLACE_STRNCAT
838 REPLACE_STRERROR_R
839 REPLACE_STRERROR
840 REPLACE_STRCHRNUL
841 REPLACE_STRCASESTR
842 REPLACE_STRSTR
843 REPLACE_STRDUP
844 REPLACE_STPNCPY
845 REPLACE_MEMMEM
846 REPLACE_MEMCHR
847 HAVE_STRVERSCMP
848 HAVE_DECL_STRSIGNAL
849 HAVE_DECL_STRERROR_R
850 HAVE_DECL_STRTOK_R
851 HAVE_STRCASESTR
852 HAVE_STRSEP
853 HAVE_STRPBRK
854 HAVE_DECL_STRNLEN
855 HAVE_DECL_STRNDUP
856 HAVE_DECL_STRDUP
857 HAVE_STRCHRNUL
858 HAVE_STPNCPY
859 HAVE_STPCPY
860 HAVE_RAWMEMCHR
861 HAVE_DECL_MEMRCHR
862 HAVE_MEMPCPY
863 HAVE_DECL_MEMMEM
864 HAVE_MEMCHR
865 HAVE_FFSLL
866 HAVE_FFSL
867 HAVE_MBSLEN
868 GNULIB_STRVERSCMP
869 GNULIB_STRSIGNAL
870 GNULIB_STRERROR_R
871 GNULIB_STRERROR
872 GNULIB_MBSTOK_R
873 GNULIB_MBSSEP
874 GNULIB_MBSSPN
875 GNULIB_MBSPBRK
876 GNULIB_MBSCSPN
877 GNULIB_MBSCASESTR
878 GNULIB_MBSPCASECMP
879 GNULIB_MBSNCASECMP
880 GNULIB_MBSCASECMP
881 GNULIB_MBSSTR
882 GNULIB_MBSRCHR
883 GNULIB_MBSCHR
884 GNULIB_MBSNLEN
885 GNULIB_MBSLEN
886 GNULIB_STRTOK_R
887 GNULIB_STRCASESTR
888 GNULIB_STRSTR
889 GNULIB_STRSEP
890 GNULIB_STRPBRK
891 GNULIB_STRNLEN
892 GNULIB_STRNDUP
893 GNULIB_STRNCAT
894 GNULIB_STRDUP
895 GNULIB_STRCHRNUL
896 GNULIB_STPNCPY
897 GNULIB_STPCPY
898 GNULIB_RAWMEMCHR
899 GNULIB_MEMRCHR
900 GNULIB_MEMPCPY
901 GNULIB_MEMMEM
902 GNULIB_MEMCHR
903 GNULIB_FFSLL
904 GNULIB_FFSL
905 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
906 NEXT_INTTYPES_H
907 UINT64_MAX_EQ_ULONG_MAX
908 UINT32_MAX_LT_UINTMAX_MAX
909 PRIPTR_PREFIX
910 PRI_MACROS_BROKEN
911 INT64_MAX_EQ_LONG_MAX
912 INT32_MAX_LT_INTMAX_MAX
913 REPLACE_STRTOIMAX
914 HAVE_DECL_STRTOUMAX
915 HAVE_DECL_STRTOIMAX
916 HAVE_DECL_IMAXDIV
917 HAVE_DECL_IMAXABS
918 GNULIB_STRTOUMAX
919 GNULIB_STRTOIMAX
920 GNULIB_IMAXDIV
921 GNULIB_IMAXABS
922 GL_GENERATE_STDINT_H_FALSE
923 GL_GENERATE_STDINT_H_TRUE
924 STDINT_H
925 WINT_T_SUFFIX
926 WCHAR_T_SUFFIX
927 SIG_ATOMIC_T_SUFFIX
928 SIZE_T_SUFFIX
929 PTRDIFF_T_SUFFIX
930 HAVE_SIGNED_WINT_T
931 HAVE_SIGNED_WCHAR_T
932 HAVE_SIGNED_SIG_ATOMIC_T
933 BITSIZEOF_WINT_T
934 BITSIZEOF_WCHAR_T
935 BITSIZEOF_SIG_ATOMIC_T
936 BITSIZEOF_SIZE_T
937 BITSIZEOF_PTRDIFF_T
938 APPLE_UNIVERSAL_BUILD
939 HAVE_SYS_BITYPES_H
940 HAVE_SYS_INTTYPES_H
941 HAVE_STDINT_H
942 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
943 NEXT_STDINT_H
944 HAVE_SYS_TYPES_H
945 HAVE_INTTYPES_H
946 HAVE_WCHAR_H
947 HAVE_UNSIGNED_LONG_LONG_INT
948 HAVE_LONG_LONG_INT
949 HAVE_WINSOCK2_H
950 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
951 NEXT_SYS_TIME_H
952 REPLACE_STRUCT_TIMEVAL
953 REPLACE_GETTIMEOFDAY
954 HAVE_SYS_TIME_H
955 HAVE_STRUCT_TIMEVAL
956 HAVE_GETTIMEOFDAY
957 GNULIB_GETTIMEOFDAY
958 GNULIB_GL_UNISTD_H_GETOPT
959 GETOPT_H
960 HAVE_GETOPT_H
961 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
962 NEXT_GETOPT_H
963 GETLOADAVG_LIBS
964 REPLACE_WCTOMB
965 REPLACE_UNSETENV
966 REPLACE_STRTOD
967 REPLACE_SETENV
968 REPLACE_REALPATH
969 REPLACE_REALLOC
970 REPLACE_RANDOM_R
971 REPLACE_PUTENV
972 REPLACE_PTSNAME_R
973 REPLACE_PTSNAME
974 REPLACE_MKSTEMP
975 REPLACE_MBTOWC
976 REPLACE_MALLOC
977 REPLACE_CANONICALIZE_FILE_NAME
978 REPLACE_CALLOC
979 HAVE_DECL_UNSETENV
980 HAVE_UNLOCKPT
981 HAVE_SYS_LOADAVG_H
982 HAVE_STRUCT_RANDOM_DATA
983 HAVE_STRTOULL
984 HAVE_STRTOLL
985 HAVE_STRTOD
986 HAVE_DECL_SETENV
987 HAVE_SETENV
988 HAVE_SECURE_GETENV
989 HAVE_RPMATCH
990 HAVE_REALPATH
991 HAVE_RANDOM_R
992 HAVE_RANDOM_H
993 HAVE_RANDOM
994 HAVE_PTSNAME_R
995 HAVE_PTSNAME
996 HAVE_POSIX_OPENPT
997 HAVE_MKSTEMPS
998 HAVE_MKSTEMP
999 HAVE_MKOSTEMPS
1000 HAVE_MKOSTEMP
1001 HAVE_MKDTEMP
1002 HAVE_GRANTPT
1003 HAVE_GETSUBOPT
1004 HAVE_DECL_GETLOADAVG
1005 HAVE_CANONICALIZE_FILE_NAME
1006 HAVE_ATOLL
1007 HAVE__EXIT
1008 GNULIB_WCTOMB
1009 GNULIB_UNSETENV
1010 GNULIB_UNLOCKPT
1011 GNULIB_SYSTEM_POSIX
1012 GNULIB_STRTOULL
1013 GNULIB_STRTOLL
1014 GNULIB_STRTOD
1015 GNULIB_SETENV
1016 GNULIB_SECURE_GETENV
1017 GNULIB_RPMATCH
1018 GNULIB_REALPATH
1019 GNULIB_REALLOC_POSIX
1020 GNULIB_RANDOM_R
1021 GNULIB_RANDOM
1022 GNULIB_PUTENV
1023 GNULIB_PTSNAME_R
1024 GNULIB_PTSNAME
1025 GNULIB_POSIX_OPENPT
1026 GNULIB_MKSTEMPS
1027 GNULIB_MKSTEMP
1028 GNULIB_MKOSTEMPS
1029 GNULIB_MKOSTEMP
1030 GNULIB_MKDTEMP
1031 GNULIB_MBTOWC
1032 GNULIB_MALLOC_POSIX
1033 GNULIB_GRANTPT
1034 GNULIB_GETSUBOPT
1035 GNULIB_GETLOADAVG
1036 GNULIB_CANONICALIZE_FILE_NAME
1037 GNULIB_CALLOC_POSIX
1038 GNULIB_ATOLL
1039 GNULIB__EXIT
1040 REPLACE_UTIMENSAT
1041 REPLACE_STAT
1042 REPLACE_MKNOD
1043 REPLACE_MKFIFO
1044 REPLACE_MKDIR
1045 REPLACE_LSTAT
1046 REPLACE_FUTIMENS
1047 REPLACE_FSTATAT
1048 REPLACE_FSTAT
1049 HAVE_UTIMENSAT
1050 HAVE_MKNODAT
1051 HAVE_MKNOD
1052 HAVE_MKFIFOAT
1053 HAVE_MKFIFO
1054 HAVE_MKDIRAT
1055 HAVE_LSTAT
1056 HAVE_LCHMOD
1057 HAVE_FUTIMENS
1058 HAVE_FSTATAT
1059 HAVE_FCHMODAT
1060 GNULIB_UTIMENSAT
1061 GNULIB_STAT
1062 GNULIB_MKNODAT
1063 GNULIB_MKNOD
1064 GNULIB_MKFIFOAT
1065 GNULIB_MKFIFO
1066 GNULIB_MKDIRAT
1067 GNULIB_LSTAT
1068 GNULIB_LCHMOD
1069 GNULIB_FUTIMENS
1070 GNULIB_FSTATAT
1071 GNULIB_FSTAT
1072 GNULIB_FCHMODAT
1073 LIB_FDATASYNC
1074 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1075 NEXT_FCNTL_H
1076 REPLACE_OPENAT
1077 REPLACE_OPEN
1078 REPLACE_FCNTL
1079 HAVE_OPENAT
1080 HAVE_FCNTL
1081 GNULIB_OPENAT
1082 GNULIB_OPEN
1083 GNULIB_NONBLOCKING
1084 GNULIB_FCNTL
1085 GL_GENERATE_EXECINFO_H_FALSE
1086 GL_GENERATE_EXECINFO_H_TRUE
1087 LIB_EXECINFO
1088 EXECINFO_H
1089 EOVERFLOW_VALUE
1090 EOVERFLOW_HIDDEN
1091 ENOLINK_VALUE
1092 ENOLINK_HIDDEN
1093 EMULTIHOP_VALUE
1094 EMULTIHOP_HIDDEN
1095 GL_GENERATE_ERRNO_H_FALSE
1096 GL_GENERATE_ERRNO_H_TRUE
1097 ERRNO_H
1098 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1099 NEXT_ERRNO_H
1100 HAVE_DIRENT_H
1101 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1102 NEXT_DIRENT_H
1103 PRAGMA_COLUMNS
1104 PRAGMA_SYSTEM_HEADER
1105 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1106 INCLUDE_NEXT
1107 REPLACE_FDOPENDIR
1108 REPLACE_DIRFD
1109 REPLACE_CLOSEDIR
1110 REPLACE_OPENDIR
1111 HAVE_ALPHASORT
1112 HAVE_SCANDIR
1113 HAVE_FDOPENDIR
1114 HAVE_DECL_FDOPENDIR
1115 HAVE_DECL_DIRFD
1116 HAVE_CLOSEDIR
1117 HAVE_REWINDDIR
1118 HAVE_READDIR
1119 HAVE_OPENDIR
1120 GNULIB_ALPHASORT
1121 GNULIB_SCANDIR
1122 GNULIB_FDOPENDIR
1123 GNULIB_DIRFD
1124 GNULIB_CLOSEDIR
1125 GNULIB_REWINDDIR
1126 GNULIB_READDIR
1127 GNULIB_OPENDIR
1128 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1129 UNISTD_H_HAVE_WINSOCK2_H
1130 REPLACE_WRITE
1131 REPLACE_USLEEP
1132 REPLACE_UNLINKAT
1133 REPLACE_UNLINK
1134 REPLACE_TTYNAME_R
1135 REPLACE_SYMLINK
1136 REPLACE_SLEEP
1137 REPLACE_RMDIR
1138 REPLACE_READLINK
1139 REPLACE_READ
1140 REPLACE_PWRITE
1141 REPLACE_PREAD
1142 REPLACE_LSEEK
1143 REPLACE_LINKAT
1144 REPLACE_LINK
1145 REPLACE_LCHOWN
1146 REPLACE_ISATTY
1147 REPLACE_GETPAGESIZE
1148 REPLACE_GETGROUPS
1149 REPLACE_GETLOGIN_R
1150 REPLACE_GETDOMAINNAME
1151 REPLACE_GETCWD
1152 REPLACE_FTRUNCATE
1153 REPLACE_FCHOWNAT
1154 REPLACE_DUP2
1155 REPLACE_DUP
1156 REPLACE_CLOSE
1157 REPLACE_CHOWN
1158 HAVE_SYS_PARAM_H
1159 HAVE_OS_H
1160 HAVE_DECL_TTYNAME_R
1161 HAVE_DECL_SETHOSTNAME
1162 HAVE_DECL_GETUSERSHELL
1163 HAVE_DECL_GETPAGESIZE
1164 HAVE_DECL_GETLOGIN_R
1165 HAVE_DECL_GETDOMAINNAME
1166 HAVE_DECL_FDATASYNC
1167 HAVE_DECL_FCHDIR
1168 HAVE_DECL_ENVIRON
1169 HAVE_USLEEP
1170 HAVE_UNLINKAT
1171 HAVE_SYMLINKAT
1172 HAVE_SYMLINK
1173 HAVE_SLEEP
1174 HAVE_SETHOSTNAME
1175 HAVE_READLINKAT
1176 HAVE_READLINK
1177 HAVE_PWRITE
1178 HAVE_PREAD
1179 HAVE_PIPE2
1180 HAVE_PIPE
1181 HAVE_LINKAT
1182 HAVE_LINK
1183 HAVE_LCHOWN
1184 HAVE_GROUP_MEMBER
1185 HAVE_GETPAGESIZE
1186 HAVE_GETLOGIN
1187 HAVE_GETHOSTNAME
1188 HAVE_GETGROUPS
1189 HAVE_GETDTABLESIZE
1190 HAVE_FTRUNCATE
1191 HAVE_FSYNC
1192 HAVE_FDATASYNC
1193 HAVE_FCHOWNAT
1194 HAVE_FCHDIR
1195 HAVE_FACCESSAT
1196 HAVE_EUIDACCESS
1197 HAVE_DUP3
1198 HAVE_DUP2
1199 HAVE_CHOWN
1200 GNULIB_WRITE
1201 GNULIB_USLEEP
1202 GNULIB_UNLINKAT
1203 GNULIB_UNLINK
1204 GNULIB_UNISTD_H_SIGPIPE
1205 GNULIB_UNISTD_H_NONBLOCKING
1206 GNULIB_TTYNAME_R
1207 GNULIB_SYMLINKAT
1208 GNULIB_SYMLINK
1209 GNULIB_SLEEP
1210 GNULIB_SETHOSTNAME
1211 GNULIB_RMDIR
1212 GNULIB_READLINKAT
1213 GNULIB_READLINK
1214 GNULIB_READ
1215 GNULIB_PWRITE
1216 GNULIB_PREAD
1217 GNULIB_PIPE2
1218 GNULIB_PIPE
1219 GNULIB_LSEEK
1220 GNULIB_LINKAT
1221 GNULIB_LINK
1222 GNULIB_LCHOWN
1223 GNULIB_ISATTY
1224 GNULIB_GROUP_MEMBER
1225 GNULIB_GETUSERSHELL
1226 GNULIB_GETPAGESIZE
1227 GNULIB_GETLOGIN_R
1228 GNULIB_GETLOGIN
1229 GNULIB_GETHOSTNAME
1230 GNULIB_GETGROUPS
1231 GNULIB_GETDTABLESIZE
1232 GNULIB_GETDOMAINNAME
1233 GNULIB_GETCWD
1234 GNULIB_FTRUNCATE
1235 GNULIB_FSYNC
1236 GNULIB_FDATASYNC
1237 GNULIB_FCHOWNAT
1238 GNULIB_FCHDIR
1239 GNULIB_FACCESSAT
1240 GNULIB_EUIDACCESS
1241 GNULIB_ENVIRON
1242 GNULIB_DUP3
1243 GNULIB_DUP2
1244 GNULIB_DUP
1245 GNULIB_CLOSE
1246 GNULIB_CHOWN
1247 GNULIB_CHDIR
1248 LIB_CLOCK_GETTIME
1249 GL_GENERATE_ALLOCA_H_FALSE
1250 GL_GENERATE_ALLOCA_H_TRUE
1251 ALLOCA_H
1252 ALLOCA
1253 GL_COND_LIBTOOL_FALSE
1254 GL_COND_LIBTOOL_TRUE
1255 POST_ALLOC_OBJ
1256 PRE_ALLOC_OBJ
1257 CYGWIN_OBJ
1258 RALLOC_OBJ
1259 OLDXMENU_DEPS
1260 LIBX_OTHER
1261 LIBXMENU
1262 OLDXMENU
1263 OLDXMENU_TARGET
1264 LIBXT_OTHER
1265 TOOLKIT_LIBW
1266 WIDGET_OBJ
1267 XOBJ
1268 XMENU_OBJ
1269 FONT_OBJ
1270 OTHER_FILES
1271 GNU_OBJC_CFLAGS
1272 ns_appsrc
1273 ns_appresdir
1274 ns_appbindir
1275 ns_appdir
1276 X_TOOLKIT_TYPE
1277 GNUSTEP_CFLAGS
1278 C_SWITCH_X_SITE
1279 LD_SWITCH_X_SITE
1280 gameuser
1281 gamedir
1282 bitmapdir
1283 etcdocdir
1284 archlibdir
1285 etcdir
1286 x_default_search_path
1287 lisppath
1288 locallisppath
1289 standardlisppath
1290 leimdir
1291 lispdir
1292 srcdir
1293 canonical
1294 configuration
1295 version
1296 copyright
1297 XGSELOBJ
1298 KRB4LIB
1299 DESLIB
1300 KRB5LIB
1301 CRYPTOLIB
1302 COM_ERRLIB
1303 LIBRESOLV
1304 LIBHESIOD
1305 TERMCAP_OBJ
1306 LIBS_TERMCAP
1307 BLESSMAIL_TARGET
1308 LIBS_MAIL
1309 liblockfile
1310 LIBXML2_LIBS
1311 LIBXML2_CFLAGS
1312 XINERAMA_LIBS
1313 XINERAMA_CFLAGS
1314 XRANDR_LIBS
1315 XRANDR_CFLAGS
1316 LIBXSM
1317 LIBGPM
1318 LIBGIF
1319 LIBTIFF
1320 LIBZ
1321 LIBPNG
1322 LIBJPEG
1323 LIBXPM
1324 M17N_FLT_LIBS
1325 M17N_FLT_CFLAGS
1326 LIBOTF_LIBS
1327 LIBOTF_CFLAGS
1328 FREETYPE_LIBS
1329 FREETYPE_CFLAGS
1330 XFT_LIBS
1331 XFT_CFLAGS
1332 FONTCONFIG_LIBS
1333 FONTCONFIG_CFLAGS
1334 LIBXMU
1335 LIBXTR6
1336 NOTIFY_OBJ
1337 GFILENOTIFY_LIBS
1338 GFILENOTIFY_CFLAGS
1339 LIBGNUTLS_LIBS
1340 LIBGNUTLS_CFLAGS
1341 LIBSELINUX_LIBS
1342 SETTINGS_LIBS
1343 SETTINGS_CFLAGS
1344 GOBJECT_LIBS
1345 GOBJECT_CFLAGS
1346 GCONF_LIBS
1347 GCONF_CFLAGS
1348 GSETTINGS_LIBS
1349 GSETTINGS_CFLAGS
1350 DBUS_OBJ
1351 DBUS_LIBS
1352 DBUS_CFLAGS
1353 GTK_OBJ
1354 GTK_LIBS
1355 GTK_CFLAGS
1356 IMAGEMAGICK_LIBS
1357 IMAGEMAGICK_CFLAGS
1358 RSVG_LIBS
1359 RSVG_CFLAGS
1360 LIB_PTHREAD
1361 VMLIMIT_OBJ
1362 GMALLOC_OBJ
1363 HAVE_XSERVER
1364 XARGS_LIMIT
1365 NTLIB
1366 LIB_WSOCK32
1367 LIBS_ECLIENT
1368 CM_OBJ
1369 NTDIR
1370 FIRSTFILE_OBJ
1371 W32_RES_LINK
1372 CLIENTW
1373 CLIENTRES
1374 UPDATE_MANIFEST
1375 EMACS_MANIFEST
1376 EMACSRES
1377 W32_LIBS
1378 W32_OBJ
1379 WINDRES
1380 NS_OBJC_OBJ
1381 NS_OBJ
1382 ns_self_contained
1383 INSTALL_ARCH_INDEP_EXTRA
1384 LIBS_GNUSTEP
1385 LD_SWITCH_X_SITE_RPATH
1386 XMKMF
1387 DEPFLAGS
1388 MKDEPDIR
1389 CFLAGS_SOUND
1390 ALSA_LIBS
1391 ALSA_CFLAGS
1392 LIBSOUND
1393 PKG_CONFIG
1394 LIB_MATH
1395 LIBS_SYSTEM
1396 C_SWITCH_SYSTEM
1397 UNEXEC_OBJ
1398 C_SWITCH_MACHINE
1399 LD_SWITCH_SYSTEM
1400 CANNOT_DUMP
1401 DOCMISC_W32
1402 INFO_OPTS
1403 INFO_EXT
1404 HAVE_MAKEINFO
1405 PAXCTL
1406 GZIP_PROG
1407 INSTALL_INFO
1408 LN_S_FILEONLY
1409 GNULIB_WARN_CFLAGS
1410 WERROR_CFLAGS
1411 WARN_CFLAGS
1412 RANLIB
1413 ARFLAGS
1415 EGREP
1416 GREP
1418 BUILDING_FOR_WINDOWSNT_FALSE
1419 BUILDING_FOR_WINDOWSNT_TRUE
1420 am__fastdepCC_FALSE
1421 am__fastdepCC_TRUE
1422 CCDEPMODE
1423 AMDEPBACKSLASH
1424 AMDEP_FALSE
1425 AMDEP_TRUE
1426 am__quote
1427 am__include
1428 DEPDIR
1429 OBJEXT
1430 EXEEXT
1431 ac_ct_CC
1432 CPPFLAGS
1433 LDFLAGS
1434 CFLAGS
1436 host_os
1437 host_vendor
1438 host_cpu
1439 host
1440 build_os
1441 build_vendor
1442 build_cpu
1443 build
1444 PROFILING_CFLAGS
1445 cache_file
1446 am__untar
1447 am__tar
1448 AMTAR
1449 am__leading_dot
1450 SET_MAKE
1452 mkdir_p
1453 MKDIR_P
1454 INSTALL_STRIP_PROGRAM
1455 STRIP
1456 install_sh
1457 MAKEINFO
1458 AUTOHEADER
1459 AUTOMAKE
1460 AUTOCONF
1461 ACLOCAL
1462 VERSION
1463 PACKAGE
1464 CYGPATH_W
1465 am__isrc
1466 INSTALL_DATA
1467 INSTALL_SCRIPT
1468 INSTALL_PROGRAM
1469 target_alias
1470 host_alias
1471 build_alias
1472 LIBS
1473 ECHO_T
1474 ECHO_N
1475 ECHO_C
1476 DEFS
1477 mandir
1478 localedir
1479 libdir
1480 psdir
1481 pdfdir
1482 dvidir
1483 htmldir
1484 infodir
1485 docdir
1486 oldincludedir
1487 includedir
1488 localstatedir
1489 sharedstatedir
1490 sysconfdir
1491 datadir
1492 datarootdir
1493 libexecdir
1494 sbindir
1495 bindir
1496 program_transform_name
1497 prefix
1498 exec_prefix
1499 PACKAGE_URL
1500 PACKAGE_BUGREPORT
1501 PACKAGE_STRING
1502 PACKAGE_VERSION
1503 PACKAGE_TARNAME
1504 PACKAGE_NAME
1505 PATH_SEPARATOR
1506 SHELL'
1507 ac_subst_files='deps_frag
1508 lisp_frag'
1509 ac_user_opts='
1510 enable_option_checking
1511 with_all
1512 with_pop
1513 with_kerberos
1514 with_kerberos5
1515 with_hesiod
1516 with_mmdf
1517 with_mail_unlink
1518 with_mailhost
1519 with_sound
1520 with_x_toolkit
1521 with_wide_int
1522 with_xpm
1523 with_jpeg
1524 with_tiff
1525 with_gif
1526 with_png
1527 with_rsvg
1528 with_xml2
1529 with_imagemagick
1530 with_xft
1531 with_libotf
1532 with_m17n_flt
1533 with_toolkit_scroll_bars
1534 with_xaw3d
1535 with_xim
1536 with_ns
1537 with_w32
1538 with_gpm
1539 with_dbus
1540 with_gconf
1541 with_gsettings
1542 with_selinux
1543 with_gnutls
1544 with_zlib
1545 with_file_notification
1546 with_makeinfo
1547 with_compress_install
1548 with_pkg_config_prog
1549 with_gameuser
1550 with_gnustep_conf
1551 enable_ns_self_contained
1552 enable_locallisppath
1553 enable_checking
1554 enable_check_lisp_object_type
1555 enable_profiling
1556 enable_autodepend
1557 enable_gtk_deprecation_warnings
1558 enable_dependency_tracking
1559 enable_largefile
1560 enable_gcc_warnings
1561 enable_link_time_optimization
1562 with_x
1563 enable_acl
1565 ac_precious_vars='build_alias
1566 host_alias
1567 target_alias
1569 CFLAGS
1570 LDFLAGS
1571 LIBS
1572 CPPFLAGS
1574 XMKMF'
1577 # Initialize some variables set by options.
1578 ac_init_help=
1579 ac_init_version=false
1580 ac_unrecognized_opts=
1581 ac_unrecognized_sep=
1582 # The variables have the same names as the options, with
1583 # dashes changed to underlines.
1584 cache_file=/dev/null
1585 exec_prefix=NONE
1586 no_create=
1587 no_recursion=
1588 prefix=NONE
1589 program_prefix=NONE
1590 program_suffix=NONE
1591 program_transform_name=s,x,x,
1592 silent=
1593 site=
1594 srcdir=
1595 verbose=
1596 x_includes=NONE
1597 x_libraries=NONE
1599 # Installation directory options.
1600 # These are left unexpanded so users can "make install exec_prefix=/foo"
1601 # and all the variables that are supposed to be based on exec_prefix
1602 # by default will actually change.
1603 # Use braces instead of parens because sh, perl, etc. also accept them.
1604 # (The list follows the same order as the GNU Coding Standards.)
1605 bindir='${exec_prefix}/bin'
1606 sbindir='${exec_prefix}/sbin'
1607 libexecdir='${exec_prefix}/libexec'
1608 datarootdir='${prefix}/share'
1609 datadir='${datarootdir}'
1610 sysconfdir='${prefix}/etc'
1611 sharedstatedir='${prefix}/com'
1612 localstatedir='${prefix}/var'
1613 includedir='${prefix}/include'
1614 oldincludedir='/usr/include'
1615 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1616 infodir='${datarootdir}/info'
1617 htmldir='${docdir}'
1618 dvidir='${docdir}'
1619 pdfdir='${docdir}'
1620 psdir='${docdir}'
1621 libdir='${exec_prefix}/lib'
1622 localedir='${datarootdir}/locale'
1623 mandir='${datarootdir}/man'
1625 ac_prev=
1626 ac_dashdash=
1627 for ac_option
1629 # If the previous option needs an argument, assign it.
1630 if test -n "$ac_prev"; then
1631 eval $ac_prev=\$ac_option
1632 ac_prev=
1633 continue
1636 case $ac_option in
1637 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1638 *) ac_optarg=yes ;;
1639 esac
1641 # Accept the important Cygnus configure options, so we can diagnose typos.
1643 case $ac_dashdash$ac_option in
1645 ac_dashdash=yes ;;
1647 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1648 ac_prev=bindir ;;
1649 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1650 bindir=$ac_optarg ;;
1652 -build | --build | --buil | --bui | --bu)
1653 ac_prev=build_alias ;;
1654 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1655 build_alias=$ac_optarg ;;
1657 -cache-file | --cache-file | --cache-fil | --cache-fi \
1658 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1659 ac_prev=cache_file ;;
1660 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1661 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1662 cache_file=$ac_optarg ;;
1664 --config-cache | -C)
1665 cache_file=config.cache ;;
1667 -datadir | --datadir | --datadi | --datad)
1668 ac_prev=datadir ;;
1669 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1670 datadir=$ac_optarg ;;
1672 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1673 | --dataroo | --dataro | --datar)
1674 ac_prev=datarootdir ;;
1675 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1676 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1677 datarootdir=$ac_optarg ;;
1679 -disable-* | --disable-*)
1680 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1681 # Reject names that are not valid shell variable names.
1682 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1683 as_fn_error "invalid feature name: $ac_useropt"
1684 ac_useropt_orig=$ac_useropt
1685 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1686 case $ac_user_opts in
1688 "enable_$ac_useropt"
1689 "*) ;;
1690 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1691 ac_unrecognized_sep=', ';;
1692 esac
1693 eval enable_$ac_useropt=no ;;
1695 -docdir | --docdir | --docdi | --doc | --do)
1696 ac_prev=docdir ;;
1697 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1698 docdir=$ac_optarg ;;
1700 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1701 ac_prev=dvidir ;;
1702 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1703 dvidir=$ac_optarg ;;
1705 -enable-* | --enable-*)
1706 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1707 # Reject names that are not valid shell variable names.
1708 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1709 as_fn_error "invalid feature name: $ac_useropt"
1710 ac_useropt_orig=$ac_useropt
1711 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1712 case $ac_user_opts in
1714 "enable_$ac_useropt"
1715 "*) ;;
1716 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1717 ac_unrecognized_sep=', ';;
1718 esac
1719 eval enable_$ac_useropt=\$ac_optarg ;;
1721 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1722 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1723 | --exec | --exe | --ex)
1724 ac_prev=exec_prefix ;;
1725 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1726 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1727 | --exec=* | --exe=* | --ex=*)
1728 exec_prefix=$ac_optarg ;;
1730 -gas | --gas | --ga | --g)
1731 # Obsolete; use --with-gas.
1732 with_gas=yes ;;
1734 -help | --help | --hel | --he | -h)
1735 ac_init_help=long ;;
1736 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1737 ac_init_help=recursive ;;
1738 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1739 ac_init_help=short ;;
1741 -host | --host | --hos | --ho)
1742 ac_prev=host_alias ;;
1743 -host=* | --host=* | --hos=* | --ho=*)
1744 host_alias=$ac_optarg ;;
1746 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1747 ac_prev=htmldir ;;
1748 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1749 | --ht=*)
1750 htmldir=$ac_optarg ;;
1752 -includedir | --includedir | --includedi | --included | --include \
1753 | --includ | --inclu | --incl | --inc)
1754 ac_prev=includedir ;;
1755 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1756 | --includ=* | --inclu=* | --incl=* | --inc=*)
1757 includedir=$ac_optarg ;;
1759 -infodir | --infodir | --infodi | --infod | --info | --inf)
1760 ac_prev=infodir ;;
1761 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1762 infodir=$ac_optarg ;;
1764 -libdir | --libdir | --libdi | --libd)
1765 ac_prev=libdir ;;
1766 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1767 libdir=$ac_optarg ;;
1769 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1770 | --libexe | --libex | --libe)
1771 ac_prev=libexecdir ;;
1772 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1773 | --libexe=* | --libex=* | --libe=*)
1774 libexecdir=$ac_optarg ;;
1776 -localedir | --localedir | --localedi | --localed | --locale)
1777 ac_prev=localedir ;;
1778 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1779 localedir=$ac_optarg ;;
1781 -localstatedir | --localstatedir | --localstatedi | --localstated \
1782 | --localstate | --localstat | --localsta | --localst | --locals)
1783 ac_prev=localstatedir ;;
1784 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1785 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1786 localstatedir=$ac_optarg ;;
1788 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1789 ac_prev=mandir ;;
1790 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1791 mandir=$ac_optarg ;;
1793 -nfp | --nfp | --nf)
1794 # Obsolete; use --without-fp.
1795 with_fp=no ;;
1797 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1798 | --no-cr | --no-c | -n)
1799 no_create=yes ;;
1801 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1802 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1803 no_recursion=yes ;;
1805 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1806 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1807 | --oldin | --oldi | --old | --ol | --o)
1808 ac_prev=oldincludedir ;;
1809 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1810 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1811 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1812 oldincludedir=$ac_optarg ;;
1814 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1815 ac_prev=prefix ;;
1816 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1817 prefix=$ac_optarg ;;
1819 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1820 | --program-pre | --program-pr | --program-p)
1821 ac_prev=program_prefix ;;
1822 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1823 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1824 program_prefix=$ac_optarg ;;
1826 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1827 | --program-suf | --program-su | --program-s)
1828 ac_prev=program_suffix ;;
1829 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1830 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1831 program_suffix=$ac_optarg ;;
1833 -program-transform-name | --program-transform-name \
1834 | --program-transform-nam | --program-transform-na \
1835 | --program-transform-n | --program-transform- \
1836 | --program-transform | --program-transfor \
1837 | --program-transfo | --program-transf \
1838 | --program-trans | --program-tran \
1839 | --progr-tra | --program-tr | --program-t)
1840 ac_prev=program_transform_name ;;
1841 -program-transform-name=* | --program-transform-name=* \
1842 | --program-transform-nam=* | --program-transform-na=* \
1843 | --program-transform-n=* | --program-transform-=* \
1844 | --program-transform=* | --program-transfor=* \
1845 | --program-transfo=* | --program-transf=* \
1846 | --program-trans=* | --program-tran=* \
1847 | --progr-tra=* | --program-tr=* | --program-t=*)
1848 program_transform_name=$ac_optarg ;;
1850 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1851 ac_prev=pdfdir ;;
1852 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1853 pdfdir=$ac_optarg ;;
1855 -psdir | --psdir | --psdi | --psd | --ps)
1856 ac_prev=psdir ;;
1857 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1858 psdir=$ac_optarg ;;
1860 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1861 | -silent | --silent | --silen | --sile | --sil)
1862 silent=yes ;;
1864 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1865 ac_prev=sbindir ;;
1866 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1867 | --sbi=* | --sb=*)
1868 sbindir=$ac_optarg ;;
1870 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1871 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1872 | --sharedst | --shareds | --shared | --share | --shar \
1873 | --sha | --sh)
1874 ac_prev=sharedstatedir ;;
1875 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1876 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1877 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1878 | --sha=* | --sh=*)
1879 sharedstatedir=$ac_optarg ;;
1881 -site | --site | --sit)
1882 ac_prev=site ;;
1883 -site=* | --site=* | --sit=*)
1884 site=$ac_optarg ;;
1886 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1887 ac_prev=srcdir ;;
1888 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1889 srcdir=$ac_optarg ;;
1891 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1892 | --syscon | --sysco | --sysc | --sys | --sy)
1893 ac_prev=sysconfdir ;;
1894 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1895 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1896 sysconfdir=$ac_optarg ;;
1898 -target | --target | --targe | --targ | --tar | --ta | --t)
1899 ac_prev=target_alias ;;
1900 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1901 target_alias=$ac_optarg ;;
1903 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1904 verbose=yes ;;
1906 -version | --version | --versio | --versi | --vers | -V)
1907 ac_init_version=: ;;
1909 -with-* | --with-*)
1910 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1911 # Reject names that are not valid shell variable names.
1912 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1913 as_fn_error "invalid package name: $ac_useropt"
1914 ac_useropt_orig=$ac_useropt
1915 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1916 case $ac_user_opts in
1918 "with_$ac_useropt"
1919 "*) ;;
1920 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1921 ac_unrecognized_sep=', ';;
1922 esac
1923 eval with_$ac_useropt=\$ac_optarg ;;
1925 -without-* | --without-*)
1926 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1927 # Reject names that are not valid shell variable names.
1928 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1929 as_fn_error "invalid package name: $ac_useropt"
1930 ac_useropt_orig=$ac_useropt
1931 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1932 case $ac_user_opts in
1934 "with_$ac_useropt"
1935 "*) ;;
1936 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1937 ac_unrecognized_sep=', ';;
1938 esac
1939 eval with_$ac_useropt=no ;;
1941 --x)
1942 # Obsolete; use --with-x.
1943 with_x=yes ;;
1945 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1946 | --x-incl | --x-inc | --x-in | --x-i)
1947 ac_prev=x_includes ;;
1948 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1949 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1950 x_includes=$ac_optarg ;;
1952 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1953 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1954 ac_prev=x_libraries ;;
1955 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1956 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1957 x_libraries=$ac_optarg ;;
1959 -*) as_fn_error "unrecognized option: \`$ac_option'
1960 Try \`$0 --help' for more information."
1963 *=*)
1964 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1965 # Reject names that are not valid shell variable names.
1966 case $ac_envvar in #(
1967 '' | [0-9]* | *[!_$as_cr_alnum]* )
1968 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1969 esac
1970 eval $ac_envvar=\$ac_optarg
1971 export $ac_envvar ;;
1974 # FIXME: should be removed in autoconf 3.0.
1975 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1976 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1977 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1978 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1981 esac
1982 done
1984 if test -n "$ac_prev"; then
1985 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1986 as_fn_error "missing argument to $ac_option"
1989 if test -n "$ac_unrecognized_opts"; then
1990 case $enable_option_checking in
1991 no) ;;
1992 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1993 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1994 esac
1997 # Check all directory arguments for consistency.
1998 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1999 datadir sysconfdir sharedstatedir localstatedir includedir \
2000 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2001 libdir localedir mandir
2003 eval ac_val=\$$ac_var
2004 # Remove trailing slashes.
2005 case $ac_val in
2006 */ )
2007 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2008 eval $ac_var=\$ac_val;;
2009 esac
2010 # Be sure to have absolute directory names.
2011 case $ac_val in
2012 [\\/$]* | ?:[\\/]* ) continue;;
2013 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2014 esac
2015 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2016 done
2018 # There might be people who depend on the old broken behavior: `$host'
2019 # used to hold the argument of --host etc.
2020 # FIXME: To remove some day.
2021 build=$build_alias
2022 host=$host_alias
2023 target=$target_alias
2025 # FIXME: To remove some day.
2026 if test "x$host_alias" != x; then
2027 if test "x$build_alias" = x; then
2028 cross_compiling=maybe
2029 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2030 If a cross compiler is detected then cross compile mode will be used." >&2
2031 elif test "x$build_alias" != "x$host_alias"; then
2032 cross_compiling=yes
2036 ac_tool_prefix=
2037 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2039 test "$silent" = yes && exec 6>/dev/null
2042 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2043 ac_ls_di=`ls -di .` &&
2044 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2045 as_fn_error "working directory cannot be determined"
2046 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2047 as_fn_error "pwd does not report name of working directory"
2050 # Find the source files, if location was not specified.
2051 if test -z "$srcdir"; then
2052 ac_srcdir_defaulted=yes
2053 # Try the directory containing this script, then the parent directory.
2054 ac_confdir=`$as_dirname -- "$as_myself" ||
2055 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2056 X"$as_myself" : 'X\(//\)[^/]' \| \
2057 X"$as_myself" : 'X\(//\)$' \| \
2058 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2059 $as_echo X"$as_myself" |
2060 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2061 s//\1/
2064 /^X\(\/\/\)[^/].*/{
2065 s//\1/
2068 /^X\(\/\/\)$/{
2069 s//\1/
2072 /^X\(\/\).*/{
2073 s//\1/
2076 s/.*/./; q'`
2077 srcdir=$ac_confdir
2078 if test ! -r "$srcdir/$ac_unique_file"; then
2079 srcdir=..
2081 else
2082 ac_srcdir_defaulted=no
2084 if test ! -r "$srcdir/$ac_unique_file"; then
2085 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2086 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2088 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2089 ac_abs_confdir=`(
2090 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2091 pwd)`
2092 # When building in place, set srcdir=.
2093 if test "$ac_abs_confdir" = "$ac_pwd"; then
2094 srcdir=.
2096 # Remove unnecessary trailing slashes from srcdir.
2097 # Double slashes in file names in object file debugging info
2098 # mess up M-x gdb in Emacs.
2099 case $srcdir in
2100 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2101 esac
2102 for ac_var in $ac_precious_vars; do
2103 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2104 eval ac_env_${ac_var}_value=\$${ac_var}
2105 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2106 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2107 done
2110 # Report the --help message.
2112 if test "$ac_init_help" = "long"; then
2113 # Omit some internal or obsolete options to make the list less imposing.
2114 # This message is too long to be a string in the A/UX 3.1 sh.
2115 cat <<_ACEOF
2116 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
2118 Usage: $0 [OPTION]... [VAR=VALUE]...
2120 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2121 VAR=VALUE. See below for descriptions of some of the useful variables.
2123 Defaults for the options are specified in brackets.
2125 Configuration:
2126 -h, --help display this help and exit
2127 --help=short display options specific to this package
2128 --help=recursive display the short help of all the included packages
2129 -V, --version display version information and exit
2130 -q, --quiet, --silent do not print \`checking...' messages
2131 --cache-file=FILE cache test results in FILE [disabled]
2132 -C, --config-cache alias for \`--cache-file=config.cache'
2133 -n, --no-create do not create output files
2134 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2136 Installation directories:
2137 --prefix=PREFIX install architecture-independent files in PREFIX
2138 [$ac_default_prefix]
2139 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2140 [PREFIX]
2142 By default, \`make install' will install all the files in
2143 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2144 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2145 for instance \`--prefix=\$HOME'.
2147 For better control, use the options below.
2149 Fine tuning of the installation directories:
2150 --bindir=DIR user executables [EPREFIX/bin]
2151 --sbindir=DIR system admin executables [EPREFIX/sbin]
2152 --libexecdir=DIR program executables [EPREFIX/libexec]
2153 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2154 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2155 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2156 --libdir=DIR object code libraries [EPREFIX/lib]
2157 --includedir=DIR C header files [PREFIX/include]
2158 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2159 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2160 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2161 --infodir=DIR info documentation [DATAROOTDIR/info]
2162 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2163 --mandir=DIR man documentation [DATAROOTDIR/man]
2164 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2165 --htmldir=DIR html documentation [DOCDIR]
2166 --dvidir=DIR dvi documentation [DOCDIR]
2167 --pdfdir=DIR pdf documentation [DOCDIR]
2168 --psdir=DIR ps documentation [DOCDIR]
2169 _ACEOF
2171 cat <<\_ACEOF
2173 Program names:
2174 --program-prefix=PREFIX prepend PREFIX to installed program names
2175 --program-suffix=SUFFIX append SUFFIX to installed program names
2176 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2178 X features:
2179 --x-includes=DIR X include files are in DIR
2180 --x-libraries=DIR X library files are in DIR
2182 System types:
2183 --build=BUILD configure for building on BUILD [guessed]
2184 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2185 _ACEOF
2188 if test -n "$ac_init_help"; then
2189 case $ac_init_help in
2190 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2191 esac
2192 cat <<\_ACEOF
2194 Optional Features:
2195 --disable-option-checking ignore unrecognized --enable/--with options
2196 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2197 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2198 --disable-ns-self-contained
2199 disable self contained build under NeXTstep
2200 --enable-locallisppath=PATH
2201 directories Emacs should search for lisp files
2202 specific to this site
2203 --enable-checking[=LIST]
2204 enable expensive run-time checks. With LIST, enable
2205 only specific categories of checks. Categories are:
2206 all,yes,no. Flags are: stringbytes, stringoverrun,
2207 stringfreelist, xmallocoverrun, conslist, glyphs
2208 --enable-check-lisp-object-type
2209 enable compile time checks for the Lisp_Object data
2210 type. This is useful for development for catching
2211 certain types of bugs.
2212 --enable-profiling build emacs with low-level, gprof profiling support.
2213 Mainly useful for debugging Emacs itself. May not
2214 work on all platforms. Stops profiler.el working.
2215 --enable-autodepend automatically generate dependencies to .h-files.
2216 Requires GNU Make and Gcc. Enabled if GNU Make and
2217 Gcc is found
2218 --enable-gtk-deprecation-warnings
2219 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2220 --disable-dependency-tracking speeds up one-time build
2221 --enable-dependency-tracking do not reject slow dependency extractors
2222 --disable-largefile omit support for large files
2223 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2224 intended for developers, and may generate false
2225 alarms when used with older or non-GNU development
2226 tools.
2227 --enable-link-time-optimization
2228 build emacs with link-time optimization. This is
2229 supported only for GCC since 4.5.0.
2230 --disable-acl do not support ACLs
2232 Optional Packages:
2233 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2234 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2235 --without-all omit almost all features and build small executable
2236 with minimal dependencies
2237 --without-pop don't support POP mail retrieval with movemail
2238 --with-kerberos support Kerberos-authenticated POP
2239 --with-kerberos5 support Kerberos version 5 authenticated POP
2240 --with-hesiod support Hesiod to get the POP server host
2241 --with-mmdf support MMDF mailboxes
2242 --with-mail-unlink unlink, rather than empty, mail spool after reading
2243 --with-mailhost=HOSTNAME
2244 string giving default POP mail host
2245 --with-sound=VALUE compile with sound support (VALUE one of: yes, alsa,
2246 oss, bsd-ossaudio, no; default yes). Only for
2247 GNU/Linux, FreeBSD, NetBSD, MinGW.
2248 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2249 gtk3, lucid or athena, motif, no)
2250 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2251 --without-xpm don't compile with XPM image support
2252 --without-jpeg don't compile with JPEG image support
2253 --without-tiff don't compile with TIFF image support
2254 --without-gif don't compile with GIF image support
2255 --without-png don't compile with PNG image support
2256 --without-rsvg don't compile with SVG image support
2257 --without-xml2 don't compile with XML parsing support
2258 --without-imagemagick don't compile with ImageMagick image support
2259 --without-xft don't use XFT for anti aliased fonts
2260 --without-libotf don't use libotf for OpenType font support
2261 --without-m17n-flt don't use m17n-flt for text shaping
2262 --without-toolkit-scroll-bars
2263 don't use Motif or Xaw3d scroll bars
2264 --without-xaw3d don't use Xaw3d
2265 --without-xim don't use X11 XIM
2266 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2267 --with-w32 use native MS Windows GUI in a Cygwin build
2268 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2269 console
2270 --without-dbus don't compile with D-Bus support
2271 --without-gconf don't compile with GConf support
2272 --without-gsettings don't compile with GSettings support
2273 --without-selinux don't compile with SELinux support
2274 --without-gnutls don't use -lgnutls for SSL/TLS support
2275 --without-zlib don't compile with zlib decompression support
2276 --with-file-notification=LIB
2277 use a file notification library (LIB one of: yes,
2278 gfile, inotify, w32, no)
2279 --without-makeinfo don't require makeinfo for building manuals
2280 --without-compress-install
2281 don't compress some files (.el, .info, etc.) when
2282 installing. Equivalent to: make GZIP_PROG= install
2283 --with-pkg-config-prog=FILENAME
2284 file name of pkg-config for finding GTK and librsvg
2285 --with-gameuser=USER user for shared game score files
2286 --with-gnustep-conf=FILENAME
2287 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2288 or /etc/GNUstep/GNUstep.conf
2289 --with-x use the X Window System
2291 Some influential environment variables:
2292 CC C compiler command
2293 CFLAGS C compiler flags
2294 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2295 nonstandard directory <lib dir>
2296 LIBS libraries to pass to the linker, e.g. -l<library>
2297 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2298 you have headers in a nonstandard directory <include dir>
2299 CPP C preprocessor
2300 XMKMF Path to xmkmf, Makefile generator for X Window System
2302 Use these variables to override the choices made by `configure' or to help
2303 it to find libraries and programs with nonstandard names/locations.
2305 Report bugs to the package provider.
2306 _ACEOF
2307 ac_status=$?
2310 if test "$ac_init_help" = "recursive"; then
2311 # If there are subdirs, report their specific --help.
2312 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2313 test -d "$ac_dir" ||
2314 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2315 continue
2316 ac_builddir=.
2318 case "$ac_dir" in
2319 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2321 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2322 # A ".." for each directory in $ac_dir_suffix.
2323 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2324 case $ac_top_builddir_sub in
2325 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2326 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2327 esac ;;
2328 esac
2329 ac_abs_top_builddir=$ac_pwd
2330 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2331 # for backward compatibility:
2332 ac_top_builddir=$ac_top_build_prefix
2334 case $srcdir in
2335 .) # We are building in place.
2336 ac_srcdir=.
2337 ac_top_srcdir=$ac_top_builddir_sub
2338 ac_abs_top_srcdir=$ac_pwd ;;
2339 [\\/]* | ?:[\\/]* ) # Absolute name.
2340 ac_srcdir=$srcdir$ac_dir_suffix;
2341 ac_top_srcdir=$srcdir
2342 ac_abs_top_srcdir=$srcdir ;;
2343 *) # Relative name.
2344 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2345 ac_top_srcdir=$ac_top_build_prefix$srcdir
2346 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2347 esac
2348 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2350 cd "$ac_dir" || { ac_status=$?; continue; }
2351 # Check for guested configure.
2352 if test -f "$ac_srcdir/configure.gnu"; then
2353 echo &&
2354 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2355 elif test -f "$ac_srcdir/configure"; then
2356 echo &&
2357 $SHELL "$ac_srcdir/configure" --help=recursive
2358 else
2359 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2360 fi || ac_status=$?
2361 cd "$ac_pwd" || { ac_status=$?; break; }
2362 done
2365 test -n "$ac_init_help" && exit $ac_status
2366 if $ac_init_version; then
2367 cat <<\_ACEOF
2368 emacs configure 24.3.50
2369 generated by GNU Autoconf 2.65
2371 Copyright (C) 2009 Free Software Foundation, Inc.
2372 This configure script is free software; the Free Software Foundation
2373 gives unlimited permission to copy, distribute and modify it.
2374 _ACEOF
2375 exit
2378 ## ------------------------ ##
2379 ## Autoconf initialization. ##
2380 ## ------------------------ ##
2382 # ac_fn_c_try_compile LINENO
2383 # --------------------------
2384 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2385 ac_fn_c_try_compile ()
2387 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2388 rm -f conftest.$ac_objext
2389 if { { ac_try="$ac_compile"
2390 case "(($ac_try" in
2391 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2392 *) ac_try_echo=$ac_try;;
2393 esac
2394 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2395 $as_echo "$ac_try_echo"; } >&5
2396 (eval "$ac_compile") 2>conftest.err
2397 ac_status=$?
2398 if test -s conftest.err; then
2399 grep -v '^ *+' conftest.err >conftest.er1
2400 cat conftest.er1 >&5
2401 mv -f conftest.er1 conftest.err
2403 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2404 test $ac_status = 0; } && {
2405 test -z "$ac_c_werror_flag" ||
2406 test ! -s conftest.err
2407 } && test -s conftest.$ac_objext; then :
2408 ac_retval=0
2409 else
2410 $as_echo "$as_me: failed program was:" >&5
2411 sed 's/^/| /' conftest.$ac_ext >&5
2413 ac_retval=1
2415 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2416 as_fn_set_status $ac_retval
2418 } # ac_fn_c_try_compile
2420 # ac_fn_c_try_cpp LINENO
2421 # ----------------------
2422 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2423 ac_fn_c_try_cpp ()
2425 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2426 if { { ac_try="$ac_cpp conftest.$ac_ext"
2427 case "(($ac_try" in
2428 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2429 *) ac_try_echo=$ac_try;;
2430 esac
2431 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2432 $as_echo "$ac_try_echo"; } >&5
2433 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2434 ac_status=$?
2435 if test -s conftest.err; then
2436 grep -v '^ *+' conftest.err >conftest.er1
2437 cat conftest.er1 >&5
2438 mv -f conftest.er1 conftest.err
2440 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2441 test $ac_status = 0; } >/dev/null && {
2442 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2443 test ! -s conftest.err
2444 }; then :
2445 ac_retval=0
2446 else
2447 $as_echo "$as_me: failed program was:" >&5
2448 sed 's/^/| /' conftest.$ac_ext >&5
2450 ac_retval=1
2452 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2453 as_fn_set_status $ac_retval
2455 } # ac_fn_c_try_cpp
2457 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2458 # -------------------------------------------------------
2459 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2460 # the include files in INCLUDES and setting the cache variable VAR
2461 # accordingly.
2462 ac_fn_c_check_header_mongrel ()
2464 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2465 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2467 $as_echo_n "checking for $2... " >&6; }
2468 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2469 $as_echo_n "(cached) " >&6
2471 eval ac_res=\$$3
2472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2473 $as_echo "$ac_res" >&6; }
2474 else
2475 # Is the header compilable?
2476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2477 $as_echo_n "checking $2 usability... " >&6; }
2478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2479 /* end confdefs.h. */
2481 #include <$2>
2482 _ACEOF
2483 if ac_fn_c_try_compile "$LINENO"; then :
2484 ac_header_compiler=yes
2485 else
2486 ac_header_compiler=no
2488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2490 $as_echo "$ac_header_compiler" >&6; }
2492 # Is the header present?
2493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2494 $as_echo_n "checking $2 presence... " >&6; }
2495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2496 /* end confdefs.h. */
2497 #include <$2>
2498 _ACEOF
2499 if ac_fn_c_try_cpp "$LINENO"; then :
2500 ac_header_preproc=yes
2501 else
2502 ac_header_preproc=no
2504 rm -f conftest.err conftest.$ac_ext
2505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2506 $as_echo "$ac_header_preproc" >&6; }
2508 # So? What about this header?
2509 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2510 yes:no: )
2511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2512 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2513 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2514 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2516 no:yes:* )
2517 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2518 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2520 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2522 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2523 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2524 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2526 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2528 esac
2529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2530 $as_echo_n "checking for $2... " >&6; }
2531 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2532 $as_echo_n "(cached) " >&6
2533 else
2534 eval "$3=\$ac_header_compiler"
2536 eval ac_res=\$$3
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2538 $as_echo "$ac_res" >&6; }
2540 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2542 } # ac_fn_c_check_header_mongrel
2544 # ac_fn_c_try_run LINENO
2545 # ----------------------
2546 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2547 # that executables *can* be run.
2548 ac_fn_c_try_run ()
2550 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2551 if { { ac_try="$ac_link"
2552 case "(($ac_try" in
2553 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2554 *) ac_try_echo=$ac_try;;
2555 esac
2556 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2557 $as_echo "$ac_try_echo"; } >&5
2558 (eval "$ac_link") 2>&5
2559 ac_status=$?
2560 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2561 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2562 { { case "(($ac_try" in
2563 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2564 *) ac_try_echo=$ac_try;;
2565 esac
2566 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2567 $as_echo "$ac_try_echo"; } >&5
2568 (eval "$ac_try") 2>&5
2569 ac_status=$?
2570 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2571 test $ac_status = 0; }; }; then :
2572 ac_retval=0
2573 else
2574 $as_echo "$as_me: program exited with status $ac_status" >&5
2575 $as_echo "$as_me: failed program was:" >&5
2576 sed 's/^/| /' conftest.$ac_ext >&5
2578 ac_retval=$ac_status
2580 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2581 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2582 as_fn_set_status $ac_retval
2584 } # ac_fn_c_try_run
2586 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2587 # -------------------------------------------------------
2588 # Tests whether HEADER exists and can be compiled using the include files in
2589 # INCLUDES, setting the cache variable VAR accordingly.
2590 ac_fn_c_check_header_compile ()
2592 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2594 $as_echo_n "checking for $2... " >&6; }
2595 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2596 $as_echo_n "(cached) " >&6
2597 else
2598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2599 /* end confdefs.h. */
2601 #include <$2>
2602 _ACEOF
2603 if ac_fn_c_try_compile "$LINENO"; then :
2604 eval "$3=yes"
2605 else
2606 eval "$3=no"
2608 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2610 eval ac_res=\$$3
2611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2612 $as_echo "$ac_res" >&6; }
2613 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2615 } # ac_fn_c_check_header_compile
2617 # ac_fn_c_try_link LINENO
2618 # -----------------------
2619 # Try to link conftest.$ac_ext, and return whether this succeeded.
2620 ac_fn_c_try_link ()
2622 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2623 rm -f conftest.$ac_objext conftest$ac_exeext
2624 if { { ac_try="$ac_link"
2625 case "(($ac_try" in
2626 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2627 *) ac_try_echo=$ac_try;;
2628 esac
2629 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2630 $as_echo "$ac_try_echo"; } >&5
2631 (eval "$ac_link") 2>conftest.err
2632 ac_status=$?
2633 if test -s conftest.err; then
2634 grep -v '^ *+' conftest.err >conftest.er1
2635 cat conftest.er1 >&5
2636 mv -f conftest.er1 conftest.err
2638 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2639 test $ac_status = 0; } && {
2640 test -z "$ac_c_werror_flag" ||
2641 test ! -s conftest.err
2642 } && test -s conftest$ac_exeext && {
2643 test "$cross_compiling" = yes ||
2644 $as_test_x conftest$ac_exeext
2645 }; then :
2646 ac_retval=0
2647 else
2648 $as_echo "$as_me: failed program was:" >&5
2649 sed 's/^/| /' conftest.$ac_ext >&5
2651 ac_retval=1
2653 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2654 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2655 # interfere with the next link command; also delete a directory that is
2656 # left behind by Apple's compiler. We do this before executing the actions.
2657 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2658 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2659 as_fn_set_status $ac_retval
2661 } # ac_fn_c_try_link
2663 # ac_fn_c_check_decl LINENO SYMBOL VAR
2664 # ------------------------------------
2665 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2666 ac_fn_c_check_decl ()
2668 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2670 $as_echo_n "checking whether $2 is declared... " >&6; }
2671 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2672 $as_echo_n "(cached) " >&6
2673 else
2674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2675 /* end confdefs.h. */
2678 main ()
2680 #ifndef $2
2681 (void) $2;
2682 #endif
2685 return 0;
2687 _ACEOF
2688 if ac_fn_c_try_compile "$LINENO"; then :
2689 eval "$3=yes"
2690 else
2691 eval "$3=no"
2693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2695 eval ac_res=\$$3
2696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2697 $as_echo "$ac_res" >&6; }
2698 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2700 } # ac_fn_c_check_decl
2702 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2703 # ----------------------------------------------
2704 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2705 ac_fn_c_check_header_preproc ()
2707 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2709 $as_echo_n "checking for $2... " >&6; }
2710 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2711 $as_echo_n "(cached) " >&6
2712 else
2713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2714 /* end confdefs.h. */
2715 #include <$2>
2716 _ACEOF
2717 if ac_fn_c_try_cpp "$LINENO"; then :
2718 eval "$3=yes"
2719 else
2720 eval "$3=no"
2722 rm -f conftest.err conftest.$ac_ext
2724 eval ac_res=\$$3
2725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2726 $as_echo "$ac_res" >&6; }
2727 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2729 } # ac_fn_c_check_header_preproc
2731 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2732 # ----------------------------------------------------
2733 # Tries to find if the field MEMBER exists in type AGGR, after including
2734 # INCLUDES, setting cache variable VAR accordingly.
2735 ac_fn_c_check_member ()
2737 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2739 $as_echo_n "checking for $2.$3... " >&6; }
2740 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2741 $as_echo_n "(cached) " >&6
2742 else
2743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2744 /* end confdefs.h. */
2747 main ()
2749 static $2 ac_aggr;
2750 if (ac_aggr.$3)
2751 return 0;
2753 return 0;
2755 _ACEOF
2756 if ac_fn_c_try_compile "$LINENO"; then :
2757 eval "$4=yes"
2758 else
2759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2760 /* end confdefs.h. */
2763 main ()
2765 static $2 ac_aggr;
2766 if (sizeof ac_aggr.$3)
2767 return 0;
2769 return 0;
2771 _ACEOF
2772 if ac_fn_c_try_compile "$LINENO"; then :
2773 eval "$4=yes"
2774 else
2775 eval "$4=no"
2777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2779 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2781 eval ac_res=\$$4
2782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2783 $as_echo "$ac_res" >&6; }
2784 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2786 } # ac_fn_c_check_member
2788 # ac_fn_c_check_func LINENO FUNC VAR
2789 # ----------------------------------
2790 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2791 ac_fn_c_check_func ()
2793 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2795 $as_echo_n "checking for $2... " >&6; }
2796 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2797 $as_echo_n "(cached) " >&6
2798 else
2799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2800 /* end confdefs.h. */
2801 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2802 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2803 #define $2 innocuous_$2
2805 /* System header to define __stub macros and hopefully few prototypes,
2806 which can conflict with char $2 (); below.
2807 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2808 <limits.h> exists even on freestanding compilers. */
2810 #ifdef __STDC__
2811 # include <limits.h>
2812 #else
2813 # include <assert.h>
2814 #endif
2816 #undef $2
2818 /* Override any GCC internal prototype to avoid an error.
2819 Use char because int might match the return type of a GCC
2820 builtin and then its argument prototype would still apply. */
2821 #ifdef __cplusplus
2822 extern "C"
2823 #endif
2824 char $2 ();
2825 /* The GNU C library defines this for functions which it implements
2826 to always fail with ENOSYS. Some functions are actually named
2827 something starting with __ and the normal name is an alias. */
2828 #if defined __stub_$2 || defined __stub___$2
2829 choke me
2830 #endif
2833 main ()
2835 return $2 ();
2837 return 0;
2839 _ACEOF
2840 if ac_fn_c_try_link "$LINENO"; then :
2841 eval "$3=yes"
2842 else
2843 eval "$3=no"
2845 rm -f core conftest.err conftest.$ac_objext \
2846 conftest$ac_exeext conftest.$ac_ext
2848 eval ac_res=\$$3
2849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2850 $as_echo "$ac_res" >&6; }
2851 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2853 } # ac_fn_c_check_func
2855 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2856 # -------------------------------------------
2857 # Tests whether TYPE exists after having included INCLUDES, setting cache
2858 # variable VAR accordingly.
2859 ac_fn_c_check_type ()
2861 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2863 $as_echo_n "checking for $2... " >&6; }
2864 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2865 $as_echo_n "(cached) " >&6
2866 else
2867 eval "$3=no"
2868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2869 /* end confdefs.h. */
2872 main ()
2874 if (sizeof ($2))
2875 return 0;
2877 return 0;
2879 _ACEOF
2880 if ac_fn_c_try_compile "$LINENO"; then :
2881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2882 /* end confdefs.h. */
2885 main ()
2887 if (sizeof (($2)))
2888 return 0;
2890 return 0;
2892 _ACEOF
2893 if ac_fn_c_try_compile "$LINENO"; then :
2895 else
2896 eval "$3=yes"
2898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2902 eval ac_res=\$$3
2903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2904 $as_echo "$ac_res" >&6; }
2905 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2907 } # ac_fn_c_check_type
2909 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2910 # --------------------------------------------
2911 # Tries to find the compile-time value of EXPR in a program that includes
2912 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2913 # computed
2914 ac_fn_c_compute_int ()
2916 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2917 if test "$cross_compiling" = yes; then
2918 # Depending upon the size, compute the lo and hi bounds.
2919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2920 /* end confdefs.h. */
2923 main ()
2925 static int test_array [1 - 2 * !(($2) >= 0)];
2926 test_array [0] = 0
2929 return 0;
2931 _ACEOF
2932 if ac_fn_c_try_compile "$LINENO"; then :
2933 ac_lo=0 ac_mid=0
2934 while :; do
2935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2936 /* end confdefs.h. */
2939 main ()
2941 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2942 test_array [0] = 0
2945 return 0;
2947 _ACEOF
2948 if ac_fn_c_try_compile "$LINENO"; then :
2949 ac_hi=$ac_mid; break
2950 else
2951 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2952 if test $ac_lo -le $ac_mid; then
2953 ac_lo= ac_hi=
2954 break
2956 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2958 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2959 done
2960 else
2961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2962 /* end confdefs.h. */
2965 main ()
2967 static int test_array [1 - 2 * !(($2) < 0)];
2968 test_array [0] = 0
2971 return 0;
2973 _ACEOF
2974 if ac_fn_c_try_compile "$LINENO"; then :
2975 ac_hi=-1 ac_mid=-1
2976 while :; do
2977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2978 /* end confdefs.h. */
2981 main ()
2983 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2984 test_array [0] = 0
2987 return 0;
2989 _ACEOF
2990 if ac_fn_c_try_compile "$LINENO"; then :
2991 ac_lo=$ac_mid; break
2992 else
2993 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2994 if test $ac_mid -le $ac_hi; then
2995 ac_lo= ac_hi=
2996 break
2998 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
3000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3001 done
3002 else
3003 ac_lo= ac_hi=
3005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3008 # Binary search between lo and hi bounds.
3009 while test "x$ac_lo" != "x$ac_hi"; do
3010 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
3011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3012 /* end confdefs.h. */
3015 main ()
3017 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3018 test_array [0] = 0
3021 return 0;
3023 _ACEOF
3024 if ac_fn_c_try_compile "$LINENO"; then :
3025 ac_hi=$ac_mid
3026 else
3027 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3030 done
3031 case $ac_lo in #((
3032 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3033 '') ac_retval=1 ;;
3034 esac
3035 else
3036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3037 /* end confdefs.h. */
3039 static long int longval () { return $2; }
3040 static unsigned long int ulongval () { return $2; }
3041 #include <stdio.h>
3042 #include <stdlib.h>
3044 main ()
3047 FILE *f = fopen ("conftest.val", "w");
3048 if (! f)
3049 return 1;
3050 if (($2) < 0)
3052 long int i = longval ();
3053 if (i != ($2))
3054 return 1;
3055 fprintf (f, "%ld", i);
3057 else
3059 unsigned long int i = ulongval ();
3060 if (i != ($2))
3061 return 1;
3062 fprintf (f, "%lu", i);
3064 /* Do not output a trailing newline, as this causes \r\n confusion
3065 on some platforms. */
3066 return ferror (f) || fclose (f) != 0;
3069 return 0;
3071 _ACEOF
3072 if ac_fn_c_try_run "$LINENO"; then :
3073 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3074 else
3075 ac_retval=1
3077 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3078 conftest.$ac_objext conftest.beam conftest.$ac_ext
3079 rm -f conftest.val
3082 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3083 as_fn_set_status $ac_retval
3085 } # ac_fn_c_compute_int
3086 cat >config.log <<_ACEOF
3087 This file contains any messages produced by compilers while
3088 running configure, to aid debugging if configure makes a mistake.
3090 It was created by emacs $as_me 24.3.50, which was
3091 generated by GNU Autoconf 2.65. Invocation command line was
3093 $ $0 $@
3095 _ACEOF
3096 exec 5>>config.log
3098 cat <<_ASUNAME
3099 ## --------- ##
3100 ## Platform. ##
3101 ## --------- ##
3103 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3104 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3105 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3106 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3107 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3109 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3110 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3112 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3113 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3114 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3115 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3116 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3117 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3118 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3120 _ASUNAME
3122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3123 for as_dir in $PATH
3125 IFS=$as_save_IFS
3126 test -z "$as_dir" && as_dir=.
3127 $as_echo "PATH: $as_dir"
3128 done
3129 IFS=$as_save_IFS
3131 } >&5
3133 cat >&5 <<_ACEOF
3136 ## ----------- ##
3137 ## Core tests. ##
3138 ## ----------- ##
3140 _ACEOF
3143 # Keep a trace of the command line.
3144 # Strip out --no-create and --no-recursion so they do not pile up.
3145 # Strip out --silent because we don't want to record it for future runs.
3146 # Also quote any args containing shell meta-characters.
3147 # Make two passes to allow for proper duplicate-argument suppression.
3148 ac_configure_args=
3149 ac_configure_args0=
3150 ac_configure_args1=
3151 ac_must_keep_next=false
3152 for ac_pass in 1 2
3154 for ac_arg
3156 case $ac_arg in
3157 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3158 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3159 | -silent | --silent | --silen | --sile | --sil)
3160 continue ;;
3161 *\'*)
3162 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3163 esac
3164 case $ac_pass in
3165 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3167 as_fn_append ac_configure_args1 " '$ac_arg'"
3168 if test $ac_must_keep_next = true; then
3169 ac_must_keep_next=false # Got value, back to normal.
3170 else
3171 case $ac_arg in
3172 *=* | --config-cache | -C | -disable-* | --disable-* \
3173 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3174 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3175 | -with-* | --with-* | -without-* | --without-* | --x)
3176 case "$ac_configure_args0 " in
3177 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3178 esac
3180 -* ) ac_must_keep_next=true ;;
3181 esac
3183 as_fn_append ac_configure_args " '$ac_arg'"
3185 esac
3186 done
3187 done
3188 { ac_configure_args0=; unset ac_configure_args0;}
3189 { ac_configure_args1=; unset ac_configure_args1;}
3191 # When interrupted or exit'd, cleanup temporary files, and complete
3192 # config.log. We remove comments because anyway the quotes in there
3193 # would cause problems or look ugly.
3194 # WARNING: Use '\'' to represent an apostrophe within the trap.
3195 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3196 trap 'exit_status=$?
3197 # Save into config.log some information that might help in debugging.
3199 echo
3201 cat <<\_ASBOX
3202 ## ---------------- ##
3203 ## Cache variables. ##
3204 ## ---------------- ##
3205 _ASBOX
3206 echo
3207 # The following way of writing the cache mishandles newlines in values,
3209 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3210 eval ac_val=\$$ac_var
3211 case $ac_val in #(
3212 *${as_nl}*)
3213 case $ac_var in #(
3214 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3215 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3216 esac
3217 case $ac_var in #(
3218 _ | IFS | as_nl) ;; #(
3219 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3220 *) { eval $ac_var=; unset $ac_var;} ;;
3221 esac ;;
3222 esac
3223 done
3224 (set) 2>&1 |
3225 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3226 *${as_nl}ac_space=\ *)
3227 sed -n \
3228 "s/'\''/'\''\\\\'\'''\''/g;
3229 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3230 ;; #(
3232 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3234 esac |
3235 sort
3237 echo
3239 cat <<\_ASBOX
3240 ## ----------------- ##
3241 ## Output variables. ##
3242 ## ----------------- ##
3243 _ASBOX
3244 echo
3245 for ac_var in $ac_subst_vars
3247 eval ac_val=\$$ac_var
3248 case $ac_val in
3249 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3250 esac
3251 $as_echo "$ac_var='\''$ac_val'\''"
3252 done | sort
3253 echo
3255 if test -n "$ac_subst_files"; then
3256 cat <<\_ASBOX
3257 ## ------------------- ##
3258 ## File substitutions. ##
3259 ## ------------------- ##
3260 _ASBOX
3261 echo
3262 for ac_var in $ac_subst_files
3264 eval ac_val=\$$ac_var
3265 case $ac_val in
3266 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3267 esac
3268 $as_echo "$ac_var='\''$ac_val'\''"
3269 done | sort
3270 echo
3273 if test -s confdefs.h; then
3274 cat <<\_ASBOX
3275 ## ----------- ##
3276 ## confdefs.h. ##
3277 ## ----------- ##
3278 _ASBOX
3279 echo
3280 cat confdefs.h
3281 echo
3283 test "$ac_signal" != 0 &&
3284 $as_echo "$as_me: caught signal $ac_signal"
3285 $as_echo "$as_me: exit $exit_status"
3286 } >&5
3287 rm -f core *.core core.conftest.* &&
3288 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3289 exit $exit_status
3291 for ac_signal in 1 2 13 15; do
3292 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3293 done
3294 ac_signal=0
3296 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3297 rm -f -r conftest* confdefs.h
3299 $as_echo "/* confdefs.h */" > confdefs.h
3301 # Predefined preprocessor variables.
3303 cat >>confdefs.h <<_ACEOF
3304 #define PACKAGE_NAME "$PACKAGE_NAME"
3305 _ACEOF
3307 cat >>confdefs.h <<_ACEOF
3308 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3309 _ACEOF
3311 cat >>confdefs.h <<_ACEOF
3312 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3313 _ACEOF
3315 cat >>confdefs.h <<_ACEOF
3316 #define PACKAGE_STRING "$PACKAGE_STRING"
3317 _ACEOF
3319 cat >>confdefs.h <<_ACEOF
3320 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3321 _ACEOF
3323 cat >>confdefs.h <<_ACEOF
3324 #define PACKAGE_URL "$PACKAGE_URL"
3325 _ACEOF
3328 # Let the site file select an alternate cache file if it wants to.
3329 # Prefer an explicitly selected file to automatically selected ones.
3330 ac_site_file1=NONE
3331 ac_site_file2=NONE
3332 if test -n "$CONFIG_SITE"; then
3333 ac_site_file1=$CONFIG_SITE
3334 elif test "x$prefix" != xNONE; then
3335 ac_site_file1=$prefix/share/config.site
3336 ac_site_file2=$prefix/etc/config.site
3337 else
3338 ac_site_file1=$ac_default_prefix/share/config.site
3339 ac_site_file2=$ac_default_prefix/etc/config.site
3341 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3343 test "x$ac_site_file" = xNONE && continue
3344 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3346 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3347 sed 's/^/| /' "$ac_site_file" >&5
3348 . "$ac_site_file"
3350 done
3352 if test -r "$cache_file"; then
3353 # Some versions of bash will fail to source /dev/null (special files
3354 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3355 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3356 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3357 $as_echo "$as_me: loading cache $cache_file" >&6;}
3358 case $cache_file in
3359 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3360 *) . "./$cache_file";;
3361 esac
3363 else
3364 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3365 $as_echo "$as_me: creating cache $cache_file" >&6;}
3366 >$cache_file
3369 as_fn_append ac_header_list " sys/systeminfo.h"
3370 as_fn_append ac_header_list " coff.h"
3371 as_fn_append ac_header_list " pty.h"
3372 as_fn_append ac_header_list " sys/resource.h"
3373 as_fn_append ac_header_list " sys/utsname.h"
3374 as_fn_append ac_header_list " pwd.h"
3375 as_fn_append ac_header_list " utmp.h"
3376 as_fn_append ac_header_list " util.h"
3377 as_fn_append ac_header_list " sys/socket.h"
3378 as_fn_append ac_header_list " stdlib.h"
3379 as_fn_append ac_header_list " unistd.h"
3380 as_fn_append ac_header_list " sys/param.h"
3381 as_fn_append ac_header_list " pthread.h"
3382 as_fn_append ac_header_list " malloc/malloc.h"
3383 as_fn_append ac_header_list " maillock.h"
3384 as_fn_append ac_header_list " sys/un.h"
3385 as_fn_append ac_func_list " tzset"
3386 as_fn_append ac_func_list " readlinkat"
3387 as_fn_append ac_header_list " dirent.h"
3388 as_fn_append ac_header_list " execinfo.h"
3389 as_fn_append ac_func_list " faccessat"
3390 as_fn_append ac_func_list " fcntl"
3391 as_fn_append ac_func_list " fdopendir"
3392 as_fn_append ac_header_list " stdio_ext.h"
3393 as_fn_append ac_func_list " fstatat"
3394 as_fn_append ac_func_list " fsync"
3395 gl_getopt_required=GNU
3396 as_fn_append ac_header_list " getopt.h"
3397 as_fn_append ac_func_list " gettimeofday"
3398 as_fn_append ac_func_list " nanotime"
3399 as_fn_append ac_header_list " sys/time.h"
3400 as_fn_append ac_header_list " wchar.h"
3401 as_fn_append ac_header_list " stdint.h"
3402 as_fn_append ac_header_list " inttypes.h"
3403 as_fn_append ac_func_list " lstat"
3404 as_fn_append ac_func_list " mkostemp"
3405 as_fn_append ac_func_list " pipe2"
3406 as_fn_append ac_header_list " sys/select.h"
3407 as_fn_append ac_func_list " pselect"
3408 as_fn_append ac_func_list " pthread_sigmask"
3409 as_fn_append ac_func_list " readlink"
3410 as_fn_append ac_func_list " strtoimax"
3411 as_fn_append ac_func_list " strtoumax"
3412 as_fn_append ac_func_list " symlink"
3413 as_fn_append ac_header_list " sys/stat.h"
3414 as_fn_append ac_func_list " localtime_r"
3415 as_fn_append ac_header_list " utime.h"
3416 as_fn_append ac_func_list " futimes"
3417 as_fn_append ac_func_list " futimesat"
3418 as_fn_append ac_func_list " futimens"
3419 as_fn_append ac_func_list " utimensat"
3420 as_fn_append ac_func_list " lutimes"
3421 as_fn_append ac_func_list " getdtablesize"
3422 as_fn_append ac_func_list " secure_getenv"
3423 # Check that the precious variables saved in the cache have kept the same
3424 # value.
3425 ac_cache_corrupted=false
3426 for ac_var in $ac_precious_vars; do
3427 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3428 eval ac_new_set=\$ac_env_${ac_var}_set
3429 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3430 eval ac_new_val=\$ac_env_${ac_var}_value
3431 case $ac_old_set,$ac_new_set in
3432 set,)
3433 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3434 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3435 ac_cache_corrupted=: ;;
3436 ,set)
3437 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3438 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3439 ac_cache_corrupted=: ;;
3440 ,);;
3442 if test "x$ac_old_val" != "x$ac_new_val"; then
3443 # differences in whitespace do not lead to failure.
3444 ac_old_val_w=`echo x $ac_old_val`
3445 ac_new_val_w=`echo x $ac_new_val`
3446 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3447 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3448 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3449 ac_cache_corrupted=:
3450 else
3451 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3452 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3453 eval $ac_var=\$ac_old_val
3455 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3456 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3458 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3459 fi;;
3460 esac
3461 # Pass precious variables to config.status.
3462 if test "$ac_new_set" = set; then
3463 case $ac_new_val in
3464 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3465 *) ac_arg=$ac_var=$ac_new_val ;;
3466 esac
3467 case " $ac_configure_args " in
3468 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3469 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3470 esac
3472 done
3473 if $ac_cache_corrupted; then
3474 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3475 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3476 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3477 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3478 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3480 ## -------------------- ##
3481 ## Main body of script. ##
3482 ## -------------------- ##
3484 ac_ext=c
3485 ac_cpp='$CPP $CPPFLAGS'
3486 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3487 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3488 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3492 emacs_config_options=
3493 optsep=
3494 for opt in ${1+"$@"} CFLAGS CPPFLAGS LDFLAGS; do
3495 case $opt in
3496 -n | --no-create | --no-recursion)
3497 continue ;;
3498 CFLAGS | CPPFLAGS | LDFLAGS)
3499 eval 'test "${'$opt'+set}" = set' || continue
3500 case " $*" in
3501 *" $opt="*) continue ;;
3502 esac
3503 eval opt=$opt=\$$opt ;;
3504 esac
3506 emacs_shell_specials=$IFS\''"#$&()*;<>?[\\`{|~'
3507 case $opt in
3508 *["$emacs_shell_specials"]*)
3509 case $opt in
3510 *\'*)
3511 emacs_quote_apostrophes="s/'/'\\\\''/g"
3512 opt=`$as_echo "$opt" | sed "$emacs_quote_apostrophes"` ;;
3513 esac
3514 opt="'$opt'"
3515 case $opt in
3516 *['"\\']*)
3517 emacs_quote_for_c='s/["\\]/\\&/g; $!s/$/\\n\\/'
3518 opt=`$as_echo "$opt" | sed "$emacs_quote_for_c"` ;;
3519 esac ;;
3520 esac
3521 as_fn_append emacs_config_options "$optsep$opt"
3522 optsep=' '
3523 done
3525 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3528 ac_aux_dir=
3529 for ac_dir in build-aux "$srcdir"/build-aux; do
3530 for ac_t in install-sh install.sh shtool; do
3531 if test -f "$ac_dir/$ac_t"; then
3532 ac_aux_dir=$ac_dir
3533 ac_install_sh="$ac_aux_dir/$ac_t -c"
3534 break 2
3536 done
3537 done
3538 if test -z "$ac_aux_dir"; then
3539 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3542 # These three variables are undocumented and unsupported,
3543 # and are intended to be withdrawn in a future Autoconf release.
3544 # They can cause serious problems if a builder's source tree is in a directory
3545 # whose full name contains unusual characters.
3546 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3547 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3548 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3551 am__api_version='1.11'
3553 # Find a good install program. We prefer a C program (faster),
3554 # so one script is as good as another. But avoid the broken or
3555 # incompatible versions:
3556 # SysV /etc/install, /usr/sbin/install
3557 # SunOS /usr/etc/install
3558 # IRIX /sbin/install
3559 # AIX /bin/install
3560 # AmigaOS /C/install, which installs bootblocks on floppy discs
3561 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3562 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3563 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3564 # OS/2's system install, which has a completely different semantic
3565 # ./install, which can be erroneously created by make from ./install.sh.
3566 # Reject install programs that cannot install multiple files.
3567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3568 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3569 if test -z "$INSTALL"; then
3570 if test "${ac_cv_path_install+set}" = set; then :
3571 $as_echo_n "(cached) " >&6
3572 else
3573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3574 for as_dir in $PATH
3576 IFS=$as_save_IFS
3577 test -z "$as_dir" && as_dir=.
3578 # Account for people who put trailing slashes in PATH elements.
3579 case $as_dir/ in #((
3580 ./ | .// | /[cC]/* | \
3581 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3582 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3583 /usr/ucb/* ) ;;
3585 # OSF1 and SCO ODT 3.0 have their own names for install.
3586 # Don't use installbsd from OSF since it installs stuff as root
3587 # by default.
3588 for ac_prog in ginstall scoinst install; do
3589 for ac_exec_ext in '' $ac_executable_extensions; do
3590 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3591 if test $ac_prog = install &&
3592 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3593 # AIX install. It has an incompatible calling convention.
3595 elif test $ac_prog = install &&
3596 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3597 # program-specific install script used by HP pwplus--don't use.
3599 else
3600 rm -rf conftest.one conftest.two conftest.dir
3601 echo one > conftest.one
3602 echo two > conftest.two
3603 mkdir conftest.dir
3604 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3605 test -s conftest.one && test -s conftest.two &&
3606 test -s conftest.dir/conftest.one &&
3607 test -s conftest.dir/conftest.two
3608 then
3609 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3610 break 3
3614 done
3615 done
3617 esac
3619 done
3620 IFS=$as_save_IFS
3622 rm -rf conftest.one conftest.two conftest.dir
3625 if test "${ac_cv_path_install+set}" = set; then
3626 INSTALL=$ac_cv_path_install
3627 else
3628 # As a last resort, use the slow shell script. Don't cache a
3629 # value for INSTALL within a source directory, because that will
3630 # break other packages using the cache if that directory is
3631 # removed, or if the value is a relative name.
3632 INSTALL=$ac_install_sh
3635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3636 $as_echo "$INSTALL" >&6; }
3638 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3639 # It thinks the first close brace ends the variable substitution.
3640 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3642 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3644 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3647 $as_echo_n "checking whether build environment is sane... " >&6; }
3648 # Just in case
3649 sleep 1
3650 echo timestamp > conftest.file
3651 # Reject unsafe characters in $srcdir or the absolute working directory
3652 # name. Accept space and tab only in the latter.
3653 am_lf='
3655 case `pwd` in
3656 *[\\\"\#\$\&\'\`$am_lf]*)
3657 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3658 esac
3659 case $srcdir in
3660 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3661 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3662 esac
3664 # Do `set' in a subshell so we don't clobber the current shell's
3665 # arguments. Must try -L first in case configure is actually a
3666 # symlink; some systems play weird games with the mod time of symlinks
3667 # (eg FreeBSD returns the mod time of the symlink's containing
3668 # directory).
3669 if (
3670 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3671 if test "$*" = "X"; then
3672 # -L didn't work.
3673 set X `ls -t "$srcdir/configure" conftest.file`
3675 rm -f conftest.file
3676 if test "$*" != "X $srcdir/configure conftest.file" \
3677 && test "$*" != "X conftest.file $srcdir/configure"; then
3679 # If neither matched, then we have a broken ls. This can happen
3680 # if, for instance, CONFIG_SHELL is bash and it inherits a
3681 # broken ls alias from the environment. This has actually
3682 # happened. Such a system could not be considered "sane".
3683 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3684 alias in your environment" "$LINENO" 5
3687 test "$2" = conftest.file
3689 then
3690 # Ok.
3692 else
3693 as_fn_error "newly created file is older than distributed files!
3694 Check your system clock" "$LINENO" 5
3696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3697 $as_echo "yes" >&6; }
3698 test "$program_prefix" != NONE &&
3699 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3700 # Use a double $ so make ignores it.
3701 test "$program_suffix" != NONE &&
3702 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3703 # Double any \ or $.
3704 # By default was `s,x,x', remove it if useless.
3705 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3706 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3708 # expand $ac_aux_dir to an absolute path
3709 am_aux_dir=`cd $ac_aux_dir && pwd`
3711 if test x"${MISSING+set}" != xset; then
3712 case $am_aux_dir in
3713 *\ * | *\ *)
3714 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3716 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3717 esac
3719 # Use eval to expand $SHELL
3720 if eval "$MISSING --run true"; then
3721 am_missing_run="$MISSING --run "
3722 else
3723 am_missing_run=
3724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3725 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3728 if test x"${install_sh}" != xset; then
3729 case $am_aux_dir in
3730 *\ * | *\ *)
3731 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3733 install_sh="\${SHELL} $am_aux_dir/install-sh"
3734 esac
3737 # Installed binaries are usually stripped using `strip' when the user
3738 # run `make install-strip'. However `strip' might not be the right
3739 # tool to use in cross-compilation environments, therefore Automake
3740 # will honor the `STRIP' environment variable to overrule this program.
3741 if test "$cross_compiling" != no; then
3742 if test -n "$ac_tool_prefix"; then
3743 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3744 set dummy ${ac_tool_prefix}strip; ac_word=$2
3745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3746 $as_echo_n "checking for $ac_word... " >&6; }
3747 if test "${ac_cv_prog_STRIP+set}" = set; then :
3748 $as_echo_n "(cached) " >&6
3749 else
3750 if test -n "$STRIP"; then
3751 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3752 else
3753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3754 for as_dir in $PATH
3756 IFS=$as_save_IFS
3757 test -z "$as_dir" && as_dir=.
3758 for ac_exec_ext in '' $ac_executable_extensions; do
3759 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3760 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3762 break 2
3764 done
3765 done
3766 IFS=$as_save_IFS
3770 STRIP=$ac_cv_prog_STRIP
3771 if test -n "$STRIP"; then
3772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3773 $as_echo "$STRIP" >&6; }
3774 else
3775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3776 $as_echo "no" >&6; }
3781 if test -z "$ac_cv_prog_STRIP"; then
3782 ac_ct_STRIP=$STRIP
3783 # Extract the first word of "strip", so it can be a program name with args.
3784 set dummy strip; ac_word=$2
3785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3786 $as_echo_n "checking for $ac_word... " >&6; }
3787 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3788 $as_echo_n "(cached) " >&6
3789 else
3790 if test -n "$ac_ct_STRIP"; then
3791 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3792 else
3793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3794 for as_dir in $PATH
3796 IFS=$as_save_IFS
3797 test -z "$as_dir" && as_dir=.
3798 for ac_exec_ext in '' $ac_executable_extensions; do
3799 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3800 ac_cv_prog_ac_ct_STRIP="strip"
3801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3802 break 2
3804 done
3805 done
3806 IFS=$as_save_IFS
3810 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3811 if test -n "$ac_ct_STRIP"; then
3812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3813 $as_echo "$ac_ct_STRIP" >&6; }
3814 else
3815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3816 $as_echo "no" >&6; }
3819 if test "x$ac_ct_STRIP" = x; then
3820 STRIP=":"
3821 else
3822 case $cross_compiling:$ac_tool_warned in
3823 yes:)
3824 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3825 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3826 ac_tool_warned=yes ;;
3827 esac
3828 STRIP=$ac_ct_STRIP
3830 else
3831 STRIP="$ac_cv_prog_STRIP"
3835 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3838 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3839 if test -z "$MKDIR_P"; then
3840 if test "${ac_cv_path_mkdir+set}" = set; then :
3841 $as_echo_n "(cached) " >&6
3842 else
3843 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3844 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3846 IFS=$as_save_IFS
3847 test -z "$as_dir" && as_dir=.
3848 for ac_prog in mkdir gmkdir; do
3849 for ac_exec_ext in '' $ac_executable_extensions; do
3850 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3851 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3852 'mkdir (GNU coreutils) '* | \
3853 'mkdir (coreutils) '* | \
3854 'mkdir (fileutils) '4.1*)
3855 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3856 break 3;;
3857 esac
3858 done
3859 done
3860 done
3861 IFS=$as_save_IFS
3865 test -d ./--version && rmdir ./--version
3866 if test "${ac_cv_path_mkdir+set}" = set; then
3867 MKDIR_P="$ac_cv_path_mkdir -p"
3868 else
3869 # As a last resort, use the slow shell script. Don't cache a
3870 # value for MKDIR_P within a source directory, because that will
3871 # break other packages using the cache if that directory is
3872 # removed, or if the value is a relative name.
3873 MKDIR_P="$ac_install_sh -d"
3876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3877 $as_echo "$MKDIR_P" >&6; }
3879 mkdir_p="$MKDIR_P"
3880 case $mkdir_p in
3881 [\\/$]* | ?:[\\/]*) ;;
3882 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3883 esac
3885 for ac_prog in gawk mawk nawk awk
3887 # Extract the first word of "$ac_prog", so it can be a program name with args.
3888 set dummy $ac_prog; ac_word=$2
3889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3890 $as_echo_n "checking for $ac_word... " >&6; }
3891 if test "${ac_cv_prog_AWK+set}" = set; then :
3892 $as_echo_n "(cached) " >&6
3893 else
3894 if test -n "$AWK"; then
3895 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3896 else
3897 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3898 for as_dir in $PATH
3900 IFS=$as_save_IFS
3901 test -z "$as_dir" && as_dir=.
3902 for ac_exec_ext in '' $ac_executable_extensions; do
3903 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3904 ac_cv_prog_AWK="$ac_prog"
3905 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3906 break 2
3908 done
3909 done
3910 IFS=$as_save_IFS
3914 AWK=$ac_cv_prog_AWK
3915 if test -n "$AWK"; then
3916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3917 $as_echo "$AWK" >&6; }
3918 else
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3920 $as_echo "no" >&6; }
3924 test -n "$AWK" && break
3925 done
3927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3928 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3929 set x ${MAKE-make}
3930 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3931 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3932 $as_echo_n "(cached) " >&6
3933 else
3934 cat >conftest.make <<\_ACEOF
3935 SHELL = /bin/sh
3936 all:
3937 @echo '@@@%%%=$(MAKE)=@@@%%%'
3938 _ACEOF
3939 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3940 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3941 *@@@%%%=?*=@@@%%%*)
3942 eval ac_cv_prog_make_${ac_make}_set=yes;;
3944 eval ac_cv_prog_make_${ac_make}_set=no;;
3945 esac
3946 rm -f conftest.make
3948 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3950 $as_echo "yes" >&6; }
3951 SET_MAKE=
3952 else
3953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3954 $as_echo "no" >&6; }
3955 SET_MAKE="MAKE=${MAKE-make}"
3958 rm -rf .tst 2>/dev/null
3959 mkdir .tst 2>/dev/null
3960 if test -d .tst; then
3961 am__leading_dot=.
3962 else
3963 am__leading_dot=_
3965 rmdir .tst 2>/dev/null
3967 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3968 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3969 # is not polluted with repeated "-I."
3970 am__isrc=' -I$(srcdir)'
3971 # test to see if srcdir already configured
3972 if test -f $srcdir/config.status; then
3973 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3977 # test whether we have cygpath
3978 if test -z "$CYGPATH_W"; then
3979 if (cygpath --version) >/dev/null 2>/dev/null; then
3980 CYGPATH_W='cygpath -w'
3981 else
3982 CYGPATH_W=echo
3987 # Define the identity of the package.
3988 PACKAGE='emacs'
3989 VERSION='24.3.50'
3992 cat >>confdefs.h <<_ACEOF
3993 #define PACKAGE "$PACKAGE"
3994 _ACEOF
3997 cat >>confdefs.h <<_ACEOF
3998 #define VERSION "$VERSION"
3999 _ACEOF
4001 # Some tools Automake needs.
4003 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4006 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4009 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4012 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4015 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4017 # We need awk for the "check" target. The system "awk" is bad on
4018 # some platforms.
4019 # Always define AMTAR for backward compatibility.
4021 AMTAR=${AMTAR-"${am_missing_run}tar"}
4023 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
4032 lispdir='${datadir}/emacs/${version}/lisp'
4033 leimdir='${datadir}/emacs/${version}/leim'
4034 standardlisppath='${lispdir}:${leimdir}'
4035 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
4036 '${datadir}/emacs/site-lisp'
4037 lisppath='${locallisppath}:${standardlisppath}'
4038 etcdir='${datadir}/emacs/${version}/etc'
4039 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4040 etcdocdir='${datadir}/emacs/${version}/etc'
4041 gamedir='${localstatedir}/games/emacs'
4044 # Check whether --with-all was given.
4045 if test "${with_all+set}" = set; then :
4046 withval=$with_all; with_features=$withval
4047 else
4048 with_features=yes
4055 # Check whether --with-pop was given.
4056 if test "${with_pop+set}" = set; then :
4057 withval=$with_pop;
4058 else
4059 with_pop=$with_features
4062 if test "$with_pop" = yes; then
4063 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4068 # Check whether --with-kerberos was given.
4069 if test "${with_kerberos+set}" = set; then :
4070 withval=$with_kerberos;
4071 else
4072 with_kerberos=no
4075 if test "$with_kerberos" != no; then
4076 $as_echo "#define KERBEROS 1" >>confdefs.h
4081 # Check whether --with-kerberos5 was given.
4082 if test "${with_kerberos5+set}" = set; then :
4083 withval=$with_kerberos5;
4084 else
4085 with_kerberos5=no
4088 if test "${with_kerberos5}" != no; then
4089 if test "${with_kerberos}" = no; then
4090 with_kerberos=yes
4091 $as_echo "#define KERBEROS 1" >>confdefs.h
4095 $as_echo "#define KERBEROS5 1" >>confdefs.h
4100 # Check whether --with-hesiod was given.
4101 if test "${with_hesiod+set}" = set; then :
4102 withval=$with_hesiod;
4103 else
4104 with_hesiod=no
4107 if test "$with_hesiod" != no; then
4109 $as_echo "#define HESIOD 1" >>confdefs.h
4114 # Check whether --with-mmdf was given.
4115 if test "${with_mmdf+set}" = set; then :
4116 withval=$with_mmdf;
4117 else
4118 with_mmdf=no
4121 if test "$with_mmdf" != no; then
4123 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4128 # Check whether --with-mail-unlink was given.
4129 if test "${with_mail_unlink+set}" = set; then :
4130 withval=$with_mail_unlink;
4131 else
4132 with_mail_unlink=no
4135 if test "$with_mail_unlink" != no; then
4137 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4142 # Check whether --with-mailhost was given.
4143 if test "${with_mailhost+set}" = set; then :
4144 withval=$with_mailhost;
4145 cat >>confdefs.h <<_ACEOF
4146 #define MAILHOST "$withval"
4147 _ACEOF
4153 # Check whether --with-sound was given.
4154 if test "${with_sound+set}" = set; then :
4155 withval=$with_sound; case "${withval}" in
4156 yes|no|alsa|oss|bsd-ossaudio) val=$withval ;;
4157 *) as_fn_error "\`--with-sound=$withval' is invalid;
4158 this option's value should be \`yes', \`no', \`alsa', \`oss', or \`bsd-ossaudio'." "$LINENO" 5
4160 esac
4161 with_sound=$val
4163 else
4164 with_sound=$with_features
4169 # Check whether --with-x-toolkit was given.
4170 if test "${with_x_toolkit+set}" = set; then :
4171 withval=$with_x_toolkit; case "${withval}" in
4172 y | ye | yes ) val=gtk ;;
4173 n | no ) val=no ;;
4174 l | lu | luc | luci | lucid ) val=lucid ;;
4175 a | at | ath | athe | athen | athena ) val=athena ;;
4176 m | mo | mot | moti | motif ) val=motif ;;
4177 g | gt | gtk ) val=gtk ;;
4178 gtk2 ) val=gtk2 ;;
4179 gtk3 ) val=gtk3 ;;
4181 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4182 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4183 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4184 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4186 esac
4187 with_x_toolkit=$val
4193 # Check whether --with-wide-int was given.
4194 if test "${with_wide_int+set}" = set; then :
4195 withval=$with_wide_int;
4196 else
4197 with_wide_int=no
4200 if test "$with_wide_int" = yes; then
4202 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4207 # Check whether --with-xpm was given.
4208 if test "${with_xpm+set}" = set; then :
4209 withval=$with_xpm;
4210 else
4211 with_xpm=$with_features
4215 # Check whether --with-jpeg was given.
4216 if test "${with_jpeg+set}" = set; then :
4217 withval=$with_jpeg;
4218 else
4219 with_jpeg=$with_features
4223 # Check whether --with-tiff was given.
4224 if test "${with_tiff+set}" = set; then :
4225 withval=$with_tiff;
4226 else
4227 with_tiff=$with_features
4231 # Check whether --with-gif was given.
4232 if test "${with_gif+set}" = set; then :
4233 withval=$with_gif;
4234 else
4235 with_gif=$with_features
4239 # Check whether --with-png was given.
4240 if test "${with_png+set}" = set; then :
4241 withval=$with_png;
4242 else
4243 with_png=$with_features
4247 # Check whether --with-rsvg was given.
4248 if test "${with_rsvg+set}" = set; then :
4249 withval=$with_rsvg;
4250 else
4251 with_rsvg=$with_features
4255 # Check whether --with-xml2 was given.
4256 if test "${with_xml2+set}" = set; then :
4257 withval=$with_xml2;
4258 else
4259 with_xml2=$with_features
4263 # Check whether --with-imagemagick was given.
4264 if test "${with_imagemagick+set}" = set; then :
4265 withval=$with_imagemagick;
4266 else
4267 with_imagemagick=$with_features
4272 # Check whether --with-xft was given.
4273 if test "${with_xft+set}" = set; then :
4274 withval=$with_xft;
4275 else
4276 with_xft=$with_features
4280 # Check whether --with-libotf was given.
4281 if test "${with_libotf+set}" = set; then :
4282 withval=$with_libotf;
4283 else
4284 with_libotf=$with_features
4288 # Check whether --with-m17n-flt was given.
4289 if test "${with_m17n_flt+set}" = set; then :
4290 withval=$with_m17n_flt;
4291 else
4292 with_m17n_flt=$with_features
4297 # Check whether --with-toolkit-scroll-bars was given.
4298 if test "${with_toolkit_scroll_bars+set}" = set; then :
4299 withval=$with_toolkit_scroll_bars;
4300 else
4301 with_toolkit_scroll_bars=$with_features
4305 # Check whether --with-xaw3d was given.
4306 if test "${with_xaw3d+set}" = set; then :
4307 withval=$with_xaw3d;
4308 else
4309 with_xaw3d=$with_features
4313 # Check whether --with-xim was given.
4314 if test "${with_xim+set}" = set; then :
4315 withval=$with_xim;
4316 else
4317 with_xim=$with_features
4321 # Check whether --with-ns was given.
4322 if test "${with_ns+set}" = set; then :
4323 withval=$with_ns;
4324 else
4325 with_ns=no
4329 # Check whether --with-w32 was given.
4330 if test "${with_w32+set}" = set; then :
4331 withval=$with_w32;
4332 else
4333 with_w32=no
4338 # Check whether --with-gpm was given.
4339 if test "${with_gpm+set}" = set; then :
4340 withval=$with_gpm;
4341 else
4342 with_gpm=$with_features
4346 # Check whether --with-dbus was given.
4347 if test "${with_dbus+set}" = set; then :
4348 withval=$with_dbus;
4349 else
4350 with_dbus=$with_features
4354 # Check whether --with-gconf was given.
4355 if test "${with_gconf+set}" = set; then :
4356 withval=$with_gconf;
4357 else
4358 with_gconf=$with_features
4362 # Check whether --with-gsettings was given.
4363 if test "${with_gsettings+set}" = set; then :
4364 withval=$with_gsettings;
4365 else
4366 with_gsettings=$with_features
4370 # Check whether --with-selinux was given.
4371 if test "${with_selinux+set}" = set; then :
4372 withval=$with_selinux;
4373 else
4374 with_selinux=$with_features
4378 # Check whether --with-gnutls was given.
4379 if test "${with_gnutls+set}" = set; then :
4380 withval=$with_gnutls;
4381 else
4382 with_gnutls=$with_features
4386 # Check whether --with-zlib was given.
4387 if test "${with_zlib+set}" = set; then :
4388 withval=$with_zlib;
4389 else
4390 with_zlib=$with_features
4395 # Check whether --with-file-notification was given.
4396 if test "${with_file_notification+set}" = set; then :
4397 withval=$with_file_notification; case "${withval}" in
4398 y | ye | yes ) val=yes ;;
4399 n | no ) val=no ;;
4400 g | gf | gfi | gfil | gfile ) val=gfile ;;
4401 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4402 w | w3 | w32 ) val=w32 ;;
4403 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4404 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4405 \`yes' is a synonym for \`w32' on MS-Windows, for \`no' on Nextstep,
4406 otherwise for the first of \`gfile' or \`inotify' that is usable." "$LINENO" 5
4408 esac
4409 with_file_notification=$val
4411 else
4412 with_file_notification=$with_features
4416 ## For the times when you want to build Emacs but don't have
4417 ## a suitable makeinfo, and can live without the manuals.
4419 # Check whether --with-makeinfo was given.
4420 if test "${with_makeinfo+set}" = set; then :
4421 withval=$with_makeinfo;
4422 else
4423 with_makeinfo=$with_features
4427 ## Makefile.in needs the cache file name.
4430 ## This is an option because I do not know if all info/man support
4431 ## compressed files, nor how to test if they do so.
4433 # Check whether --with-compress-install was given.
4434 if test "${with_compress_install+set}" = set; then :
4435 withval=$with_compress_install;
4436 else
4437 with_compress_install=$with_features
4442 # Check whether --with-pkg-config-prog was given.
4443 if test "${with_pkg_config_prog+set}" = set; then :
4444 withval=$with_pkg_config_prog;
4447 if test "X${with_pkg_config_prog}" != X; then
4448 if test "${with_pkg_config_prog}" != yes; then
4449 PKG_CONFIG="${with_pkg_config_prog}"
4454 # Check whether --with-gameuser was given.
4455 if test "${with_gameuser+set}" = set; then :
4456 withval=$with_gameuser;
4459 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4460 && gameuser="${with_gameuser}"
4461 test "X$gameuser" = X && gameuser=games
4464 # Check whether --with-gnustep-conf was given.
4465 if test "${with_gnustep_conf+set}" = set; then :
4466 withval=$with_gnustep_conf;
4469 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4470 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4471 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4472 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4474 # Check whether --enable-ns-self-contained was given.
4475 if test "${enable_ns_self_contained+set}" = set; then :
4476 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4477 else
4478 EN_NS_SELF_CONTAINED=yes
4482 # Check whether --enable-locallisppath was given.
4483 if test "${enable_locallisppath+set}" = set; then :
4484 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4485 locallisppath=
4486 elif test "${enableval}" != "yes"; then
4487 locallisppath=${enableval}
4492 # Check whether --enable-checking was given.
4493 if test "${enable_checking+set}" = set; then :
4494 enableval=$enable_checking; ac_checking_flags="${enableval}"
4497 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4498 for check in $ac_checking_flags
4500 case $check in
4501 # these set all the flags to specific states
4502 yes) ac_enable_checking=1 ;;
4503 no) ac_enable_checking= ;
4504 ac_gc_check_stringbytes= ;
4505 ac_gc_check_string_overrun= ;
4506 ac_gc_check_string_free_list= ;
4507 ac_xmalloc_overrun= ;
4508 ac_gc_check_cons_list= ;
4509 ac_glyphs_debug= ;;
4510 all) ac_enable_checking=1 ;
4511 ac_gc_check_stringbytes=1 ;
4512 ac_gc_check_string_overrun=1 ;
4513 ac_gc_check_string_free_list=1 ;
4514 ac_xmalloc_overrun=1 ;
4515 ac_gc_check_cons_list=1 ;
4516 ac_glyphs_debug=1 ;;
4517 # these enable particular checks
4518 stringbytes) ac_gc_check_stringbytes=1 ;;
4519 stringoverrun) ac_gc_check_string_overrun=1 ;;
4520 stringfreelist) ac_gc_check_string_free_list=1 ;;
4521 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4522 conslist) ac_gc_check_cons_list=1 ;;
4523 glyphs) ac_glyphs_debug=1 ;;
4524 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4525 esac
4526 done
4527 IFS="$ac_save_IFS"
4529 if test x$ac_enable_checking != x ; then
4531 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4534 if test x$ac_gc_check_stringbytes != x ; then
4536 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4539 if test x$ac_gc_check_string_overrun != x ; then
4541 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4544 if test x$ac_gc_check_string_free_list != x ; then
4546 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4549 if test x$ac_xmalloc_overrun != x ; then
4551 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4554 if test x$ac_gc_check_cons_list != x ; then
4556 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4559 if test x$ac_glyphs_debug != x ; then
4561 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4565 # Check whether --enable-check-lisp-object-type was given.
4566 if test "${enable_check_lisp_object_type+set}" = set; then :
4567 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4569 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4576 # Check whether --enable-profiling was given.
4577 if test "${enable_profiling+set}" = set; then :
4578 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4581 if test x$ac_enable_profiling != x ; then
4582 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4583 else
4584 PROFILING_CFLAGS=
4588 # Check whether --enable-autodepend was given.
4589 if test "${enable_autodepend+set}" = set; then :
4590 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4591 else
4592 ac_enable_autodepend=yes
4596 # Check whether --enable-gtk-deprecation-warnings was given.
4597 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4598 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4602 #### Make srcdir absolute, if it isn't already. It's important to
4603 #### avoid running the file name through pwd unnecessarily, since pwd can
4604 #### give you automounter prefixes, which can go away. We do all this
4605 #### so Emacs can find its files when run uninstalled.
4606 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4607 unset CDPATH
4608 case "${srcdir}" in
4609 [\\/]* | ?:[\\/]*) ;;
4611 ## We may be able to use the $PWD environment variable to make this
4612 ## absolute. But sometimes PWD is inaccurate.
4613 ## Note: we used to use $PWD at the end instead of `pwd`,
4614 ## but that tested only for a well-formed and valid PWD,
4615 ## it did not object when PWD was well-formed and valid but just wrong.
4616 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4617 then
4618 srcdir="$PWD"
4619 else
4620 srcdir=`(cd "$srcdir"; pwd)`
4623 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4624 esac
4626 #### When building with MinGW inside the MSYS tree, 'pwd' produces
4627 #### directories relative to the root of the MSYS tree,
4628 #### e.g. '/home/user/foo' instead of '/d/MSYS/home/user/foo'. When
4629 #### such a value of srcdir is written to the top-level Makefile, it
4630 #### gets propagated to src/epaths.h, and that causes temacs to fail,
4631 #### because, being a MinGW program that knows nothing of MSYS root
4632 #### substitution, it cannot find the data directory. "pwd -W"
4633 #### produces Windows-style 'd:/foo/bar' absolute directory names, so
4634 #### we use it here to countermand that lossage.
4635 test "$MSYSTEM" = "MINGW32" && srcdir=`(cd "$srcdir"; pwd -W | sed -e 's,^\([A-Za-z]\):,/\1,')`
4637 ### Canonicalize the configuration name.
4639 # Make sure we can run config.sub.
4640 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4641 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4644 $as_echo_n "checking build system type... " >&6; }
4645 if test "${ac_cv_build+set}" = set; then :
4646 $as_echo_n "(cached) " >&6
4647 else
4648 ac_build_alias=$build_alias
4649 test "x$ac_build_alias" = x &&
4650 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4651 test "x$ac_build_alias" = x &&
4652 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4653 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4654 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4658 $as_echo "$ac_cv_build" >&6; }
4659 case $ac_cv_build in
4660 *-*-*) ;;
4661 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4662 esac
4663 build=$ac_cv_build
4664 ac_save_IFS=$IFS; IFS='-'
4665 set x $ac_cv_build
4666 shift
4667 build_cpu=$1
4668 build_vendor=$2
4669 shift; shift
4670 # Remember, the first character of IFS is used to create $*,
4671 # except with old shells:
4672 build_os=$*
4673 IFS=$ac_save_IFS
4674 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4678 $as_echo_n "checking host system type... " >&6; }
4679 if test "${ac_cv_host+set}" = set; then :
4680 $as_echo_n "(cached) " >&6
4681 else
4682 if test "x$host_alias" = x; then
4683 ac_cv_host=$ac_cv_build
4684 else
4685 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4686 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4691 $as_echo "$ac_cv_host" >&6; }
4692 case $ac_cv_host in
4693 *-*-*) ;;
4694 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4695 esac
4696 host=$ac_cv_host
4697 ac_save_IFS=$IFS; IFS='-'
4698 set x $ac_cv_host
4699 shift
4700 host_cpu=$1
4701 host_vendor=$2
4702 shift; shift
4703 # Remember, the first character of IFS is used to create $*,
4704 # except with old shells:
4705 host_os=$*
4706 IFS=$ac_save_IFS
4707 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4710 canonical=$host
4711 configuration=${host_alias-${build_alias-$host}}
4715 ### If you add support for a new configuration, add code to this
4716 ### switch statement to recognize your configuration name and select
4717 ### the appropriate operating system file.
4719 ### You would hope that you could choose an s/*.h
4720 ### file based on the operating system portion. However, it turns out
4721 ### that each s/*.h file is pretty manufacturer-specific.
4722 ### So we basically have to have a special case for each
4723 ### configuration name.
4725 ### As far as handling version numbers on operating systems is
4726 ### concerned, make sure things will fail in a fixable way. If
4727 ### /etc/MACHINES doesn't say anything about version numbers, be
4728 ### prepared to handle anything reasonably. If version numbers
4729 ### matter, be sure /etc/MACHINES says something about it.
4731 opsys='' unported=no
4732 case "${canonical}" in
4734 ## GNU/Linux and similar ports
4735 *-*-linux* )
4736 opsys=gnu-linux
4739 ## FreeBSD ports
4740 *-*-freebsd* )
4741 opsys=freebsd
4744 ## DragonFly ports
4745 *-*-dragonfly* )
4746 opsys=dragonfly
4749 ## FreeBSD kernel + glibc based userland
4750 *-*-kfreebsd*gnu* )
4751 opsys=gnu-kfreebsd
4754 ## NetBSD ports
4755 *-*-netbsd* )
4756 opsys=netbsd
4759 ## OpenBSD ports
4760 *-*-openbsd* )
4761 opsys=openbsd
4764 ## Apple Darwin / Mac OS X
4765 *-apple-darwin* )
4766 case "${canonical}" in
4767 i[3456]86-* ) ;;
4768 powerpc-* ) ;;
4769 x86_64-* ) ;;
4770 * ) unported=yes ;;
4771 esac
4772 opsys=darwin
4773 ## Use fink packages if available.
4774 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4775 ## if test -d /sw/include && test -d /sw/lib; then
4776 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4777 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4778 ## fi
4781 ## Cygwin ports
4782 *-*-cygwin )
4783 opsys=cygwin
4786 ## HP 9000 series 700 and 800, running HP/UX
4787 hppa*-hp-hpux10.2* )
4788 opsys=hpux10-20
4790 hppa*-hp-hpux1[1-9]* )
4791 opsys=hpux11
4792 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4795 ## IBM machines
4796 rs6000-ibm-aix4.[23]* )
4797 opsys=aix4-2
4799 powerpc-ibm-aix4.[23]* )
4800 opsys=aix4-2
4802 rs6000-ibm-aix[56]* )
4803 opsys=aix4-2
4805 powerpc-ibm-aix[56]* )
4806 opsys=aix4-2
4809 ## Silicon Graphics machines
4810 ## Iris 4D
4811 mips-sgi-irix6.5 )
4812 opsys=irix6-5
4813 # Without defining _LANGUAGE_C, things get masked out in the headers
4814 # so that, for instance, grepping for `free' in stdlib.h fails and
4815 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4816 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4819 ## Suns
4820 *-sun-solaris* \
4821 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4822 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4823 case "${canonical}" in
4824 i[3456]86-*-* ) ;;
4825 amd64-*-*|x86_64-*-*) ;;
4826 sparc* ) ;;
4827 * ) unported=yes ;;
4828 esac
4829 case "${canonical}" in
4830 *-sunos5.6* | *-solaris2.6* )
4831 opsys=sol2-6
4832 RANLIB="ar -ts"
4834 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4835 opsys=sol2-6
4836 emacs_check_sunpro_c=yes
4838 *-sunos5* | *-solaris* )
4839 opsys=sol2-10
4840 emacs_check_sunpro_c=yes
4842 esac
4843 ## Watch out for a compiler that we know will not work.
4844 case "${canonical}" in
4845 *-solaris* | *-sunos5* )
4846 if [ "x$CC" = x/usr/ucb/cc ]; then
4847 ## /usr/ucb/cc doesn't work;
4848 ## we should find some other compiler that does work.
4849 unset CC
4852 *) ;;
4853 esac
4856 ## Intel 386 machines where we don't care about the manufacturer.
4857 i[3456]86-*-* )
4858 case "${canonical}" in
4859 *-darwin* ) opsys=darwin ;;
4860 *-mingw32 )
4861 opsys=mingw32
4862 # MinGW overrides and adds some system headers in nt/inc.
4863 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4865 *-sysv4.2uw* ) opsys=unixware ;;
4866 *-sysv5uw* ) opsys=unixware ;;
4867 *-sysv5OpenUNIX* ) opsys=unixware ;;
4868 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4869 esac
4873 unported=yes
4875 esac
4877 ### If the code above didn't choose an operating system, just choose
4878 ### an operating system based on the configuration name. You really
4879 ### only want to use this when you have no idea what the right
4880 ### operating system is; if you know what operating systems a machine
4881 ### runs, it's cleaner to make it explicit in the case statement
4882 ### above.
4883 if test x"${opsys}" = x; then
4884 case "${canonical}" in
4885 *-gnu* ) opsys=gnu ;;
4887 unported=yes
4889 esac
4894 if test $unported = yes; then
4895 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4896 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4900 #### Choose a compiler.
4902 ac_ext=c
4903 ac_cpp='$CPP $CPPFLAGS'
4904 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4905 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4906 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4907 if test -n "$ac_tool_prefix"; then
4908 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4909 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4911 $as_echo_n "checking for $ac_word... " >&6; }
4912 if test "${ac_cv_prog_CC+set}" = set; then :
4913 $as_echo_n "(cached) " >&6
4914 else
4915 if test -n "$CC"; then
4916 ac_cv_prog_CC="$CC" # Let the user override the test.
4917 else
4918 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4919 for as_dir in $PATH
4921 IFS=$as_save_IFS
4922 test -z "$as_dir" && as_dir=.
4923 for ac_exec_ext in '' $ac_executable_extensions; do
4924 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4925 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4926 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4927 break 2
4929 done
4930 done
4931 IFS=$as_save_IFS
4935 CC=$ac_cv_prog_CC
4936 if test -n "$CC"; then
4937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4938 $as_echo "$CC" >&6; }
4939 else
4940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4941 $as_echo "no" >&6; }
4946 if test -z "$ac_cv_prog_CC"; then
4947 ac_ct_CC=$CC
4948 # Extract the first word of "gcc", so it can be a program name with args.
4949 set dummy gcc; ac_word=$2
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4951 $as_echo_n "checking for $ac_word... " >&6; }
4952 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4953 $as_echo_n "(cached) " >&6
4954 else
4955 if test -n "$ac_ct_CC"; then
4956 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4957 else
4958 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4959 for as_dir in $PATH
4961 IFS=$as_save_IFS
4962 test -z "$as_dir" && as_dir=.
4963 for ac_exec_ext in '' $ac_executable_extensions; do
4964 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4965 ac_cv_prog_ac_ct_CC="gcc"
4966 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4967 break 2
4969 done
4970 done
4971 IFS=$as_save_IFS
4975 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4976 if test -n "$ac_ct_CC"; then
4977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4978 $as_echo "$ac_ct_CC" >&6; }
4979 else
4980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4981 $as_echo "no" >&6; }
4984 if test "x$ac_ct_CC" = x; then
4985 CC=""
4986 else
4987 case $cross_compiling:$ac_tool_warned in
4988 yes:)
4989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4990 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4991 ac_tool_warned=yes ;;
4992 esac
4993 CC=$ac_ct_CC
4995 else
4996 CC="$ac_cv_prog_CC"
4999 if test -z "$CC"; then
5000 if test -n "$ac_tool_prefix"; then
5001 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5002 set dummy ${ac_tool_prefix}cc; ac_word=$2
5003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5004 $as_echo_n "checking for $ac_word... " >&6; }
5005 if test "${ac_cv_prog_CC+set}" = set; then :
5006 $as_echo_n "(cached) " >&6
5007 else
5008 if test -n "$CC"; then
5009 ac_cv_prog_CC="$CC" # Let the user override the test.
5010 else
5011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5012 for as_dir in $PATH
5014 IFS=$as_save_IFS
5015 test -z "$as_dir" && as_dir=.
5016 for ac_exec_ext in '' $ac_executable_extensions; do
5017 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5018 ac_cv_prog_CC="${ac_tool_prefix}cc"
5019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5020 break 2
5022 done
5023 done
5024 IFS=$as_save_IFS
5028 CC=$ac_cv_prog_CC
5029 if test -n "$CC"; then
5030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5031 $as_echo "$CC" >&6; }
5032 else
5033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5034 $as_echo "no" >&6; }
5040 if test -z "$CC"; then
5041 # Extract the first word of "cc", so it can be a program name with args.
5042 set dummy cc; ac_word=$2
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5044 $as_echo_n "checking for $ac_word... " >&6; }
5045 if test "${ac_cv_prog_CC+set}" = set; then :
5046 $as_echo_n "(cached) " >&6
5047 else
5048 if test -n "$CC"; then
5049 ac_cv_prog_CC="$CC" # Let the user override the test.
5050 else
5051 ac_prog_rejected=no
5052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5053 for as_dir in $PATH
5055 IFS=$as_save_IFS
5056 test -z "$as_dir" && as_dir=.
5057 for ac_exec_ext in '' $ac_executable_extensions; do
5058 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5059 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5060 ac_prog_rejected=yes
5061 continue
5063 ac_cv_prog_CC="cc"
5064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5065 break 2
5067 done
5068 done
5069 IFS=$as_save_IFS
5071 if test $ac_prog_rejected = yes; then
5072 # We found a bogon in the path, so make sure we never use it.
5073 set dummy $ac_cv_prog_CC
5074 shift
5075 if test $# != 0; then
5076 # We chose a different compiler from the bogus one.
5077 # However, it has the same basename, so the bogon will be chosen
5078 # first if we set CC to just the basename; use the full file name.
5079 shift
5080 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5085 CC=$ac_cv_prog_CC
5086 if test -n "$CC"; then
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5088 $as_echo "$CC" >&6; }
5089 else
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5091 $as_echo "no" >&6; }
5096 if test -z "$CC"; then
5097 if test -n "$ac_tool_prefix"; then
5098 for ac_prog in cl.exe
5100 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5101 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5103 $as_echo_n "checking for $ac_word... " >&6; }
5104 if test "${ac_cv_prog_CC+set}" = set; then :
5105 $as_echo_n "(cached) " >&6
5106 else
5107 if test -n "$CC"; then
5108 ac_cv_prog_CC="$CC" # Let the user override the test.
5109 else
5110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5111 for as_dir in $PATH
5113 IFS=$as_save_IFS
5114 test -z "$as_dir" && as_dir=.
5115 for ac_exec_ext in '' $ac_executable_extensions; do
5116 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5117 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5118 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5119 break 2
5121 done
5122 done
5123 IFS=$as_save_IFS
5127 CC=$ac_cv_prog_CC
5128 if test -n "$CC"; then
5129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5130 $as_echo "$CC" >&6; }
5131 else
5132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5133 $as_echo "no" >&6; }
5137 test -n "$CC" && break
5138 done
5140 if test -z "$CC"; then
5141 ac_ct_CC=$CC
5142 for ac_prog in cl.exe
5144 # Extract the first word of "$ac_prog", so it can be a program name with args.
5145 set dummy $ac_prog; ac_word=$2
5146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5147 $as_echo_n "checking for $ac_word... " >&6; }
5148 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5149 $as_echo_n "(cached) " >&6
5150 else
5151 if test -n "$ac_ct_CC"; then
5152 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5153 else
5154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5155 for as_dir in $PATH
5157 IFS=$as_save_IFS
5158 test -z "$as_dir" && as_dir=.
5159 for ac_exec_ext in '' $ac_executable_extensions; do
5160 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5161 ac_cv_prog_ac_ct_CC="$ac_prog"
5162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5163 break 2
5165 done
5166 done
5167 IFS=$as_save_IFS
5171 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5172 if test -n "$ac_ct_CC"; then
5173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5174 $as_echo "$ac_ct_CC" >&6; }
5175 else
5176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5177 $as_echo "no" >&6; }
5181 test -n "$ac_ct_CC" && break
5182 done
5184 if test "x$ac_ct_CC" = x; then
5185 CC=""
5186 else
5187 case $cross_compiling:$ac_tool_warned in
5188 yes:)
5189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5190 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5191 ac_tool_warned=yes ;;
5192 esac
5193 CC=$ac_ct_CC
5200 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5201 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5202 as_fn_error "no acceptable C compiler found in \$PATH
5203 See \`config.log' for more details." "$LINENO" 5; }
5205 # Provide some information about the compiler.
5206 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5207 set X $ac_compile
5208 ac_compiler=$2
5209 for ac_option in --version -v -V -qversion; do
5210 { { ac_try="$ac_compiler $ac_option >&5"
5211 case "(($ac_try" in
5212 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5213 *) ac_try_echo=$ac_try;;
5214 esac
5215 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5216 $as_echo "$ac_try_echo"; } >&5
5217 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5218 ac_status=$?
5219 if test -s conftest.err; then
5220 sed '10a\
5221 ... rest of stderr output deleted ...
5222 10q' conftest.err >conftest.er1
5223 cat conftest.er1 >&5
5225 rm -f conftest.er1 conftest.err
5226 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5227 test $ac_status = 0; }
5228 done
5230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5231 /* end confdefs.h. */
5234 main ()
5238 return 0;
5240 _ACEOF
5241 ac_clean_files_save=$ac_clean_files
5242 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5243 # Try to create an executable without -o first, disregard a.out.
5244 # It will help us diagnose broken compilers, and finding out an intuition
5245 # of exeext.
5246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5247 $as_echo_n "checking whether the C compiler works... " >&6; }
5248 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5250 # The possible output files:
5251 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5253 ac_rmfiles=
5254 for ac_file in $ac_files
5256 case $ac_file in
5257 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5258 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5259 esac
5260 done
5261 rm -f $ac_rmfiles
5263 if { { ac_try="$ac_link_default"
5264 case "(($ac_try" in
5265 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5266 *) ac_try_echo=$ac_try;;
5267 esac
5268 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5269 $as_echo "$ac_try_echo"; } >&5
5270 (eval "$ac_link_default") 2>&5
5271 ac_status=$?
5272 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5273 test $ac_status = 0; }; then :
5274 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5275 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5276 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5277 # so that the user can short-circuit this test for compilers unknown to
5278 # Autoconf.
5279 for ac_file in $ac_files ''
5281 test -f "$ac_file" || continue
5282 case $ac_file in
5283 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5285 [ab].out )
5286 # We found the default executable, but exeext='' is most
5287 # certainly right.
5288 break;;
5289 *.* )
5290 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5291 then :; else
5292 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5294 # We set ac_cv_exeext here because the later test for it is not
5295 # safe: cross compilers may not add the suffix if given an `-o'
5296 # argument, so we may need to know it at that point already.
5297 # Even if this section looks crufty: it has the advantage of
5298 # actually working.
5299 break;;
5301 break;;
5302 esac
5303 done
5304 test "$ac_cv_exeext" = no && ac_cv_exeext=
5306 else
5307 ac_file=''
5309 if test -z "$ac_file"; then :
5310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5311 $as_echo "no" >&6; }
5312 $as_echo "$as_me: failed program was:" >&5
5313 sed 's/^/| /' conftest.$ac_ext >&5
5315 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5316 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5317 { as_fn_set_status 77
5318 as_fn_error "C compiler cannot create executables
5319 See \`config.log' for more details." "$LINENO" 5; }; }
5320 else
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5322 $as_echo "yes" >&6; }
5324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5325 $as_echo_n "checking for C compiler default output file name... " >&6; }
5326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5327 $as_echo "$ac_file" >&6; }
5328 ac_exeext=$ac_cv_exeext
5330 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5331 ac_clean_files=$ac_clean_files_save
5332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5333 $as_echo_n "checking for suffix of executables... " >&6; }
5334 if { { ac_try="$ac_link"
5335 case "(($ac_try" in
5336 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5337 *) ac_try_echo=$ac_try;;
5338 esac
5339 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5340 $as_echo "$ac_try_echo"; } >&5
5341 (eval "$ac_link") 2>&5
5342 ac_status=$?
5343 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5344 test $ac_status = 0; }; then :
5345 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5346 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5347 # work properly (i.e., refer to `conftest.exe'), while it won't with
5348 # `rm'.
5349 for ac_file in conftest.exe conftest conftest.*; do
5350 test -f "$ac_file" || continue
5351 case $ac_file in
5352 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5353 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5354 break;;
5355 * ) break;;
5356 esac
5357 done
5358 else
5359 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5360 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5361 as_fn_error "cannot compute suffix of executables: cannot compile and link
5362 See \`config.log' for more details." "$LINENO" 5; }
5364 rm -f conftest conftest$ac_cv_exeext
5365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5366 $as_echo "$ac_cv_exeext" >&6; }
5368 rm -f conftest.$ac_ext
5369 EXEEXT=$ac_cv_exeext
5370 ac_exeext=$EXEEXT
5371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5372 /* end confdefs.h. */
5373 #include <stdio.h>
5375 main ()
5377 FILE *f = fopen ("conftest.out", "w");
5378 return ferror (f) || fclose (f) != 0;
5381 return 0;
5383 _ACEOF
5384 ac_clean_files="$ac_clean_files conftest.out"
5385 # Check that the compiler produces executables we can run. If not, either
5386 # the compiler is broken, or we cross compile.
5387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5388 $as_echo_n "checking whether we are cross compiling... " >&6; }
5389 if test "$cross_compiling" != yes; then
5390 { { ac_try="$ac_link"
5391 case "(($ac_try" in
5392 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5393 *) ac_try_echo=$ac_try;;
5394 esac
5395 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5396 $as_echo "$ac_try_echo"; } >&5
5397 (eval "$ac_link") 2>&5
5398 ac_status=$?
5399 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5400 test $ac_status = 0; }
5401 if { ac_try='./conftest$ac_cv_exeext'
5402 { { case "(($ac_try" in
5403 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5404 *) ac_try_echo=$ac_try;;
5405 esac
5406 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5407 $as_echo "$ac_try_echo"; } >&5
5408 (eval "$ac_try") 2>&5
5409 ac_status=$?
5410 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5411 test $ac_status = 0; }; }; then
5412 cross_compiling=no
5413 else
5414 if test "$cross_compiling" = maybe; then
5415 cross_compiling=yes
5416 else
5417 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5418 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5419 as_fn_error "cannot run C compiled programs.
5420 If you meant to cross compile, use \`--host'.
5421 See \`config.log' for more details." "$LINENO" 5; }
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5426 $as_echo "$cross_compiling" >&6; }
5428 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5429 ac_clean_files=$ac_clean_files_save
5430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5431 $as_echo_n "checking for suffix of object files... " >&6; }
5432 if test "${ac_cv_objext+set}" = set; then :
5433 $as_echo_n "(cached) " >&6
5434 else
5435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5436 /* end confdefs.h. */
5439 main ()
5443 return 0;
5445 _ACEOF
5446 rm -f conftest.o conftest.obj
5447 if { { ac_try="$ac_compile"
5448 case "(($ac_try" in
5449 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5450 *) ac_try_echo=$ac_try;;
5451 esac
5452 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5453 $as_echo "$ac_try_echo"; } >&5
5454 (eval "$ac_compile") 2>&5
5455 ac_status=$?
5456 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5457 test $ac_status = 0; }; then :
5458 for ac_file in conftest.o conftest.obj conftest.*; do
5459 test -f "$ac_file" || continue;
5460 case $ac_file in
5461 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5462 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5463 break;;
5464 esac
5465 done
5466 else
5467 $as_echo "$as_me: failed program was:" >&5
5468 sed 's/^/| /' conftest.$ac_ext >&5
5470 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5471 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5472 as_fn_error "cannot compute suffix of object files: cannot compile
5473 See \`config.log' for more details." "$LINENO" 5; }
5475 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5478 $as_echo "$ac_cv_objext" >&6; }
5479 OBJEXT=$ac_cv_objext
5480 ac_objext=$OBJEXT
5481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5482 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5483 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5484 $as_echo_n "(cached) " >&6
5485 else
5486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5487 /* end confdefs.h. */
5490 main ()
5492 #ifndef __GNUC__
5493 choke me
5494 #endif
5497 return 0;
5499 _ACEOF
5500 if ac_fn_c_try_compile "$LINENO"; then :
5501 ac_compiler_gnu=yes
5502 else
5503 ac_compiler_gnu=no
5505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5506 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5510 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5511 if test $ac_compiler_gnu = yes; then
5512 GCC=yes
5513 else
5514 GCC=
5516 ac_test_CFLAGS=${CFLAGS+set}
5517 ac_save_CFLAGS=$CFLAGS
5518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5519 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5520 if test "${ac_cv_prog_cc_g+set}" = set; then :
5521 $as_echo_n "(cached) " >&6
5522 else
5523 ac_save_c_werror_flag=$ac_c_werror_flag
5524 ac_c_werror_flag=yes
5525 ac_cv_prog_cc_g=no
5526 CFLAGS="-g"
5527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5528 /* end confdefs.h. */
5531 main ()
5535 return 0;
5537 _ACEOF
5538 if ac_fn_c_try_compile "$LINENO"; then :
5539 ac_cv_prog_cc_g=yes
5540 else
5541 CFLAGS=""
5542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5543 /* end confdefs.h. */
5546 main ()
5550 return 0;
5552 _ACEOF
5553 if ac_fn_c_try_compile "$LINENO"; then :
5555 else
5556 ac_c_werror_flag=$ac_save_c_werror_flag
5557 CFLAGS="-g"
5558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5559 /* end confdefs.h. */
5562 main ()
5566 return 0;
5568 _ACEOF
5569 if ac_fn_c_try_compile "$LINENO"; then :
5570 ac_cv_prog_cc_g=yes
5572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5576 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5577 ac_c_werror_flag=$ac_save_c_werror_flag
5579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5580 $as_echo "$ac_cv_prog_cc_g" >&6; }
5581 if test "$ac_test_CFLAGS" = set; then
5582 CFLAGS=$ac_save_CFLAGS
5583 elif test $ac_cv_prog_cc_g = yes; then
5584 if test "$GCC" = yes; then
5585 CFLAGS="-g -O2"
5586 else
5587 CFLAGS="-g"
5589 else
5590 if test "$GCC" = yes; then
5591 CFLAGS="-O2"
5592 else
5593 CFLAGS=
5596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5597 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5598 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5599 $as_echo_n "(cached) " >&6
5600 else
5601 ac_cv_prog_cc_c89=no
5602 ac_save_CC=$CC
5603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5604 /* end confdefs.h. */
5605 #include <stdarg.h>
5606 #include <stdio.h>
5607 #include <sys/types.h>
5608 #include <sys/stat.h>
5609 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5610 struct buf { int x; };
5611 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5612 static char *e (p, i)
5613 char **p;
5614 int i;
5616 return p[i];
5618 static char *f (char * (*g) (char **, int), char **p, ...)
5620 char *s;
5621 va_list v;
5622 va_start (v,p);
5623 s = g (p, va_arg (v,int));
5624 va_end (v);
5625 return s;
5628 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5629 function prototypes and stuff, but not '\xHH' hex character constants.
5630 These don't provoke an error unfortunately, instead are silently treated
5631 as 'x'. The following induces an error, until -std is added to get
5632 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5633 array size at least. It's necessary to write '\x00'==0 to get something
5634 that's true only with -std. */
5635 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5637 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5638 inside strings and character constants. */
5639 #define FOO(x) 'x'
5640 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5642 int test (int i, double x);
5643 struct s1 {int (*f) (int a);};
5644 struct s2 {int (*f) (double a);};
5645 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5646 int argc;
5647 char **argv;
5649 main ()
5651 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5653 return 0;
5655 _ACEOF
5656 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5657 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5659 CC="$ac_save_CC $ac_arg"
5660 if ac_fn_c_try_compile "$LINENO"; then :
5661 ac_cv_prog_cc_c89=$ac_arg
5663 rm -f core conftest.err conftest.$ac_objext
5664 test "x$ac_cv_prog_cc_c89" != "xno" && break
5665 done
5666 rm -f conftest.$ac_ext
5667 CC=$ac_save_CC
5670 # AC_CACHE_VAL
5671 case "x$ac_cv_prog_cc_c89" in
5673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5674 $as_echo "none needed" >&6; } ;;
5675 xno)
5676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5677 $as_echo "unsupported" >&6; } ;;
5679 CC="$CC $ac_cv_prog_cc_c89"
5680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5681 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5682 esac
5683 if test "x$ac_cv_prog_cc_c89" != xno; then :
5687 ac_ext=c
5688 ac_cpp='$CPP $CPPFLAGS'
5689 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5690 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5691 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5692 DEPDIR="${am__leading_dot}deps"
5694 ac_config_commands="$ac_config_commands depfiles"
5697 am_make=${MAKE-make}
5698 cat > confinc << 'END'
5699 am__doit:
5700 @echo this is the am__doit target
5701 .PHONY: am__doit
5703 # If we don't find an include directive, just comment out the code.
5704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5705 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5706 am__include="#"
5707 am__quote=
5708 _am_result=none
5709 # First try GNU make style include.
5710 echo "include confinc" > confmf
5711 # Ignore all kinds of additional output from `make'.
5712 case `$am_make -s -f confmf 2> /dev/null` in #(
5713 *the\ am__doit\ target*)
5714 am__include=include
5715 am__quote=
5716 _am_result=GNU
5718 esac
5719 # Now try BSD make style include.
5720 if test "$am__include" = "#"; then
5721 echo '.include "confinc"' > confmf
5722 case `$am_make -s -f confmf 2> /dev/null` in #(
5723 *the\ am__doit\ target*)
5724 am__include=.include
5725 am__quote="\""
5726 _am_result=BSD
5728 esac
5732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5733 $as_echo "$_am_result" >&6; }
5734 rm -f confinc confmf
5736 # Check whether --enable-dependency-tracking was given.
5737 if test "${enable_dependency_tracking+set}" = set; then :
5738 enableval=$enable_dependency_tracking;
5741 if test "x$enable_dependency_tracking" != xno; then
5742 am_depcomp="$ac_aux_dir/depcomp"
5743 AMDEPBACKSLASH='\'
5745 if test "x$enable_dependency_tracking" != xno; then
5746 AMDEP_TRUE=
5747 AMDEP_FALSE='#'
5748 else
5749 AMDEP_TRUE='#'
5750 AMDEP_FALSE=
5755 depcc="$CC" am_compiler_list=
5757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5758 $as_echo_n "checking dependency style of $depcc... " >&6; }
5759 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5760 $as_echo_n "(cached) " >&6
5761 else
5762 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5763 # We make a subdir and do the tests there. Otherwise we can end up
5764 # making bogus files that we don't know about and never remove. For
5765 # instance it was reported that on HP-UX the gcc test will end up
5766 # making a dummy file named `D' -- because `-MD' means `put the output
5767 # in D'.
5768 mkdir conftest.dir
5769 # Copy depcomp to subdir because otherwise we won't find it if we're
5770 # using a relative directory.
5771 cp "$am_depcomp" conftest.dir
5772 cd conftest.dir
5773 # We will build objects and dependencies in a subdirectory because
5774 # it helps to detect inapplicable dependency modes. For instance
5775 # both Tru64's cc and ICC support -MD to output dependencies as a
5776 # side effect of compilation, but ICC will put the dependencies in
5777 # the current directory while Tru64 will put them in the object
5778 # directory.
5779 mkdir sub
5781 am_cv_CC_dependencies_compiler_type=none
5782 if test "$am_compiler_list" = ""; then
5783 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5785 am__universal=false
5786 case " $depcc " in #(
5787 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5788 esac
5790 for depmode in $am_compiler_list; do
5791 # Setup a source with many dependencies, because some compilers
5792 # like to wrap large dependency lists on column 80 (with \), and
5793 # we should not choose a depcomp mode which is confused by this.
5795 # We need to recreate these files for each test, as the compiler may
5796 # overwrite some of them when testing with obscure command lines.
5797 # This happens at least with the AIX C compiler.
5798 : > sub/conftest.c
5799 for i in 1 2 3 4 5 6; do
5800 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5801 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5802 # Solaris 8's {/usr,}/bin/sh.
5803 touch sub/conftst$i.h
5804 done
5805 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5807 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5808 # mode. It turns out that the SunPro C++ compiler does not properly
5809 # handle `-M -o', and we need to detect this. Also, some Intel
5810 # versions had trouble with output in subdirs
5811 am__obj=sub/conftest.${OBJEXT-o}
5812 am__minus_obj="-o $am__obj"
5813 case $depmode in
5814 gcc)
5815 # This depmode causes a compiler race in universal mode.
5816 test "$am__universal" = false || continue
5818 nosideeffect)
5819 # after this tag, mechanisms are not by side-effect, so they'll
5820 # only be used when explicitly requested
5821 if test "x$enable_dependency_tracking" = xyes; then
5822 continue
5823 else
5824 break
5827 msvisualcpp | msvcmsys)
5828 # This compiler won't grok `-c -o', but also, the minuso test has
5829 # not run yet. These depmodes are late enough in the game, and
5830 # so weak that their functioning should not be impacted.
5831 am__obj=conftest.${OBJEXT-o}
5832 am__minus_obj=
5834 none) break ;;
5835 esac
5836 if depmode=$depmode \
5837 source=sub/conftest.c object=$am__obj \
5838 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5839 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5840 >/dev/null 2>conftest.err &&
5841 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5842 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5843 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5844 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5845 # icc doesn't choke on unknown options, it will just issue warnings
5846 # or remarks (even with -Werror). So we grep stderr for any message
5847 # that says an option was ignored or not supported.
5848 # When given -MP, icc 7.0 and 7.1 complain thusly:
5849 # icc: Command line warning: ignoring option '-M'; no argument required
5850 # The diagnosis changed in icc 8.0:
5851 # icc: Command line remark: option '-MP' not supported
5852 if (grep 'ignoring option' conftest.err ||
5853 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5854 am_cv_CC_dependencies_compiler_type=$depmode
5855 break
5858 done
5860 cd ..
5861 rm -rf conftest.dir
5862 else
5863 am_cv_CC_dependencies_compiler_type=none
5867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5868 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5869 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5872 test "x$enable_dependency_tracking" != xno \
5873 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5874 am__fastdepCC_TRUE=
5875 am__fastdepCC_FALSE='#'
5876 else
5877 am__fastdepCC_TRUE='#'
5878 am__fastdepCC_FALSE=
5882 if test "x$CC" != xcc; then
5883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5884 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5885 else
5886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5887 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5889 set dummy $CC; ac_cc=`$as_echo "$2" |
5890 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5891 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5892 $as_echo_n "(cached) " >&6
5893 else
5894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5895 /* end confdefs.h. */
5898 main ()
5902 return 0;
5904 _ACEOF
5905 # Make sure it works both with $CC and with simple cc.
5906 # We do the test twice because some compilers refuse to overwrite an
5907 # existing .o file with -o, though they will create one.
5908 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5909 rm -f conftest2.*
5910 if { { case "(($ac_try" in
5911 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5912 *) ac_try_echo=$ac_try;;
5913 esac
5914 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5915 $as_echo "$ac_try_echo"; } >&5
5916 (eval "$ac_try") 2>&5
5917 ac_status=$?
5918 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5919 test $ac_status = 0; } &&
5920 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5921 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5922 *) ac_try_echo=$ac_try;;
5923 esac
5924 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5925 $as_echo "$ac_try_echo"; } >&5
5926 (eval "$ac_try") 2>&5
5927 ac_status=$?
5928 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5929 test $ac_status = 0; };
5930 then
5931 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5932 if test "x$CC" != xcc; then
5933 # Test first that cc exists at all.
5934 if { ac_try='cc -c conftest.$ac_ext >&5'
5935 { { case "(($ac_try" in
5936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5937 *) ac_try_echo=$ac_try;;
5938 esac
5939 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5940 $as_echo "$ac_try_echo"; } >&5
5941 (eval "$ac_try") 2>&5
5942 ac_status=$?
5943 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5944 test $ac_status = 0; }; }; then
5945 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5946 rm -f conftest2.*
5947 if { { case "(($ac_try" in
5948 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5949 *) ac_try_echo=$ac_try;;
5950 esac
5951 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5952 $as_echo "$ac_try_echo"; } >&5
5953 (eval "$ac_try") 2>&5
5954 ac_status=$?
5955 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5956 test $ac_status = 0; } &&
5957 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5958 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5959 *) ac_try_echo=$ac_try;;
5960 esac
5961 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5962 $as_echo "$ac_try_echo"; } >&5
5963 (eval "$ac_try") 2>&5
5964 ac_status=$?
5965 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5966 test $ac_status = 0; };
5967 then
5968 # cc works too.
5970 else
5971 # cc exists but doesn't like -o.
5972 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5976 else
5977 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5979 rm -f core conftest*
5982 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5984 $as_echo "yes" >&6; }
5985 else
5986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5987 $as_echo "no" >&6; }
5989 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5993 # FIXME: we rely on the cache variable name because
5994 # there is no other way.
5995 set dummy $CC
5996 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5997 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5998 if test "$am_t" != yes; then
5999 # Losing compiler, so override with the script.
6000 # FIXME: It is wrong to rewrite CC.
6001 # But if we don't then we get into trouble of one sort or another.
6002 # A longer-term fix would be to have automake use am__CC in this case,
6003 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
6004 CC="$am_aux_dir/compile $CC"
6009 if test x$GCC = xyes; then
6010 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
6011 else
6012 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
6015 if test "x$opsys" = "xmingw32"; then
6016 BUILDING_FOR_WINDOWSNT_TRUE=
6017 BUILDING_FOR_WINDOWSNT_FALSE='#'
6018 else
6019 BUILDING_FOR_WINDOWSNT_TRUE='#'
6020 BUILDING_FOR_WINDOWSNT_FALSE=
6024 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
6025 # as we don't use them.
6027 # Avoid gnulib's threadlib module, as we do threads our own way.
6030 # Initialize gnulib right after choosing the compiler.
6032 ac_ext=c
6033 ac_cpp='$CPP $CPPFLAGS'
6034 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6035 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6036 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6038 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6039 # On Suns, sometimes $CPP names a directory.
6040 if test -n "$CPP" && test -d "$CPP"; then
6041 CPP=
6043 if test -z "$CPP"; then
6044 if test "${ac_cv_prog_CPP+set}" = set; then :
6045 $as_echo_n "(cached) " >&6
6046 else
6047 # Double quotes because CPP needs to be expanded
6048 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6050 ac_preproc_ok=false
6051 for ac_c_preproc_warn_flag in '' yes
6053 # Use a header file that comes with gcc, so configuring glibc
6054 # with a fresh cross-compiler works.
6055 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6056 # <limits.h> exists even on freestanding compilers.
6057 # On the NeXT, cc -E runs the code through the compiler's parser,
6058 # not just through cpp. "Syntax error" is here to catch this case.
6059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h. */
6061 #ifdef __STDC__
6062 # include <limits.h>
6063 #else
6064 # include <assert.h>
6065 #endif
6066 Syntax error
6067 _ACEOF
6068 if ac_fn_c_try_cpp "$LINENO"; then :
6070 else
6071 # Broken: fails on valid input.
6072 continue
6074 rm -f conftest.err conftest.$ac_ext
6076 # OK, works on sane cases. Now check whether nonexistent headers
6077 # can be detected and how.
6078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6079 /* end confdefs.h. */
6080 #include <ac_nonexistent.h>
6081 _ACEOF
6082 if ac_fn_c_try_cpp "$LINENO"; then :
6083 # Broken: success on invalid input.
6084 continue
6085 else
6086 # Passes both tests.
6087 ac_preproc_ok=:
6088 break
6090 rm -f conftest.err conftest.$ac_ext
6092 done
6093 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6094 rm -f conftest.err conftest.$ac_ext
6095 if $ac_preproc_ok; then :
6096 break
6099 done
6100 ac_cv_prog_CPP=$CPP
6103 CPP=$ac_cv_prog_CPP
6104 else
6105 ac_cv_prog_CPP=$CPP
6107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6108 $as_echo "$CPP" >&6; }
6109 ac_preproc_ok=false
6110 for ac_c_preproc_warn_flag in '' yes
6112 # Use a header file that comes with gcc, so configuring glibc
6113 # with a fresh cross-compiler works.
6114 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6115 # <limits.h> exists even on freestanding compilers.
6116 # On the NeXT, cc -E runs the code through the compiler's parser,
6117 # not just through cpp. "Syntax error" is here to catch this case.
6118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6119 /* end confdefs.h. */
6120 #ifdef __STDC__
6121 # include <limits.h>
6122 #else
6123 # include <assert.h>
6124 #endif
6125 Syntax error
6126 _ACEOF
6127 if ac_fn_c_try_cpp "$LINENO"; then :
6129 else
6130 # Broken: fails on valid input.
6131 continue
6133 rm -f conftest.err conftest.$ac_ext
6135 # OK, works on sane cases. Now check whether nonexistent headers
6136 # can be detected and how.
6137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6138 /* end confdefs.h. */
6139 #include <ac_nonexistent.h>
6140 _ACEOF
6141 if ac_fn_c_try_cpp "$LINENO"; then :
6142 # Broken: success on invalid input.
6143 continue
6144 else
6145 # Passes both tests.
6146 ac_preproc_ok=:
6147 break
6149 rm -f conftest.err conftest.$ac_ext
6151 done
6152 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6153 rm -f conftest.err conftest.$ac_ext
6154 if $ac_preproc_ok; then :
6156 else
6157 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6158 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6159 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6160 See \`config.log' for more details." "$LINENO" 5; }
6163 ac_ext=c
6164 ac_cpp='$CPP $CPPFLAGS'
6165 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6166 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6167 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6171 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6172 if test "${ac_cv_path_GREP+set}" = set; then :
6173 $as_echo_n "(cached) " >&6
6174 else
6175 if test -z "$GREP"; then
6176 ac_path_GREP_found=false
6177 # Loop through the user's path and test for each of PROGNAME-LIST
6178 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6179 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6181 IFS=$as_save_IFS
6182 test -z "$as_dir" && as_dir=.
6183 for ac_prog in grep ggrep; do
6184 for ac_exec_ext in '' $ac_executable_extensions; do
6185 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6186 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6187 # Check for GNU ac_path_GREP and select it if it is found.
6188 # Check for GNU $ac_path_GREP
6189 case `"$ac_path_GREP" --version 2>&1` in
6190 *GNU*)
6191 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6193 ac_count=0
6194 $as_echo_n 0123456789 >"conftest.in"
6195 while :
6197 cat "conftest.in" "conftest.in" >"conftest.tmp"
6198 mv "conftest.tmp" "conftest.in"
6199 cp "conftest.in" "conftest.nl"
6200 $as_echo 'GREP' >> "conftest.nl"
6201 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6202 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6203 as_fn_arith $ac_count + 1 && ac_count=$as_val
6204 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6205 # Best one so far, save it but keep looking for a better one
6206 ac_cv_path_GREP="$ac_path_GREP"
6207 ac_path_GREP_max=$ac_count
6209 # 10*(2^10) chars as input seems more than enough
6210 test $ac_count -gt 10 && break
6211 done
6212 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6213 esac
6215 $ac_path_GREP_found && break 3
6216 done
6217 done
6218 done
6219 IFS=$as_save_IFS
6220 if test -z "$ac_cv_path_GREP"; then
6221 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6223 else
6224 ac_cv_path_GREP=$GREP
6228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6229 $as_echo "$ac_cv_path_GREP" >&6; }
6230 GREP="$ac_cv_path_GREP"
6233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6234 $as_echo_n "checking for egrep... " >&6; }
6235 if test "${ac_cv_path_EGREP+set}" = set; then :
6236 $as_echo_n "(cached) " >&6
6237 else
6238 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6239 then ac_cv_path_EGREP="$GREP -E"
6240 else
6241 if test -z "$EGREP"; then
6242 ac_path_EGREP_found=false
6243 # Loop through the user's path and test for each of PROGNAME-LIST
6244 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6245 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6247 IFS=$as_save_IFS
6248 test -z "$as_dir" && as_dir=.
6249 for ac_prog in egrep; do
6250 for ac_exec_ext in '' $ac_executable_extensions; do
6251 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6252 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6253 # Check for GNU ac_path_EGREP and select it if it is found.
6254 # Check for GNU $ac_path_EGREP
6255 case `"$ac_path_EGREP" --version 2>&1` in
6256 *GNU*)
6257 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6259 ac_count=0
6260 $as_echo_n 0123456789 >"conftest.in"
6261 while :
6263 cat "conftest.in" "conftest.in" >"conftest.tmp"
6264 mv "conftest.tmp" "conftest.in"
6265 cp "conftest.in" "conftest.nl"
6266 $as_echo 'EGREP' >> "conftest.nl"
6267 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6268 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6269 as_fn_arith $ac_count + 1 && ac_count=$as_val
6270 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6271 # Best one so far, save it but keep looking for a better one
6272 ac_cv_path_EGREP="$ac_path_EGREP"
6273 ac_path_EGREP_max=$ac_count
6275 # 10*(2^10) chars as input seems more than enough
6276 test $ac_count -gt 10 && break
6277 done
6278 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6279 esac
6281 $ac_path_EGREP_found && break 3
6282 done
6283 done
6284 done
6285 IFS=$as_save_IFS
6286 if test -z "$ac_cv_path_EGREP"; then
6287 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6289 else
6290 ac_cv_path_EGREP=$EGREP
6295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6296 $as_echo "$ac_cv_path_EGREP" >&6; }
6297 EGREP="$ac_cv_path_EGREP"
6302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6303 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6304 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6305 $as_echo_n "(cached) " >&6
6306 else
6308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6309 /* end confdefs.h. */
6311 #ifdef __ACK__
6312 Amsterdam
6313 #endif
6315 _ACEOF
6316 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6317 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6318 gl_cv_c_amsterdam_compiler=yes
6319 else
6320 gl_cv_c_amsterdam_compiler=no
6322 rm -f conftest*
6326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6327 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6328 if test -z "$AR"; then
6329 if test $gl_cv_c_amsterdam_compiler = yes; then
6330 AR='cc -c.a'
6331 if test -z "$ARFLAGS"; then
6332 ARFLAGS='-o'
6334 else
6335 if test -n "$ac_tool_prefix"; then
6336 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6337 set dummy ${ac_tool_prefix}ar; ac_word=$2
6338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6339 $as_echo_n "checking for $ac_word... " >&6; }
6340 if test "${ac_cv_prog_AR+set}" = set; then :
6341 $as_echo_n "(cached) " >&6
6342 else
6343 if test -n "$AR"; then
6344 ac_cv_prog_AR="$AR" # Let the user override the test.
6345 else
6346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6347 for as_dir in $PATH
6349 IFS=$as_save_IFS
6350 test -z "$as_dir" && as_dir=.
6351 for ac_exec_ext in '' $ac_executable_extensions; do
6352 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6353 ac_cv_prog_AR="${ac_tool_prefix}ar"
6354 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6355 break 2
6357 done
6358 done
6359 IFS=$as_save_IFS
6363 AR=$ac_cv_prog_AR
6364 if test -n "$AR"; then
6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6366 $as_echo "$AR" >&6; }
6367 else
6368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6369 $as_echo "no" >&6; }
6374 if test -z "$ac_cv_prog_AR"; then
6375 ac_ct_AR=$AR
6376 # Extract the first word of "ar", so it can be a program name with args.
6377 set dummy ar; ac_word=$2
6378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6379 $as_echo_n "checking for $ac_word... " >&6; }
6380 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6381 $as_echo_n "(cached) " >&6
6382 else
6383 if test -n "$ac_ct_AR"; then
6384 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6385 else
6386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6387 for as_dir in $PATH
6389 IFS=$as_save_IFS
6390 test -z "$as_dir" && as_dir=.
6391 for ac_exec_ext in '' $ac_executable_extensions; do
6392 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6393 ac_cv_prog_ac_ct_AR="ar"
6394 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6395 break 2
6397 done
6398 done
6399 IFS=$as_save_IFS
6403 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6404 if test -n "$ac_ct_AR"; then
6405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6406 $as_echo "$ac_ct_AR" >&6; }
6407 else
6408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6409 $as_echo "no" >&6; }
6412 if test "x$ac_ct_AR" = x; then
6413 AR="ar"
6414 else
6415 case $cross_compiling:$ac_tool_warned in
6416 yes:)
6417 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6418 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6419 ac_tool_warned=yes ;;
6420 esac
6421 AR=$ac_ct_AR
6423 else
6424 AR="$ac_cv_prog_AR"
6427 if test -z "$ARFLAGS"; then
6428 ARFLAGS='cru'
6431 else
6432 if test -z "$ARFLAGS"; then
6433 ARFLAGS='cru'
6438 if test -z "$RANLIB"; then
6439 if test $gl_cv_c_amsterdam_compiler = yes; then
6440 RANLIB=':'
6441 else
6442 if test -n "$ac_tool_prefix"; then
6443 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6444 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6446 $as_echo_n "checking for $ac_word... " >&6; }
6447 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6448 $as_echo_n "(cached) " >&6
6449 else
6450 if test -n "$RANLIB"; then
6451 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6452 else
6453 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6454 for as_dir in $PATH
6456 IFS=$as_save_IFS
6457 test -z "$as_dir" && as_dir=.
6458 for ac_exec_ext in '' $ac_executable_extensions; do
6459 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6460 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6461 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6462 break 2
6464 done
6465 done
6466 IFS=$as_save_IFS
6470 RANLIB=$ac_cv_prog_RANLIB
6471 if test -n "$RANLIB"; then
6472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6473 $as_echo "$RANLIB" >&6; }
6474 else
6475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6476 $as_echo "no" >&6; }
6481 if test -z "$ac_cv_prog_RANLIB"; then
6482 ac_ct_RANLIB=$RANLIB
6483 # Extract the first word of "ranlib", so it can be a program name with args.
6484 set dummy ranlib; ac_word=$2
6485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6486 $as_echo_n "checking for $ac_word... " >&6; }
6487 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6488 $as_echo_n "(cached) " >&6
6489 else
6490 if test -n "$ac_ct_RANLIB"; then
6491 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6492 else
6493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6494 for as_dir in $PATH
6496 IFS=$as_save_IFS
6497 test -z "$as_dir" && as_dir=.
6498 for ac_exec_ext in '' $ac_executable_extensions; do
6499 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6500 ac_cv_prog_ac_ct_RANLIB="ranlib"
6501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6502 break 2
6504 done
6505 done
6506 IFS=$as_save_IFS
6510 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6511 if test -n "$ac_ct_RANLIB"; then
6512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6513 $as_echo "$ac_ct_RANLIB" >&6; }
6514 else
6515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6516 $as_echo "no" >&6; }
6519 if test "x$ac_ct_RANLIB" = x; then
6520 RANLIB=":"
6521 else
6522 case $cross_compiling:$ac_tool_warned in
6523 yes:)
6524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6525 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6526 ac_tool_warned=yes ;;
6527 esac
6528 RANLIB=$ac_ct_RANLIB
6530 else
6531 RANLIB="$ac_cv_prog_RANLIB"
6538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6539 $as_echo_n "checking for ANSI C header files... " >&6; }
6540 if test "${ac_cv_header_stdc+set}" = set; then :
6541 $as_echo_n "(cached) " >&6
6542 else
6543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6544 /* end confdefs.h. */
6545 #include <stdlib.h>
6546 #include <stdarg.h>
6547 #include <string.h>
6548 #include <float.h>
6551 main ()
6555 return 0;
6557 _ACEOF
6558 if ac_fn_c_try_compile "$LINENO"; then :
6559 ac_cv_header_stdc=yes
6560 else
6561 ac_cv_header_stdc=no
6563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6565 if test $ac_cv_header_stdc = yes; then
6566 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6568 /* end confdefs.h. */
6569 #include <string.h>
6571 _ACEOF
6572 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6573 $EGREP "memchr" >/dev/null 2>&1; then :
6575 else
6576 ac_cv_header_stdc=no
6578 rm -f conftest*
6582 if test $ac_cv_header_stdc = yes; then
6583 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6585 /* end confdefs.h. */
6586 #include <stdlib.h>
6588 _ACEOF
6589 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6590 $EGREP "free" >/dev/null 2>&1; then :
6592 else
6593 ac_cv_header_stdc=no
6595 rm -f conftest*
6599 if test $ac_cv_header_stdc = yes; then
6600 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6601 if test "$cross_compiling" = yes; then :
6603 else
6604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6605 /* end confdefs.h. */
6606 #include <ctype.h>
6607 #include <stdlib.h>
6608 #if ((' ' & 0x0FF) == 0x020)
6609 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6610 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6611 #else
6612 # define ISLOWER(c) \
6613 (('a' <= (c) && (c) <= 'i') \
6614 || ('j' <= (c) && (c) <= 'r') \
6615 || ('s' <= (c) && (c) <= 'z'))
6616 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6617 #endif
6619 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6621 main ()
6623 int i;
6624 for (i = 0; i < 256; i++)
6625 if (XOR (islower (i), ISLOWER (i))
6626 || toupper (i) != TOUPPER (i))
6627 return 2;
6628 return 0;
6630 _ACEOF
6631 if ac_fn_c_try_run "$LINENO"; then :
6633 else
6634 ac_cv_header_stdc=no
6636 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6637 conftest.$ac_objext conftest.beam conftest.$ac_ext
6642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6643 $as_echo "$ac_cv_header_stdc" >&6; }
6644 if test $ac_cv_header_stdc = yes; then
6646 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6650 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6651 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6652 inttypes.h stdint.h unistd.h
6653 do :
6654 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6655 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6657 eval as_val=\$$as_ac_Header
6658 if test "x$as_val" = x""yes; then :
6659 cat >>confdefs.h <<_ACEOF
6660 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6661 _ACEOF
6665 done
6669 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6670 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6671 MINIX=yes
6672 else
6673 MINIX=
6677 if test "$MINIX" = yes; then
6679 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6682 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6685 $as_echo "#define _MINIX 1" >>confdefs.h
6688 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6694 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6695 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6696 $as_echo_n "(cached) " >&6
6697 else
6698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6699 /* end confdefs.h. */
6701 # define __EXTENSIONS__ 1
6702 $ac_includes_default
6704 main ()
6708 return 0;
6710 _ACEOF
6711 if ac_fn_c_try_compile "$LINENO"; then :
6712 ac_cv_safe_to_define___extensions__=yes
6713 else
6714 ac_cv_safe_to_define___extensions__=no
6716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6719 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6720 test $ac_cv_safe_to_define___extensions__ = yes &&
6721 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6723 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6725 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6727 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6729 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6731 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6734 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6735 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6736 $as_echo_n "(cached) " >&6
6737 else
6738 ac_cv_should_define__xopen_source=no
6739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6740 /* end confdefs.h. */
6742 #include <wchar.h>
6743 mbstate_t x;
6745 main ()
6749 return 0;
6751 _ACEOF
6752 if ac_fn_c_try_compile "$LINENO"; then :
6754 else
6755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6756 /* end confdefs.h. */
6758 #define _XOPEN_SOURCE 500
6759 #include <wchar.h>
6760 mbstate_t x;
6762 main ()
6766 return 0;
6768 _ACEOF
6769 if ac_fn_c_try_compile "$LINENO"; then :
6770 ac_cv_should_define__xopen_source=yes
6772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6777 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6778 test $ac_cv_should_define__xopen_source = yes &&
6779 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6788 # Check whether --enable-largefile was given.
6789 if test "${enable_largefile+set}" = set; then :
6790 enableval=$enable_largefile;
6793 if test "$enable_largefile" != no; then
6795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6796 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6797 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6798 $as_echo_n "(cached) " >&6
6799 else
6800 ac_cv_sys_largefile_CC=no
6801 if test "$GCC" != yes; then
6802 ac_save_CC=$CC
6803 while :; do
6804 # IRIX 6.2 and later do not support large files by default,
6805 # so use the C compiler's -n32 option if that helps.
6806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6807 /* end confdefs.h. */
6808 #include <sys/types.h>
6809 /* Check that off_t can represent 2**63 - 1 correctly.
6810 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6811 since some C++ compilers masquerading as C compilers
6812 incorrectly reject 9223372036854775807. */
6813 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6814 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6815 && LARGE_OFF_T % 2147483647 == 1)
6816 ? 1 : -1];
6818 main ()
6822 return 0;
6824 _ACEOF
6825 if ac_fn_c_try_compile "$LINENO"; then :
6826 break
6828 rm -f core conftest.err conftest.$ac_objext
6829 CC="$CC -n32"
6830 if ac_fn_c_try_compile "$LINENO"; then :
6831 ac_cv_sys_largefile_CC=' -n32'; break
6833 rm -f core conftest.err conftest.$ac_objext
6834 break
6835 done
6836 CC=$ac_save_CC
6837 rm -f conftest.$ac_ext
6840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6841 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6842 if test "$ac_cv_sys_largefile_CC" != no; then
6843 CC=$CC$ac_cv_sys_largefile_CC
6846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6847 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6848 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6849 $as_echo_n "(cached) " >&6
6850 else
6851 while :; do
6852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6853 /* end confdefs.h. */
6854 #include <sys/types.h>
6855 /* Check that off_t can represent 2**63 - 1 correctly.
6856 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6857 since some C++ compilers masquerading as C compilers
6858 incorrectly reject 9223372036854775807. */
6859 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6860 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6861 && LARGE_OFF_T % 2147483647 == 1)
6862 ? 1 : -1];
6864 main ()
6868 return 0;
6870 _ACEOF
6871 if ac_fn_c_try_compile "$LINENO"; then :
6872 ac_cv_sys_file_offset_bits=no; break
6874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6876 /* end confdefs.h. */
6877 #define _FILE_OFFSET_BITS 64
6878 #include <sys/types.h>
6879 /* Check that off_t can represent 2**63 - 1 correctly.
6880 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6881 since some C++ compilers masquerading as C compilers
6882 incorrectly reject 9223372036854775807. */
6883 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6884 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6885 && LARGE_OFF_T % 2147483647 == 1)
6886 ? 1 : -1];
6888 main ()
6892 return 0;
6894 _ACEOF
6895 if ac_fn_c_try_compile "$LINENO"; then :
6896 ac_cv_sys_file_offset_bits=64; break
6898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6899 ac_cv_sys_file_offset_bits=unknown
6900 break
6901 done
6903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6904 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6905 case $ac_cv_sys_file_offset_bits in #(
6906 no | unknown) ;;
6908 cat >>confdefs.h <<_ACEOF
6909 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6910 _ACEOF
6912 esac
6913 rm -rf conftest*
6914 if test $ac_cv_sys_file_offset_bits = unknown; then
6915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6916 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6917 if test "${ac_cv_sys_large_files+set}" = set; then :
6918 $as_echo_n "(cached) " >&6
6919 else
6920 while :; do
6921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6922 /* end confdefs.h. */
6923 #include <sys/types.h>
6924 /* Check that off_t can represent 2**63 - 1 correctly.
6925 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6926 since some C++ compilers masquerading as C compilers
6927 incorrectly reject 9223372036854775807. */
6928 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6929 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6930 && LARGE_OFF_T % 2147483647 == 1)
6931 ? 1 : -1];
6933 main ()
6937 return 0;
6939 _ACEOF
6940 if ac_fn_c_try_compile "$LINENO"; then :
6941 ac_cv_sys_large_files=no; break
6943 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6945 /* end confdefs.h. */
6946 #define _LARGE_FILES 1
6947 #include <sys/types.h>
6948 /* Check that off_t can represent 2**63 - 1 correctly.
6949 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6950 since some C++ compilers masquerading as C compilers
6951 incorrectly reject 9223372036854775807. */
6952 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6953 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6954 && LARGE_OFF_T % 2147483647 == 1)
6955 ? 1 : -1];
6957 main ()
6961 return 0;
6963 _ACEOF
6964 if ac_fn_c_try_compile "$LINENO"; then :
6965 ac_cv_sys_large_files=1; break
6967 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6968 ac_cv_sys_large_files=unknown
6969 break
6970 done
6972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6973 $as_echo "$ac_cv_sys_large_files" >&6; }
6974 case $ac_cv_sys_large_files in #(
6975 no | unknown) ;;
6977 cat >>confdefs.h <<_ACEOF
6978 #define _LARGE_FILES $ac_cv_sys_large_files
6979 _ACEOF
6981 esac
6982 rm -rf conftest*
6986 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6990 case $ac_cv_prog_cc_stdc in #(
6991 no) :
6992 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6993 *) :
6994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6995 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6996 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6997 $as_echo_n "(cached) " >&6
6998 else
6999 ac_cv_prog_cc_c99=no
7000 ac_save_CC=$CC
7001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7002 /* end confdefs.h. */
7003 #include <stdarg.h>
7004 #include <stdbool.h>
7005 #include <stdlib.h>
7006 #include <wchar.h>
7007 #include <stdio.h>
7009 // Check varargs macros. These examples are taken from C99 6.10.3.5.
7010 #define debug(...) fprintf (stderr, __VA_ARGS__)
7011 #define showlist(...) puts (#__VA_ARGS__)
7012 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
7013 static void
7014 test_varargs_macros (void)
7016 int x = 1234;
7017 int y = 5678;
7018 debug ("Flag");
7019 debug ("X = %d\n", x);
7020 showlist (The first, second, and third items.);
7021 report (x>y, "x is %d but y is %d", x, y);
7024 // Check long long types.
7025 #define BIG64 18446744073709551615ull
7026 #define BIG32 4294967295ul
7027 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
7028 #if !BIG_OK
7029 your preprocessor is broken;
7030 #endif
7031 #if BIG_OK
7032 #else
7033 your preprocessor is broken;
7034 #endif
7035 static long long int bignum = -9223372036854775807LL;
7036 static unsigned long long int ubignum = BIG64;
7038 struct incomplete_array
7040 int datasize;
7041 double data[];
7044 struct named_init {
7045 int number;
7046 const wchar_t *name;
7047 double average;
7050 typedef const char *ccp;
7052 static inline int
7053 test_restrict (ccp restrict text)
7055 // See if C++-style comments work.
7056 // Iterate through items via the restricted pointer.
7057 // Also check for declarations in for loops.
7058 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7059 continue;
7060 return 0;
7063 // Check varargs and va_copy.
7064 static void
7065 test_varargs (const char *format, ...)
7067 va_list args;
7068 va_start (args, format);
7069 va_list args_copy;
7070 va_copy (args_copy, args);
7072 const char *str;
7073 int number;
7074 float fnumber;
7076 while (*format)
7078 switch (*format++)
7080 case 's': // string
7081 str = va_arg (args_copy, const char *);
7082 break;
7083 case 'd': // int
7084 number = va_arg (args_copy, int);
7085 break;
7086 case 'f': // float
7087 fnumber = va_arg (args_copy, double);
7088 break;
7089 default:
7090 break;
7093 va_end (args_copy);
7094 va_end (args);
7098 main ()
7101 // Check bool.
7102 _Bool success = false;
7104 // Check restrict.
7105 if (test_restrict ("String literal") == 0)
7106 success = true;
7107 char *restrict newvar = "Another string";
7109 // Check varargs.
7110 test_varargs ("s, d' f .", "string", 65, 34.234);
7111 test_varargs_macros ();
7113 // Check flexible array members.
7114 struct incomplete_array *ia =
7115 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7116 ia->datasize = 10;
7117 for (int i = 0; i < ia->datasize; ++i)
7118 ia->data[i] = i * 1.234;
7120 // Check named initializers.
7121 struct named_init ni = {
7122 .number = 34,
7123 .name = L"Test wide string",
7124 .average = 543.34343,
7127 ni.number = 58;
7129 int dynamic_array[ni.number];
7130 dynamic_array[ni.number - 1] = 543;
7132 // work around unused variable warnings
7133 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7134 || dynamic_array[ni.number - 1] != 543);
7137 return 0;
7139 _ACEOF
7140 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7142 CC="$ac_save_CC $ac_arg"
7143 if ac_fn_c_try_compile "$LINENO"; then :
7144 ac_cv_prog_cc_c99=$ac_arg
7146 rm -f core conftest.err conftest.$ac_objext
7147 test "x$ac_cv_prog_cc_c99" != "xno" && break
7148 done
7149 rm -f conftest.$ac_ext
7150 CC=$ac_save_CC
7153 # AC_CACHE_VAL
7154 case "x$ac_cv_prog_cc_c99" in
7156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7157 $as_echo "none needed" >&6; } ;;
7158 xno)
7159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7160 $as_echo "unsupported" >&6; } ;;
7162 CC="$CC $ac_cv_prog_cc_c99"
7163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7164 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7165 esac
7166 if test "x$ac_cv_prog_cc_c99" != xno; then :
7167 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7168 else
7169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7170 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7171 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7172 $as_echo_n "(cached) " >&6
7173 else
7174 ac_cv_prog_cc_c89=no
7175 ac_save_CC=$CC
7176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7177 /* end confdefs.h. */
7178 #include <stdarg.h>
7179 #include <stdio.h>
7180 #include <sys/types.h>
7181 #include <sys/stat.h>
7182 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7183 struct buf { int x; };
7184 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7185 static char *e (p, i)
7186 char **p;
7187 int i;
7189 return p[i];
7191 static char *f (char * (*g) (char **, int), char **p, ...)
7193 char *s;
7194 va_list v;
7195 va_start (v,p);
7196 s = g (p, va_arg (v,int));
7197 va_end (v);
7198 return s;
7201 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7202 function prototypes and stuff, but not '\xHH' hex character constants.
7203 These don't provoke an error unfortunately, instead are silently treated
7204 as 'x'. The following induces an error, until -std is added to get
7205 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7206 array size at least. It's necessary to write '\x00'==0 to get something
7207 that's true only with -std. */
7208 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7210 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7211 inside strings and character constants. */
7212 #define FOO(x) 'x'
7213 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7215 int test (int i, double x);
7216 struct s1 {int (*f) (int a);};
7217 struct s2 {int (*f) (double a);};
7218 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7219 int argc;
7220 char **argv;
7222 main ()
7224 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7226 return 0;
7228 _ACEOF
7229 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7230 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7232 CC="$ac_save_CC $ac_arg"
7233 if ac_fn_c_try_compile "$LINENO"; then :
7234 ac_cv_prog_cc_c89=$ac_arg
7236 rm -f core conftest.err conftest.$ac_objext
7237 test "x$ac_cv_prog_cc_c89" != "xno" && break
7238 done
7239 rm -f conftest.$ac_ext
7240 CC=$ac_save_CC
7243 # AC_CACHE_VAL
7244 case "x$ac_cv_prog_cc_c89" in
7246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7247 $as_echo "none needed" >&6; } ;;
7248 xno)
7249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7250 $as_echo "unsupported" >&6; } ;;
7252 CC="$CC $ac_cv_prog_cc_c89"
7253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7254 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7255 esac
7256 if test "x$ac_cv_prog_cc_c89" != xno; then :
7257 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7258 else
7259 ac_cv_prog_cc_stdc=no
7264 esac
7265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7266 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7267 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7268 $as_echo_n "(cached) " >&6
7271 case $ac_cv_prog_cc_stdc in #(
7272 no) :
7273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7274 $as_echo "unsupported" >&6; } ;; #(
7275 '') :
7276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7277 $as_echo "none needed" >&6; } ;; #(
7278 *) :
7279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7280 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7281 esac
7285 # Code from module alloca-opt:
7286 # Code from module allocator:
7287 # Code from module at-internal:
7288 # Code from module binary-io:
7289 # Code from module c-ctype:
7290 # Code from module c-strcase:
7291 # Code from module careadlinkat:
7292 # Code from module clock-time:
7293 # Code from module close-stream:
7294 # Code from module crypto/md5:
7295 # Code from module crypto/sha1:
7296 # Code from module crypto/sha256:
7297 # Code from module crypto/sha512:
7298 # Code from module dirent:
7299 # Code from module dosname:
7300 # Code from module dtoastr:
7301 # Code from module dtotimespec:
7302 # Code from module dup2:
7303 # Code from module environ:
7304 # Code from module errno:
7305 # Code from module euidaccess:
7306 # Code from module execinfo:
7307 # Code from module extensions:
7309 # Code from module extern-inline:
7310 # Code from module faccessat:
7311 # Code from module fcntl:
7312 # Code from module fcntl-h:
7313 # Code from module fdatasync:
7314 # Code from module fdopendir:
7315 # Code from module filemode:
7316 # Code from module fpending:
7317 # Code from module fstatat:
7318 # Code from module fsync:
7319 # Code from module getdtablesize:
7320 # Code from module getgroups:
7321 # Code from module getloadavg:
7322 # Code from module getopt-gnu:
7323 # Code from module getopt-posix:
7324 # Code from module gettext-h:
7325 # Code from module gettime:
7326 # Code from module gettimeofday:
7327 # Code from module group-member:
7328 # Code from module include_next:
7329 # Code from module intprops:
7330 # Code from module inttypes-incomplete:
7331 # Code from module largefile:
7333 # Code from module lstat:
7334 # Code from module manywarnings:
7335 # Code from module memrchr:
7336 # Code from module mkostemp:
7337 # Code from module mktime:
7338 # Code from module multiarch:
7339 # Code from module nocrash:
7340 # Code from module openat-h:
7341 # Code from module pathmax:
7342 # Code from module pipe2:
7343 # Code from module pselect:
7344 # Code from module pthread_sigmask:
7345 # Code from module putenv:
7346 # Code from module qacl:
7347 # Code from module readlink:
7348 # Code from module readlinkat:
7349 # Code from module root-uid:
7350 # Code from module secure_getenv:
7351 # Code from module sig2str:
7352 # Code from module signal-h:
7353 # Code from module snippet/_Noreturn:
7354 # Code from module snippet/arg-nonnull:
7355 # Code from module snippet/c++defs:
7356 # Code from module snippet/warn-on-use:
7357 # Code from module socklen:
7358 # Code from module ssize_t:
7359 # Code from module stat:
7360 # Code from module stat-time:
7361 # Code from module stdalign:
7362 # Code from module stdarg:
7366 # Code from module stdbool:
7367 # Code from module stddef:
7368 # Code from module stdint:
7369 # Code from module stdio:
7370 # Code from module stdlib:
7371 # Code from module strftime:
7372 # Code from module string:
7373 # Code from module strtoimax:
7374 # Code from module strtoll:
7375 # Code from module strtoull:
7376 # Code from module strtoumax:
7377 # Code from module symlink:
7378 # Code from module sys_select:
7379 # Code from module sys_stat:
7380 # Code from module sys_time:
7381 # Code from module tempname:
7382 # Code from module time:
7383 # Code from module time_r:
7384 # Code from module timer-time:
7385 # Code from module timespec:
7386 # Code from module timespec-add:
7387 # Code from module timespec-sub:
7388 # Code from module u64:
7389 # Code from module unistd:
7390 # Code from module unsetenv:
7391 # Code from module utimens:
7392 # Code from module verify:
7393 # Code from module warnings:
7394 # Code from module xalloc-oversized:
7397 if test "$ac_test_CFLAGS" != set; then
7398 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7399 # if -g3 works and the user does not specify CFLAGS.
7400 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7401 case $CFLAGS in
7402 '-g')
7403 emacs_g3_CFLAGS='-g3';;
7404 '-g -O2')
7405 emacs_g3_CFLAGS='-g3 -O2';;
7407 emacs_g3_CFLAGS='';;
7408 esac
7409 if test -n "$emacs_g3_CFLAGS"; then
7410 emacs_save_CFLAGS=$CFLAGS
7411 CFLAGS=$emacs_g3_CFLAGS
7412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7413 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7414 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7415 $as_echo_n "(cached) " >&6
7416 else
7417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7418 /* end confdefs.h. */
7421 main ()
7425 return 0;
7427 _ACEOF
7428 if ac_fn_c_try_link "$LINENO"; then :
7429 emacs_cv_prog_cc_g3=yes
7430 else
7431 emacs_cv_prog_cc_g3=no
7433 rm -f core conftest.err conftest.$ac_objext \
7434 conftest$ac_exeext conftest.$ac_ext
7436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7437 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7438 if test $emacs_cv_prog_cc_g3 != yes; then
7439 CFLAGS=$emacs_save_CFLAGS
7441 if test $opsys = mingw32; then
7442 CFLAGS="$CFLAGS -gdwarf-2"
7446 case $CFLAGS in
7447 *-O*) ;;
7449 # No optimization flag was inferred for this non-GCC compiler.
7450 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7451 emacs_save_CFLAGS=$CFLAGS
7452 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7453 CFLAGS=${CFLAGS}-O
7454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7455 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7456 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7457 $as_echo_n "(cached) " >&6
7458 else
7459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7460 /* end confdefs.h. */
7463 main ()
7467 return 0;
7469 _ACEOF
7470 if ac_fn_c_try_link "$LINENO"; then :
7471 emacs_cv_prog_cc_o=yes
7472 else
7473 emacs_cv_prog_cc_o=no
7475 rm -f core conftest.err conftest.$ac_objext \
7476 conftest$ac_exeext conftest.$ac_ext
7478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7479 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7480 if test $emacs_cv_prog_cc_o != yes; then
7481 CFLAGS=$emacs_save_CFLAGS
7482 fi ;;
7483 esac
7486 # Check whether --enable-gcc-warnings was given.
7487 if test "${enable_gcc_warnings+set}" = set; then :
7488 enableval=$enable_gcc_warnings; case $enableval in
7489 yes|no) ;;
7490 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7491 esac
7492 gl_gcc_warnings=$enableval
7493 else
7494 gl_gcc_warnings=no
7499 # Check whether --enable-link-time-optimization was given.
7500 if test "${enable_link_time_optimization+set}" = set; then :
7501 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7503 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7504 ac_lto_supported=no
7505 if test x$GCC = xyes; then
7506 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7507 if test x$CPUS != x; then
7508 LTO="-flto=$CPUS"
7509 else
7510 LTO="-flto"
7512 old_CFLAGS=$CFLAGS
7513 CFLAGS="$CFLAGS $LTO"
7514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7515 /* end confdefs.h. */
7518 main ()
7522 return 0;
7524 _ACEOF
7525 if ac_fn_c_try_compile "$LINENO"; then :
7526 ac_lto_supported=yes
7527 else
7528 ac_lto_supported=no
7530 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7531 CFLAGS="$old_CFLAGS"
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7534 $as_echo "$ac_lto_supported" >&6; }
7535 if test "$ac_lto_supported" = "yes"; then
7536 CFLAGS="$CFLAGS $LTO"
7542 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7543 # ------------------------------------------------
7544 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7545 # Otherwise, run RUN-IF-NOT-FOUND.
7548 # clang is unduly picky about some things.
7549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7550 $as_echo_n "checking whether the compiler is clang... " >&6; }
7551 if test "${emacs_cv_clang+set}" = set; then :
7552 $as_echo_n "(cached) " >&6
7553 else
7554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7555 /* end confdefs.h. */
7557 #ifndef __clang__
7558 #error "not clang"
7559 #endif
7562 main ()
7566 return 0;
7568 _ACEOF
7569 if ac_fn_c_try_compile "$LINENO"; then :
7570 emacs_cv_clang=yes
7571 else
7572 emacs_cv_clang=no
7574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7577 $as_echo "$emacs_cv_clang" >&6; }
7579 # When compiling with GCC, prefer -isystem to -I when including system
7580 # include files, to avoid generating useless diagnostics for the files.
7581 if test "$gl_gcc_warnings" != yes; then
7582 isystem='-I'
7583 if test "$emacs_cv_clang" = yes
7584 then
7585 # Turn off some warnings if supported.
7586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7587 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7588 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7589 $as_echo_n "(cached) " >&6
7590 else
7592 gl_save_compiler_FLAGS="$CFLAGS"
7593 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7595 /* end confdefs.h. */
7598 main ()
7602 return 0;
7604 _ACEOF
7605 if ac_fn_c_try_compile "$LINENO"; then :
7606 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7607 else
7608 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7611 CFLAGS="$gl_save_compiler_FLAGS"
7614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7615 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7616 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7617 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7618 else
7619 gl_unknown_warnings_are_errors=
7623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7624 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7625 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7626 $as_echo_n "(cached) " >&6
7627 else
7629 gl_save_compiler_FLAGS="$CFLAGS"
7630 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
7631 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7632 /* end confdefs.h. */
7635 main ()
7639 return 0;
7641 _ACEOF
7642 if ac_fn_c_try_compile "$LINENO"; then :
7643 gl_cv_warn_c__Wno_switch=yes
7644 else
7645 gl_cv_warn_c__Wno_switch=no
7647 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7648 CFLAGS="$gl_save_compiler_FLAGS"
7651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7652 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7653 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7654 as_fn_append WARN_CFLAGS " -Wno-switch"
7659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
7660 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
7661 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
7662 $as_echo_n "(cached) " >&6
7663 else
7665 gl_save_compiler_FLAGS="$CFLAGS"
7666 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
7667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7668 /* end confdefs.h. */
7671 main ()
7675 return 0;
7677 _ACEOF
7678 if ac_fn_c_try_compile "$LINENO"; then :
7679 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
7680 else
7681 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
7683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7684 CFLAGS="$gl_save_compiler_FLAGS"
7687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
7688 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
7689 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
7690 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
7695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-pointer-sign" >&5
7696 $as_echo_n "checking whether C compiler handles -Wno-pointer-sign... " >&6; }
7697 if test "${gl_cv_warn_c__Wno_pointer_sign+set}" = set; then :
7698 $as_echo_n "(cached) " >&6
7699 else
7701 gl_save_compiler_FLAGS="$CFLAGS"
7702 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wpointer-sign"
7703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7704 /* end confdefs.h. */
7707 main ()
7711 return 0;
7713 _ACEOF
7714 if ac_fn_c_try_compile "$LINENO"; then :
7715 gl_cv_warn_c__Wno_pointer_sign=yes
7716 else
7717 gl_cv_warn_c__Wno_pointer_sign=no
7719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7720 CFLAGS="$gl_save_compiler_FLAGS"
7723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_pointer_sign" >&5
7724 $as_echo "$gl_cv_warn_c__Wno_pointer_sign" >&6; }
7725 if test "x$gl_cv_warn_c__Wno_pointer_sign" = x""yes; then :
7726 as_fn_append WARN_CFLAGS " -Wno-pointer-sign"
7731 else
7732 isystem='-isystem '
7734 # This, $nw, is the list of warnings we disable.
7737 case $with_x_toolkit in
7738 lucid | athena | motif)
7739 # Old toolkits mishandle 'const'.
7740 nw="$nw -Wwrite-strings"
7744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7745 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7746 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7747 $as_echo_n "(cached) " >&6
7748 else
7750 gl_save_compiler_FLAGS="$CFLAGS"
7751 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7753 /* end confdefs.h. */
7756 main ()
7760 return 0;
7762 _ACEOF
7763 if ac_fn_c_try_compile "$LINENO"; then :
7764 gl_cv_warn_c__Werror=yes
7765 else
7766 gl_cv_warn_c__Werror=no
7768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7769 CFLAGS="$gl_save_compiler_FLAGS"
7772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7773 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7774 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7775 as_fn_append WERROR_CFLAGS " -Werror"
7780 esac
7783 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7784 nw="$nw -Woverlength-strings" # Not a problem these days
7785 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7786 nw="$nw -Wformat-nonliteral" # we do this a lot
7787 nw="$nw -Wvla" # warnings in gettext.h
7788 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7789 nw="$nw -Wswitch-default" # Too many warnings for now
7790 nw="$nw -Winline" # OK to ignore 'inline'
7791 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7792 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7793 # signed overflow has undefined behavior
7794 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7795 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7796 nw="$nw -Wbad-function-cast" # These casts are no worse than others.
7798 # Emacs doesn't care about shadowing; see
7799 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7800 nw="$nw -Wshadow"
7802 # Emacs's use of alloca inhibits protecting the stack.
7803 nw="$nw -Wstack-protector"
7805 # The following line should be removable at some point.
7806 nw="$nw -Wsuggest-attribute=pure"
7808 # This part is merely for shortening the command line,
7809 # since -Wno-FOO needs to be added below regardless.
7810 nw="$nw -Wmissing-field-initializers"
7811 nw="$nw -Wswitch"
7812 nw="$nw -Wtype-limits"
7813 nw="$nw -Wunused-parameter"
7815 if test $emacs_cv_clang = yes; then
7816 nw="$nw -Wcast-align"
7821 if test -n "$GCC"; then
7823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7824 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7825 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7826 $as_echo_n "(cached) " >&6
7827 else
7829 gl_save_CFLAGS="$CFLAGS"
7830 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7832 /* end confdefs.h. */
7835 main ()
7839 return 0;
7841 _ACEOF
7842 if ac_fn_c_try_compile "$LINENO"; then :
7843 gl_cv_cc_nomfi_supported=yes
7844 else
7845 gl_cv_cc_nomfi_supported=no
7847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7848 CFLAGS="$gl_save_CFLAGS"
7851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7852 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7854 if test "$gl_cv_cc_nomfi_supported" = yes; then
7855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7856 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7857 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7858 $as_echo_n "(cached) " >&6
7859 else
7861 gl_save_CFLAGS="$CFLAGS"
7862 CFLAGS="$CFLAGS -W -Werror"
7863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7864 /* end confdefs.h. */
7865 void f (void)
7867 typedef struct { int a; int b; } s_t;
7868 s_t s1 = { 0, };
7872 main ()
7876 return 0;
7878 _ACEOF
7879 if ac_fn_c_try_compile "$LINENO"; then :
7880 gl_cv_cc_nomfi_needed=no
7881 else
7882 gl_cv_cc_nomfi_needed=yes
7884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7885 CFLAGS="$gl_save_CFLAGS"
7889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7890 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7894 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7895 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7896 $as_echo_n "(cached) " >&6
7897 else
7899 gl_save_CFLAGS="$CFLAGS"
7900 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7902 /* end confdefs.h. */
7905 main ()
7909 return 0;
7911 _ACEOF
7912 if ac_fn_c_try_compile "$LINENO"; then :
7913 gl_cv_cc_uninitialized_supported=yes
7914 else
7915 gl_cv_cc_uninitialized_supported=no
7917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7918 CFLAGS="$gl_save_CFLAGS"
7921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7922 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7926 # List all gcc warning categories.
7927 gl_manywarn_set=
7928 for gl_manywarn_item in \
7929 -W \
7930 -Wabi \
7931 -Waddress \
7932 -Waggressive-loop-optimizations \
7933 -Wall \
7934 -Warray-bounds \
7935 -Wattributes \
7936 -Wbad-function-cast \
7937 -Wbuiltin-macro-redefined \
7938 -Wcast-align \
7939 -Wchar-subscripts \
7940 -Wclobbered \
7941 -Wcomment \
7942 -Wcomments \
7943 -Wcoverage-mismatch \
7944 -Wcpp \
7945 -Wdeprecated \
7946 -Wdeprecated-declarations \
7947 -Wdisabled-optimization \
7948 -Wdiv-by-zero \
7949 -Wdouble-promotion \
7950 -Wempty-body \
7951 -Wendif-labels \
7952 -Wenum-compare \
7953 -Wextra \
7954 -Wformat-contains-nul \
7955 -Wformat-extra-args \
7956 -Wformat-nonliteral \
7957 -Wformat-security \
7958 -Wformat-y2k \
7959 -Wformat-zero-length \
7960 -Wfree-nonheap-object \
7961 -Wignored-qualifiers \
7962 -Wimplicit \
7963 -Wimplicit-function-declaration \
7964 -Wimplicit-int \
7965 -Winit-self \
7966 -Winline \
7967 -Wint-to-pointer-cast \
7968 -Winvalid-memory-model \
7969 -Winvalid-pch \
7970 -Wjump-misses-init \
7971 -Wlogical-op \
7972 -Wmain \
7973 -Wmaybe-uninitialized \
7974 -Wmissing-braces \
7975 -Wmissing-declarations \
7976 -Wmissing-field-initializers \
7977 -Wmissing-include-dirs \
7978 -Wmissing-parameter-type \
7979 -Wmissing-prototypes \
7980 -Wmudflap \
7981 -Wmultichar \
7982 -Wnarrowing \
7983 -Wnested-externs \
7984 -Wnonnull \
7985 -Wnormalized=nfc \
7986 -Wold-style-declaration \
7987 -Wold-style-definition \
7988 -Woverflow \
7989 -Woverlength-strings \
7990 -Woverride-init \
7991 -Wpacked \
7992 -Wpacked-bitfield-compat \
7993 -Wparentheses \
7994 -Wpointer-arith \
7995 -Wpointer-sign \
7996 -Wpointer-to-int-cast \
7997 -Wpragmas \
7998 -Wreturn-local-addr \
7999 -Wreturn-type \
8000 -Wsequence-point \
8001 -Wshadow \
8002 -Wsizeof-pointer-memaccess \
8003 -Wstack-protector \
8004 -Wstrict-aliasing \
8005 -Wstrict-overflow \
8006 -Wstrict-prototypes \
8007 -Wsuggest-attribute=const \
8008 -Wsuggest-attribute=format \
8009 -Wsuggest-attribute=noreturn \
8010 -Wsuggest-attribute=pure \
8011 -Wswitch \
8012 -Wswitch-default \
8013 -Wsync-nand \
8014 -Wsystem-headers \
8015 -Wtrampolines \
8016 -Wtrigraphs \
8017 -Wtype-limits \
8018 -Wuninitialized \
8019 -Wunknown-pragmas \
8020 -Wunsafe-loop-optimizations \
8021 -Wunused \
8022 -Wunused-but-set-parameter \
8023 -Wunused-but-set-variable \
8024 -Wunused-function \
8025 -Wunused-label \
8026 -Wunused-local-typedefs \
8027 -Wunused-macros \
8028 -Wunused-parameter \
8029 -Wunused-result \
8030 -Wunused-value \
8031 -Wunused-variable \
8032 -Wvarargs \
8033 -Wvariadic-macros \
8034 -Wvector-operation-performance \
8035 -Wvla \
8036 -Wvolatile-register-var \
8037 -Wwrite-strings \
8039 ; do
8040 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
8041 done
8043 # Disable specific options as needed.
8044 if test "$gl_cv_cc_nomfi_needed" = yes; then
8045 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
8048 if test "$gl_cv_cc_uninitialized_supported" = no; then
8049 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
8052 ws=$gl_manywarn_set
8055 gl_warn_set=
8056 set x $ws; shift
8057 for gl_warn_item
8059 case " $nw " in
8060 *" $gl_warn_item "*)
8063 gl_warn_set="$gl_warn_set $gl_warn_item"
8065 esac
8066 done
8067 ws=$gl_warn_set
8069 for w in $ws; do
8071 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
8072 gl_positive="$w"
8073 case $gl_positive in
8074 -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
8075 esac
8076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
8077 $as_echo_n "checking whether C compiler handles $w... " >&6; }
8078 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
8079 $as_echo_n "(cached) " >&6
8080 else
8082 gl_save_compiler_FLAGS="$CFLAGS"
8083 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive"
8084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8085 /* end confdefs.h. */
8088 main ()
8092 return 0;
8094 _ACEOF
8095 if ac_fn_c_try_compile "$LINENO"; then :
8096 eval "$as_gl_Warn=yes"
8097 else
8098 eval "$as_gl_Warn=no"
8100 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8101 CFLAGS="$gl_save_compiler_FLAGS"
8104 eval ac_res=\$$as_gl_Warn
8105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8106 $as_echo "$ac_res" >&6; }
8107 eval as_val=\$$as_gl_Warn
8108 if test "x$as_val" = x""yes; then :
8109 as_fn_append WARN_CFLAGS " $w"
8113 done
8115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
8116 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
8117 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
8118 $as_echo_n "(cached) " >&6
8119 else
8121 gl_save_compiler_FLAGS="$CFLAGS"
8122 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wmissing-field-initializers"
8123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8124 /* end confdefs.h. */
8127 main ()
8131 return 0;
8133 _ACEOF
8134 if ac_fn_c_try_compile "$LINENO"; then :
8135 gl_cv_warn_c__Wno_missing_field_initializers=yes
8136 else
8137 gl_cv_warn_c__Wno_missing_field_initializers=no
8139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8140 CFLAGS="$gl_save_compiler_FLAGS"
8143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
8144 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
8145 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
8146 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
8149 # We need this one
8151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
8152 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
8153 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
8154 $as_echo_n "(cached) " >&6
8155 else
8157 gl_save_compiler_FLAGS="$CFLAGS"
8158 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wsign-compare"
8159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8160 /* end confdefs.h. */
8163 main ()
8167 return 0;
8169 _ACEOF
8170 if ac_fn_c_try_compile "$LINENO"; then :
8171 gl_cv_warn_c__Wno_sign_compare=yes
8172 else
8173 gl_cv_warn_c__Wno_sign_compare=no
8175 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8176 CFLAGS="$gl_save_compiler_FLAGS"
8179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
8180 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
8181 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
8182 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
8185 # Too many warnings for now
8187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
8188 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
8189 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8190 $as_echo_n "(cached) " >&6
8191 else
8193 gl_save_compiler_FLAGS="$CFLAGS"
8194 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtype-limits"
8195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8196 /* end confdefs.h. */
8199 main ()
8203 return 0;
8205 _ACEOF
8206 if ac_fn_c_try_compile "$LINENO"; then :
8207 gl_cv_warn_c__Wno_type_limits=yes
8208 else
8209 gl_cv_warn_c__Wno_type_limits=no
8211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8212 CFLAGS="$gl_save_compiler_FLAGS"
8215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8216 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8217 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8218 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8221 # Too many warnings for now
8223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8224 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8225 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8226 $as_echo_n "(cached) " >&6
8227 else
8229 gl_save_compiler_FLAGS="$CFLAGS"
8230 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
8231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8232 /* end confdefs.h. */
8235 main ()
8239 return 0;
8241 _ACEOF
8242 if ac_fn_c_try_compile "$LINENO"; then :
8243 gl_cv_warn_c__Wno_switch=yes
8244 else
8245 gl_cv_warn_c__Wno_switch=no
8247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8248 CFLAGS="$gl_save_compiler_FLAGS"
8251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8252 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8253 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8254 as_fn_append WARN_CFLAGS " -Wno-switch"
8257 # Too many warnings for now
8259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8260 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8261 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8262 $as_echo_n "(cached) " >&6
8263 else
8265 gl_save_compiler_FLAGS="$CFLAGS"
8266 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-parameter"
8267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8268 /* end confdefs.h. */
8271 main ()
8275 return 0;
8277 _ACEOF
8278 if ac_fn_c_try_compile "$LINENO"; then :
8279 gl_cv_warn_c__Wno_unused_parameter=yes
8280 else
8281 gl_cv_warn_c__Wno_unused_parameter=no
8283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8284 CFLAGS="$gl_save_compiler_FLAGS"
8287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8288 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8289 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8290 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8293 # Too many warnings for now
8295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8296 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8297 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8298 $as_echo_n "(cached) " >&6
8299 else
8301 gl_save_compiler_FLAGS="$CFLAGS"
8302 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-nonliteral"
8303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8304 /* end confdefs.h. */
8307 main ()
8311 return 0;
8313 _ACEOF
8314 if ac_fn_c_try_compile "$LINENO"; then :
8315 gl_cv_warn_c__Wno_format_nonliteral=yes
8316 else
8317 gl_cv_warn_c__Wno_format_nonliteral=no
8319 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8320 CFLAGS="$gl_save_compiler_FLAGS"
8323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8324 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8325 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8326 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8331 # In spite of excluding -Wlogical-op above, it is enabled, as of
8332 # gcc 4.5.0 20090517.
8334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8335 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8336 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8337 $as_echo_n "(cached) " >&6
8338 else
8340 gl_save_compiler_FLAGS="$CFLAGS"
8341 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wlogical-op"
8342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8343 /* end confdefs.h. */
8346 main ()
8350 return 0;
8352 _ACEOF
8353 if ac_fn_c_try_compile "$LINENO"; then :
8354 gl_cv_warn_c__Wno_logical_op=yes
8355 else
8356 gl_cv_warn_c__Wno_logical_op=no
8358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8359 CFLAGS="$gl_save_compiler_FLAGS"
8362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8363 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8364 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8365 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8370 # More things that clang is unduly picky about.
8371 if test $emacs_cv_clang = yes; then
8373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8374 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8375 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8376 $as_echo_n "(cached) " >&6
8377 else
8379 gl_save_compiler_FLAGS="$CFLAGS"
8380 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-extra-args"
8381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8382 /* end confdefs.h. */
8385 main ()
8389 return 0;
8391 _ACEOF
8392 if ac_fn_c_try_compile "$LINENO"; then :
8393 gl_cv_warn_c__Wno_format_extra_args=yes
8394 else
8395 gl_cv_warn_c__Wno_format_extra_args=no
8397 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8398 CFLAGS="$gl_save_compiler_FLAGS"
8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8402 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8403 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8404 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8410 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8411 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8412 $as_echo_n "(cached) " >&6
8413 else
8415 gl_save_compiler_FLAGS="$CFLAGS"
8416 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
8417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8418 /* end confdefs.h. */
8421 main ()
8425 return 0;
8427 _ACEOF
8428 if ac_fn_c_try_compile "$LINENO"; then :
8429 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8430 else
8431 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8434 CFLAGS="$gl_save_compiler_FLAGS"
8437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8438 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8439 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8440 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8446 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8447 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8448 $as_echo_n "(cached) " >&6
8449 else
8451 gl_save_compiler_FLAGS="$CFLAGS"
8452 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-command-line-argument"
8453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8454 /* end confdefs.h. */
8457 main ()
8461 return 0;
8463 _ACEOF
8464 if ac_fn_c_try_compile "$LINENO"; then :
8465 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8466 else
8467 gl_cv_warn_c__Wno_unused_command_line_argument=no
8469 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8470 CFLAGS="$gl_save_compiler_FLAGS"
8473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8474 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8475 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8476 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8482 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8483 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8484 $as_echo_n "(cached) " >&6
8485 else
8487 gl_save_compiler_FLAGS="$CFLAGS"
8488 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-value"
8489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8490 /* end confdefs.h. */
8493 main ()
8497 return 0;
8499 _ACEOF
8500 if ac_fn_c_try_compile "$LINENO"; then :
8501 gl_cv_warn_c__Wno_unused_value=yes
8502 else
8503 gl_cv_warn_c__Wno_unused_value=no
8505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8506 CFLAGS="$gl_save_compiler_FLAGS"
8509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8510 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8511 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8512 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
8520 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
8521 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
8522 $as_echo_n "(cached) " >&6
8523 else
8525 gl_save_compiler_FLAGS="$CFLAGS"
8526 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
8527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8528 /* end confdefs.h. */
8531 main ()
8535 return 0;
8537 _ACEOF
8538 if ac_fn_c_try_compile "$LINENO"; then :
8539 gl_cv_warn_c__fdiagnostics_show_option=yes
8540 else
8541 gl_cv_warn_c__fdiagnostics_show_option=no
8543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8544 CFLAGS="$gl_save_compiler_FLAGS"
8547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
8548 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
8549 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
8550 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
8555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
8556 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
8557 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
8558 $as_echo_n "(cached) " >&6
8559 else
8561 gl_save_compiler_FLAGS="$CFLAGS"
8562 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
8563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8564 /* end confdefs.h. */
8567 main ()
8571 return 0;
8573 _ACEOF
8574 if ac_fn_c_try_compile "$LINENO"; then :
8575 gl_cv_warn_c__funit_at_a_time=yes
8576 else
8577 gl_cv_warn_c__funit_at_a_time=no
8579 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8580 CFLAGS="$gl_save_compiler_FLAGS"
8583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
8584 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
8585 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
8586 as_fn_append WARN_CFLAGS " -funit-at-a-time"
8592 $as_echo "#define lint 1" >>confdefs.h
8596 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8599 # We use a slightly smaller set of warning options for lib/.
8600 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8602 nw="$nw -Wunused-macros"
8605 gl_warn_set=
8606 set x $WARN_CFLAGS; shift
8607 for gl_warn_item
8609 case " $nw " in
8610 *" $gl_warn_item "*)
8613 gl_warn_set="$gl_warn_set $gl_warn_item"
8615 esac
8616 done
8617 GNULIB_WARN_CFLAGS=$gl_warn_set
8627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8628 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8629 rm -f conf$$ conf$$.file
8631 LN_S_FILEONLY='cp -p'
8633 if (echo >conf$$.file) 2>/dev/null; then
8634 if ln -s conf$$.file conf$$ 2>/dev/null; then
8635 LN_S_FILEONLY='ln -s'
8636 elif ln conf$$.file conf$$ 2>/dev/null; then
8637 LN_S_FILEONLY=ln
8641 rm -f conf$$ conf$$.file
8643 if test "$LN_S_FILEONLY" = "ln -s"; then
8644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8645 $as_echo "yes" >&6; }
8646 else
8647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8648 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8654 if test "$opsys" = "mingw32"; then
8655 LN_S="ln"
8658 # Extract the first word of "install-info", so it can be a program name with args.
8659 set dummy install-info; ac_word=$2
8660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8661 $as_echo_n "checking for $ac_word... " >&6; }
8662 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8663 $as_echo_n "(cached) " >&6
8664 else
8665 case $INSTALL_INFO in
8666 [\\/]* | ?:[\\/]*)
8667 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8671 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8673 IFS=$as_save_IFS
8674 test -z "$as_dir" && as_dir=.
8675 for ac_exec_ext in '' $ac_executable_extensions; do
8676 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8677 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8679 break 2
8681 done
8682 done
8683 IFS=$as_save_IFS
8685 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8687 esac
8689 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8690 if test -n "$INSTALL_INFO"; then
8691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8692 $as_echo "$INSTALL_INFO" >&6; }
8693 else
8694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8695 $as_echo "no" >&6; }
8699 # Extract the first word of "gzip", so it can be a program name with args.
8700 set dummy gzip; ac_word=$2
8701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8702 $as_echo_n "checking for $ac_word... " >&6; }
8703 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8704 $as_echo_n "(cached) " >&6
8705 else
8706 case $GZIP_PROG in
8707 [\\/]* | ?:[\\/]*)
8708 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8711 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8712 for as_dir in $PATH
8714 IFS=$as_save_IFS
8715 test -z "$as_dir" && as_dir=.
8716 for ac_exec_ext in '' $ac_executable_extensions; do
8717 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8718 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8720 break 2
8722 done
8723 done
8724 IFS=$as_save_IFS
8727 esac
8729 GZIP_PROG=$ac_cv_path_GZIP_PROG
8730 if test -n "$GZIP_PROG"; then
8731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8732 $as_echo "$GZIP_PROG" >&6; }
8733 else
8734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8735 $as_echo "no" >&6; }
8740 test $with_compress_install != yes && test -n "$GZIP_PROG" && \
8741 GZIP_PROG=" # $GZIP_PROG # (disabled by configure --without-compress-install)"
8743 if test $opsys = gnu-linux; then
8744 # Extract the first word of "paxctl", so it can be a program name with args.
8745 set dummy paxctl; ac_word=$2
8746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8747 $as_echo_n "checking for $ac_word... " >&6; }
8748 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8749 $as_echo_n "(cached) " >&6
8750 else
8751 case $PAXCTL in
8752 [\\/]* | ?:[\\/]*)
8753 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8756 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8757 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8759 IFS=$as_save_IFS
8760 test -z "$as_dir" && as_dir=.
8761 for ac_exec_ext in '' $ac_executable_extensions; do
8762 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8763 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8764 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8765 break 2
8767 done
8768 done
8769 IFS=$as_save_IFS
8772 esac
8774 PAXCTL=$ac_cv_path_PAXCTL
8775 if test -n "$PAXCTL"; then
8776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8777 $as_echo "$PAXCTL" >&6; }
8778 else
8779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8780 $as_echo "no" >&6; }
8784 if test "X$PAXCTL" != X; then
8785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8786 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8788 /* end confdefs.h. */
8791 main ()
8795 return 0;
8797 _ACEOF
8798 if ac_fn_c_try_link "$LINENO"; then :
8799 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8800 $as_echo "yes" >&6; }
8801 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8802 $as_echo "no" >&6; }; PAXCTL=""; fi
8804 rm -f core conftest.err conftest.$ac_objext \
8805 conftest$ac_exeext conftest.$ac_ext
8809 ## Need makeinfo >= 4.7 (?) to build the manuals.
8810 # Extract the first word of "makeinfo", so it can be a program name with args.
8811 set dummy makeinfo; ac_word=$2
8812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8813 $as_echo_n "checking for $ac_word... " >&6; }
8814 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8815 $as_echo_n "(cached) " >&6
8816 else
8817 case $MAKEINFO in
8818 [\\/]* | ?:[\\/]*)
8819 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8822 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8823 for as_dir in $PATH
8825 IFS=$as_save_IFS
8826 test -z "$as_dir" && as_dir=.
8827 for ac_exec_ext in '' $ac_executable_extensions; do
8828 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8829 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8830 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8831 break 2
8833 done
8834 done
8835 IFS=$as_save_IFS
8837 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8839 esac
8841 MAKEINFO=$ac_cv_path_MAKEINFO
8842 if test -n "$MAKEINFO"; then
8843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8844 $as_echo "$MAKEINFO" >&6; }
8845 else
8846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8847 $as_echo "no" >&6; }
8851 if test "$MAKEINFO" != "no"; then
8852 case `
8853 $MAKEINFO --version 2> /dev/null |
8854 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8855 ` in
8856 '') MAKEINFO=no;;
8857 esac
8860 ## Makeinfo is unusual. For a released Emacs, the manuals are
8861 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8862 ## therefore in the category of "special tools" not normally required, which
8863 ## configure does not have to check for (eg autoconf itself).
8864 ## In a Bazaar checkout on the other hand, the manuals are not included.
8865 ## So makeinfo is a requirement to build from Bazaar, and configure
8866 ## should test for it as it does for any other build requirement.
8867 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8868 ## with pre-built manuals, from a Bazaar checkout.
8869 HAVE_MAKEINFO=yes
8871 if test "$MAKEINFO" = "no"; then
8872 MAKEINFO=makeinfo
8873 if test "x${with_makeinfo}" = "xno"; then
8874 HAVE_MAKEINFO=no
8875 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8876 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8877 source tree does not seem to have pre-built manuals in the \`info' directory.
8878 Either install a suitable version of makeinfo, or re-run configure
8879 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8884 INFO_EXT=.info
8885 INFO_OPTS=--no-split
8889 if test $opsys = mingw32; then
8890 DOCMISC_W32=efaq-w32
8891 else
8892 DOCMISC_W32=
8897 if test x$GCC = xyes; then
8898 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8899 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8900 else
8901 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8902 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8906 late_LDFLAGS="$LDFLAGS"
8907 if test x$GCC = xyes; then
8908 LDFLAGS_NOCOMBRELOC="-Wl,-znocombreloc"
8909 else
8910 LDFLAGS_NOCOMBRELOC="-znocombreloc"
8913 LDFLAGS="$LDFLAGS $LDFLAGS_NOCOMBRELOC"
8915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8916 $as_echo_n "checking for -znocombreloc... " >&6; }
8917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8918 /* end confdefs.h. */
8921 main ()
8925 return 0;
8927 _ACEOF
8928 if ac_fn_c_try_link "$LINENO"; then :
8929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8930 $as_echo "yes" >&6; }
8931 else
8932 LDFLAGS_NOCOMBRELOC=
8933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8934 $as_echo "no" >&6; }
8936 rm -f core conftest.err conftest.$ac_objext \
8937 conftest$ac_exeext conftest.$ac_ext
8939 LDFLAGS="$late_LDFLAGS"
8941 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8942 case "$opsys" in
8943 your-opsys-here) CANNOT_DUMP=yes ;;
8944 esac
8946 test "$CANNOT_DUMP" = "yes" && \
8948 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8954 UNEXEC_OBJ=unexelf.o
8955 case "$opsys" in
8956 # MSDOS uses unexcoff.o
8957 aix4-2)
8958 UNEXEC_OBJ=unexaix.o
8960 cygwin)
8961 UNEXEC_OBJ=unexcw.o
8963 darwin)
8964 UNEXEC_OBJ=unexmacosx.o
8966 hpux10-20 | hpux11)
8967 UNEXEC_OBJ=unexhp9k800.o
8969 mingw32)
8970 UNEXEC_OBJ=unexw32.o
8972 sol2-10)
8973 # Use the Solaris dldump() function, called from unexsol.c, to dump
8974 # emacs, instead of the generic ELF dump code found in unexelf.c.
8975 # The resulting binary has a complete symbol table, and is better
8976 # for debugging and other observability tools (debuggers, pstack, etc).
8978 # If you encounter a problem using dldump(), please consider sending
8979 # a message to the OpenSolaris tools-linking mailing list:
8980 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8982 # It is likely that dldump() works with older Solaris too, but this has
8983 # not been tested, so for now this change is for Solaris 10 or newer.
8984 UNEXEC_OBJ=unexsol.o
8986 esac
8988 LD_SWITCH_SYSTEM=
8989 case "$opsys" in
8990 freebsd|dragonfly)
8991 ## Let `ld' find image libs and similar things in /usr/local/lib.
8992 ## The system compiler, GCC, has apparently been modified to not
8993 ## look there, contrary to what a stock GCC would do.
8994 ### It's not our place to do this. See bug#10313#17.
8995 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8999 gnu-linux)
9000 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
9001 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
9004 netbsd)
9005 ### It's not our place to do this. See bug#10313#17.
9006 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
9010 openbsd)
9011 ## Han Boetes <han@boetes.org> says this is necessary,
9012 ## otherwise Emacs dumps core on elf systems.
9013 LD_SWITCH_SYSTEM="-Z"
9015 esac
9018 ac_link="$ac_link $LD_SWITCH_SYSTEM"
9020 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
9021 ## which has not been defined yet. When this was handled with cpp,
9022 ## it was expanded to null when configure sourced the s/*.h file.
9023 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
9024 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
9025 ## (or somesuch), but because it is supposed to go at the _front_
9026 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
9027 ## Compare with the gnu-linux case below, which added to the end
9028 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
9029 ## LD_SWITCH_SYSTEM_TEMACS.
9030 case "$opsys" in
9031 netbsd|openbsd)
9032 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
9033 esac
9036 C_SWITCH_MACHINE=
9037 case $canonical in
9038 alpha*)
9039 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
9040 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
9044 if test "$ac_cv_have_decl___ELF__" = "yes"; then
9045 ## With ELF, make sure that all common symbols get allocated to in the
9046 ## data section. Otherwise, the dump of temacs may miss variables in
9047 ## the shared library that have been initialized. For example, with
9048 ## GNU libc, __malloc_initialized would normally be resolved to the
9049 ## shared library's .bss section, which is fatal.
9050 if test "x$GCC" = "xyes"; then
9051 C_SWITCH_MACHINE="-fno-common"
9052 else
9053 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
9055 else
9056 UNEXEC_OBJ=unexalpha.o
9059 esac
9064 C_SWITCH_SYSTEM=
9065 ## Some programs in src produce warnings saying certain subprograms
9066 ## are too complex and need a MAXMEM value greater than 2000 for
9067 ## additional optimization. --nils@exp-math.uni-essen.de
9068 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
9069 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
9070 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
9071 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
9072 ## It is redundant in glibc2, since we define _GNU_SOURCE.
9076 LIBS_SYSTEM=
9077 case "$opsys" in
9078 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
9079 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
9081 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
9083 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
9085 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
9087 ## Motif needs -lgen.
9088 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
9089 esac
9093 ### Make sure subsequent tests use flags consistent with the build flags.
9095 if test x"${OVERRIDE_CPPFLAGS}" != x; then
9096 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
9097 else
9098 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
9101 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
9103 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
9107 LIB_MATH=-lm
9108 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
9110 case $opsys in
9111 cygwin )
9112 LIB_MATH=
9114 darwin )
9115 ## Adding -lm confuses the dynamic linker, so omit it.
9116 LIB_MATH=
9118 freebsd | dragonfly )
9119 SYSTEM_TYPE=berkeley-unix
9121 gnu-linux | gnu-kfreebsd )
9123 hpux10-20 | hpux11 )
9125 mingw32 )
9126 LIB_MATH=
9127 SYSTEM_TYPE=windows-nt
9129 netbsd | openbsd )
9130 SYSTEM_TYPE=berkeley-unix
9133 sol2* | unixware )
9134 SYSTEM_TYPE=usg-unix-v
9137 esac
9141 cat >>confdefs.h <<_ACEOF
9142 #define SYSTEM_TYPE "$SYSTEM_TYPE"
9143 _ACEOF
9147 pre_PKG_CONFIG_CFLAGS=$CFLAGS
9148 pre_PKG_CONFIG_LIBS=$LIBS
9150 # Extract the first word of "pkg-config", so it can be a program name with args.
9151 set dummy pkg-config; ac_word=$2
9152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9153 $as_echo_n "checking for $ac_word... " >&6; }
9154 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9155 $as_echo_n "(cached) " >&6
9156 else
9157 case $PKG_CONFIG in
9158 [\\/]* | ?:[\\/]*)
9159 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9162 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9163 for as_dir in $PATH
9165 IFS=$as_save_IFS
9166 test -z "$as_dir" && as_dir=.
9167 for ac_exec_ext in '' $ac_executable_extensions; do
9168 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9169 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9170 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9171 break 2
9173 done
9174 done
9175 IFS=$as_save_IFS
9177 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9179 esac
9181 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9182 if test -n "$PKG_CONFIG"; then
9183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9184 $as_echo "$PKG_CONFIG" >&6; }
9185 else
9186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9187 $as_echo "no" >&6; }
9194 HAVE_SOUND=no
9195 if test "${with_sound}" != "no"; then
9196 # Sound support for GNU/Linux, the free BSDs, and MinGW.
9197 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
9198 do :
9199 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9200 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9201 #ifdef __MINGW32__
9202 #define WIN32_LEAN_AND_MEAN
9203 #include <windows.h>
9204 #endif
9207 eval as_val=\$$as_ac_Header
9208 if test "x$as_val" = x""yes; then :
9209 cat >>confdefs.h <<_ACEOF
9210 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9211 _ACEOF
9212 have_sound_header=yes
9215 done
9217 test "${with_sound}" = "oss" && test "${have_sound_header}" != "yes" && \
9218 as_fn_error "OSS sound support requested but not found." "$LINENO" 5
9220 if test "${with_sound}" = "bsd-ossaudio" || test "${with_sound}" = "yes"; then
9221 # Emulation library used on NetBSD.
9222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9223 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9224 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9225 $as_echo_n "(cached) " >&6
9226 else
9227 ac_check_lib_save_LIBS=$LIBS
9228 LIBS="-lossaudio $LIBS"
9229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9230 /* end confdefs.h. */
9232 /* Override any GCC internal prototype to avoid an error.
9233 Use char because int might match the return type of a GCC
9234 builtin and then its argument prototype would still apply. */
9235 #ifdef __cplusplus
9236 extern "C"
9237 #endif
9238 char _oss_ioctl ();
9240 main ()
9242 return _oss_ioctl ();
9244 return 0;
9246 _ACEOF
9247 if ac_fn_c_try_link "$LINENO"; then :
9248 ac_cv_lib_ossaudio__oss_ioctl=yes
9249 else
9250 ac_cv_lib_ossaudio__oss_ioctl=no
9252 rm -f core conftest.err conftest.$ac_objext \
9253 conftest$ac_exeext conftest.$ac_ext
9254 LIBS=$ac_check_lib_save_LIBS
9256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9257 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9258 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9259 LIBSOUND=-lossaudio
9260 else
9261 LIBSOUND=
9264 test "${with_sound}" = "bsd-ossaudio" && test -z "$LIBSOUND" && \
9265 as_fn_error "bsd-ossaudio sound support requested but not found." "$LINENO" 5
9269 if test "${with_sound}" = "alsa" || test "${with_sound}" = "yes"; then
9270 ALSA_REQUIRED=1.0.0
9271 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9273 succeeded=no
9275 if test "$PKG_CONFIG" = "no" ; then
9276 HAVE_ALSA=no
9277 else
9278 PKG_CONFIG_MIN_VERSION=0.9.0
9279 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9281 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9283 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9284 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9285 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9286 edit_cflags="
9287 s,///*,/,g
9288 s/^/ /
9289 s/ -I/ $isystem/g
9290 s/^ //
9292 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9293 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9295 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9296 succeeded=yes
9297 else
9298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9299 $as_echo "no" >&6; }
9300 ALSA_CFLAGS=""
9301 ALSA_LIBS=""
9302 ## If we have a custom action on failure, don't print errors, but
9303 ## do set a variable so people can do so. Do it in a subshell
9304 ## to capture any diagnostics in invoking pkg-config.
9305 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9311 else
9312 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9313 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9317 if test $succeeded = yes; then
9318 HAVE_ALSA=yes
9319 else
9320 HAVE_ALSA=no
9323 if test $HAVE_ALSA = yes; then
9324 SAVE_CFLAGS="$CFLAGS"
9325 SAVE_LIBS="$LIBS"
9326 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9327 LIBS="$ALSA_LIBS $LIBS"
9328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9329 /* end confdefs.h. */
9330 #include <asoundlib.h>
9332 main ()
9334 snd_lib_error_set_handler (0);
9336 return 0;
9338 _ACEOF
9339 if ac_fn_c_try_compile "$LINENO"; then :
9340 emacs_alsa_normal=yes
9341 else
9342 emacs_alsa_normal=no
9344 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9345 if test "$emacs_alsa_normal" != yes; then
9346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9347 /* end confdefs.h. */
9348 #include <alsa/asoundlib.h>
9350 main ()
9352 snd_lib_error_set_handler (0);
9354 return 0;
9356 _ACEOF
9357 if ac_fn_c_try_compile "$LINENO"; then :
9358 emacs_alsa_subdir=yes
9359 else
9360 emacs_alsa_subdir=no
9362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9363 if test "$emacs_alsa_subdir" != yes; then
9364 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9366 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9369 CFLAGS="$SAVE_CFLAGS"
9370 LIBS="$SAVE_LIBS"
9371 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9372 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9374 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9376 elif test "${with_sound}" = "alsa"; then
9377 as_fn_error "ALSA sound support requested but not found." "$LINENO" 5
9380 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9381 case "$opsys" in
9382 gnu-linux|freebsd|netbsd|mingw32)
9384 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9386 HAVE_SOUND=yes
9388 esac
9397 for ac_header in $ac_header_list
9398 do :
9399 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9400 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9402 eval as_val=\$$as_ac_Header
9403 if test "x$as_val" = x""yes; then :
9404 cat >>confdefs.h <<_ACEOF
9405 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9406 _ACEOF
9410 done
9430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9431 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9433 /* end confdefs.h. */
9434 #include <sys/personality.h>
9436 main ()
9438 personality (PER_LINUX32)
9440 return 0;
9442 _ACEOF
9443 if ac_fn_c_try_compile "$LINENO"; then :
9444 emacs_cv_personality_linux32=yes
9445 else
9446 emacs_cv_personality_linux32=no
9448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9450 $as_echo "$emacs_cv_personality_linux32" >&6; }
9452 if test $emacs_cv_personality_linux32 = yes; then
9454 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9458 for ac_header in term.h
9459 do :
9460 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9461 if test "x$ac_cv_header_term_h" = x""yes; then :
9462 cat >>confdefs.h <<_ACEOF
9463 #define HAVE_TERM_H 1
9464 _ACEOF
9468 done
9470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9471 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9472 if test "${ac_cv_header_time+set}" = set; then :
9473 $as_echo_n "(cached) " >&6
9474 else
9475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9476 /* end confdefs.h. */
9477 #include <sys/types.h>
9478 #include <sys/time.h>
9479 #include <time.h>
9482 main ()
9484 if ((struct tm *) 0)
9485 return 0;
9487 return 0;
9489 _ACEOF
9490 if ac_fn_c_try_compile "$LINENO"; then :
9491 ac_cv_header_time=yes
9492 else
9493 ac_cv_header_time=no
9495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9498 $as_echo "$ac_cv_header_time" >&6; }
9499 if test $ac_cv_header_time = yes; then
9501 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9505 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9508 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9509 ac_have_decl=1
9510 else
9511 ac_have_decl=0
9514 cat >>confdefs.h <<_ACEOF
9515 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9516 _ACEOF
9518 if test $ac_cv_have_decl_sys_siglist != yes; then
9519 # For Tru64, at least:
9520 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9523 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9524 ac_have_decl=1
9525 else
9526 ac_have_decl=0
9529 cat >>confdefs.h <<_ACEOF
9530 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9531 _ACEOF
9534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9535 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9536 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
9537 $as_echo_n "(cached) " >&6
9538 else
9539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9540 /* end confdefs.h. */
9541 #include <sys/types.h>
9542 #include <sys/wait.h>
9543 #ifndef WEXITSTATUS
9544 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9545 #endif
9546 #ifndef WIFEXITED
9547 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9548 #endif
9551 main ()
9553 int s;
9554 wait (&s);
9555 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9557 return 0;
9559 _ACEOF
9560 if ac_fn_c_try_compile "$LINENO"; then :
9561 ac_cv_header_sys_wait_h=yes
9562 else
9563 ac_cv_header_sys_wait_h=no
9565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9568 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9569 if test $ac_cv_header_sys_wait_h = yes; then
9571 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9579 for ac_header in net/if.h
9580 do :
9581 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9582 #if HAVE_SYS_SOCKET_H
9583 #include <sys/socket.h>
9584 #endif
9586 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9587 cat >>confdefs.h <<_ACEOF
9588 #define HAVE_NET_IF_H 1
9589 _ACEOF
9593 done
9595 for ac_header in ifaddrs.h
9596 do :
9597 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9598 #if HAVE_SYS_SOCKET_H
9599 #include <sys/socket.h>
9600 #endif
9602 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9603 cat >>confdefs.h <<_ACEOF
9604 #define HAVE_IFADDRS_H 1
9605 _ACEOF
9609 done
9611 for ac_header in net/if_dl.h
9612 do :
9613 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9614 #if HAVE_SYS_SOCKET_H
9615 #include <sys/socket.h>
9616 #endif
9618 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9619 cat >>confdefs.h <<_ACEOF
9620 #define HAVE_NET_IF_DL_H 1
9621 _ACEOF
9625 done
9628 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9629 #if HAVE_SYS_SOCKET_H
9630 #include <sys/socket.h>
9631 #endif
9632 #if HAVE_NET_IF_H
9633 #include <net/if.h>
9634 #endif
9636 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9638 cat >>confdefs.h <<_ACEOF
9639 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9640 _ACEOF
9644 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9645 #if HAVE_SYS_SOCKET_H
9646 #include <sys/socket.h>
9647 #endif
9648 #if HAVE_NET_IF_H
9649 #include <net/if.h>
9650 #endif
9652 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9654 cat >>confdefs.h <<_ACEOF
9655 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9656 _ACEOF
9660 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9661 #if HAVE_SYS_SOCKET_H
9662 #include <sys/socket.h>
9663 #endif
9664 #if HAVE_NET_IF_H
9665 #include <net/if.h>
9666 #endif
9668 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9670 cat >>confdefs.h <<_ACEOF
9671 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9672 _ACEOF
9676 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9677 #if HAVE_SYS_SOCKET_H
9678 #include <sys/socket.h>
9679 #endif
9680 #if HAVE_NET_IF_H
9681 #include <net/if.h>
9682 #endif
9684 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9686 cat >>confdefs.h <<_ACEOF
9687 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9688 _ACEOF
9692 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9693 #if HAVE_SYS_SOCKET_H
9694 #include <sys/socket.h>
9695 #endif
9696 #if HAVE_NET_IF_H
9697 #include <net/if.h>
9698 #endif
9700 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9702 cat >>confdefs.h <<_ACEOF
9703 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9704 _ACEOF
9708 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9709 #if HAVE_SYS_SOCKET_H
9710 #include <sys/socket.h>
9711 #endif
9712 #if HAVE_NET_IF_H
9713 #include <net/if.h>
9714 #endif
9716 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9718 cat >>confdefs.h <<_ACEOF
9719 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9720 _ACEOF
9728 DEPFLAGS=
9729 MKDEPDIR=":"
9730 deps_frag=deps.mk
9731 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9733 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9734 HAVE_GNU_MAKE=no
9735 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9736 if test "x$testval" != x; then
9737 HAVE_GNU_MAKE=yes
9738 else
9739 ac_enable_autodepend=no
9741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9742 $as_echo "$HAVE_GNU_MAKE" >&6; }
9743 if test $HAVE_GNU_MAKE = yes; then
9744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9745 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9746 SAVE_CFLAGS="$CFLAGS"
9747 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9749 /* end confdefs.h. */
9752 main ()
9756 return 0;
9758 _ACEOF
9759 if ac_fn_c_try_compile "$LINENO"; then :
9761 else
9762 ac_enable_autodepend=no
9764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9765 CFLAGS="$SAVE_CFLAGS"
9766 test -f deps.d || ac_enable_autodepend=no
9767 rm -rf deps.d
9768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9769 $as_echo "$ac_enable_autodepend" >&6; }
9771 if test $ac_enable_autodepend = yes; then
9772 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9773 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9774 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9775 deps_frag=autodeps.mk
9778 deps_frag=$srcdir/src/$deps_frag
9784 lisp_frag=$srcdir/src/lisp.mk
9788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9789 $as_echo_n "checking for long file names... " >&6; }
9790 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9791 $as_echo_n "(cached) " >&6
9792 else
9793 ac_cv_sys_long_file_names=yes
9794 # Test for long file names in all the places we know might matter:
9795 # . the current directory, where building will happen
9796 # $prefix/lib where we will be installing things
9797 # $exec_prefix/lib likewise
9798 # $TMPDIR if set, where it might want to write temporary files
9799 # /tmp where it might want to write temporary files
9800 # /var/tmp likewise
9801 # /usr/tmp likewise
9802 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9803 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9804 # in the usual case where exec_prefix is '${prefix}'.
9805 case $ac_dir in #(
9806 . | /* | ?:[\\/]*) ;; #(
9807 *) continue;;
9808 esac
9809 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9810 ac_xdir=$ac_dir/cf$$
9811 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9812 ac_tf1=$ac_xdir/conftest9012345
9813 ac_tf2=$ac_xdir/conftest9012346
9814 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9815 ac_cv_sys_long_file_names=no
9816 rm -f -r "$ac_xdir" 2>/dev/null
9817 test $ac_cv_sys_long_file_names = no && break
9818 done
9820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9821 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9822 if test $ac_cv_sys_long_file_names = yes; then
9824 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9829 #### Choose a window system.
9831 ## We leave window_system equal to none if
9832 ## we end up building without one. Any new window system should
9833 ## set window_system to an appropriate value and add objects to
9834 ## window-system-specific substs.
9836 window_system=none
9837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9838 $as_echo_n "checking for X... " >&6; }
9841 # Check whether --with-x was given.
9842 if test "${with_x+set}" = set; then :
9843 withval=$with_x;
9846 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9847 if test "x$with_x" = xno; then
9848 # The user explicitly disabled X.
9849 have_x=disabled
9850 else
9851 case $x_includes,$x_libraries in #(
9852 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9853 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9854 $as_echo_n "(cached) " >&6
9855 else
9856 # One or both of the vars are not set, and there is no cached value.
9857 ac_x_includes=no ac_x_libraries=no
9858 rm -f -r conftest.dir
9859 if mkdir conftest.dir; then
9860 cd conftest.dir
9861 cat >Imakefile <<'_ACEOF'
9862 incroot:
9863 @echo incroot='${INCROOT}'
9864 usrlibdir:
9865 @echo usrlibdir='${USRLIBDIR}'
9866 libdir:
9867 @echo libdir='${LIBDIR}'
9868 _ACEOF
9869 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9870 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9871 for ac_var in incroot usrlibdir libdir; do
9872 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9873 done
9874 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9875 for ac_extension in a so sl dylib la dll; do
9876 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9877 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9878 ac_im_usrlibdir=$ac_im_libdir; break
9880 done
9881 # Screen out bogus values from the imake configuration. They are
9882 # bogus both because they are the default anyway, and because
9883 # using them would break gcc on systems where it needs fixed includes.
9884 case $ac_im_incroot in
9885 /usr/include) ac_x_includes= ;;
9886 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9887 esac
9888 case $ac_im_usrlibdir in
9889 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9890 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9891 esac
9893 cd ..
9894 rm -f -r conftest.dir
9897 # Standard set of common directories for X headers.
9898 # Check X11 before X11Rn because it is often a symlink to the current release.
9899 ac_x_header_dirs='
9900 /usr/X11/include
9901 /usr/X11R7/include
9902 /usr/X11R6/include
9903 /usr/X11R5/include
9904 /usr/X11R4/include
9906 /usr/include/X11
9907 /usr/include/X11R7
9908 /usr/include/X11R6
9909 /usr/include/X11R5
9910 /usr/include/X11R4
9912 /usr/local/X11/include
9913 /usr/local/X11R7/include
9914 /usr/local/X11R6/include
9915 /usr/local/X11R5/include
9916 /usr/local/X11R4/include
9918 /usr/local/include/X11
9919 /usr/local/include/X11R7
9920 /usr/local/include/X11R6
9921 /usr/local/include/X11R5
9922 /usr/local/include/X11R4
9924 /usr/X386/include
9925 /usr/x386/include
9926 /usr/XFree86/include/X11
9928 /usr/include
9929 /usr/local/include
9930 /usr/unsupported/include
9931 /usr/athena/include
9932 /usr/local/x11r5/include
9933 /usr/lpp/Xamples/include
9935 /usr/openwin/include
9936 /usr/openwin/share/include'
9938 if test "$ac_x_includes" = no; then
9939 # Guess where to find include files, by looking for Xlib.h.
9940 # First, try using that file with no special directory specified.
9941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9942 /* end confdefs.h. */
9943 #include <X11/Xlib.h>
9944 _ACEOF
9945 if ac_fn_c_try_cpp "$LINENO"; then :
9946 # We can compile using X headers with no special include directory.
9947 ac_x_includes=
9948 else
9949 for ac_dir in $ac_x_header_dirs; do
9950 if test -r "$ac_dir/X11/Xlib.h"; then
9951 ac_x_includes=$ac_dir
9952 break
9954 done
9956 rm -f conftest.err conftest.$ac_ext
9957 fi # $ac_x_includes = no
9959 if test "$ac_x_libraries" = no; then
9960 # Check for the libraries.
9961 # See if we find them without any special options.
9962 # Don't add to $LIBS permanently.
9963 ac_save_LIBS=$LIBS
9964 LIBS="-lX11 $LIBS"
9965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9966 /* end confdefs.h. */
9967 #include <X11/Xlib.h>
9969 main ()
9971 XrmInitialize ()
9973 return 0;
9975 _ACEOF
9976 if ac_fn_c_try_link "$LINENO"; then :
9977 LIBS=$ac_save_LIBS
9978 # We can link X programs with no special library path.
9979 ac_x_libraries=
9980 else
9981 LIBS=$ac_save_LIBS
9982 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9984 # Don't even attempt the hair of trying to link an X program!
9985 for ac_extension in a so sl dylib la dll; do
9986 if test -r "$ac_dir/libX11.$ac_extension"; then
9987 ac_x_libraries=$ac_dir
9988 break 2
9990 done
9991 done
9993 rm -f core conftest.err conftest.$ac_objext \
9994 conftest$ac_exeext conftest.$ac_ext
9995 fi # $ac_x_libraries = no
9997 case $ac_x_includes,$ac_x_libraries in #(
9998 no,* | *,no | *\'*)
9999 # Didn't find X, or a directory has "'" in its name.
10000 ac_cv_have_x="have_x=no";; #(
10002 # Record where we found X for the cache.
10003 ac_cv_have_x="have_x=yes\
10004 ac_x_includes='$ac_x_includes'\
10005 ac_x_libraries='$ac_x_libraries'"
10006 esac
10008 ;; #(
10009 *) have_x=yes;;
10010 esac
10011 eval "$ac_cv_have_x"
10012 fi # $with_x != no
10014 if test "$have_x" != yes; then
10015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
10016 $as_echo "$have_x" >&6; }
10017 no_x=yes
10018 else
10019 # If each of the values was on the command line, it overrides each guess.
10020 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
10021 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
10022 # Update the cache value to reflect the command line values.
10023 ac_cv_have_x="have_x=yes\
10024 ac_x_includes='$x_includes'\
10025 ac_x_libraries='$x_libraries'"
10026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
10027 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
10030 if test "$no_x" != yes; then
10031 window_system=x11
10034 LD_SWITCH_X_SITE_RPATH=
10035 if test "${x_libraries}" != NONE; then
10036 if test -n "${x_libraries}"; then
10037 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
10038 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
10040 x_default_search_path=""
10041 x_search_path=${x_libraries}
10042 if test -z "${x_search_path}"; then
10043 x_search_path=/usr/lib
10045 for x_library in `echo ${x_search_path}: | \
10046 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
10047 x_search_path="\
10048 ${x_library}/X11/%L/%T/%N%C%S:\
10049 ${x_library}/X11/%l/%T/%N%C%S:\
10050 ${x_library}/X11/%T/%N%C%S:\
10051 ${x_library}/X11/%L/%T/%N%S:\
10052 ${x_library}/X11/%l/%T/%N%S:\
10053 ${x_library}/X11/%T/%N%S"
10054 if test x"${x_default_search_path}" = x; then
10055 x_default_search_path=${x_search_path}
10056 else
10057 x_default_search_path="${x_search_path}:${x_default_search_path}"
10059 done
10063 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
10064 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
10067 if test x"${x_includes}" = x; then
10068 bitmapdir=/usr/include/X11/bitmaps
10069 else
10070 # accumulate include directories that have X11 bitmap subdirectories
10071 bmd_acc="dummyval"
10072 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
10073 if test -d "${bmd}/X11/bitmaps"; then
10074 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
10076 if test -d "${bmd}/bitmaps"; then
10077 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
10079 done
10080 if test ${bmd_acc} != "dummyval"; then
10081 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
10085 HAVE_NS=no
10086 NS_IMPL_COCOA=no
10087 NS_IMPL_GNUSTEP=no
10088 tmp_CPPFLAGS="$CPPFLAGS"
10089 tmp_CFLAGS="$CFLAGS"
10090 CPPFLAGS="$CPPFLAGS -x objective-c"
10091 CFLAGS="$CFLAGS -x objective-c"
10092 GNU_OBJC_CFLAGS=
10093 LIBS_GNUSTEP=
10094 if test "${with_ns}" != no; then
10095 if test "${opsys}" = darwin; then
10096 NS_IMPL_COCOA=yes
10097 ns_appdir=`pwd`/nextstep/Emacs.app
10098 ns_appbindir=${ns_appdir}/Contents/MacOS
10099 ns_appresdir=${ns_appdir}/Contents/Resources
10100 ns_appsrc=Cocoa/Emacs.base
10101 elif test -f $GNUSTEP_CONFIG_FILE; then
10102 NS_IMPL_GNUSTEP=yes
10103 ns_appdir=`pwd`/nextstep/Emacs.app
10104 ns_appbindir=${ns_appdir}
10105 ns_appresdir=${ns_appdir}/Resources
10106 ns_appsrc=GNUstep/Emacs.base
10107 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
10108 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
10109 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
10110 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
10111 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
10112 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
10113 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
10114 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
10115 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10116 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10117 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
10118 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
10119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
10120 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
10121 if test "${emacs_cv_objc_exceptions+set}" = set; then :
10122 $as_echo_n "(cached) " >&6
10123 else
10124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10125 /* end confdefs.h. */
10126 #include <GNUstepBase/GSConfig.h>
10128 main ()
10130 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
10132 #else
10133 fail;
10134 #endif
10136 return 0;
10138 _ACEOF
10139 if ac_fn_c_try_compile "$LINENO"; then :
10140 emacs_cv_objc_exceptions=yes
10141 else
10142 emacs_cv_objc_exceptions=no
10144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
10147 $as_echo "$emacs_cv_objc_exceptions" >&6; }
10148 if test $emacs_cv_objc_exceptions = yes; then
10150 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
10152 GNU_OBJC_CFLAGS="-fobjc-exceptions"
10156 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
10158 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
10159 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
10160 HAVE_NS=yes
10161 else
10162 as_fn_error "\`--with-ns' was specified, but the include
10163 files are missing or cannot be compiled." "$LINENO" 5
10168 macfont_file=""
10169 if test "${NS_IMPL_COCOA}" = "yes"; then
10170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.4 or newer" >&5
10171 $as_echo_n "checking for OSX 10.4 or newer... " >&6; }
10172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10173 /* end confdefs.h. */
10174 #include <AppKit/AppKit.h>
10176 main ()
10179 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10180 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
10181 ; /* OK */
10182 #else
10183 #error "OSX 10.4 or newer required"
10184 #endif
10185 #endif
10188 return 0;
10190 _ACEOF
10191 if ac_fn_c_try_compile "$LINENO"; then :
10192 ns_osx_have_104=yes
10193 else
10194 ns_osx_have_104=no
10196 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_104" >&5
10198 $as_echo "$ns_osx_have_104" >&6; }
10200 if test $ns_osx_have_104 = no; then
10201 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 or newer" >&5
10204 $as_echo_n "checking for OSX 10.5 or newer... " >&6; }
10205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10206 /* end confdefs.h. */
10207 #include <AppKit/AppKit.h>
10209 main ()
10212 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10213 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
10214 ; /* OK */
10215 #else
10216 #error "OSX 10.5 not found"
10217 #endif
10218 #endif
10221 return 0;
10223 _ACEOF
10224 if ac_fn_c_try_compile "$LINENO"; then :
10225 ns_osx_have_105=yes
10226 else
10227 ns_osx_have_105=no
10229 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_105" >&5
10231 $as_echo "$ns_osx_have_105" >&6; }
10232 if test $ns_osx_have_105 = yes; then
10233 macfont_file="macfont.o"
10236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10237 /* end confdefs.h. */
10238 #include <Foundation/NSObjCRuntime.h>
10240 main ()
10242 NSInteger i;
10244 return 0;
10246 _ACEOF
10247 if ac_fn_c_try_compile "$LINENO"; then :
10248 ns_have_nsinteger=yes
10249 else
10250 ns_have_nsinteger=no
10252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10253 if test $ns_have_nsinteger = yes; then
10255 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10262 INSTALL_ARCH_INDEP_EXTRA=install-etc
10263 ns_self_contained=no
10264 NS_OBJ=
10265 NS_OBJC_OBJ=
10266 if test "${HAVE_NS}" = yes; then
10267 if test "$with_toolkit_scroll_bars" = "no"; then
10268 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10271 window_system=nextstep
10272 # set up packaging dirs
10273 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10274 ns_self_contained=yes
10275 prefix=${ns_appresdir}
10276 exec_prefix=${ns_appbindir}
10277 libexecdir="\${ns_appbindir}/libexec"
10278 archlibdir="\${ns_appbindir}/libexec"
10279 etcdocdir="\${ns_appresdir}/etc"
10280 etcdir="\${ns_appresdir}/etc"
10281 infodir="\${ns_appresdir}/info"
10282 mandir="\${ns_appresdir}/man"
10283 lispdir="\${ns_appresdir}/lisp"
10284 leimdir="\${ns_appresdir}/leim"
10285 INSTALL_ARCH_INDEP_EXTRA=
10288 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o $macfont_file"
10290 CFLAGS="$tmp_CFLAGS"
10291 CPPFLAGS="$tmp_CPPFLAGS"
10297 HAVE_W32=no
10298 W32_OBJ=
10299 W32_LIBS=
10300 EMACSRES=
10301 CLIENTRES=
10302 CLIENTW=
10303 W32_RES_LINK=
10304 EMACS_MANIFEST=
10305 UPDATE_MANIFEST=
10306 if test "${with_w32}" != no; then
10307 case "${opsys}" in
10308 cygwin)
10309 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10310 if test "x$ac_cv_header_windows_h" = x""yes; then :
10311 HAVE_W32=yes
10312 else
10313 as_fn_error "\`--with-w32' was specified, but windows.h
10314 cannot be found." "$LINENO" 5
10319 mingw32)
10320 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10323 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10325 esac
10328 if test "${opsys}" = "mingw32"; then
10329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10330 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10332 /* end confdefs.h. */
10334 #include <windows.h>
10335 #include <usp10.h>
10337 main ()
10339 PIMAGE_NT_HEADERS pHeader;
10340 PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader)
10342 return 0;
10344 _ACEOF
10345 if ac_fn_c_try_compile "$LINENO"; then :
10346 emacs_cv_w32api=yes
10347 HAVE_W32=yes
10348 else
10349 emacs_cv_w32api=no
10351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10353 $as_echo "$emacs_cv_w32api" >&6; }
10354 if test "${emacs_cv_w32api}" = "no"; then
10355 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10359 FIRSTFILE_OBJ=
10360 NTDIR=
10361 LIBS_ECLIENT=
10362 LIB_WSOCK32=
10363 NTLIB=
10364 CM_OBJ="cm.o"
10365 XARGS_LIMIT=
10366 if test "${HAVE_W32}" = "yes"; then
10368 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10370 if test -n "$ac_tool_prefix"; then
10371 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10372 set dummy ${ac_tool_prefix}windres; ac_word=$2
10373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10374 $as_echo_n "checking for $ac_word... " >&6; }
10375 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10376 $as_echo_n "(cached) " >&6
10377 else
10378 if test -n "$WINDRES"; then
10379 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10380 else
10381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10382 for as_dir in $PATH
10384 IFS=$as_save_IFS
10385 test -z "$as_dir" && as_dir=.
10386 for ac_exec_ext in '' $ac_executable_extensions; do
10387 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10388 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10390 break 2
10392 done
10393 done
10394 IFS=$as_save_IFS
10398 WINDRES=$ac_cv_prog_WINDRES
10399 if test -n "$WINDRES"; then
10400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10401 $as_echo "$WINDRES" >&6; }
10402 else
10403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10404 $as_echo "no" >&6; }
10409 if test -z "$ac_cv_prog_WINDRES"; then
10410 ac_ct_WINDRES=$WINDRES
10411 # Extract the first word of "windres", so it can be a program name with args.
10412 set dummy windres; ac_word=$2
10413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10414 $as_echo_n "checking for $ac_word... " >&6; }
10415 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10416 $as_echo_n "(cached) " >&6
10417 else
10418 if test -n "$ac_ct_WINDRES"; then
10419 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10420 else
10421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10422 for as_dir in $PATH
10424 IFS=$as_save_IFS
10425 test -z "$as_dir" && as_dir=.
10426 for ac_exec_ext in '' $ac_executable_extensions; do
10427 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10428 ac_cv_prog_ac_ct_WINDRES="windres"
10429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10430 break 2
10432 done
10433 done
10434 IFS=$as_save_IFS
10438 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10439 if test -n "$ac_ct_WINDRES"; then
10440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10441 $as_echo "$ac_ct_WINDRES" >&6; }
10442 else
10443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10444 $as_echo "no" >&6; }
10447 if test "x$ac_ct_WINDRES" = x; then
10448 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10449 else
10450 case $cross_compiling:$ac_tool_warned in
10451 yes:)
10452 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10453 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10454 ac_tool_warned=yes ;;
10455 esac
10456 WINDRES=$ac_ct_WINDRES
10458 else
10459 WINDRES="$ac_cv_prog_WINDRES"
10462 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10463 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10464 EMACSRES="emacs.res"
10465 case "$canonical" in
10466 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10467 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10468 esac
10469 UPDATE_MANIFEST=update-game-score.exe.manifest
10470 if test "${opsys}" = "cygwin"; then
10471 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10472 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10473 # Tell the linker that emacs.res is an object (which we compile from
10474 # the rc file), not a linker script.
10475 W32_RES_LINK="-Wl,emacs.res"
10476 else
10477 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10478 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10479 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10480 W32_RES_LINK="\$(EMACSRES)"
10481 CLIENTRES="emacsclient.res"
10482 CLIENTW="emacsclientw\$(EXEEXT)"
10483 FIRSTFILE_OBJ=firstfile.o
10484 NTDIR=nt
10485 CM_OBJ=
10486 LIBS_ECLIENT="-lcomctl32"
10487 LIB_WSOCK32="-lwsock32"
10488 NTLIB="ntlib.$ac_objext"
10489 XARGS_LIMIT="-s 10000"
10508 if test "${HAVE_W32}" = "yes"; then
10509 window_system=w32
10510 with_xft=no
10513 ## $window_system is now set to the window system we will
10514 ## ultimately use.
10516 if test "$window_system" = none && test "$gl_gcc_warnings" = yes; then
10517 # Too many warnings for now.
10519 nw="$nw -Wsuggest-attribute=const"
10520 nw="$nw -Wsuggest-attribute=noreturn"
10522 gl_warn_set=
10523 set x $WARN_CFLAGS; shift
10524 for gl_warn_item
10526 case " $nw " in
10527 *" $gl_warn_item "*)
10530 gl_warn_set="$gl_warn_set $gl_warn_item"
10532 esac
10533 done
10534 WARN_CFLAGS=$gl_warn_set
10538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-variable" >&5
10539 $as_echo_n "checking whether C compiler handles -Wno-unused-variable... " >&6; }
10540 if test "${gl_cv_warn_c__Wno_unused_variable+set}" = set; then :
10541 $as_echo_n "(cached) " >&6
10542 else
10544 gl_save_compiler_FLAGS="$CFLAGS"
10545 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-variable"
10546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10547 /* end confdefs.h. */
10550 main ()
10554 return 0;
10556 _ACEOF
10557 if ac_fn_c_try_compile "$LINENO"; then :
10558 gl_cv_warn_c__Wno_unused_variable=yes
10559 else
10560 gl_cv_warn_c__Wno_unused_variable=no
10562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10563 CFLAGS="$gl_save_compiler_FLAGS"
10566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_variable" >&5
10567 $as_echo "$gl_cv_warn_c__Wno_unused_variable" >&6; }
10568 if test "x$gl_cv_warn_c__Wno_unused_variable" = x""yes; then :
10569 as_fn_append WARN_CFLAGS " -Wno-unused-variable"
10574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-variable" >&5
10575 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-variable... " >&6; }
10576 if test "${gl_cv_warn_c__Wno_unused_but_set_variable+set}" = set; then :
10577 $as_echo_n "(cached) " >&6
10578 else
10580 gl_save_compiler_FLAGS="$CFLAGS"
10581 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-variable"
10582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10583 /* end confdefs.h. */
10586 main ()
10590 return 0;
10592 _ACEOF
10593 if ac_fn_c_try_compile "$LINENO"; then :
10594 gl_cv_warn_c__Wno_unused_but_set_variable=yes
10595 else
10596 gl_cv_warn_c__Wno_unused_but_set_variable=no
10598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10599 CFLAGS="$gl_save_compiler_FLAGS"
10602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_variable" >&5
10603 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_variable" >&6; }
10604 if test "x$gl_cv_warn_c__Wno_unused_but_set_variable" = x""yes; then :
10605 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-variable"
10610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-parameter" >&5
10611 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-parameter... " >&6; }
10612 if test "${gl_cv_warn_c__Wno_unused_but_set_parameter+set}" = set; then :
10613 $as_echo_n "(cached) " >&6
10614 else
10616 gl_save_compiler_FLAGS="$CFLAGS"
10617 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-parameter"
10618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10619 /* end confdefs.h. */
10622 main ()
10626 return 0;
10628 _ACEOF
10629 if ac_fn_c_try_compile "$LINENO"; then :
10630 gl_cv_warn_c__Wno_unused_but_set_parameter=yes
10631 else
10632 gl_cv_warn_c__Wno_unused_but_set_parameter=no
10634 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10635 CFLAGS="$gl_save_compiler_FLAGS"
10638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_parameter" >&5
10639 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_parameter" >&6; }
10640 if test "x$gl_cv_warn_c__Wno_unused_but_set_parameter" = x""yes; then :
10641 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-parameter"
10647 term_header=
10648 HAVE_X_WINDOWS=no
10649 HAVE_X11=no
10650 USE_X_TOOLKIT=none
10652 case "${window_system}" in
10653 x11 )
10654 HAVE_X_WINDOWS=yes
10655 HAVE_X11=yes
10656 term_header=xterm.h
10657 case "${with_x_toolkit}" in
10658 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10659 motif ) USE_X_TOOLKIT=MOTIF ;;
10660 gtk ) with_gtk=yes
10661 term_header=gtkutil.h
10662 USE_X_TOOLKIT=none ;;
10663 gtk2 ) with_gtk2=yes
10664 term_header=gtkutil.h
10665 USE_X_TOOLKIT=none ;;
10666 gtk3 ) with_gtk3=yes
10667 term_header=gtkutil.h
10668 USE_X_TOOLKIT=none ;;
10669 no ) USE_X_TOOLKIT=none ;;
10670 * ) USE_X_TOOLKIT=maybe ;;
10671 esac
10673 nextstep )
10674 term_header=nsterm.h
10676 w32 )
10677 term_header=w32term.h
10679 esac
10681 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10682 # Extract the first word of "X", so it can be a program name with args.
10683 set dummy X; ac_word=$2
10684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10685 $as_echo_n "checking for $ac_word... " >&6; }
10686 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10687 $as_echo_n "(cached) " >&6
10688 else
10689 if test -n "$HAVE_XSERVER"; then
10690 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10691 else
10692 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10693 for as_dir in $PATH
10695 IFS=$as_save_IFS
10696 test -z "$as_dir" && as_dir=.
10697 for ac_exec_ext in '' $ac_executable_extensions; do
10698 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10699 ac_cv_prog_HAVE_XSERVER="true"
10700 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10701 break 2
10703 done
10704 done
10705 IFS=$as_save_IFS
10707 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10710 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10711 if test -n "$HAVE_XSERVER"; then
10712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10713 $as_echo "$HAVE_XSERVER" >&6; }
10714 else
10715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10716 $as_echo "no" >&6; }
10720 if test "$HAVE_XSERVER" = true ||
10721 test -n "$DISPLAY" ||
10722 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10723 as_fn_error "You seem to be running X, but no X development libraries
10724 were found. You should install the relevant development files for X
10725 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10726 sure you have development files for image handling, i.e.
10727 tiff, gif, jpeg, png and xpm.
10728 If you are sure you want Emacs compiled without X window support, pass
10729 --without-x
10730 to configure." "$LINENO" 5
10734 ### If we're using X11, we should use the X menu package.
10735 HAVE_MENUS=no
10736 case ${HAVE_X11} in
10737 yes ) HAVE_MENUS=yes ;;
10738 esac
10740 # Does the opsystem file prohibit the use of the GNU malloc?
10741 # Assume not, until told otherwise.
10742 GNU_MALLOC=yes
10744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10745 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10746 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10747 $as_echo_n "(cached) " >&6
10748 else
10749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10750 /* end confdefs.h. */
10751 #include <malloc.h>
10752 static void hook (void) {}
10754 main ()
10756 malloc_set_state (malloc_get_state ());
10757 __after_morecore_hook = hook;
10758 __malloc_initialize_hook = hook;
10760 return 0;
10762 _ACEOF
10763 if ac_fn_c_try_link "$LINENO"; then :
10764 emacs_cv_var_doug_lea_malloc=yes
10765 else
10766 emacs_cv_var_doug_lea_malloc=no
10768 rm -f core conftest.err conftest.$ac_objext \
10769 conftest$ac_exeext conftest.$ac_ext
10771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10772 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10773 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10776 system_malloc=no
10777 case "$opsys" in
10778 ## darwin ld insists on the use of malloc routines in the System framework.
10779 darwin|sol2-10) system_malloc=yes ;;
10780 esac
10782 if test "${system_malloc}" = "yes"; then
10784 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10786 GNU_MALLOC=no
10787 GNU_MALLOC_reason="
10788 (The GNU allocators don't work with this system configuration.)"
10789 GMALLOC_OBJ=
10790 VMLIMIT_OBJ=
10791 else
10792 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10793 VMLIMIT_OBJ=vm-limit.o
10795 for ac_header in sys/vlimit.h
10796 do :
10797 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10798 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10799 cat >>confdefs.h <<_ACEOF
10800 #define HAVE_SYS_VLIMIT_H 1
10801 _ACEOF
10805 done
10807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10808 $as_echo_n "checking for data_start... " >&6; }
10809 if test "${emacs_cv_data_start+set}" = set; then :
10810 $as_echo_n "(cached) " >&6
10811 else
10812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10813 /* end confdefs.h. */
10814 extern char data_start[]; char ch;
10816 main ()
10818 return data_start < &ch;
10820 return 0;
10822 _ACEOF
10823 if ac_fn_c_try_link "$LINENO"; then :
10824 emacs_cv_data_start=yes
10825 else
10826 emacs_cv_data_start=no
10828 rm -f core conftest.err conftest.$ac_objext \
10829 conftest$ac_exeext conftest.$ac_ext
10831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10832 $as_echo "$emacs_cv_data_start" >&6; }
10833 if test $emacs_cv_data_start = yes; then
10835 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10842 if test "$doug_lea_malloc" = "yes" ; then
10843 if test "$GNU_MALLOC" = yes ; then
10844 GNU_MALLOC_reason="
10845 (Using Doug Lea's new malloc from the GNU C Library.)"
10848 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10851 ## Use mmap directly for allocating larger buffers.
10852 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10853 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10854 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10855 case "$opsys" in
10856 gnu*) REL_ALLOC=no ;;
10857 esac
10860 if test x"${REL_ALLOC}" = x; then
10861 REL_ALLOC=${GNU_MALLOC}
10864 use_mmap_for_buffers=no
10865 case "$opsys" in
10866 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10867 esac
10876 for ac_func in getpagesize
10877 do :
10878 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10879 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10880 cat >>confdefs.h <<_ACEOF
10881 #define HAVE_GETPAGESIZE 1
10882 _ACEOF
10885 done
10887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10888 $as_echo_n "checking for working mmap... " >&6; }
10889 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10890 $as_echo_n "(cached) " >&6
10891 else
10892 if test "$cross_compiling" = yes; then :
10893 ac_cv_func_mmap_fixed_mapped=no
10894 else
10895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10896 /* end confdefs.h. */
10897 $ac_includes_default
10898 /* malloc might have been renamed as rpl_malloc. */
10899 #undef malloc
10901 /* Thanks to Mike Haertel and Jim Avera for this test.
10902 Here is a matrix of mmap possibilities:
10903 mmap private not fixed
10904 mmap private fixed at somewhere currently unmapped
10905 mmap private fixed at somewhere already mapped
10906 mmap shared not fixed
10907 mmap shared fixed at somewhere currently unmapped
10908 mmap shared fixed at somewhere already mapped
10909 For private mappings, we should verify that changes cannot be read()
10910 back from the file, nor mmap's back from the file at a different
10911 address. (There have been systems where private was not correctly
10912 implemented like the infamous i386 svr4.0, and systems where the
10913 VM page cache was not coherent with the file system buffer cache
10914 like early versions of FreeBSD and possibly contemporary NetBSD.)
10915 For shared mappings, we should conversely verify that changes get
10916 propagated back to all the places they're supposed to be.
10918 Grep wants private fixed already mapped.
10919 The main things grep needs to know about mmap are:
10920 * does it exist and is it safe to write into the mmap'd area
10921 * how to use it (BSD variants) */
10923 #include <fcntl.h>
10924 #include <sys/mman.h>
10926 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10927 char *malloc ();
10928 #endif
10930 /* This mess was copied from the GNU getpagesize.h. */
10931 #ifndef HAVE_GETPAGESIZE
10932 # ifdef _SC_PAGESIZE
10933 # define getpagesize() sysconf(_SC_PAGESIZE)
10934 # else /* no _SC_PAGESIZE */
10935 # ifdef HAVE_SYS_PARAM_H
10936 # include <sys/param.h>
10937 # ifdef EXEC_PAGESIZE
10938 # define getpagesize() EXEC_PAGESIZE
10939 # else /* no EXEC_PAGESIZE */
10940 # ifdef NBPG
10941 # define getpagesize() NBPG * CLSIZE
10942 # ifndef CLSIZE
10943 # define CLSIZE 1
10944 # endif /* no CLSIZE */
10945 # else /* no NBPG */
10946 # ifdef NBPC
10947 # define getpagesize() NBPC
10948 # else /* no NBPC */
10949 # ifdef PAGESIZE
10950 # define getpagesize() PAGESIZE
10951 # endif /* PAGESIZE */
10952 # endif /* no NBPC */
10953 # endif /* no NBPG */
10954 # endif /* no EXEC_PAGESIZE */
10955 # else /* no HAVE_SYS_PARAM_H */
10956 # define getpagesize() 8192 /* punt totally */
10957 # endif /* no HAVE_SYS_PARAM_H */
10958 # endif /* no _SC_PAGESIZE */
10960 #endif /* no HAVE_GETPAGESIZE */
10963 main ()
10965 char *data, *data2, *data3;
10966 const char *cdata2;
10967 int i, pagesize;
10968 int fd, fd2;
10970 pagesize = getpagesize ();
10972 /* First, make a file with some known garbage in it. */
10973 data = (char *) malloc (pagesize);
10974 if (!data)
10975 return 1;
10976 for (i = 0; i < pagesize; ++i)
10977 *(data + i) = rand ();
10978 umask (0);
10979 fd = creat ("conftest.mmap", 0600);
10980 if (fd < 0)
10981 return 2;
10982 if (write (fd, data, pagesize) != pagesize)
10983 return 3;
10984 close (fd);
10986 /* Next, check that the tail of a page is zero-filled. File must have
10987 non-zero length, otherwise we risk SIGBUS for entire page. */
10988 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10989 if (fd2 < 0)
10990 return 4;
10991 cdata2 = "";
10992 if (write (fd2, cdata2, 1) != 1)
10993 return 5;
10994 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10995 if (data2 == MAP_FAILED)
10996 return 6;
10997 for (i = 0; i < pagesize; ++i)
10998 if (*(data2 + i))
10999 return 7;
11000 close (fd2);
11001 if (munmap (data2, pagesize))
11002 return 8;
11004 /* Next, try to mmap the file at a fixed address which already has
11005 something else allocated at it. If we can, also make sure that
11006 we see the same garbage. */
11007 fd = open ("conftest.mmap", O_RDWR);
11008 if (fd < 0)
11009 return 9;
11010 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
11011 MAP_PRIVATE | MAP_FIXED, fd, 0L))
11012 return 10;
11013 for (i = 0; i < pagesize; ++i)
11014 if (*(data + i) != *(data2 + i))
11015 return 11;
11017 /* Finally, make sure that changes to the mapped area do not
11018 percolate back to the file as seen by read(). (This is a bug on
11019 some variants of i386 svr4.0.) */
11020 for (i = 0; i < pagesize; ++i)
11021 *(data2 + i) = *(data2 + i) + 1;
11022 data3 = (char *) malloc (pagesize);
11023 if (!data3)
11024 return 12;
11025 if (read (fd, data3, pagesize) != pagesize)
11026 return 13;
11027 for (i = 0; i < pagesize; ++i)
11028 if (*(data + i) != *(data3 + i))
11029 return 14;
11030 close (fd);
11031 return 0;
11033 _ACEOF
11034 if ac_fn_c_try_run "$LINENO"; then :
11035 ac_cv_func_mmap_fixed_mapped=yes
11036 else
11037 ac_cv_func_mmap_fixed_mapped=no
11039 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11040 conftest.$ac_objext conftest.beam conftest.$ac_ext
11044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
11045 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
11046 if test $ac_cv_func_mmap_fixed_mapped = yes; then
11048 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
11051 rm -f conftest.mmap conftest.txt
11053 if test $use_mmap_for_buffers = yes; then
11055 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
11057 REL_ALLOC=no
11060 LIBS="$LIBS_SYSTEM $LIBS"
11062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
11063 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
11064 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
11065 $as_echo_n "(cached) " >&6
11066 else
11067 ac_check_lib_save_LIBS=$LIBS
11068 LIBS="-ldnet $LIBS"
11069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11070 /* end confdefs.h. */
11072 /* Override any GCC internal prototype to avoid an error.
11073 Use char because int might match the return type of a GCC
11074 builtin and then its argument prototype would still apply. */
11075 #ifdef __cplusplus
11076 extern "C"
11077 #endif
11078 char dnet_ntoa ();
11080 main ()
11082 return dnet_ntoa ();
11084 return 0;
11086 _ACEOF
11087 if ac_fn_c_try_link "$LINENO"; then :
11088 ac_cv_lib_dnet_dnet_ntoa=yes
11089 else
11090 ac_cv_lib_dnet_dnet_ntoa=no
11092 rm -f core conftest.err conftest.$ac_objext \
11093 conftest$ac_exeext conftest.$ac_ext
11094 LIBS=$ac_check_lib_save_LIBS
11096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
11097 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
11098 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
11099 cat >>confdefs.h <<_ACEOF
11100 #define HAVE_LIBDNET 1
11101 _ACEOF
11103 LIBS="-ldnet $LIBS"
11108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
11109 $as_echo_n "checking for main in -lXbsd... " >&6; }
11110 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
11111 $as_echo_n "(cached) " >&6
11112 else
11113 ac_check_lib_save_LIBS=$LIBS
11114 LIBS="-lXbsd $LIBS"
11115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11116 /* end confdefs.h. */
11120 main ()
11122 return main ();
11124 return 0;
11126 _ACEOF
11127 if ac_fn_c_try_link "$LINENO"; then :
11128 ac_cv_lib_Xbsd_main=yes
11129 else
11130 ac_cv_lib_Xbsd_main=no
11132 rm -f core conftest.err conftest.$ac_objext \
11133 conftest$ac_exeext conftest.$ac_ext
11134 LIBS=$ac_check_lib_save_LIBS
11136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
11137 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
11138 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
11139 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
11143 LIB_PTHREAD=
11147 if test "$ac_cv_header_pthread_h"; then
11148 if test "$GMALLOC_OBJ" = gmalloc.o; then
11149 emacs_pthread_function=pthread_atfork
11150 else
11151 emacs_pthread_function=pthread_self
11153 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
11154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
11155 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
11156 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
11157 $as_echo_n "(cached) " >&6
11158 else
11159 ac_check_lib_save_LIBS=$LIBS
11160 LIBS="-lpthread $LIBS"
11161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11162 /* end confdefs.h. */
11164 /* Override any GCC internal prototype to avoid an error.
11165 Use char because int might match the return type of a GCC
11166 builtin and then its argument prototype would still apply. */
11167 #ifdef __cplusplus
11168 extern "C"
11169 #endif
11170 char $emacs_pthread_function ();
11172 main ()
11174 return $emacs_pthread_function ();
11176 return 0;
11178 _ACEOF
11179 if ac_fn_c_try_link "$LINENO"; then :
11180 eval "$as_ac_Lib=yes"
11181 else
11182 eval "$as_ac_Lib=no"
11184 rm -f core conftest.err conftest.$ac_objext \
11185 conftest$ac_exeext conftest.$ac_ext
11186 LIBS=$ac_check_lib_save_LIBS
11188 eval ac_res=\$$as_ac_Lib
11189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11190 $as_echo "$ac_res" >&6; }
11191 eval as_val=\$$as_ac_Lib
11192 if test "x$as_val" = x""yes; then :
11193 HAVE_PTHREAD=yes
11197 if test "$HAVE_PTHREAD" = yes; then
11198 case "${canonical}" in
11199 *-hpux*) ;;
11200 *) LIB_PTHREAD="-lpthread"
11201 LIBS="$LIB_PTHREAD $LIBS" ;;
11202 esac
11204 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
11209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
11210 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
11211 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
11212 $as_echo_n "(cached) " >&6
11213 else
11214 ac_check_lib_save_LIBS=$LIBS
11215 LIBS="-lpthreads $LIBS"
11216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11217 /* end confdefs.h. */
11219 /* Override any GCC internal prototype to avoid an error.
11220 Use char because int might match the return type of a GCC
11221 builtin and then its argument prototype would still apply. */
11222 #ifdef __cplusplus
11223 extern "C"
11224 #endif
11225 char cma_open ();
11227 main ()
11229 return cma_open ();
11231 return 0;
11233 _ACEOF
11234 if ac_fn_c_try_link "$LINENO"; then :
11235 ac_cv_lib_pthreads_cma_open=yes
11236 else
11237 ac_cv_lib_pthreads_cma_open=no
11239 rm -f core conftest.err conftest.$ac_objext \
11240 conftest$ac_exeext conftest.$ac_ext
11241 LIBS=$ac_check_lib_save_LIBS
11243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
11244 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
11245 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
11246 cat >>confdefs.h <<_ACEOF
11247 #define HAVE_LIBPTHREADS 1
11248 _ACEOF
11250 LIBS="-lpthreads $LIBS"
11255 ## Note: when using cpp in s/aix4.2.h, this definition depended on
11256 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
11257 ## the system file was sourced. Hence the value of LIBS_SYSTEM
11258 ## added to LIBS in configure would never contain the pthreads part,
11259 ## but the value used in Makefiles might. FIXME?
11261 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
11262 ## be harmless on older versions of X where it happens to exist.
11263 test "$opsys" = "aix4-2" && \
11264 test $ac_cv_lib_pthreads_cma_open = yes && \
11265 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
11268 case ${host_os} in
11269 aix*)
11270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
11271 $as_echo_n "checking for -bbigtoc option... " >&6; }
11272 if test "${gdb_cv_bigtoc+set}" = set; then :
11273 $as_echo_n "(cached) " >&6
11274 else
11276 case $GCC in
11277 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
11278 *) gdb_cv_bigtoc=-bbigtoc ;;
11279 esac
11281 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
11282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11283 /* end confdefs.h. */
11286 main ()
11288 int i;
11290 return 0;
11292 _ACEOF
11293 if ac_fn_c_try_link "$LINENO"; then :
11295 else
11296 gdb_cv_bigtoc=
11298 rm -f core conftest.err conftest.$ac_objext \
11299 conftest$ac_exeext conftest.$ac_ext
11302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
11303 $as_echo "$gdb_cv_bigtoc" >&6; }
11305 esac
11307 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
11308 # used for the tests that follow. We set them back to REAL_CFLAGS and
11309 # REAL_CPPFLAGS later on.
11311 REAL_CFLAGS="$CFLAGS"
11312 REAL_CPPFLAGS="$CPPFLAGS"
11314 if test "${HAVE_X11}" = "yes"; then
11315 DEFS="$C_SWITCH_X_SITE $DEFS"
11316 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
11317 LIBS="-lX11 $LIBS"
11318 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
11319 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
11321 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
11322 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
11323 # but it's more convenient here to set LD_RUN_PATH since this
11324 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
11325 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
11326 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
11327 export LD_RUN_PATH
11330 if test "${opsys}" = "gnu-linux"; then
11331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
11332 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
11333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11334 /* end confdefs.h. */
11337 main ()
11339 XOpenDisplay ("foo");
11341 return 0;
11343 _ACEOF
11344 if ac_fn_c_try_link "$LINENO"; then :
11345 xgnu_linux_first_failure=no
11346 else
11347 xgnu_linux_first_failure=yes
11349 rm -f core conftest.err conftest.$ac_objext \
11350 conftest$ac_exeext conftest.$ac_ext
11351 if test "${xgnu_linux_first_failure}" = "yes"; then
11352 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
11353 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
11354 OLD_CPPFLAGS="$CPPFLAGS"
11355 OLD_LIBS="$LIBS"
11356 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
11357 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
11358 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
11359 LIBS="$LIBS -b i486-linuxaout"
11360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11361 /* end confdefs.h. */
11364 main ()
11366 XOpenDisplay ("foo");
11368 return 0;
11370 _ACEOF
11371 if ac_fn_c_try_link "$LINENO"; then :
11372 xgnu_linux_second_failure=no
11373 else
11374 xgnu_linux_second_failure=yes
11376 rm -f core conftest.err conftest.$ac_objext \
11377 conftest$ac_exeext conftest.$ac_ext
11378 if test "${xgnu_linux_second_failure}" = "yes"; then
11379 # If we get the same failure with -b, there is no use adding -b.
11380 # So take it out. This plays safe.
11381 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11382 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11383 CPPFLAGS="$OLD_CPPFLAGS"
11384 LIBS="$OLD_LIBS"
11385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11386 $as_echo "no" >&6; }
11387 else
11388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11389 $as_echo "yes" >&6; }
11391 else
11392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11393 $as_echo "no" >&6; }
11397 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11398 # header files included from there.
11399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11400 $as_echo_n "checking for Xkb... " >&6; }
11401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11402 /* end confdefs.h. */
11403 #include <X11/Xlib.h>
11404 #include <X11/XKBlib.h>
11406 main ()
11408 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11410 return 0;
11412 _ACEOF
11413 if ac_fn_c_try_link "$LINENO"; then :
11414 emacs_xkb=yes
11415 else
11416 emacs_xkb=no
11418 rm -f core conftest.err conftest.$ac_objext \
11419 conftest$ac_exeext conftest.$ac_ext
11420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11421 $as_echo "$emacs_xkb" >&6; }
11422 if test $emacs_xkb = yes; then
11424 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11428 for ac_func in XrmSetDatabase XScreenResourceString \
11429 XScreenNumberOfScreen
11430 do :
11431 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11432 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11433 eval as_val=\$$as_ac_var
11434 if test "x$as_val" = x""yes; then :
11435 cat >>confdefs.h <<_ACEOF
11436 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11437 _ACEOF
11440 done
11444 if test "${window_system}" = "x11"; then
11445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11446 $as_echo_n "checking X11 version 6... " >&6; }
11447 if test "${emacs_cv_x11_version_6+set}" = set; then :
11448 $as_echo_n "(cached) " >&6
11449 else
11450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11451 /* end confdefs.h. */
11452 #include <X11/Xlib.h>
11454 main ()
11456 #if XlibSpecificationRelease < 6
11457 fail;
11458 #endif
11461 return 0;
11463 _ACEOF
11464 if ac_fn_c_try_link "$LINENO"; then :
11465 emacs_cv_x11_version_6=yes
11466 else
11467 emacs_cv_x11_version_6=no
11469 rm -f core conftest.err conftest.$ac_objext \
11470 conftest$ac_exeext conftest.$ac_ext
11473 if test $emacs_cv_x11_version_6 = yes; then
11474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11475 $as_echo "6 or newer" >&6; }
11477 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11480 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11482 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11483 ## XIM support.
11484 case "$opsys" in
11485 sol2-*) : ;;
11487 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11490 esac
11491 else
11492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11493 $as_echo "before 6" >&6; }
11498 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11499 HAVE_RSVG=no
11500 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11501 if test "${with_rsvg}" != "no"; then
11502 RSVG_REQUIRED=2.11.0
11503 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11506 succeeded=no
11508 if test "$PKG_CONFIG" = "no" ; then
11510 else
11511 PKG_CONFIG_MIN_VERSION=0.9.0
11512 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11514 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11516 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11517 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11518 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11519 edit_cflags="
11520 s,///*,/,g
11521 s/^/ /
11522 s/ -I/ $isystem/g
11523 s/^ //
11525 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11526 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11528 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11529 succeeded=yes
11530 else
11531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11532 $as_echo "no" >&6; }
11533 RSVG_CFLAGS=""
11534 RSVG_LIBS=""
11535 ## If we have a custom action on failure, don't print errors, but
11536 ## do set a variable so people can do so. Do it in a subshell
11537 ## to capture any diagnostics in invoking pkg-config.
11538 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11544 else
11545 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11546 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11550 if test $succeeded = yes; then
11551 HAVE_RSVG=yes
11552 else
11559 if test $HAVE_RSVG = yes; then
11561 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11563 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11564 LIBS="$RSVG_LIBS $LIBS"
11569 HAVE_IMAGEMAGICK=no
11570 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
11571 if test "${with_imagemagick}" != "no"; then
11572 ## 6.2.8 is the earliest version known to work, but earlier versions
11573 ## might work - let us know if you find one.
11574 ## 6.0.7 does not work. See bug#7955.
11575 ## 6.8.2 makes Emacs crash; see Bug#13867.
11576 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11578 succeeded=no
11580 if test "$PKG_CONFIG" = "no" ; then
11582 else
11583 PKG_CONFIG_MIN_VERSION=0.9.0
11584 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11586 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11588 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11589 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11590 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11591 edit_cflags="
11592 s,///*,/,g
11593 s/^/ /
11594 s/ -I/ $isystem/g
11595 s/^ //
11597 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11598 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11600 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11601 succeeded=yes
11602 else
11603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11604 $as_echo "no" >&6; }
11605 IMAGEMAGICK_CFLAGS=""
11606 IMAGEMAGICK_LIBS=""
11607 ## If we have a custom action on failure, don't print errors, but
11608 ## do set a variable so people can do so. Do it in a subshell
11609 ## to capture any diagnostics in invoking pkg-config.
11610 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11616 else
11617 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11618 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11622 if test $succeeded = yes; then
11623 HAVE_IMAGEMAGICK=yes
11624 else
11631 if test $HAVE_IMAGEMAGICK = yes; then
11633 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11635 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11636 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11637 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11638 do :
11639 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11640 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11641 eval as_val=\$$as_ac_var
11642 if test "x$as_val" = x""yes; then :
11643 cat >>confdefs.h <<_ACEOF
11644 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11645 _ACEOF
11648 done
11655 HAVE_GTK=no
11656 GTK_OBJ=
11657 gtk_term_header=$term_header
11658 check_gtk2=no
11659 gtk3_pkg_errors=
11660 if test "${opsys}" != "mingw32"; then
11661 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11662 GLIB_REQUIRED=2.28
11663 GTK_REQUIRED=3.0
11664 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11667 succeeded=no
11669 if test "$PKG_CONFIG" = "no" ; then
11670 pkg_check_gtk=no
11671 else
11672 PKG_CONFIG_MIN_VERSION=0.9.0
11673 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11675 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11677 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11678 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11679 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11680 edit_cflags="
11681 s,///*,/,g
11682 s/^/ /
11683 s/ -I/ $isystem/g
11684 s/^ //
11686 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11687 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11689 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11690 succeeded=yes
11691 else
11692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11693 $as_echo "no" >&6; }
11694 GTK_CFLAGS=""
11695 GTK_LIBS=""
11696 ## If we have a custom action on failure, don't print errors, but
11697 ## do set a variable so people can do so. Do it in a subshell
11698 ## to capture any diagnostics in invoking pkg-config.
11699 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11705 else
11706 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11707 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11711 if test $succeeded = yes; then
11712 pkg_check_gtk=yes
11713 else
11714 pkg_check_gtk=no
11717 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11718 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11720 if test "$pkg_check_gtk" = "yes"; then
11722 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11724 GTK_OBJ=emacsgtkfixed.o
11725 gtk_term_header=gtkutil.h
11726 USE_GTK_TOOLKIT="GTK3"
11727 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11728 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11729 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11731 else
11732 check_gtk2=yes
11733 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11737 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11738 GLIB_REQUIRED=2.10
11739 GTK_REQUIRED=2.10
11740 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11743 succeeded=no
11745 if test "$PKG_CONFIG" = "no" ; then
11746 pkg_check_gtk=no
11747 else
11748 PKG_CONFIG_MIN_VERSION=0.9.0
11749 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11751 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11753 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11754 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11755 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11756 edit_cflags="
11757 s,///*,/,g
11758 s/^/ /
11759 s/ -I/ $isystem/g
11760 s/^ //
11762 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11763 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11765 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11766 succeeded=yes
11767 else
11768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11769 $as_echo "no" >&6; }
11770 GTK_CFLAGS=""
11771 GTK_LIBS=""
11772 ## If we have a custom action on failure, don't print errors, but
11773 ## do set a variable so people can do so. Do it in a subshell
11774 ## to capture any diagnostics in invoking pkg-config.
11775 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11781 else
11782 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11783 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11787 if test $succeeded = yes; then
11788 pkg_check_gtk=yes
11789 else
11790 pkg_check_gtk=no
11793 if test "$pkg_check_gtk" = "no" &&
11794 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11795 then
11796 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11798 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11802 if test x"$pkg_check_gtk" = xyes; then
11806 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11807 CFLAGS="$CFLAGS $GTK_CFLAGS"
11808 LIBS="$GTK_LIBS $LIBS"
11809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GTK compiles" >&5
11810 $as_echo_n "checking whether GTK compiles... " >&6; }
11811 GTK_COMPILES=no
11812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11813 /* end confdefs.h. */
11814 /* Check the Gtk and Glib APIs. */
11815 #include <gtk/gtk.h>
11816 #include <glib-object.h>
11817 static void
11818 callback (GObject *go, GParamSpec *spec, gpointer user_data)
11822 main ()
11825 GtkSettings *gs = 0;
11826 /* Use G_CALLBACK to make sure function pointers can be cast to void *;
11827 strict C prohibits this. Use gtk_main_iteration to test that the
11828 libraries are there. */
11829 if (g_signal_handler_find (G_OBJECT (gs), G_SIGNAL_MATCH_FUNC,
11830 0, 0, 0, G_CALLBACK (callback), 0))
11831 gtk_main_iteration ();
11834 return 0;
11836 _ACEOF
11837 if ac_fn_c_try_link "$LINENO"; then :
11838 GTK_COMPILES=yes
11840 rm -f core conftest.err conftest.$ac_objext \
11841 conftest$ac_exeext conftest.$ac_ext
11842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_COMPILES" >&5
11843 $as_echo "$GTK_COMPILES" >&6; }
11844 if test "${GTK_COMPILES}" != "yes"; then
11845 GTK_OBJ=
11846 if test "$USE_X_TOOLKIT" != "maybe"; then
11847 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11849 else
11850 HAVE_GTK=yes
11852 $as_echo "#define USE_GTK 1" >>confdefs.h
11854 GTK_OBJ="gtkutil.o $GTK_OBJ"
11855 term_header=$gtk_term_header
11856 USE_X_TOOLKIT=none
11857 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11859 else
11860 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11861 closing open displays. This is no problem if you just use
11862 one display, but if you use more than one and close one of them
11863 Emacs may crash." >&5
11864 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11865 closing open displays. This is no problem if you just use
11866 one display, but if you use more than one and close one of them
11867 Emacs may crash." >&2;}
11868 sleep 3
11876 if test "${HAVE_GTK}" = "yes"; then
11878 if test "$with_toolkit_scroll_bars" != no; then
11879 with_toolkit_scroll_bars=yes
11882 HAVE_GTK_FILE_SELECTION=no
11883 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11884 #include <gtk/gtk.h>
11886 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11887 HAVE_GTK_FILE_SELECTION=yes
11888 else
11889 HAVE_GTK_FILE_SELECTION=no
11892 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11893 for ac_func in gtk_file_selection_new
11894 do :
11895 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11896 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11897 cat >>confdefs.h <<_ACEOF
11898 #define HAVE_GTK_FILE_SELECTION_NEW 1
11899 _ACEOF
11902 done
11906 HAVE_GTK_HANDLE_BOX=no
11907 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11908 #include <gtk/gtk.h>
11910 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11911 HAVE_GTK_HANDLE_BOX=yes
11912 else
11913 HAVE_GTK_HANDLE_BOX=no
11916 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11917 for ac_func in gtk_handle_box_new
11918 do :
11919 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11920 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11921 cat >>confdefs.h <<_ACEOF
11922 #define HAVE_GTK_HANDLE_BOX_NEW 1
11923 _ACEOF
11926 done
11930 HAVE_GTK_TEAROFF_MENU_ITEM=no
11931 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11932 #include <gtk/gtk.h>
11934 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11935 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11936 else
11937 HAVE_GTK_TEAROFF_MENU_ITEM=no
11940 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11941 for ac_func in gtk_tearoff_menu_item_new
11942 do :
11943 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11944 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11945 cat >>confdefs.h <<_ACEOF
11946 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11947 _ACEOF
11950 done
11954 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11955 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11956 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11957 gtk_orientable_set_orientation \
11958 gtk_window_set_has_resize_grip
11959 do :
11960 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11961 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11962 eval as_val=\$$as_ac_var
11963 if test "x$as_val" = x""yes; then :
11964 cat >>confdefs.h <<_ACEOF
11965 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11966 _ACEOF
11969 done
11972 term_header=gtkutil.h
11975 HAVE_DBUS=no
11976 DBUS_OBJ=
11977 if test "${with_dbus}" = "yes"; then
11979 succeeded=no
11981 if test "$PKG_CONFIG" = "no" ; then
11982 HAVE_DBUS=no
11983 else
11984 PKG_CONFIG_MIN_VERSION=0.9.0
11985 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11987 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11989 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11990 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11991 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11992 edit_cflags="
11993 s,///*,/,g
11994 s/^/ /
11995 s/ -I/ $isystem/g
11996 s/^ //
11998 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11999 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
12000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
12001 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
12002 succeeded=yes
12003 else
12004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12005 $as_echo "no" >&6; }
12006 DBUS_CFLAGS=""
12007 DBUS_LIBS=""
12008 ## If we have a custom action on failure, don't print errors, but
12009 ## do set a variable so people can do so. Do it in a subshell
12010 ## to capture any diagnostics in invoking pkg-config.
12011 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
12017 else
12018 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12019 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12023 if test $succeeded = yes; then
12024 HAVE_DBUS=yes
12025 else
12026 HAVE_DBUS=no
12029 if test "$HAVE_DBUS" = yes; then
12030 LIBS="$LIBS $DBUS_LIBS"
12032 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
12034 for ac_func in dbus_watch_get_unix_fd \
12035 dbus_type_is_valid \
12036 dbus_validate_bus_name \
12037 dbus_validate_path \
12038 dbus_validate_interface \
12039 dbus_validate_member
12040 do :
12041 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12042 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12043 eval as_val=\$$as_ac_var
12044 if test "x$as_val" = x""yes; then :
12045 cat >>confdefs.h <<_ACEOF
12046 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12047 _ACEOF
12050 done
12052 DBUS_OBJ=dbusbind.o
12057 HAVE_GSETTINGS=no
12058 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
12060 succeeded=no
12062 if test "$PKG_CONFIG" = "no" ; then
12063 HAVE_GSETTINGS=no
12064 else
12065 PKG_CONFIG_MIN_VERSION=0.9.0
12066 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
12068 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
12070 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
12071 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
12072 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
12073 edit_cflags="
12074 s,///*,/,g
12075 s/^/ /
12076 s/ -I/ $isystem/g
12077 s/^ //
12079 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
12080 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
12081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
12082 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
12083 succeeded=yes
12084 else
12085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12086 $as_echo "no" >&6; }
12087 GSETTINGS_CFLAGS=""
12088 GSETTINGS_LIBS=""
12089 ## If we have a custom action on failure, don't print errors, but
12090 ## do set a variable so people can do so. Do it in a subshell
12091 ## to capture any diagnostics in invoking pkg-config.
12092 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
12098 else
12099 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12100 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12104 if test $succeeded = yes; then
12105 HAVE_GSETTINGS=yes
12106 else
12107 HAVE_GSETTINGS=no
12110 if test "$HAVE_GSETTINGS" = "yes"; then
12112 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
12114 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
12115 SETTINGS_LIBS="$GSETTINGS_LIBS"
12119 HAVE_GCONF=no
12120 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
12122 succeeded=no
12124 if test "$PKG_CONFIG" = "no" ; then
12125 HAVE_GCONF=no
12126 else
12127 PKG_CONFIG_MIN_VERSION=0.9.0
12128 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
12130 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
12132 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
12133 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
12134 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
12135 edit_cflags="
12136 s,///*,/,g
12137 s/^/ /
12138 s/ -I/ $isystem/g
12139 s/^ //
12141 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
12142 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
12143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
12144 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
12145 succeeded=yes
12146 else
12147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12148 $as_echo "no" >&6; }
12149 GCONF_CFLAGS=""
12150 GCONF_LIBS=""
12151 ## If we have a custom action on failure, don't print errors, but
12152 ## do set a variable so people can do so. Do it in a subshell
12153 ## to capture any diagnostics in invoking pkg-config.
12154 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
12160 else
12161 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12162 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12166 if test $succeeded = yes; then
12167 HAVE_GCONF=yes
12168 else
12169 HAVE_GCONF=no
12172 if test "$HAVE_GCONF" = yes; then
12174 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
12176 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
12177 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
12181 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
12183 succeeded=no
12185 if test "$PKG_CONFIG" = "no" ; then
12186 HAVE_GOBJECT=no
12187 else
12188 PKG_CONFIG_MIN_VERSION=0.9.0
12189 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
12191 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
12193 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
12194 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
12195 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
12196 edit_cflags="
12197 s,///*,/,g
12198 s/^/ /
12199 s/ -I/ $isystem/g
12200 s/^ //
12202 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
12203 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
12204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
12205 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
12206 succeeded=yes
12207 else
12208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12209 $as_echo "no" >&6; }
12210 GOBJECT_CFLAGS=""
12211 GOBJECT_LIBS=""
12212 ## If we have a custom action on failure, don't print errors, but
12213 ## do set a variable so people can do so. Do it in a subshell
12214 ## to capture any diagnostics in invoking pkg-config.
12215 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
12221 else
12222 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12223 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12227 if test $succeeded = yes; then
12228 HAVE_GOBJECT=yes
12229 else
12230 HAVE_GOBJECT=no
12233 if test "$HAVE_GOBJECT" = "yes"; then
12234 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
12235 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
12237 SAVE_CFLAGS="$CFLAGS"
12238 SAVE_LIBS="$LIBS"
12239 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
12240 LIBS="$SETTINGS_LIBS $LIBS"
12241 CFLAGS="$SAVE_CFLAGS"
12242 LIBS="$SAVE_LIBS"
12248 HAVE_LIBSELINUX=no
12249 LIBSELINUX_LIBS=
12250 if test "${with_selinux}" = "yes"; then
12251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
12252 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
12253 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
12254 $as_echo_n "(cached) " >&6
12255 else
12256 ac_check_lib_save_LIBS=$LIBS
12257 LIBS="-lselinux $LIBS"
12258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12259 /* end confdefs.h. */
12261 /* Override any GCC internal prototype to avoid an error.
12262 Use char because int might match the return type of a GCC
12263 builtin and then its argument prototype would still apply. */
12264 #ifdef __cplusplus
12265 extern "C"
12266 #endif
12267 char lgetfilecon ();
12269 main ()
12271 return lgetfilecon ();
12273 return 0;
12275 _ACEOF
12276 if ac_fn_c_try_link "$LINENO"; then :
12277 ac_cv_lib_selinux_lgetfilecon=yes
12278 else
12279 ac_cv_lib_selinux_lgetfilecon=no
12281 rm -f core conftest.err conftest.$ac_objext \
12282 conftest$ac_exeext conftest.$ac_ext
12283 LIBS=$ac_check_lib_save_LIBS
12285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
12286 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
12287 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
12288 HAVE_LIBSELINUX=yes
12289 else
12290 HAVE_LIBSELINUX=no
12293 if test "$HAVE_LIBSELINUX" = yes; then
12295 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
12297 LIBSELINUX_LIBS=-lselinux
12302 HAVE_GNUTLS=no
12303 if test "${with_gnutls}" = "yes" ; then
12305 succeeded=no
12307 if test "$PKG_CONFIG" = "no" ; then
12308 HAVE_GNUTLS=no
12309 else
12310 PKG_CONFIG_MIN_VERSION=0.9.0
12311 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
12313 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
12315 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
12316 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
12317 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
12318 edit_cflags="
12319 s,///*,/,g
12320 s/^/ /
12321 s/ -I/ $isystem/g
12322 s/^ //
12324 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
12325 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
12326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
12327 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
12328 succeeded=yes
12329 else
12330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12331 $as_echo "no" >&6; }
12332 LIBGNUTLS_CFLAGS=""
12333 LIBGNUTLS_LIBS=""
12334 ## If we have a custom action on failure, don't print errors, but
12335 ## do set a variable so people can do so. Do it in a subshell
12336 ## to capture any diagnostics in invoking pkg-config.
12337 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
12343 else
12344 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12345 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12349 if test $succeeded = yes; then
12350 HAVE_GNUTLS=yes
12351 else
12352 HAVE_GNUTLS=no
12355 if test "${HAVE_GNUTLS}" = "yes"; then
12357 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
12361 # Windows loads GnuTLS dynamically
12362 if test "${opsys}" = "mingw32"; then
12363 LIBGNUTLS_LIBS=
12364 else
12365 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
12366 LIBS="$LIBGNUTLS_LIBS $LIBS"
12373 NOTIFY_OBJ=
12374 NOTIFY_SUMMARY=no
12376 if test "${with_ns}" = yes && test ${with_file_notification} = yes; then
12377 with_file_notification=no
12380 case $with_file_notification,$opsys in
12381 w32,* | yes,mingw32)
12382 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12383 if test "x$ac_cv_header_windows_h" = x""yes; then :
12388 if test "$ac_cv_header_windows_h" = yes ; then
12390 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12392 NOTIFY_OBJ=w32notify.o
12393 NOTIFY_SUMMARY="yes (w32)"
12394 fi ;;
12395 esac
12397 case $with_file_notification,$NOTIFY_OBJ in
12398 gfile, | yes,)
12400 succeeded=no
12402 if test "$PKG_CONFIG" = "no" ; then
12403 HAVE_GFILENOTIFY=no
12404 else
12405 PKG_CONFIG_MIN_VERSION=0.9.0
12406 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12408 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12410 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12411 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12412 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12413 edit_cflags="
12414 s,///*,/,g
12415 s/^/ /
12416 s/ -I/ $isystem/g
12417 s/^ //
12419 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12420 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12422 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12423 succeeded=yes
12424 else
12425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12426 $as_echo "no" >&6; }
12427 GFILENOTIFY_CFLAGS=""
12428 GFILENOTIFY_LIBS=""
12429 ## If we have a custom action on failure, don't print errors, but
12430 ## do set a variable so people can do so. Do it in a subshell
12431 ## to capture any diagnostics in invoking pkg-config.
12432 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12438 else
12439 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12440 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12444 if test $succeeded = yes; then
12445 HAVE_GFILENOTIFY=yes
12446 else
12447 HAVE_GFILENOTIFY=no
12450 if test "$HAVE_GFILENOTIFY" = "yes"; then
12452 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12454 NOTIFY_OBJ=gfilenotify.o
12455 NOTIFY_SUMMARY="yes -lgio (gfile)"
12456 fi ;;
12457 esac
12459 case $with_file_notification,$NOTIFY_OBJ in
12460 inotify, | yes,)
12461 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12462 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12467 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12468 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12469 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12473 if test "$ac_cv_func_inotify_init1" = yes; then
12475 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12477 NOTIFY_OBJ=inotify.o
12478 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12480 fi ;;
12481 esac
12483 case $with_file_notification,$NOTIFY_OBJ in
12484 yes,* | no,* | *,?*) ;;
12485 *) as_fn_error "File notification \`$with_file_notification' requested but requirements not found." "$LINENO" 5 ;;
12486 esac
12488 if test -n "$NOTIFY_OBJ"; then
12490 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12497 HAVE_XAW3D=no
12498 LUCID_LIBW=
12499 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12500 if test "$with_xaw3d" != no; then
12501 if test "${emacs_cv_xaw3d+set}" = set; then :
12502 $as_echo_n "(cached) " >&6
12503 else
12504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12505 /* end confdefs.h. */
12507 #include <X11/Intrinsic.h>
12508 #include <X11/Xaw3d/Simple.h>
12510 main ()
12514 return 0;
12516 _ACEOF
12517 if ac_fn_c_try_link "$LINENO"; then :
12518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12519 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12520 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12521 $as_echo_n "(cached) " >&6
12522 else
12523 ac_check_lib_save_LIBS=$LIBS
12524 LIBS="-lXaw3d $LIBS"
12525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12526 /* end confdefs.h. */
12528 /* Override any GCC internal prototype to avoid an error.
12529 Use char because int might match the return type of a GCC
12530 builtin and then its argument prototype would still apply. */
12531 #ifdef __cplusplus
12532 extern "C"
12533 #endif
12534 char XawScrollbarSetThumb ();
12536 main ()
12538 return XawScrollbarSetThumb ();
12540 return 0;
12542 _ACEOF
12543 if ac_fn_c_try_link "$LINENO"; then :
12544 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12545 else
12546 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12548 rm -f core conftest.err conftest.$ac_objext \
12549 conftest$ac_exeext conftest.$ac_ext
12550 LIBS=$ac_check_lib_save_LIBS
12552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12553 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12554 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12555 emacs_cv_xaw3d=yes
12556 else
12557 emacs_cv_xaw3d=no
12560 else
12561 emacs_cv_xaw3d=no
12563 rm -f core conftest.err conftest.$ac_objext \
12564 conftest$ac_exeext conftest.$ac_ext
12567 else
12568 emacs_cv_xaw3d=no
12570 if test $emacs_cv_xaw3d = yes; then
12571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12572 $as_echo_n "checking for xaw3d... " >&6; }
12573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12574 $as_echo "yes; using Lucid toolkit" >&6; }
12575 USE_X_TOOLKIT=LUCID
12576 HAVE_XAW3D=yes
12577 LUCID_LIBW=-lXaw3d
12579 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12581 else
12582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12583 $as_echo_n "checking for xaw3d... " >&6; }
12584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12585 $as_echo "no" >&6; }
12586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12587 $as_echo_n "checking for libXaw... " >&6; }
12588 if test "${emacs_cv_xaw+set}" = set; then :
12589 $as_echo_n "(cached) " >&6
12590 else
12591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12592 /* end confdefs.h. */
12594 #include <X11/Intrinsic.h>
12595 #include <X11/Xaw/Simple.h>
12597 main ()
12601 return 0;
12603 _ACEOF
12604 if ac_fn_c_try_link "$LINENO"; then :
12605 emacs_cv_xaw=yes
12606 else
12607 emacs_cv_xaw=no
12609 rm -f core conftest.err conftest.$ac_objext \
12610 conftest$ac_exeext conftest.$ac_ext
12613 if test $emacs_cv_xaw = yes; then
12614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12615 $as_echo "yes; using Lucid toolkit" >&6; }
12616 USE_X_TOOLKIT=LUCID
12617 LUCID_LIBW=-lXaw
12618 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12619 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12620 else
12621 as_fn_error "No X toolkit could be found.
12622 If you are sure you want Emacs compiled without an X toolkit, pass
12623 --with-x-toolkit=no
12624 to configure. Otherwise, install the development libraries for the toolkit
12625 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12630 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12632 LIBXTR6=
12633 if test "${USE_X_TOOLKIT}" != "none"; then
12634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12635 $as_echo_n "checking X11 toolkit version... " >&6; }
12636 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12637 $as_echo_n "(cached) " >&6
12638 else
12639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12640 /* end confdefs.h. */
12641 #include <X11/Intrinsic.h>
12643 main ()
12645 #if XtSpecificationRelease < 6
12646 fail;
12647 #endif
12650 return 0;
12652 _ACEOF
12653 if ac_fn_c_try_link "$LINENO"; then :
12654 emacs_cv_x11_toolkit_version_6=yes
12655 else
12656 emacs_cv_x11_toolkit_version_6=no
12658 rm -f core conftest.err conftest.$ac_objext \
12659 conftest$ac_exeext conftest.$ac_ext
12662 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12663 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12665 $as_echo "6 or newer" >&6; }
12667 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12669 LIBXTR6="-lSM -lICE"
12670 case "$opsys" in
12671 ## Use libw.a along with X11R6 Xt.
12672 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12673 esac
12674 else
12675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12676 $as_echo "before 6" >&6; }
12679 OLDLIBS="$LIBS"
12680 if test x$HAVE_X11XTR6 = xyes; then
12681 LIBS="-lXt -lSM -lICE $LIBS"
12682 else
12683 LIBS="-lXt $LIBS"
12685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12686 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12687 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12688 $as_echo_n "(cached) " >&6
12689 else
12690 ac_check_lib_save_LIBS=$LIBS
12691 LIBS="-lXmu $LIBS"
12692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12693 /* end confdefs.h. */
12695 /* Override any GCC internal prototype to avoid an error.
12696 Use char because int might match the return type of a GCC
12697 builtin and then its argument prototype would still apply. */
12698 #ifdef __cplusplus
12699 extern "C"
12700 #endif
12701 char XmuConvertStandardSelection ();
12703 main ()
12705 return XmuConvertStandardSelection ();
12707 return 0;
12709 _ACEOF
12710 if ac_fn_c_try_link "$LINENO"; then :
12711 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12712 else
12713 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12715 rm -f core conftest.err conftest.$ac_objext \
12716 conftest$ac_exeext conftest.$ac_ext
12717 LIBS=$ac_check_lib_save_LIBS
12719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12720 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12721 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12722 cat >>confdefs.h <<_ACEOF
12723 #define HAVE_LIBXMU 1
12724 _ACEOF
12726 LIBS="-lXmu $LIBS"
12730 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12734 LIBXMU=-lXmu
12735 case $opsys in
12736 ## These systems don't supply Xmu.
12737 hpux* | aix4-2 )
12738 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12740 mingw32 )
12741 LIBXMU=
12743 esac
12746 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12747 if test "${HAVE_X11}" = "yes"; then
12748 if test "${USE_X_TOOLKIT}" != "none"; then
12749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12750 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12751 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12752 $as_echo_n "(cached) " >&6
12753 else
12754 ac_check_lib_save_LIBS=$LIBS
12755 LIBS="-lXext $LIBS"
12756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12757 /* end confdefs.h. */
12759 /* Override any GCC internal prototype to avoid an error.
12760 Use char because int might match the return type of a GCC
12761 builtin and then its argument prototype would still apply. */
12762 #ifdef __cplusplus
12763 extern "C"
12764 #endif
12765 char XShapeQueryExtension ();
12767 main ()
12769 return XShapeQueryExtension ();
12771 return 0;
12773 _ACEOF
12774 if ac_fn_c_try_link "$LINENO"; then :
12775 ac_cv_lib_Xext_XShapeQueryExtension=yes
12776 else
12777 ac_cv_lib_Xext_XShapeQueryExtension=no
12779 rm -f core conftest.err conftest.$ac_objext \
12780 conftest$ac_exeext conftest.$ac_ext
12781 LIBS=$ac_check_lib_save_LIBS
12783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12784 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12785 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12786 cat >>confdefs.h <<_ACEOF
12787 #define HAVE_LIBXEXT 1
12788 _ACEOF
12790 LIBS="-lXext $LIBS"
12797 LIBXP=
12798 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12799 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12800 if test -d /usr/include/openmotif; then
12801 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12802 emacs_cv_openmotif=yes
12803 case "$canonical" in
12804 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12805 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12808 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12809 esac
12810 else
12811 emacs_cv_openmotif=no
12813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12814 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12815 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12816 $as_echo_n "(cached) " >&6
12817 else
12818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12819 /* end confdefs.h. */
12820 #include <Xm/Xm.h>
12822 main ()
12824 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12825 int x = 5;
12826 #else
12827 Motif version prior to 2.1.
12828 #endif
12830 return 0;
12832 _ACEOF
12833 if ac_fn_c_try_compile "$LINENO"; then :
12834 emacs_cv_motif_version_2_1=yes
12835 else
12836 emacs_cv_motif_version_2_1=no
12838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12841 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12842 if test $emacs_cv_motif_version_2_1 = yes; then
12843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12844 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12845 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12846 $as_echo_n "(cached) " >&6
12847 else
12848 ac_check_lib_save_LIBS=$LIBS
12849 LIBS="-lXp $LIBS"
12850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12851 /* end confdefs.h. */
12853 /* Override any GCC internal prototype to avoid an error.
12854 Use char because int might match the return type of a GCC
12855 builtin and then its argument prototype would still apply. */
12856 #ifdef __cplusplus
12857 extern "C"
12858 #endif
12859 char XpCreateContext ();
12861 main ()
12863 return XpCreateContext ();
12865 return 0;
12867 _ACEOF
12868 if ac_fn_c_try_link "$LINENO"; then :
12869 ac_cv_lib_Xp_XpCreateContext=yes
12870 else
12871 ac_cv_lib_Xp_XpCreateContext=no
12873 rm -f core conftest.err conftest.$ac_objext \
12874 conftest$ac_exeext conftest.$ac_ext
12875 LIBS=$ac_check_lib_save_LIBS
12877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12878 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12879 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12880 LIBXP=-lXp
12883 if test x$emacs_cv_openmotif = xyes; then
12884 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12886 else
12887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12888 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12889 if test "${emacs_cv_lesstif+set}" = set; then :
12890 $as_echo_n "(cached) " >&6
12891 else
12892 # We put this in CFLAGS temporarily to precede other -I options
12893 # that might be in CFLAGS temporarily.
12894 # We put this in CPPFLAGS where it precedes the other -I options.
12895 OLD_CPPFLAGS=$CPPFLAGS
12896 OLD_CFLAGS=$CFLAGS
12897 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12898 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12900 /* end confdefs.h. */
12901 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12903 main ()
12905 int x = 5;
12907 return 0;
12909 _ACEOF
12910 if ac_fn_c_try_compile "$LINENO"; then :
12911 emacs_cv_lesstif=yes
12912 else
12913 emacs_cv_lesstif=no
12915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12918 $as_echo "$emacs_cv_lesstif" >&6; }
12919 if test $emacs_cv_lesstif = yes; then
12920 # Make sure this -I option remains in CPPFLAGS after it is set
12921 # back to REAL_CPPFLAGS.
12922 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12923 # have those other -I options anyway. Ultimately, having this
12924 # directory ultimately in CPPFLAGS will be enough.
12925 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12926 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12927 else
12928 CFLAGS=$OLD_CFLAGS
12929 CPPFLAGS=$OLD_CPPFLAGS
12932 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12933 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12935 else
12936 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12943 USE_TOOLKIT_SCROLL_BARS=no
12944 if test "${with_toolkit_scroll_bars}" != "no"; then
12945 if test "${USE_X_TOOLKIT}" != "none"; then
12946 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12947 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12949 HAVE_XAW3D=no
12950 USE_TOOLKIT_SCROLL_BARS=yes
12951 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12952 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12954 USE_TOOLKIT_SCROLL_BARS=yes
12956 elif test "${HAVE_GTK}" = "yes"; then
12957 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12959 USE_TOOLKIT_SCROLL_BARS=yes
12960 elif test "${HAVE_NS}" = "yes"; then
12961 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12963 USE_TOOLKIT_SCROLL_BARS=yes
12964 elif test "${HAVE_W32}" = "yes"; then
12965 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12967 USE_TOOLKIT_SCROLL_BARS=yes
12971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12972 /* end confdefs.h. */
12974 #include <X11/Xlib.h>
12975 #include <X11/Xresource.h>
12977 main ()
12979 XIMProc callback;
12981 return 0;
12983 _ACEOF
12984 if ac_fn_c_try_compile "$LINENO"; then :
12985 HAVE_XIM=yes
12987 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12989 else
12990 HAVE_XIM=no
12992 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12995 if test "${with_xim}" != "no"; then
12997 $as_echo "#define USE_XIM 1" >>confdefs.h
13002 if test "${HAVE_XIM}" != "no"; then
13003 late_CFLAGS=$CFLAGS
13004 if test "$GCC" = yes; then
13005 CFLAGS="$CFLAGS --pedantic-errors"
13007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13008 /* end confdefs.h. */
13010 #include <X11/Xlib.h>
13011 #include <X11/Xresource.h>
13013 main ()
13015 Display *display;
13016 XrmDatabase db;
13017 char *res_name;
13018 char *res_class;
13019 XIMProc callback;
13020 XPointer *client_data;
13021 #ifndef __GNUC__
13022 /* If we're not using GCC, it's probably not XFree86, and this is
13023 probably right, but we can't use something like --pedantic-errors. */
13024 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
13025 char*, XIMProc, XPointer*);
13026 #endif
13027 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
13028 client_data);
13030 return 0;
13032 _ACEOF
13033 if ac_fn_c_try_compile "$LINENO"; then :
13034 emacs_cv_arg6_star=yes
13036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13037 if test "$emacs_cv_arg6_star" = yes; then
13038 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
13040 else
13041 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
13044 CFLAGS=$late_CFLAGS
13047 ### Start of font-backend (under any platform) section.
13048 # (nothing here yet -- this is a placeholder)
13049 ### End of font-backend (under any platform) section.
13051 ### Start of font-backend (under X11) section.
13052 if test "${HAVE_X11}" = "yes"; then
13054 succeeded=no
13056 if test "$PKG_CONFIG" = "no" ; then
13057 HAVE_FC=no
13058 else
13059 PKG_CONFIG_MIN_VERSION=0.9.0
13060 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
13062 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
13064 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
13065 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
13066 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
13067 edit_cflags="
13068 s,///*,/,g
13069 s/^/ /
13070 s/ -I/ $isystem/g
13071 s/^ //
13073 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
13074 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
13075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
13076 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
13077 succeeded=yes
13078 else
13079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13080 $as_echo "no" >&6; }
13081 FONTCONFIG_CFLAGS=""
13082 FONTCONFIG_LIBS=""
13083 ## If we have a custom action on failure, don't print errors, but
13084 ## do set a variable so people can do so. Do it in a subshell
13085 ## to capture any diagnostics in invoking pkg-config.
13086 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
13092 else
13093 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13094 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13098 if test $succeeded = yes; then
13099 HAVE_FC=yes
13100 else
13101 HAVE_FC=no
13105 ## Use -lXft if available, unless `--with-xft=no'.
13106 HAVE_XFT=maybe
13107 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
13108 with_xft="no";
13110 if test "x${with_xft}" != "xno"; then
13113 succeeded=no
13115 if test "$PKG_CONFIG" = "no" ; then
13116 HAVE_XFT=no
13117 else
13118 PKG_CONFIG_MIN_VERSION=0.9.0
13119 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
13121 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
13123 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
13124 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
13125 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
13126 edit_cflags="
13127 s,///*,/,g
13128 s/^/ /
13129 s/ -I/ $isystem/g
13130 s/^ //
13132 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
13133 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
13134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
13135 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
13136 succeeded=yes
13137 else
13138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13139 $as_echo "no" >&6; }
13140 XFT_CFLAGS=""
13141 XFT_LIBS=""
13142 ## If we have a custom action on failure, don't print errors, but
13143 ## do set a variable so people can do so. Do it in a subshell
13144 ## to capture any diagnostics in invoking pkg-config.
13145 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
13151 else
13152 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13153 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13157 if test $succeeded = yes; then
13159 else
13160 HAVE_XFT=no
13163 ## Because xftfont.c uses XRenderQueryExtension, we also
13164 ## need to link to -lXrender.
13165 HAVE_XRENDER=no
13166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
13167 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
13168 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
13169 $as_echo_n "(cached) " >&6
13170 else
13171 ac_check_lib_save_LIBS=$LIBS
13172 LIBS="-lXrender $LIBS"
13173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13174 /* end confdefs.h. */
13176 /* Override any GCC internal prototype to avoid an error.
13177 Use char because int might match the return type of a GCC
13178 builtin and then its argument prototype would still apply. */
13179 #ifdef __cplusplus
13180 extern "C"
13181 #endif
13182 char XRenderQueryExtension ();
13184 main ()
13186 return XRenderQueryExtension ();
13188 return 0;
13190 _ACEOF
13191 if ac_fn_c_try_link "$LINENO"; then :
13192 ac_cv_lib_Xrender_XRenderQueryExtension=yes
13193 else
13194 ac_cv_lib_Xrender_XRenderQueryExtension=no
13196 rm -f core conftest.err conftest.$ac_objext \
13197 conftest$ac_exeext conftest.$ac_ext
13198 LIBS=$ac_check_lib_save_LIBS
13200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
13201 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
13202 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
13203 HAVE_XRENDER=yes
13206 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
13207 OLD_CPPFLAGS="$CPPFLAGS"
13208 OLD_CFLAGS="$CFLAGS"
13209 OLD_LIBS="$LIBS"
13210 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
13211 CFLAGS="$CFLAGS $XFT_CFLAGS"
13212 XFT_LIBS="-lXrender $XFT_LIBS"
13213 LIBS="$XFT_LIBS $LIBS"
13214 ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/X.h>
13216 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
13217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
13218 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
13219 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
13220 $as_echo_n "(cached) " >&6
13221 else
13222 ac_check_lib_save_LIBS=$LIBS
13223 LIBS="-lXft $XFT_LIBS $LIBS"
13224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13225 /* end confdefs.h. */
13227 /* Override any GCC internal prototype to avoid an error.
13228 Use char because int might match the return type of a GCC
13229 builtin and then its argument prototype would still apply. */
13230 #ifdef __cplusplus
13231 extern "C"
13232 #endif
13233 char XftFontOpen ();
13235 main ()
13237 return XftFontOpen ();
13239 return 0;
13241 _ACEOF
13242 if ac_fn_c_try_link "$LINENO"; then :
13243 ac_cv_lib_Xft_XftFontOpen=yes
13244 else
13245 ac_cv_lib_Xft_XftFontOpen=no
13247 rm -f core conftest.err conftest.$ac_objext \
13248 conftest$ac_exeext conftest.$ac_ext
13249 LIBS=$ac_check_lib_save_LIBS
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
13252 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
13253 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
13254 HAVE_XFT=yes
13261 if test "${HAVE_XFT}" = "yes"; then
13263 $as_echo "#define HAVE_XFT 1" >>confdefs.h
13266 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
13267 else
13268 CPPFLAGS="$OLD_CPPFLAGS"
13269 CFLAGS="$OLD_CFLAGS"
13270 LIBS="$OLD_LIBS"
13271 fi # "${HAVE_XFT}" = "yes"
13272 fi # "$HAVE_XFT" != no
13273 fi # "x${with_xft}" != "xno"
13275 ## We used to allow building with FreeType and without Xft.
13276 ## However, the ftx font backend driver is not in good shape.
13277 if test "$HAVE_XFT" != "yes"; then
13278 HAVE_XFT=no
13279 HAVE_FREETYPE=no
13280 else
13282 succeeded=no
13284 if test "$PKG_CONFIG" = "no" ; then
13285 HAVE_FREETYPE=no
13286 else
13287 PKG_CONFIG_MIN_VERSION=0.9.0
13288 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
13290 $as_echo_n "checking for freetype2... " >&6; }
13292 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
13293 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
13294 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
13295 edit_cflags="
13296 s,///*,/,g
13297 s/^/ /
13298 s/ -I/ $isystem/g
13299 s/^ //
13301 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
13302 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
13303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
13304 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
13305 succeeded=yes
13306 else
13307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13308 $as_echo "no" >&6; }
13309 FREETYPE_CFLAGS=""
13310 FREETYPE_LIBS=""
13311 ## If we have a custom action on failure, don't print errors, but
13312 ## do set a variable so people can do so. Do it in a subshell
13313 ## to capture any diagnostics in invoking pkg-config.
13314 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
13320 else
13321 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13322 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13326 if test $succeeded = yes; then
13327 HAVE_FREETYPE=yes
13328 else
13329 HAVE_FREETYPE=no
13333 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
13336 HAVE_LIBOTF=no
13337 if test "${HAVE_FREETYPE}" = "yes"; then
13339 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
13341 if test "${with_libotf}" != "no"; then
13343 succeeded=no
13345 if test "$PKG_CONFIG" = "no" ; then
13346 HAVE_LIBOTF=no
13347 else
13348 PKG_CONFIG_MIN_VERSION=0.9.0
13349 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
13351 $as_echo_n "checking for libotf... " >&6; }
13353 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13354 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13355 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13356 edit_cflags="
13357 s,///*,/,g
13358 s/^/ /
13359 s/ -I/ $isystem/g
13360 s/^ //
13362 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13363 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13365 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13366 succeeded=yes
13367 else
13368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13369 $as_echo "no" >&6; }
13370 LIBOTF_CFLAGS=""
13371 LIBOTF_LIBS=""
13372 ## If we have a custom action on failure, don't print errors, but
13373 ## do set a variable so people can do so. Do it in a subshell
13374 ## to capture any diagnostics in invoking pkg-config.
13375 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13381 else
13382 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13383 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13387 if test $succeeded = yes; then
13388 HAVE_LIBOTF=yes
13389 else
13390 HAVE_LIBOTF=no
13393 if test "$HAVE_LIBOTF" = "yes"; then
13395 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13398 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13399 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13400 $as_echo_n "(cached) " >&6
13401 else
13402 ac_check_lib_save_LIBS=$LIBS
13403 LIBS="-lotf $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 OTF_get_variation_glyphs ();
13415 main ()
13417 return OTF_get_variation_glyphs ();
13419 return 0;
13421 _ACEOF
13422 if ac_fn_c_try_link "$LINENO"; then :
13423 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13424 else
13425 ac_cv_lib_otf_OTF_get_variation_glyphs=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_otf_OTF_get_variation_glyphs" >&5
13432 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13433 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13434 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13435 else
13436 HAVE_OTF_GET_VARIATION_GLYPHS=no
13439 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13441 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13448 HAVE_M17N_FLT=no
13449 if test "${HAVE_LIBOTF}" = yes; then
13450 if test "${with_m17n_flt}" != "no"; then
13452 succeeded=no
13454 if test "$PKG_CONFIG" = "no" ; then
13455 HAVE_M17N_FLT=no
13456 else
13457 PKG_CONFIG_MIN_VERSION=0.9.0
13458 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13460 $as_echo_n "checking for m17n-flt... " >&6; }
13462 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13463 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13464 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13465 edit_cflags="
13466 s,///*,/,g
13467 s/^/ /
13468 s/ -I/ $isystem/g
13469 s/^ //
13471 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13472 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13474 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13475 succeeded=yes
13476 else
13477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13478 $as_echo "no" >&6; }
13479 M17N_FLT_CFLAGS=""
13480 M17N_FLT_LIBS=""
13481 ## If we have a custom action on failure, don't print errors, but
13482 ## do set a variable so people can do so. Do it in a subshell
13483 ## to capture any diagnostics in invoking pkg-config.
13484 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13490 else
13491 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13492 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13496 if test $succeeded = yes; then
13497 HAVE_M17N_FLT=yes
13498 else
13499 HAVE_M17N_FLT=no
13502 if test "$HAVE_M17N_FLT" = "yes"; then
13504 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13509 else
13510 HAVE_XFT=no
13511 HAVE_FREETYPE=no
13512 HAVE_LIBOTF=no
13513 HAVE_M17N_FLT=no
13516 ### End of font-backend (under X11) section.
13527 ### Use -lXpm if available, unless `--with-xpm=no'.
13528 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13529 HAVE_XPM=no
13530 LIBXPM=
13531 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13532 if test "${with_xpm}" != "no"; then
13533 SAVE_CPPFLAGS="$CPPFLAGS"
13534 SAVE_LDFLAGS="$LDFLAGS"
13535 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13536 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13537 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13538 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13540 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13541 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13542 $as_echo_n "(cached) " >&6
13543 else
13544 ac_check_lib_save_LIBS=$LIBS
13545 LIBS="-lXpm $LIBS"
13546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13547 /* end confdefs.h. */
13549 /* Override any GCC internal prototype to avoid an error.
13550 Use char because int might match the return type of a GCC
13551 builtin and then its argument prototype would still apply. */
13552 #ifdef __cplusplus
13553 extern "C"
13554 #endif
13555 char XpmReadFileToImage ();
13557 main ()
13559 return XpmReadFileToImage ();
13561 return 0;
13563 _ACEOF
13564 if ac_fn_c_try_link "$LINENO"; then :
13565 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13566 else
13567 ac_cv_lib_Xpm_XpmReadFileToImage=no
13569 rm -f core conftest.err conftest.$ac_objext \
13570 conftest$ac_exeext conftest.$ac_ext
13571 LIBS=$ac_check_lib_save_LIBS
13573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13574 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13575 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13576 HAVE_XPM=yes
13582 if test "${HAVE_XPM}" = "yes"; then
13583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13584 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13586 /* end confdefs.h. */
13587 #include "X11/xpm.h"
13588 #ifndef XpmReturnAllocPixels
13589 no_return_alloc_pixels
13590 #endif
13592 _ACEOF
13593 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13594 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13595 HAVE_XPM=no
13596 else
13597 HAVE_XPM=yes
13599 rm -f conftest*
13602 if test "${HAVE_XPM}" = "yes"; then
13603 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13605 $as_echo "yes" >&6; }
13606 else
13607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13608 $as_echo "no" >&6; }
13609 CPPFLAGS="$SAVE_CPPFLAGS"
13610 LDFLAGS="$SAVE_LDFLAGS"
13615 if test "${HAVE_XPM}" = "yes"; then
13617 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13619 LIBXPM=-lXpm
13623 if test "${HAVE_X11}" = "yes"; then
13624 if test "${with_xpm}" != "no"; then
13625 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13626 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13628 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13629 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13630 $as_echo_n "(cached) " >&6
13631 else
13632 ac_check_lib_save_LIBS=$LIBS
13633 LIBS="-lXpm -lX11 $LIBS"
13634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13635 /* end confdefs.h. */
13637 /* Override any GCC internal prototype to avoid an error.
13638 Use char because int might match the return type of a GCC
13639 builtin and then its argument prototype would still apply. */
13640 #ifdef __cplusplus
13641 extern "C"
13642 #endif
13643 char XpmReadFileToPixmap ();
13645 main ()
13647 return XpmReadFileToPixmap ();
13649 return 0;
13651 _ACEOF
13652 if ac_fn_c_try_link "$LINENO"; then :
13653 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13654 else
13655 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13657 rm -f core conftest.err conftest.$ac_objext \
13658 conftest$ac_exeext conftest.$ac_ext
13659 LIBS=$ac_check_lib_save_LIBS
13661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13662 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13663 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13664 HAVE_XPM=yes
13670 if test "${HAVE_XPM}" = "yes"; then
13671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13672 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13674 /* end confdefs.h. */
13675 #include "X11/xpm.h"
13676 #ifndef XpmReturnAllocPixels
13677 no_return_alloc_pixels
13678 #endif
13680 _ACEOF
13681 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13682 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13683 HAVE_XPM=no
13684 else
13685 HAVE_XPM=yes
13687 rm -f conftest*
13690 if test "${HAVE_XPM}" = "yes"; then
13691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13692 $as_echo "yes" >&6; }
13693 else
13694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13695 $as_echo "no" >&6; }
13700 if test "${HAVE_XPM}" = "yes"; then
13702 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13704 LIBXPM=-lXpm
13708 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13709 ### slightly different requirements wrt image libraries (it doesn't
13710 ### use -lXpm because it loads the xpm shared library dynamically at
13711 ### run time).
13712 if test "${opsys}" = "mingw32"; then
13713 if test "${with_xpm}" != "no"; then
13714 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13715 #define FOR_MSW 1
13717 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13718 HAVE_XPM=yes
13719 else
13720 HAVE_XPM=no
13726 if test "${HAVE_XPM}" = "yes"; then
13728 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13735 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13736 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13737 HAVE_JPEG=no
13738 LIBJPEG=
13739 if test "${opsys}" = "mingw32"; then
13740 if test "${with_jpeg}" != "no"; then
13741 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13742 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13743 HAVE_JPEG=yes
13744 else
13745 HAVE_JPEG=no
13750 if test "${HAVE_JPEG}" = "yes"; then
13751 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13754 /* end confdefs.h. */
13755 #include <jpeglib.h>
13756 version=JPEG_LIB_VERSION
13758 _ACEOF
13759 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13760 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13761 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13763 else
13764 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13765 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13766 HAVE_JPEG=no
13768 rm -f conftest*
13771 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13772 if test "${with_jpeg}" != "no"; then
13773 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13774 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13776 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13777 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13778 $as_echo_n "(cached) " >&6
13779 else
13780 ac_check_lib_save_LIBS=$LIBS
13781 LIBS="-ljpeg $LIBS"
13782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13783 /* end confdefs.h. */
13785 /* Override any GCC internal prototype to avoid an error.
13786 Use char because int might match the return type of a GCC
13787 builtin and then its argument prototype would still apply. */
13788 #ifdef __cplusplus
13789 extern "C"
13790 #endif
13791 char jpeg_destroy_compress ();
13793 main ()
13795 return jpeg_destroy_compress ();
13797 return 0;
13799 _ACEOF
13800 if ac_fn_c_try_link "$LINENO"; then :
13801 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13802 else
13803 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13805 rm -f core conftest.err conftest.$ac_objext \
13806 conftest$ac_exeext conftest.$ac_ext
13807 LIBS=$ac_check_lib_save_LIBS
13809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13810 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13811 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13812 HAVE_JPEG=yes
13820 if test "${HAVE_JPEG}" = "yes"; then
13821 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13824 /* end confdefs.h. */
13825 #include <jpeglib.h>
13826 version=JPEG_LIB_VERSION
13828 _ACEOF
13829 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13830 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13831 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13833 else
13834 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13835 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13836 HAVE_JPEG=no
13838 rm -f conftest*
13841 if test "${HAVE_JPEG}" = "yes"; then
13842 LIBJPEG=-ljpeg
13847 ### Use -lpng if available, unless `--with-png=no'.
13848 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13849 HAVE_PNG=no
13850 LIBPNG=
13851 if test "${opsys}" = "mingw32"; then
13852 if test "${with_png}" != "no"; then
13853 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13854 if test "x$ac_cv_header_png_h" = x""yes; then :
13855 HAVE_PNG=yes
13856 else
13857 HAVE_PNG=no
13862 if test "${HAVE_PNG}" = "yes"; then
13864 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13867 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13868 # include <libpng/png.h>
13869 #else
13870 # include <png.h>
13871 #endif
13874 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13876 else
13878 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13883 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13884 if test "${with_png}" != "no"; then
13885 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13886 # in /usr/include/libpng.
13887 for ac_header in png.h libpng/png.h
13888 do :
13889 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13890 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13891 eval as_val=\$$as_ac_Header
13892 if test "x$as_val" = x""yes; then :
13893 cat >>confdefs.h <<_ACEOF
13894 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13895 _ACEOF
13896 break
13899 done
13901 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13903 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13904 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13905 $as_echo_n "(cached) " >&6
13906 else
13907 ac_check_lib_save_LIBS=$LIBS
13908 LIBS="-lpng -lz -lm $LIBS"
13909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13910 /* end confdefs.h. */
13912 /* Override any GCC internal prototype to avoid an error.
13913 Use char because int might match the return type of a GCC
13914 builtin and then its argument prototype would still apply. */
13915 #ifdef __cplusplus
13916 extern "C"
13917 #endif
13918 char png_get_channels ();
13920 main ()
13922 return png_get_channels ();
13924 return 0;
13926 _ACEOF
13927 if ac_fn_c_try_link "$LINENO"; then :
13928 ac_cv_lib_png_png_get_channels=yes
13929 else
13930 ac_cv_lib_png_png_get_channels=no
13932 rm -f core conftest.err conftest.$ac_objext \
13933 conftest$ac_exeext conftest.$ac_ext
13934 LIBS=$ac_check_lib_save_LIBS
13936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13937 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13938 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13939 HAVE_PNG=yes
13945 if test "${HAVE_PNG}" = "yes"; then
13947 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13949 LIBPNG="-lpng -lz -lm"
13951 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13952 # include <libpng/png.h>
13953 #else
13954 # include <png.h>
13955 #endif
13958 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13960 else
13962 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13970 HAVE_ZLIB=no
13971 LIBZ=
13972 if test "${with_zlib}" != "no"; then
13973 OLIBS=$LIBS
13974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inflateEnd" >&5
13975 $as_echo_n "checking for library containing inflateEnd... " >&6; }
13976 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13977 $as_echo_n "(cached) " >&6
13978 else
13979 ac_func_search_save_LIBS=$LIBS
13980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13981 /* end confdefs.h. */
13983 /* Override any GCC internal prototype to avoid an error.
13984 Use char because int might match the return type of a GCC
13985 builtin and then its argument prototype would still apply. */
13986 #ifdef __cplusplus
13987 extern "C"
13988 #endif
13989 char inflateEnd ();
13991 main ()
13993 return inflateEnd ();
13995 return 0;
13997 _ACEOF
13998 for ac_lib in '' z; do
13999 if test -z "$ac_lib"; then
14000 ac_res="none required"
14001 else
14002 ac_res=-l$ac_lib
14003 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
14005 if ac_fn_c_try_link "$LINENO"; then :
14006 ac_cv_search_inflateEnd=$ac_res
14008 rm -f core conftest.err conftest.$ac_objext \
14009 conftest$ac_exeext
14010 if test "${ac_cv_search_inflateEnd+set}" = set; then :
14011 break
14013 done
14014 if test "${ac_cv_search_inflateEnd+set}" = set; then :
14016 else
14017 ac_cv_search_inflateEnd=no
14019 rm conftest.$ac_ext
14020 LIBS=$ac_func_search_save_LIBS
14022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inflateEnd" >&5
14023 $as_echo "$ac_cv_search_inflateEnd" >&6; }
14024 ac_res=$ac_cv_search_inflateEnd
14025 if test "$ac_res" != no; then :
14026 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14027 HAVE_ZLIB=yes
14030 LIBS=$OLIBS
14031 case $ac_cv_search_inflateEnd in
14032 -*) LIBZ=$ac_cv_search_inflateEnd ;;
14033 esac
14035 if test "${HAVE_ZLIB}" = "yes"; then
14037 $as_echo "#define HAVE_ZLIB 1" >>confdefs.h
14039 ### mingw32 doesn't use -lz, since it loads the library dynamically.
14040 if test "${opsys}" = "mingw32"; then
14041 LIBZ=
14047 ### Use -ltiff if available, unless `--with-tiff=no'.
14048 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
14049 HAVE_TIFF=no
14050 LIBTIFF=
14051 if test "${opsys}" = "mingw32"; then
14052 if test "${with_tiff}" != "no"; then
14053 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
14054 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
14055 HAVE_TIFF=yes
14056 else
14057 HAVE_TIFF=no
14062 if test "${HAVE_TIFF}" = "yes"; then
14064 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
14067 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
14068 if test "${with_tiff}" != "no"; then
14069 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
14070 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
14071 tifflibs="-lz -lm"
14072 # At least one tiff package requires the jpeg library.
14073 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
14074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
14075 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
14076 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
14077 $as_echo_n "(cached) " >&6
14078 else
14079 ac_check_lib_save_LIBS=$LIBS
14080 LIBS="-ltiff $tifflibs $LIBS"
14081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14082 /* end confdefs.h. */
14084 /* Override any GCC internal prototype to avoid an error.
14085 Use char because int might match the return type of a GCC
14086 builtin and then its argument prototype would still apply. */
14087 #ifdef __cplusplus
14088 extern "C"
14089 #endif
14090 char TIFFGetVersion ();
14092 main ()
14094 return TIFFGetVersion ();
14096 return 0;
14098 _ACEOF
14099 if ac_fn_c_try_link "$LINENO"; then :
14100 ac_cv_lib_tiff_TIFFGetVersion=yes
14101 else
14102 ac_cv_lib_tiff_TIFFGetVersion=no
14104 rm -f core conftest.err conftest.$ac_objext \
14105 conftest$ac_exeext conftest.$ac_ext
14106 LIBS=$ac_check_lib_save_LIBS
14108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
14109 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
14110 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
14111 HAVE_TIFF=yes
14119 if test "${HAVE_TIFF}" = "yes"; then
14121 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
14123 LIBTIFF=-ltiff
14128 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
14129 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
14130 HAVE_GIF=no
14131 LIBGIF=
14132 if test "${opsys}" = "mingw32"; then
14133 if test "${with_gif}" != "no"; then
14134 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14135 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14136 HAVE_GIF=yes
14137 else
14138 HAVE_GIF=no
14143 if test "${HAVE_GIF}" = "yes"; then
14145 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14148 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
14149 || test "${HAVE_W32}" = "yes"; then
14150 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14151 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14152 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
14153 # Earlier versions can crash Emacs.
14154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
14155 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
14156 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
14157 $as_echo_n "(cached) " >&6
14158 else
14159 ac_check_lib_save_LIBS=$LIBS
14160 LIBS="-lgif $LIBS"
14161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14162 /* end confdefs.h. */
14164 /* Override any GCC internal prototype to avoid an error.
14165 Use char because int might match the return type of a GCC
14166 builtin and then its argument prototype would still apply. */
14167 #ifdef __cplusplus
14168 extern "C"
14169 #endif
14170 char EGifPutExtensionLast ();
14172 main ()
14174 return EGifPutExtensionLast ();
14176 return 0;
14178 _ACEOF
14179 if ac_fn_c_try_link "$LINENO"; then :
14180 ac_cv_lib_gif_EGifPutExtensionLast=yes
14181 else
14182 ac_cv_lib_gif_EGifPutExtensionLast=no
14184 rm -f core conftest.err conftest.$ac_objext \
14185 conftest$ac_exeext conftest.$ac_ext
14186 LIBS=$ac_check_lib_save_LIBS
14188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
14189 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
14190 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
14191 HAVE_GIF=yes
14192 else
14193 HAVE_GIF=maybe
14200 if test "$HAVE_GIF" = yes; then
14201 LIBGIF=-lgif
14202 elif test "$HAVE_GIF" = maybe; then
14203 # If gif_lib.h but no libgif, try libungif.
14204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
14205 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
14206 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
14207 $as_echo_n "(cached) " >&6
14208 else
14209 ac_check_lib_save_LIBS=$LIBS
14210 LIBS="-lungif $LIBS"
14211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14212 /* end confdefs.h. */
14214 /* Override any GCC internal prototype to avoid an error.
14215 Use char because int might match the return type of a GCC
14216 builtin and then its argument prototype would still apply. */
14217 #ifdef __cplusplus
14218 extern "C"
14219 #endif
14220 char EGifPutExtensionLast ();
14222 main ()
14224 return EGifPutExtensionLast ();
14226 return 0;
14228 _ACEOF
14229 if ac_fn_c_try_link "$LINENO"; then :
14230 ac_cv_lib_ungif_EGifPutExtensionLast=yes
14231 else
14232 ac_cv_lib_ungif_EGifPutExtensionLast=no
14234 rm -f core conftest.err conftest.$ac_objext \
14235 conftest$ac_exeext conftest.$ac_ext
14236 LIBS=$ac_check_lib_save_LIBS
14238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
14239 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
14240 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
14241 HAVE_GIF=yes
14242 else
14243 HAVE_GIF=no
14246 test "$HAVE_GIF" = yes && LIBGIF=-lungif
14249 if test "${HAVE_GIF}" = "yes"; then
14251 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14257 if test "${HAVE_X11}" = "yes"; then
14258 MISSING=""
14259 WITH_NO=""
14260 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
14261 MISSING="libXpm" && WITH_NO="--with-xpm=no"
14262 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
14263 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
14264 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
14265 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
14266 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
14267 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
14268 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
14269 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
14271 if test "X${MISSING}" != X; then
14272 as_fn_error "The following required libraries were not found:
14273 $MISSING
14274 Maybe some development libraries/packages are missing?
14275 If you don't want to link with them give
14276 $WITH_NO
14277 as options to configure" "$LINENO" 5
14281 ### Use -lgpm if available, unless `--with-gpm=no'.
14282 HAVE_GPM=no
14283 LIBGPM=
14284 if test "${with_gpm}" != "no"; then
14285 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
14286 if test "x$ac_cv_header_gpm_h" = x""yes; then :
14287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
14288 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
14289 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
14290 $as_echo_n "(cached) " >&6
14291 else
14292 ac_check_lib_save_LIBS=$LIBS
14293 LIBS="-lgpm $LIBS"
14294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14295 /* end confdefs.h. */
14297 /* Override any GCC internal prototype to avoid an error.
14298 Use char because int might match the return type of a GCC
14299 builtin and then its argument prototype would still apply. */
14300 #ifdef __cplusplus
14301 extern "C"
14302 #endif
14303 char Gpm_Open ();
14305 main ()
14307 return Gpm_Open ();
14309 return 0;
14311 _ACEOF
14312 if ac_fn_c_try_link "$LINENO"; then :
14313 ac_cv_lib_gpm_Gpm_Open=yes
14314 else
14315 ac_cv_lib_gpm_Gpm_Open=no
14317 rm -f core conftest.err conftest.$ac_objext \
14318 conftest$ac_exeext conftest.$ac_ext
14319 LIBS=$ac_check_lib_save_LIBS
14321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
14322 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
14323 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
14324 HAVE_GPM=yes
14331 if test "${HAVE_GPM}" = "yes"; then
14333 $as_echo "#define HAVE_GPM 1" >>confdefs.h
14335 LIBGPM=-lgpm
14344 GNUSTEP_CFLAGS=
14345 ### Use NeXTstep API to implement GUI.
14346 if test "${HAVE_NS}" = "yes"; then
14348 $as_echo "#define HAVE_NS 1" >>confdefs.h
14350 if test "${NS_IMPL_COCOA}" = "yes"; then
14352 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
14355 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
14357 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
14359 # See also .m.o rule in Makefile.in */
14360 # FIXME: are all these flags really needed? Document here why. */
14361 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
14362 ## Extra CFLAGS applied to src/*.m files.
14363 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"
14365 # We also have mouse menus.
14366 HAVE_MENUS=yes
14367 OTHER_FILES=ns-app
14370 if test "${HAVE_W32}" = "yes"; then
14371 HAVE_MENUS=yes
14374 ### Use session management (-lSM -lICE) if available
14375 HAVE_X_SM=no
14376 LIBXSM=
14377 if test "${HAVE_X11}" = "yes"; then
14378 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
14379 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
14380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
14381 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
14382 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
14383 $as_echo_n "(cached) " >&6
14384 else
14385 ac_check_lib_save_LIBS=$LIBS
14386 LIBS="-lSM -lICE $LIBS"
14387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14388 /* end confdefs.h. */
14390 /* Override any GCC internal prototype to avoid an error.
14391 Use char because int might match the return type of a GCC
14392 builtin and then its argument prototype would still apply. */
14393 #ifdef __cplusplus
14394 extern "C"
14395 #endif
14396 char SmcOpenConnection ();
14398 main ()
14400 return SmcOpenConnection ();
14402 return 0;
14404 _ACEOF
14405 if ac_fn_c_try_link "$LINENO"; then :
14406 ac_cv_lib_SM_SmcOpenConnection=yes
14407 else
14408 ac_cv_lib_SM_SmcOpenConnection=no
14410 rm -f core conftest.err conftest.$ac_objext \
14411 conftest$ac_exeext conftest.$ac_ext
14412 LIBS=$ac_check_lib_save_LIBS
14414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
14415 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
14416 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
14417 HAVE_X_SM=yes
14424 if test "${HAVE_X_SM}" = "yes"; then
14426 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
14428 LIBXSM="-lSM -lICE"
14429 case "$LIBS" in
14430 *-lSM*) ;;
14431 *) LIBS="$LIBXSM $LIBS" ;;
14432 esac
14437 ### Use XRandr (-lXrandr) if available
14438 HAVE_XRANDR=no
14439 if test "${HAVE_X11}" = "yes"; then
14440 XRANDR_REQUIRED=1.2.2
14441 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14443 succeeded=no
14445 if test "$PKG_CONFIG" = "no" ; then
14446 HAVE_XRANDR=no
14447 else
14448 PKG_CONFIG_MIN_VERSION=0.9.0
14449 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14451 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14453 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14454 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14455 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14456 edit_cflags="
14457 s,///*,/,g
14458 s/^/ /
14459 s/ -I/ $isystem/g
14460 s/^ //
14462 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14463 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14465 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14466 succeeded=yes
14467 else
14468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14469 $as_echo "no" >&6; }
14470 XRANDR_CFLAGS=""
14471 XRANDR_LIBS=""
14472 ## If we have a custom action on failure, don't print errors, but
14473 ## do set a variable so people can do so. Do it in a subshell
14474 ## to capture any diagnostics in invoking pkg-config.
14475 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14481 else
14482 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14483 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14487 if test $succeeded = yes; then
14488 HAVE_XRANDR=yes
14489 else
14490 HAVE_XRANDR=no
14493 if test $HAVE_XRANDR = no; then
14494 # Test old way in case pkg-config doesn't have it (older machines).
14495 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14496 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14498 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14499 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14500 $as_echo_n "(cached) " >&6
14501 else
14502 ac_check_lib_save_LIBS=$LIBS
14503 LIBS="-lXrandr $LIBS"
14504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14505 /* end confdefs.h. */
14507 /* Override any GCC internal prototype to avoid an error.
14508 Use char because int might match the return type of a GCC
14509 builtin and then its argument prototype would still apply. */
14510 #ifdef __cplusplus
14511 extern "C"
14512 #endif
14513 char XRRGetScreenResources ();
14515 main ()
14517 return XRRGetScreenResources ();
14519 return 0;
14521 _ACEOF
14522 if ac_fn_c_try_link "$LINENO"; then :
14523 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14524 else
14525 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14527 rm -f core conftest.err conftest.$ac_objext \
14528 conftest$ac_exeext conftest.$ac_ext
14529 LIBS=$ac_check_lib_save_LIBS
14531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14532 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14533 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14534 HAVE_XRANDR=yes
14540 if test $HAVE_XRANDR = yes; then
14541 XRANDR_LIBS=-lXrandr
14545 if test $HAVE_XRANDR = yes; then
14546 SAVE_CFLAGS="$CFLAGS"
14547 SAVE_LIBS="$LIBS"
14548 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14549 LIBS="$XRANDR_LIBS $LIBS"
14550 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14551 do :
14552 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14553 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14554 eval as_val=\$$as_ac_var
14555 if test "x$as_val" = x""yes; then :
14556 cat >>confdefs.h <<_ACEOF
14557 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14558 _ACEOF
14561 done
14563 CFLAGS="$SAVE_CFLAGS"
14564 LIBS="$SAVE_LIBS"
14567 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14572 ### Use Xinerama (-lXinerama) if available
14573 HAVE_XINERAMA=no
14574 if test "${HAVE_X11}" = "yes"; then
14575 XINERAMA_REQUIRED=1.0.2
14576 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14578 succeeded=no
14580 if test "$PKG_CONFIG" = "no" ; then
14581 HAVE_XINERAMA=no
14582 else
14583 PKG_CONFIG_MIN_VERSION=0.9.0
14584 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14586 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14588 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14589 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14590 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14591 edit_cflags="
14592 s,///*,/,g
14593 s/^/ /
14594 s/ -I/ $isystem/g
14595 s/^ //
14597 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14598 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14600 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14601 succeeded=yes
14602 else
14603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14604 $as_echo "no" >&6; }
14605 XINERAMA_CFLAGS=""
14606 XINERAMA_LIBS=""
14607 ## If we have a custom action on failure, don't print errors, but
14608 ## do set a variable so people can do so. Do it in a subshell
14609 ## to capture any diagnostics in invoking pkg-config.
14610 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14616 else
14617 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14618 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14622 if test $succeeded = yes; then
14623 HAVE_XINERAMA=yes
14624 else
14625 HAVE_XINERAMA=no
14628 if test $HAVE_XINERAMA = no; then
14629 # Test old way in case pkg-config doesn't have it (older machines).
14630 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14631 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14633 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14634 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14635 $as_echo_n "(cached) " >&6
14636 else
14637 ac_check_lib_save_LIBS=$LIBS
14638 LIBS="-lXinerama $LIBS"
14639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14640 /* end confdefs.h. */
14642 /* Override any GCC internal prototype to avoid an error.
14643 Use char because int might match the return type of a GCC
14644 builtin and then its argument prototype would still apply. */
14645 #ifdef __cplusplus
14646 extern "C"
14647 #endif
14648 char XineramaQueryExtension ();
14650 main ()
14652 return XineramaQueryExtension ();
14654 return 0;
14656 _ACEOF
14657 if ac_fn_c_try_link "$LINENO"; then :
14658 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14659 else
14660 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14662 rm -f core conftest.err conftest.$ac_objext \
14663 conftest$ac_exeext conftest.$ac_ext
14664 LIBS=$ac_check_lib_save_LIBS
14666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14667 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14668 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14669 HAVE_XINERAMA=yes
14675 if test $HAVE_XINERAMA = yes; then
14676 XINERAMA_LIBS=-lXinerama
14680 if test $HAVE_XINERAMA = yes; then
14682 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14688 ### Use libxml (-lxml2) if available
14689 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14690 HAVE_LIBXML2=no
14691 if test "${with_xml2}" != "no"; then
14692 ### I'm not sure what the version number should be, so I just guessed.
14694 succeeded=no
14696 if test "$PKG_CONFIG" = "no" ; then
14697 HAVE_LIBXML2=no
14698 else
14699 PKG_CONFIG_MIN_VERSION=0.9.0
14700 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14702 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14704 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14705 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14706 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14707 edit_cflags="
14708 s,///*,/,g
14709 s/^/ /
14710 s/ -I/ $isystem/g
14711 s/^ //
14713 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14714 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14716 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14717 succeeded=yes
14718 else
14719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14720 $as_echo "no" >&6; }
14721 LIBXML2_CFLAGS=""
14722 LIBXML2_LIBS=""
14723 ## If we have a custom action on failure, don't print errors, but
14724 ## do set a variable so people can do so. Do it in a subshell
14725 ## to capture any diagnostics in invoking pkg-config.
14726 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14732 else
14733 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14734 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14738 if test $succeeded = yes; then
14739 HAVE_LIBXML2=yes
14740 else
14741 HAVE_LIBXML2=no
14744 # Built-in libxml2 on OS X 10.8 lacks libxml-2.0.pc.
14745 if test "${HAVE_LIBXML2}" != "yes" -a "$opsys" = "darwin"; then
14746 SAVE_CPPFLAGS="$CPPFLAGS"
14747 CPPFLAGS="$CPPFLAGS -I/usr/include/libxml2"
14748 ac_fn_c_check_header_mongrel "$LINENO" "libxml/HTMLparser.h" "ac_cv_header_libxml_HTMLparser_h" "$ac_includes_default"
14749 if test "x$ac_cv_header_libxml_HTMLparser_h" = x""yes; then :
14750 ac_fn_c_check_decl "$LINENO" "HTML_PARSE_RECOVER" "ac_cv_have_decl_HTML_PARSE_RECOVER" "#include <libxml/HTMLparser.h>
14752 if test "x$ac_cv_have_decl_HTML_PARSE_RECOVER" = x""yes; then :
14753 HAVE_LIBXML2=yes
14759 CPPFLAGS="$SAVE_CPPFLAGS"
14760 if test "${HAVE_LIBXML2}" = "yes"; then
14761 LIBXML2_LIBS="-lxml2"
14762 LIBXML2_CFLAGS="-I/usr/include/libxml2"
14765 if test "${HAVE_LIBXML2}" = "yes"; then
14766 if test "${opsys}" != "mingw32"; then
14767 LIBS="$LIBXML2_LIBS $LIBS"
14768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14769 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14770 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14771 $as_echo_n "(cached) " >&6
14772 else
14773 ac_check_lib_save_LIBS=$LIBS
14774 LIBS="-lxml2 $LIBS"
14775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14776 /* end confdefs.h. */
14778 /* Override any GCC internal prototype to avoid an error.
14779 Use char because int might match the return type of a GCC
14780 builtin and then its argument prototype would still apply. */
14781 #ifdef __cplusplus
14782 extern "C"
14783 #endif
14784 char htmlReadMemory ();
14786 main ()
14788 return htmlReadMemory ();
14790 return 0;
14792 _ACEOF
14793 if ac_fn_c_try_link "$LINENO"; then :
14794 ac_cv_lib_xml2_htmlReadMemory=yes
14795 else
14796 ac_cv_lib_xml2_htmlReadMemory=no
14798 rm -f core conftest.err conftest.$ac_objext \
14799 conftest$ac_exeext conftest.$ac_ext
14800 LIBS=$ac_check_lib_save_LIBS
14802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14803 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14804 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14805 HAVE_LIBXML2=yes
14806 else
14807 HAVE_LIBXML2=no
14810 else
14811 LIBXML2_LIBS=""
14813 if test "${HAVE_LIBXML2}" = "yes"; then
14815 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14817 else
14818 LIBXML2_LIBS=""
14819 LIBXML2_CFLAGS=""
14826 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14827 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14828 if test "${opsys}" = "mingw32"; then
14829 emacs_cv_netdb_declares_h_errno=yes
14831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14832 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14833 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14834 $as_echo_n "(cached) " >&6
14835 else
14836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14837 /* end confdefs.h. */
14838 #include <netdb.h>
14840 main ()
14842 return h_errno;
14844 return 0;
14846 _ACEOF
14847 if ac_fn_c_try_link "$LINENO"; then :
14848 emacs_cv_netdb_declares_h_errno=yes
14849 else
14850 emacs_cv_netdb_declares_h_errno=no
14852 rm -f core conftest.err conftest.$ac_objext \
14853 conftest$ac_exeext conftest.$ac_ext
14855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14856 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14857 if test $emacs_cv_netdb_declares_h_errno = yes; then
14859 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14863 # sqrt and other floating-point functions such as fmod and frexp
14864 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14865 if test "${opsys}" != "mingw32"; then
14866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14867 $as_echo_n "checking for sqrt in -lm... " >&6; }
14868 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14869 $as_echo_n "(cached) " >&6
14870 else
14871 ac_check_lib_save_LIBS=$LIBS
14872 LIBS="-lm $LIBS"
14873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14874 /* end confdefs.h. */
14876 /* Override any GCC internal prototype to avoid an error.
14877 Use char because int might match the return type of a GCC
14878 builtin and then its argument prototype would still apply. */
14879 #ifdef __cplusplus
14880 extern "C"
14881 #endif
14882 char sqrt ();
14884 main ()
14886 return sqrt ();
14888 return 0;
14890 _ACEOF
14891 if ac_fn_c_try_link "$LINENO"; then :
14892 ac_cv_lib_m_sqrt=yes
14893 else
14894 ac_cv_lib_m_sqrt=no
14896 rm -f core conftest.err conftest.$ac_objext \
14897 conftest$ac_exeext conftest.$ac_ext
14898 LIBS=$ac_check_lib_save_LIBS
14900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14901 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14902 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14903 cat >>confdefs.h <<_ACEOF
14904 #define HAVE_LIBM 1
14905 _ACEOF
14907 LIBS="-lm $LIBS"
14913 # Check for mail-locking functions in a "mail" library. Probably this should
14914 # have the same check as for liblockfile below.
14915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14916 $as_echo_n "checking for maillock in -lmail... " >&6; }
14917 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14918 $as_echo_n "(cached) " >&6
14919 else
14920 ac_check_lib_save_LIBS=$LIBS
14921 LIBS="-lmail $LIBS"
14922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14923 /* end confdefs.h. */
14925 /* Override any GCC internal prototype to avoid an error.
14926 Use char because int might match the return type of a GCC
14927 builtin and then its argument prototype would still apply. */
14928 #ifdef __cplusplus
14929 extern "C"
14930 #endif
14931 char maillock ();
14933 main ()
14935 return maillock ();
14937 return 0;
14939 _ACEOF
14940 if ac_fn_c_try_link "$LINENO"; then :
14941 ac_cv_lib_mail_maillock=yes
14942 else
14943 ac_cv_lib_mail_maillock=no
14945 rm -f core conftest.err conftest.$ac_objext \
14946 conftest$ac_exeext conftest.$ac_ext
14947 LIBS=$ac_check_lib_save_LIBS
14949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14950 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14951 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14952 have_mail=yes
14953 else
14954 have_mail=no
14957 if test $have_mail = yes; then
14958 LIBS_MAIL=-lmail
14959 LIBS="$LIBS_MAIL $LIBS"
14961 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14963 else
14964 LIBS_MAIL=
14966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14967 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14968 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14969 $as_echo_n "(cached) " >&6
14970 else
14971 ac_check_lib_save_LIBS=$LIBS
14972 LIBS="-llockfile $LIBS"
14973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14974 /* end confdefs.h. */
14976 /* Override any GCC internal prototype to avoid an error.
14977 Use char because int might match the return type of a GCC
14978 builtin and then its argument prototype would still apply. */
14979 #ifdef __cplusplus
14980 extern "C"
14981 #endif
14982 char maillock ();
14984 main ()
14986 return maillock ();
14988 return 0;
14990 _ACEOF
14991 if ac_fn_c_try_link "$LINENO"; then :
14992 ac_cv_lib_lockfile_maillock=yes
14993 else
14994 ac_cv_lib_lockfile_maillock=no
14996 rm -f core conftest.err conftest.$ac_objext \
14997 conftest$ac_exeext conftest.$ac_ext
14998 LIBS=$ac_check_lib_save_LIBS
15000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
15001 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
15002 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
15003 have_lockfile=yes
15004 else
15005 have_lockfile=no
15008 if test $have_lockfile = yes; then
15009 LIBS_MAIL=-llockfile
15010 LIBS="$LIBS_MAIL $LIBS"
15012 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
15014 else
15015 # If we have the shared liblockfile, assume we must use it for mail
15016 # locking (e.g. Debian). If we couldn't link against liblockfile
15017 # (no liblockfile.a installed), ensure that we don't need to.
15018 # Extract the first word of "liblockfile.so", so it can be a program name with args.
15019 set dummy liblockfile.so; ac_word=$2
15020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15021 $as_echo_n "checking for $ac_word... " >&6; }
15022 if test "${ac_cv_prog_liblockfile+set}" = set; then :
15023 $as_echo_n "(cached) " >&6
15024 else
15025 if test -n "$liblockfile"; then
15026 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
15027 else
15028 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15029 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
15030 for as_dir in $as_dummy
15032 IFS=$as_save_IFS
15033 test -z "$as_dir" && as_dir=.
15034 for ac_exec_ext in '' $ac_executable_extensions; do
15035 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15036 ac_cv_prog_liblockfile="yes"
15037 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15038 break 2
15040 done
15041 done
15042 IFS=$as_save_IFS
15044 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
15047 liblockfile=$ac_cv_prog_liblockfile
15048 if test -n "$liblockfile"; then
15049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
15050 $as_echo "$liblockfile" >&6; }
15051 else
15052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15053 $as_echo "no" >&6; }
15057 if test $ac_cv_prog_liblockfile = yes; then
15058 as_fn_error "Shared liblockfile found but can't link against it.
15059 This probably means that movemail could lose mail.
15060 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
15068 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
15069 ## interlock access to the mail spool. The alternative is a lock file named
15070 ## /usr/spool/mail/$USER.lock.
15071 mail_lock=no
15072 case "$opsys" in
15073 aix4-2) mail_lock="lockf" ;;
15075 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
15077 ## On GNU/Linux systems, both methods are used by various mail programs.
15078 ## I assume most people are using newer mailers that have heard of flock.
15079 ## Change this if you need to.
15080 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
15081 ## configure gets the right answers, and that means *NOT* using flock.
15082 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
15083 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
15084 ## Debian maintainer hasn't provided a clean fix for Emacs.
15085 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
15086 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
15087 ## correct logic. -- fx
15088 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
15089 ## liblockfile is a Free Software replacement for libmail, used on
15090 ## Debian systems and elsewhere. -rfr.
15091 gnu-*)
15092 mail_lock="flock"
15093 if test $have_mail = yes || test $have_lockfile = yes; then
15094 test $ac_cv_header_maillock_h = yes && mail_lock=no
15098 mingw32)
15099 mail_lock="none-needed" ;;
15100 esac
15102 BLESSMAIL_TARGET=
15103 case "$mail_lock" in
15104 flock)
15105 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
15108 lockf)
15109 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
15112 none-needed) ;;
15114 *) BLESSMAIL_TARGET="need-blessmail" ;;
15115 esac
15119 for ac_func in accept4 gethostname \
15120 getrusage get_current_dir_name \
15121 lrand48 \
15122 select getpagesize setlocale \
15123 getrlimit setrlimit shutdown getaddrinfo \
15124 strsignal setitimer \
15125 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
15126 gai_strerror getline getdelim sync \
15127 difftime posix_memalign \
15128 getpwent endpwent getgrent endgrent \
15129 touchlock \
15130 cfmakeraw cfsetspeed copysign __executable_start log2
15131 do :
15132 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15133 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15134 eval as_val=\$$as_ac_var
15135 if test "x$as_val" = x""yes; then :
15136 cat >>confdefs.h <<_ACEOF
15137 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15138 _ACEOF
15141 done
15144 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
15145 ## has a broken `rint' in some library versions including math library
15146 ## version number A.09.05.
15147 ## You can fix the math library by installing patch number PHSS_4630.
15148 ## But we can fix it more reliably for Emacs by just not using rint.
15149 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
15150 case $opsys in
15151 hpux*) : ;;
15152 *) for ac_func in random rint
15153 do :
15154 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15155 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15156 eval as_val=\$$as_ac_var
15157 if test "x$as_val" = x""yes; then :
15158 cat >>confdefs.h <<_ACEOF
15159 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15160 _ACEOF
15163 done
15165 esac
15167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
15168 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
15169 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
15170 $as_echo_n "(cached) " >&6
15171 else
15172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15173 /* end confdefs.h. */
15176 main ()
15178 __builtin_unwind_init ();
15180 return 0;
15182 _ACEOF
15183 if ac_fn_c_try_link "$LINENO"; then :
15184 emacs_cv_func___builtin_unwind_init=yes
15185 else
15186 emacs_cv_func___builtin_unwind_init=no
15188 rm -f core conftest.err conftest.$ac_objext \
15189 conftest$ac_exeext conftest.$ac_ext
15191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
15192 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
15193 if test $emacs_cv_func___builtin_unwind_init = yes; then
15195 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
15203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15204 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15205 if test "${ac_cv_sys_largefile_source+set}" = set; then :
15206 $as_echo_n "(cached) " >&6
15207 else
15208 while :; do
15209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15210 /* end confdefs.h. */
15211 #include <sys/types.h> /* for off_t */
15212 #include <stdio.h>
15214 main ()
15216 int (*fp) (FILE *, off_t, int) = fseeko;
15217 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15219 return 0;
15221 _ACEOF
15222 if ac_fn_c_try_link "$LINENO"; then :
15223 ac_cv_sys_largefile_source=no; break
15225 rm -f core conftest.err conftest.$ac_objext \
15226 conftest$ac_exeext conftest.$ac_ext
15227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15228 /* end confdefs.h. */
15229 #define _LARGEFILE_SOURCE 1
15230 #include <sys/types.h> /* for off_t */
15231 #include <stdio.h>
15233 main ()
15235 int (*fp) (FILE *, off_t, int) = fseeko;
15236 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15238 return 0;
15240 _ACEOF
15241 if ac_fn_c_try_link "$LINENO"; then :
15242 ac_cv_sys_largefile_source=1; break
15244 rm -f core conftest.err conftest.$ac_objext \
15245 conftest$ac_exeext conftest.$ac_ext
15246 ac_cv_sys_largefile_source=unknown
15247 break
15248 done
15250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15251 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15252 case $ac_cv_sys_largefile_source in #(
15253 no | unknown) ;;
15255 cat >>confdefs.h <<_ACEOF
15256 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15257 _ACEOF
15259 esac
15260 rm -rf conftest*
15262 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15263 # in glibc 2.1.3, but that breaks too many other things.
15264 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15265 if test $ac_cv_sys_largefile_source != unknown; then
15267 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15272 # UNIX98 PTYs.
15273 for ac_func in grantpt
15274 do :
15275 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
15276 if test "x$ac_cv_func_grantpt" = x""yes; then :
15277 cat >>confdefs.h <<_ACEOF
15278 #define HAVE_GRANTPT 1
15279 _ACEOF
15282 done
15285 # PTY-related GNU extensions.
15286 for ac_func in getpt posix_openpt
15287 do :
15288 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15289 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15290 eval as_val=\$$as_ac_var
15291 if test "x$as_val" = x""yes; then :
15292 cat >>confdefs.h <<_ACEOF
15293 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15294 _ACEOF
15297 done
15300 # Check this now, so that we will NOT find the above functions in ncurses.
15301 # That is because we have not set up to link ncurses in lib-src.
15302 # It's better to believe a function is not available
15303 # than to expect to find it in ncurses.
15304 # Also we need tputs and friends to be able to build at all.
15305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
15306 $as_echo_n "checking for library containing tputs... " >&6; }
15307 # Run a test program that contains a call to tputs, a call that is
15308 # never executed. This tests whether a pre-'main' dynamic linker
15309 # works with the library. It's too much trouble to actually call
15310 # tputs in the test program, due to portability hassles. When
15311 # cross-compiling, assume the test program will run if it links.
15313 if test "${opsys}" = "mingw32"; then
15314 msg='none required'
15315 else
15316 # Maybe curses should be tried earlier?
15317 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
15318 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
15319 OLIBS=$LIBS
15320 if test -z "$tputs_library"; then
15321 LIBS_TERMCAP=
15322 msg='none required'
15323 else
15324 LIBS_TERMCAP=-l$tputs_library
15325 msg=$LIBS_TERMCAP
15326 LIBS="$LIBS_TERMCAP $LIBS"
15328 if test "$cross_compiling" = yes; then :
15329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15330 /* end confdefs.h. */
15332 extern void tputs (const char *, int, int (*)(int));
15333 int main (int argc, char **argv)
15335 if (argc == 10000)
15336 tputs (argv[0], 0, 0);
15337 return 0;
15340 _ACEOF
15341 if ac_fn_c_try_link "$LINENO"; then :
15343 else
15344 msg=no
15346 rm -f core conftest.err conftest.$ac_objext \
15347 conftest$ac_exeext conftest.$ac_ext
15348 else
15349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15350 /* end confdefs.h. */
15352 extern void tputs (const char *, int, int (*)(int));
15353 int main (int argc, char **argv)
15355 if (argc == 10000)
15356 tputs (argv[0], 0, 0);
15357 return 0;
15360 _ACEOF
15361 if ac_fn_c_try_run "$LINENO"; then :
15363 else
15364 msg=no
15366 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15367 conftest.$ac_objext conftest.beam conftest.$ac_ext
15370 LIBS=$OLIBS
15371 if test "X$msg" != Xno; then
15372 break
15374 done
15376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
15377 $as_echo "$msg" >&6; }
15378 if test "X$msg" = Xno; then
15379 as_fn_error "The required function \`tputs' was not found in any library.
15380 The following libraries were tried (in order):
15381 libtinfo, libncurses, libterminfo, libtermcap, libcurses
15382 Please try installing whichever of these libraries is most appropriate
15383 for your system, together with its header files.
15384 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
15387 ## Use termcap instead of terminfo?
15388 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
15389 TERMINFO=yes
15390 ## FIXME? In the cases below where we unconditionally set
15391 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
15392 ## if that was found above to have tputs.
15393 ## Should we use the gnu* logic everywhere?
15394 case "$opsys" in
15395 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
15396 ## The ncurses library has been moved out of the System framework in
15397 ## Mac OS X 10.2. So if configure detects it, set the command-line
15398 ## option to use it.
15399 darwin) LIBS_TERMCAP="-lncurses" ;;
15401 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
15403 freebsd)
15404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
15405 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
15406 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
15407 $as_echo_n "(cached) " >&6
15408 else
15409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15410 /* end confdefs.h. */
15411 #include <osreldate.h>
15413 main ()
15415 #if __FreeBSD_version < 400000
15416 fail;
15417 #endif
15420 return 0;
15422 _ACEOF
15423 if ac_fn_c_try_link "$LINENO"; then :
15424 emacs_cv_freebsd_terminfo=yes
15425 else
15426 emacs_cv_freebsd_terminfo=no
15428 rm -f core conftest.err conftest.$ac_objext \
15429 conftest$ac_exeext conftest.$ac_ext
15433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
15434 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
15436 if test $emacs_cv_freebsd_terminfo = yes; then
15437 LIBS_TERMCAP="-lncurses"
15438 else
15439 TERMINFO=no
15440 LIBS_TERMCAP="-ltermcap"
15444 mingw32)
15445 TERMINFO=no
15446 LIBS_TERMCAP=
15449 netbsd)
15450 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15451 TERMINFO=no
15452 LIBS_TERMCAP="-ltermcap"
15456 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15458 ## hpux: Make sure we get select from libc rather than from libcurses
15459 ## because libcurses on HPUX 10.10 has a broken version of select.
15460 ## We used to use -lc -lcurses, but this may be cleaner.
15461 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15462 # set that way, now it uses the default). Isn't this a contradiction?
15463 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15465 esac
15467 TERMCAP_OBJ=tparam.o
15468 if test $TERMINFO = yes; then
15470 $as_echo "#define TERMINFO 1" >>confdefs.h
15472 TERMCAP_OBJ=terminfo.o
15474 if test "X$LIBS_TERMCAP" = "X-lncurses"; then
15476 $as_echo "#define USE_NCURSES 1" >>confdefs.h
15483 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15484 # On Darwin, res_init appears not to be useful: see bug#562 and
15485 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15486 resolv=no
15488 if test $opsys != darwin; then
15490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15491 /* end confdefs.h. */
15492 #include <netinet/in.h>
15493 #include <arpa/nameser.h>
15494 #include <resolv.h>
15496 main ()
15498 return res_init();
15500 return 0;
15502 _ACEOF
15503 if ac_fn_c_try_link "$LINENO"; then :
15504 have_res_init=yes
15505 else
15506 have_res_init=no
15508 rm -f core conftest.err conftest.$ac_objext \
15509 conftest$ac_exeext conftest.$ac_ext
15510 if test "$have_res_init" = no; then
15511 OLIBS="$LIBS"
15512 LIBS="$LIBS -lresolv"
15513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15514 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15516 /* end confdefs.h. */
15517 #include <netinet/in.h>
15518 #include <arpa/nameser.h>
15519 #include <resolv.h>
15521 main ()
15523 return res_init();
15525 return 0;
15527 _ACEOF
15528 if ac_fn_c_try_link "$LINENO"; then :
15529 have_res_init=yes
15530 else
15531 have_res_init=no
15533 rm -f core conftest.err conftest.$ac_objext \
15534 conftest$ac_exeext conftest.$ac_ext
15535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15536 $as_echo "$have_res_init" >&6; }
15537 if test "$have_res_init" = yes ; then
15538 resolv=yes
15540 LIBS="$OLIBS"
15543 if test "$have_res_init" = yes; then
15545 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15549 # Do we need the Hesiod library to provide the support routines?
15550 LIBHESIOD=
15551 if test "$with_hesiod" != no ; then
15552 # Don't set $LIBS here -- see comments above. FIXME which comments?
15553 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15554 if test "x$ac_cv_func_res_send" = x""yes; then :
15556 else
15557 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15558 if test "x$ac_cv_func___res_send" = x""yes; then :
15560 else
15561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15562 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15563 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15564 $as_echo_n "(cached) " >&6
15565 else
15566 ac_check_lib_save_LIBS=$LIBS
15567 LIBS="-lresolv $LIBS"
15568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15569 /* end confdefs.h. */
15571 /* Override any GCC internal prototype to avoid an error.
15572 Use char because int might match the return type of a GCC
15573 builtin and then its argument prototype would still apply. */
15574 #ifdef __cplusplus
15575 extern "C"
15576 #endif
15577 char res_send ();
15579 main ()
15581 return res_send ();
15583 return 0;
15585 _ACEOF
15586 if ac_fn_c_try_link "$LINENO"; then :
15587 ac_cv_lib_resolv_res_send=yes
15588 else
15589 ac_cv_lib_resolv_res_send=no
15591 rm -f core conftest.err conftest.$ac_objext \
15592 conftest$ac_exeext conftest.$ac_ext
15593 LIBS=$ac_check_lib_save_LIBS
15595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15596 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15597 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15598 resolv=yes
15599 else
15600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15601 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15602 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15603 $as_echo_n "(cached) " >&6
15604 else
15605 ac_check_lib_save_LIBS=$LIBS
15606 LIBS="-lresolv $LIBS"
15607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15608 /* end confdefs.h. */
15610 /* Override any GCC internal prototype to avoid an error.
15611 Use char because int might match the return type of a GCC
15612 builtin and then its argument prototype would still apply. */
15613 #ifdef __cplusplus
15614 extern "C"
15615 #endif
15616 char __res_send ();
15618 main ()
15620 return __res_send ();
15622 return 0;
15624 _ACEOF
15625 if ac_fn_c_try_link "$LINENO"; then :
15626 ac_cv_lib_resolv___res_send=yes
15627 else
15628 ac_cv_lib_resolv___res_send=no
15630 rm -f core conftest.err conftest.$ac_objext \
15631 conftest$ac_exeext conftest.$ac_ext
15632 LIBS=$ac_check_lib_save_LIBS
15634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15635 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15636 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15637 resolv=yes
15646 if test "$resolv" = yes ; then
15647 RESOLVLIB=-lresolv
15648 else
15649 RESOLVLIB=
15651 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15652 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15654 else
15655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15656 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15657 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15658 $as_echo_n "(cached) " >&6
15659 else
15660 ac_check_lib_save_LIBS=$LIBS
15661 LIBS="-lhesiod $RESOLVLIB $LIBS"
15662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15663 /* end confdefs.h. */
15665 /* Override any GCC internal prototype to avoid an error.
15666 Use char because int might match the return type of a GCC
15667 builtin and then its argument prototype would still apply. */
15668 #ifdef __cplusplus
15669 extern "C"
15670 #endif
15671 char hes_getmailhost ();
15673 main ()
15675 return hes_getmailhost ();
15677 return 0;
15679 _ACEOF
15680 if ac_fn_c_try_link "$LINENO"; then :
15681 ac_cv_lib_hesiod_hes_getmailhost=yes
15682 else
15683 ac_cv_lib_hesiod_hes_getmailhost=no
15685 rm -f core conftest.err conftest.$ac_objext \
15686 conftest$ac_exeext conftest.$ac_ext
15687 LIBS=$ac_check_lib_save_LIBS
15689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15690 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15691 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15692 hesiod=yes
15693 else
15700 if test x"$hesiod" = xyes; then
15701 LIBHESIOD=-lhesiod
15706 # Do we need libresolv (due to res_init or Hesiod)?
15707 if test "$resolv" = yes && test $opsys != darwin; then
15708 LIBRESOLV=-lresolv
15709 else
15710 LIBRESOLV=
15714 # These tell us which Kerberos-related libraries to use.
15715 COM_ERRLIB=
15716 CRYPTOLIB=
15717 KRB5LIB=
15718 DESLIB=
15719 KRB4LIB=
15721 if test "${with_kerberos}" != no; then
15722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15723 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15724 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15725 $as_echo_n "(cached) " >&6
15726 else
15727 ac_check_lib_save_LIBS=$LIBS
15728 LIBS="-lcom_err $LIBS"
15729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15730 /* end confdefs.h. */
15732 /* Override any GCC internal prototype to avoid an error.
15733 Use char because int might match the return type of a GCC
15734 builtin and then its argument prototype would still apply. */
15735 #ifdef __cplusplus
15736 extern "C"
15737 #endif
15738 char com_err ();
15740 main ()
15742 return com_err ();
15744 return 0;
15746 _ACEOF
15747 if ac_fn_c_try_link "$LINENO"; then :
15748 ac_cv_lib_com_err_com_err=yes
15749 else
15750 ac_cv_lib_com_err_com_err=no
15752 rm -f core conftest.err conftest.$ac_objext \
15753 conftest$ac_exeext conftest.$ac_ext
15754 LIBS=$ac_check_lib_save_LIBS
15756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15757 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15758 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15759 have_com_err=yes
15760 else
15761 have_com_err=no
15764 if test $have_com_err = yes; then
15765 COM_ERRLIB=-lcom_err
15766 LIBS="$COM_ERRLIB $LIBS"
15768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15769 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15770 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15771 $as_echo_n "(cached) " >&6
15772 else
15773 ac_check_lib_save_LIBS=$LIBS
15774 LIBS="-lcrypto $LIBS"
15775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15776 /* end confdefs.h. */
15778 /* Override any GCC internal prototype to avoid an error.
15779 Use char because int might match the return type of a GCC
15780 builtin and then its argument prototype would still apply. */
15781 #ifdef __cplusplus
15782 extern "C"
15783 #endif
15784 char mit_des_cbc_encrypt ();
15786 main ()
15788 return mit_des_cbc_encrypt ();
15790 return 0;
15792 _ACEOF
15793 if ac_fn_c_try_link "$LINENO"; then :
15794 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15795 else
15796 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15798 rm -f core conftest.err conftest.$ac_objext \
15799 conftest$ac_exeext conftest.$ac_ext
15800 LIBS=$ac_check_lib_save_LIBS
15802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15803 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15804 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15805 have_crypto=yes
15806 else
15807 have_crypto=no
15810 if test $have_crypto = yes; then
15811 CRYPTOLIB=-lcrypto
15812 LIBS="$CRYPTOLIB $LIBS"
15814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15815 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15816 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15817 $as_echo_n "(cached) " >&6
15818 else
15819 ac_check_lib_save_LIBS=$LIBS
15820 LIBS="-lk5crypto $LIBS"
15821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15822 /* end confdefs.h. */
15824 /* Override any GCC internal prototype to avoid an error.
15825 Use char because int might match the return type of a GCC
15826 builtin and then its argument prototype would still apply. */
15827 #ifdef __cplusplus
15828 extern "C"
15829 #endif
15830 char mit_des_cbc_encrypt ();
15832 main ()
15834 return mit_des_cbc_encrypt ();
15836 return 0;
15838 _ACEOF
15839 if ac_fn_c_try_link "$LINENO"; then :
15840 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15841 else
15842 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15844 rm -f core conftest.err conftest.$ac_objext \
15845 conftest$ac_exeext conftest.$ac_ext
15846 LIBS=$ac_check_lib_save_LIBS
15848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15849 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15850 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15851 have_k5crypto=yes
15852 else
15853 have_k5crypto=no
15856 if test $have_k5crypto = yes; then
15857 CRYPTOLIB=-lk5crypto
15858 LIBS="$CRYPTOLIB $LIBS"
15860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15861 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15862 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15863 $as_echo_n "(cached) " >&6
15864 else
15865 ac_check_lib_save_LIBS=$LIBS
15866 LIBS="-lkrb5 $LIBS"
15867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15868 /* end confdefs.h. */
15870 /* Override any GCC internal prototype to avoid an error.
15871 Use char because int might match the return type of a GCC
15872 builtin and then its argument prototype would still apply. */
15873 #ifdef __cplusplus
15874 extern "C"
15875 #endif
15876 char krb5_init_context ();
15878 main ()
15880 return krb5_init_context ();
15882 return 0;
15884 _ACEOF
15885 if ac_fn_c_try_link "$LINENO"; then :
15886 ac_cv_lib_krb5_krb5_init_context=yes
15887 else
15888 ac_cv_lib_krb5_krb5_init_context=no
15890 rm -f core conftest.err conftest.$ac_objext \
15891 conftest$ac_exeext conftest.$ac_ext
15892 LIBS=$ac_check_lib_save_LIBS
15894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15895 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15896 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15897 have_krb5=yes
15898 else
15899 have_krb5=no
15902 if test $have_krb5=yes; then
15903 KRB5LIB=-lkrb5
15904 LIBS="$KRB5LIB $LIBS"
15906 if test "${with_kerberos5}" = no; then
15907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15908 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15909 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15910 $as_echo_n "(cached) " >&6
15911 else
15912 ac_check_lib_save_LIBS=$LIBS
15913 LIBS="-ldes425 $LIBS"
15914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15915 /* end confdefs.h. */
15917 /* Override any GCC internal prototype to avoid an error.
15918 Use char because int might match the return type of a GCC
15919 builtin and then its argument prototype would still apply. */
15920 #ifdef __cplusplus
15921 extern "C"
15922 #endif
15923 char des_cbc_encrypt ();
15925 main ()
15927 return des_cbc_encrypt ();
15929 return 0;
15931 _ACEOF
15932 if ac_fn_c_try_link "$LINENO"; then :
15933 ac_cv_lib_des425_des_cbc_encrypt=yes
15934 else
15935 ac_cv_lib_des425_des_cbc_encrypt=no
15937 rm -f core conftest.err conftest.$ac_objext \
15938 conftest$ac_exeext conftest.$ac_ext
15939 LIBS=$ac_check_lib_save_LIBS
15941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15942 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15943 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15944 have_des425=yes
15945 else
15946 have_des425=no
15949 if test $have_des425 = yes; then
15950 DESLIB=-ldes425
15951 LIBS="$DESLIB $LIBS"
15952 else
15953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15954 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15955 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15956 $as_echo_n "(cached) " >&6
15957 else
15958 ac_check_lib_save_LIBS=$LIBS
15959 LIBS="-ldes $LIBS"
15960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15961 /* end confdefs.h. */
15963 /* Override any GCC internal prototype to avoid an error.
15964 Use char because int might match the return type of a GCC
15965 builtin and then its argument prototype would still apply. */
15966 #ifdef __cplusplus
15967 extern "C"
15968 #endif
15969 char des_cbc_encrypt ();
15971 main ()
15973 return des_cbc_encrypt ();
15975 return 0;
15977 _ACEOF
15978 if ac_fn_c_try_link "$LINENO"; then :
15979 ac_cv_lib_des_des_cbc_encrypt=yes
15980 else
15981 ac_cv_lib_des_des_cbc_encrypt=no
15983 rm -f core conftest.err conftest.$ac_objext \
15984 conftest$ac_exeext conftest.$ac_ext
15985 LIBS=$ac_check_lib_save_LIBS
15987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
15988 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
15989 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
15990 have_des=yes
15991 else
15992 have_des=no
15995 if test $have_des = yes; then
15996 DESLIB=-ldes
15997 LIBS="$DESLIB $LIBS"
16000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
16001 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
16002 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
16003 $as_echo_n "(cached) " >&6
16004 else
16005 ac_check_lib_save_LIBS=$LIBS
16006 LIBS="-lkrb4 $LIBS"
16007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16008 /* end confdefs.h. */
16010 /* Override any GCC internal prototype to avoid an error.
16011 Use char because int might match the return type of a GCC
16012 builtin and then its argument prototype would still apply. */
16013 #ifdef __cplusplus
16014 extern "C"
16015 #endif
16016 char krb_get_cred ();
16018 main ()
16020 return krb_get_cred ();
16022 return 0;
16024 _ACEOF
16025 if ac_fn_c_try_link "$LINENO"; then :
16026 ac_cv_lib_krb4_krb_get_cred=yes
16027 else
16028 ac_cv_lib_krb4_krb_get_cred=no
16030 rm -f core conftest.err conftest.$ac_objext \
16031 conftest$ac_exeext conftest.$ac_ext
16032 LIBS=$ac_check_lib_save_LIBS
16034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
16035 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
16036 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
16037 have_krb4=yes
16038 else
16039 have_krb4=no
16042 if test $have_krb4 = yes; then
16043 KRB4LIB=-lkrb4
16044 LIBS="$KRB4LIB $LIBS"
16045 else
16046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
16047 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
16048 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
16049 $as_echo_n "(cached) " >&6
16050 else
16051 ac_check_lib_save_LIBS=$LIBS
16052 LIBS="-lkrb $LIBS"
16053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16054 /* end confdefs.h. */
16056 /* Override any GCC internal prototype to avoid an error.
16057 Use char because int might match the return type of a GCC
16058 builtin and then its argument prototype would still apply. */
16059 #ifdef __cplusplus
16060 extern "C"
16061 #endif
16062 char krb_get_cred ();
16064 main ()
16066 return krb_get_cred ();
16068 return 0;
16070 _ACEOF
16071 if ac_fn_c_try_link "$LINENO"; then :
16072 ac_cv_lib_krb_krb_get_cred=yes
16073 else
16074 ac_cv_lib_krb_krb_get_cred=no
16076 rm -f core conftest.err conftest.$ac_objext \
16077 conftest$ac_exeext conftest.$ac_ext
16078 LIBS=$ac_check_lib_save_LIBS
16080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
16081 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
16082 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
16083 have_krb=yes
16084 else
16085 have_krb=no
16088 if test $have_krb = yes; then
16089 KRB4LIB=-lkrb
16090 LIBS="$KRB4LIB $LIBS"
16095 if test "${with_kerberos5}" != no; then
16096 for ac_header in krb5.h
16097 do :
16098 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
16099 if test "x$ac_cv_header_krb5_h" = x""yes; then :
16100 cat >>confdefs.h <<_ACEOF
16101 #define HAVE_KRB5_H 1
16102 _ACEOF
16103 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
16105 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
16107 cat >>confdefs.h <<_ACEOF
16108 #define HAVE_KRB5_ERROR_TEXT 1
16109 _ACEOF
16113 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
16115 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
16117 cat >>confdefs.h <<_ACEOF
16118 #define HAVE_KRB5_ERROR_E_TEXT 1
16119 _ACEOF
16126 done
16128 else
16129 for ac_header in krb.h
16130 do :
16131 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
16132 if test "x$ac_cv_header_krb_h" = x""yes; then :
16133 cat >>confdefs.h <<_ACEOF
16134 #define HAVE_KRB_H 1
16135 _ACEOF
16137 else
16138 for ac_header in kerberosIV/krb.h
16139 do :
16140 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
16141 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
16142 cat >>confdefs.h <<_ACEOF
16143 #define HAVE_KERBEROSIV_KRB_H 1
16144 _ACEOF
16146 else
16147 for ac_header in kerberos/krb.h
16148 do :
16149 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
16150 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
16151 cat >>confdefs.h <<_ACEOF
16152 #define HAVE_KERBEROS_KRB_H 1
16153 _ACEOF
16157 done
16161 done
16165 done
16168 for ac_header in com_err.h
16169 do :
16170 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
16171 if test "x$ac_cv_header_com_err_h" = x""yes; then :
16172 cat >>confdefs.h <<_ACEOF
16173 #define HAVE_COM_ERR_H 1
16174 _ACEOF
16178 done
16188 for ac_header in valgrind/valgrind.h
16189 do :
16190 ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default"
16191 if test "x$ac_cv_header_valgrind_valgrind_h" = x""yes; then :
16192 cat >>confdefs.h <<_ACEOF
16193 #define HAVE_VALGRIND_VALGRIND_H 1
16194 _ACEOF
16198 done
16204 for ac_func in $ac_func_list
16205 do :
16206 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16207 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16208 eval as_val=\$$as_ac_var
16209 if test "x$as_val" = x""yes; then :
16210 cat >>confdefs.h <<_ACEOF
16211 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16212 _ACEOF
16215 done
16220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
16221 $as_echo_n "checking whether localtime caches TZ... " >&6; }
16222 if test "${emacs_cv_localtime_cache+set}" = set; then :
16223 $as_echo_n "(cached) " >&6
16224 else
16225 if test x$ac_cv_func_tzset = xyes; then
16226 if test "$cross_compiling" = yes; then :
16227 # If we have tzset, assume the worst when cross-compiling.
16228 emacs_cv_localtime_cache=yes
16229 else
16230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16231 /* end confdefs.h. */
16232 #include <time.h>
16233 char TZ_GMT0[] = "TZ=GMT0";
16234 char TZ_PST8[] = "TZ=PST8";
16235 main()
16237 time_t now = time ((time_t *) 0);
16238 int hour_GMT0, hour_unset;
16239 if (putenv (TZ_GMT0) != 0)
16240 exit (1);
16241 hour_GMT0 = localtime (&now)->tm_hour;
16242 unsetenv("TZ");
16243 hour_unset = localtime (&now)->tm_hour;
16244 if (putenv (TZ_PST8) != 0)
16245 exit (1);
16246 if (localtime (&now)->tm_hour == hour_GMT0)
16247 exit (1);
16248 unsetenv("TZ");
16249 if (localtime (&now)->tm_hour != hour_unset)
16250 exit (1);
16251 exit (0);
16253 _ACEOF
16254 if ac_fn_c_try_run "$LINENO"; then :
16255 emacs_cv_localtime_cache=no
16256 else
16257 emacs_cv_localtime_cache=yes
16259 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16260 conftest.$ac_objext conftest.beam conftest.$ac_ext
16263 else
16264 # If we lack tzset, report that localtime does not cache TZ,
16265 # since we can't invalidate the cache if we don't have tzset.
16266 emacs_cv_localtime_cache=no
16269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
16270 $as_echo "$emacs_cv_localtime_cache" >&6; }
16271 if test $emacs_cv_localtime_cache = yes; then
16273 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
16277 ok_so_far=yes
16278 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
16279 if test "x$ac_cv_func_socket" = x""yes; then :
16281 else
16282 ok_so_far=no
16285 if test $ok_so_far = yes; then
16286 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
16287 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
16289 else
16290 ok_so_far=no
16295 if test $ok_so_far = yes; then
16296 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
16297 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
16299 else
16300 ok_so_far=no
16305 if test $ok_so_far = yes; then
16307 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
16311 case $canonical in
16312 *-solaris2.4 | *-solaris2.4.*)
16313 : ${ac_cv_func_vfork_works=no};;
16314 esac
16316 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
16317 if test "x$ac_cv_type_pid_t" = x""yes; then :
16319 else
16321 cat >>confdefs.h <<_ACEOF
16322 #define pid_t int
16323 _ACEOF
16327 for ac_header in vfork.h
16328 do :
16329 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
16330 if test "x$ac_cv_header_vfork_h" = x""yes; then :
16331 cat >>confdefs.h <<_ACEOF
16332 #define HAVE_VFORK_H 1
16333 _ACEOF
16337 done
16339 for ac_func in fork vfork
16340 do :
16341 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16342 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16343 eval as_val=\$$as_ac_var
16344 if test "x$as_val" = x""yes; then :
16345 cat >>confdefs.h <<_ACEOF
16346 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16347 _ACEOF
16350 done
16352 if test "x$ac_cv_func_fork" = xyes; then
16353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
16354 $as_echo_n "checking for working fork... " >&6; }
16355 if test "${ac_cv_func_fork_works+set}" = set; then :
16356 $as_echo_n "(cached) " >&6
16357 else
16358 if test "$cross_compiling" = yes; then :
16359 ac_cv_func_fork_works=cross
16360 else
16361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16362 /* end confdefs.h. */
16363 $ac_includes_default
16365 main ()
16368 /* By Ruediger Kuhlmann. */
16369 return fork () < 0;
16372 return 0;
16374 _ACEOF
16375 if ac_fn_c_try_run "$LINENO"; then :
16376 ac_cv_func_fork_works=yes
16377 else
16378 ac_cv_func_fork_works=no
16380 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16381 conftest.$ac_objext conftest.beam conftest.$ac_ext
16385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
16386 $as_echo "$ac_cv_func_fork_works" >&6; }
16388 else
16389 ac_cv_func_fork_works=$ac_cv_func_fork
16391 if test "x$ac_cv_func_fork_works" = xcross; then
16392 case $host in
16393 *-*-amigaos* | *-*-msdosdjgpp*)
16394 # Override, as these systems have only a dummy fork() stub
16395 ac_cv_func_fork_works=no
16398 ac_cv_func_fork_works=yes
16400 esac
16401 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
16402 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
16404 ac_cv_func_vfork_works=$ac_cv_func_vfork
16405 if test "x$ac_cv_func_vfork" = xyes; then
16406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
16407 $as_echo_n "checking for working vfork... " >&6; }
16408 if test "${ac_cv_func_vfork_works+set}" = set; then :
16409 $as_echo_n "(cached) " >&6
16410 else
16411 if test "$cross_compiling" = yes; then :
16412 ac_cv_func_vfork_works=cross
16413 else
16414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16415 /* end confdefs.h. */
16416 /* Thanks to Paul Eggert for this test. */
16417 $ac_includes_default
16418 #include <sys/wait.h>
16419 #ifdef HAVE_VFORK_H
16420 # include <vfork.h>
16421 #endif
16422 /* On some sparc systems, changes by the child to local and incoming
16423 argument registers are propagated back to the parent. The compiler
16424 is told about this with #include <vfork.h>, but some compilers
16425 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
16426 static variable whose address is put into a register that is
16427 clobbered by the vfork. */
16428 static void
16429 #ifdef __cplusplus
16430 sparc_address_test (int arg)
16431 # else
16432 sparc_address_test (arg) int arg;
16433 #endif
16435 static pid_t child;
16436 if (!child) {
16437 child = vfork ();
16438 if (child < 0) {
16439 perror ("vfork");
16440 _exit(2);
16442 if (!child) {
16443 arg = getpid();
16444 write(-1, "", 0);
16445 _exit (arg);
16451 main ()
16453 pid_t parent = getpid ();
16454 pid_t child;
16456 sparc_address_test (0);
16458 child = vfork ();
16460 if (child == 0) {
16461 /* Here is another test for sparc vfork register problems. This
16462 test uses lots of local variables, at least as many local
16463 variables as main has allocated so far including compiler
16464 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16465 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16466 reuse the register of parent for one of the local variables,
16467 since it will think that parent can't possibly be used any more
16468 in this routine. Assigning to the local variable will thus
16469 munge parent in the parent process. */
16470 pid_t
16471 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16472 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16473 /* Convince the compiler that p..p7 are live; otherwise, it might
16474 use the same hardware register for all 8 local variables. */
16475 if (p != p1 || p != p2 || p != p3 || p != p4
16476 || p != p5 || p != p6 || p != p7)
16477 _exit(1);
16479 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16480 from child file descriptors. If the child closes a descriptor
16481 before it execs or exits, this munges the parent's descriptor
16482 as well. Test for this by closing stdout in the child. */
16483 _exit(close(fileno(stdout)) != 0);
16484 } else {
16485 int status;
16486 struct stat st;
16488 while (wait(&status) != child)
16490 return (
16491 /* Was there some problem with vforking? */
16492 child < 0
16494 /* Did the child fail? (This shouldn't happen.) */
16495 || status
16497 /* Did the vfork/compiler bug occur? */
16498 || parent != getpid()
16500 /* Did the file descriptor bug occur? */
16501 || fstat(fileno(stdout), &st) != 0
16505 _ACEOF
16506 if ac_fn_c_try_run "$LINENO"; then :
16507 ac_cv_func_vfork_works=yes
16508 else
16509 ac_cv_func_vfork_works=no
16511 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16512 conftest.$ac_objext conftest.beam conftest.$ac_ext
16516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16517 $as_echo "$ac_cv_func_vfork_works" >&6; }
16520 if test "x$ac_cv_func_fork_works" = xcross; then
16521 ac_cv_func_vfork_works=$ac_cv_func_vfork
16522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16523 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16526 if test "x$ac_cv_func_vfork_works" = xyes; then
16528 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16530 else
16532 $as_echo "#define vfork fork" >>confdefs.h
16535 if test "x$ac_cv_func_fork_works" = xyes; then
16537 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16542 for ac_func in snprintf
16543 do :
16544 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16545 if test "x$ac_cv_func_snprintf" = x""yes; then :
16546 cat >>confdefs.h <<_ACEOF
16547 #define HAVE_SNPRINTF 1
16548 _ACEOF
16551 done
16554 XGSELOBJ=
16555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16556 $as_echo_n "checking whether GLib is linked in... " >&6; }
16557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16558 /* end confdefs.h. */
16559 #include <glib.h>
16562 main ()
16564 g_print ("Hello world");
16566 return 0;
16568 _ACEOF
16569 if ac_fn_c_try_link "$LINENO"; then :
16570 links_glib=yes
16571 else
16572 links_glib=no
16574 rm -f core conftest.err conftest.$ac_objext \
16575 conftest$ac_exeext conftest.$ac_ext
16576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16577 $as_echo "$links_glib" >&6; }
16578 if test "${links_glib}" = "yes"; then
16580 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16582 if test "$HAVE_NS" = no;then
16583 XGSELOBJ=xgselect.o
16588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16589 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16590 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16591 $as_echo_n "(cached) " >&6
16592 else
16593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16594 /* end confdefs.h. */
16595 #include <langinfo.h>
16597 main ()
16599 char* cs = nl_langinfo(CODESET);
16601 return 0;
16603 _ACEOF
16604 if ac_fn_c_try_link "$LINENO"; then :
16605 emacs_cv_langinfo_codeset=yes
16606 else
16607 emacs_cv_langinfo_codeset=no
16609 rm -f core conftest.err conftest.$ac_objext \
16610 conftest$ac_exeext conftest.$ac_ext
16613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16614 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16615 if test $emacs_cv_langinfo_codeset = yes; then
16617 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16622 $as_echo_n "checking for mbstate_t... " >&6; }
16623 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16624 $as_echo_n "(cached) " >&6
16625 else
16626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16627 /* end confdefs.h. */
16628 $ac_includes_default
16629 # include <wchar.h>
16631 main ()
16633 mbstate_t x; return sizeof x;
16635 return 0;
16637 _ACEOF
16638 if ac_fn_c_try_compile "$LINENO"; then :
16639 ac_cv_type_mbstate_t=yes
16640 else
16641 ac_cv_type_mbstate_t=no
16643 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16646 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16647 if test $ac_cv_type_mbstate_t = yes; then
16649 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16651 else
16653 $as_echo "#define mbstate_t int" >>confdefs.h
16657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16658 $as_echo_n "checking for C restricted array declarations... " >&6; }
16659 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16660 $as_echo_n "(cached) " >&6
16661 else
16662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16663 /* end confdefs.h. */
16664 void fred (int x[__restrict]);
16666 main ()
16670 return 0;
16672 _ACEOF
16673 if ac_fn_c_try_compile "$LINENO"; then :
16674 emacs_cv_c_restrict_arr=yes
16675 else
16676 emacs_cv_c_restrict_arr=no
16678 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16681 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16682 if test "$emacs_cv_c_restrict_arr" = yes; then
16684 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16689 if test "${opsys}" != "mingw32"; then
16691 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16696 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16699 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16700 if test "${opsys}" != "mingw32"; then
16702 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16707 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16713 if test "${opsys}" = "mingw32"; then
16714 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16716 else
16717 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16722 if test "${opsys}" = "mingw32"; then
16723 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16725 else
16726 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16731 $as_echo "#define subprocesses 1" >>confdefs.h
16735 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16740 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16743 if test "${opsys}" = "mingw32"; then
16745 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == ':')" >>confdefs.h
16749 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16753 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16755 else
16757 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16761 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16765 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16771 case $opsys in
16772 aix4-2)
16773 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16774 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16779 hpux*)
16780 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16783 esac
16786 case $opsys in
16787 irix6-5 | sol2* | unixware )
16789 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16792 esac
16794 emacs_broken_SIGIO=no
16796 case $opsys in
16797 hpux* | irix6-5 | openbsd | sol2* | unixware )
16798 emacs_broken_SIGIO=yes
16801 aix4-2)
16803 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16807 freebsd)
16809 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16812 esac
16814 case $opsys in
16815 gnu-* | sol2-10 )
16817 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16820 esac
16822 case $opsys in
16823 darwin | dragonfly | freebsd | netbsd | openbsd )
16825 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16828 esac
16830 case $opsys in
16831 netbsd | openbsd) sound_device="/dev/audio" ;;
16832 *) sound_device="/dev/dsp" ;;
16833 esac
16836 cat >>confdefs.h <<_ACEOF
16837 #define DEFAULT_SOUND_DEVICE "$sound_device"
16838 _ACEOF
16842 case $opsys in
16843 darwin | gnu-linux | gnu-kfreebsd )
16845 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16848 esac
16851 case $opsys in
16852 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16854 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16857 esac
16866 case $opsys in
16867 aix4-2 )
16868 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16870 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16872 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16876 cygwin )
16877 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16879 $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
16881 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16883 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16887 darwin )
16888 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16890 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16892 $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
16894 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16896 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16900 gnu | openbsd )
16901 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16905 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16906 if test "x$ac_cv_func_grantpt" = xyes; then
16908 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16910 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16912 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16914 if test "x$ac_cv_func_posix_openpt" = xyes; then
16915 $as_echo "#define PTY_OPEN do { fd = posix_openpt (O_RDWR | O_CLOEXEC | O_NOCTTY); if (fd < 0 && errno == EINVAL) fd = posix_openpt (O_RDWR | O_NOCTTY); } while (0)" >>confdefs.h
16917 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16919 elif test "x$ac_cv_func_getpt" = xyes; then
16920 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16922 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16924 else
16925 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16928 else
16929 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16934 hpux*)
16935 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16937 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16939 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16943 irix6-5 )
16944 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16946 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16948 $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
16950 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16952 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16956 sol2* )
16957 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16961 unixware )
16962 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16965 esac
16968 case $opsys in
16969 sol2* | unixware )
16970 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16972 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16975 $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
16978 esac
16983 case $opsys in
16984 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
16985 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16989 gnu-linux | gnu-kfreebsd )
16991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
16992 $as_echo_n "checking for signals via characters... " >&6; }
16993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16994 /* end confdefs.h. */
16996 #include <linux/version.h>
16997 #if LINUX_VERSION_CODE < 0x20400
16998 # error "Linux version too old"
16999 #endif
17002 main ()
17006 return 0;
17008 _ACEOF
17009 if ac_fn_c_try_cpp "$LINENO"; then :
17010 emacs_signals_via_chars=yes
17011 else
17012 emacs_signals_via_chars=no
17014 rm -f conftest.err conftest.$ac_ext
17016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
17017 $as_echo "$emacs_signals_via_chars" >&6; }
17018 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
17021 esac
17026 case $opsys in
17027 aix*)
17028 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
17031 hpux*)
17032 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
17035 irix6-5)
17036 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
17039 esac
17044 case $opsys in
17045 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
17048 gnu | dragonfly | freebsd | netbsd | openbsd )
17050 $as_echo "#define TABDLY OXTABS" >>confdefs.h
17052 $as_echo "#define TAB3 OXTABS" >>confdefs.h
17056 gnu-linux | gnu-kfreebsd )
17057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17058 /* end confdefs.h. */
17060 #ifndef __ia64__
17061 # error "not ia64"
17062 #endif
17065 main ()
17069 return 0;
17071 _ACEOF
17072 if ac_fn_c_try_cpp "$LINENO"; then :
17074 $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
17077 rm -f conftest.err conftest.$ac_ext
17080 hpux*)
17082 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
17085 esac
17091 case $opsys in
17092 gnu-linux | gnu-kfreebsd )
17093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17094 /* end confdefs.h. */
17096 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
17097 || defined __alpha__ || defined __mips__ || defined __s390__ \
17098 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
17099 || defined __ia64__ || defined __sh__
17100 /* ok */
17101 #else
17102 # error "setjmp not known to work on this arch"
17103 #endif
17106 main ()
17110 return 0;
17112 _ACEOF
17113 if ac_fn_c_try_cpp "$LINENO"; then :
17114 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17117 rm -f conftest.err conftest.$ac_ext
17119 esac
17122 if test x$GCC = xyes; then
17123 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17125 else
17126 case $opsys in
17127 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
17128 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17131 esac
17133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
17134 $as_echo_n "checking for _setjmp... " >&6; }
17135 if test "${emacs_cv_func__setjmp+set}" = set; then :
17136 $as_echo_n "(cached) " >&6
17137 else
17138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17139 /* end confdefs.h. */
17140 #include <setjmp.h>
17141 #ifdef __MINGW32__
17142 # define _longjmp longjmp
17143 #endif
17146 main ()
17148 jmp_buf j;
17149 if (! _setjmp (j))
17150 _longjmp (j, 1);
17152 return 0;
17154 _ACEOF
17155 if ac_fn_c_try_link "$LINENO"; then :
17156 emacs_cv_func__setjmp=yes
17157 else
17158 emacs_cv_func__setjmp=no
17160 rm -f core conftest.err conftest.$ac_objext \
17161 conftest$ac_exeext conftest.$ac_ext
17163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
17164 $as_echo "$emacs_cv_func__setjmp" >&6; }
17165 if test $emacs_cv_func__setjmp = yes; then
17167 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
17169 else
17170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
17171 $as_echo_n "checking for sigsetjmp... " >&6; }
17172 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
17173 $as_echo_n "(cached) " >&6
17174 else
17175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17176 /* end confdefs.h. */
17177 #include <setjmp.h>
17180 main ()
17182 sigjmp_buf j;
17183 if (! sigsetjmp (j, 1))
17184 siglongjmp (j, 1);
17186 return 0;
17188 _ACEOF
17189 if ac_fn_c_try_link "$LINENO"; then :
17190 emacs_cv_func_sigsetjmp=yes
17191 else
17192 emacs_cv_func_sigsetjmp=no
17194 rm -f core conftest.err conftest.$ac_objext \
17195 conftest$ac_exeext conftest.$ac_ext
17197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
17198 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
17199 if test $emacs_cv_func_sigsetjmp = yes; then
17201 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
17206 case $opsys in
17207 sol2* | unixware )
17209 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
17212 esac
17215 case $opsys in
17216 hpux* | sol2* )
17218 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
17221 esac
17229 case $opsys in
17230 aix4-2)
17231 $as_echo "#define USG /**/" >>confdefs.h
17233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17234 /* end confdefs.h. */
17236 #ifndef _AIX
17237 # error "_AIX not defined"
17238 #endif
17241 main ()
17245 return 0;
17247 _ACEOF
17248 if ac_fn_c_try_cpp "$LINENO"; then :
17250 else
17252 $as_echo "#define _AIX /**/" >>confdefs.h
17255 rm -f conftest.err conftest.$ac_ext
17258 cygwin)
17260 $as_echo "#define CYGWIN 1" >>confdefs.h
17264 darwin)
17266 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
17270 gnu-linux | gnu-kfreebsd )
17271 $as_echo "#define USG /**/" >>confdefs.h
17274 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
17278 hpux*)
17279 $as_echo "#define USG /**/" >>confdefs.h
17282 $as_echo "#define HPUX /**/" >>confdefs.h
17286 irix6-5)
17287 $as_echo "#define USG /**/" >>confdefs.h
17289 $as_echo "#define USG5_4 /**/" >>confdefs.h
17292 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
17296 mingw32)
17297 $as_echo "#define DOS_NT /**/" >>confdefs.h
17300 $as_echo "#define WINDOWSNT 1" >>confdefs.h
17302 if test "x$ac_enable_checking" != "x" ; then
17304 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
17309 sol2*)
17310 $as_echo "#define USG /**/" >>confdefs.h
17312 $as_echo "#define USG5_4 /**/" >>confdefs.h
17315 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
17319 unixware)
17320 $as_echo "#define USG /**/" >>confdefs.h
17322 $as_echo "#define USG5_4 /**/" >>confdefs.h
17325 esac
17327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
17328 $as_echo_n "checking for usable FIONREAD... " >&6; }
17329 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
17330 $as_echo_n "(cached) " >&6
17331 else
17332 case $opsys in
17333 aix4-2)
17334 emacs_cv_usable_FIONREAD=no
17337 mingw32)
17338 emacs_cv_usable_FIONREAD=yes
17342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17343 /* end confdefs.h. */
17344 #include <sys/types.h>
17345 #include <sys/ioctl.h>
17346 #ifdef USG5_4
17347 # include <sys/filio.h>
17348 #endif
17351 main ()
17353 int foo = ioctl (0, FIONREAD, &foo);
17355 return 0;
17357 _ACEOF
17358 if ac_fn_c_try_compile "$LINENO"; then :
17359 emacs_cv_usable_FIONREAD=yes
17360 else
17361 emacs_cv_usable_FIONREAD=no
17363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17365 esac
17367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
17368 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
17369 if test $emacs_cv_usable_FIONREAD = yes; then
17371 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
17374 if test $emacs_broken_SIGIO = no; then
17375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
17376 $as_echo_n "checking for usable SIGIO... " >&6; }
17377 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
17378 $as_echo_n "(cached) " >&6
17379 else
17380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17381 /* end confdefs.h. */
17382 #include <fcntl.h>
17383 #include <signal.h>
17386 main ()
17388 int foo = SIGIO | F_SETFL | FASYNC;
17390 return 0;
17392 _ACEOF
17393 if ac_fn_c_try_compile "$LINENO"; then :
17394 emacs_cv_usable_SIGIO=yes
17395 else
17396 emacs_cv_usable_SIGIO=no
17398 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
17401 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
17402 if test $emacs_cv_usable_SIGIO = yes; then
17404 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
17411 case $opsys in
17412 cygwin)
17414 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
17418 hpux11)
17420 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
17424 irix6-5)
17426 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
17430 sol2-10)
17432 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
17435 esac
17437 # Set up the CFLAGS for real compilation, so we can substitute it.
17438 CFLAGS="$REAL_CFLAGS"
17439 CPPFLAGS="$REAL_CPPFLAGS"
17441 ## Hack to detect a buggy GCC version.
17442 if test "x$GCC" = xyes \
17443 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17444 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17445 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17446 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17449 version=$PACKAGE_VERSION
17451 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17453 cat >>confdefs.h <<_ACEOF
17454 #define COPYRIGHT "$copyright"
17455 _ACEOF
17459 ### Specify what sort of things we'll be editing into Makefile and config.h.
17460 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17463 ## Unused?
17486 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17487 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17488 ## end of LIBX_BASE, but nothing ever set it.
17493 ## Used in lwlib/Makefile.in.
17502 if test -n "${term_header}"; then
17504 cat >>confdefs.h <<_ACEOF
17505 #define TERM_HEADER "${term_header}"
17506 _ACEOF
17511 cat >>confdefs.h <<_ACEOF
17512 #define EMACS_CONFIGURATION "${canonical}"
17513 _ACEOF
17516 cat >>confdefs.h <<_ACEOF
17517 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17518 _ACEOF
17522 case $opsys in
17523 mingw32)
17524 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17527 esac
17529 XMENU_OBJ=
17530 XOBJ=
17531 FONT_OBJ=
17532 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17534 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17536 XMENU_OBJ=xmenu.o
17537 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17538 FONT_OBJ=xfont.o
17539 if test "$HAVE_XFT" = "yes"; then
17540 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17541 elif test "$HAVE_FREETYPE" = "yes"; then
17542 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17550 WIDGET_OBJ=
17551 MOTIF_LIBW=
17552 if test "${USE_X_TOOLKIT}" != "none" ; then
17553 WIDGET_OBJ=widget.o
17555 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17557 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17559 $as_echo "#define USE_LUCID 1" >>confdefs.h
17561 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17563 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17565 MOTIF_LIBW=-lXm
17566 case "$opsys" in
17567 gnu-linux)
17568 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17569 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17572 unixware)
17573 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17574 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17575 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17578 aix4-2)
17579 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17580 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17582 esac
17583 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17588 TOOLKIT_LIBW=
17589 case "$USE_X_TOOLKIT" in
17590 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17591 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17592 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17593 esac
17596 if test "${opsys}" != "mingw32"; then
17597 if test "$USE_X_TOOLKIT" = "none"; then
17598 LIBXT_OTHER="\$(LIBXSM)"
17599 OLDXMENU_TARGET="really-oldXMenu"
17600 else
17601 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17602 OLDXMENU_TARGET="really-lwlib"
17607 ## The X Menu stuff is present in the X10 distribution, but missing
17608 ## from X11. If we have X10, just use the installed library;
17609 ## otherwise, use our own copy.
17610 if test "${HAVE_X11}" = "yes" ; then
17612 $as_echo "#define HAVE_X11 1" >>confdefs.h
17615 if test "$USE_X_TOOLKIT" = "none"; then
17616 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17617 else
17618 OLDXMENU="\${lwlibdir}/liblw.a"
17620 LIBXMENU="\$(OLDXMENU)"
17621 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17622 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17623 else
17624 ## For a syntactically valid Makefile; not actually used for anything.
17625 ## See comments in src/Makefile.in.
17626 OLDXMENU=nothing
17627 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17628 if test "${HAVE_X_WINDOWS}" = "yes"; then
17629 LIBXMENU="-lXMenu"
17630 else
17631 LIBXMENU=
17633 LIBX_OTHER=
17634 OLDXMENU_DEPS=
17637 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17638 OLDXMENU_TARGET=
17639 OLDXMENU=nothing
17640 LIBXMENU=
17641 OLDXMENU_DEPS=
17650 if test "${HAVE_MENUS}" = "yes" ; then
17652 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17656 if test "${GNU_MALLOC}" = "yes" ; then
17658 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17662 RALLOC_OBJ=
17663 if test "${REL_ALLOC}" = "yes" ; then
17665 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17668 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17672 if test "$opsys" = "cygwin"; then
17673 CYGWIN_OBJ="sheap.o cygw32.o"
17674 ## Cygwin differs because of its unexec().
17675 PRE_ALLOC_OBJ=
17676 POST_ALLOC_OBJ=lastfile.o
17677 elif test "$opsys" = "mingw32"; then
17678 CYGWIN_OBJ=
17679 PRE_ALLOC_OBJ=
17680 POST_ALLOC_OBJ=lastfile.o
17681 else
17682 CYGWIN_OBJ=
17683 PRE_ALLOC_OBJ=lastfile.o
17684 POST_ALLOC_OBJ=
17692 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17693 # it temporarily reverts them to their pre-pkg-config values,
17694 # because gnulib needs to work with both src (which uses the
17695 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17696 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17697 # and it therefore needs to run in an environment where LIBS does not
17698 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17699 # for some package unrelated to lib-src.
17700 SAVE_CFLAGS=$CFLAGS
17701 SAVE_LIBS=$LIBS
17702 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17703 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17715 LIBC_FATAL_STDERR_=1
17716 export LIBC_FATAL_STDERR_
17718 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17719 # for constant arguments. Useless!
17720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17721 $as_echo_n "checking for working alloca.h... " >&6; }
17722 if test "${ac_cv_working_alloca_h+set}" = set; then :
17723 $as_echo_n "(cached) " >&6
17724 else
17725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17726 /* end confdefs.h. */
17727 #include <alloca.h>
17729 main ()
17731 char *p = (char *) alloca (2 * sizeof (int));
17732 if (p) return 0;
17734 return 0;
17736 _ACEOF
17737 if ac_fn_c_try_link "$LINENO"; then :
17738 ac_cv_working_alloca_h=yes
17739 else
17740 ac_cv_working_alloca_h=no
17742 rm -f core conftest.err conftest.$ac_objext \
17743 conftest$ac_exeext conftest.$ac_ext
17745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17746 $as_echo "$ac_cv_working_alloca_h" >&6; }
17747 if test $ac_cv_working_alloca_h = yes; then
17749 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17754 $as_echo_n "checking for alloca... " >&6; }
17755 if test "${ac_cv_func_alloca_works+set}" = set; then :
17756 $as_echo_n "(cached) " >&6
17757 else
17758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17759 /* end confdefs.h. */
17760 #ifdef __GNUC__
17761 # define alloca __builtin_alloca
17762 #else
17763 # ifdef _MSC_VER
17764 # include <malloc.h>
17765 # define alloca _alloca
17766 # else
17767 # ifdef HAVE_ALLOCA_H
17768 # include <alloca.h>
17769 # else
17770 # ifdef _AIX
17771 #pragma alloca
17772 # else
17773 # ifndef alloca /* predefined by HP cc +Olibcalls */
17774 char *alloca ();
17775 # endif
17776 # endif
17777 # endif
17778 # endif
17779 #endif
17782 main ()
17784 char *p = (char *) alloca (1);
17785 if (p) return 0;
17787 return 0;
17789 _ACEOF
17790 if ac_fn_c_try_link "$LINENO"; then :
17791 ac_cv_func_alloca_works=yes
17792 else
17793 ac_cv_func_alloca_works=no
17795 rm -f core conftest.err conftest.$ac_objext \
17796 conftest$ac_exeext conftest.$ac_ext
17798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17799 $as_echo "$ac_cv_func_alloca_works" >&6; }
17801 if test $ac_cv_func_alloca_works = yes; then
17803 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17805 else
17806 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17807 # that cause trouble. Some versions do not even contain alloca or
17808 # contain a buggy version. If you still want to use their alloca,
17809 # use ar to extract alloca.o from them instead of compiling alloca.c.
17815 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17817 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17821 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17822 if test "${ac_cv_os_cray+set}" = set; then :
17823 $as_echo_n "(cached) " >&6
17824 else
17825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17826 /* end confdefs.h. */
17827 #if defined CRAY && ! defined CRAY2
17828 webecray
17829 #else
17830 wenotbecray
17831 #endif
17833 _ACEOF
17834 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17835 $EGREP "webecray" >/dev/null 2>&1; then :
17836 ac_cv_os_cray=yes
17837 else
17838 ac_cv_os_cray=no
17840 rm -f conftest*
17843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17844 $as_echo "$ac_cv_os_cray" >&6; }
17845 if test $ac_cv_os_cray = yes; then
17846 for ac_func in _getb67 GETB67 getb67; do
17847 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17848 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17849 eval as_val=\$$as_ac_var
17850 if test "x$as_val" = x""yes; then :
17852 cat >>confdefs.h <<_ACEOF
17853 #define CRAY_STACKSEG_END $ac_func
17854 _ACEOF
17856 break
17859 done
17862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17863 $as_echo_n "checking stack direction for C alloca... " >&6; }
17864 if test "${ac_cv_c_stack_direction+set}" = set; then :
17865 $as_echo_n "(cached) " >&6
17866 else
17867 if test "$cross_compiling" = yes; then :
17868 ac_cv_c_stack_direction=0
17869 else
17870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17871 /* end confdefs.h. */
17872 $ac_includes_default
17874 find_stack_direction (int *addr, int depth)
17876 int dir, dummy = 0;
17877 if (! addr)
17878 addr = &dummy;
17879 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17880 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17881 return dir + dummy;
17885 main (int argc, char **argv)
17887 return find_stack_direction (0, argc + !argv + 20) < 0;
17889 _ACEOF
17890 if ac_fn_c_try_run "$LINENO"; then :
17891 ac_cv_c_stack_direction=1
17892 else
17893 ac_cv_c_stack_direction=-1
17895 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17896 conftest.$ac_objext conftest.beam conftest.$ac_ext
17900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17901 $as_echo "$ac_cv_c_stack_direction" >&6; }
17902 cat >>confdefs.h <<_ACEOF
17903 #define STACK_DIRECTION $ac_cv_c_stack_direction
17904 _ACEOF
17912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17913 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17914 if test "${ac_cv_c_bigendian+set}" = set; then :
17915 $as_echo_n "(cached) " >&6
17916 else
17917 ac_cv_c_bigendian=unknown
17918 # See if we're dealing with a universal compiler.
17919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17920 /* end confdefs.h. */
17921 #ifndef __APPLE_CC__
17922 not a universal capable compiler
17923 #endif
17924 typedef int dummy;
17926 _ACEOF
17927 if ac_fn_c_try_compile "$LINENO"; then :
17929 # Check for potential -arch flags. It is not universal unless
17930 # there are at least two -arch flags with different values.
17931 ac_arch=
17932 ac_prev=
17933 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17934 if test -n "$ac_prev"; then
17935 case $ac_word in
17936 i?86 | x86_64 | ppc | ppc64)
17937 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17938 ac_arch=$ac_word
17939 else
17940 ac_cv_c_bigendian=universal
17941 break
17944 esac
17945 ac_prev=
17946 elif test "x$ac_word" = "x-arch"; then
17947 ac_prev=arch
17949 done
17951 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17952 if test $ac_cv_c_bigendian = unknown; then
17953 # See if sys/param.h defines the BYTE_ORDER macro.
17954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17955 /* end confdefs.h. */
17956 #include <sys/types.h>
17957 #include <sys/param.h>
17960 main ()
17962 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17963 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17964 && LITTLE_ENDIAN)
17965 bogus endian macros
17966 #endif
17969 return 0;
17971 _ACEOF
17972 if ac_fn_c_try_compile "$LINENO"; then :
17973 # It does; now see whether it defined to BIG_ENDIAN or not.
17974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17975 /* end confdefs.h. */
17976 #include <sys/types.h>
17977 #include <sys/param.h>
17980 main ()
17982 #if BYTE_ORDER != BIG_ENDIAN
17983 not big endian
17984 #endif
17987 return 0;
17989 _ACEOF
17990 if ac_fn_c_try_compile "$LINENO"; then :
17991 ac_cv_c_bigendian=yes
17992 else
17993 ac_cv_c_bigendian=no
17995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17999 if test $ac_cv_c_bigendian = unknown; then
18000 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
18001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18002 /* end confdefs.h. */
18003 #include <limits.h>
18006 main ()
18008 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
18009 bogus endian macros
18010 #endif
18013 return 0;
18015 _ACEOF
18016 if ac_fn_c_try_compile "$LINENO"; then :
18017 # It does; now see whether it defined to _BIG_ENDIAN or not.
18018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18019 /* end confdefs.h. */
18020 #include <limits.h>
18023 main ()
18025 #ifndef _BIG_ENDIAN
18026 not big endian
18027 #endif
18030 return 0;
18032 _ACEOF
18033 if ac_fn_c_try_compile "$LINENO"; then :
18034 ac_cv_c_bigendian=yes
18035 else
18036 ac_cv_c_bigendian=no
18038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18042 if test $ac_cv_c_bigendian = unknown; then
18043 # Compile a test program.
18044 if test "$cross_compiling" = yes; then :
18045 # Try to guess by grepping values from an object file.
18046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18047 /* end confdefs.h. */
18048 short int ascii_mm[] =
18049 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
18050 short int ascii_ii[] =
18051 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
18052 int use_ascii (int i) {
18053 return ascii_mm[i] + ascii_ii[i];
18055 short int ebcdic_ii[] =
18056 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
18057 short int ebcdic_mm[] =
18058 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
18059 int use_ebcdic (int i) {
18060 return ebcdic_mm[i] + ebcdic_ii[i];
18062 extern int foo;
18065 main ()
18067 return use_ascii (foo) == use_ebcdic (foo);
18069 return 0;
18071 _ACEOF
18072 if ac_fn_c_try_compile "$LINENO"; then :
18073 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
18074 ac_cv_c_bigendian=yes
18076 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
18077 if test "$ac_cv_c_bigendian" = unknown; then
18078 ac_cv_c_bigendian=no
18079 else
18080 # finding both strings is unlikely to happen, but who knows?
18081 ac_cv_c_bigendian=unknown
18085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18086 else
18087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18088 /* end confdefs.h. */
18089 $ac_includes_default
18091 main ()
18094 /* Are we little or big endian? From Harbison&Steele. */
18095 union
18097 long int l;
18098 char c[sizeof (long int)];
18099 } u;
18100 u.l = 1;
18101 return u.c[sizeof (long int) - 1] == 1;
18104 return 0;
18106 _ACEOF
18107 if ac_fn_c_try_run "$LINENO"; then :
18108 ac_cv_c_bigendian=no
18109 else
18110 ac_cv_c_bigendian=yes
18112 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18113 conftest.$ac_objext conftest.beam conftest.$ac_ext
18118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
18119 $as_echo "$ac_cv_c_bigendian" >&6; }
18120 case $ac_cv_c_bigendian in #(
18121 yes)
18122 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
18123 ;; #(
18125 ;; #(
18126 universal)
18128 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
18130 ;; #(
18132 as_fn_error "unknown endianness
18133 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
18134 esac
18138 GNULIB_CHDIR=0;
18139 GNULIB_CHOWN=0;
18140 GNULIB_CLOSE=0;
18141 GNULIB_DUP=0;
18142 GNULIB_DUP2=0;
18143 GNULIB_DUP3=0;
18144 GNULIB_ENVIRON=0;
18145 GNULIB_EUIDACCESS=0;
18146 GNULIB_FACCESSAT=0;
18147 GNULIB_FCHDIR=0;
18148 GNULIB_FCHOWNAT=0;
18149 GNULIB_FDATASYNC=0;
18150 GNULIB_FSYNC=0;
18151 GNULIB_FTRUNCATE=0;
18152 GNULIB_GETCWD=0;
18153 GNULIB_GETDOMAINNAME=0;
18154 GNULIB_GETDTABLESIZE=0;
18155 GNULIB_GETGROUPS=0;
18156 GNULIB_GETHOSTNAME=0;
18157 GNULIB_GETLOGIN=0;
18158 GNULIB_GETLOGIN_R=0;
18159 GNULIB_GETPAGESIZE=0;
18160 GNULIB_GETUSERSHELL=0;
18161 GNULIB_GROUP_MEMBER=0;
18162 GNULIB_ISATTY=0;
18163 GNULIB_LCHOWN=0;
18164 GNULIB_LINK=0;
18165 GNULIB_LINKAT=0;
18166 GNULIB_LSEEK=0;
18167 GNULIB_PIPE=0;
18168 GNULIB_PIPE2=0;
18169 GNULIB_PREAD=0;
18170 GNULIB_PWRITE=0;
18171 GNULIB_READ=0;
18172 GNULIB_READLINK=0;
18173 GNULIB_READLINKAT=0;
18174 GNULIB_RMDIR=0;
18175 GNULIB_SETHOSTNAME=0;
18176 GNULIB_SLEEP=0;
18177 GNULIB_SYMLINK=0;
18178 GNULIB_SYMLINKAT=0;
18179 GNULIB_TTYNAME_R=0;
18180 GNULIB_UNISTD_H_NONBLOCKING=0;
18181 GNULIB_UNISTD_H_SIGPIPE=0;
18182 GNULIB_UNLINK=0;
18183 GNULIB_UNLINKAT=0;
18184 GNULIB_USLEEP=0;
18185 GNULIB_WRITE=0;
18186 HAVE_CHOWN=1;
18187 HAVE_DUP2=1;
18188 HAVE_DUP3=1;
18189 HAVE_EUIDACCESS=1;
18190 HAVE_FACCESSAT=1;
18191 HAVE_FCHDIR=1;
18192 HAVE_FCHOWNAT=1;
18193 HAVE_FDATASYNC=1;
18194 HAVE_FSYNC=1;
18195 HAVE_FTRUNCATE=1;
18196 HAVE_GETDTABLESIZE=1;
18197 HAVE_GETGROUPS=1;
18198 HAVE_GETHOSTNAME=1;
18199 HAVE_GETLOGIN=1;
18200 HAVE_GETPAGESIZE=1;
18201 HAVE_GROUP_MEMBER=1;
18202 HAVE_LCHOWN=1;
18203 HAVE_LINK=1;
18204 HAVE_LINKAT=1;
18205 HAVE_PIPE=1;
18206 HAVE_PIPE2=1;
18207 HAVE_PREAD=1;
18208 HAVE_PWRITE=1;
18209 HAVE_READLINK=1;
18210 HAVE_READLINKAT=1;
18211 HAVE_SETHOSTNAME=1;
18212 HAVE_SLEEP=1;
18213 HAVE_SYMLINK=1;
18214 HAVE_SYMLINKAT=1;
18215 HAVE_UNLINKAT=1;
18216 HAVE_USLEEP=1;
18217 HAVE_DECL_ENVIRON=1;
18218 HAVE_DECL_FCHDIR=1;
18219 HAVE_DECL_FDATASYNC=1;
18220 HAVE_DECL_GETDOMAINNAME=1;
18221 HAVE_DECL_GETLOGIN_R=1;
18222 HAVE_DECL_GETPAGESIZE=1;
18223 HAVE_DECL_GETUSERSHELL=1;
18224 HAVE_DECL_SETHOSTNAME=1;
18225 HAVE_DECL_TTYNAME_R=1;
18226 HAVE_OS_H=0;
18227 HAVE_SYS_PARAM_H=0;
18228 REPLACE_CHOWN=0;
18229 REPLACE_CLOSE=0;
18230 REPLACE_DUP=0;
18231 REPLACE_DUP2=0;
18232 REPLACE_FCHOWNAT=0;
18233 REPLACE_FTRUNCATE=0;
18234 REPLACE_GETCWD=0;
18235 REPLACE_GETDOMAINNAME=0;
18236 REPLACE_GETLOGIN_R=0;
18237 REPLACE_GETGROUPS=0;
18238 REPLACE_GETPAGESIZE=0;
18239 REPLACE_ISATTY=0;
18240 REPLACE_LCHOWN=0;
18241 REPLACE_LINK=0;
18242 REPLACE_LINKAT=0;
18243 REPLACE_LSEEK=0;
18244 REPLACE_PREAD=0;
18245 REPLACE_PWRITE=0;
18246 REPLACE_READ=0;
18247 REPLACE_READLINK=0;
18248 REPLACE_RMDIR=0;
18249 REPLACE_SLEEP=0;
18250 REPLACE_SYMLINK=0;
18251 REPLACE_TTYNAME_R=0;
18252 REPLACE_UNLINK=0;
18253 REPLACE_UNLINKAT=0;
18254 REPLACE_USLEEP=0;
18255 REPLACE_WRITE=0;
18256 UNISTD_H_HAVE_WINSOCK2_H=0;
18257 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
18261 GNULIB_OPENDIR=0;
18262 GNULIB_READDIR=0;
18263 GNULIB_REWINDDIR=0;
18264 GNULIB_CLOSEDIR=0;
18265 GNULIB_DIRFD=0;
18266 GNULIB_FDOPENDIR=0;
18267 GNULIB_SCANDIR=0;
18268 GNULIB_ALPHASORT=0;
18269 HAVE_OPENDIR=1;
18270 HAVE_READDIR=1;
18271 HAVE_REWINDDIR=1;
18272 HAVE_CLOSEDIR=1;
18273 HAVE_DECL_DIRFD=1;
18274 HAVE_DECL_FDOPENDIR=1;
18275 HAVE_FDOPENDIR=1;
18276 HAVE_SCANDIR=1;
18277 HAVE_ALPHASORT=1;
18278 REPLACE_OPENDIR=0;
18279 REPLACE_CLOSEDIR=0;
18280 REPLACE_DIRFD=0;
18281 REPLACE_FDOPENDIR=0;
18285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
18286 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
18287 if test "${gl_cv_have_include_next+set}" = set; then :
18288 $as_echo_n "(cached) " >&6
18289 else
18290 rm -rf conftestd1a conftestd1b conftestd2
18291 mkdir conftestd1a conftestd1b conftestd2
18292 cat <<EOF > conftestd1a/conftest.h
18293 #define DEFINED_IN_CONFTESTD1
18294 #include_next <conftest.h>
18295 #ifdef DEFINED_IN_CONFTESTD2
18296 int foo;
18297 #else
18298 #error "include_next doesn't work"
18299 #endif
18301 cat <<EOF > conftestd1b/conftest.h
18302 #define DEFINED_IN_CONFTESTD1
18303 #include <stdio.h>
18304 #include_next <conftest.h>
18305 #ifdef DEFINED_IN_CONFTESTD2
18306 int foo;
18307 #else
18308 #error "include_next doesn't work"
18309 #endif
18311 cat <<EOF > conftestd2/conftest.h
18312 #ifndef DEFINED_IN_CONFTESTD1
18313 #error "include_next test doesn't work"
18314 #endif
18315 #define DEFINED_IN_CONFTESTD2
18317 gl_save_CPPFLAGS="$CPPFLAGS"
18318 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
18319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18320 /* end confdefs.h. */
18321 #include <conftest.h>
18322 _ACEOF
18323 if ac_fn_c_try_compile "$LINENO"; then :
18324 gl_cv_have_include_next=yes
18325 else
18326 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
18327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18328 /* end confdefs.h. */
18329 #include <conftest.h>
18330 _ACEOF
18331 if ac_fn_c_try_compile "$LINENO"; then :
18332 gl_cv_have_include_next=buggy
18333 else
18334 gl_cv_have_include_next=no
18336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18340 CPPFLAGS="$gl_save_CPPFLAGS"
18341 rm -rf conftestd1a conftestd1b conftestd2
18344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
18345 $as_echo "$gl_cv_have_include_next" >&6; }
18346 PRAGMA_SYSTEM_HEADER=
18347 if test $gl_cv_have_include_next = yes; then
18348 INCLUDE_NEXT=include_next
18349 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18350 if test -n "$GCC"; then
18351 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
18353 else
18354 if test $gl_cv_have_include_next = buggy; then
18355 INCLUDE_NEXT=include
18356 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18357 else
18358 INCLUDE_NEXT=include
18359 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
18365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
18366 $as_echo_n "checking whether system header files limit the line length... " >&6; }
18367 if test "${gl_cv_pragma_columns+set}" = set; then :
18368 $as_echo_n "(cached) " >&6
18369 else
18370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18371 /* end confdefs.h. */
18373 #ifdef __TANDEM
18374 choke me
18375 #endif
18377 _ACEOF
18378 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18379 $EGREP "choke me" >/dev/null 2>&1; then :
18380 gl_cv_pragma_columns=yes
18381 else
18382 gl_cv_pragma_columns=no
18384 rm -f conftest*
18388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
18389 $as_echo "$gl_cv_pragma_columns" >&6; }
18390 if test $gl_cv_pragma_columns = yes; then
18391 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
18392 else
18393 PRAGMA_COLUMNS=
18400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
18401 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
18402 if test "${gl_cv_func_c99_strtold+set}" = set; then :
18403 $as_echo_n "(cached) " >&6
18404 else
18405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18406 /* end confdefs.h. */
18407 /* On HP-UX before 11.23, strtold returns a struct instead of
18408 long double. Reject implementations like that, by requiring
18409 compatibility with the C99 prototype. */
18410 #include <stdlib.h>
18411 static long double (*p) (char const *, char **) = strtold;
18412 static long double
18413 test (char const *nptr, char **endptr)
18415 long double r;
18416 r = strtold (nptr, endptr);
18417 return r;
18420 main ()
18422 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
18424 return 0;
18426 _ACEOF
18427 if ac_fn_c_try_link "$LINENO"; then :
18428 gl_cv_func_c99_strtold=yes
18429 else
18430 gl_cv_func_c99_strtold=no
18432 rm -f core conftest.err conftest.$ac_objext \
18433 conftest$ac_exeext conftest.$ac_ext
18435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
18436 $as_echo "$gl_cv_func_c99_strtold" >&6; }
18437 if test $gl_cv_func_c99_strtold = yes; then
18439 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18451 $as_echo_n "checking if environ is properly declared... " >&6; }
18452 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18453 $as_echo_n "(cached) " >&6
18454 else
18456 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18457 /* end confdefs.h. */
18458 #if HAVE_UNISTD_H
18459 #include <unistd.h>
18460 #endif
18461 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18462 #include <stdlib.h>
18464 extern struct { int foo; } environ;
18466 main ()
18468 environ.foo = 1;
18470 return 0;
18472 _ACEOF
18473 if ac_fn_c_try_compile "$LINENO"; then :
18474 gt_cv_var_environ_declaration=no
18475 else
18476 gt_cv_var_environ_declaration=yes
18478 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18482 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18483 if test $gt_cv_var_environ_declaration = yes; then
18485 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18490 if test $gt_cv_var_environ_declaration != yes; then
18491 HAVE_DECL_ENVIRON=0
18496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18497 $as_echo_n "checking for complete errno.h... " >&6; }
18498 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18499 $as_echo_n "(cached) " >&6
18500 else
18502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18503 /* end confdefs.h. */
18505 #include <errno.h>
18506 #if !defined ETXTBSY
18507 booboo
18508 #endif
18509 #if !defined ENOMSG
18510 booboo
18511 #endif
18512 #if !defined EIDRM
18513 booboo
18514 #endif
18515 #if !defined ENOLINK
18516 booboo
18517 #endif
18518 #if !defined EPROTO
18519 booboo
18520 #endif
18521 #if !defined EMULTIHOP
18522 booboo
18523 #endif
18524 #if !defined EBADMSG
18525 booboo
18526 #endif
18527 #if !defined EOVERFLOW
18528 booboo
18529 #endif
18530 #if !defined ENOTSUP
18531 booboo
18532 #endif
18533 #if !defined ENETRESET
18534 booboo
18535 #endif
18536 #if !defined ECONNABORTED
18537 booboo
18538 #endif
18539 #if !defined ESTALE
18540 booboo
18541 #endif
18542 #if !defined EDQUOT
18543 booboo
18544 #endif
18545 #if !defined ECANCELED
18546 booboo
18547 #endif
18548 #if !defined EOWNERDEAD
18549 booboo
18550 #endif
18551 #if !defined ENOTRECOVERABLE
18552 booboo
18553 #endif
18554 #if !defined EILSEQ
18555 booboo
18556 #endif
18558 _ACEOF
18559 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18560 $EGREP "booboo" >/dev/null 2>&1; then :
18561 gl_cv_header_errno_h_complete=no
18562 else
18563 gl_cv_header_errno_h_complete=yes
18565 rm -f conftest*
18569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18570 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18571 if test $gl_cv_header_errno_h_complete = yes; then
18572 ERRNO_H=''
18573 else
18582 if test $gl_cv_have_include_next = yes; then
18583 gl_cv_next_errno_h='<'errno.h'>'
18584 else
18585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18586 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18587 if test "${gl_cv_next_errno_h+set}" = set; then :
18588 $as_echo_n "(cached) " >&6
18589 else
18591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18592 /* end confdefs.h. */
18593 #include <errno.h>
18595 _ACEOF
18596 case "$host_os" in
18597 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18598 *) gl_absname_cpp="$ac_cpp" ;;
18599 esac
18601 case "$host_os" in
18602 mingw*)
18603 gl_dirsep_regex='[/\\]'
18606 gl_dirsep_regex='\/'
18608 esac
18609 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18611 gl_header_literal_regex=`echo 'errno.h' \
18612 | sed -e "$gl_make_literal_regex_sed"`
18613 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18614 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18615 s|^/[^/]|//&|
18619 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18620 sed -n "$gl_absolute_header_sed"`'"'
18624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18625 $as_echo "$gl_cv_next_errno_h" >&6; }
18627 NEXT_ERRNO_H=$gl_cv_next_errno_h
18629 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18630 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18631 gl_next_as_first_directive='<'errno.h'>'
18632 else
18633 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18634 gl_next_as_first_directive=$gl_cv_next_errno_h
18636 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18641 ERRNO_H='errno.h'
18644 if test -n "$ERRNO_H"; then
18645 GL_GENERATE_ERRNO_H_TRUE=
18646 GL_GENERATE_ERRNO_H_FALSE='#'
18647 else
18648 GL_GENERATE_ERRNO_H_TRUE='#'
18649 GL_GENERATE_ERRNO_H_FALSE=
18653 if test -n "$ERRNO_H"; then
18654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18655 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18656 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18657 $as_echo_n "(cached) " >&6
18658 else
18660 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18661 /* end confdefs.h. */
18663 #include <errno.h>
18664 #ifdef EMULTIHOP
18666 #endif
18668 _ACEOF
18669 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18670 $EGREP "yes" >/dev/null 2>&1; then :
18671 gl_cv_header_errno_h_EMULTIHOP=yes
18672 else
18673 gl_cv_header_errno_h_EMULTIHOP=no
18675 rm -f conftest*
18677 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18679 /* end confdefs.h. */
18681 #define _XOPEN_SOURCE_EXTENDED 1
18682 #include <errno.h>
18683 #ifdef EMULTIHOP
18685 #endif
18687 _ACEOF
18688 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18689 $EGREP "yes" >/dev/null 2>&1; then :
18690 gl_cv_header_errno_h_EMULTIHOP=hidden
18692 rm -f conftest*
18694 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18695 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18696 #define _XOPEN_SOURCE_EXTENDED 1
18697 #include <errno.h>
18698 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18699 #include <stdio.h>
18700 #include <stdlib.h>
18701 "; then :
18709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18710 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18711 case $gl_cv_header_errno_h_EMULTIHOP in
18712 yes | no)
18713 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18716 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18718 esac
18724 if test -n "$ERRNO_H"; then
18725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18726 $as_echo_n "checking for ENOLINK value... " >&6; }
18727 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18728 $as_echo_n "(cached) " >&6
18729 else
18731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18732 /* end confdefs.h. */
18734 #include <errno.h>
18735 #ifdef ENOLINK
18737 #endif
18739 _ACEOF
18740 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18741 $EGREP "yes" >/dev/null 2>&1; then :
18742 gl_cv_header_errno_h_ENOLINK=yes
18743 else
18744 gl_cv_header_errno_h_ENOLINK=no
18746 rm -f conftest*
18748 if test $gl_cv_header_errno_h_ENOLINK = no; then
18749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18750 /* end confdefs.h. */
18752 #define _XOPEN_SOURCE_EXTENDED 1
18753 #include <errno.h>
18754 #ifdef ENOLINK
18756 #endif
18758 _ACEOF
18759 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18760 $EGREP "yes" >/dev/null 2>&1; then :
18761 gl_cv_header_errno_h_ENOLINK=hidden
18763 rm -f conftest*
18765 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18766 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18767 #define _XOPEN_SOURCE_EXTENDED 1
18768 #include <errno.h>
18769 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18770 #include <stdio.h>
18771 #include <stdlib.h>
18772 "; then :
18780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18781 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18782 case $gl_cv_header_errno_h_ENOLINK in
18783 yes | no)
18784 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18787 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18789 esac
18795 if test -n "$ERRNO_H"; then
18796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18797 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18798 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18799 $as_echo_n "(cached) " >&6
18800 else
18802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18803 /* end confdefs.h. */
18805 #include <errno.h>
18806 #ifdef EOVERFLOW
18808 #endif
18810 _ACEOF
18811 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18812 $EGREP "yes" >/dev/null 2>&1; then :
18813 gl_cv_header_errno_h_EOVERFLOW=yes
18814 else
18815 gl_cv_header_errno_h_EOVERFLOW=no
18817 rm -f conftest*
18819 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18821 /* end confdefs.h. */
18823 #define _XOPEN_SOURCE_EXTENDED 1
18824 #include <errno.h>
18825 #ifdef EOVERFLOW
18827 #endif
18829 _ACEOF
18830 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18831 $EGREP "yes" >/dev/null 2>&1; then :
18832 gl_cv_header_errno_h_EOVERFLOW=hidden
18834 rm -f conftest*
18836 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18837 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18838 #define _XOPEN_SOURCE_EXTENDED 1
18839 #include <errno.h>
18840 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18841 #include <stdio.h>
18842 #include <stdlib.h>
18843 "; then :
18851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18852 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18853 case $gl_cv_header_errno_h_EOVERFLOW in
18854 yes | no)
18855 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18858 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18860 esac
18874 GNULIB_FCNTL=0;
18875 GNULIB_NONBLOCKING=0;
18876 GNULIB_OPEN=0;
18877 GNULIB_OPENAT=0;
18878 HAVE_FCNTL=1;
18879 HAVE_OPENAT=1;
18880 REPLACE_FCNTL=0;
18881 REPLACE_OPEN=0;
18882 REPLACE_OPENAT=0;
18887 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18888 if test "x$ac_cv_type_mode_t" = x""yes; then :
18890 else
18892 cat >>confdefs.h <<_ACEOF
18893 #define mode_t int
18894 _ACEOF
18898 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18899 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18900 ac_have_decl=1
18901 else
18902 ac_have_decl=0
18905 cat >>confdefs.h <<_ACEOF
18906 #define HAVE_DECL_FDATASYNC $ac_have_decl
18907 _ACEOF
18911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18912 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18913 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18914 $as_echo_n "(cached) " >&6
18915 else
18916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18917 /* end confdefs.h. */
18919 #include <sys/types.h>
18920 #include <sys/stat.h>
18922 main ()
18924 struct stat s; s.st_dm_mode;
18926 return 0;
18928 _ACEOF
18929 if ac_fn_c_try_compile "$LINENO"; then :
18930 ac_cv_struct_st_dm_mode=yes
18931 else
18932 ac_cv_struct_st_dm_mode=no
18934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
18937 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
18939 if test $ac_cv_struct_st_dm_mode = yes; then
18941 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
18946 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
18947 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
18948 ac_have_decl=1
18949 else
18950 ac_have_decl=0
18953 cat >>confdefs.h <<_ACEOF
18954 #define HAVE_DECL_STRMODE $ac_have_decl
18955 _ACEOF
18960 GNULIB_FCHMODAT=0;
18961 GNULIB_FSTAT=0;
18962 GNULIB_FSTATAT=0;
18963 GNULIB_FUTIMENS=0;
18964 GNULIB_LCHMOD=0;
18965 GNULIB_LSTAT=0;
18966 GNULIB_MKDIRAT=0;
18967 GNULIB_MKFIFO=0;
18968 GNULIB_MKFIFOAT=0;
18969 GNULIB_MKNOD=0;
18970 GNULIB_MKNODAT=0;
18971 GNULIB_STAT=0;
18972 GNULIB_UTIMENSAT=0;
18973 HAVE_FCHMODAT=1;
18974 HAVE_FSTATAT=1;
18975 HAVE_FUTIMENS=1;
18976 HAVE_LCHMOD=1;
18977 HAVE_LSTAT=1;
18978 HAVE_MKDIRAT=1;
18979 HAVE_MKFIFO=1;
18980 HAVE_MKFIFOAT=1;
18981 HAVE_MKNOD=1;
18982 HAVE_MKNODAT=1;
18983 HAVE_UTIMENSAT=1;
18984 REPLACE_FSTAT=0;
18985 REPLACE_FSTATAT=0;
18986 REPLACE_FUTIMENS=0;
18987 REPLACE_LSTAT=0;
18988 REPLACE_MKDIR=0;
18989 REPLACE_MKFIFO=0;
18990 REPLACE_MKNOD=0;
18991 REPLACE_STAT=0;
18992 REPLACE_UTIMENSAT=0;
18995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18996 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18997 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18998 $as_echo_n "(cached) " >&6
18999 else
19000 rm -f conftest.sym conftest.file
19001 echo >conftest.file
19002 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
19003 if test "$cross_compiling" = yes; then :
19004 case "$host_os" in
19005 # Guess yes on glibc systems.
19006 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
19007 # If we don't know, assume the worst.
19008 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
19009 esac
19011 else
19012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19013 /* end confdefs.h. */
19014 $ac_includes_default
19016 main ()
19018 struct stat sbuf;
19019 /* Linux will dereference the symlink and fail, as required by
19020 POSIX. That is better in the sense that it means we will not
19021 have to compile and use the lstat wrapper. */
19022 return lstat ("conftest.sym/", &sbuf) == 0;
19025 return 0;
19027 _ACEOF
19028 if ac_fn_c_try_run "$LINENO"; then :
19029 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19030 else
19031 gl_cv_func_lstat_dereferences_slashed_symlink=no
19033 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19034 conftest.$ac_objext conftest.beam conftest.$ac_ext
19037 else
19038 # If the 'ln -s' command failed, then we probably don't even
19039 # have an lstat function.
19040 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19042 rm -f conftest.sym conftest.file
19045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19046 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19047 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19048 *yes)
19050 cat >>confdefs.h <<_ACEOF
19051 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19052 _ACEOF
19055 esac
19062 GNULIB__EXIT=0;
19063 GNULIB_ATOLL=0;
19064 GNULIB_CALLOC_POSIX=0;
19065 GNULIB_CANONICALIZE_FILE_NAME=0;
19066 GNULIB_GETLOADAVG=0;
19067 GNULIB_GETSUBOPT=0;
19068 GNULIB_GRANTPT=0;
19069 GNULIB_MALLOC_POSIX=0;
19070 GNULIB_MBTOWC=0;
19071 GNULIB_MKDTEMP=0;
19072 GNULIB_MKOSTEMP=0;
19073 GNULIB_MKOSTEMPS=0;
19074 GNULIB_MKSTEMP=0;
19075 GNULIB_MKSTEMPS=0;
19076 GNULIB_POSIX_OPENPT=0;
19077 GNULIB_PTSNAME=0;
19078 GNULIB_PTSNAME_R=0;
19079 GNULIB_PUTENV=0;
19080 GNULIB_RANDOM=0;
19081 GNULIB_RANDOM_R=0;
19082 GNULIB_REALLOC_POSIX=0;
19083 GNULIB_REALPATH=0;
19084 GNULIB_RPMATCH=0;
19085 GNULIB_SECURE_GETENV=0;
19086 GNULIB_SETENV=0;
19087 GNULIB_STRTOD=0;
19088 GNULIB_STRTOLL=0;
19089 GNULIB_STRTOULL=0;
19090 GNULIB_SYSTEM_POSIX=0;
19091 GNULIB_UNLOCKPT=0;
19092 GNULIB_UNSETENV=0;
19093 GNULIB_WCTOMB=0;
19094 HAVE__EXIT=1;
19095 HAVE_ATOLL=1;
19096 HAVE_CANONICALIZE_FILE_NAME=1;
19097 HAVE_DECL_GETLOADAVG=1;
19098 HAVE_GETSUBOPT=1;
19099 HAVE_GRANTPT=1;
19100 HAVE_MKDTEMP=1;
19101 HAVE_MKOSTEMP=1;
19102 HAVE_MKOSTEMPS=1;
19103 HAVE_MKSTEMP=1;
19104 HAVE_MKSTEMPS=1;
19105 HAVE_POSIX_OPENPT=1;
19106 HAVE_PTSNAME=1;
19107 HAVE_PTSNAME_R=1;
19108 HAVE_RANDOM=1;
19109 HAVE_RANDOM_H=1;
19110 HAVE_RANDOM_R=1;
19111 HAVE_REALPATH=1;
19112 HAVE_RPMATCH=1;
19113 HAVE_SECURE_GETENV=1;
19114 HAVE_SETENV=1;
19115 HAVE_DECL_SETENV=1;
19116 HAVE_STRTOD=1;
19117 HAVE_STRTOLL=1;
19118 HAVE_STRTOULL=1;
19119 HAVE_STRUCT_RANDOM_DATA=1;
19120 HAVE_SYS_LOADAVG_H=0;
19121 HAVE_UNLOCKPT=1;
19122 HAVE_DECL_UNSETENV=1;
19123 REPLACE_CALLOC=0;
19124 REPLACE_CANONICALIZE_FILE_NAME=0;
19125 REPLACE_MALLOC=0;
19126 REPLACE_MBTOWC=0;
19127 REPLACE_MKSTEMP=0;
19128 REPLACE_PTSNAME=0;
19129 REPLACE_PTSNAME_R=0;
19130 REPLACE_PUTENV=0;
19131 REPLACE_RANDOM_R=0;
19132 REPLACE_REALLOC=0;
19133 REPLACE_REALPATH=0;
19134 REPLACE_SETENV=0;
19135 REPLACE_STRTOD=0;
19136 REPLACE_UNSETENV=0;
19137 REPLACE_WCTOMB=0;
19154 if test $gl_cv_have_include_next = yes; then
19155 gl_cv_next_getopt_h='<'getopt.h'>'
19156 else
19157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
19158 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
19159 if test "${gl_cv_next_getopt_h+set}" = set; then :
19160 $as_echo_n "(cached) " >&6
19161 else
19163 if test $ac_cv_header_getopt_h = yes; then
19166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19167 /* end confdefs.h. */
19168 #include <getopt.h>
19170 _ACEOF
19171 case "$host_os" in
19172 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19173 *) gl_absname_cpp="$ac_cpp" ;;
19174 esac
19176 case "$host_os" in
19177 mingw*)
19178 gl_dirsep_regex='[/\\]'
19181 gl_dirsep_regex='\/'
19183 esac
19184 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19186 gl_header_literal_regex=`echo 'getopt.h' \
19187 | sed -e "$gl_make_literal_regex_sed"`
19188 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19189 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19190 s|^/[^/]|//&|
19194 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19195 sed -n "$gl_absolute_header_sed"`'"'
19196 else
19197 gl_cv_next_getopt_h='<'getopt.h'>'
19202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
19203 $as_echo "$gl_cv_next_getopt_h" >&6; }
19205 NEXT_GETOPT_H=$gl_cv_next_getopt_h
19207 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19208 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19209 gl_next_as_first_directive='<'getopt.h'>'
19210 else
19211 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19212 gl_next_as_first_directive=$gl_cv_next_getopt_h
19214 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
19219 if test $ac_cv_header_getopt_h = yes; then
19220 HAVE_GETOPT_H=1
19221 else
19222 HAVE_GETOPT_H=0
19226 gl_replace_getopt=
19228 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19229 for ac_header in getopt.h
19230 do :
19231 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
19232 if test "x$ac_cv_header_getopt_h" = x""yes; then :
19233 cat >>confdefs.h <<_ACEOF
19234 #define HAVE_GETOPT_H 1
19235 _ACEOF
19237 else
19238 gl_replace_getopt=yes
19241 done
19245 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19246 for ac_func in getopt_long_only
19247 do :
19248 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
19249 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
19250 cat >>confdefs.h <<_ACEOF
19251 #define HAVE_GETOPT_LONG_ONLY 1
19252 _ACEOF
19254 else
19255 gl_replace_getopt=yes
19257 done
19261 if test -z "$gl_replace_getopt"; then
19262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
19263 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
19264 if test "${gl_cv_func_getopt_posix+set}" = set; then :
19265 $as_echo_n "(cached) " >&6
19266 else
19268 if test $cross_compiling = no; then
19269 if test "$cross_compiling" = yes; then :
19270 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19271 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19272 as_fn_error "cannot run test program while cross compiling
19273 See \`config.log' for more details." "$LINENO" 5; }
19274 else
19275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19276 /* end confdefs.h. */
19278 #include <unistd.h>
19279 #include <stdlib.h>
19280 #include <string.h>
19283 main ()
19285 static char program[] = "program";
19286 static char a[] = "-a";
19287 static char foo[] = "foo";
19288 static char bar[] = "bar";
19289 char *argv[] = { program, a, foo, bar, NULL };
19290 int c;
19292 c = getopt (4, argv, "ab");
19293 if (!(c == 'a'))
19294 return 1;
19295 c = getopt (4, argv, "ab");
19296 if (!(c == -1))
19297 return 2;
19298 if (!(optind == 2))
19299 return 3;
19300 return 0;
19303 _ACEOF
19304 if ac_fn_c_try_run "$LINENO"; then :
19305 gl_cv_func_getopt_posix=maybe
19306 else
19307 gl_cv_func_getopt_posix=no
19309 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19310 conftest.$ac_objext conftest.beam conftest.$ac_ext
19313 if test $gl_cv_func_getopt_posix = maybe; then
19314 if test "$cross_compiling" = yes; then :
19315 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19316 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19317 as_fn_error "cannot run test program while cross compiling
19318 See \`config.log' for more details." "$LINENO" 5; }
19319 else
19320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19321 /* end confdefs.h. */
19323 #include <unistd.h>
19324 #include <stdlib.h>
19325 #include <string.h>
19328 main ()
19330 static char program[] = "program";
19331 static char donald[] = "donald";
19332 static char p[] = "-p";
19333 static char billy[] = "billy";
19334 static char duck[] = "duck";
19335 static char a[] = "-a";
19336 static char bar[] = "bar";
19337 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
19338 int c;
19340 c = getopt (7, argv, "+abp:q:");
19341 if (!(c == -1))
19342 return 4;
19343 if (!(strcmp (argv[0], "program") == 0))
19344 return 5;
19345 if (!(strcmp (argv[1], "donald") == 0))
19346 return 6;
19347 if (!(strcmp (argv[2], "-p") == 0))
19348 return 7;
19349 if (!(strcmp (argv[3], "billy") == 0))
19350 return 8;
19351 if (!(strcmp (argv[4], "duck") == 0))
19352 return 9;
19353 if (!(strcmp (argv[5], "-a") == 0))
19354 return 10;
19355 if (!(strcmp (argv[6], "bar") == 0))
19356 return 11;
19357 if (!(optind == 1))
19358 return 12;
19359 return 0;
19362 _ACEOF
19363 if ac_fn_c_try_run "$LINENO"; then :
19364 gl_cv_func_getopt_posix=maybe
19365 else
19366 gl_cv_func_getopt_posix=no
19368 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19369 conftest.$ac_objext conftest.beam conftest.$ac_ext
19373 if test $gl_cv_func_getopt_posix = maybe; then
19374 if test "$cross_compiling" = yes; then :
19375 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19376 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19377 as_fn_error "cannot run test program while cross compiling
19378 See \`config.log' for more details." "$LINENO" 5; }
19379 else
19380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19381 /* end confdefs.h. */
19383 #include <unistd.h>
19384 #include <stdlib.h>
19385 #include <string.h>
19388 main ()
19390 static char program[] = "program";
19391 static char ab[] = "-ab";
19392 char *argv[3] = { program, ab, NULL };
19393 if (getopt (2, argv, "ab:") != 'a')
19394 return 13;
19395 if (getopt (2, argv, "ab:") != '?')
19396 return 14;
19397 if (optopt != 'b')
19398 return 15;
19399 if (optind != 2)
19400 return 16;
19401 return 0;
19404 _ACEOF
19405 if ac_fn_c_try_run "$LINENO"; then :
19406 gl_cv_func_getopt_posix=yes
19407 else
19408 gl_cv_func_getopt_posix=no
19410 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19411 conftest.$ac_objext conftest.beam conftest.$ac_ext
19415 else
19416 case "$host_os" in
19417 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
19418 *) gl_cv_func_getopt_posix="guessing yes";;
19419 esac
19423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
19424 $as_echo "$gl_cv_func_getopt_posix" >&6; }
19425 case "$gl_cv_func_getopt_posix" in
19426 *no) gl_replace_getopt=yes ;;
19427 esac
19430 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
19432 $as_echo_n "checking for working GNU getopt function... " >&6; }
19433 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
19434 $as_echo_n "(cached) " >&6
19435 else
19436 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
19437 # optstring is necessary for programs like m4 that have POSIX-mandated
19438 # semantics for supporting options interspersed with files.
19439 # Also, since getopt_long is a GNU extension, we require optind=0.
19440 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
19441 # so take care to revert to the correct (non-)export state.
19442 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19443 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19444 xx) gl_had_POSIXLY_CORRECT=exported ;;
19445 x) gl_had_POSIXLY_CORRECT=yes ;;
19446 *) gl_had_POSIXLY_CORRECT= ;;
19447 esac
19448 POSIXLY_CORRECT=1
19449 export POSIXLY_CORRECT
19450 if test "$cross_compiling" = yes; then :
19451 gl_cv_func_getopt_gnu="guessing no"
19453 else
19454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19455 /* end confdefs.h. */
19456 #include <getopt.h>
19457 #include <stddef.h>
19458 #include <string.h>
19460 #include <stdlib.h>
19461 #if defined __MACH__ && defined __APPLE__
19462 /* Avoid a crash on Mac OS X. */
19463 #include <mach/mach.h>
19464 #include <mach/mach_error.h>
19465 #include <mach/thread_status.h>
19466 #include <mach/exception.h>
19467 #include <mach/task.h>
19468 #include <pthread.h>
19469 /* The exception port on which our thread listens. */
19470 static mach_port_t our_exception_port;
19471 /* The main function of the thread listening for exceptions of type
19472 EXC_BAD_ACCESS. */
19473 static void *
19474 mach_exception_thread (void *arg)
19476 /* Buffer for a message to be received. */
19477 struct {
19478 mach_msg_header_t head;
19479 mach_msg_body_t msgh_body;
19480 char data[1024];
19481 } msg;
19482 mach_msg_return_t retval;
19483 /* Wait for a message on the exception port. */
19484 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19485 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19486 if (retval != MACH_MSG_SUCCESS)
19487 abort ();
19488 exit (1);
19490 static void
19491 nocrash_init (void)
19493 mach_port_t self = mach_task_self ();
19494 /* Allocate a port on which the thread shall listen for exceptions. */
19495 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19496 == KERN_SUCCESS) {
19497 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19498 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19499 MACH_MSG_TYPE_MAKE_SEND)
19500 == KERN_SUCCESS) {
19501 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19502 for us. */
19503 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19504 /* Create the thread listening on the exception port. */
19505 pthread_attr_t attr;
19506 pthread_t thread;
19507 if (pthread_attr_init (&attr) == 0
19508 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19509 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19510 pthread_attr_destroy (&attr);
19511 /* Replace the exception port info for these exceptions with our own.
19512 Note that we replace the exception port for the entire task, not only
19513 for a particular thread. This has the effect that when our exception
19514 port gets the message, the thread specific exception port has already
19515 been asked, and we don't need to bother about it.
19516 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19517 task_set_exception_ports (self, mask, our_exception_port,
19518 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19523 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19524 /* Avoid a crash on native Windows. */
19525 #define WIN32_LEAN_AND_MEAN
19526 #include <windows.h>
19527 #include <winerror.h>
19528 static LONG WINAPI
19529 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19531 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19533 case EXCEPTION_ACCESS_VIOLATION:
19534 case EXCEPTION_IN_PAGE_ERROR:
19535 case EXCEPTION_STACK_OVERFLOW:
19536 case EXCEPTION_GUARD_PAGE:
19537 case EXCEPTION_PRIV_INSTRUCTION:
19538 case EXCEPTION_ILLEGAL_INSTRUCTION:
19539 case EXCEPTION_DATATYPE_MISALIGNMENT:
19540 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19541 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19542 exit (1);
19544 return EXCEPTION_CONTINUE_SEARCH;
19546 static void
19547 nocrash_init (void)
19549 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19551 #else
19552 /* Avoid a crash on POSIX systems. */
19553 #include <signal.h>
19554 /* A POSIX signal handler. */
19555 static void
19556 exception_handler (int sig)
19558 exit (1);
19560 static void
19561 nocrash_init (void)
19563 #ifdef SIGSEGV
19564 signal (SIGSEGV, exception_handler);
19565 #endif
19566 #ifdef SIGBUS
19567 signal (SIGBUS, exception_handler);
19568 #endif
19570 #endif
19574 main ()
19577 int result = 0;
19579 nocrash_init();
19581 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19582 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19583 OSF/1 5.1, Solaris 10. */
19585 static char conftest[] = "conftest";
19586 static char plus[] = "-+";
19587 char *argv[3] = { conftest, plus, NULL };
19588 opterr = 0;
19589 if (getopt (2, argv, "+a") != '?')
19590 result |= 1;
19592 /* This code succeeds on glibc 2.8, mingw,
19593 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19594 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19596 static char program[] = "program";
19597 static char p[] = "-p";
19598 static char foo[] = "foo";
19599 static char bar[] = "bar";
19600 char *argv[] = { program, p, foo, bar, NULL };
19602 optind = 1;
19603 if (getopt (4, argv, "p::") != 'p')
19604 result |= 2;
19605 else if (optarg != NULL)
19606 result |= 4;
19607 else if (getopt (4, argv, "p::") != -1)
19608 result |= 6;
19609 else if (optind != 2)
19610 result |= 8;
19612 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19614 static char program[] = "program";
19615 static char foo[] = "foo";
19616 static char p[] = "-p";
19617 char *argv[] = { program, foo, p, NULL };
19618 optind = 0;
19619 if (getopt (3, argv, "-p") != 1)
19620 result |= 16;
19621 else if (getopt (3, argv, "-p") != 'p')
19622 result |= 16;
19624 /* This code fails on glibc 2.11. */
19626 static char program[] = "program";
19627 static char b[] = "-b";
19628 static char a[] = "-a";
19629 char *argv[] = { program, b, a, NULL };
19630 optind = opterr = 0;
19631 if (getopt (3, argv, "+:a:b") != 'b')
19632 result |= 32;
19633 else if (getopt (3, argv, "+:a:b") != ':')
19634 result |= 32;
19636 /* This code dumps core on glibc 2.14. */
19638 static char program[] = "program";
19639 static char w[] = "-W";
19640 static char dummy[] = "dummy";
19641 char *argv[] = { program, w, dummy, NULL };
19642 optind = opterr = 1;
19643 if (getopt (3, argv, "W;") != 'W')
19644 result |= 64;
19646 return result;
19649 return 0;
19651 _ACEOF
19652 if ac_fn_c_try_run "$LINENO"; then :
19653 gl_cv_func_getopt_gnu=yes
19654 else
19655 gl_cv_func_getopt_gnu=no
19657 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19658 conftest.$ac_objext conftest.beam conftest.$ac_ext
19661 case $gl_had_POSIXLY_CORRECT in
19662 exported) ;;
19663 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19664 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19665 esac
19668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19669 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19670 if test "$gl_cv_func_getopt_gnu" != yes; then
19671 gl_replace_getopt=yes
19672 else
19673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19674 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19675 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19676 $as_echo_n "(cached) " >&6
19677 else
19678 if test "$cross_compiling" = yes; then :
19679 case "$host_os" in
19680 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19681 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19682 esac
19684 else
19685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19686 /* end confdefs.h. */
19687 #include <getopt.h>
19688 #include <stddef.h>
19689 #include <string.h>
19692 main ()
19694 static const struct option long_options[] =
19696 { "xtremely-",no_argument, NULL, 1003 },
19697 { "xtra", no_argument, NULL, 1001 },
19698 { "xtreme", no_argument, NULL, 1002 },
19699 { "xtremely", no_argument, NULL, 1003 },
19700 { NULL, 0, NULL, 0 }
19702 /* This code fails on OpenBSD 5.0. */
19704 static char program[] = "program";
19705 static char xtremel[] = "--xtremel";
19706 char *argv[] = { program, xtremel, NULL };
19707 int option_index;
19708 optind = 1; opterr = 0;
19709 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19710 return 1;
19712 return 0;
19715 return 0;
19717 _ACEOF
19718 if ac_fn_c_try_run "$LINENO"; then :
19719 gl_cv_func_getopt_long_gnu=yes
19720 else
19721 gl_cv_func_getopt_long_gnu=no
19723 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19724 conftest.$ac_objext conftest.beam conftest.$ac_ext
19729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19730 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19731 case "$gl_cv_func_getopt_long_gnu" in
19732 *yes) ;;
19733 *) gl_replace_getopt=yes ;;
19734 esac
19743 REPLACE_GETOPT=0
19744 if test -n "$gl_replace_getopt"; then
19745 REPLACE_GETOPT=1
19748 if test $REPLACE_GETOPT = 1; then
19750 GETOPT_H=getopt.h
19752 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19758 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19759 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19760 ac_have_decl=1
19761 else
19762 ac_have_decl=0
19765 cat >>confdefs.h <<_ACEOF
19766 #define HAVE_DECL_GETENV $ac_have_decl
19767 _ACEOF
19774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19775 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19776 if test "${ac_cv_c_restrict+set}" = set; then :
19777 $as_echo_n "(cached) " >&6
19778 else
19779 ac_cv_c_restrict=no
19780 # The order here caters to the fact that C++ does not require restrict.
19781 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19783 /* end confdefs.h. */
19784 typedef int * int_ptr;
19785 int foo (int_ptr $ac_kw ip) {
19786 return ip[0];
19789 main ()
19791 int s[1];
19792 int * $ac_kw t = s;
19793 t[0] = 0;
19794 return foo(t)
19796 return 0;
19798 _ACEOF
19799 if ac_fn_c_try_compile "$LINENO"; then :
19800 ac_cv_c_restrict=$ac_kw
19802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19803 test "$ac_cv_c_restrict" != no && break
19804 done
19807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19808 $as_echo "$ac_cv_c_restrict" >&6; }
19810 case $ac_cv_c_restrict in
19811 restrict) ;;
19812 no) $as_echo "#define restrict /**/" >>confdefs.h
19814 *) cat >>confdefs.h <<_ACEOF
19815 #define restrict $ac_cv_c_restrict
19816 _ACEOF
19818 esac
19821 GNULIB_GETTIMEOFDAY=0;
19822 HAVE_GETTIMEOFDAY=1;
19823 HAVE_STRUCT_TIMEVAL=1;
19824 HAVE_SYS_TIME_H=1;
19825 REPLACE_GETTIMEOFDAY=0;
19826 REPLACE_STRUCT_TIMEVAL=0;
19843 if test $gl_cv_have_include_next = yes; then
19844 gl_cv_next_sys_time_h='<'sys/time.h'>'
19845 else
19846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19847 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19848 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19849 $as_echo_n "(cached) " >&6
19850 else
19852 if test $ac_cv_header_sys_time_h = yes; then
19855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19856 /* end confdefs.h. */
19857 #include <sys/time.h>
19859 _ACEOF
19860 case "$host_os" in
19861 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19862 *) gl_absname_cpp="$ac_cpp" ;;
19863 esac
19865 case "$host_os" in
19866 mingw*)
19867 gl_dirsep_regex='[/\\]'
19870 gl_dirsep_regex='\/'
19872 esac
19873 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19875 gl_header_literal_regex=`echo 'sys/time.h' \
19876 | sed -e "$gl_make_literal_regex_sed"`
19877 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19878 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19879 s|^/[^/]|//&|
19883 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19884 sed -n "$gl_absolute_header_sed"`'"'
19885 else
19886 gl_cv_next_sys_time_h='<'sys/time.h'>'
19891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19892 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19894 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19896 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19897 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19898 gl_next_as_first_directive='<'sys/time.h'>'
19899 else
19900 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19901 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19903 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19909 if test $ac_cv_header_sys_time_h != yes; then
19910 HAVE_SYS_TIME_H=0
19917 if test $ac_cv_header_sys_socket_h != yes; then
19918 for ac_header in winsock2.h
19919 do :
19920 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19921 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19922 cat >>confdefs.h <<_ACEOF
19923 #define HAVE_WINSOCK2_H 1
19924 _ACEOF
19928 done
19931 if test "$ac_cv_header_winsock2_h" = yes; then
19932 HAVE_WINSOCK2_H=1
19933 UNISTD_H_HAVE_WINSOCK2_H=1
19934 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19935 else
19936 HAVE_WINSOCK2_H=0
19940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
19941 $as_echo_n "checking for struct timeval... " >&6; }
19942 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
19943 $as_echo_n "(cached) " >&6
19944 else
19945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19946 /* end confdefs.h. */
19947 #if HAVE_SYS_TIME_H
19948 #include <sys/time.h>
19949 #endif
19950 #include <time.h>
19951 #if HAVE_WINSOCK2_H
19952 # include <winsock2.h>
19953 #endif
19956 main ()
19958 static struct timeval x; x.tv_sec = x.tv_usec;
19960 return 0;
19962 _ACEOF
19963 if ac_fn_c_try_compile "$LINENO"; then :
19964 gl_cv_sys_struct_timeval=yes
19965 else
19966 gl_cv_sys_struct_timeval=no
19968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
19972 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
19973 if test $gl_cv_sys_struct_timeval != yes; then
19974 HAVE_STRUCT_TIMEVAL=0
19975 else
19976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
19977 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
19978 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
19979 $as_echo_n "(cached) " >&6
19980 else
19981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19982 /* end confdefs.h. */
19983 #if HAVE_SYS_TIME_H
19984 #include <sys/time.h>
19985 #endif
19986 #include <time.h>
19987 #if HAVE_WINSOCK2_H
19988 # include <winsock2.h>
19989 #endif
19992 main ()
19994 static struct timeval x;
19995 typedef int verify_tv_sec_type[
19996 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
20000 return 0;
20002 _ACEOF
20003 if ac_fn_c_try_compile "$LINENO"; then :
20004 gl_cv_sys_struct_timeval_tv_sec=yes
20005 else
20006 gl_cv_sys_struct_timeval_tv_sec=no
20008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
20012 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
20013 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
20014 REPLACE_STRUCT_TIMEVAL=1
20024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
20025 $as_echo_n "checking for unsigned long long int... " >&6; }
20026 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
20027 $as_echo_n "(cached) " >&6
20028 else
20029 ac_cv_type_unsigned_long_long_int=yes
20030 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
20031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20032 /* end confdefs.h. */
20034 /* For now, do not test the preprocessor; as of 2007 there are too many
20035 implementations with broken preprocessors. Perhaps this can
20036 be revisited in 2012. In the meantime, code should not expect
20037 #if to work with literals wider than 32 bits. */
20038 /* Test literals. */
20039 long long int ll = 9223372036854775807ll;
20040 long long int nll = -9223372036854775807LL;
20041 unsigned long long int ull = 18446744073709551615ULL;
20042 /* Test constant expressions. */
20043 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
20044 ? 1 : -1)];
20045 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
20046 ? 1 : -1)];
20047 int i = 63;
20049 main ()
20051 /* Test availability of runtime routines for shift and division. */
20052 long long int llmax = 9223372036854775807ll;
20053 unsigned long long int ullmax = 18446744073709551615ull;
20054 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
20055 | (llmax / ll) | (llmax % ll)
20056 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
20057 | (ullmax / ull) | (ullmax % ull));
20059 return 0;
20062 _ACEOF
20063 if ac_fn_c_try_link "$LINENO"; then :
20065 else
20066 ac_cv_type_unsigned_long_long_int=no
20068 rm -f core conftest.err conftest.$ac_objext \
20069 conftest$ac_exeext conftest.$ac_ext
20072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
20073 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
20074 if test $ac_cv_type_unsigned_long_long_int = yes; then
20076 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
20082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
20083 $as_echo_n "checking for long long int... " >&6; }
20084 if test "${ac_cv_type_long_long_int+set}" = set; then :
20085 $as_echo_n "(cached) " >&6
20086 else
20087 ac_cv_type_long_long_int=yes
20088 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
20089 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
20090 if test $ac_cv_type_long_long_int = yes; then
20091 if test "$cross_compiling" = yes; then :
20093 else
20094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20095 /* end confdefs.h. */
20096 #include <limits.h>
20097 #ifndef LLONG_MAX
20098 # define HALF \
20099 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
20100 # define LLONG_MAX (HALF - 1 + HALF)
20101 #endif
20103 main ()
20105 long long int n = 1;
20106 int i;
20107 for (i = 0; ; i++)
20109 long long int m = n << i;
20110 if (m >> i != n)
20111 return 1;
20112 if (LLONG_MAX / 2 < m)
20113 break;
20115 return 0;
20117 return 0;
20119 _ACEOF
20120 if ac_fn_c_try_run "$LINENO"; then :
20122 else
20123 ac_cv_type_long_long_int=no
20125 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20126 conftest.$ac_objext conftest.beam conftest.$ac_ext
20132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
20133 $as_echo "$ac_cv_type_long_long_int" >&6; }
20134 if test $ac_cv_type_long_long_int = yes; then
20136 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
20145 gl_cv_c_multiarch=no
20146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20147 /* end confdefs.h. */
20148 #ifndef __APPLE_CC__
20149 not a universal capable compiler
20150 #endif
20151 typedef int dummy;
20153 _ACEOF
20154 if ac_fn_c_try_compile "$LINENO"; then :
20156 arch=
20157 prev=
20158 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
20159 if test -n "$prev"; then
20160 case $word in
20161 i?86 | x86_64 | ppc | ppc64)
20162 if test -z "$arch" || test "$arch" = "$word"; then
20163 arch="$word"
20164 else
20165 gl_cv_c_multiarch=yes
20168 esac
20169 prev=
20170 else
20171 if test "x$word" = "x-arch"; then
20172 prev=arch
20175 done
20178 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20179 if test $gl_cv_c_multiarch = yes; then
20180 APPLE_UNIVERSAL_BUILD=1
20181 else
20182 APPLE_UNIVERSAL_BUILD=0
20189 if test $ac_cv_type_long_long_int = yes; then
20190 HAVE_LONG_LONG_INT=1
20191 else
20192 HAVE_LONG_LONG_INT=0
20196 if test $ac_cv_type_unsigned_long_long_int = yes; then
20197 HAVE_UNSIGNED_LONG_LONG_INT=1
20198 else
20199 HAVE_UNSIGNED_LONG_LONG_INT=0
20204 if test $ac_cv_header_wchar_h = yes; then
20205 HAVE_WCHAR_H=1
20206 else
20207 HAVE_WCHAR_H=0
20211 if test $ac_cv_header_inttypes_h = yes; then
20212 HAVE_INTTYPES_H=1
20213 else
20214 HAVE_INTTYPES_H=0
20218 if test $ac_cv_header_sys_types_h = yes; then
20219 HAVE_SYS_TYPES_H=1
20220 else
20221 HAVE_SYS_TYPES_H=0
20234 if test $gl_cv_have_include_next = yes; then
20235 gl_cv_next_stdint_h='<'stdint.h'>'
20236 else
20237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
20238 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
20239 if test "${gl_cv_next_stdint_h+set}" = set; then :
20240 $as_echo_n "(cached) " >&6
20241 else
20243 if test $ac_cv_header_stdint_h = yes; then
20246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20247 /* end confdefs.h. */
20248 #include <stdint.h>
20250 _ACEOF
20251 case "$host_os" in
20252 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20253 *) gl_absname_cpp="$ac_cpp" ;;
20254 esac
20256 case "$host_os" in
20257 mingw*)
20258 gl_dirsep_regex='[/\\]'
20261 gl_dirsep_regex='\/'
20263 esac
20264 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20266 gl_header_literal_regex=`echo 'stdint.h' \
20267 | sed -e "$gl_make_literal_regex_sed"`
20268 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20269 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20270 s|^/[^/]|//&|
20274 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20275 sed -n "$gl_absolute_header_sed"`'"'
20276 else
20277 gl_cv_next_stdint_h='<'stdint.h'>'
20282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
20283 $as_echo "$gl_cv_next_stdint_h" >&6; }
20285 NEXT_STDINT_H=$gl_cv_next_stdint_h
20287 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20288 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20289 gl_next_as_first_directive='<'stdint.h'>'
20290 else
20291 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20292 gl_next_as_first_directive=$gl_cv_next_stdint_h
20294 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
20299 if test $ac_cv_header_stdint_h = yes; then
20300 HAVE_STDINT_H=1
20301 else
20302 HAVE_STDINT_H=0
20306 if test $ac_cv_header_stdint_h = yes; then
20307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
20308 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
20309 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
20310 $as_echo_n "(cached) " >&6
20311 else
20312 gl_cv_header_working_stdint_h=no
20313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20314 /* end confdefs.h. */
20317 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20318 #include <stdint.h>
20319 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
20320 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
20321 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
20322 #endif
20325 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20326 included before <wchar.h>. */
20327 #include <stddef.h>
20328 #include <signal.h>
20329 #if HAVE_WCHAR_H
20330 # include <stdio.h>
20331 # include <time.h>
20332 # include <wchar.h>
20333 #endif
20336 #ifdef INT8_MAX
20337 int8_t a1 = INT8_MAX;
20338 int8_t a1min = INT8_MIN;
20339 #endif
20340 #ifdef INT16_MAX
20341 int16_t a2 = INT16_MAX;
20342 int16_t a2min = INT16_MIN;
20343 #endif
20344 #ifdef INT32_MAX
20345 int32_t a3 = INT32_MAX;
20346 int32_t a3min = INT32_MIN;
20347 #endif
20348 #ifdef INT64_MAX
20349 int64_t a4 = INT64_MAX;
20350 int64_t a4min = INT64_MIN;
20351 #endif
20352 #ifdef UINT8_MAX
20353 uint8_t b1 = UINT8_MAX;
20354 #else
20355 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
20356 #endif
20357 #ifdef UINT16_MAX
20358 uint16_t b2 = UINT16_MAX;
20359 #endif
20360 #ifdef UINT32_MAX
20361 uint32_t b3 = UINT32_MAX;
20362 #endif
20363 #ifdef UINT64_MAX
20364 uint64_t b4 = UINT64_MAX;
20365 #endif
20366 int_least8_t c1 = INT8_C (0x7f);
20367 int_least8_t c1max = INT_LEAST8_MAX;
20368 int_least8_t c1min = INT_LEAST8_MIN;
20369 int_least16_t c2 = INT16_C (0x7fff);
20370 int_least16_t c2max = INT_LEAST16_MAX;
20371 int_least16_t c2min = INT_LEAST16_MIN;
20372 int_least32_t c3 = INT32_C (0x7fffffff);
20373 int_least32_t c3max = INT_LEAST32_MAX;
20374 int_least32_t c3min = INT_LEAST32_MIN;
20375 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20376 int_least64_t c4max = INT_LEAST64_MAX;
20377 int_least64_t c4min = INT_LEAST64_MIN;
20378 uint_least8_t d1 = UINT8_C (0xff);
20379 uint_least8_t d1max = UINT_LEAST8_MAX;
20380 uint_least16_t d2 = UINT16_C (0xffff);
20381 uint_least16_t d2max = UINT_LEAST16_MAX;
20382 uint_least32_t d3 = UINT32_C (0xffffffff);
20383 uint_least32_t d3max = UINT_LEAST32_MAX;
20384 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20385 uint_least64_t d4max = UINT_LEAST64_MAX;
20386 int_fast8_t e1 = INT_FAST8_MAX;
20387 int_fast8_t e1min = INT_FAST8_MIN;
20388 int_fast16_t e2 = INT_FAST16_MAX;
20389 int_fast16_t e2min = INT_FAST16_MIN;
20390 int_fast32_t e3 = INT_FAST32_MAX;
20391 int_fast32_t e3min = INT_FAST32_MIN;
20392 int_fast64_t e4 = INT_FAST64_MAX;
20393 int_fast64_t e4min = INT_FAST64_MIN;
20394 uint_fast8_t f1 = UINT_FAST8_MAX;
20395 uint_fast16_t f2 = UINT_FAST16_MAX;
20396 uint_fast32_t f3 = UINT_FAST32_MAX;
20397 uint_fast64_t f4 = UINT_FAST64_MAX;
20398 #ifdef INTPTR_MAX
20399 intptr_t g = INTPTR_MAX;
20400 intptr_t gmin = INTPTR_MIN;
20401 #endif
20402 #ifdef UINTPTR_MAX
20403 uintptr_t h = UINTPTR_MAX;
20404 #endif
20405 intmax_t i = INTMAX_MAX;
20406 uintmax_t j = UINTMAX_MAX;
20408 #include <limits.h> /* for CHAR_BIT */
20409 #define TYPE_MINIMUM(t) \
20410 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
20411 #define TYPE_MAXIMUM(t) \
20412 ((t) ((t) 0 < (t) -1 \
20413 ? (t) -1 \
20414 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
20415 struct s {
20416 int check_PTRDIFF:
20417 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20418 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20419 ? 1 : -1;
20420 /* Detect bug in FreeBSD 6.0 / ia64. */
20421 int check_SIG_ATOMIC:
20422 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20423 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20424 ? 1 : -1;
20425 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20426 int check_WCHAR:
20427 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20428 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20429 ? 1 : -1;
20430 /* Detect bug in mingw. */
20431 int check_WINT:
20432 WINT_MIN == TYPE_MINIMUM (wint_t)
20433 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20434 ? 1 : -1;
20436 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20437 int check_UINT8_C:
20438 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20439 int check_UINT16_C:
20440 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20442 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20443 #ifdef UINT8_MAX
20444 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20445 #endif
20446 #ifdef UINT16_MAX
20447 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20448 #endif
20449 #ifdef UINT32_MAX
20450 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20451 #endif
20452 #ifdef UINT64_MAX
20453 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20454 #endif
20455 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20456 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20457 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20458 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20459 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20460 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20461 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20462 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20463 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20464 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20465 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20469 main ()
20473 return 0;
20475 _ACEOF
20476 if ac_fn_c_try_compile "$LINENO"; then :
20477 if test "$cross_compiling" = yes; then :
20478 gl_cv_header_working_stdint_h=yes
20480 else
20481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20482 /* end confdefs.h. */
20485 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20486 #include <stdint.h>
20489 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20490 included before <wchar.h>. */
20491 #include <stddef.h>
20492 #include <signal.h>
20493 #if HAVE_WCHAR_H
20494 # include <stdio.h>
20495 # include <time.h>
20496 # include <wchar.h>
20497 #endif
20500 #include <stdio.h>
20501 #include <string.h>
20502 #define MVAL(macro) MVAL1(macro)
20503 #define MVAL1(expression) #expression
20504 static const char *macro_values[] =
20506 #ifdef INT8_MAX
20507 MVAL (INT8_MAX),
20508 #endif
20509 #ifdef INT16_MAX
20510 MVAL (INT16_MAX),
20511 #endif
20512 #ifdef INT32_MAX
20513 MVAL (INT32_MAX),
20514 #endif
20515 #ifdef INT64_MAX
20516 MVAL (INT64_MAX),
20517 #endif
20518 #ifdef UINT8_MAX
20519 MVAL (UINT8_MAX),
20520 #endif
20521 #ifdef UINT16_MAX
20522 MVAL (UINT16_MAX),
20523 #endif
20524 #ifdef UINT32_MAX
20525 MVAL (UINT32_MAX),
20526 #endif
20527 #ifdef UINT64_MAX
20528 MVAL (UINT64_MAX),
20529 #endif
20530 NULL
20534 main ()
20537 const char **mv;
20538 for (mv = macro_values; *mv != NULL; mv++)
20540 const char *value = *mv;
20541 /* Test whether it looks like a cast expression. */
20542 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20543 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20544 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20545 || strncmp (value, "((int)"/*)*/, 6) == 0
20546 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20547 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20548 return mv - macro_values + 1;
20550 return 0;
20553 return 0;
20555 _ACEOF
20556 if ac_fn_c_try_run "$LINENO"; then :
20557 gl_cv_header_working_stdint_h=yes
20559 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20560 conftest.$ac_objext conftest.beam conftest.$ac_ext
20565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20569 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20571 if test "$gl_cv_header_working_stdint_h" = yes; then
20572 STDINT_H=
20573 else
20574 for ac_header in sys/inttypes.h sys/bitypes.h
20575 do :
20576 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20577 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20578 eval as_val=\$$as_ac_Header
20579 if test "x$as_val" = x""yes; then :
20580 cat >>confdefs.h <<_ACEOF
20581 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20582 _ACEOF
20586 done
20588 if test $ac_cv_header_sys_inttypes_h = yes; then
20589 HAVE_SYS_INTTYPES_H=1
20590 else
20591 HAVE_SYS_INTTYPES_H=0
20594 if test $ac_cv_header_sys_bitypes_h = yes; then
20595 HAVE_SYS_BITYPES_H=1
20596 else
20597 HAVE_SYS_BITYPES_H=0
20603 if test $APPLE_UNIVERSAL_BUILD = 0; then
20606 for gltype in ptrdiff_t size_t ; do
20607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20608 $as_echo_n "checking for bit size of $gltype... " >&6; }
20609 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20610 $as_echo_n "(cached) " >&6
20611 else
20612 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20613 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20614 included before <wchar.h>. */
20615 #include <stddef.h>
20616 #include <signal.h>
20617 #if HAVE_WCHAR_H
20618 # include <stdio.h>
20619 # include <time.h>
20620 # include <wchar.h>
20621 #endif
20623 #include <limits.h>"; then :
20625 else
20626 result=unknown
20629 eval gl_cv_bitsizeof_${gltype}=\$result
20632 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20634 $as_echo "$ac_res" >&6; }
20635 eval result=\$gl_cv_bitsizeof_${gltype}
20636 if test $result = unknown; then
20637 result=0
20639 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20640 cat >>confdefs.h <<_ACEOF
20641 #define BITSIZEOF_${GLTYPE} $result
20642 _ACEOF
20644 eval BITSIZEOF_${GLTYPE}=\$result
20645 done
20651 for gltype in sig_atomic_t wchar_t wint_t ; do
20652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20653 $as_echo_n "checking for bit size of $gltype... " >&6; }
20654 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20655 $as_echo_n "(cached) " >&6
20656 else
20657 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20658 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20659 included before <wchar.h>. */
20660 #include <stddef.h>
20661 #include <signal.h>
20662 #if HAVE_WCHAR_H
20663 # include <stdio.h>
20664 # include <time.h>
20665 # include <wchar.h>
20666 #endif
20668 #include <limits.h>"; then :
20670 else
20671 result=unknown
20674 eval gl_cv_bitsizeof_${gltype}=\$result
20677 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20679 $as_echo "$ac_res" >&6; }
20680 eval result=\$gl_cv_bitsizeof_${gltype}
20681 if test $result = unknown; then
20682 result=0
20684 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20685 cat >>confdefs.h <<_ACEOF
20686 #define BITSIZEOF_${GLTYPE} $result
20687 _ACEOF
20689 eval BITSIZEOF_${GLTYPE}=\$result
20690 done
20695 for gltype in sig_atomic_t wchar_t wint_t ; do
20696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20697 $as_echo_n "checking whether $gltype is signed... " >&6; }
20698 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20699 $as_echo_n "(cached) " >&6
20700 else
20701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20702 /* end confdefs.h. */
20704 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20705 included before <wchar.h>. */
20706 #include <stddef.h>
20707 #include <signal.h>
20708 #if HAVE_WCHAR_H
20709 # include <stdio.h>
20710 # include <time.h>
20711 # include <wchar.h>
20712 #endif
20714 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20716 main ()
20720 return 0;
20722 _ACEOF
20723 if ac_fn_c_try_compile "$LINENO"; then :
20724 result=yes
20725 else
20726 result=no
20728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20729 eval gl_cv_type_${gltype}_signed=\$result
20732 eval ac_res=\$gl_cv_type_${gltype}_signed
20733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20734 $as_echo "$ac_res" >&6; }
20735 eval result=\$gl_cv_type_${gltype}_signed
20736 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20737 if test "$result" = yes; then
20738 cat >>confdefs.h <<_ACEOF
20739 #define HAVE_SIGNED_${GLTYPE} 1
20740 _ACEOF
20742 eval HAVE_SIGNED_${GLTYPE}=1
20743 else
20744 eval HAVE_SIGNED_${GLTYPE}=0
20746 done
20749 gl_cv_type_ptrdiff_t_signed=yes
20750 gl_cv_type_size_t_signed=no
20751 if test $APPLE_UNIVERSAL_BUILD = 0; then
20754 for gltype in ptrdiff_t size_t ; do
20755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20756 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20757 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20758 $as_echo_n "(cached) " >&6
20759 else
20760 eval gl_cv_type_${gltype}_suffix=no
20761 eval result=\$gl_cv_type_${gltype}_signed
20762 if test "$result" = yes; then
20763 glsufu=
20764 else
20765 glsufu=u
20767 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20768 case $glsuf in
20769 '') gltype1='int';;
20770 l) gltype1='long int';;
20771 ll) gltype1='long long int';;
20772 i64) gltype1='__int64';;
20773 u) gltype1='unsigned int';;
20774 ul) gltype1='unsigned long int';;
20775 ull) gltype1='unsigned long long int';;
20776 ui64)gltype1='unsigned __int64';;
20777 esac
20778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20779 /* end confdefs.h. */
20781 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20782 included before <wchar.h>. */
20783 #include <stddef.h>
20784 #include <signal.h>
20785 #if HAVE_WCHAR_H
20786 # include <stdio.h>
20787 # include <time.h>
20788 # include <wchar.h>
20789 #endif
20791 extern $gltype foo;
20792 extern $gltype1 foo;
20794 main ()
20798 return 0;
20800 _ACEOF
20801 if ac_fn_c_try_compile "$LINENO"; then :
20802 eval gl_cv_type_${gltype}_suffix=\$glsuf
20804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20805 eval result=\$gl_cv_type_${gltype}_suffix
20806 test "$result" != no && break
20807 done
20809 eval ac_res=\$gl_cv_type_${gltype}_suffix
20810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20811 $as_echo "$ac_res" >&6; }
20812 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20813 eval result=\$gl_cv_type_${gltype}_suffix
20814 test "$result" = no && result=
20815 eval ${GLTYPE}_SUFFIX=\$result
20816 cat >>confdefs.h <<_ACEOF
20817 #define ${GLTYPE}_SUFFIX $result
20818 _ACEOF
20820 done
20826 for gltype in sig_atomic_t wchar_t wint_t ; do
20827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20828 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20829 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20830 $as_echo_n "(cached) " >&6
20831 else
20832 eval gl_cv_type_${gltype}_suffix=no
20833 eval result=\$gl_cv_type_${gltype}_signed
20834 if test "$result" = yes; then
20835 glsufu=
20836 else
20837 glsufu=u
20839 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20840 case $glsuf in
20841 '') gltype1='int';;
20842 l) gltype1='long int';;
20843 ll) gltype1='long long int';;
20844 i64) gltype1='__int64';;
20845 u) gltype1='unsigned int';;
20846 ul) gltype1='unsigned long int';;
20847 ull) gltype1='unsigned long long int';;
20848 ui64)gltype1='unsigned __int64';;
20849 esac
20850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20851 /* end confdefs.h. */
20853 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20854 included before <wchar.h>. */
20855 #include <stddef.h>
20856 #include <signal.h>
20857 #if HAVE_WCHAR_H
20858 # include <stdio.h>
20859 # include <time.h>
20860 # include <wchar.h>
20861 #endif
20863 extern $gltype foo;
20864 extern $gltype1 foo;
20866 main ()
20870 return 0;
20872 _ACEOF
20873 if ac_fn_c_try_compile "$LINENO"; then :
20874 eval gl_cv_type_${gltype}_suffix=\$glsuf
20876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20877 eval result=\$gl_cv_type_${gltype}_suffix
20878 test "$result" != no && break
20879 done
20881 eval ac_res=\$gl_cv_type_${gltype}_suffix
20882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20883 $as_echo "$ac_res" >&6; }
20884 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20885 eval result=\$gl_cv_type_${gltype}_suffix
20886 test "$result" = no && result=
20887 eval ${GLTYPE}_SUFFIX=\$result
20888 cat >>confdefs.h <<_ACEOF
20889 #define ${GLTYPE}_SUFFIX $result
20890 _ACEOF
20892 done
20896 if test $BITSIZEOF_WINT_T -lt 32; then
20897 BITSIZEOF_WINT_T=32
20900 STDINT_H=stdint.h
20903 if test -n "$STDINT_H"; then
20904 GL_GENERATE_STDINT_H_TRUE=
20905 GL_GENERATE_STDINT_H_FALSE='#'
20906 else
20907 GL_GENERATE_STDINT_H_TRUE='#'
20908 GL_GENERATE_STDINT_H_FALSE=
20915 GNULIB_IMAXABS=0;
20916 GNULIB_IMAXDIV=0;
20917 GNULIB_STRTOIMAX=0;
20918 GNULIB_STRTOUMAX=0;
20919 HAVE_DECL_IMAXABS=1;
20920 HAVE_DECL_IMAXDIV=1;
20921 HAVE_DECL_STRTOIMAX=1;
20922 HAVE_DECL_STRTOUMAX=1;
20923 REPLACE_STRTOIMAX=0;
20924 INT32_MAX_LT_INTMAX_MAX=1;
20925 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20926 PRI_MACROS_BROKEN=0;
20927 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20928 UINT32_MAX_LT_UINTMAX_MAX=1;
20929 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20945 if test $gl_cv_have_include_next = yes; then
20946 gl_cv_next_inttypes_h='<'inttypes.h'>'
20947 else
20948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20949 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20950 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20951 $as_echo_n "(cached) " >&6
20952 else
20954 if test $ac_cv_header_inttypes_h = yes; then
20957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20958 /* end confdefs.h. */
20959 #include <inttypes.h>
20961 _ACEOF
20962 case "$host_os" in
20963 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20964 *) gl_absname_cpp="$ac_cpp" ;;
20965 esac
20967 case "$host_os" in
20968 mingw*)
20969 gl_dirsep_regex='[/\\]'
20972 gl_dirsep_regex='\/'
20974 esac
20975 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20977 gl_header_literal_regex=`echo 'inttypes.h' \
20978 | sed -e "$gl_make_literal_regex_sed"`
20979 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20980 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20981 s|^/[^/]|//&|
20985 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20986 sed -n "$gl_absolute_header_sed"`'"'
20987 else
20988 gl_cv_next_inttypes_h='<'inttypes.h'>'
20993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
20994 $as_echo "$gl_cv_next_inttypes_h" >&6; }
20996 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
20998 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20999 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21000 gl_next_as_first_directive='<'inttypes.h'>'
21001 else
21002 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21003 gl_next_as_first_directive=$gl_cv_next_inttypes_h
21005 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
21017 case "$host_os" in
21018 mingw*)
21019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
21020 $as_echo_n "checking for 64-bit off_t... " >&6; }
21021 if test "${gl_cv_type_off_t_64+set}" = set; then :
21022 $as_echo_n "(cached) " >&6
21023 else
21024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21025 /* end confdefs.h. */
21026 #include <sys/types.h>
21027 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
21030 main ()
21034 return 0;
21036 _ACEOF
21037 if ac_fn_c_try_compile "$LINENO"; then :
21038 gl_cv_type_off_t_64=yes
21039 else
21040 gl_cv_type_off_t_64=no
21042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
21046 $as_echo "$gl_cv_type_off_t_64" >&6; }
21047 if test $gl_cv_type_off_t_64 = no; then
21048 WINDOWS_64_BIT_OFF_T=1
21049 else
21050 WINDOWS_64_BIT_OFF_T=0
21052 WINDOWS_64_BIT_ST_SIZE=1
21055 WINDOWS_64_BIT_OFF_T=0
21056 WINDOWS_64_BIT_ST_SIZE=0
21058 esac
21063 GNULIB_FFSL=0;
21064 GNULIB_FFSLL=0;
21065 GNULIB_MEMCHR=0;
21066 GNULIB_MEMMEM=0;
21067 GNULIB_MEMPCPY=0;
21068 GNULIB_MEMRCHR=0;
21069 GNULIB_RAWMEMCHR=0;
21070 GNULIB_STPCPY=0;
21071 GNULIB_STPNCPY=0;
21072 GNULIB_STRCHRNUL=0;
21073 GNULIB_STRDUP=0;
21074 GNULIB_STRNCAT=0;
21075 GNULIB_STRNDUP=0;
21076 GNULIB_STRNLEN=0;
21077 GNULIB_STRPBRK=0;
21078 GNULIB_STRSEP=0;
21079 GNULIB_STRSTR=0;
21080 GNULIB_STRCASESTR=0;
21081 GNULIB_STRTOK_R=0;
21082 GNULIB_MBSLEN=0;
21083 GNULIB_MBSNLEN=0;
21084 GNULIB_MBSCHR=0;
21085 GNULIB_MBSRCHR=0;
21086 GNULIB_MBSSTR=0;
21087 GNULIB_MBSCASECMP=0;
21088 GNULIB_MBSNCASECMP=0;
21089 GNULIB_MBSPCASECMP=0;
21090 GNULIB_MBSCASESTR=0;
21091 GNULIB_MBSCSPN=0;
21092 GNULIB_MBSPBRK=0;
21093 GNULIB_MBSSPN=0;
21094 GNULIB_MBSSEP=0;
21095 GNULIB_MBSTOK_R=0;
21096 GNULIB_STRERROR=0;
21097 GNULIB_STRERROR_R=0;
21098 GNULIB_STRSIGNAL=0;
21099 GNULIB_STRVERSCMP=0;
21100 HAVE_MBSLEN=0;
21101 HAVE_FFSL=1;
21102 HAVE_FFSLL=1;
21103 HAVE_MEMCHR=1;
21104 HAVE_DECL_MEMMEM=1;
21105 HAVE_MEMPCPY=1;
21106 HAVE_DECL_MEMRCHR=1;
21107 HAVE_RAWMEMCHR=1;
21108 HAVE_STPCPY=1;
21109 HAVE_STPNCPY=1;
21110 HAVE_STRCHRNUL=1;
21111 HAVE_DECL_STRDUP=1;
21112 HAVE_DECL_STRNDUP=1;
21113 HAVE_DECL_STRNLEN=1;
21114 HAVE_STRPBRK=1;
21115 HAVE_STRSEP=1;
21116 HAVE_STRCASESTR=1;
21117 HAVE_DECL_STRTOK_R=1;
21118 HAVE_DECL_STRERROR_R=1;
21119 HAVE_DECL_STRSIGNAL=1;
21120 HAVE_STRVERSCMP=1;
21121 REPLACE_MEMCHR=0;
21122 REPLACE_MEMMEM=0;
21123 REPLACE_STPNCPY=0;
21124 REPLACE_STRDUP=0;
21125 REPLACE_STRSTR=0;
21126 REPLACE_STRCASESTR=0;
21127 REPLACE_STRCHRNUL=0;
21128 REPLACE_STRERROR=0;
21129 REPLACE_STRERROR_R=0;
21130 REPLACE_STRNCAT=0;
21131 REPLACE_STRNDUP=0;
21132 REPLACE_STRNLEN=0;
21133 REPLACE_STRSIGNAL=0;
21134 REPLACE_STRTOK_R=0;
21135 UNDEFINE_STRTOK_R=0;
21137 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
21138 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
21139 ac_have_decl=1
21140 else
21141 ac_have_decl=0
21144 cat >>confdefs.h <<_ACEOF
21145 #define HAVE_DECL_MEMRCHR $ac_have_decl
21146 _ACEOF
21151 GNULIB_MKTIME=0;
21152 GNULIB_NANOSLEEP=0;
21153 GNULIB_STRPTIME=0;
21154 GNULIB_TIMEGM=0;
21155 GNULIB_TIME_R=0;
21156 HAVE_DECL_LOCALTIME_R=1;
21157 HAVE_NANOSLEEP=1;
21158 HAVE_STRPTIME=1;
21159 HAVE_TIMEGM=1;
21160 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
21161 REPLACE_MKTIME=GNULIB_PORTCHECK;
21162 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
21163 REPLACE_TIMEGM=GNULIB_PORTCHECK;
21165 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
21166 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
21167 ac_have_decl=1
21168 else
21169 ac_have_decl=0
21172 cat >>confdefs.h <<_ACEOF
21173 #define HAVE_DECL_ALARM $ac_have_decl
21174 _ACEOF
21179 GNULIB_PSELECT=0;
21180 GNULIB_SELECT=0;
21181 HAVE_PSELECT=1;
21182 REPLACE_PSELECT=0;
21183 REPLACE_SELECT=0;
21190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
21191 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
21192 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
21193 $as_echo_n "(cached) " >&6
21194 else
21196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21197 /* end confdefs.h. */
21198 #include <sys/select.h>
21200 main ()
21202 struct timeval b;
21204 return 0;
21206 _ACEOF
21207 if ac_fn_c_try_compile "$LINENO"; then :
21208 gl_cv_header_sys_select_h_selfcontained=yes
21209 else
21210 gl_cv_header_sys_select_h_selfcontained=no
21212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21213 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
21214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21215 /* end confdefs.h. */
21216 #include <sys/select.h>
21218 main ()
21220 int memset; int bzero;
21222 return 0;
21225 _ACEOF
21226 if ac_fn_c_try_compile "$LINENO"; then :
21227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21228 /* end confdefs.h. */
21229 #include <sys/select.h>
21231 main ()
21234 #undef memset
21235 #define memset nonexistent_memset
21236 extern
21237 #ifdef __cplusplus
21239 #endif
21240 void *memset (void *, int, unsigned long);
21241 #undef bzero
21242 #define bzero nonexistent_bzero
21243 extern
21244 #ifdef __cplusplus
21246 #endif
21247 void bzero (void *, unsigned long);
21248 fd_set fds;
21249 FD_ZERO (&fds);
21252 return 0;
21255 _ACEOF
21256 if ac_fn_c_try_link "$LINENO"; then :
21258 else
21259 gl_cv_header_sys_select_h_selfcontained=no
21261 rm -f core conftest.err conftest.$ac_objext \
21262 conftest$ac_exeext conftest.$ac_ext
21265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
21270 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
21280 if test $gl_cv_have_include_next = yes; then
21281 gl_cv_next_sys_select_h='<'sys/select.h'>'
21282 else
21283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
21284 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
21285 if test "${gl_cv_next_sys_select_h+set}" = set; then :
21286 $as_echo_n "(cached) " >&6
21287 else
21289 if test $ac_cv_header_sys_select_h = yes; then
21292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21293 /* end confdefs.h. */
21294 #include <sys/select.h>
21296 _ACEOF
21297 case "$host_os" in
21298 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21299 *) gl_absname_cpp="$ac_cpp" ;;
21300 esac
21302 case "$host_os" in
21303 mingw*)
21304 gl_dirsep_regex='[/\\]'
21307 gl_dirsep_regex='\/'
21309 esac
21310 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21312 gl_header_literal_regex=`echo 'sys/select.h' \
21313 | sed -e "$gl_make_literal_regex_sed"`
21314 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21315 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21316 s|^/[^/]|//&|
21320 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21321 sed -n "$gl_absolute_header_sed"`'"'
21322 else
21323 gl_cv_next_sys_select_h='<'sys/select.h'>'
21328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
21329 $as_echo "$gl_cv_next_sys_select_h" >&6; }
21331 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
21333 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21334 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21335 gl_next_as_first_directive='<'sys/select.h'>'
21336 else
21337 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21338 gl_next_as_first_directive=$gl_cv_next_sys_select_h
21340 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
21345 if test $ac_cv_header_sys_select_h = yes; then
21346 HAVE_SYS_SELECT_H=1
21347 else
21348 HAVE_SYS_SELECT_H=0
21355 if test $ac_cv_header_sys_socket_h != yes; then
21356 for ac_header in winsock2.h
21357 do :
21358 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21359 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
21360 cat >>confdefs.h <<_ACEOF
21361 #define HAVE_WINSOCK2_H 1
21362 _ACEOF
21366 done
21369 if test "$ac_cv_header_winsock2_h" = yes; then
21370 HAVE_WINSOCK2_H=1
21371 UNISTD_H_HAVE_WINSOCK2_H=1
21372 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21373 else
21374 HAVE_WINSOCK2_H=0
21384 GNULIB_PTHREAD_SIGMASK=0;
21385 GNULIB_RAISE=0;
21386 GNULIB_SIGNAL_H_SIGPIPE=0;
21387 GNULIB_SIGPROCMASK=0;
21388 GNULIB_SIGACTION=0;
21389 HAVE_POSIX_SIGNALBLOCKING=1;
21390 HAVE_PTHREAD_SIGMASK=1;
21391 HAVE_RAISE=1;
21392 HAVE_SIGSET_T=1;
21393 HAVE_SIGINFO_T=1;
21394 HAVE_SIGACTION=1;
21395 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
21397 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
21399 HAVE_SIGHANDLER_T=1;
21400 REPLACE_PTHREAD_SIGMASK=0;
21401 REPLACE_RAISE=0;
21409 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
21410 #include <signal.h>
21411 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
21412 #include <sys/types.h>
21415 if test "x$ac_cv_type_sigset_t" = x""yes; then :
21417 cat >>confdefs.h <<_ACEOF
21418 #define HAVE_SIGSET_T 1
21419 _ACEOF
21421 gl_cv_type_sigset_t=yes
21422 else
21423 gl_cv_type_sigset_t=no
21426 if test $gl_cv_type_sigset_t != yes; then
21427 HAVE_SIGSET_T=0
21432 if test $ac_cv_header_sys_socket_h = no; then
21433 for ac_header in ws2tcpip.h
21434 do :
21435 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
21436 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
21437 cat >>confdefs.h <<_ACEOF
21438 #define HAVE_WS2TCPIP_H 1
21439 _ACEOF
21443 done
21447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21448 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21449 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21450 $as_echo_n "(cached) " >&6
21451 else
21452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21453 /* end confdefs.h. */
21455 #include <stdbool.h>
21456 #ifndef bool
21457 "error: bool is not defined"
21458 #endif
21459 #ifndef false
21460 "error: false is not defined"
21461 #endif
21462 #if false
21463 "error: false is not 0"
21464 #endif
21465 #ifndef true
21466 "error: true is not defined"
21467 #endif
21468 #if true != 1
21469 "error: true is not 1"
21470 #endif
21471 #ifndef __bool_true_false_are_defined
21472 "error: __bool_true_false_are_defined is not defined"
21473 #endif
21475 struct s { _Bool s: 1; _Bool t; } s;
21477 char a[true == 1 ? 1 : -1];
21478 char b[false == 0 ? 1 : -1];
21479 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21480 char d[(bool) 0.5 == true ? 1 : -1];
21481 /* See body of main program for 'e'. */
21482 char f[(_Bool) 0.0 == false ? 1 : -1];
21483 char g[true];
21484 char h[sizeof (_Bool)];
21485 char i[sizeof s.t];
21486 enum { j = false, k = true, l = false * true, m = true * 256 };
21487 /* The following fails for
21488 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21489 _Bool n[m];
21490 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21491 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21492 /* Catch a bug in an HP-UX C compiler. See
21493 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21494 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21496 _Bool q = true;
21497 _Bool *pq = &q;
21500 main ()
21503 bool e = &s;
21504 *pq |= q;
21505 *pq |= ! q;
21506 /* Refer to every declared value, to avoid compiler optimizations. */
21507 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21508 + !m + !n + !o + !p + !q + !pq);
21511 return 0;
21513 _ACEOF
21514 if ac_fn_c_try_compile "$LINENO"; then :
21515 ac_cv_header_stdbool_h=yes
21516 else
21517 ac_cv_header_stdbool_h=no
21519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21522 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21523 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21524 if test "x$ac_cv_type__Bool" = x""yes; then :
21526 cat >>confdefs.h <<_ACEOF
21527 #define HAVE__BOOL 1
21528 _ACEOF
21535 REPLACE_NULL=0;
21536 HAVE_WCHAR_T=1;
21539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21540 $as_echo_n "checking for wchar_t... " >&6; }
21541 if test "${gt_cv_c_wchar_t+set}" = set; then :
21542 $as_echo_n "(cached) " >&6
21543 else
21544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21545 /* end confdefs.h. */
21546 #include <stddef.h>
21547 wchar_t foo = (wchar_t)'\0';
21549 main ()
21553 return 0;
21555 _ACEOF
21556 if ac_fn_c_try_compile "$LINENO"; then :
21557 gt_cv_c_wchar_t=yes
21558 else
21559 gt_cv_c_wchar_t=no
21561 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21564 $as_echo "$gt_cv_c_wchar_t" >&6; }
21565 if test $gt_cv_c_wchar_t = yes; then
21567 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21572 GNULIB_DPRINTF=0;
21573 GNULIB_FCLOSE=0;
21574 GNULIB_FDOPEN=0;
21575 GNULIB_FFLUSH=0;
21576 GNULIB_FGETC=0;
21577 GNULIB_FGETS=0;
21578 GNULIB_FOPEN=0;
21579 GNULIB_FPRINTF=0;
21580 GNULIB_FPRINTF_POSIX=0;
21581 GNULIB_FPURGE=0;
21582 GNULIB_FPUTC=0;
21583 GNULIB_FPUTS=0;
21584 GNULIB_FREAD=0;
21585 GNULIB_FREOPEN=0;
21586 GNULIB_FSCANF=0;
21587 GNULIB_FSEEK=0;
21588 GNULIB_FSEEKO=0;
21589 GNULIB_FTELL=0;
21590 GNULIB_FTELLO=0;
21591 GNULIB_FWRITE=0;
21592 GNULIB_GETC=0;
21593 GNULIB_GETCHAR=0;
21594 GNULIB_GETDELIM=0;
21595 GNULIB_GETLINE=0;
21596 GNULIB_OBSTACK_PRINTF=0;
21597 GNULIB_OBSTACK_PRINTF_POSIX=0;
21598 GNULIB_PCLOSE=0;
21599 GNULIB_PERROR=0;
21600 GNULIB_POPEN=0;
21601 GNULIB_PRINTF=0;
21602 GNULIB_PRINTF_POSIX=0;
21603 GNULIB_PUTC=0;
21604 GNULIB_PUTCHAR=0;
21605 GNULIB_PUTS=0;
21606 GNULIB_REMOVE=0;
21607 GNULIB_RENAME=0;
21608 GNULIB_RENAMEAT=0;
21609 GNULIB_SCANF=0;
21610 GNULIB_SNPRINTF=0;
21611 GNULIB_SPRINTF_POSIX=0;
21612 GNULIB_STDIO_H_NONBLOCKING=0;
21613 GNULIB_STDIO_H_SIGPIPE=0;
21614 GNULIB_TMPFILE=0;
21615 GNULIB_VASPRINTF=0;
21616 GNULIB_VFSCANF=0;
21617 GNULIB_VSCANF=0;
21618 GNULIB_VDPRINTF=0;
21619 GNULIB_VFPRINTF=0;
21620 GNULIB_VFPRINTF_POSIX=0;
21621 GNULIB_VPRINTF=0;
21622 GNULIB_VPRINTF_POSIX=0;
21623 GNULIB_VSNPRINTF=0;
21624 GNULIB_VSPRINTF_POSIX=0;
21625 HAVE_DECL_FPURGE=1;
21626 HAVE_DECL_FSEEKO=1;
21627 HAVE_DECL_FTELLO=1;
21628 HAVE_DECL_GETDELIM=1;
21629 HAVE_DECL_GETLINE=1;
21630 HAVE_DECL_OBSTACK_PRINTF=1;
21631 HAVE_DECL_SNPRINTF=1;
21632 HAVE_DECL_VSNPRINTF=1;
21633 HAVE_DPRINTF=1;
21634 HAVE_FSEEKO=1;
21635 HAVE_FTELLO=1;
21636 HAVE_PCLOSE=1;
21637 HAVE_POPEN=1;
21638 HAVE_RENAMEAT=1;
21639 HAVE_VASPRINTF=1;
21640 HAVE_VDPRINTF=1;
21641 REPLACE_DPRINTF=0;
21642 REPLACE_FCLOSE=0;
21643 REPLACE_FDOPEN=0;
21644 REPLACE_FFLUSH=0;
21645 REPLACE_FOPEN=0;
21646 REPLACE_FPRINTF=0;
21647 REPLACE_FPURGE=0;
21648 REPLACE_FREOPEN=0;
21649 REPLACE_FSEEK=0;
21650 REPLACE_FSEEKO=0;
21651 REPLACE_FTELL=0;
21652 REPLACE_FTELLO=0;
21653 REPLACE_GETDELIM=0;
21654 REPLACE_GETLINE=0;
21655 REPLACE_OBSTACK_PRINTF=0;
21656 REPLACE_PERROR=0;
21657 REPLACE_POPEN=0;
21658 REPLACE_PRINTF=0;
21659 REPLACE_REMOVE=0;
21660 REPLACE_RENAME=0;
21661 REPLACE_RENAMEAT=0;
21662 REPLACE_SNPRINTF=0;
21663 REPLACE_SPRINTF=0;
21664 REPLACE_STDIO_READ_FUNCS=0;
21665 REPLACE_STDIO_WRITE_FUNCS=0;
21666 REPLACE_TMPFILE=0;
21667 REPLACE_VASPRINTF=0;
21668 REPLACE_VDPRINTF=0;
21669 REPLACE_VFPRINTF=0;
21670 REPLACE_VPRINTF=0;
21671 REPLACE_VSNPRINTF=0;
21672 REPLACE_VSPRINTF=0;
21674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21675 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21676 if test "${ac_cv_struct_tm+set}" = set; then :
21677 $as_echo_n "(cached) " >&6
21678 else
21679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21680 /* end confdefs.h. */
21681 #include <sys/types.h>
21682 #include <time.h>
21685 main ()
21687 struct tm tm;
21688 int *p = &tm.tm_sec;
21689 return !p;
21691 return 0;
21693 _ACEOF
21694 if ac_fn_c_try_compile "$LINENO"; then :
21695 ac_cv_struct_tm=time.h
21696 else
21697 ac_cv_struct_tm=sys/time.h
21699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21702 $as_echo "$ac_cv_struct_tm" >&6; }
21703 if test $ac_cv_struct_tm = sys/time.h; then
21705 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21709 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21710 #include <$ac_cv_struct_tm>
21713 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21715 cat >>confdefs.h <<_ACEOF
21716 #define HAVE_STRUCT_TM_TM_ZONE 1
21717 _ACEOF
21722 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21724 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21726 else
21727 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21729 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21730 ac_have_decl=1
21731 else
21732 ac_have_decl=0
21735 cat >>confdefs.h <<_ACEOF
21736 #define HAVE_DECL_TZNAME $ac_have_decl
21737 _ACEOF
21739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21740 $as_echo_n "checking for tzname... " >&6; }
21741 if test "${ac_cv_var_tzname+set}" = set; then :
21742 $as_echo_n "(cached) " >&6
21743 else
21744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21745 /* end confdefs.h. */
21746 #include <time.h>
21747 #if !HAVE_DECL_TZNAME
21748 extern char *tzname[];
21749 #endif
21752 main ()
21754 return tzname[0][0];
21756 return 0;
21758 _ACEOF
21759 if ac_fn_c_try_link "$LINENO"; then :
21760 ac_cv_var_tzname=yes
21761 else
21762 ac_cv_var_tzname=no
21764 rm -f core conftest.err conftest.$ac_objext \
21765 conftest$ac_exeext conftest.$ac_ext
21767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21768 $as_echo "$ac_cv_var_tzname" >&6; }
21769 if test $ac_cv_var_tzname = yes; then
21771 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21777 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21779 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21781 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21797 if test $gl_cv_have_include_next = yes; then
21798 gl_cv_next_string_h='<'string.h'>'
21799 else
21800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21801 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21802 if test "${gl_cv_next_string_h+set}" = set; then :
21803 $as_echo_n "(cached) " >&6
21804 else
21806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21807 /* end confdefs.h. */
21808 #include <string.h>
21810 _ACEOF
21811 case "$host_os" in
21812 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21813 *) gl_absname_cpp="$ac_cpp" ;;
21814 esac
21816 case "$host_os" in
21817 mingw*)
21818 gl_dirsep_regex='[/\\]'
21821 gl_dirsep_regex='\/'
21823 esac
21824 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21826 gl_header_literal_regex=`echo 'string.h' \
21827 | sed -e "$gl_make_literal_regex_sed"`
21828 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21829 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21830 s|^/[^/]|//&|
21834 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21835 sed -n "$gl_absolute_header_sed"`'"'
21839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21840 $as_echo "$gl_cv_next_string_h" >&6; }
21842 NEXT_STRING_H=$gl_cv_next_string_h
21844 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21845 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21846 gl_next_as_first_directive='<'string.h'>'
21847 else
21848 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21849 gl_next_as_first_directive=$gl_cv_next_string_h
21851 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21861 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21862 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21863 ac_have_decl=1
21864 else
21865 ac_have_decl=0
21868 cat >>confdefs.h <<_ACEOF
21869 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21870 _ACEOF
21874 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21875 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21876 ac_have_decl=1
21877 else
21878 ac_have_decl=0
21881 cat >>confdefs.h <<_ACEOF
21882 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21883 _ACEOF
21887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21888 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21889 if test "${ac_cv_header_stat_broken+set}" = set; then :
21890 $as_echo_n "(cached) " >&6
21891 else
21892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21893 /* end confdefs.h. */
21894 #include <sys/types.h>
21895 #include <sys/stat.h>
21897 #if defined S_ISBLK && defined S_IFDIR
21898 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21899 #endif
21901 #if defined S_ISBLK && defined S_IFCHR
21902 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21903 #endif
21905 #if defined S_ISLNK && defined S_IFREG
21906 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21907 #endif
21909 #if defined S_ISSOCK && defined S_IFREG
21910 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21911 #endif
21913 _ACEOF
21914 if ac_fn_c_try_compile "$LINENO"; then :
21915 ac_cv_header_stat_broken=no
21916 else
21917 ac_cv_header_stat_broken=yes
21919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21922 $as_echo "$ac_cv_header_stat_broken" >&6; }
21923 if test $ac_cv_header_stat_broken = yes; then
21925 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21934 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21935 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21936 $as_echo_n "(cached) " >&6
21937 else
21938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21939 /* end confdefs.h. */
21940 #include <time.h>
21943 main ()
21945 static struct timespec x; x.tv_sec = x.tv_nsec;
21947 return 0;
21949 _ACEOF
21950 if ac_fn_c_try_compile "$LINENO"; then :
21951 gl_cv_sys_struct_timespec_in_time_h=yes
21952 else
21953 gl_cv_sys_struct_timespec_in_time_h=no
21955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21958 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21960 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21961 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21962 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21963 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21964 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21965 else
21966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21967 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21968 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21969 $as_echo_n "(cached) " >&6
21970 else
21971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21972 /* end confdefs.h. */
21973 #include <sys/time.h>
21976 main ()
21978 static struct timespec x; x.tv_sec = x.tv_nsec;
21980 return 0;
21982 _ACEOF
21983 if ac_fn_c_try_compile "$LINENO"; then :
21984 gl_cv_sys_struct_timespec_in_sys_time_h=yes
21985 else
21986 gl_cv_sys_struct_timespec_in_sys_time_h=no
21988 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
21991 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
21992 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
21993 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
21994 else
21995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
21996 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
21997 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
21998 $as_echo_n "(cached) " >&6
21999 else
22000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22001 /* end confdefs.h. */
22002 #include <pthread.h>
22005 main ()
22007 static struct timespec x; x.tv_sec = x.tv_nsec;
22009 return 0;
22011 _ACEOF
22012 if ac_fn_c_try_compile "$LINENO"; then :
22013 gl_cv_sys_struct_timespec_in_pthread_h=yes
22014 else
22015 gl_cv_sys_struct_timespec_in_pthread_h=no
22017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
22020 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
22021 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
22022 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
22041 if test $gl_cv_have_include_next = yes; then
22042 gl_cv_next_time_h='<'time.h'>'
22043 else
22044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
22045 $as_echo_n "checking absolute name of <time.h>... " >&6; }
22046 if test "${gl_cv_next_time_h+set}" = set; then :
22047 $as_echo_n "(cached) " >&6
22048 else
22050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22051 /* end confdefs.h. */
22052 #include <time.h>
22054 _ACEOF
22055 case "$host_os" in
22056 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22057 *) gl_absname_cpp="$ac_cpp" ;;
22058 esac
22060 case "$host_os" in
22061 mingw*)
22062 gl_dirsep_regex='[/\\]'
22065 gl_dirsep_regex='\/'
22067 esac
22068 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22070 gl_header_literal_regex=`echo 'time.h' \
22071 | sed -e "$gl_make_literal_regex_sed"`
22072 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22073 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22074 s|^/[^/]|//&|
22078 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22079 sed -n "$gl_absolute_header_sed"`'"'
22083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
22084 $as_echo "$gl_cv_next_time_h" >&6; }
22086 NEXT_TIME_H=$gl_cv_next_time_h
22088 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22089 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22090 gl_next_as_first_directive='<'time.h'>'
22091 else
22092 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22093 gl_next_as_first_directive=$gl_cv_next_time_h
22095 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
22110 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
22111 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
22112 ac_have_decl=1
22113 else
22114 ac_have_decl=0
22117 cat >>confdefs.h <<_ACEOF
22118 #define HAVE_DECL_UNSETENV $ac_have_decl
22119 _ACEOF
22122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
22123 $as_echo_n "checking whether the utimes function works... " >&6; }
22124 if test "${gl_cv_func_working_utimes+set}" = set; then :
22125 $as_echo_n "(cached) " >&6
22126 else
22128 if test "$cross_compiling" = yes; then :
22129 gl_cv_func_working_utimes=no
22130 else
22131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22132 /* end confdefs.h. */
22134 #include <sys/types.h>
22135 #include <sys/stat.h>
22136 #include <fcntl.h>
22137 #include <sys/time.h>
22138 #include <time.h>
22139 #include <unistd.h>
22140 #include <stdlib.h>
22141 #include <stdio.h>
22142 #include <utime.h>
22144 static int
22145 inorder (time_t a, time_t b, time_t c)
22147 return a <= b && b <= c;
22151 main ()
22153 int result = 0;
22154 char const *file = "conftest.utimes";
22155 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
22157 /* Test whether utimes() essentially works. */
22159 struct stat sbuf;
22160 FILE *f = fopen (file, "w");
22161 if (f == NULL)
22162 result |= 1;
22163 else if (fclose (f) != 0)
22164 result |= 1;
22165 else if (utimes (file, timeval) != 0)
22166 result |= 2;
22167 else if (lstat (file, &sbuf) != 0)
22168 result |= 1;
22169 else if (!(sbuf.st_atime == timeval[0].tv_sec
22170 && sbuf.st_mtime == timeval[1].tv_sec))
22171 result |= 4;
22172 if (unlink (file) != 0)
22173 result |= 1;
22176 /* Test whether utimes() with a NULL argument sets the file's timestamp
22177 to the current time. Use 'fstat' as well as 'time' to
22178 determine the "current" time, to accommodate NFS file systems
22179 if there is a time skew between the host and the NFS server. */
22181 int fd = open (file, O_WRONLY|O_CREAT, 0644);
22182 if (fd < 0)
22183 result |= 1;
22184 else
22186 time_t t0, t2;
22187 struct stat st0, st1, st2;
22188 if (time (&t0) == (time_t) -1)
22189 result |= 1;
22190 else if (fstat (fd, &st0) != 0)
22191 result |= 1;
22192 else if (utimes (file, timeval) != 0)
22193 result |= 2;
22194 else if (utimes (file, NULL) != 0)
22195 result |= 8;
22196 else if (fstat (fd, &st1) != 0)
22197 result |= 1;
22198 else if (write (fd, "\n", 1) != 1)
22199 result |= 1;
22200 else if (fstat (fd, &st2) != 0)
22201 result |= 1;
22202 else if (time (&t2) == (time_t) -1)
22203 result |= 1;
22204 else
22206 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
22207 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
22208 if (! (st1.st_atime == st1.st_mtime))
22209 result |= 16;
22210 if (! (m_ok_POSIX || m_ok_NFS))
22211 result |= 32;
22213 if (close (fd) != 0)
22214 result |= 1;
22216 if (unlink (file) != 0)
22217 result |= 1;
22220 /* Test whether utimes() with a NULL argument works on read-only files. */
22222 int fd = open (file, O_WRONLY|O_CREAT, 0444);
22223 if (fd < 0)
22224 result |= 1;
22225 else if (close (fd) != 0)
22226 result |= 1;
22227 else if (utimes (file, NULL) != 0)
22228 result |= 64;
22229 if (unlink (file) != 0)
22230 result |= 1;
22233 return result;
22236 _ACEOF
22237 if ac_fn_c_try_run "$LINENO"; then :
22238 gl_cv_func_working_utimes=yes
22239 else
22240 gl_cv_func_working_utimes=no
22242 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22243 conftest.$ac_objext conftest.beam conftest.$ac_ext
22247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
22248 $as_echo "$gl_cv_func_working_utimes" >&6; }
22250 if test $gl_cv_func_working_utimes = yes; then
22252 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
22260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
22261 $as_echo_n "checking for struct utimbuf... " >&6; }
22262 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
22263 $as_echo_n "(cached) " >&6
22264 else
22265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22266 /* end confdefs.h. */
22267 #if HAVE_SYS_TIME_H
22268 #include <sys/time.h>
22269 #endif
22270 #include <time.h>
22271 #ifdef HAVE_UTIME_H
22272 #include <utime.h>
22273 #endif
22276 main ()
22278 static struct utimbuf x; x.actime = x.modtime;
22280 return 0;
22282 _ACEOF
22283 if ac_fn_c_try_compile "$LINENO"; then :
22284 gl_cv_sys_struct_utimbuf=yes
22285 else
22286 gl_cv_sys_struct_utimbuf=no
22288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
22291 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
22293 if test $gl_cv_sys_struct_utimbuf = yes; then
22295 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
22309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
22310 $as_echo_n "checking type of array argument to getgroups... " >&6; }
22311 if test "${ac_cv_type_getgroups+set}" = set; then :
22312 $as_echo_n "(cached) " >&6
22313 else
22314 if test "$cross_compiling" = yes; then :
22315 ac_cv_type_getgroups=cross
22316 else
22317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22318 /* end confdefs.h. */
22319 /* Thanks to Mike Rendell for this test. */
22320 $ac_includes_default
22321 #define NGID 256
22322 #undef MAX
22323 #define MAX(x, y) ((x) > (y) ? (x) : (y))
22326 main ()
22328 gid_t gidset[NGID];
22329 int i, n;
22330 union { gid_t gval; long int lval; } val;
22332 val.lval = -1;
22333 for (i = 0; i < NGID; i++)
22334 gidset[i] = val.gval;
22335 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
22336 gidset);
22337 /* Exit non-zero if getgroups seems to require an array of ints. This
22338 happens when gid_t is short int but getgroups modifies an array
22339 of ints. */
22340 return n > 0 && gidset[n] != val.gval;
22342 _ACEOF
22343 if ac_fn_c_try_run "$LINENO"; then :
22344 ac_cv_type_getgroups=gid_t
22345 else
22346 ac_cv_type_getgroups=int
22348 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22349 conftest.$ac_objext conftest.beam conftest.$ac_ext
22352 if test $ac_cv_type_getgroups = cross; then
22353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22354 /* end confdefs.h. */
22355 #include <unistd.h>
22357 _ACEOF
22358 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22359 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
22360 ac_cv_type_getgroups=gid_t
22361 else
22362 ac_cv_type_getgroups=int
22364 rm -f conftest*
22368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
22369 $as_echo "$ac_cv_type_getgroups" >&6; }
22371 cat >>confdefs.h <<_ACEOF
22372 #define GETGROUPS_T $ac_cv_type_getgroups
22373 _ACEOF
22382 if false; then
22383 GL_COND_LIBTOOL_TRUE=
22384 GL_COND_LIBTOOL_FALSE='#'
22385 else
22386 GL_COND_LIBTOOL_TRUE='#'
22387 GL_COND_LIBTOOL_FALSE=
22390 gl_cond_libtool=false
22391 gl_libdeps=
22392 gl_ltlibdeps=
22393 gl_m4_base='m4'
22403 gl_source_base='lib'
22406 if test $ac_cv_func_alloca_works = no; then
22410 # Define an additional variable used in the Makefile substitution.
22411 if test $ac_cv_working_alloca_h = yes; then
22412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
22413 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
22414 if test "${gl_cv_rpl_alloca+set}" = set; then :
22415 $as_echo_n "(cached) " >&6
22416 else
22418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22419 /* end confdefs.h. */
22421 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
22422 Need own alloca
22423 #endif
22425 _ACEOF
22426 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22427 $EGREP "Need own alloca" >/dev/null 2>&1; then :
22428 gl_cv_rpl_alloca=yes
22429 else
22430 gl_cv_rpl_alloca=no
22432 rm -f conftest*
22436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
22437 $as_echo "$gl_cv_rpl_alloca" >&6; }
22438 if test $gl_cv_rpl_alloca = yes; then
22440 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
22442 ALLOCA_H=alloca.h
22443 else
22444 ALLOCA_H=
22446 else
22447 ALLOCA_H=alloca.h
22450 if test -n "$ALLOCA_H"; then
22451 GL_GENERATE_ALLOCA_H_TRUE=
22452 GL_GENERATE_ALLOCA_H_FALSE='#'
22453 else
22454 GL_GENERATE_ALLOCA_H_TRUE='#'
22455 GL_GENERATE_ALLOCA_H_FALSE=
22463 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22464 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22466 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22467 # programs in the package would end up linked with that potentially-shared
22468 # library, inducing unnecessary run-time overhead.
22469 LIB_CLOCK_GETTIME=
22471 gl_saved_libs=$LIBS
22472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22473 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22474 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22475 $as_echo_n "(cached) " >&6
22476 else
22477 ac_func_search_save_LIBS=$LIBS
22478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22479 /* end confdefs.h. */
22481 /* Override any GCC internal prototype to avoid an error.
22482 Use char because int might match the return type of a GCC
22483 builtin and then its argument prototype would still apply. */
22484 #ifdef __cplusplus
22485 extern "C"
22486 #endif
22487 char clock_gettime ();
22489 main ()
22491 return clock_gettime ();
22493 return 0;
22495 _ACEOF
22496 for ac_lib in '' rt posix4; do
22497 if test -z "$ac_lib"; then
22498 ac_res="none required"
22499 else
22500 ac_res=-l$ac_lib
22501 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22503 if ac_fn_c_try_link "$LINENO"; then :
22504 ac_cv_search_clock_gettime=$ac_res
22506 rm -f core conftest.err conftest.$ac_objext \
22507 conftest$ac_exeext
22508 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22509 break
22511 done
22512 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22514 else
22515 ac_cv_search_clock_gettime=no
22517 rm conftest.$ac_ext
22518 LIBS=$ac_func_search_save_LIBS
22520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22521 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22522 ac_res=$ac_cv_search_clock_gettime
22523 if test "$ac_res" != no; then :
22524 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22525 test "$ac_cv_search_clock_gettime" = "none required" ||
22526 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22529 for ac_func in clock_gettime clock_settime
22530 do :
22531 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22532 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22533 eval as_val=\$$as_ac_var
22534 if test "x$as_val" = x""yes; then :
22535 cat >>confdefs.h <<_ACEOF
22536 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22537 _ACEOF
22540 done
22542 LIBS=$gl_saved_libs
22549 cat >>confdefs.h <<_ACEOF
22550 #define GNULIB_CLOSE_STREAM 1
22551 _ACEOF
22582 if test $gl_cv_have_include_next = yes; then
22583 gl_cv_next_dirent_h='<'dirent.h'>'
22584 else
22585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22586 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22587 if test "${gl_cv_next_dirent_h+set}" = set; then :
22588 $as_echo_n "(cached) " >&6
22589 else
22591 if test $ac_cv_header_dirent_h = yes; then
22594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22595 /* end confdefs.h. */
22596 #include <dirent.h>
22598 _ACEOF
22599 case "$host_os" in
22600 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22601 *) gl_absname_cpp="$ac_cpp" ;;
22602 esac
22604 case "$host_os" in
22605 mingw*)
22606 gl_dirsep_regex='[/\\]'
22609 gl_dirsep_regex='\/'
22611 esac
22612 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22614 gl_header_literal_regex=`echo 'dirent.h' \
22615 | sed -e "$gl_make_literal_regex_sed"`
22616 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22617 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22618 s|^/[^/]|//&|
22622 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22623 sed -n "$gl_absolute_header_sed"`'"'
22624 else
22625 gl_cv_next_dirent_h='<'dirent.h'>'
22630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22631 $as_echo "$gl_cv_next_dirent_h" >&6; }
22633 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22635 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22636 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22637 gl_next_as_first_directive='<'dirent.h'>'
22638 else
22639 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22640 gl_next_as_first_directive=$gl_cv_next_dirent_h
22642 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22647 if test $ac_cv_header_dirent_h = yes; then
22648 HAVE_DIRENT_H=1
22649 else
22650 HAVE_DIRENT_H=0
22662 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22665 if test $HAVE_DUP2 = 1; then
22666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22667 $as_echo_n "checking whether dup2 works... " >&6; }
22668 if test "${gl_cv_func_dup2_works+set}" = set; then :
22669 $as_echo_n "(cached) " >&6
22670 else
22671 if test "$cross_compiling" = yes; then :
22672 case "$host_os" in
22673 mingw*) # on this platform, dup2 always returns 0 for success
22674 gl_cv_func_dup2_works="guessing no" ;;
22675 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22676 gl_cv_func_dup2_works="guessing no" ;;
22677 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22678 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22679 gl_cv_func_dup2_works="guessing no" ;;
22680 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22681 gl_cv_func_dup2_works="guessing no" ;;
22682 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22683 gl_cv_func_dup2_works="guessing no" ;;
22684 *) gl_cv_func_dup2_works="guessing yes" ;;
22685 esac
22686 else
22687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22688 /* end confdefs.h. */
22690 #include <unistd.h>
22691 #include <fcntl.h>
22692 #include <errno.h>
22694 main ()
22696 int result = 0;
22697 #ifdef FD_CLOEXEC
22698 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22699 result |= 1;
22700 #endif
22701 if (dup2 (1, 1) == 0)
22702 result |= 2;
22703 #ifdef FD_CLOEXEC
22704 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22705 result |= 4;
22706 #endif
22707 close (0);
22708 if (dup2 (0, 0) != -1)
22709 result |= 8;
22710 /* Many gnulib modules require POSIX conformance of EBADF. */
22711 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22712 result |= 16;
22713 /* Flush out a cygwin core dump. */
22714 if (dup2 (2, -1) != -1 || errno != EBADF)
22715 result |= 32;
22716 return result;
22719 return 0;
22722 _ACEOF
22723 if ac_fn_c_try_run "$LINENO"; then :
22724 gl_cv_func_dup2_works=yes
22725 else
22726 gl_cv_func_dup2_works=no
22728 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22729 conftest.$ac_objext conftest.beam conftest.$ac_ext
22734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22735 $as_echo "$gl_cv_func_dup2_works" >&6; }
22736 case "$gl_cv_func_dup2_works" in
22737 *yes) ;;
22739 REPLACE_DUP2=1
22741 esac
22745 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22754 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22763 GNULIB_DUP2=1
22775 GNULIB_ENVIRON=1
22785 LIB_EXECINFO=''
22786 EXECINFO_H='execinfo.h'
22788 if test $ac_cv_header_execinfo_h = yes; then
22789 gl_saved_libs=$LIBS
22790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22791 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22792 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22793 $as_echo_n "(cached) " >&6
22794 else
22795 ac_func_search_save_LIBS=$LIBS
22796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22797 /* end confdefs.h. */
22799 /* Override any GCC internal prototype to avoid an error.
22800 Use char because int might match the return type of a GCC
22801 builtin and then its argument prototype would still apply. */
22802 #ifdef __cplusplus
22803 extern "C"
22804 #endif
22805 char backtrace_symbols_fd ();
22807 main ()
22809 return backtrace_symbols_fd ();
22811 return 0;
22813 _ACEOF
22814 for ac_lib in '' execinfo; do
22815 if test -z "$ac_lib"; then
22816 ac_res="none required"
22817 else
22818 ac_res=-l$ac_lib
22819 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22821 if ac_fn_c_try_link "$LINENO"; then :
22822 ac_cv_search_backtrace_symbols_fd=$ac_res
22824 rm -f core conftest.err conftest.$ac_objext \
22825 conftest$ac_exeext
22826 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22827 break
22829 done
22830 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22832 else
22833 ac_cv_search_backtrace_symbols_fd=no
22835 rm conftest.$ac_ext
22836 LIBS=$ac_func_search_save_LIBS
22838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22839 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22840 ac_res=$ac_cv_search_backtrace_symbols_fd
22841 if test "$ac_res" != no; then :
22842 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22843 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22844 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22847 LIBS=$gl_saved_libs
22848 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22851 if test -n "$EXECINFO_H"; then
22860 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22866 if test -n "$EXECINFO_H"; then
22867 GL_GENERATE_EXECINFO_H_TRUE=
22868 GL_GENERATE_EXECINFO_H_FALSE='#'
22869 else
22870 GL_GENERATE_EXECINFO_H_TRUE='#'
22871 GL_GENERATE_EXECINFO_H_FALSE=
22882 if test $ac_cv_func_faccessat = no; then
22883 HAVE_FACCESSAT=0
22886 if test $HAVE_FACCESSAT = 0; then
22895 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22898 for ac_func in access
22899 do :
22900 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22901 if test "x$ac_cv_func_access" = x""yes; then :
22902 cat >>confdefs.h <<_ACEOF
22903 #define HAVE_ACCESS 1
22904 _ACEOF
22907 done
22913 cat >>confdefs.h <<_ACEOF
22914 #define GNULIB_FACCESSAT 1
22915 _ACEOF
22923 GNULIB_FACCESSAT=1
22934 if test $ac_cv_func_fcntl = no; then
22938 if test $ac_cv_func_fcntl = no; then
22939 HAVE_FCNTL=0
22940 else
22941 REPLACE_FCNTL=1
22944 else
22945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
22946 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
22947 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
22948 $as_echo_n "(cached) " >&6
22949 else
22950 if test "$cross_compiling" = yes; then :
22951 # Guess that it works on glibc systems
22952 case $host_os in #((
22953 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
22954 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
22955 esac
22956 else
22957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22958 /* end confdefs.h. */
22960 #include <fcntl.h>
22961 #include <errno.h>
22964 main ()
22966 int result = 0;
22967 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
22968 if (errno != EINVAL) result |= 2;
22969 return result;
22972 return 0;
22974 _ACEOF
22975 if ac_fn_c_try_run "$LINENO"; then :
22976 gl_cv_func_fcntl_f_dupfd_works=yes
22977 else
22978 gl_cv_func_fcntl_f_dupfd_works=no
22980 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22981 conftest.$ac_objext conftest.beam conftest.$ac_ext
22985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
22986 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
22987 case $gl_cv_func_fcntl_f_dupfd_works in
22988 *yes) ;;
22992 if test $ac_cv_func_fcntl = no; then
22993 HAVE_FCNTL=0
22994 else
22995 REPLACE_FCNTL=1
22999 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
23001 esac
23003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
23004 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
23005 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
23006 $as_echo_n "(cached) " >&6
23007 else
23008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23009 /* end confdefs.h. */
23011 #include <fcntl.h>
23012 #ifndef F_DUPFD_CLOEXEC
23013 choke me
23014 #endif
23017 main ()
23021 return 0;
23023 _ACEOF
23024 if ac_fn_c_try_compile "$LINENO"; then :
23025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23026 /* end confdefs.h. */
23028 #ifdef __linux__
23029 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
23030 it to support the semantics on older kernels that failed with EINVAL. */
23031 choke me
23032 #endif
23035 main ()
23039 return 0;
23041 _ACEOF
23042 if ac_fn_c_try_compile "$LINENO"; then :
23043 gl_cv_func_fcntl_f_dupfd_cloexec=yes
23044 else
23045 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
23047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23048 else
23049 gl_cv_func_fcntl_f_dupfd_cloexec=no
23051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
23054 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
23055 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
23059 if test $ac_cv_func_fcntl = no; then
23060 HAVE_FCNTL=0
23061 else
23062 REPLACE_FCNTL=1
23069 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
23078 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
23086 GNULIB_FCNTL=1
23103 if test $gl_cv_have_include_next = yes; then
23104 gl_cv_next_fcntl_h='<'fcntl.h'>'
23105 else
23106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
23107 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
23108 if test "${gl_cv_next_fcntl_h+set}" = set; then :
23109 $as_echo_n "(cached) " >&6
23110 else
23112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23113 /* end confdefs.h. */
23114 #include <fcntl.h>
23116 _ACEOF
23117 case "$host_os" in
23118 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23119 *) gl_absname_cpp="$ac_cpp" ;;
23120 esac
23122 case "$host_os" in
23123 mingw*)
23124 gl_dirsep_regex='[/\\]'
23127 gl_dirsep_regex='\/'
23129 esac
23130 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23132 gl_header_literal_regex=`echo 'fcntl.h' \
23133 | sed -e "$gl_make_literal_regex_sed"`
23134 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23135 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23136 s|^/[^/]|//&|
23140 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23141 sed -n "$gl_absolute_header_sed"`'"'
23145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
23146 $as_echo "$gl_cv_next_fcntl_h" >&6; }
23148 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
23150 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23151 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23152 gl_next_as_first_directive='<'fcntl.h'>'
23153 else
23154 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23155 gl_next_as_first_directive=$gl_cv_next_fcntl_h
23157 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
23173 LIB_FDATASYNC=
23176 if test $ac_cv_have_decl_fdatasync = no; then
23177 HAVE_DECL_FDATASYNC=0
23178 for ac_func in fdatasync
23179 do :
23180 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
23181 if test "x$ac_cv_func_fdatasync" = x""yes; then :
23182 cat >>confdefs.h <<_ACEOF
23183 #define HAVE_FDATASYNC 1
23184 _ACEOF
23187 done
23189 if test $ac_cv_func_fdatasync = no; then
23190 HAVE_FDATASYNC=0
23192 else
23193 gl_saved_libs=$LIBS
23194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
23195 $as_echo_n "checking for library containing fdatasync... " >&6; }
23196 if test "${ac_cv_search_fdatasync+set}" = set; then :
23197 $as_echo_n "(cached) " >&6
23198 else
23199 ac_func_search_save_LIBS=$LIBS
23200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23201 /* end confdefs.h. */
23203 /* Override any GCC internal prototype to avoid an error.
23204 Use char because int might match the return type of a GCC
23205 builtin and then its argument prototype would still apply. */
23206 #ifdef __cplusplus
23207 extern "C"
23208 #endif
23209 char fdatasync ();
23211 main ()
23213 return fdatasync ();
23215 return 0;
23217 _ACEOF
23218 for ac_lib in '' rt posix4; do
23219 if test -z "$ac_lib"; then
23220 ac_res="none required"
23221 else
23222 ac_res=-l$ac_lib
23223 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23225 if ac_fn_c_try_link "$LINENO"; then :
23226 ac_cv_search_fdatasync=$ac_res
23228 rm -f core conftest.err conftest.$ac_objext \
23229 conftest$ac_exeext
23230 if test "${ac_cv_search_fdatasync+set}" = set; then :
23231 break
23233 done
23234 if test "${ac_cv_search_fdatasync+set}" = set; then :
23236 else
23237 ac_cv_search_fdatasync=no
23239 rm conftest.$ac_ext
23240 LIBS=$ac_func_search_save_LIBS
23242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
23243 $as_echo "$ac_cv_search_fdatasync" >&6; }
23244 ac_res=$ac_cv_search_fdatasync
23245 if test "$ac_res" != no; then :
23246 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23247 test "$ac_cv_search_fdatasync" = "none required" ||
23248 LIB_FDATASYNC=$ac_cv_search_fdatasync
23251 LIBS=$gl_saved_libs
23254 if test $HAVE_FDATASYNC = 0; then
23263 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
23271 GNULIB_FDATASYNC=1
23282 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
23283 #include <dirent.h>
23286 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
23287 ac_have_decl=1
23288 else
23289 ac_have_decl=0
23292 cat >>confdefs.h <<_ACEOF
23293 #define HAVE_DECL_FDOPENDIR $ac_have_decl
23294 _ACEOF
23295 if test $ac_have_decl = 1; then :
23297 else
23298 HAVE_DECL_FDOPENDIR=0
23302 if test $ac_cv_func_fdopendir = no; then
23303 HAVE_FDOPENDIR=0
23304 else
23305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
23306 $as_echo_n "checking whether fdopendir works... " >&6; }
23307 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
23308 $as_echo_n "(cached) " >&6
23309 else
23310 if test "$cross_compiling" = yes; then :
23311 case "$host_os" in
23312 # Guess yes on glibc systems.
23313 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
23314 # If we don't know, assume the worst.
23315 *) gl_cv_func_fdopendir_works="guessing no" ;;
23316 esac
23318 else
23319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23320 /* end confdefs.h. */
23322 #include <dirent.h>
23323 #include <fcntl.h>
23324 #include <unistd.h>
23325 #if !HAVE_DECL_FDOPENDIR
23326 extern
23327 # ifdef __cplusplus
23329 # endif
23330 DIR *fdopendir (int);
23331 #endif
23334 main ()
23336 int result = 0;
23337 int fd = open ("conftest.c", O_RDONLY);
23338 if (fd < 0) result |= 1;
23339 if (fdopendir (fd)) result |= 2;
23340 if (close (fd)) result |= 4;
23341 return result;
23343 return 0;
23345 _ACEOF
23346 if ac_fn_c_try_run "$LINENO"; then :
23347 gl_cv_func_fdopendir_works=yes
23348 else
23349 gl_cv_func_fdopendir_works=no
23351 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23352 conftest.$ac_objext conftest.beam conftest.$ac_ext
23356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
23357 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
23358 case "$gl_cv_func_fdopendir_works" in
23359 *yes) ;;
23361 REPLACE_FDOPENDIR=1
23363 esac
23366 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
23375 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
23383 GNULIB_FDOPENDIR=1
23391 cat >>confdefs.h <<_ACEOF
23392 #define GNULIB_FDOPENDIR 1
23393 _ACEOF
23402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpending" >&5
23403 $as_echo_n "checking for __fpending... " >&6; }
23404 if test "${gl_cv_func___fpending+set}" = set; then :
23405 $as_echo_n "(cached) " >&6
23406 else
23408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23409 /* end confdefs.h. */
23410 #include <stdio.h>
23411 #if HAVE_STDIO_EXT_H
23412 # include <stdio_ext.h>
23413 #endif
23416 main ()
23418 return ! __fpending (stdin);
23420 return 0;
23422 _ACEOF
23423 if ac_fn_c_try_link "$LINENO"; then :
23424 gl_cv_func___fpending=yes
23425 else
23426 gl_cv_func___fpending=no
23428 rm -f core conftest.err conftest.$ac_objext \
23429 conftest$ac_exeext conftest.$ac_ext
23432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func___fpending" >&5
23433 $as_echo "$gl_cv_func___fpending" >&6; }
23435 if test $gl_cv_func___fpending = no; then
23444 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
23447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
23448 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
23449 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
23450 $as_echo_n "(cached) " >&6
23451 else
23453 for ac_expr in \
23455 '# glibc2' \
23456 'fp->_IO_write_ptr - fp->_IO_write_base' \
23458 '# traditional Unix' \
23459 'fp->_ptr - fp->_base' \
23461 '# BSD' \
23462 'fp->_p - fp->_bf._base' \
23464 '# SCO, Unixware' \
23465 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
23467 '# QNX' \
23468 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
23470 '# old glibc?' \
23471 'fp->__bufp - fp->__buffer' \
23473 '# old glibc iostream?' \
23474 'fp->_pptr - fp->_pbase' \
23476 '# emx+gcc' \
23477 'fp->_ptr - fp->_buffer' \
23479 '# Minix' \
23480 'fp->_ptr - fp->_buf' \
23482 '# Plan9' \
23483 'fp->wp - fp->buf' \
23485 '# VMS' \
23486 '(*fp)->_ptr - (*fp)->_base' \
23488 '# e.g., DGUX R4.11; the info is not available' \
23490 ; do
23492 # Skip each embedded comment.
23493 case "$ac_expr" in '#'*) continue;; esac
23495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23496 /* end confdefs.h. */
23497 #include <stdio.h>
23499 main ()
23501 FILE *fp = stdin; (void) ($ac_expr);
23503 return 0;
23505 _ACEOF
23506 if ac_fn_c_try_compile "$LINENO"; then :
23507 fp_done=yes
23510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23511 test "$fp_done" = yes && break
23512 done
23514 ac_cv_sys_pending_output_n_bytes=$ac_expr
23518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
23519 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
23521 cat >>confdefs.h <<_ACEOF
23522 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
23523 _ACEOF
23533 if test $ac_cv_func_fstatat = no; then
23534 HAVE_FSTATAT=0
23535 else
23536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
23537 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
23538 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
23539 $as_echo_n "(cached) " >&6
23540 else
23541 if test "$cross_compiling" = yes; then :
23542 case "$host_os" in
23543 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
23544 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
23545 esac
23547 else
23548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23549 /* end confdefs.h. */
23551 #include <fcntl.h>
23552 #include <sys/stat.h>
23554 main (void)
23556 struct stat a;
23557 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23560 _ACEOF
23561 if ac_fn_c_try_run "$LINENO"; then :
23562 gl_cv_func_fstatat_zero_flag=yes
23563 else
23564 gl_cv_func_fstatat_zero_flag=no
23566 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23567 conftest.$ac_objext conftest.beam conftest.$ac_ext
23572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23573 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23575 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23576 *yes+*yes) ;;
23577 *) REPLACE_FSTATAT=1
23578 case $gl_cv_func_fstatat_zero_flag in
23579 *yes)
23581 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23584 esac
23586 esac
23589 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23598 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23606 GNULIB_FSTATAT=1
23615 if test $ac_cv_func_fsync = no; then
23616 HAVE_FSYNC=0
23619 if test $HAVE_FSYNC = 0; then
23628 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23637 GNULIB_FSYNC=1
23645 # Persuade glibc <stdlib.h> to declare getloadavg().
23648 gl_save_LIBS=$LIBS
23650 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23651 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23652 HAVE_GETLOADAVG=1
23653 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23654 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23656 else
23657 gl_func_getloadavg_done=no
23659 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23660 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23661 # to get the right answer into the cache.
23662 # For kstat on solaris, we need to test for libelf and libkvm to force the
23663 # definition of SVR4 below.
23664 if test $gl_func_getloadavg_done = no; then
23665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23666 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23667 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23668 $as_echo_n "(cached) " >&6
23669 else
23670 ac_check_lib_save_LIBS=$LIBS
23671 LIBS="-lelf $LIBS"
23672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23673 /* end confdefs.h. */
23675 /* Override any GCC internal prototype to avoid an error.
23676 Use char because int might match the return type of a GCC
23677 builtin and then its argument prototype would still apply. */
23678 #ifdef __cplusplus
23679 extern "C"
23680 #endif
23681 char elf_begin ();
23683 main ()
23685 return elf_begin ();
23687 return 0;
23689 _ACEOF
23690 if ac_fn_c_try_link "$LINENO"; then :
23691 ac_cv_lib_elf_elf_begin=yes
23692 else
23693 ac_cv_lib_elf_elf_begin=no
23695 rm -f core conftest.err conftest.$ac_objext \
23696 conftest$ac_exeext conftest.$ac_ext
23697 LIBS=$ac_check_lib_save_LIBS
23699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23700 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23701 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23702 LIBS="-lelf $LIBS"
23705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23706 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23707 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23708 $as_echo_n "(cached) " >&6
23709 else
23710 ac_check_lib_save_LIBS=$LIBS
23711 LIBS="-lkvm $LIBS"
23712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23713 /* end confdefs.h. */
23715 /* Override any GCC internal prototype to avoid an error.
23716 Use char because int might match the return type of a GCC
23717 builtin and then its argument prototype would still apply. */
23718 #ifdef __cplusplus
23719 extern "C"
23720 #endif
23721 char kvm_open ();
23723 main ()
23725 return kvm_open ();
23727 return 0;
23729 _ACEOF
23730 if ac_fn_c_try_link "$LINENO"; then :
23731 ac_cv_lib_kvm_kvm_open=yes
23732 else
23733 ac_cv_lib_kvm_kvm_open=no
23735 rm -f core conftest.err conftest.$ac_objext \
23736 conftest$ac_exeext conftest.$ac_ext
23737 LIBS=$ac_check_lib_save_LIBS
23739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23740 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23741 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23742 LIBS="-lkvm $LIBS"
23745 # Check for the 4.4BSD definition of getloadavg.
23746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23747 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23748 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23749 $as_echo_n "(cached) " >&6
23750 else
23751 ac_check_lib_save_LIBS=$LIBS
23752 LIBS="-lutil $LIBS"
23753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23754 /* end confdefs.h. */
23756 /* Override any GCC internal prototype to avoid an error.
23757 Use char because int might match the return type of a GCC
23758 builtin and then its argument prototype would still apply. */
23759 #ifdef __cplusplus
23760 extern "C"
23761 #endif
23762 char getloadavg ();
23764 main ()
23766 return getloadavg ();
23768 return 0;
23770 _ACEOF
23771 if ac_fn_c_try_link "$LINENO"; then :
23772 ac_cv_lib_util_getloadavg=yes
23773 else
23774 ac_cv_lib_util_getloadavg=no
23776 rm -f core conftest.err conftest.$ac_objext \
23777 conftest$ac_exeext conftest.$ac_ext
23778 LIBS=$ac_check_lib_save_LIBS
23780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23781 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23782 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23783 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23788 if test $gl_func_getloadavg_done = no; then
23789 # There is a commonly available library for RS/6000 AIX.
23790 # Since it is not a standard part of AIX, it might be installed locally.
23791 gl_getloadavg_LIBS=$LIBS
23792 LIBS="-L/usr/local/lib $LIBS"
23793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23794 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23795 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23796 $as_echo_n "(cached) " >&6
23797 else
23798 ac_check_lib_save_LIBS=$LIBS
23799 LIBS="-lgetloadavg $LIBS"
23800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23801 /* end confdefs.h. */
23803 /* Override any GCC internal prototype to avoid an error.
23804 Use char because int might match the return type of a GCC
23805 builtin and then its argument prototype would still apply. */
23806 #ifdef __cplusplus
23807 extern "C"
23808 #endif
23809 char getloadavg ();
23811 main ()
23813 return getloadavg ();
23815 return 0;
23817 _ACEOF
23818 if ac_fn_c_try_link "$LINENO"; then :
23819 ac_cv_lib_getloadavg_getloadavg=yes
23820 else
23821 ac_cv_lib_getloadavg_getloadavg=no
23823 rm -f core conftest.err conftest.$ac_objext \
23824 conftest$ac_exeext conftest.$ac_ext
23825 LIBS=$ac_check_lib_save_LIBS
23827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23828 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23829 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23830 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23831 else
23832 LIBS=$gl_getloadavg_LIBS
23837 # Set up the replacement function if necessary.
23838 if test $gl_func_getloadavg_done = no; then
23839 HAVE_GETLOADAVG=0
23841 # Solaris has libkstat which does not require root.
23842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23843 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23844 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23845 $as_echo_n "(cached) " >&6
23846 else
23847 ac_check_lib_save_LIBS=$LIBS
23848 LIBS="-lkstat $LIBS"
23849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23850 /* end confdefs.h. */
23852 /* Override any GCC internal prototype to avoid an error.
23853 Use char because int might match the return type of a GCC
23854 builtin and then its argument prototype would still apply. */
23855 #ifdef __cplusplus
23856 extern "C"
23857 #endif
23858 char kstat_open ();
23860 main ()
23862 return kstat_open ();
23864 return 0;
23866 _ACEOF
23867 if ac_fn_c_try_link "$LINENO"; then :
23868 ac_cv_lib_kstat_kstat_open=yes
23869 else
23870 ac_cv_lib_kstat_kstat_open=no
23872 rm -f core conftest.err conftest.$ac_objext \
23873 conftest$ac_exeext conftest.$ac_ext
23874 LIBS=$ac_check_lib_save_LIBS
23876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23877 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23878 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23879 cat >>confdefs.h <<_ACEOF
23880 #define HAVE_LIBKSTAT 1
23881 _ACEOF
23883 LIBS="-lkstat $LIBS"
23887 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23889 # AIX has libperfstat which does not require root
23890 if test $gl_func_getloadavg_done = no; then
23891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23892 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23893 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23894 $as_echo_n "(cached) " >&6
23895 else
23896 ac_check_lib_save_LIBS=$LIBS
23897 LIBS="-lperfstat $LIBS"
23898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23899 /* end confdefs.h. */
23901 /* Override any GCC internal prototype to avoid an error.
23902 Use char because int might match the return type of a GCC
23903 builtin and then its argument prototype would still apply. */
23904 #ifdef __cplusplus
23905 extern "C"
23906 #endif
23907 char perfstat_cpu_total ();
23909 main ()
23911 return perfstat_cpu_total ();
23913 return 0;
23915 _ACEOF
23916 if ac_fn_c_try_link "$LINENO"; then :
23917 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23918 else
23919 ac_cv_lib_perfstat_perfstat_cpu_total=no
23921 rm -f core conftest.err conftest.$ac_objext \
23922 conftest$ac_exeext conftest.$ac_ext
23923 LIBS=$ac_check_lib_save_LIBS
23925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
23926 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
23927 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
23928 cat >>confdefs.h <<_ACEOF
23929 #define HAVE_LIBPERFSTAT 1
23930 _ACEOF
23932 LIBS="-lperfstat $LIBS"
23936 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
23939 if test $gl_func_getloadavg_done = no; then
23940 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
23941 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
23942 gl_func_getloadavg_done=yes
23944 $as_echo "#define DGUX 1" >>confdefs.h
23946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
23947 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
23948 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
23949 $as_echo_n "(cached) " >&6
23950 else
23951 ac_check_lib_save_LIBS=$LIBS
23952 LIBS="-ldgc $LIBS"
23953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23954 /* end confdefs.h. */
23956 /* Override any GCC internal prototype to avoid an error.
23957 Use char because int might match the return type of a GCC
23958 builtin and then its argument prototype would still apply. */
23959 #ifdef __cplusplus
23960 extern "C"
23961 #endif
23962 char dg_sys_info ();
23964 main ()
23966 return dg_sys_info ();
23968 return 0;
23970 _ACEOF
23971 if ac_fn_c_try_link "$LINENO"; then :
23972 ac_cv_lib_dgc_dg_sys_info=yes
23973 else
23974 ac_cv_lib_dgc_dg_sys_info=no
23976 rm -f core conftest.err conftest.$ac_objext \
23977 conftest$ac_exeext conftest.$ac_ext
23978 LIBS=$ac_check_lib_save_LIBS
23980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
23981 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
23982 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
23983 cat >>confdefs.h <<_ACEOF
23984 #define HAVE_LIBDGC 1
23985 _ACEOF
23987 LIBS="-ldgc $LIBS"
23999 if test "x$gl_save_LIBS" = x; then
24000 GETLOADAVG_LIBS=$LIBS
24001 else
24002 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
24004 LIBS=$gl_save_LIBS
24007 # Test whether the system declares getloadavg. Solaris has the function
24008 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
24009 for ac_header in sys/loadavg.h
24010 do :
24011 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
24012 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
24013 cat >>confdefs.h <<_ACEOF
24014 #define HAVE_SYS_LOADAVG_H 1
24015 _ACEOF
24019 done
24021 if test $ac_cv_header_sys_loadavg_h = yes; then
24022 HAVE_SYS_LOADAVG_H=1
24023 else
24024 HAVE_SYS_LOADAVG_H=0
24026 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
24027 # include <sys/loadavg.h>
24028 #endif
24029 #include <stdlib.h>
24031 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
24033 else
24034 HAVE_DECL_GETLOADAVG=0
24038 if test $HAVE_GETLOADAVG = 0; then
24047 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
24050 # Figure out what our getloadavg.c needs.
24054 # On HPUX9, an unprivileged user can get load averages this way.
24055 if test $gl_func_getloadavg_done = no; then
24056 for ac_func in pstat_getdynamic
24057 do :
24058 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
24059 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
24060 cat >>confdefs.h <<_ACEOF
24061 #define HAVE_PSTAT_GETDYNAMIC 1
24062 _ACEOF
24063 gl_func_getloadavg_done=yes
24065 done
24069 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
24070 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
24071 # Irix 4.0.5F has the header but not the library.
24072 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
24073 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
24074 gl_func_getloadavg_done=yes
24076 $as_echo "#define SVR4 1" >>confdefs.h
24080 if test $gl_func_getloadavg_done = no; then
24081 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
24082 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
24083 gl_func_getloadavg_done=yes
24085 $as_echo "#define UMAX 1" >>confdefs.h
24088 $as_echo "#define UMAX4_3 1" >>confdefs.h
24095 if test $gl_func_getloadavg_done = no; then
24096 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
24097 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
24098 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
24105 if test $gl_func_getloadavg_done = no; then
24106 for ac_header in mach/mach.h
24107 do :
24108 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
24109 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
24110 cat >>confdefs.h <<_ACEOF
24111 #define HAVE_MACH_MACH_H 1
24112 _ACEOF
24116 done
24120 for ac_header in nlist.h
24121 do :
24122 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
24123 if test "x$ac_cv_header_nlist_h" = x""yes; then :
24124 cat >>confdefs.h <<_ACEOF
24125 #define HAVE_NLIST_H 1
24126 _ACEOF
24127 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
24129 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
24131 cat >>confdefs.h <<_ACEOF
24132 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
24133 _ACEOF
24138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24139 /* end confdefs.h. */
24140 #include <nlist.h>
24142 main ()
24144 struct nlist x;
24145 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
24146 x.n_un.n_name = "";
24147 #else
24148 x.n_name = "";
24149 #endif
24151 return 0;
24153 _ACEOF
24154 if ac_fn_c_try_link "$LINENO"; then :
24156 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
24159 rm -f core conftest.err conftest.$ac_objext \
24160 conftest$ac_exeext conftest.$ac_ext
24164 done
24172 GNULIB_GETLOADAVG=1
24183 if test $REPLACE_GETOPT = 1; then
24192 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24202 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24207 GNULIB_GL_UNISTD_H_GETOPT=1
24216 REPLACE_GETOPT=0
24217 if test -n "$gl_replace_getopt"; then
24218 REPLACE_GETOPT=1
24221 if test $REPLACE_GETOPT = 1; then
24223 GETOPT_H=getopt.h
24225 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
24231 if test $REPLACE_GETOPT = 1; then
24240 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24250 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24255 GNULIB_GL_UNISTD_H_GETOPT=1
24269 gl_gettimeofday_timezone=void
24270 if test $ac_cv_func_gettimeofday != yes; then
24271 HAVE_GETTIMEOFDAY=0
24272 else
24276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
24277 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
24278 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
24279 $as_echo_n "(cached) " >&6
24280 else
24281 if test "$cross_compiling" = yes; then :
24282 # When cross-compiling:
24283 case "$host_os" in
24284 # Guess all is fine on glibc systems.
24285 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
24286 # If we don't know, assume the worst.
24287 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
24288 esac
24290 else
24291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24292 /* end confdefs.h. */
24293 #include <string.h>
24294 #include <sys/time.h>
24295 #include <time.h>
24296 #include <stdlib.h>
24299 main ()
24302 time_t t = 0;
24303 struct tm *lt;
24304 struct tm saved_lt;
24305 struct timeval tv;
24306 lt = localtime (&t);
24307 saved_lt = *lt;
24308 gettimeofday (&tv, NULL);
24309 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
24312 return 0;
24314 _ACEOF
24315 if ac_fn_c_try_run "$LINENO"; then :
24316 gl_cv_func_gettimeofday_clobber=no
24317 else
24318 gl_cv_func_gettimeofday_clobber=yes
24320 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24321 conftest.$ac_objext conftest.beam conftest.$ac_ext
24325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
24326 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
24328 case "$gl_cv_func_gettimeofday_clobber" in
24329 *yes)
24330 REPLACE_GETTIMEOFDAY=1
24333 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
24336 $as_echo "#define localtime rpl_localtime" >>confdefs.h
24340 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
24343 esac
24345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
24346 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
24347 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
24348 $as_echo_n "(cached) " >&6
24349 else
24350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24351 /* end confdefs.h. */
24352 #include <sys/time.h>
24353 struct timeval c;
24354 int gettimeofday (struct timeval *restrict, void *restrict);
24357 main ()
24359 /* glibc uses struct timezone * rather than the POSIX void *
24360 if _GNU_SOURCE is defined. However, since the only portable
24361 use of gettimeofday uses NULL as the second parameter, and
24362 since the glibc definition is actually more typesafe, it is
24363 not worth wrapping this to get a compliant signature. */
24364 int (*f) (struct timeval *restrict, void *restrict)
24365 = gettimeofday;
24366 int x = f (&c, 0);
24367 return !(x | c.tv_sec | c.tv_usec);
24370 return 0;
24372 _ACEOF
24373 if ac_fn_c_try_compile "$LINENO"; then :
24374 gl_cv_func_gettimeofday_posix_signature=yes
24375 else
24376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24377 /* end confdefs.h. */
24378 #include <sys/time.h>
24379 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
24382 main ()
24386 return 0;
24388 _ACEOF
24389 if ac_fn_c_try_compile "$LINENO"; then :
24390 gl_cv_func_gettimeofday_posix_signature=almost
24391 else
24392 gl_cv_func_gettimeofday_posix_signature=no
24394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
24399 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
24400 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
24401 gl_gettimeofday_timezone='struct timezone'
24402 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
24403 REPLACE_GETTIMEOFDAY=1
24405 if test $REPLACE_STRUCT_TIMEVAL = 1; then
24406 REPLACE_GETTIMEOFDAY=1
24411 cat >>confdefs.h <<_ACEOF
24412 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
24413 _ACEOF
24416 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
24425 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
24428 for ac_header in sys/timeb.h
24429 do :
24430 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
24431 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
24432 cat >>confdefs.h <<_ACEOF
24433 #define HAVE_SYS_TIMEB_H 1
24434 _ACEOF
24438 done
24440 for ac_func in _ftime
24441 do :
24442 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
24443 if test "x$ac_cv_func__ftime" = x""yes; then :
24444 cat >>confdefs.h <<_ACEOF
24445 #define HAVE__FTIME 1
24446 _ACEOF
24449 done
24458 GNULIB_GETTIMEOFDAY=1
24469 if test $ac_cv_func_lstat = yes; then
24471 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
24472 *no)
24473 REPLACE_LSTAT=1
24475 esac
24476 else
24477 HAVE_LSTAT=0
24480 if test $REPLACE_LSTAT = 1; then
24489 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
24498 GNULIB_LSTAT=1
24509 if test $ac_cv_have_decl_memrchr = no; then
24510 HAVE_DECL_MEMRCHR=0
24513 for ac_func in memrchr
24514 do :
24515 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
24516 if test "x$ac_cv_func_memrchr" = x""yes; then :
24517 cat >>confdefs.h <<_ACEOF
24518 #define HAVE_MEMRCHR 1
24519 _ACEOF
24522 done
24525 if test $ac_cv_func_memrchr = no; then
24534 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24543 GNULIB_MEMRCHR=1
24555 if test $ac_cv_func_mkostemp != yes; then
24556 HAVE_MKOSTEMP=0
24559 if test $HAVE_MKOSTEMP = 0; then
24568 gl_LIBOBJS="$gl_LIBOBJS mkostemp.$ac_objext"
24575 cat >>confdefs.h <<_ACEOF
24576 #define GNULIB_MKOSTEMP 1
24577 _ACEOF
24585 GNULIB_MKOSTEMP=1
24597 if test $APPLE_UNIVERSAL_BUILD = 1; then
24598 # A universal build on Apple Mac OS X platforms.
24599 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24600 # But we need a configuration result that is valid in both modes.
24601 gl_cv_func_working_mktime=no
24603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24604 $as_echo_n "checking for working mktime... " >&6; }
24605 if test "${gl_cv_func_working_mktime+set}" = set; then :
24606 $as_echo_n "(cached) " >&6
24607 else
24608 if test "$cross_compiling" = yes; then :
24609 gl_cv_func_working_mktime=no
24610 else
24611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24612 /* end confdefs.h. */
24613 /* Test program from Paul Eggert and Tony Leneis. */
24614 #include <limits.h>
24615 #include <stdlib.h>
24616 #include <time.h>
24618 #ifdef HAVE_UNISTD_H
24619 # include <unistd.h>
24620 #endif
24622 #if HAVE_DECL_ALARM
24623 # include <signal.h>
24624 #endif
24626 /* Work around redefinition to rpl_putenv by other config tests. */
24627 #undef putenv
24629 static time_t time_t_max;
24630 static time_t time_t_min;
24632 /* Values we'll use to set the TZ environment variable. */
24633 static char *tz_strings[] = {
24634 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24635 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24637 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24639 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24640 Based on a problem report from Andreas Jaeger. */
24641 static int
24642 spring_forward_gap ()
24644 /* glibc (up to about 1998-10-07) failed this test. */
24645 struct tm tm;
24647 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24648 instead of "TZ=America/Vancouver" in order to detect the bug even
24649 on systems that don't support the Olson extension, or don't have the
24650 full zoneinfo tables installed. */
24651 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24653 tm.tm_year = 98;
24654 tm.tm_mon = 3;
24655 tm.tm_mday = 5;
24656 tm.tm_hour = 2;
24657 tm.tm_min = 0;
24658 tm.tm_sec = 0;
24659 tm.tm_isdst = -1;
24660 return mktime (&tm) != (time_t) -1;
24663 static int
24664 mktime_test1 (time_t now)
24666 struct tm *lt;
24667 return ! (lt = localtime (&now)) || mktime (lt) == now;
24670 static int
24671 mktime_test (time_t now)
24673 return (mktime_test1 (now)
24674 && mktime_test1 ((time_t) (time_t_max - now))
24675 && mktime_test1 ((time_t) (time_t_min + now)));
24678 static int
24679 irix_6_4_bug ()
24681 /* Based on code from Ariel Faigon. */
24682 struct tm tm;
24683 tm.tm_year = 96;
24684 tm.tm_mon = 3;
24685 tm.tm_mday = 0;
24686 tm.tm_hour = 0;
24687 tm.tm_min = 0;
24688 tm.tm_sec = 0;
24689 tm.tm_isdst = -1;
24690 mktime (&tm);
24691 return tm.tm_mon == 2 && tm.tm_mday == 31;
24694 static int
24695 bigtime_test (int j)
24697 struct tm tm;
24698 time_t now;
24699 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24700 now = mktime (&tm);
24701 if (now != (time_t) -1)
24703 struct tm *lt = localtime (&now);
24704 if (! (lt
24705 && lt->tm_year == tm.tm_year
24706 && lt->tm_mon == tm.tm_mon
24707 && lt->tm_mday == tm.tm_mday
24708 && lt->tm_hour == tm.tm_hour
24709 && lt->tm_min == tm.tm_min
24710 && lt->tm_sec == tm.tm_sec
24711 && lt->tm_yday == tm.tm_yday
24712 && lt->tm_wday == tm.tm_wday
24713 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24714 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24715 return 0;
24717 return 1;
24720 static int
24721 year_2050_test ()
24723 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24724 ignoring leap seconds. */
24725 unsigned long int answer = 2527315200UL;
24727 struct tm tm;
24728 time_t t;
24729 tm.tm_year = 2050 - 1900;
24730 tm.tm_mon = 2 - 1;
24731 tm.tm_mday = 1;
24732 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24733 tm.tm_isdst = -1;
24735 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24736 instead of "TZ=America/Vancouver" in order to detect the bug even
24737 on systems that don't support the Olson extension, or don't have the
24738 full zoneinfo tables installed. */
24739 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24741 t = mktime (&tm);
24743 /* Check that the result is either a failure, or close enough
24744 to the correct answer that we can assume the discrepancy is
24745 due to leap seconds. */
24746 return (t == (time_t) -1
24747 || (0 < t && answer - 120 <= t && t <= answer + 120));
24751 main ()
24753 int result = 0;
24754 time_t t, delta;
24755 int i, j;
24756 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24757 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24759 #if HAVE_DECL_ALARM
24760 /* This test makes some buggy mktime implementations loop.
24761 Give up after 60 seconds; a mktime slower than that
24762 isn't worth using anyway. */
24763 signal (SIGALRM, SIG_DFL);
24764 alarm (60);
24765 #endif
24767 time_t_max = (! time_t_signed
24768 ? (time_t) -1
24769 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24770 * 2 + 1));
24771 time_t_min = (! time_t_signed
24772 ? (time_t) 0
24773 : time_t_signed_magnitude
24774 ? ~ (time_t) 0
24775 : ~ time_t_max);
24777 delta = time_t_max / 997; /* a suitable prime number */
24778 for (i = 0; i < N_STRINGS; i++)
24780 if (tz_strings[i])
24781 putenv (tz_strings[i]);
24783 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24784 if (! mktime_test (t))
24785 result |= 1;
24786 if ((result & 2) == 0
24787 && ! (mktime_test ((time_t) 1)
24788 && mktime_test ((time_t) (60 * 60))
24789 && mktime_test ((time_t) (60 * 60 * 24))))
24790 result |= 2;
24792 for (j = 1; (result & 4) == 0; j <<= 1)
24794 if (! bigtime_test (j))
24795 result |= 4;
24796 if (INT_MAX / 2 < j)
24797 break;
24799 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24800 result |= 8;
24802 if (! irix_6_4_bug ())
24803 result |= 16;
24804 if (! spring_forward_gap ())
24805 result |= 32;
24806 if (! year_2050_test ())
24807 result |= 64;
24808 return result;
24810 _ACEOF
24811 if ac_fn_c_try_run "$LINENO"; then :
24812 gl_cv_func_working_mktime=yes
24813 else
24814 gl_cv_func_working_mktime=no
24816 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24817 conftest.$ac_objext conftest.beam conftest.$ac_ext
24822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24823 $as_echo "$gl_cv_func_working_mktime" >&6; }
24825 if test $gl_cv_func_working_mktime = no; then
24826 REPLACE_MKTIME=1
24827 else
24828 REPLACE_MKTIME=0
24831 if test $REPLACE_MKTIME = 1; then
24840 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24849 GNULIB_MKTIME=1
24862 if test $ac_cv_func_pipe2 != yes; then
24863 HAVE_PIPE2=0
24871 GNULIB_PIPE2=1
24882 if test $ac_cv_func_pselect = yes; then
24883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24884 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24885 if test "${gl_cv_sig_pselect+set}" = set; then :
24886 $as_echo_n "(cached) " >&6
24887 else
24888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24889 /* end confdefs.h. */
24890 #include <sys/select.h>
24893 main ()
24895 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24896 struct timespec const *restrict,
24897 sigset_t const *restrict) = pselect;
24898 return !p;
24900 return 0;
24902 _ACEOF
24903 if ac_fn_c_try_link "$LINENO"; then :
24904 gl_cv_sig_pselect=yes
24905 else
24906 gl_cv_sig_pselect=no
24908 rm -f core conftest.err conftest.$ac_objext \
24909 conftest$ac_exeext conftest.$ac_ext
24911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24912 $as_echo "$gl_cv_sig_pselect" >&6; }
24914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24915 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24916 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24917 $as_echo_n "(cached) " >&6
24918 else
24920 if test "$cross_compiling" = yes; then :
24922 case "$host_os" in
24923 # Guess yes on glibc systems.
24924 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24925 # If we don't know, assume the worst.
24926 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
24927 esac
24929 else
24930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24931 /* end confdefs.h. */
24933 #include <sys/types.h>
24934 #include <sys/time.h>
24935 #if HAVE_SYS_SELECT_H
24936 # include <sys/select.h>
24937 #endif
24938 #include <unistd.h>
24939 #include <errno.h>
24942 main ()
24945 fd_set set;
24946 dup2(0, 16);
24947 FD_ZERO(&set);
24948 FD_SET(16, &set);
24949 close(16);
24950 struct timespec timeout;
24951 timeout.tv_sec = 0;
24952 timeout.tv_nsec = 5000;
24953 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
24956 return 0;
24958 _ACEOF
24959 if ac_fn_c_try_run "$LINENO"; then :
24960 gl_cv_func_pselect_detects_ebadf=yes
24961 else
24962 gl_cv_func_pselect_detects_ebadf=no
24964 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24965 conftest.$ac_objext conftest.beam conftest.$ac_ext
24970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
24971 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
24972 case $gl_cv_func_pselect_detects_ebadf in
24973 *yes) ;;
24974 *) REPLACE_PSELECT=1 ;;
24975 esac
24978 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
24979 REPLACE_PSELECT=1
24982 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
24991 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
24999 GNULIB_PSELECT=1
25009 LIB_PTHREAD_SIGMASK=
25014 if test "$gl_threads_api" = posix; then
25015 if test $ac_cv_func_pthread_sigmask = yes; then
25017 else
25018 if test -n "$LIBMULTITHREAD"; then
25019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
25020 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
25021 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
25022 $as_echo_n "(cached) " >&6
25023 else
25024 gl_save_LIBS="$LIBS"
25025 LIBS="$LIBS $LIBMULTITHREAD"
25026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25027 /* end confdefs.h. */
25028 #include <pthread.h>
25029 #include <signal.h>
25032 main ()
25034 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
25036 return 0;
25039 _ACEOF
25040 if ac_fn_c_try_link "$LINENO"; then :
25041 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
25042 else
25043 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
25045 rm -f core conftest.err conftest.$ac_objext \
25046 conftest$ac_exeext conftest.$ac_ext
25047 LIBS="$gl_save_LIBS"
25050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
25051 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
25052 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
25053 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
25054 else
25055 HAVE_PTHREAD_SIGMASK=0
25057 else
25058 HAVE_PTHREAD_SIGMASK=0
25061 else
25062 if test $ac_cv_func_pthread_sigmask = yes; then
25063 REPLACE_PTHREAD_SIGMASK=1
25064 else
25065 HAVE_PTHREAD_SIGMASK=0
25072 if test $HAVE_PTHREAD_SIGMASK = 1; then
25075 if test -z "$LIB_PTHREAD_SIGMASK"; then
25076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
25077 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
25078 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
25079 $as_echo_n "(cached) " >&6
25080 else
25082 if test "$cross_compiling" = yes; then :
25084 case "$host_os" in
25085 freebsd* | hpux* | solaris | solaris2.[2-9]*)
25086 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
25088 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
25089 esac
25091 else
25092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25093 /* end confdefs.h. */
25095 #include <pthread.h>
25096 #include <signal.h>
25097 #include <stddef.h>
25098 int main ()
25100 sigset_t set;
25101 sigemptyset (&set);
25102 return pthread_sigmask (1729, &set, NULL) != 0;
25104 _ACEOF
25105 if ac_fn_c_try_run "$LINENO"; then :
25106 gl_cv_func_pthread_sigmask_in_libc_works=no
25107 else
25108 gl_cv_func_pthread_sigmask_in_libc_works=yes
25110 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25111 conftest.$ac_objext conftest.beam conftest.$ac_ext
25116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
25117 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
25118 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
25119 *no)
25120 REPLACE_PTHREAD_SIGMASK=1
25122 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
25125 esac
25128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
25129 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
25130 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
25131 $as_echo_n "(cached) " >&6
25132 else
25134 gl_save_LIBS="$LIBS"
25135 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
25136 if test "$cross_compiling" = yes; then :
25137 case "$host_os" in
25138 cygwin*)
25139 gl_cv_func_pthread_sigmask_return_works="guessing no";;
25141 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
25142 esac
25144 else
25145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25146 /* end confdefs.h. */
25148 #include <pthread.h>
25149 #include <signal.h>
25150 #include <stddef.h>
25151 int main ()
25153 sigset_t set;
25154 sigemptyset (&set);
25155 if (pthread_sigmask (1729, &set, NULL) == -1)
25156 return 1;
25157 return 0;
25159 _ACEOF
25160 if ac_fn_c_try_run "$LINENO"; then :
25161 gl_cv_func_pthread_sigmask_return_works=yes
25162 else
25163 gl_cv_func_pthread_sigmask_return_works=no
25165 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25166 conftest.$ac_objext conftest.beam conftest.$ac_ext
25169 LIBS="$gl_save_LIBS"
25172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
25173 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
25174 case "$gl_cv_func_pthread_sigmask_return_works" in
25175 *no)
25176 REPLACE_PTHREAD_SIGMASK=1
25178 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
25181 esac
25183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
25184 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
25185 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
25186 $as_echo_n "(cached) " >&6
25187 else
25189 case "$host_os" in
25190 irix*)
25191 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
25193 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
25194 esac
25195 gl_save_LIBS="$LIBS"
25196 LIBS="$LIBS $LIBMULTITHREAD"
25197 if test "$cross_compiling" = yes; then :
25199 else
25200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25201 /* end confdefs.h. */
25203 #include <pthread.h>
25204 #include <signal.h>
25205 #include <stdio.h>
25206 #include <stdlib.h>
25207 #include <unistd.h>
25208 static volatile int sigint_occurred;
25209 static void
25210 sigint_handler (int sig)
25212 sigint_occurred++;
25214 int main ()
25216 sigset_t set;
25217 int pid = getpid ();
25218 char command[80];
25219 signal (SIGINT, sigint_handler);
25220 sigemptyset (&set);
25221 sigaddset (&set, SIGINT);
25222 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
25223 return 1;
25224 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
25225 if (!(system (command) == 0))
25226 return 2;
25227 sleep (2);
25228 if (!(sigint_occurred == 0))
25229 return 3;
25230 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
25231 return 4;
25232 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
25233 return 5;
25234 return 0;
25236 _ACEOF
25237 if ac_fn_c_try_run "$LINENO"; then :
25239 else
25240 gl_cv_func_pthread_sigmask_unblock_works=no
25242 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25243 conftest.$ac_objext conftest.beam conftest.$ac_ext
25246 LIBS="$gl_save_LIBS"
25249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
25250 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
25251 case "$gl_cv_func_pthread_sigmask_unblock_works" in
25252 *no)
25253 REPLACE_PTHREAD_SIGMASK=1
25255 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
25258 esac
25261 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
25270 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
25273 if test $HAVE_PTHREAD_SIGMASK = 1; then
25275 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
25285 GNULIB_PTHREAD_SIGMASK=1
25293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
25294 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
25295 if test "${gl_cv_func_svid_putenv+set}" = set; then :
25296 $as_echo_n "(cached) " >&6
25297 else
25298 if test "$cross_compiling" = yes; then :
25299 case "$host_os" in
25300 # Guess yes on glibc systems.
25301 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
25302 # If we don't know, assume the worst.
25303 *) gl_cv_func_svid_putenv="guessing no" ;;
25304 esac
25306 else
25307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25308 /* end confdefs.h. */
25309 $ac_includes_default
25311 main ()
25314 /* Put it in env. */
25315 if (putenv ("CONFTEST_putenv=val"))
25316 return 1;
25318 /* Try to remove it. */
25319 if (putenv ("CONFTEST_putenv"))
25320 return 2;
25322 /* Make sure it was deleted. */
25323 if (getenv ("CONFTEST_putenv") != 0)
25324 return 3;
25326 return 0;
25329 return 0;
25331 _ACEOF
25332 if ac_fn_c_try_run "$LINENO"; then :
25333 gl_cv_func_svid_putenv=yes
25334 else
25335 gl_cv_func_svid_putenv=no
25337 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25338 conftest.$ac_objext conftest.beam conftest.$ac_ext
25343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
25344 $as_echo "$gl_cv_func_svid_putenv" >&6; }
25345 case "$gl_cv_func_svid_putenv" in
25346 *yes) ;;
25348 REPLACE_PUTENV=1
25350 esac
25352 if test $REPLACE_PUTENV = 1; then
25361 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
25364 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
25365 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
25366 ac_have_decl=1
25367 else
25368 ac_have_decl=0
25371 cat >>confdefs.h <<_ACEOF
25372 #define HAVE_DECL__PUTENV $ac_have_decl
25373 _ACEOF
25382 GNULIB_PUTENV=1
25389 # Check whether --enable-acl was given.
25390 if test "${enable_acl+set}" = set; then :
25391 enableval=$enable_acl;
25392 else
25393 enable_acl=auto
25397 LIB_ACL=
25398 use_acl=0
25399 if test "x$enable_acl" != "xno"; then
25400 for ac_header in sys/acl.h
25401 do :
25402 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
25403 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
25404 cat >>confdefs.h <<_ACEOF
25405 #define HAVE_SYS_ACL_H 1
25406 _ACEOF
25410 done
25412 if test $ac_cv_header_sys_acl_h = yes; then
25413 ac_save_LIBS=$LIBS
25415 if test $use_acl = 0; then
25416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
25417 $as_echo_n "checking for library containing acl_get_file... " >&6; }
25418 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25419 $as_echo_n "(cached) " >&6
25420 else
25421 ac_func_search_save_LIBS=$LIBS
25422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25423 /* end confdefs.h. */
25425 /* Override any GCC internal prototype to avoid an error.
25426 Use char because int might match the return type of a GCC
25427 builtin and then its argument prototype would still apply. */
25428 #ifdef __cplusplus
25429 extern "C"
25430 #endif
25431 char acl_get_file ();
25433 main ()
25435 return acl_get_file ();
25437 return 0;
25439 _ACEOF
25440 for ac_lib in '' acl pacl; do
25441 if test -z "$ac_lib"; then
25442 ac_res="none required"
25443 else
25444 ac_res=-l$ac_lib
25445 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25447 if ac_fn_c_try_link "$LINENO"; then :
25448 ac_cv_search_acl_get_file=$ac_res
25450 rm -f core conftest.err conftest.$ac_objext \
25451 conftest$ac_exeext
25452 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25453 break
25455 done
25456 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25458 else
25459 ac_cv_search_acl_get_file=no
25461 rm conftest.$ac_ext
25462 LIBS=$ac_func_search_save_LIBS
25464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
25465 $as_echo "$ac_cv_search_acl_get_file" >&6; }
25466 ac_res=$ac_cv_search_acl_get_file
25467 if test "$ac_res" != no; then :
25468 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25469 if test "$ac_cv_search_acl_get_file" != "none required"; then
25470 LIB_ACL=$ac_cv_search_acl_get_file
25472 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
25473 acl_free acl_from_mode acl_from_text \
25474 acl_delete_def_file acl_extended_file \
25475 acl_delete_fd_np acl_delete_file_np \
25476 acl_copy_ext_native acl_create_entry_np \
25477 acl_to_short_text acl_free_text
25478 do :
25479 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25480 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
25481 eval as_val=\$$as_ac_var
25482 if test "x$as_val" = x""yes; then :
25483 cat >>confdefs.h <<_ACEOF
25484 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25485 _ACEOF
25488 done
25490 # If the acl_get_file bug is detected, don't enable the ACL support.
25492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
25493 $as_echo_n "checking for working acl_get_file... " >&6; }
25494 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
25495 $as_echo_n "(cached) " >&6
25496 else
25497 if test "$cross_compiling" = yes; then :
25498 gl_cv_func_working_acl_get_file=cross-compiling
25499 else
25500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25501 /* end confdefs.h. */
25502 #include <sys/types.h>
25503 #include <sys/acl.h>
25504 #include <errno.h>
25507 main ()
25509 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25510 return 1;
25511 return 0;
25514 return 0;
25516 _ACEOF
25517 if ac_fn_c_try_run "$LINENO"; then :
25518 gl_cv_func_working_acl_get_file=yes
25519 else
25520 gl_cv_func_working_acl_get_file=no
25522 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25523 conftest.$ac_objext conftest.beam conftest.$ac_ext
25527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25528 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25530 if test $gl_cv_func_working_acl_get_file = yes; then :
25531 use_acl=1
25534 if test $use_acl = 1; then
25535 for ac_header in acl/libacl.h
25536 do :
25537 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25538 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
25539 cat >>confdefs.h <<_ACEOF
25540 #define HAVE_ACL_LIBACL_H 1
25541 _ACEOF
25545 done
25555 for ac_func in acl_entries
25556 do :
25557 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25558 if test "x$ac_cv_func_acl_entries" = x""yes; then :
25559 cat >>confdefs.h <<_ACEOF
25560 #define HAVE_ACL_ENTRIES 1
25561 _ACEOF
25563 else
25565 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25568 done
25571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25572 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25573 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
25574 $as_echo_n "(cached) " >&6
25575 else
25576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25577 /* end confdefs.h. */
25578 #include <sys/types.h>
25579 #include <sys/acl.h>
25580 int type = ACL_FIRST_ENTRY;
25582 main ()
25586 return 0;
25588 _ACEOF
25589 if ac_fn_c_try_compile "$LINENO"; then :
25590 gl_cv_acl_ACL_FIRST_ENTRY=yes
25591 else
25592 gl_cv_acl_ACL_FIRST_ENTRY=no
25594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25597 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25598 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25600 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25604 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25605 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
25606 $as_echo_n "(cached) " >&6
25607 else
25608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25609 /* end confdefs.h. */
25610 #include <sys/types.h>
25611 #include <sys/acl.h>
25612 int type = ACL_TYPE_EXTENDED;
25614 main ()
25618 return 0;
25620 _ACEOF
25621 if ac_fn_c_try_compile "$LINENO"; then :
25622 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25623 else
25624 gl_cv_acl_ACL_TYPE_EXTENDED=no
25626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25629 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25630 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25632 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25635 else
25636 LIB_ACL=
25643 if test $use_acl = 0; then
25644 for ac_func in facl
25645 do :
25646 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25647 if test "x$ac_cv_func_facl" = x""yes; then :
25648 cat >>confdefs.h <<_ACEOF
25649 #define HAVE_FACL 1
25650 _ACEOF
25653 done
25655 if test $ac_cv_func_facl = yes; then
25656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25657 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25658 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25659 $as_echo_n "(cached) " >&6
25660 else
25661 ac_func_search_save_LIBS=$LIBS
25662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25663 /* end confdefs.h. */
25665 /* Override any GCC internal prototype to avoid an error.
25666 Use char because int might match the return type of a GCC
25667 builtin and then its argument prototype would still apply. */
25668 #ifdef __cplusplus
25669 extern "C"
25670 #endif
25671 char acl_trivial ();
25673 main ()
25675 return acl_trivial ();
25677 return 0;
25679 _ACEOF
25680 for ac_lib in '' sec; do
25681 if test -z "$ac_lib"; then
25682 ac_res="none required"
25683 else
25684 ac_res=-l$ac_lib
25685 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25687 if ac_fn_c_try_link "$LINENO"; then :
25688 ac_cv_search_acl_trivial=$ac_res
25690 rm -f core conftest.err conftest.$ac_objext \
25691 conftest$ac_exeext
25692 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25693 break
25695 done
25696 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25698 else
25699 ac_cv_search_acl_trivial=no
25701 rm conftest.$ac_ext
25702 LIBS=$ac_func_search_save_LIBS
25704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25705 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25706 ac_res=$ac_cv_search_acl_trivial
25707 if test "$ac_res" != no; then :
25708 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25709 if test "$ac_cv_search_acl_trivial" != "none required"; then
25710 LIB_ACL=$ac_cv_search_acl_trivial
25715 for ac_func in acl_trivial
25716 do :
25717 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25718 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25719 cat >>confdefs.h <<_ACEOF
25720 #define HAVE_ACL_TRIVIAL 1
25721 _ACEOF
25724 done
25726 use_acl=1
25730 if test $use_acl = 0; then
25731 for ac_func in getacl
25732 do :
25733 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25734 if test "x$ac_cv_func_getacl" = x""yes; then :
25735 cat >>confdefs.h <<_ACEOF
25736 #define HAVE_GETACL 1
25737 _ACEOF
25740 done
25742 if test $ac_cv_func_getacl = yes; then
25743 use_acl=1
25745 for ac_header in aclv.h
25746 do :
25747 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25749 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25750 cat >>confdefs.h <<_ACEOF
25751 #define HAVE_ACLV_H 1
25752 _ACEOF
25756 done
25760 if test $use_acl = 0; then
25761 for ac_func in aclx_get
25762 do :
25763 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25764 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25765 cat >>confdefs.h <<_ACEOF
25766 #define HAVE_ACLX_GET 1
25767 _ACEOF
25770 done
25772 if test $ac_cv_func_aclx_get = yes; then
25773 use_acl=1
25777 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25778 for ac_func in statacl
25779 do :
25780 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25781 if test "x$ac_cv_func_statacl" = x""yes; then :
25782 cat >>confdefs.h <<_ACEOF
25783 #define HAVE_STATACL 1
25784 _ACEOF
25787 done
25789 if test $ac_cv_func_statacl = yes; then
25790 use_acl=1
25794 if test $use_acl = 0; then
25795 for ac_func in aclsort
25796 do :
25797 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25798 if test "x$ac_cv_func_aclsort" = x""yes; then :
25799 cat >>confdefs.h <<_ACEOF
25800 #define HAVE_ACLSORT 1
25801 _ACEOF
25804 done
25806 if test $ac_cv_func_aclsort = yes; then
25807 use_acl=1
25811 LIBS=$ac_save_LIBS
25813 if test "x$enable_acl$use_acl" = "xyes0"; then
25814 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25815 elif test "x$enable_acl$use_acl" = "xauto0"; then
25816 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25817 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25818 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25819 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25824 cat >>confdefs.h <<_ACEOF
25825 #define USE_ACL $use_acl
25826 _ACEOF
25828 USE_ACL=$use_acl
25834 if test $ac_cv_func_readlink = no; then
25835 HAVE_READLINK=0
25836 else
25837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25838 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25839 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25840 $as_echo_n "(cached) " >&6
25841 else
25842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25843 /* end confdefs.h. */
25844 #include <unistd.h>
25845 /* Cause compilation failure if original declaration has wrong type. */
25846 ssize_t readlink (const char *, char *, size_t);
25848 main ()
25852 return 0;
25854 _ACEOF
25855 if ac_fn_c_try_compile "$LINENO"; then :
25856 gl_cv_decl_readlink_works=yes
25857 else
25858 gl_cv_decl_readlink_works=no
25860 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25863 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25865 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25866 if test "${gl_cv_func_readlink_works+set}" = set; then :
25867 $as_echo_n "(cached) " >&6
25868 else
25869 # We have readlink, so assume ln -s works.
25870 ln -s conftest.no-such conftest.link
25871 ln -s conftest.link conftest.lnk2
25872 if test "$cross_compiling" = yes; then :
25873 case "$host_os" in
25874 # Guess yes on glibc systems.
25875 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25876 # If we don't know, assume the worst.
25877 *) gl_cv_func_readlink_works="guessing no" ;;
25878 esac
25880 else
25881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25882 /* end confdefs.h. */
25883 #include <unistd.h>
25886 main ()
25888 char buf[20];
25889 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25891 return 0;
25893 _ACEOF
25894 if ac_fn_c_try_run "$LINENO"; then :
25895 gl_cv_func_readlink_works=yes
25896 else
25897 gl_cv_func_readlink_works=no
25899 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25900 conftest.$ac_objext conftest.beam conftest.$ac_ext
25903 rm -f conftest.link conftest.lnk2
25905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25906 $as_echo "$gl_cv_func_readlink_works" >&6; }
25907 case "$gl_cv_func_readlink_works" in
25908 *yes)
25909 if test "$gl_cv_decl_readlink_works" != yes; then
25910 REPLACE_READLINK=1
25915 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25917 REPLACE_READLINK=1
25919 esac
25922 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25931 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
25942 GNULIB_READLINK=1
25952 if test $ac_cv_func_readlinkat = no; then
25953 HAVE_READLINKAT=0
25956 if test $HAVE_READLINKAT = 0; then
25965 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
25973 GNULIB_READLINKAT=1
25980 for ac_func in sig2str
25981 do :
25982 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
25983 if test "x$ac_cv_func_sig2str" = x""yes; then :
25984 cat >>confdefs.h <<_ACEOF
25985 #define HAVE_SIG2STR 1
25986 _ACEOF
25989 done
25992 if test $ac_cv_func_sig2str = no; then
26001 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
26018 if test $gl_cv_have_include_next = yes; then
26019 gl_cv_next_signal_h='<'signal.h'>'
26020 else
26021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
26022 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
26023 if test "${gl_cv_next_signal_h+set}" = set; then :
26024 $as_echo_n "(cached) " >&6
26025 else
26027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26028 /* end confdefs.h. */
26029 #include <signal.h>
26031 _ACEOF
26032 case "$host_os" in
26033 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26034 *) gl_absname_cpp="$ac_cpp" ;;
26035 esac
26037 case "$host_os" in
26038 mingw*)
26039 gl_dirsep_regex='[/\\]'
26042 gl_dirsep_regex='\/'
26044 esac
26045 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26047 gl_header_literal_regex=`echo 'signal.h' \
26048 | sed -e "$gl_make_literal_regex_sed"`
26049 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26050 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26051 s|^/[^/]|//&|
26055 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26056 sed -n "$gl_absolute_header_sed"`'"'
26060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
26061 $as_echo "$gl_cv_next_signal_h" >&6; }
26063 NEXT_SIGNAL_H=$gl_cv_next_signal_h
26065 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26066 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26067 gl_next_as_first_directive='<'signal.h'>'
26068 else
26069 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26070 gl_next_as_first_directive=$gl_cv_next_signal_h
26072 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
26078 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
26079 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
26080 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
26081 #include <signal.h>
26084 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
26086 else
26087 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
26096 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
26097 #include <signal.h>
26100 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
26102 else
26103 HAVE_SIGHANDLER_T=0
26109 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
26110 /* <sys/types.h> is not needed according to POSIX, but the
26111 <sys/socket.h> in i386-unknown-freebsd4.10 and
26112 powerpc-apple-darwin5.5 required it. */
26113 #include <sys/types.h>
26114 #if HAVE_SYS_SOCKET_H
26115 # include <sys/socket.h>
26116 #elif HAVE_WS2TCPIP_H
26117 # include <ws2tcpip.h>
26118 #endif
26121 if test "x$ac_cv_type_socklen_t" = x""yes; then :
26123 else
26124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
26125 $as_echo_n "checking for socklen_t equivalent... " >&6; }
26126 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
26127 $as_echo_n "(cached) " >&6
26128 else
26129 # Systems have either "struct sockaddr *" or
26130 # "void *" as the second argument to getpeername
26131 gl_cv_socklen_t_equiv=
26132 for arg2 in "struct sockaddr" void; do
26133 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
26134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26135 /* end confdefs.h. */
26136 #include <sys/types.h>
26137 #include <sys/socket.h>
26139 int getpeername (int, $arg2 *, $t *);
26141 main ()
26143 $t len;
26144 getpeername (0, 0, &len);
26146 return 0;
26148 _ACEOF
26149 if ac_fn_c_try_compile "$LINENO"; then :
26150 gl_cv_socklen_t_equiv="$t"
26152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26153 test "$gl_cv_socklen_t_equiv" != "" && break
26154 done
26155 test "$gl_cv_socklen_t_equiv" != "" && break
26156 done
26160 if test "$gl_cv_socklen_t_equiv" = ""; then
26161 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
26163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
26164 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
26166 cat >>confdefs.h <<_ACEOF
26167 #define socklen_t $gl_cv_socklen_t_equiv
26168 _ACEOF
26173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
26174 $as_echo_n "checking for ssize_t... " >&6; }
26175 if test "${gt_cv_ssize_t+set}" = set; then :
26176 $as_echo_n "(cached) " >&6
26177 else
26178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26179 /* end confdefs.h. */
26180 #include <sys/types.h>
26182 main ()
26184 int x = sizeof (ssize_t *) + sizeof (ssize_t);
26185 return !x;
26187 return 0;
26189 _ACEOF
26190 if ac_fn_c_try_compile "$LINENO"; then :
26191 gt_cv_ssize_t=yes
26192 else
26193 gt_cv_ssize_t=no
26195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
26198 $as_echo "$gt_cv_ssize_t" >&6; }
26199 if test $gt_cv_ssize_t = no; then
26201 $as_echo "#define ssize_t int" >>confdefs.h
26209 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>
26210 #include <sys/stat.h>
26212 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
26214 cat >>confdefs.h <<_ACEOF
26215 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
26216 _ACEOF
26218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
26219 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
26220 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
26221 $as_echo_n "(cached) " >&6
26222 else
26223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26224 /* end confdefs.h. */
26226 #include <sys/types.h>
26227 #include <sys/stat.h>
26228 #if HAVE_SYS_TIME_H
26229 # include <sys/time.h>
26230 #endif
26231 #include <time.h>
26232 struct timespec ts;
26233 struct stat st;
26236 main ()
26239 st.st_atim = ts;
26242 return 0;
26244 _ACEOF
26245 if ac_fn_c_try_compile "$LINENO"; then :
26246 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
26247 else
26248 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
26250 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
26253 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
26254 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
26256 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
26259 else
26260 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>
26261 #include <sys/stat.h>
26263 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
26265 cat >>confdefs.h <<_ACEOF
26266 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
26267 _ACEOF
26270 else
26271 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
26272 #include <sys/stat.h>
26274 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
26276 cat >>confdefs.h <<_ACEOF
26277 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
26278 _ACEOF
26281 else
26282 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>
26283 #include <sys/stat.h>
26285 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
26287 cat >>confdefs.h <<_ACEOF
26288 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
26289 _ACEOF
26304 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>
26305 #include <sys/stat.h>
26307 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
26309 cat >>confdefs.h <<_ACEOF
26310 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
26311 _ACEOF
26314 else
26315 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
26316 #include <sys/stat.h>
26318 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
26320 cat >>confdefs.h <<_ACEOF
26321 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
26322 _ACEOF
26325 else
26326 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>
26327 #include <sys/stat.h>
26329 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
26331 cat >>confdefs.h <<_ACEOF
26332 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
26333 _ACEOF
26344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
26345 $as_echo_n "checking for working stdalign.h... " >&6; }
26346 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
26347 $as_echo_n "(cached) " >&6
26348 else
26349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26350 /* end confdefs.h. */
26351 #include <stdalign.h>
26352 #include <stddef.h>
26354 /* Test that alignof yields a result consistent with offsetof.
26355 This catches GCC bug 52023
26356 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
26357 #ifdef __cplusplus
26358 template <class t> struct alignof_helper { char a; t b; };
26359 # define ao(type) offsetof (alignof_helper<type>, b)
26360 #else
26361 # define ao(type) offsetof (struct { char a; type b; }, b)
26362 #endif
26363 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
26364 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
26365 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
26367 /* Test _Alignas only on platforms where gnulib can help. */
26368 #if \
26369 ((defined __cplusplus && 201103 <= __cplusplus) \
26370 || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
26371 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
26372 struct alignas_test { char c; char alignas (8) alignas_8; };
26373 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
26374 ? 1 : -1];
26375 #endif
26378 main ()
26382 return 0;
26384 _ACEOF
26385 if ac_fn_c_try_compile "$LINENO"; then :
26386 gl_cv_header_working_stdalign_h=yes
26387 else
26388 gl_cv_header_working_stdalign_h=no
26390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
26393 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
26395 if test $gl_cv_header_working_stdalign_h = yes; then
26396 STDALIGN_H=''
26397 else
26398 STDALIGN_H='stdalign.h'
26402 if test -n "$STDALIGN_H"; then
26403 GL_GENERATE_STDALIGN_H_TRUE=
26404 GL_GENERATE_STDALIGN_H_FALSE='#'
26405 else
26406 GL_GENERATE_STDALIGN_H_TRUE='#'
26407 GL_GENERATE_STDALIGN_H_FALSE=
26412 STDARG_H=''
26413 NEXT_STDARG_H='<stdarg.h>'
26414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
26415 $as_echo_n "checking for va_copy... " >&6; }
26416 if test "${gl_cv_func_va_copy+set}" = set; then :
26417 $as_echo_n "(cached) " >&6
26418 else
26420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26421 /* end confdefs.h. */
26422 #include <stdarg.h>
26424 main ()
26427 #ifndef va_copy
26428 void (*func) (va_list, va_list) = va_copy;
26429 #endif
26432 return 0;
26434 _ACEOF
26435 if ac_fn_c_try_compile "$LINENO"; then :
26436 gl_cv_func_va_copy=yes
26437 else
26438 gl_cv_func_va_copy=no
26440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
26444 $as_echo "$gl_cv_func_va_copy" >&6; }
26445 if test $gl_cv_func_va_copy = no; then
26446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26447 /* end confdefs.h. */
26448 #if defined _AIX && !defined __GNUC__
26449 AIX vaccine
26450 #endif
26452 _ACEOF
26453 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26454 $EGREP "vaccine" >/dev/null 2>&1; then :
26455 gl_aixcc=yes
26456 else
26457 gl_aixcc=no
26459 rm -f conftest*
26461 if test $gl_aixcc = yes; then
26462 STDARG_H=stdarg.h
26471 if test $gl_cv_have_include_next = yes; then
26472 gl_cv_next_stdarg_h='<'stdarg.h'>'
26473 else
26474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
26475 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
26476 if test "${gl_cv_next_stdarg_h+set}" = set; then :
26477 $as_echo_n "(cached) " >&6
26478 else
26480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26481 /* end confdefs.h. */
26482 #include <stdarg.h>
26484 _ACEOF
26485 case "$host_os" in
26486 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26487 *) gl_absname_cpp="$ac_cpp" ;;
26488 esac
26490 case "$host_os" in
26491 mingw*)
26492 gl_dirsep_regex='[/\\]'
26495 gl_dirsep_regex='\/'
26497 esac
26498 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26500 gl_header_literal_regex=`echo 'stdarg.h' \
26501 | sed -e "$gl_make_literal_regex_sed"`
26502 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26503 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26504 s|^/[^/]|//&|
26508 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26509 sed -n "$gl_absolute_header_sed"`'"'
26513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
26514 $as_echo "$gl_cv_next_stdarg_h" >&6; }
26516 NEXT_STDARG_H=$gl_cv_next_stdarg_h
26518 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26519 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26520 gl_next_as_first_directive='<'stdarg.h'>'
26521 else
26522 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26523 gl_next_as_first_directive=$gl_cv_next_stdarg_h
26525 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
26530 if test "$gl_cv_next_stdarg_h" = '""'; then
26531 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
26532 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
26534 else
26536 saved_as_echo_n="$as_echo_n"
26537 as_echo_n=':'
26538 if test "${gl_cv_func___va_copy+set}" = set; then :
26539 $as_echo_n "(cached) " >&6
26540 else
26542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26543 /* end confdefs.h. */
26544 #include <stdarg.h>
26546 main ()
26549 #ifndef __va_copy
26550 error, bail out
26551 #endif
26554 return 0;
26556 _ACEOF
26557 if ac_fn_c_try_compile "$LINENO"; then :
26558 gl_cv_func___va_copy=yes
26559 else
26560 gl_cv_func___va_copy=no
26562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26565 as_echo_n="$saved_as_echo_n"
26567 if test $gl_cv_func___va_copy = yes; then
26569 $as_echo "#define va_copy __va_copy" >>confdefs.h
26571 else
26574 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
26580 if test -n "$STDARG_H"; then
26581 GL_GENERATE_STDARG_H_TRUE=
26582 GL_GENERATE_STDARG_H_FALSE='#'
26583 else
26584 GL_GENERATE_STDARG_H_TRUE='#'
26585 GL_GENERATE_STDARG_H_FALSE=
26593 # Define two additional variables used in the Makefile substitution.
26595 if test "$ac_cv_header_stdbool_h" = yes; then
26596 STDBOOL_H=''
26597 else
26598 STDBOOL_H='stdbool.h'
26601 if test -n "$STDBOOL_H"; then
26602 GL_GENERATE_STDBOOL_H_TRUE=
26603 GL_GENERATE_STDBOOL_H_FALSE='#'
26604 else
26605 GL_GENERATE_STDBOOL_H_TRUE='#'
26606 GL_GENERATE_STDBOOL_H_FALSE=
26610 if test "$ac_cv_type__Bool" = yes; then
26611 HAVE__BOOL=1
26612 else
26613 HAVE__BOOL=0
26620 STDDEF_H=
26621 if test $gt_cv_c_wchar_t = no; then
26622 HAVE_WCHAR_T=0
26623 STDDEF_H=stddef.h
26625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26626 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26627 if test "${gl_cv_decl_null_works+set}" = set; then :
26628 $as_echo_n "(cached) " >&6
26629 else
26630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26631 /* end confdefs.h. */
26632 #include <stddef.h>
26633 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26636 main ()
26640 return 0;
26642 _ACEOF
26643 if ac_fn_c_try_compile "$LINENO"; then :
26644 gl_cv_decl_null_works=yes
26645 else
26646 gl_cv_decl_null_works=no
26648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26651 $as_echo "$gl_cv_decl_null_works" >&6; }
26652 if test $gl_cv_decl_null_works = no; then
26653 REPLACE_NULL=1
26654 STDDEF_H=stddef.h
26657 if test -n "$STDDEF_H"; then
26658 GL_GENERATE_STDDEF_H_TRUE=
26659 GL_GENERATE_STDDEF_H_FALSE='#'
26660 else
26661 GL_GENERATE_STDDEF_H_TRUE='#'
26662 GL_GENERATE_STDDEF_H_FALSE=
26665 if test -n "$STDDEF_H"; then
26674 if test $gl_cv_have_include_next = yes; then
26675 gl_cv_next_stddef_h='<'stddef.h'>'
26676 else
26677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26678 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26679 if test "${gl_cv_next_stddef_h+set}" = set; then :
26680 $as_echo_n "(cached) " >&6
26681 else
26683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26684 /* end confdefs.h. */
26685 #include <stddef.h>
26687 _ACEOF
26688 case "$host_os" in
26689 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26690 *) gl_absname_cpp="$ac_cpp" ;;
26691 esac
26693 case "$host_os" in
26694 mingw*)
26695 gl_dirsep_regex='[/\\]'
26698 gl_dirsep_regex='\/'
26700 esac
26701 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26703 gl_header_literal_regex=`echo 'stddef.h' \
26704 | sed -e "$gl_make_literal_regex_sed"`
26705 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26706 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26707 s|^/[^/]|//&|
26711 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26712 sed -n "$gl_absolute_header_sed"`'"'
26716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26717 $as_echo "$gl_cv_next_stddef_h" >&6; }
26719 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26721 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26722 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26723 gl_next_as_first_directive='<'stddef.h'>'
26724 else
26725 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26726 gl_next_as_first_directive=$gl_cv_next_stddef_h
26728 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26746 if test $gl_cv_have_include_next = yes; then
26747 gl_cv_next_stdio_h='<'stdio.h'>'
26748 else
26749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26750 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26751 if test "${gl_cv_next_stdio_h+set}" = set; then :
26752 $as_echo_n "(cached) " >&6
26753 else
26755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26756 /* end confdefs.h. */
26757 #include <stdio.h>
26759 _ACEOF
26760 case "$host_os" in
26761 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26762 *) gl_absname_cpp="$ac_cpp" ;;
26763 esac
26765 case "$host_os" in
26766 mingw*)
26767 gl_dirsep_regex='[/\\]'
26770 gl_dirsep_regex='\/'
26772 esac
26773 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26775 gl_header_literal_regex=`echo 'stdio.h' \
26776 | sed -e "$gl_make_literal_regex_sed"`
26777 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26778 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26779 s|^/[^/]|//&|
26783 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26784 sed -n "$gl_absolute_header_sed"`'"'
26788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26789 $as_echo "$gl_cv_next_stdio_h" >&6; }
26791 NEXT_STDIO_H=$gl_cv_next_stdio_h
26793 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26794 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26795 gl_next_as_first_directive='<'stdio.h'>'
26796 else
26797 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26798 gl_next_as_first_directive=$gl_cv_next_stdio_h
26800 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26806 GNULIB_FSCANF=1
26809 cat >>confdefs.h <<_ACEOF
26810 #define GNULIB_FSCANF 1
26811 _ACEOF
26814 GNULIB_SCANF=1
26817 cat >>confdefs.h <<_ACEOF
26818 #define GNULIB_SCANF 1
26819 _ACEOF
26822 GNULIB_FGETC=1
26823 GNULIB_GETC=1
26824 GNULIB_GETCHAR=1
26825 GNULIB_FGETS=1
26826 GNULIB_FREAD=1
26829 GNULIB_FPRINTF=1
26830 GNULIB_PRINTF=1
26831 GNULIB_VFPRINTF=1
26832 GNULIB_VPRINTF=1
26833 GNULIB_FPUTC=1
26834 GNULIB_PUTC=1
26835 GNULIB_PUTCHAR=1
26836 GNULIB_FPUTS=1
26837 GNULIB_PUTS=1
26838 GNULIB_FWRITE=1
26854 if test $gl_cv_have_include_next = yes; then
26855 gl_cv_next_stdlib_h='<'stdlib.h'>'
26856 else
26857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26858 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26859 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26860 $as_echo_n "(cached) " >&6
26861 else
26863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26864 /* end confdefs.h. */
26865 #include <stdlib.h>
26867 _ACEOF
26868 case "$host_os" in
26869 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26870 *) gl_absname_cpp="$ac_cpp" ;;
26871 esac
26873 case "$host_os" in
26874 mingw*)
26875 gl_dirsep_regex='[/\\]'
26878 gl_dirsep_regex='\/'
26880 esac
26881 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26883 gl_header_literal_regex=`echo 'stdlib.h' \
26884 | sed -e "$gl_make_literal_regex_sed"`
26885 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26886 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26887 s|^/[^/]|//&|
26891 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26892 sed -n "$gl_absolute_header_sed"`'"'
26896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26897 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26899 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26901 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26902 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26903 gl_next_as_first_directive='<'stdlib.h'>'
26904 else
26905 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26906 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26908 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26918 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26926 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26938 if test "$ac_cv_have_decl_strtoimax" != yes; then
26939 HAVE_DECL_STRTOIMAX=0
26942 if test $ac_cv_func_strtoimax = yes; then
26943 HAVE_STRTOIMAX=1
26944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
26945 $as_echo_n "checking whether strtoimax works... " >&6; }
26946 if test "${gl_cv_func_strtoimax+set}" = set; then :
26947 $as_echo_n "(cached) " >&6
26948 else
26949 if test "$cross_compiling" = yes; then :
26950 case "$host_os" in
26951 # Guess no on AIX 5.
26952 aix5*) gl_cv_func_strtoimax="guessing no" ;;
26953 # Guess yes otherwise.
26954 *) gl_cv_func_strtoimax="guessing yes" ;;
26955 esac
26957 else
26958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26959 /* end confdefs.h. */
26961 #include <errno.h>
26962 #include <string.h>
26963 #include <inttypes.h>
26964 int main ()
26966 if (sizeof (intmax_t) > sizeof (int))
26968 const char *s = "4294967295";
26969 char *p;
26970 intmax_t res;
26971 errno = 0;
26972 res = strtoimax (s, &p, 10);
26973 if (p != s + strlen (s))
26974 return 1;
26975 if (errno != 0)
26976 return 2;
26977 if (res != (intmax_t) 65535 * (intmax_t) 65537)
26978 return 3;
26980 else
26982 const char *s = "2147483647";
26983 char *p;
26984 intmax_t res;
26985 errno = 0;
26986 res = strtoimax (s, &p, 10);
26987 if (p != s + strlen (s))
26988 return 1;
26989 if (errno != 0)
26990 return 2;
26991 if (res != 2147483647)
26992 return 3;
26994 return 0;
26997 _ACEOF
26998 if ac_fn_c_try_run "$LINENO"; then :
26999 gl_cv_func_strtoimax=yes
27000 else
27001 gl_cv_func_strtoimax=no
27003 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27004 conftest.$ac_objext conftest.beam conftest.$ac_ext
27009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
27010 $as_echo "$gl_cv_func_strtoimax" >&6; }
27011 case "$gl_cv_func_strtoimax" in
27012 *no) REPLACE_STRTOIMAX=1 ;;
27013 esac
27014 else
27015 HAVE_STRTOIMAX=0
27018 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
27027 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
27030 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
27031 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
27032 ac_have_decl=1
27033 else
27034 ac_have_decl=0
27037 cat >>confdefs.h <<_ACEOF
27038 #define HAVE_DECL_STRTOLL $ac_have_decl
27039 _ACEOF
27049 GNULIB_STRTOIMAX=1
27059 if test "$ac_cv_have_decl_strtoumax" != yes; then
27060 HAVE_DECL_STRTOUMAX=0
27063 if test $ac_cv_func_strtoumax = no; then
27072 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
27075 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
27076 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
27077 ac_have_decl=1
27078 else
27079 ac_have_decl=0
27082 cat >>confdefs.h <<_ACEOF
27083 #define HAVE_DECL_STRTOULL $ac_have_decl
27084 _ACEOF
27094 GNULIB_STRTOUMAX=1
27102 if test $ac_cv_func_symlink = no; then
27103 HAVE_SYMLINK=0
27104 else
27105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
27106 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
27107 if test "${gl_cv_func_symlink_works+set}" = set; then :
27108 $as_echo_n "(cached) " >&6
27109 else
27110 if test "$cross_compiling" = yes; then :
27111 case "$host_os" in
27112 # Guess yes on glibc systems.
27113 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
27114 # If we don't know, assume the worst.
27115 *) gl_cv_func_symlink_works="guessing no" ;;
27116 esac
27118 else
27119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27120 /* end confdefs.h. */
27121 #include <unistd.h>
27124 main ()
27126 int result = 0;
27127 if (!symlink ("a", "conftest.link/"))
27128 result |= 1;
27129 if (symlink ("conftest.f", "conftest.lnk2"))
27130 result |= 2;
27131 else if (!symlink ("a", "conftest.lnk2/"))
27132 result |= 4;
27133 return result;
27136 return 0;
27138 _ACEOF
27139 if ac_fn_c_try_run "$LINENO"; then :
27140 gl_cv_func_symlink_works=yes
27141 else
27142 gl_cv_func_symlink_works=no
27144 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27145 conftest.$ac_objext conftest.beam conftest.$ac_ext
27148 rm -f conftest.f conftest.link conftest.lnk2
27150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
27151 $as_echo "$gl_cv_func_symlink_works" >&6; }
27152 case "$gl_cv_func_symlink_works" in
27153 *yes) ;;
27155 REPLACE_SYMLINK=1
27157 esac
27160 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
27169 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
27177 GNULIB_SYMLINK=1
27186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
27187 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
27188 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
27189 $as_echo_n "(cached) " >&6
27190 else
27192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27193 /* end confdefs.h. */
27194 #include <sys/select.h>
27196 main ()
27198 struct timeval b;
27200 return 0;
27202 _ACEOF
27203 if ac_fn_c_try_compile "$LINENO"; then :
27204 gl_cv_header_sys_select_h_selfcontained=yes
27205 else
27206 gl_cv_header_sys_select_h_selfcontained=no
27208 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27209 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
27210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27211 /* end confdefs.h. */
27212 #include <sys/select.h>
27214 main ()
27216 int memset; int bzero;
27218 return 0;
27221 _ACEOF
27222 if ac_fn_c_try_compile "$LINENO"; then :
27223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27224 /* end confdefs.h. */
27225 #include <sys/select.h>
27227 main ()
27230 #undef memset
27231 #define memset nonexistent_memset
27232 extern
27233 #ifdef __cplusplus
27235 #endif
27236 void *memset (void *, int, unsigned long);
27237 #undef bzero
27238 #define bzero nonexistent_bzero
27239 extern
27240 #ifdef __cplusplus
27242 #endif
27243 void bzero (void *, unsigned long);
27244 fd_set fds;
27245 FD_ZERO (&fds);
27248 return 0;
27251 _ACEOF
27252 if ac_fn_c_try_link "$LINENO"; then :
27254 else
27255 gl_cv_header_sys_select_h_selfcontained=no
27257 rm -f core conftest.err conftest.$ac_objext \
27258 conftest$ac_exeext conftest.$ac_ext
27261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
27266 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
27276 if test $gl_cv_have_include_next = yes; then
27277 gl_cv_next_sys_select_h='<'sys/select.h'>'
27278 else
27279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
27280 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
27281 if test "${gl_cv_next_sys_select_h+set}" = set; then :
27282 $as_echo_n "(cached) " >&6
27283 else
27285 if test $ac_cv_header_sys_select_h = yes; then
27288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27289 /* end confdefs.h. */
27290 #include <sys/select.h>
27292 _ACEOF
27293 case "$host_os" in
27294 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27295 *) gl_absname_cpp="$ac_cpp" ;;
27296 esac
27298 case "$host_os" in
27299 mingw*)
27300 gl_dirsep_regex='[/\\]'
27303 gl_dirsep_regex='\/'
27305 esac
27306 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27308 gl_header_literal_regex=`echo 'sys/select.h' \
27309 | sed -e "$gl_make_literal_regex_sed"`
27310 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27311 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27312 s|^/[^/]|//&|
27316 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27317 sed -n "$gl_absolute_header_sed"`'"'
27318 else
27319 gl_cv_next_sys_select_h='<'sys/select.h'>'
27324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
27325 $as_echo "$gl_cv_next_sys_select_h" >&6; }
27327 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
27329 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27330 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27331 gl_next_as_first_directive='<'sys/select.h'>'
27332 else
27333 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27334 gl_next_as_first_directive=$gl_cv_next_sys_select_h
27336 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
27341 if test $ac_cv_header_sys_select_h = yes; then
27342 HAVE_SYS_SELECT_H=1
27343 else
27344 HAVE_SYS_SELECT_H=0
27351 if test $ac_cv_header_sys_socket_h != yes; then
27352 for ac_header in winsock2.h
27353 do :
27354 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
27355 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
27356 cat >>confdefs.h <<_ACEOF
27357 #define HAVE_WINSOCK2_H 1
27358 _ACEOF
27362 done
27365 if test "$ac_cv_header_winsock2_h" = yes; then
27366 HAVE_WINSOCK2_H=1
27367 UNISTD_H_HAVE_WINSOCK2_H=1
27368 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
27369 else
27370 HAVE_WINSOCK2_H=0
27392 if test $gl_cv_have_include_next = yes; then
27393 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27394 else
27395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
27396 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
27397 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
27398 $as_echo_n "(cached) " >&6
27399 else
27401 if test $ac_cv_header_sys_stat_h = yes; then
27404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27405 /* end confdefs.h. */
27406 #include <sys/stat.h>
27408 _ACEOF
27409 case "$host_os" in
27410 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27411 *) gl_absname_cpp="$ac_cpp" ;;
27412 esac
27414 case "$host_os" in
27415 mingw*)
27416 gl_dirsep_regex='[/\\]'
27419 gl_dirsep_regex='\/'
27421 esac
27422 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27424 gl_header_literal_regex=`echo 'sys/stat.h' \
27425 | sed -e "$gl_make_literal_regex_sed"`
27426 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27427 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27428 s|^/[^/]|//&|
27432 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27433 sed -n "$gl_absolute_header_sed"`'"'
27434 else
27435 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
27441 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
27443 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
27445 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27446 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27447 gl_next_as_first_directive='<'sys/stat.h'>'
27448 else
27449 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27450 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
27452 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
27464 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
27466 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
27470 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
27471 #include <sys/stat.h>
27473 if test "x$ac_cv_type_nlink_t" = x""yes; then :
27475 else
27477 $as_echo "#define nlink_t int" >>confdefs.h
27498 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
27500 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
27501 ac_have_decl=1
27502 else
27503 ac_have_decl=0
27506 cat >>confdefs.h <<_ACEOF
27507 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
27508 _ACEOF
27510 if test $ac_cv_have_decl_localtime_r = no; then
27511 HAVE_DECL_LOCALTIME_R=0
27515 if test $ac_cv_func_localtime_r = yes; then
27516 HAVE_LOCALTIME_R=1
27517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
27518 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
27519 if test "${gl_cv_time_r_posix+set}" = set; then :
27520 $as_echo_n "(cached) " >&6
27521 else
27522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27523 /* end confdefs.h. */
27524 #include <time.h>
27526 main ()
27528 /* We don't need to append 'restrict's to the argument types,
27529 even though the POSIX signature has the 'restrict's,
27530 since C99 says they can't affect type compatibility. */
27531 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
27532 if (ptr) return 0;
27533 /* Check the return type is a pointer.
27534 On HP-UX 10 it is 'int'. */
27535 *localtime_r (0, 0);
27537 return 0;
27540 _ACEOF
27541 if ac_fn_c_try_compile "$LINENO"; then :
27542 gl_cv_time_r_posix=yes
27543 else
27544 gl_cv_time_r_posix=no
27546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
27550 $as_echo "$gl_cv_time_r_posix" >&6; }
27551 if test $gl_cv_time_r_posix = yes; then
27552 REPLACE_LOCALTIME_R=0
27553 else
27554 REPLACE_LOCALTIME_R=1
27556 else
27557 HAVE_LOCALTIME_R=0
27560 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
27569 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
27580 GNULIB_TIME_R=1
27591 LIB_TIMER_TIME=
27593 gl_saved_libs=$LIBS
27594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
27595 $as_echo_n "checking for library containing timer_settime... " >&6; }
27596 if test "${ac_cv_search_timer_settime+set}" = set; then :
27597 $as_echo_n "(cached) " >&6
27598 else
27599 ac_func_search_save_LIBS=$LIBS
27600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27601 /* end confdefs.h. */
27603 /* Override any GCC internal prototype to avoid an error.
27604 Use char because int might match the return type of a GCC
27605 builtin and then its argument prototype would still apply. */
27606 #ifdef __cplusplus
27607 extern "C"
27608 #endif
27609 char timer_settime ();
27611 main ()
27613 return timer_settime ();
27615 return 0;
27617 _ACEOF
27618 for ac_lib in '' rt posix4; do
27619 if test -z "$ac_lib"; then
27620 ac_res="none required"
27621 else
27622 ac_res=-l$ac_lib
27623 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27625 if ac_fn_c_try_link "$LINENO"; then :
27626 ac_cv_search_timer_settime=$ac_res
27628 rm -f core conftest.err conftest.$ac_objext \
27629 conftest$ac_exeext
27630 if test "${ac_cv_search_timer_settime+set}" = set; then :
27631 break
27633 done
27634 if test "${ac_cv_search_timer_settime+set}" = set; then :
27636 else
27637 ac_cv_search_timer_settime=no
27639 rm conftest.$ac_ext
27640 LIBS=$ac_func_search_save_LIBS
27642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27643 $as_echo "$ac_cv_search_timer_settime" >&6; }
27644 ac_res=$ac_cv_search_timer_settime
27645 if test "$ac_res" != no; then :
27646 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27647 test "$ac_cv_search_timer_settime" = "none required" ||
27648 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27652 /* end confdefs.h. */
27654 #include <features.h>
27655 #ifdef __GNU_LIBRARY__
27656 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27657 && !defined __UCLIBC__
27658 Thread emulation available
27659 #endif
27660 #endif
27662 _ACEOF
27663 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27664 $EGREP "Thread" >/dev/null 2>&1; then :
27665 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27667 rm -f conftest*
27669 for ac_func in timer_settime
27670 do :
27671 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27672 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27673 cat >>confdefs.h <<_ACEOF
27674 #define HAVE_TIMER_SETTIME 1
27675 _ACEOF
27678 done
27680 LIBS=$gl_saved_libs
27695 if test $gl_cv_have_include_next = yes; then
27696 gl_cv_next_unistd_h='<'unistd.h'>'
27697 else
27698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27699 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27700 if test "${gl_cv_next_unistd_h+set}" = set; then :
27701 $as_echo_n "(cached) " >&6
27702 else
27704 if test $ac_cv_header_unistd_h = yes; then
27707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27708 /* end confdefs.h. */
27709 #include <unistd.h>
27711 _ACEOF
27712 case "$host_os" in
27713 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27714 *) gl_absname_cpp="$ac_cpp" ;;
27715 esac
27717 case "$host_os" in
27718 mingw*)
27719 gl_dirsep_regex='[/\\]'
27722 gl_dirsep_regex='\/'
27724 esac
27725 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27727 gl_header_literal_regex=`echo 'unistd.h' \
27728 | sed -e "$gl_make_literal_regex_sed"`
27729 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27730 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27731 s|^/[^/]|//&|
27735 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27736 sed -n "$gl_absolute_header_sed"`'"'
27737 else
27738 gl_cv_next_unistd_h='<'unistd.h'>'
27743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27744 $as_echo "$gl_cv_next_unistd_h" >&6; }
27746 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27748 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27749 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27750 gl_next_as_first_directive='<'unistd.h'>'
27751 else
27752 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27753 gl_next_as_first_directive=$gl_cv_next_unistd_h
27755 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27760 if test $ac_cv_header_unistd_h = yes; then
27761 HAVE_UNISTD_H=1
27762 else
27763 HAVE_UNISTD_H=0
27776 if test $ac_cv_have_decl_unsetenv = no; then
27777 HAVE_DECL_UNSETENV=0
27779 for ac_func in unsetenv
27780 do :
27781 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27782 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27783 cat >>confdefs.h <<_ACEOF
27784 #define HAVE_UNSETENV 1
27785 _ACEOF
27788 done
27790 if test $ac_cv_func_unsetenv = no; then
27791 HAVE_UNSETENV=0
27792 else
27793 HAVE_UNSETENV=1
27794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27795 $as_echo_n "checking for unsetenv() return type... " >&6; }
27796 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27797 $as_echo_n "(cached) " >&6
27798 else
27799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27800 /* end confdefs.h. */
27802 #undef _BSD
27803 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27804 #include <stdlib.h>
27805 extern
27806 #ifdef __cplusplus
27808 #endif
27809 int unsetenv (const char *name);
27812 main ()
27816 return 0;
27818 _ACEOF
27819 if ac_fn_c_try_compile "$LINENO"; then :
27820 gt_cv_func_unsetenv_ret='int'
27821 else
27822 gt_cv_func_unsetenv_ret='void'
27824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27827 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27828 if test $gt_cv_func_unsetenv_ret = 'void'; then
27830 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27832 REPLACE_UNSETENV=1
27835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27836 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27837 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27838 $as_echo_n "(cached) " >&6
27839 else
27840 if test "$cross_compiling" = yes; then :
27841 case "$host_os" in
27842 # Guess yes on glibc systems.
27843 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27844 # If we don't know, assume the worst.
27845 *) gl_cv_func_unsetenv_works="guessing no" ;;
27846 esac
27848 else
27849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27850 /* end confdefs.h. */
27852 #include <stdlib.h>
27853 #include <errno.h>
27854 extern char **environ;
27857 main ()
27860 char entry1[] = "a=1";
27861 char entry2[] = "b=2";
27862 char *env[] = { entry1, entry2, NULL };
27863 if (putenv ((char *) "a=1")) return 1;
27864 if (putenv (entry2)) return 2;
27865 entry2[0] = 'a';
27866 unsetenv ("a");
27867 if (getenv ("a")) return 3;
27868 if (!unsetenv ("") || errno != EINVAL) return 4;
27869 entry2[0] = 'b';
27870 environ = env;
27871 if (!getenv ("a")) return 5;
27872 entry2[0] = 'a';
27873 unsetenv ("a");
27874 if (getenv ("a")) return 6;
27877 return 0;
27879 _ACEOF
27880 if ac_fn_c_try_run "$LINENO"; then :
27881 gl_cv_func_unsetenv_works=yes
27882 else
27883 gl_cv_func_unsetenv_works=no
27885 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27886 conftest.$ac_objext conftest.beam conftest.$ac_ext
27890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27891 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27892 case "$gl_cv_func_unsetenv_works" in
27893 *yes) ;;
27895 REPLACE_UNSETENV=1
27897 esac
27900 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27909 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27921 GNULIB_UNSETENV=1
27933 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
27934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
27935 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
27936 if test "${gl_cv_func_futimesat_works+set}" = set; then :
27937 $as_echo_n "(cached) " >&6
27938 else
27939 touch conftest.file
27940 if test "$cross_compiling" = yes; then :
27941 case "$host_os" in
27942 # Guess yes on glibc systems.
27943 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
27944 # If we don't know, assume the worst.
27945 *) gl_cv_func_futimesat_works="guessing no" ;;
27946 esac
27948 else
27949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27950 /* end confdefs.h. */
27952 #include <stddef.h>
27953 #include <sys/times.h>
27954 #include <fcntl.h>
27957 main ()
27959 int fd = open ("conftest.file", O_RDWR);
27960 if (fd < 0) return 1;
27961 if (futimesat (fd, NULL, NULL)) return 2;
27964 return 0;
27966 _ACEOF
27967 if ac_fn_c_try_run "$LINENO"; then :
27968 gl_cv_func_futimesat_works=yes
27969 else
27970 gl_cv_func_futimesat_works=no
27972 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27973 conftest.$ac_objext conftest.beam conftest.$ac_ext
27976 rm -f conftest.file
27978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
27979 $as_echo "$gl_cv_func_futimesat_works" >&6; }
27980 case "$gl_cv_func_futimesat_works" in
27981 *yes) ;;
27984 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
27987 esac
27990 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
27991 gl_gnulib_enabled_dosname=false
27992 gl_gnulib_enabled_euidaccess=false
27993 gl_gnulib_enabled_getdtablesize=false
27994 gl_gnulib_enabled_getgroups=false
27995 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
27996 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
27997 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
27998 gl_gnulib_enabled_pathmax=false
27999 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
28000 gl_gnulib_enabled_secure_getenv=false
28001 gl_gnulib_enabled_stat=false
28002 gl_gnulib_enabled_strtoll=false
28003 gl_gnulib_enabled_strtoull=false
28004 gl_gnulib_enabled_tempname=false
28005 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
28006 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
28008 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28017 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
28019 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
28022 func_gl_gnulib_m4code_dosname ()
28024 if ! $gl_gnulib_enabled_dosname; then
28025 gl_gnulib_enabled_dosname=true
28028 func_gl_gnulib_m4code_euidaccess ()
28030 if ! $gl_gnulib_enabled_euidaccess; then
28036 for ac_func in euidaccess
28037 do :
28038 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
28039 if test "x$ac_cv_func_euidaccess" = x""yes; then :
28040 cat >>confdefs.h <<_ACEOF
28041 #define HAVE_EUIDACCESS 1
28042 _ACEOF
28045 done
28047 if test $ac_cv_func_euidaccess = no; then
28048 HAVE_EUIDACCESS=0
28051 if test $HAVE_EUIDACCESS = 0; then
28060 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
28064 for ac_header in libgen.h
28065 do :
28066 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
28067 if test "x$ac_cv_header_libgen_h" = x""yes; then :
28068 cat >>confdefs.h <<_ACEOF
28069 #define HAVE_LIBGEN_H 1
28070 _ACEOF
28074 done
28077 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28078 if test "x$ac_cv_func_getgroups" = x""yes; then :
28083 # If we don't yet have getgroups, see if it's in -lbsd.
28084 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28085 ac_save_LIBS=$LIBS
28086 if test $ac_cv_func_getgroups = no; then
28087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28088 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28089 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28090 $as_echo_n "(cached) " >&6
28091 else
28092 ac_check_lib_save_LIBS=$LIBS
28093 LIBS="-lbsd $LIBS"
28094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28095 /* end confdefs.h. */
28097 /* Override any GCC internal prototype to avoid an error.
28098 Use char because int might match the return type of a GCC
28099 builtin and then its argument prototype would still apply. */
28100 #ifdef __cplusplus
28101 extern "C"
28102 #endif
28103 char getgroups ();
28105 main ()
28107 return getgroups ();
28109 return 0;
28111 _ACEOF
28112 if ac_fn_c_try_link "$LINENO"; then :
28113 ac_cv_lib_bsd_getgroups=yes
28114 else
28115 ac_cv_lib_bsd_getgroups=no
28117 rm -f core conftest.err conftest.$ac_objext \
28118 conftest$ac_exeext conftest.$ac_ext
28119 LIBS=$ac_check_lib_save_LIBS
28121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28122 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28123 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28124 GETGROUPS_LIB=-lbsd
28129 # Run the program to test the functionality of the system-supplied
28130 # getgroups function only if there is such a function.
28131 if test $ac_cv_func_getgroups = yes; then
28132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28133 $as_echo_n "checking for working getgroups... " >&6; }
28134 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28135 $as_echo_n "(cached) " >&6
28136 else
28137 if test "$cross_compiling" = yes; then :
28138 case "$host_os" in # ((
28139 # Guess yes on glibc systems.
28140 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28141 # If we don't know, assume the worst.
28142 *) ac_cv_func_getgroups_works="guessing no" ;;
28143 esac
28145 else
28146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28147 /* end confdefs.h. */
28148 $ac_includes_default
28150 main ()
28152 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28153 return getgroups (0, 0) == -1;
28155 return 0;
28158 _ACEOF
28159 if ac_fn_c_try_run "$LINENO"; then :
28160 ac_cv_func_getgroups_works=yes
28161 else
28162 ac_cv_func_getgroups_works=no
28164 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28165 conftest.$ac_objext conftest.beam conftest.$ac_ext
28170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28171 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28172 else
28173 ac_cv_func_getgroups_works=no
28175 case "$ac_cv_func_getgroups_works" in
28176 *yes)
28178 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28181 esac
28182 LIBS=$ac_save_LIBS
28185 # Solaris 9 and 10 need -lgen to get the eaccess function.
28186 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
28187 # programs in the package would end up linked with that potentially-shared
28188 # library, inducing unnecessary run-time overhead.
28189 LIB_EACCESS=
28191 gl_saved_libs=$LIBS
28192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
28193 $as_echo_n "checking for library containing eaccess... " >&6; }
28194 if test "${ac_cv_search_eaccess+set}" = set; then :
28195 $as_echo_n "(cached) " >&6
28196 else
28197 ac_func_search_save_LIBS=$LIBS
28198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28199 /* end confdefs.h. */
28201 /* Override any GCC internal prototype to avoid an error.
28202 Use char because int might match the return type of a GCC
28203 builtin and then its argument prototype would still apply. */
28204 #ifdef __cplusplus
28205 extern "C"
28206 #endif
28207 char eaccess ();
28209 main ()
28211 return eaccess ();
28213 return 0;
28215 _ACEOF
28216 for ac_lib in '' gen; do
28217 if test -z "$ac_lib"; then
28218 ac_res="none required"
28219 else
28220 ac_res=-l$ac_lib
28221 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
28223 if ac_fn_c_try_link "$LINENO"; then :
28224 ac_cv_search_eaccess=$ac_res
28226 rm -f core conftest.err conftest.$ac_objext \
28227 conftest$ac_exeext
28228 if test "${ac_cv_search_eaccess+set}" = set; then :
28229 break
28231 done
28232 if test "${ac_cv_search_eaccess+set}" = set; then :
28234 else
28235 ac_cv_search_eaccess=no
28237 rm conftest.$ac_ext
28238 LIBS=$ac_func_search_save_LIBS
28240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
28241 $as_echo "$ac_cv_search_eaccess" >&6; }
28242 ac_res=$ac_cv_search_eaccess
28243 if test "$ac_res" != no; then :
28244 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28245 test "$ac_cv_search_eaccess" = "none required" ||
28246 LIB_EACCESS=$ac_cv_search_eaccess
28249 for ac_func in eaccess
28250 do :
28251 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
28252 if test "x$ac_cv_func_eaccess" = x""yes; then :
28253 cat >>confdefs.h <<_ACEOF
28254 #define HAVE_EACCESS 1
28255 _ACEOF
28258 done
28260 LIBS=$gl_saved_libs
28268 GNULIB_EUIDACCESS=1
28274 gl_gnulib_enabled_euidaccess=true
28275 if test $HAVE_EUIDACCESS = 0; then
28276 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
28278 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
28279 if test $HAVE_EUIDACCESS = 0; then
28280 func_gl_gnulib_m4code_stat
28284 func_gl_gnulib_m4code_getdtablesize ()
28286 if ! $gl_gnulib_enabled_getdtablesize; then
28290 if test $ac_cv_func_getdtablesize != yes; then
28291 HAVE_GETDTABLESIZE=0
28294 if test $HAVE_GETDTABLESIZE = 0; then
28303 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
28312 GNULIB_GETDTABLESIZE=1
28318 gl_gnulib_enabled_getdtablesize=true
28321 func_gl_gnulib_m4code_getgroups ()
28323 if ! $gl_gnulib_enabled_getgroups; then
28329 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28330 if test "x$ac_cv_func_getgroups" = x""yes; then :
28335 # If we don't yet have getgroups, see if it's in -lbsd.
28336 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28337 ac_save_LIBS=$LIBS
28338 if test $ac_cv_func_getgroups = no; then
28339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28340 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28341 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28342 $as_echo_n "(cached) " >&6
28343 else
28344 ac_check_lib_save_LIBS=$LIBS
28345 LIBS="-lbsd $LIBS"
28346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28347 /* end confdefs.h. */
28349 /* Override any GCC internal prototype to avoid an error.
28350 Use char because int might match the return type of a GCC
28351 builtin and then its argument prototype would still apply. */
28352 #ifdef __cplusplus
28353 extern "C"
28354 #endif
28355 char getgroups ();
28357 main ()
28359 return getgroups ();
28361 return 0;
28363 _ACEOF
28364 if ac_fn_c_try_link "$LINENO"; then :
28365 ac_cv_lib_bsd_getgroups=yes
28366 else
28367 ac_cv_lib_bsd_getgroups=no
28369 rm -f core conftest.err conftest.$ac_objext \
28370 conftest$ac_exeext conftest.$ac_ext
28371 LIBS=$ac_check_lib_save_LIBS
28373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28374 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28375 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28376 GETGROUPS_LIB=-lbsd
28381 # Run the program to test the functionality of the system-supplied
28382 # getgroups function only if there is such a function.
28383 if test $ac_cv_func_getgroups = yes; then
28384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28385 $as_echo_n "checking for working getgroups... " >&6; }
28386 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28387 $as_echo_n "(cached) " >&6
28388 else
28389 if test "$cross_compiling" = yes; then :
28390 case "$host_os" in # ((
28391 # Guess yes on glibc systems.
28392 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28393 # If we don't know, assume the worst.
28394 *) ac_cv_func_getgroups_works="guessing no" ;;
28395 esac
28397 else
28398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28399 /* end confdefs.h. */
28400 $ac_includes_default
28402 main ()
28404 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28405 return getgroups (0, 0) == -1;
28407 return 0;
28410 _ACEOF
28411 if ac_fn_c_try_run "$LINENO"; then :
28412 ac_cv_func_getgroups_works=yes
28413 else
28414 ac_cv_func_getgroups_works=no
28416 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28417 conftest.$ac_objext conftest.beam conftest.$ac_ext
28422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28423 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28424 else
28425 ac_cv_func_getgroups_works=no
28427 case "$ac_cv_func_getgroups_works" in
28428 *yes)
28430 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28433 esac
28434 LIBS=$ac_save_LIBS
28436 if test $ac_cv_func_getgroups != yes; then
28437 HAVE_GETGROUPS=0
28438 else
28439 if test "$ac_cv_type_getgroups" != gid_t \
28440 || { case "$ac_cv_func_getgroups_works" in
28441 *yes) false;;
28442 *) true;;
28443 esac
28444 }; then
28445 REPLACE_GETGROUPS=1
28447 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
28449 else
28450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
28451 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
28452 if test "${gl_cv_func_getgroups_works+set}" = set; then :
28453 $as_echo_n "(cached) " >&6
28454 else
28455 if test "$cross_compiling" = yes; then :
28456 case "$host_os" in
28457 # Guess yes on glibc systems.
28458 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
28459 # If we don't know, assume the worst.
28460 *) gl_cv_func_getgroups_works="guessing no" ;;
28461 esac
28463 else
28464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28465 /* end confdefs.h. */
28466 $ac_includes_default
28468 main ()
28470 int size = getgroups (0, 0);
28471 gid_t *list = malloc (size * sizeof *list);
28472 return getgroups (-1, list) != -1;
28474 return 0;
28476 _ACEOF
28477 if ac_fn_c_try_run "$LINENO"; then :
28478 gl_cv_func_getgroups_works=yes
28479 else
28480 gl_cv_func_getgroups_works=no
28482 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28483 conftest.$ac_objext conftest.beam conftest.$ac_ext
28487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
28488 $as_echo "$gl_cv_func_getgroups_works" >&6; }
28489 case "$gl_cv_func_getgroups_works" in
28490 *yes) ;;
28491 *) REPLACE_GETGROUPS=1 ;;
28492 esac
28495 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
28497 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
28506 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
28514 GNULIB_GETGROUPS=1
28520 gl_gnulib_enabled_getgroups=true
28523 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
28525 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28528 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
28531 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
28533 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28539 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
28540 if test "x$ac_cv_func_group_member" = x""yes; then :
28542 else
28544 HAVE_GROUP_MEMBER=0
28549 if test $HAVE_GROUP_MEMBER = 0; then
28558 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
28569 GNULIB_GROUP_MEMBER=1
28575 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
28576 if test $HAVE_GROUP_MEMBER = 0; then
28577 func_gl_gnulib_m4code_getgroups
28579 if test $HAVE_GROUP_MEMBER = 0; then
28580 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
28584 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
28586 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28587 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
28590 func_gl_gnulib_m4code_pathmax ()
28592 if ! $gl_gnulib_enabled_pathmax; then
28596 gl_gnulib_enabled_pathmax=true
28599 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
28601 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28602 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
28605 func_gl_gnulib_m4code_secure_getenv ()
28607 if ! $gl_gnulib_enabled_secure_getenv; then
28613 if test $ac_cv_func_secure_getenv = no; then
28614 HAVE_SECURE_GETENV=0
28617 if test $HAVE_SECURE_GETENV = 0; then
28626 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
28629 for ac_func in __secure_getenv
28630 do :
28631 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
28632 if test "x$ac_cv_func___secure_getenv" = x""yes; then :
28633 cat >>confdefs.h <<_ACEOF
28634 #define HAVE___SECURE_GETENV 1
28635 _ACEOF
28638 done
28640 if test $ac_cv_func___secure_getenv = no; then
28641 for ac_func in issetugid
28642 do :
28643 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
28644 if test "x$ac_cv_func_issetugid" = x""yes; then :
28645 cat >>confdefs.h <<_ACEOF
28646 #define HAVE_ISSETUGID 1
28647 _ACEOF
28650 done
28660 GNULIB_SECURE_GETENV=1
28666 gl_gnulib_enabled_secure_getenv=true
28669 func_gl_gnulib_m4code_stat ()
28671 if ! $gl_gnulib_enabled_stat; then
28675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
28676 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
28677 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
28678 $as_echo_n "(cached) " >&6
28679 else
28680 if test "$cross_compiling" = yes; then :
28681 case $host_os in
28682 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
28683 *) gl_cv_func_stat_dir_slash="guessing yes";;
28684 esac
28685 else
28686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28687 /* end confdefs.h. */
28688 #include <sys/stat.h>
28691 main ()
28693 struct stat st; return stat (".", &st) != stat ("./", &st);
28695 return 0;
28697 _ACEOF
28698 if ac_fn_c_try_run "$LINENO"; then :
28699 gl_cv_func_stat_dir_slash=yes
28700 else
28701 gl_cv_func_stat_dir_slash=no
28703 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28704 conftest.$ac_objext conftest.beam conftest.$ac_ext
28708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
28709 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
28710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28711 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28712 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
28713 $as_echo_n "(cached) " >&6
28714 else
28715 touch conftest.tmp
28716 # Assume that if we have lstat, we can also check symlinks.
28717 if test $ac_cv_func_lstat = yes; then
28718 ln -s conftest.tmp conftest.lnk
28720 if test "$cross_compiling" = yes; then :
28721 case "$host_os" in
28722 # Guess yes on glibc systems.
28723 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28724 # If we don't know, assume the worst.
28725 *) gl_cv_func_stat_file_slash="guessing no" ;;
28726 esac
28728 else
28729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28730 /* end confdefs.h. */
28731 #include <sys/stat.h>
28734 main ()
28736 int result = 0;
28737 struct stat st;
28738 if (!stat ("conftest.tmp/", &st))
28739 result |= 1;
28740 #if HAVE_LSTAT
28741 if (!stat ("conftest.lnk/", &st))
28742 result |= 2;
28743 #endif
28744 return result;
28747 return 0;
28749 _ACEOF
28750 if ac_fn_c_try_run "$LINENO"; then :
28751 gl_cv_func_stat_file_slash=yes
28752 else
28753 gl_cv_func_stat_file_slash=no
28755 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28756 conftest.$ac_objext conftest.beam conftest.$ac_ext
28759 rm -f conftest.tmp conftest.lnk
28761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28762 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28763 case $gl_cv_func_stat_dir_slash in
28764 *no) REPLACE_STAT=1
28766 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28768 esac
28769 case $gl_cv_func_stat_file_slash in
28770 *no) REPLACE_STAT=1
28772 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28774 esac
28776 if test $REPLACE_STAT = 1; then
28785 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28794 GNULIB_STAT=1
28800 gl_gnulib_enabled_stat=true
28801 if test $REPLACE_STAT = 1; then
28802 func_gl_gnulib_m4code_dosname
28804 if test $REPLACE_STAT = 1; then
28805 func_gl_gnulib_m4code_pathmax
28809 func_gl_gnulib_m4code_strtoll ()
28811 if ! $gl_gnulib_enabled_strtoll; then
28815 if test "$ac_cv_type_long_long_int" = yes; then
28816 for ac_func in strtoll
28817 do :
28818 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28819 if test "x$ac_cv_func_strtoll" = x""yes; then :
28820 cat >>confdefs.h <<_ACEOF
28821 #define HAVE_STRTOLL 1
28822 _ACEOF
28825 done
28827 if test $ac_cv_func_strtoll = no; then
28828 HAVE_STRTOLL=0
28832 if test $HAVE_STRTOLL = 0; then
28841 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28852 GNULIB_STRTOLL=1
28858 gl_gnulib_enabled_strtoll=true
28861 func_gl_gnulib_m4code_strtoull ()
28863 if ! $gl_gnulib_enabled_strtoull; then
28867 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28868 for ac_func in strtoull
28869 do :
28870 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
28871 if test "x$ac_cv_func_strtoull" = x""yes; then :
28872 cat >>confdefs.h <<_ACEOF
28873 #define HAVE_STRTOULL 1
28874 _ACEOF
28877 done
28879 if test $ac_cv_func_strtoull = no; then
28880 HAVE_STRTOULL=0
28884 if test $HAVE_STRTOULL = 0; then
28893 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
28904 GNULIB_STRTOULL=1
28910 gl_gnulib_enabled_strtoull=true
28913 func_gl_gnulib_m4code_tempname ()
28915 if ! $gl_gnulib_enabled_tempname; then
28921 gl_gnulib_enabled_tempname=true
28922 func_gl_gnulib_m4code_secure_getenv
28925 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
28927 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28928 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
28931 if test $HAVE_FACCESSAT = 0; then
28932 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28934 if test $HAVE_FACCESSAT = 0; then
28935 func_gl_gnulib_m4code_dosname
28937 if test $HAVE_FACCESSAT = 0; then
28938 func_gl_gnulib_m4code_euidaccess
28940 if test $HAVE_FACCESSAT = 0; then
28941 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28943 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
28944 func_gl_gnulib_m4code_getdtablesize
28946 if test $HAVE_FDOPENDIR = 0; then
28947 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28949 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28950 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28952 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28953 func_gl_gnulib_m4code_dosname
28955 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28956 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28958 if test $REPLACE_GETOPT = 1; then
28959 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
28961 if test $REPLACE_LSTAT = 1; then
28962 func_gl_gnulib_m4code_dosname
28964 if test $REPLACE_LSTAT = 1; then
28965 func_gl_gnulib_m4code_stat
28967 if test $HAVE_MKOSTEMP = 0; then
28968 func_gl_gnulib_m4code_tempname
28970 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
28971 func_gl_gnulib_m4code_stat
28973 if test $HAVE_READLINKAT = 0; then
28974 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28976 if test $HAVE_READLINKAT = 0; then
28977 func_gl_gnulib_m4code_dosname
28979 if test $HAVE_READLINKAT = 0; then
28980 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28982 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
28983 func_gl_gnulib_m4code_strtoll
28985 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
28986 func_gl_gnulib_m4code_strtoull
28989 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28990 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
28991 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
28992 else
28993 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
28994 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
28997 if $gl_gnulib_enabled_dosname; then
28998 gl_GNULIB_ENABLED_dosname_TRUE=
28999 gl_GNULIB_ENABLED_dosname_FALSE='#'
29000 else
29001 gl_GNULIB_ENABLED_dosname_TRUE='#'
29002 gl_GNULIB_ENABLED_dosname_FALSE=
29005 if $gl_gnulib_enabled_euidaccess; then
29006 gl_GNULIB_ENABLED_euidaccess_TRUE=
29007 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
29008 else
29009 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
29010 gl_GNULIB_ENABLED_euidaccess_FALSE=
29013 if $gl_gnulib_enabled_getdtablesize; then
29014 gl_GNULIB_ENABLED_getdtablesize_TRUE=
29015 gl_GNULIB_ENABLED_getdtablesize_FALSE='#'
29016 else
29017 gl_GNULIB_ENABLED_getdtablesize_TRUE='#'
29018 gl_GNULIB_ENABLED_getdtablesize_FALSE=
29021 if $gl_gnulib_enabled_getgroups; then
29022 gl_GNULIB_ENABLED_getgroups_TRUE=
29023 gl_GNULIB_ENABLED_getgroups_FALSE='#'
29024 else
29025 gl_GNULIB_ENABLED_getgroups_TRUE='#'
29026 gl_GNULIB_ENABLED_getgroups_FALSE=
29029 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
29030 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
29031 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
29032 else
29033 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
29034 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
29037 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
29038 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
29039 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
29040 else
29041 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
29042 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
29045 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
29046 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
29047 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
29048 else
29049 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
29050 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
29053 if $gl_gnulib_enabled_pathmax; then
29054 gl_GNULIB_ENABLED_pathmax_TRUE=
29055 gl_GNULIB_ENABLED_pathmax_FALSE='#'
29056 else
29057 gl_GNULIB_ENABLED_pathmax_TRUE='#'
29058 gl_GNULIB_ENABLED_pathmax_FALSE=
29061 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
29062 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
29063 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
29064 else
29065 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
29066 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
29069 if $gl_gnulib_enabled_secure_getenv; then
29070 gl_GNULIB_ENABLED_secure_getenv_TRUE=
29071 gl_GNULIB_ENABLED_secure_getenv_FALSE='#'
29072 else
29073 gl_GNULIB_ENABLED_secure_getenv_TRUE='#'
29074 gl_GNULIB_ENABLED_secure_getenv_FALSE=
29077 if $gl_gnulib_enabled_stat; then
29078 gl_GNULIB_ENABLED_stat_TRUE=
29079 gl_GNULIB_ENABLED_stat_FALSE='#'
29080 else
29081 gl_GNULIB_ENABLED_stat_TRUE='#'
29082 gl_GNULIB_ENABLED_stat_FALSE=
29085 if $gl_gnulib_enabled_strtoll; then
29086 gl_GNULIB_ENABLED_strtoll_TRUE=
29087 gl_GNULIB_ENABLED_strtoll_FALSE='#'
29088 else
29089 gl_GNULIB_ENABLED_strtoll_TRUE='#'
29090 gl_GNULIB_ENABLED_strtoll_FALSE=
29093 if $gl_gnulib_enabled_strtoull; then
29094 gl_GNULIB_ENABLED_strtoull_TRUE=
29095 gl_GNULIB_ENABLED_strtoull_FALSE='#'
29096 else
29097 gl_GNULIB_ENABLED_strtoull_TRUE='#'
29098 gl_GNULIB_ENABLED_strtoull_FALSE=
29101 if $gl_gnulib_enabled_tempname; then
29102 gl_GNULIB_ENABLED_tempname_TRUE=
29103 gl_GNULIB_ENABLED_tempname_FALSE='#'
29104 else
29105 gl_GNULIB_ENABLED_tempname_TRUE='#'
29106 gl_GNULIB_ENABLED_tempname_FALSE=
29109 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
29110 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
29111 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
29112 else
29113 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
29114 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
29117 # End of code from modules
29127 gltests_libdeps=
29128 gltests_ltlibdeps=
29138 gl_source_base='tests'
29139 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
29141 gl_module_indicator_condition=$gltests_WITNESS
29152 LIBGNU_LIBDEPS="$gl_libdeps"
29154 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
29157 CFLAGS=$SAVE_CFLAGS
29158 LIBS=$SAVE_LIBS
29160 if test "${opsys}" = "mingw32"; then
29161 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
29162 # Remove unneeded switches from the value of CC that goes to Makefiles
29163 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
29166 case "$opsys" in
29167 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
29169 darwin)
29170 ## The -headerpad option tells ld (see man page) to leave room at the
29171 ## end of the header for adding load commands. Needed for dumping.
29172 ## 0x690 is the total size of 30 segment load commands (at 56
29173 ## each); under Cocoa 31 commands are required.
29174 if test "$HAVE_NS" = "yes"; then
29175 libs_nsgui="-framework AppKit"
29176 if test "$NS_IMPL_COCOA" = "yes"; then
29177 libs_nsgui="$libs_nsgui -framework IOKit"
29179 headerpad_extra=6C8
29180 else
29181 libs_nsgui=
29182 headerpad_extra=690
29184 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
29186 ## This is here because src/Makefile.in did some extra fiddling around
29187 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
29188 ## LD_SWITCH_SYSTEM_TEMACS instead,
29189 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
29190 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
29193 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
29194 ## find X at run-time.
29195 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
29196 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
29197 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
29198 ## had different values in configure (in ac_link) and src/Makefile.in.
29199 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
29200 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
29202 mingw32)
29203 ## MinGW64 does not prepend an underscore to symbols, so we must
29204 ## pass a different -entry switch to linker. FIXME: It is better
29205 ## to make the entry points the same by changing unexw32.c.
29206 case "$canonical" in
29207 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
29208 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
29209 esac
29212 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
29214 *) LD_SWITCH_SYSTEM_TEMACS= ;;
29215 esac
29217 if test x$ac_enable_profiling != x ; then
29218 case $opsys in
29219 *freebsd | gnu-linux) ;;
29220 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
29221 esac
29224 LD_SWITCH_SYSTEM_TEMACS="$LDFLAGS_NOCOMBRELOC $LD_SWITCH_SYSTEM_TEMACS"
29228 ## MinGW-specific post-link processing of temacs.
29229 TEMACS_POST_LINK=":"
29230 ADDSECTION=
29231 EMACS_HEAPSIZE=
29232 if test "${opsys}" = "mingw32"; then
29233 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
29234 ADDSECTION="../nt/addsection\$(EXEEXT)"
29235 ## Preload heap size of temacs.exe in MB.
29236 case "$canonical" in
29237 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
29238 *) EMACS_HEAPSIZE=27 ;;
29239 esac
29246 ## Common for all window systems
29247 if test "$window_system" != "none"; then
29249 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
29251 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
29258 #### Report on what we decided to do.
29259 #### Report GTK as a toolkit, even if it doesn't use Xt.
29260 #### It makes printing result more understandable as using GTK sets
29261 #### toolkit_scroll_bars to yes by default.
29262 if test "${HAVE_GTK}" = "yes"; then
29263 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
29266 if test $USE_ACL -ne 0; then
29267 acl_summary="yes $LIB_ACL"
29268 else
29269 acl_summary=no
29272 echo "
29273 Configured for \`${canonical}'.
29275 Where should the build process find the source code? ${srcdir}
29276 What compiler should emacs be built with? ${CC} ${CFLAGS}
29277 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
29278 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
29279 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
29280 What window system should Emacs use? ${window_system}
29281 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
29283 if test -n "${x_includes}"; then
29284 echo " Where do we find X Windows header files? ${x_includes}"
29285 else
29286 echo " Where do we find X Windows header files? Standard dirs"
29288 if test -n "${x_libraries}"; then
29289 echo " Where do we find X Windows libraries? ${x_libraries}"
29290 else
29291 echo " Where do we find X Windows libraries? Standard dirs"
29294 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
29295 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
29296 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
29297 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
29298 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
29299 echo " Does Emacs use -lpng? ${HAVE_PNG}"
29300 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
29301 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
29303 echo " Does Emacs support sound? ${HAVE_SOUND}"
29305 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
29306 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
29307 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
29308 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
29309 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
29310 echo " Does Emacs use access control lists? ${acl_summary}"
29311 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
29312 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
29313 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
29315 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
29316 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
29317 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
29318 echo " Does Emacs use -lxft? ${HAVE_XFT}"
29319 echo " Does Emacs directly use zlib? ${HAVE_ZLIB}"
29321 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
29322 echo
29324 if test -n "${EMACSDATA}"; then
29325 echo " Environment variable EMACSDATA set to: $EMACSDATA"
29327 if test -n "${EMACSDOC}"; then
29328 echo " Environment variable EMACSDOC set to: $EMACSDOC"
29331 echo
29333 if test "$HAVE_NS" = "yes"; then
29334 echo
29335 echo "You must run \"${MAKE-make} install\" in order to test the built application.
29336 The installed application will go to nextstep/Emacs.app and can be
29337 run or moved from there."
29338 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
29339 echo "The application will be fully self-contained."
29340 else
29341 echo "The lisp resources for the application will be installed under ${prefix}.
29342 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
29343 to run if these resources are not installed."
29345 echo
29348 if test "${opsys}" = "cygwin"; then
29349 case `uname -r` in
29350 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
29351 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
29352 echo
29354 esac
29357 # Remove any trailing slashes in these variables.
29358 test "${prefix}" != NONE &&
29359 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
29360 test "${exec_prefix}" != NONE &&
29361 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
29363 if test "$HAVE_NS" = "yes"; then
29364 if test "$NS_IMPL_GNUSTEP" = yes; then
29365 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"
29367 ns_check_file=Resources/Info-gnustep.plist
29368 else
29369 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"
29371 ns_check_file=Contents/Info.plist
29376 SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile nt/Makefile"
29378 ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile nt/Makefile"
29381 opt_makefile=test/automated/Makefile
29383 if test -f "$srcdir/$opt_makefile.in"; then
29384 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29385 ac_config_files="$ac_config_files test/automated/Makefile"
29390 opt_makefile=admin/unidata/Makefile
29392 if test -f "$srcdir/$opt_makefile.in"; then
29393 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29394 ac_config_files="$ac_config_files admin/unidata/Makefile"
29399 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
29403 ac_config_commands="$ac_config_commands src/epaths.h"
29406 ac_config_commands="$ac_config_commands src/.gdbinit"
29409 cat >confcache <<\_ACEOF
29410 # This file is a shell script that caches the results of configure
29411 # tests run on this system so they can be shared between configure
29412 # scripts and configure runs, see configure's option --config-cache.
29413 # It is not useful on other systems. If it contains results you don't
29414 # want to keep, you may remove or edit it.
29416 # config.status only pays attention to the cache file if you give it
29417 # the --recheck option to rerun configure.
29419 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29420 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29421 # following values.
29423 _ACEOF
29425 # The following way of writing the cache mishandles newlines in values,
29426 # but we know of no workaround that is simple, portable, and efficient.
29427 # So, we kill variables containing newlines.
29428 # Ultrix sh set writes to stderr and can't be redirected directly,
29429 # and sets the high bit in the cache file unless we assign to the vars.
29431 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29432 eval ac_val=\$$ac_var
29433 case $ac_val in #(
29434 *${as_nl}*)
29435 case $ac_var in #(
29436 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
29437 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29438 esac
29439 case $ac_var in #(
29440 _ | IFS | as_nl) ;; #(
29441 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29442 *) { eval $ac_var=; unset $ac_var;} ;;
29443 esac ;;
29444 esac
29445 done
29447 (set) 2>&1 |
29448 case $as_nl`(ac_space=' '; set) 2>&1` in #(
29449 *${as_nl}ac_space=\ *)
29450 # `set' does not quote correctly, so add quotes: double-quote
29451 # substitution turns \\\\ into \\, and sed turns \\ into \.
29452 sed -n \
29453 "s/'/'\\\\''/g;
29454 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29455 ;; #(
29457 # `set' quotes correctly as required by POSIX, so do not add quotes.
29458 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29460 esac |
29461 sort
29463 sed '
29464 /^ac_cv_env_/b end
29465 t clear
29466 :clear
29467 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29468 t end
29469 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29470 :end' >>confcache
29471 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29472 if test -w "$cache_file"; then
29473 test "x$cache_file" != "x/dev/null" &&
29474 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
29475 $as_echo "$as_me: updating cache $cache_file" >&6;}
29476 cat confcache >$cache_file
29477 else
29478 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
29479 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29482 rm -f confcache
29484 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29485 # Let make expand exec_prefix.
29486 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29488 DEFS=-DHAVE_CONFIG_H
29490 ac_libobjs=
29491 ac_ltlibobjs=
29492 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29493 # 1. Remove the extension, and $U if already installed.
29494 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29495 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29496 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
29497 # will be set to the directory where LIBOBJS objects are built.
29498 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29499 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
29500 done
29501 LIBOBJS=$ac_libobjs
29503 LTLIBOBJS=$ac_ltlibobjs
29506 if test -n "$EXEEXT"; then
29507 am__EXEEXT_TRUE=
29508 am__EXEEXT_FALSE='#'
29509 else
29510 am__EXEEXT_TRUE='#'
29511 am__EXEEXT_FALSE=
29514 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
29515 as_fn_error "conditional \"AMDEP\" was never defined.
29516 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29518 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
29519 as_fn_error "conditional \"am__fastdepCC\" was never defined.
29520 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29522 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
29523 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
29524 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29526 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
29527 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
29528 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29530 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
29531 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
29532 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29535 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
29536 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
29537 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29539 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
29540 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
29541 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29543 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
29544 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
29545 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29547 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
29548 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
29549 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29551 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
29552 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
29553 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29555 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
29556 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
29557 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29559 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
29560 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
29561 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29563 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
29564 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
29565 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29567 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
29568 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
29569 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29571 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
29572 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
29573 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29575 if test -z "${gl_GNULIB_ENABLED_getdtablesize_TRUE}" && test -z "${gl_GNULIB_ENABLED_getdtablesize_FALSE}"; then
29576 as_fn_error "conditional \"gl_GNULIB_ENABLED_getdtablesize\" was never defined.
29577 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29579 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
29580 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
29581 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29583 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
29584 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
29585 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29587 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
29588 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
29589 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29591 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
29592 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
29593 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29595 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
29596 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
29597 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29599 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
29600 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
29601 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29603 if test -z "${gl_GNULIB_ENABLED_secure_getenv_TRUE}" && test -z "${gl_GNULIB_ENABLED_secure_getenv_FALSE}"; then
29604 as_fn_error "conditional \"gl_GNULIB_ENABLED_secure_getenv\" was never defined.
29605 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29607 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
29608 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
29609 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29611 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
29612 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
29613 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29615 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
29616 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
29617 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29619 if test -z "${gl_GNULIB_ENABLED_tempname_TRUE}" && test -z "${gl_GNULIB_ENABLED_tempname_FALSE}"; then
29620 as_fn_error "conditional \"gl_GNULIB_ENABLED_tempname\" was never defined.
29621 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29623 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
29624 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
29625 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29628 gl_libobjs=
29629 gl_ltlibobjs=
29630 if test -n "$gl_LIBOBJS"; then
29631 # Remove the extension.
29632 sed_drop_objext='s/\.o$//;s/\.obj$//'
29633 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29634 gl_libobjs="$gl_libobjs $i.$ac_objext"
29635 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
29636 done
29638 gl_LIBOBJS=$gl_libobjs
29640 gl_LTLIBOBJS=$gl_ltlibobjs
29644 gltests_libobjs=
29645 gltests_ltlibobjs=
29646 if test -n "$gltests_LIBOBJS"; then
29647 # Remove the extension.
29648 sed_drop_objext='s/\.o$//;s/\.obj$//'
29649 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29650 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
29651 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
29652 done
29654 gltests_LIBOBJS=$gltests_libobjs
29656 gltests_LTLIBOBJS=$gltests_ltlibobjs
29660 : ${CONFIG_STATUS=./config.status}
29661 ac_write_fail=0
29662 ac_clean_files_save=$ac_clean_files
29663 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29664 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29665 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29666 as_write_fail=0
29667 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29668 #! $SHELL
29669 # Generated by $as_me.
29670 # Run this file to recreate the current configuration.
29671 # Compiler output produced by configure, useful for debugging
29672 # configure, is in config.log if it exists.
29674 debug=false
29675 ac_cs_recheck=false
29676 ac_cs_silent=false
29678 SHELL=\${CONFIG_SHELL-$SHELL}
29679 export SHELL
29680 _ASEOF
29681 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29682 ## -------------------- ##
29683 ## M4sh Initialization. ##
29684 ## -------------------- ##
29686 # Be more Bourne compatible
29687 DUALCASE=1; export DUALCASE # for MKS sh
29688 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29689 emulate sh
29690 NULLCMD=:
29691 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29692 # is contrary to our usage. Disable this feature.
29693 alias -g '${1+"$@"}'='"$@"'
29694 setopt NO_GLOB_SUBST
29695 else
29696 case `(set -o) 2>/dev/null` in #(
29697 *posix*) :
29698 set -o posix ;; #(
29699 *) :
29701 esac
29705 as_nl='
29707 export as_nl
29708 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29709 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29710 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29711 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29712 # Prefer a ksh shell builtin over an external printf program on Solaris,
29713 # but without wasting forks for bash or zsh.
29714 if test -z "$BASH_VERSION$ZSH_VERSION" \
29715 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29716 as_echo='print -r --'
29717 as_echo_n='print -rn --'
29718 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29719 as_echo='printf %s\n'
29720 as_echo_n='printf %s'
29721 else
29722 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29723 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29724 as_echo_n='/usr/ucb/echo -n'
29725 else
29726 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29727 as_echo_n_body='eval
29728 arg=$1;
29729 case $arg in #(
29730 *"$as_nl"*)
29731 expr "X$arg" : "X\\(.*\\)$as_nl";
29732 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29733 esac;
29734 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29736 export as_echo_n_body
29737 as_echo_n='sh -c $as_echo_n_body as_echo'
29739 export as_echo_body
29740 as_echo='sh -c $as_echo_body as_echo'
29743 # The user is always right.
29744 if test "${PATH_SEPARATOR+set}" != set; then
29745 PATH_SEPARATOR=:
29746 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29747 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29748 PATH_SEPARATOR=';'
29753 # IFS
29754 # We need space, tab and new line, in precisely that order. Quoting is
29755 # there to prevent editors from complaining about space-tab.
29756 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29757 # splitting by setting IFS to empty value.)
29758 IFS=" "" $as_nl"
29760 # Find who we are. Look in the path if we contain no directory separator.
29761 case $0 in #((
29762 *[\\/]* ) as_myself=$0 ;;
29763 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29764 for as_dir in $PATH
29766 IFS=$as_save_IFS
29767 test -z "$as_dir" && as_dir=.
29768 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29769 done
29770 IFS=$as_save_IFS
29773 esac
29774 # We did not find ourselves, most probably we were run as `sh COMMAND'
29775 # in which case we are not to be found in the path.
29776 if test "x$as_myself" = x; then
29777 as_myself=$0
29779 if test ! -f "$as_myself"; then
29780 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29781 exit 1
29784 # Unset variables that we do not need and which cause bugs (e.g. in
29785 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29786 # suppresses any "Segmentation fault" message there. '((' could
29787 # trigger a bug in pdksh 5.2.14.
29788 for as_var in BASH_ENV ENV MAIL MAILPATH
29789 do eval test x\${$as_var+set} = xset \
29790 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29791 done
29792 PS1='$ '
29793 PS2='> '
29794 PS4='+ '
29796 # NLS nuisances.
29797 LC_ALL=C
29798 export LC_ALL
29799 LANGUAGE=C
29800 export LANGUAGE
29802 # CDPATH.
29803 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29806 # as_fn_error ERROR [LINENO LOG_FD]
29807 # ---------------------------------
29808 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29809 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29810 # script with status $?, using 1 if that was 0.
29811 as_fn_error ()
29813 as_status=$?; test $as_status -eq 0 && as_status=1
29814 if test "$3"; then
29815 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29816 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29818 $as_echo "$as_me: error: $1" >&2
29819 as_fn_exit $as_status
29820 } # as_fn_error
29823 # as_fn_set_status STATUS
29824 # -----------------------
29825 # Set $? to STATUS, without forking.
29826 as_fn_set_status ()
29828 return $1
29829 } # as_fn_set_status
29831 # as_fn_exit STATUS
29832 # -----------------
29833 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29834 as_fn_exit ()
29836 set +e
29837 as_fn_set_status $1
29838 exit $1
29839 } # as_fn_exit
29841 # as_fn_unset VAR
29842 # ---------------
29843 # Portably unset VAR.
29844 as_fn_unset ()
29846 { eval $1=; unset $1;}
29848 as_unset=as_fn_unset
29849 # as_fn_append VAR VALUE
29850 # ----------------------
29851 # Append the text in VALUE to the end of the definition contained in VAR. Take
29852 # advantage of any shell optimizations that allow amortized linear growth over
29853 # repeated appends, instead of the typical quadratic growth present in naive
29854 # implementations.
29855 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29856 eval 'as_fn_append ()
29858 eval $1+=\$2
29860 else
29861 as_fn_append ()
29863 eval $1=\$$1\$2
29865 fi # as_fn_append
29867 # as_fn_arith ARG...
29868 # ------------------
29869 # Perform arithmetic evaluation on the ARGs, and store the result in the
29870 # global $as_val. Take advantage of shells that can avoid forks. The arguments
29871 # must be portable across $(()) and expr.
29872 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29873 eval 'as_fn_arith ()
29875 as_val=$(( $* ))
29877 else
29878 as_fn_arith ()
29880 as_val=`expr "$@" || test $? -eq 1`
29882 fi # as_fn_arith
29885 if expr a : '\(a\)' >/dev/null 2>&1 &&
29886 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29887 as_expr=expr
29888 else
29889 as_expr=false
29892 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29893 as_basename=basename
29894 else
29895 as_basename=false
29898 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29899 as_dirname=dirname
29900 else
29901 as_dirname=false
29904 as_me=`$as_basename -- "$0" ||
29905 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29906 X"$0" : 'X\(//\)$' \| \
29907 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29908 $as_echo X/"$0" |
29909 sed '/^.*\/\([^/][^/]*\)\/*$/{
29910 s//\1/
29913 /^X\/\(\/\/\)$/{
29914 s//\1/
29917 /^X\/\(\/\).*/{
29918 s//\1/
29921 s/.*/./; q'`
29923 # Avoid depending upon Character Ranges.
29924 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29925 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29926 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29927 as_cr_digits='0123456789'
29928 as_cr_alnum=$as_cr_Letters$as_cr_digits
29930 ECHO_C= ECHO_N= ECHO_T=
29931 case `echo -n x` in #(((((
29932 -n*)
29933 case `echo 'xy\c'` in
29934 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29935 xy) ECHO_C='\c';;
29936 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29937 ECHO_T=' ';;
29938 esac;;
29940 ECHO_N='-n';;
29941 esac
29943 rm -f conf$$ conf$$.exe conf$$.file
29944 if test -d conf$$.dir; then
29945 rm -f conf$$.dir/conf$$.file
29946 else
29947 rm -f conf$$.dir
29948 mkdir conf$$.dir 2>/dev/null
29950 if (echo >conf$$.file) 2>/dev/null; then
29951 if ln -s conf$$.file conf$$ 2>/dev/null; then
29952 as_ln_s='ln -s'
29953 # ... but there are two gotchas:
29954 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29955 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29956 # In both cases, we have to default to `cp -p'.
29957 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29958 as_ln_s='cp -p'
29959 elif ln conf$$.file conf$$ 2>/dev/null; then
29960 as_ln_s=ln
29961 else
29962 as_ln_s='cp -p'
29964 else
29965 as_ln_s='cp -p'
29967 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29968 rmdir conf$$.dir 2>/dev/null
29971 # as_fn_mkdir_p
29972 # -------------
29973 # Create "$as_dir" as a directory, including parents if necessary.
29974 as_fn_mkdir_p ()
29977 case $as_dir in #(
29978 -*) as_dir=./$as_dir;;
29979 esac
29980 test -d "$as_dir" || eval $as_mkdir_p || {
29981 as_dirs=
29982 while :; do
29983 case $as_dir in #(
29984 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29985 *) as_qdir=$as_dir;;
29986 esac
29987 as_dirs="'$as_qdir' $as_dirs"
29988 as_dir=`$as_dirname -- "$as_dir" ||
29989 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29990 X"$as_dir" : 'X\(//\)[^/]' \| \
29991 X"$as_dir" : 'X\(//\)$' \| \
29992 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29993 $as_echo X"$as_dir" |
29994 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29995 s//\1/
29998 /^X\(\/\/\)[^/].*/{
29999 s//\1/
30002 /^X\(\/\/\)$/{
30003 s//\1/
30006 /^X\(\/\).*/{
30007 s//\1/
30010 s/.*/./; q'`
30011 test -d "$as_dir" && break
30012 done
30013 test -z "$as_dirs" || eval "mkdir $as_dirs"
30014 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
30017 } # as_fn_mkdir_p
30018 if mkdir -p . 2>/dev/null; then
30019 as_mkdir_p='mkdir -p "$as_dir"'
30020 else
30021 test -d ./-p && rmdir ./-p
30022 as_mkdir_p=false
30025 if test -x / >/dev/null 2>&1; then
30026 as_test_x='test -x'
30027 else
30028 if ls -dL / >/dev/null 2>&1; then
30029 as_ls_L_option=L
30030 else
30031 as_ls_L_option=
30033 as_test_x='
30034 eval sh -c '\''
30035 if test -d "$1"; then
30036 test -d "$1/.";
30037 else
30038 case $1 in #(
30039 -*)set "./$1";;
30040 esac;
30041 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
30042 ???[sx]*):;;*)false;;esac;fi
30043 '\'' sh
30046 as_executable_p=$as_test_x
30048 # Sed expression to map a string onto a valid CPP name.
30049 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30051 # Sed expression to map a string onto a valid variable name.
30052 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30055 exec 6>&1
30056 ## ----------------------------------- ##
30057 ## Main body of $CONFIG_STATUS script. ##
30058 ## ----------------------------------- ##
30059 _ASEOF
30060 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
30062 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30063 # Save the log message, to keep $0 and so on meaningful, and to
30064 # report actual input values of CONFIG_FILES etc. instead of their
30065 # values after options handling.
30066 ac_log="
30067 This file was extended by emacs $as_me 24.3.50, which was
30068 generated by GNU Autoconf 2.65. Invocation command line was
30070 CONFIG_FILES = $CONFIG_FILES
30071 CONFIG_HEADERS = $CONFIG_HEADERS
30072 CONFIG_LINKS = $CONFIG_LINKS
30073 CONFIG_COMMANDS = $CONFIG_COMMANDS
30074 $ $0 $@
30076 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30079 _ACEOF
30081 case $ac_config_files in *"
30082 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30083 esac
30085 case $ac_config_headers in *"
30086 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30087 esac
30090 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30091 # Files that config.status was made for.
30092 config_files="$ac_config_files"
30093 config_headers="$ac_config_headers"
30094 config_commands="$ac_config_commands"
30096 _ACEOF
30098 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30099 ac_cs_usage="\
30100 \`$as_me' instantiates files and other configuration actions
30101 from templates according to the current configuration. Unless the files
30102 and actions are specified as TAGs, all are instantiated by default.
30104 Usage: $0 [OPTION]... [TAG]...
30106 -h, --help print this help, then exit
30107 -V, --version print version number and configuration settings, then exit
30108 --config print configuration, then exit
30109 -q, --quiet, --silent
30110 do not print progress messages
30111 -d, --debug don't remove temporary files
30112 --recheck update $as_me by reconfiguring in the same conditions
30113 --file=FILE[:TEMPLATE]
30114 instantiate the configuration file FILE
30115 --header=FILE[:TEMPLATE]
30116 instantiate the configuration header FILE
30118 Configuration files:
30119 $config_files
30121 Configuration headers:
30122 $config_headers
30124 Configuration commands:
30125 $config_commands
30127 Report bugs to the package provider."
30129 _ACEOF
30130 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30131 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
30132 ac_cs_version="\\
30133 emacs config.status 24.3.50
30134 configured by $0, generated by GNU Autoconf 2.65,
30135 with options \\"\$ac_cs_config\\"
30137 Copyright (C) 2009 Free Software Foundation, Inc.
30138 This config.status script is free software; the Free Software Foundation
30139 gives unlimited permission to copy, distribute and modify it."
30141 ac_pwd='$ac_pwd'
30142 srcdir='$srcdir'
30143 INSTALL='$INSTALL'
30144 MKDIR_P='$MKDIR_P'
30145 AWK='$AWK'
30146 test -n "\$AWK" || AWK=awk
30147 _ACEOF
30149 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30150 # The default lists apply if the user does not specify any file.
30151 ac_need_defaults=:
30152 while test $# != 0
30154 case $1 in
30155 --*=*)
30156 ac_option=`expr "X$1" : 'X\([^=]*\)='`
30157 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30158 ac_shift=:
30161 ac_option=$1
30162 ac_optarg=$2
30163 ac_shift=shift
30165 esac
30167 case $ac_option in
30168 # Handling of the options.
30169 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30170 ac_cs_recheck=: ;;
30171 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30172 $as_echo "$ac_cs_version"; exit ;;
30173 --config | --confi | --conf | --con | --co | --c )
30174 $as_echo "$ac_cs_config"; exit ;;
30175 --debug | --debu | --deb | --de | --d | -d )
30176 debug=: ;;
30177 --file | --fil | --fi | --f )
30178 $ac_shift
30179 case $ac_optarg in
30180 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30181 esac
30182 as_fn_append CONFIG_FILES " '$ac_optarg'"
30183 ac_need_defaults=false;;
30184 --header | --heade | --head | --hea )
30185 $ac_shift
30186 case $ac_optarg in
30187 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30188 esac
30189 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
30190 ac_need_defaults=false;;
30191 --he | --h)
30192 # Conflict between --help and --header
30193 as_fn_error "ambiguous option: \`$1'
30194 Try \`$0 --help' for more information.";;
30195 --help | --hel | -h )
30196 $as_echo "$ac_cs_usage"; exit ;;
30197 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30198 | -silent | --silent | --silen | --sile | --sil | --si | --s)
30199 ac_cs_silent=: ;;
30201 # This is an error.
30202 -*) as_fn_error "unrecognized option: \`$1'
30203 Try \`$0 --help' for more information." ;;
30205 *) as_fn_append ac_config_targets " $1"
30206 ac_need_defaults=false ;;
30208 esac
30209 shift
30210 done
30212 ac_configure_extra_args=
30214 if $ac_cs_silent; then
30215 exec 6>/dev/null
30216 ac_configure_extra_args="$ac_configure_extra_args --silent"
30219 _ACEOF
30220 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30221 if \$ac_cs_recheck; then
30222 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30223 shift
30224 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30225 CONFIG_SHELL='$SHELL'
30226 export CONFIG_SHELL
30227 exec "\$@"
30230 _ACEOF
30231 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30232 exec 5>>config.log
30234 echo
30235 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30236 ## Running $as_me. ##
30237 _ASBOX
30238 $as_echo "$ac_log"
30239 } >&5
30241 _ACEOF
30242 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30244 # INIT-COMMANDS
30246 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
30247 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
30249 _ACEOF
30251 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30253 # Handling of arguments.
30254 for ac_config_target in $ac_config_targets
30256 case $ac_config_target in
30257 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
30258 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
30259 "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" ;;
30260 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
30261 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
30262 "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" ;;
30263 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
30264 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
30265 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
30266 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
30267 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
30268 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
30269 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
30270 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
30271 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
30272 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
30273 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
30274 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
30275 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
30276 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
30277 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
30278 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
30279 "src/epaths.h") CONFIG_COMMANDS="$CONFIG_COMMANDS src/epaths.h" ;;
30280 "src/.gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS src/.gdbinit" ;;
30282 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
30283 esac
30284 done
30287 # If the user did not use the arguments to specify the items to instantiate,
30288 # then the envvar interface is used. Set only those that are not.
30289 # We use the long form for the default assignment because of an extremely
30290 # bizarre bug on SunOS 4.1.3.
30291 if $ac_need_defaults; then
30292 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30293 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30294 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30297 # Have a temporary directory for convenience. Make it in the build tree
30298 # simply because there is no reason against having it here, and in addition,
30299 # creating and moving files from /tmp can sometimes cause problems.
30300 # Hook for its removal unless debugging.
30301 # Note that there is a small window in which the directory will not be cleaned:
30302 # after its creation but before its name has been assigned to `$tmp'.
30303 $debug ||
30305 tmp=
30306 trap 'exit_status=$?
30307 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30309 trap 'as_fn_exit 1' 1 2 13 15
30311 # Create a (secure) tmp directory for tmp files.
30314 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30315 test -n "$tmp" && test -d "$tmp"
30316 } ||
30318 tmp=./conf$$-$RANDOM
30319 (umask 077 && mkdir "$tmp")
30320 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
30322 # Set up the scripts for CONFIG_FILES section.
30323 # No need to generate them if there are no CONFIG_FILES.
30324 # This happens for instance with `./config.status config.h'.
30325 if test -n "$CONFIG_FILES"; then
30327 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
30328 ac_cs_awk_getline=:
30329 ac_cs_awk_pipe_init=
30330 ac_cs_awk_read_file='
30331 while ((getline aline < (F[key])) > 0)
30332 print(aline)
30333 close(F[key])'
30334 ac_cs_awk_pipe_fini=
30335 else
30336 ac_cs_awk_getline=false
30337 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
30338 ac_cs_awk_read_file='
30339 print "|#_!!_#|"
30340 print "cat " F[key] " &&"
30341 '$ac_cs_awk_pipe_init
30342 # The final `:' finishes the AND list.
30343 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
30345 ac_cr=`echo X | tr X '\015'`
30346 # On cygwin, bash can eat \r inside `` if the user requested igncr.
30347 # But we know of no other shell where ac_cr would be empty at this
30348 # point, so we can use a bashism as a fallback.
30349 if test "x$ac_cr" = x; then
30350 eval ac_cr=\$\'\\r\'
30352 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30353 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30354 ac_cs_awk_cr='\r'
30355 else
30356 ac_cs_awk_cr=$ac_cr
30359 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30360 _ACEOF
30362 # Create commands to substitute file output variables.
30364 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
30365 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
30366 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
30367 echo "_ACAWK" &&
30368 echo "_ACEOF"
30369 } >conf$$files.sh &&
30370 . ./conf$$files.sh ||
30371 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30372 rm -f conf$$files.sh
30375 echo "cat >conf$$subs.awk <<_ACEOF" &&
30376 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30377 echo "_ACEOF"
30378 } >conf$$subs.sh ||
30379 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30380 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30381 ac_delim='%!_!# '
30382 for ac_last_try in false false false false false :; do
30383 . ./conf$$subs.sh ||
30384 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30386 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30387 if test $ac_delim_n = $ac_delim_num; then
30388 break
30389 elif $ac_last_try; then
30390 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30391 else
30392 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30394 done
30395 rm -f conf$$subs.sh
30397 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30398 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30399 _ACEOF
30400 sed -n '
30402 s/^/S["/; s/!.*/"]=/
30405 s/^[^!]*!//
30406 :repl
30407 t repl
30408 s/'"$ac_delim"'$//
30409 t delim
30412 s/\(.\{148\}\)..*/\1/
30413 t more1
30414 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30417 b repl
30418 :more1
30419 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30422 s/.\{148\}//
30423 t nl
30424 :delim
30426 s/\(.\{148\}\)..*/\1/
30427 t more2
30428 s/["\\]/\\&/g; s/^/"/; s/$/"/
30431 :more2
30432 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30435 s/.\{148\}//
30436 t delim
30437 ' <conf$$subs.awk | sed '
30438 /^[^""]/{
30440 s/\n//
30442 ' >>$CONFIG_STATUS || ac_write_fail=1
30443 rm -f conf$$subs.awk
30444 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30445 _ACAWK
30446 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30447 for (key in S) S_is_set[key] = 1
30448 FS = "\a"
30449 \$ac_cs_awk_pipe_init
30452 line = $ 0
30453 nfields = split(line, field, "@")
30454 substed = 0
30455 len = length(field[1])
30456 for (i = 2; i < nfields; i++) {
30457 key = field[i]
30458 keylen = length(key)
30459 if (S_is_set[key]) {
30460 value = S[key]
30461 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30462 len += length(value) + length(field[++i])
30463 substed = 1
30464 } else
30465 len += 1 + keylen
30467 if (nfields == 3 && !substed) {
30468 key = field[2]
30469 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
30470 \$ac_cs_awk_read_file
30471 next
30474 print line
30476 \$ac_cs_awk_pipe_fini
30477 _ACAWK
30478 _ACEOF
30479 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30480 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30481 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30482 else
30484 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30485 || as_fn_error "could not setup config files machinery" "$LINENO" 5
30486 _ACEOF
30488 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30489 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30490 # trailing colons and then remove the whole line if VPATH becomes empty
30491 # (actually we leave an empty line to preserve line numbers).
30492 if test "x$srcdir" = x.; then
30493 ac_vpsub='/^[ ]*VPATH[ ]*=/{
30494 s/:*\$(srcdir):*/:/
30495 s/:*\${srcdir}:*/:/
30496 s/:*@srcdir@:*/:/
30497 s/^\([^=]*=[ ]*\):*/\1/
30498 s/:*$//
30499 s/^[^=]*=[ ]*$//
30503 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30504 fi # test -n "$CONFIG_FILES"
30506 # Set up the scripts for CONFIG_HEADERS section.
30507 # No need to generate them if there are no CONFIG_HEADERS.
30508 # This happens for instance with `./config.status Makefile'.
30509 if test -n "$CONFIG_HEADERS"; then
30510 cat >"$tmp/defines.awk" <<\_ACAWK ||
30511 BEGIN {
30512 _ACEOF
30514 # Transform confdefs.h into an awk script `defines.awk', embedded as
30515 # here-document in config.status, that substitutes the proper values into
30516 # config.h.in to produce config.h.
30518 # Create a delimiter string that does not exist in confdefs.h, to ease
30519 # handling of long lines.
30520 ac_delim='%!_!# '
30521 for ac_last_try in false false :; do
30522 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30523 if test -z "$ac_t"; then
30524 break
30525 elif $ac_last_try; then
30526 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
30527 else
30528 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30530 done
30532 # For the awk script, D is an array of macro values keyed by name,
30533 # likewise P contains macro parameters if any. Preserve backslash
30534 # newline sequences.
30536 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30537 sed -n '
30538 s/.\{148\}/&'"$ac_delim"'/g
30539 t rset
30540 :rset
30541 s/^[ ]*#[ ]*define[ ][ ]*/ /
30542 t def
30544 :def
30545 s/\\$//
30546 t bsnl
30547 s/["\\]/\\&/g
30548 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30549 D["\1"]=" \3"/p
30550 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
30552 :bsnl
30553 s/["\\]/\\&/g
30554 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30555 D["\1"]=" \3\\\\\\n"\\/p
30556 t cont
30557 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30558 t cont
30560 :cont
30562 s/.\{148\}/&'"$ac_delim"'/g
30563 t clear
30564 :clear
30565 s/\\$//
30566 t bsnlc
30567 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30569 :bsnlc
30570 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30571 b cont
30572 ' <confdefs.h | sed '
30573 s/'"$ac_delim"'/"\\\
30574 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30576 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30577 for (key in D) D_is_set[key] = 1
30578 FS = "\a"
30580 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30581 line = \$ 0
30582 split(line, arg, " ")
30583 if (arg[1] == "#") {
30584 defundef = arg[2]
30585 mac1 = arg[3]
30586 } else {
30587 defundef = substr(arg[1], 2)
30588 mac1 = arg[2]
30590 split(mac1, mac2, "(") #)
30591 macro = mac2[1]
30592 prefix = substr(line, 1, index(line, defundef) - 1)
30593 if (D_is_set[macro]) {
30594 # Preserve the white space surrounding the "#".
30595 print prefix "define", macro P[macro] D[macro]
30596 next
30597 } else {
30598 # Replace #undef with comments. This is necessary, for example,
30599 # in the case of _POSIX_SOURCE, which is predefined and required
30600 # on some systems where configure will not decide to define it.
30601 if (defundef == "undef") {
30602 print "/*", prefix defundef, macro, "*/"
30603 next
30607 { print }
30608 _ACAWK
30609 _ACEOF
30610 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30611 as_fn_error "could not setup config headers machinery" "$LINENO" 5
30612 fi # test -n "$CONFIG_HEADERS"
30615 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
30616 shift
30617 for ac_tag
30619 case $ac_tag in
30620 :[FHLC]) ac_mode=$ac_tag; continue;;
30621 esac
30622 case $ac_mode$ac_tag in
30623 :[FHL]*:*);;
30624 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
30625 :[FH]-) ac_tag=-:-;;
30626 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30627 esac
30628 ac_save_IFS=$IFS
30629 IFS=:
30630 set x $ac_tag
30631 IFS=$ac_save_IFS
30632 shift
30633 ac_file=$1
30634 shift
30636 case $ac_mode in
30637 :L) ac_source=$1;;
30638 :[FH])
30639 ac_file_inputs=
30640 for ac_f
30642 case $ac_f in
30643 -) ac_f="$tmp/stdin";;
30644 *) # Look for the file first in the build tree, then in the source tree
30645 # (if the path is not absolute). The absolute path cannot be DOS-style,
30646 # because $ac_f cannot contain `:'.
30647 test -f "$ac_f" ||
30648 case $ac_f in
30649 [\\/$]*) false;;
30650 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30651 esac ||
30652 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30653 esac
30654 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30655 as_fn_append ac_file_inputs " '$ac_f'"
30656 done
30658 # Let's still pretend it is `configure' which instantiates (i.e., don't
30659 # use $as_me), people would be surprised to read:
30660 # /* config.h. Generated by config.status. */
30661 configure_input='Generated from '`
30662 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30663 `' by configure.'
30664 if test x"$ac_file" != x-; then
30665 configure_input="$ac_file. $configure_input"
30666 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30667 $as_echo "$as_me: creating $ac_file" >&6;}
30669 # Neutralize special characters interpreted by sed in replacement strings.
30670 case $configure_input in #(
30671 *\&* | *\|* | *\\* )
30672 ac_sed_conf_input=`$as_echo "$configure_input" |
30673 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30674 *) ac_sed_conf_input=$configure_input;;
30675 esac
30677 case $ac_tag in
30678 *:-:* | *:-) cat >"$tmp/stdin" \
30679 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
30680 esac
30682 esac
30684 ac_dir=`$as_dirname -- "$ac_file" ||
30685 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30686 X"$ac_file" : 'X\(//\)[^/]' \| \
30687 X"$ac_file" : 'X\(//\)$' \| \
30688 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30689 $as_echo X"$ac_file" |
30690 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30691 s//\1/
30694 /^X\(\/\/\)[^/].*/{
30695 s//\1/
30698 /^X\(\/\/\)$/{
30699 s//\1/
30702 /^X\(\/\).*/{
30703 s//\1/
30706 s/.*/./; q'`
30707 as_dir="$ac_dir"; as_fn_mkdir_p
30708 ac_builddir=.
30710 case "$ac_dir" in
30711 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30713 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30714 # A ".." for each directory in $ac_dir_suffix.
30715 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30716 case $ac_top_builddir_sub in
30717 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30718 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30719 esac ;;
30720 esac
30721 ac_abs_top_builddir=$ac_pwd
30722 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30723 # for backward compatibility:
30724 ac_top_builddir=$ac_top_build_prefix
30726 case $srcdir in
30727 .) # We are building in place.
30728 ac_srcdir=.
30729 ac_top_srcdir=$ac_top_builddir_sub
30730 ac_abs_top_srcdir=$ac_pwd ;;
30731 [\\/]* | ?:[\\/]* ) # Absolute name.
30732 ac_srcdir=$srcdir$ac_dir_suffix;
30733 ac_top_srcdir=$srcdir
30734 ac_abs_top_srcdir=$srcdir ;;
30735 *) # Relative name.
30736 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30737 ac_top_srcdir=$ac_top_build_prefix$srcdir
30738 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30739 esac
30740 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30743 case $ac_mode in
30746 # CONFIG_FILE
30749 case $INSTALL in
30750 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30751 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30752 esac
30753 ac_MKDIR_P=$MKDIR_P
30754 case $MKDIR_P in
30755 [\\/$]* | ?:[\\/]* ) ;;
30756 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30757 esac
30758 _ACEOF
30760 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30761 # If the template does not know about datarootdir, expand it.
30762 # FIXME: This hack should be removed a few years after 2.60.
30763 ac_datarootdir_hack=; ac_datarootdir_seen=
30764 ac_sed_dataroot='
30765 /datarootdir/ {
30769 /@datadir@/p
30770 /@docdir@/p
30771 /@infodir@/p
30772 /@localedir@/p
30773 /@mandir@/p'
30774 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30775 *datarootdir*) ac_datarootdir_seen=yes;;
30776 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30777 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30778 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30779 _ACEOF
30780 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30781 ac_datarootdir_hack='
30782 s&@datadir@&$datadir&g
30783 s&@docdir@&$docdir&g
30784 s&@infodir@&$infodir&g
30785 s&@localedir@&$localedir&g
30786 s&@mandir@&$mandir&g
30787 s&\\\${datarootdir}&$datarootdir&g' ;;
30788 esac
30789 _ACEOF
30791 # Neutralize VPATH when `$srcdir' = `.'.
30792 # Shell code in configure.ac might set extrasub.
30793 # FIXME: do we really want to maintain this feature?
30794 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30795 ac_sed_extra="$ac_vpsub
30796 $extrasub
30797 _ACEOF
30798 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30800 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30801 s|@configure_input@|$ac_sed_conf_input|;t t
30802 s&@top_builddir@&$ac_top_builddir_sub&;t t
30803 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30804 s&@srcdir@&$ac_srcdir&;t t
30805 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30806 s&@top_srcdir@&$ac_top_srcdir&;t t
30807 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30808 s&@builddir@&$ac_builddir&;t t
30809 s&@abs_builddir@&$ac_abs_builddir&;t t
30810 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30811 s&@INSTALL@&$ac_INSTALL&;t t
30812 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30813 $ac_datarootdir_hack
30815 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30816 if $ac_cs_awk_getline; then
30817 $AWK -f "$tmp/subs.awk"
30818 else
30819 $AWK -f "$tmp/subs.awk" | $SHELL
30820 fi >$tmp/out \
30821 || as_fn_error "could not create $ac_file" "$LINENO" 5
30823 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30824 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30825 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30826 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30827 which seems to be undefined. Please make sure it is defined." >&5
30828 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30829 which seems to be undefined. Please make sure it is defined." >&2;}
30831 rm -f "$tmp/stdin"
30832 case $ac_file in
30833 -) cat "$tmp/out" && rm -f "$tmp/out";;
30834 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30835 esac \
30836 || as_fn_error "could not create $ac_file" "$LINENO" 5
30840 # CONFIG_HEADER
30842 if test x"$ac_file" != x-; then
30844 $as_echo "/* $configure_input */" \
30845 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30846 } >"$tmp/config.h" \
30847 || as_fn_error "could not create $ac_file" "$LINENO" 5
30848 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30849 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30850 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30851 else
30852 rm -f "$ac_file"
30853 mv "$tmp/config.h" "$ac_file" \
30854 || as_fn_error "could not create $ac_file" "$LINENO" 5
30856 else
30857 $as_echo "/* $configure_input */" \
30858 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30859 || as_fn_error "could not create -" "$LINENO" 5
30861 # Compute "$ac_file"'s index in $config_headers.
30862 _am_arg="$ac_file"
30863 _am_stamp_count=1
30864 for _am_header in $config_headers :; do
30865 case $_am_header in
30866 $_am_arg | $_am_arg:* )
30867 break ;;
30869 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30870 esac
30871 done
30872 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30873 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30874 X"$_am_arg" : 'X\(//\)[^/]' \| \
30875 X"$_am_arg" : 'X\(//\)$' \| \
30876 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30877 $as_echo X"$_am_arg" |
30878 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30879 s//\1/
30882 /^X\(\/\/\)[^/].*/{
30883 s//\1/
30886 /^X\(\/\/\)$/{
30887 s//\1/
30890 /^X\(\/\).*/{
30891 s//\1/
30894 s/.*/./; q'`/stamp-h$_am_stamp_count
30897 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30898 $as_echo "$as_me: executing $ac_file commands" >&6;}
30900 esac
30903 case $ac_file$ac_mode in
30904 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30905 # Autoconf 2.62 quotes --file arguments for eval, but not when files
30906 # are listed without --file. Let's play safe and only enable the eval
30907 # if we detect the quoting.
30908 case $CONFIG_FILES in
30909 *\'*) eval set x "$CONFIG_FILES" ;;
30910 *) set x $CONFIG_FILES ;;
30911 esac
30912 shift
30913 for mf
30915 # Strip MF so we end up with the name of the file.
30916 mf=`echo "$mf" | sed -e 's/:.*$//'`
30917 # Check whether this is an Automake generated Makefile or not.
30918 # We used to match only the files named `Makefile.in', but
30919 # some people rename them; so instead we look at the file content.
30920 # Grep'ing the first line is not enough: some people post-process
30921 # each Makefile.in and add a new line on top of each file to say so.
30922 # Grep'ing the whole file is not good either: AIX grep has a line
30923 # limit of 2048, but all sed's we know have understand at least 4000.
30924 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30925 dirpart=`$as_dirname -- "$mf" ||
30926 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30927 X"$mf" : 'X\(//\)[^/]' \| \
30928 X"$mf" : 'X\(//\)$' \| \
30929 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30930 $as_echo X"$mf" |
30931 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30932 s//\1/
30935 /^X\(\/\/\)[^/].*/{
30936 s//\1/
30939 /^X\(\/\/\)$/{
30940 s//\1/
30943 /^X\(\/\).*/{
30944 s//\1/
30947 s/.*/./; q'`
30948 else
30949 continue
30951 # Extract the definition of DEPDIR, am__include, and am__quote
30952 # from the Makefile without running `make'.
30953 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30954 test -z "$DEPDIR" && continue
30955 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30956 test -z "am__include" && continue
30957 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30958 # When using ansi2knr, U may be empty or an underscore; expand it
30959 U=`sed -n 's/^U = //p' < "$mf"`
30960 # Find all dependency output files, they are included files with
30961 # $(DEPDIR) in their names. We invoke sed twice because it is the
30962 # simplest approach to changing $(DEPDIR) to its actual value in the
30963 # expansion.
30964 for file in `sed -n "
30965 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30966 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
30967 # Make sure the directory exists.
30968 test -f "$dirpart/$file" && continue
30969 fdir=`$as_dirname -- "$file" ||
30970 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30971 X"$file" : 'X\(//\)[^/]' \| \
30972 X"$file" : 'X\(//\)$' \| \
30973 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30974 $as_echo X"$file" |
30975 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30976 s//\1/
30979 /^X\(\/\/\)[^/].*/{
30980 s//\1/
30983 /^X\(\/\/\)$/{
30984 s//\1/
30987 /^X\(\/\).*/{
30988 s//\1/
30991 s/.*/./; q'`
30992 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30993 # echo "creating $dirpart/$file"
30994 echo '# dummy' > "$dirpart/$file"
30995 done
30996 done
30999 "src/epaths.h":C)
31000 if test "${opsys}" = "mingw32"; then
31001 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
31002 else
31003 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
31006 "src/.gdbinit":C)
31007 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
31008 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
31012 esac
31013 done # for ac_tag
31016 as_fn_exit 0
31017 _ACEOF
31018 ac_clean_files=$ac_clean_files_save
31020 test $ac_write_fail = 0 ||
31021 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
31024 # configure is writing to config.log, and then calls config.status.
31025 # config.status does its own redirection, appending to config.log.
31026 # Unfortunately, on DOS this fails, as config.log is still kept open
31027 # by configure, so config.status won't be able to write to it; its
31028 # output is simply discarded. So we exec the FD to /dev/null,
31029 # effectively closing config.log, so it can be properly (re)opened and
31030 # appended to by config.status. When coming back to configure, we
31031 # need to make the FD available again.
31032 if test "$no_create" != yes; then
31033 ac_cs_success=:
31034 ac_config_status_args=
31035 test "$silent" = yes &&
31036 ac_config_status_args="$ac_config_status_args --quiet"
31037 exec 5>/dev/null
31038 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
31039 exec 5>>config.log
31040 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
31041 # would make configure fail if this is the last instruction.
31042 $ac_cs_success || as_fn_exit $?
31044 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
31045 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
31046 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}