* nsmenu.m (initWithContentRect:styleMask:backing:defer:): Initialize
[emacs.git] / autogen / configure
blob487f8de395a3bc02f5316bed972b4405ea0ddbfa
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.2.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.2.50'
553 PACKAGE_STRING='emacs 24.2.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 LIB_GCC
608 LD_FIRSTFLAG
609 LD_SWITCH_SYSTEM_TEMACS
610 LIBGNU_LTLIBDEPS
611 LIBGNU_LIBDEPS
612 gltests_WITNESS
613 gl_GNULIB_ENABLED_verify_FALSE
614 gl_GNULIB_ENABLED_verify_TRUE
615 gl_GNULIB_ENABLED_strtoull_FALSE
616 gl_GNULIB_ENABLED_strtoull_TRUE
617 gl_GNULIB_ENABLED_strtoll_FALSE
618 gl_GNULIB_ENABLED_strtoll_TRUE
619 gl_GNULIB_ENABLED_stat_FALSE
620 gl_GNULIB_ENABLED_stat_TRUE
621 gl_GNULIB_ENABLED_pathmax_FALSE
622 gl_GNULIB_ENABLED_pathmax_TRUE
623 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
624 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
625 gl_GNULIB_ENABLED_dosname_FALSE
626 gl_GNULIB_ENABLED_dosname_TRUE
627 LTLIBINTL
628 LIBINTL
629 WINDOWS_64_BIT_OFF_T
630 HAVE_UNISTD_H
631 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
632 NEXT_UNISTD_H
633 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
634 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
635 TIME_H_DEFINES_STRUCT_TIMESPEC
636 NEXT_AS_FIRST_DIRECTIVE_TIME_H
637 NEXT_TIME_H
638 WINDOWS_64_BIT_ST_SIZE
639 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
640 NEXT_SYS_STAT_H
641 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
642 NEXT_STDLIB_H
643 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
644 NEXT_STDIO_H
645 REPLACE_VSPRINTF
646 REPLACE_VSNPRINTF
647 REPLACE_VPRINTF
648 REPLACE_VFPRINTF
649 REPLACE_VDPRINTF
650 REPLACE_VASPRINTF
651 REPLACE_TMPFILE
652 REPLACE_STDIO_WRITE_FUNCS
653 REPLACE_STDIO_READ_FUNCS
654 REPLACE_SPRINTF
655 REPLACE_SNPRINTF
656 REPLACE_RENAMEAT
657 REPLACE_RENAME
658 REPLACE_REMOVE
659 REPLACE_PRINTF
660 REPLACE_POPEN
661 REPLACE_PERROR
662 REPLACE_OBSTACK_PRINTF
663 REPLACE_GETLINE
664 REPLACE_GETDELIM
665 REPLACE_FTELLO
666 REPLACE_FTELL
667 REPLACE_FSEEKO
668 REPLACE_FSEEK
669 REPLACE_FREOPEN
670 REPLACE_FPURGE
671 REPLACE_FPRINTF
672 REPLACE_FOPEN
673 REPLACE_FFLUSH
674 REPLACE_FDOPEN
675 REPLACE_FCLOSE
676 REPLACE_DPRINTF
677 HAVE_VDPRINTF
678 HAVE_VASPRINTF
679 HAVE_RENAMEAT
680 HAVE_POPEN
681 HAVE_PCLOSE
682 HAVE_FTELLO
683 HAVE_FSEEKO
684 HAVE_DPRINTF
685 HAVE_DECL_VSNPRINTF
686 HAVE_DECL_SNPRINTF
687 HAVE_DECL_OBSTACK_PRINTF
688 HAVE_DECL_GETLINE
689 HAVE_DECL_GETDELIM
690 HAVE_DECL_FTELLO
691 HAVE_DECL_FSEEKO
692 HAVE_DECL_FPURGE
693 GNULIB_VSPRINTF_POSIX
694 GNULIB_VSNPRINTF
695 GNULIB_VPRINTF_POSIX
696 GNULIB_VPRINTF
697 GNULIB_VFPRINTF_POSIX
698 GNULIB_VFPRINTF
699 GNULIB_VDPRINTF
700 GNULIB_VSCANF
701 GNULIB_VFSCANF
702 GNULIB_VASPRINTF
703 GNULIB_TMPFILE
704 GNULIB_STDIO_H_SIGPIPE
705 GNULIB_STDIO_H_NONBLOCKING
706 GNULIB_SPRINTF_POSIX
707 GNULIB_SNPRINTF
708 GNULIB_SCANF
709 GNULIB_RENAMEAT
710 GNULIB_RENAME
711 GNULIB_REMOVE
712 GNULIB_PUTS
713 GNULIB_PUTCHAR
714 GNULIB_PUTC
715 GNULIB_PRINTF_POSIX
716 GNULIB_PRINTF
717 GNULIB_POPEN
718 GNULIB_PERROR
719 GNULIB_PCLOSE
720 GNULIB_OBSTACK_PRINTF_POSIX
721 GNULIB_OBSTACK_PRINTF
722 GNULIB_GETLINE
723 GNULIB_GETDELIM
724 GNULIB_GETCHAR
725 GNULIB_GETC
726 GNULIB_FWRITE
727 GNULIB_FTELLO
728 GNULIB_FTELL
729 GNULIB_FSEEKO
730 GNULIB_FSEEK
731 GNULIB_FSCANF
732 GNULIB_FREOPEN
733 GNULIB_FREAD
734 GNULIB_FPUTS
735 GNULIB_FPUTC
736 GNULIB_FPURGE
737 GNULIB_FPRINTF_POSIX
738 GNULIB_FPRINTF
739 GNULIB_FOPEN
740 GNULIB_FGETS
741 GNULIB_FGETC
742 GNULIB_FFLUSH
743 GNULIB_FDOPEN
744 GNULIB_FCLOSE
745 GNULIB_DPRINTF
746 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
747 NEXT_STDDEF_H
748 GL_GENERATE_STDDEF_H_FALSE
749 GL_GENERATE_STDDEF_H_TRUE
750 STDDEF_H
751 HAVE_WCHAR_T
752 REPLACE_NULL
753 HAVE__BOOL
754 GL_GENERATE_STDBOOL_H_FALSE
755 GL_GENERATE_STDBOOL_H_TRUE
756 STDBOOL_H
757 GL_GENERATE_STDARG_H_FALSE
758 GL_GENERATE_STDARG_H_TRUE
759 STDARG_H
760 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
761 NEXT_STDARG_H
762 GL_GENERATE_STDALIGN_H_FALSE
763 GL_GENERATE_STDALIGN_H_TRUE
764 STDALIGN_H
765 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
766 NEXT_SIGNAL_H
767 LIB_PTHREAD_SIGMASK
768 REPLACE_RAISE
769 REPLACE_PTHREAD_SIGMASK
770 HAVE_SIGHANDLER_T
771 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
772 HAVE_STRUCT_SIGACTION_SA_SIGACTION
773 HAVE_SIGACTION
774 HAVE_SIGINFO_T
775 HAVE_SIGSET_T
776 HAVE_RAISE
777 HAVE_PTHREAD_SIGMASK
778 HAVE_POSIX_SIGNALBLOCKING
779 GNULIB_SIGACTION
780 GNULIB_SIGPROCMASK
781 GNULIB_SIGNAL_H_SIGPIPE
782 GNULIB_RAISE
783 GNULIB_PTHREAD_SIGMASK
784 HAVE_SYS_SELECT_H
785 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
786 NEXT_SYS_SELECT_H
787 REPLACE_SELECT
788 REPLACE_PSELECT
789 HAVE_PSELECT
790 GNULIB_SELECT
791 GNULIB_PSELECT
792 REPLACE_TIMEGM
793 REPLACE_NANOSLEEP
794 REPLACE_MKTIME
795 REPLACE_LOCALTIME_R
796 HAVE_TIMEGM
797 HAVE_STRPTIME
798 HAVE_NANOSLEEP
799 HAVE_DECL_LOCALTIME_R
800 GNULIB_TIME_R
801 GNULIB_TIMEGM
802 GNULIB_STRPTIME
803 GNULIB_NANOSLEEP
804 GNULIB_MKTIME
805 REPLACE_UTIMENSAT
806 REPLACE_STAT
807 REPLACE_MKNOD
808 REPLACE_MKFIFO
809 REPLACE_MKDIR
810 REPLACE_LSTAT
811 REPLACE_FUTIMENS
812 REPLACE_FSTATAT
813 REPLACE_FSTAT
814 HAVE_UTIMENSAT
815 HAVE_MKNODAT
816 HAVE_MKNOD
817 HAVE_MKFIFOAT
818 HAVE_MKFIFO
819 HAVE_MKDIRAT
820 HAVE_LSTAT
821 HAVE_LCHMOD
822 HAVE_FUTIMENS
823 HAVE_FSTATAT
824 HAVE_FCHMODAT
825 GNULIB_UTIMENSAT
826 GNULIB_STAT
827 GNULIB_MKNODAT
828 GNULIB_MKNOD
829 GNULIB_MKFIFOAT
830 GNULIB_MKFIFO
831 GNULIB_MKDIRAT
832 GNULIB_LSTAT
833 GNULIB_LCHMOD
834 GNULIB_FUTIMENS
835 GNULIB_FSTATAT
836 GNULIB_FSTAT
837 GNULIB_FCHMODAT
838 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
839 NEXT_INTTYPES_H
840 UINT64_MAX_EQ_ULONG_MAX
841 UINT32_MAX_LT_UINTMAX_MAX
842 PRIPTR_PREFIX
843 PRI_MACROS_BROKEN
844 INT64_MAX_EQ_LONG_MAX
845 INT32_MAX_LT_INTMAX_MAX
846 REPLACE_STRTOIMAX
847 HAVE_DECL_STRTOUMAX
848 HAVE_DECL_STRTOIMAX
849 HAVE_DECL_IMAXDIV
850 HAVE_DECL_IMAXABS
851 GNULIB_STRTOUMAX
852 GNULIB_STRTOIMAX
853 GNULIB_IMAXDIV
854 GNULIB_IMAXABS
855 GL_GENERATE_STDINT_H_FALSE
856 GL_GENERATE_STDINT_H_TRUE
857 STDINT_H
858 WINT_T_SUFFIX
859 WCHAR_T_SUFFIX
860 SIG_ATOMIC_T_SUFFIX
861 SIZE_T_SUFFIX
862 PTRDIFF_T_SUFFIX
863 HAVE_SIGNED_WINT_T
864 HAVE_SIGNED_WCHAR_T
865 HAVE_SIGNED_SIG_ATOMIC_T
866 BITSIZEOF_WINT_T
867 BITSIZEOF_WCHAR_T
868 BITSIZEOF_SIG_ATOMIC_T
869 BITSIZEOF_SIZE_T
870 BITSIZEOF_PTRDIFF_T
871 APPLE_UNIVERSAL_BUILD
872 HAVE_SYS_BITYPES_H
873 HAVE_SYS_INTTYPES_H
874 HAVE_STDINT_H
875 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
876 NEXT_STDINT_H
877 HAVE_SYS_TYPES_H
878 HAVE_INTTYPES_H
879 HAVE_WCHAR_H
880 HAVE_UNSIGNED_LONG_LONG_INT
881 HAVE_LONG_LONG_INT
882 HAVE_WINSOCK2_H
883 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
884 NEXT_SYS_TIME_H
885 REPLACE_STRUCT_TIMEVAL
886 REPLACE_GETTIMEOFDAY
887 HAVE_SYS_TIME_H
888 HAVE_STRUCT_TIMEVAL
889 HAVE_GETTIMEOFDAY
890 GNULIB_GETTIMEOFDAY
891 GNULIB_GL_UNISTD_H_GETOPT
892 GETOPT_H
893 HAVE_GETOPT_H
894 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
895 NEXT_GETOPT_H
896 PRAGMA_COLUMNS
897 PRAGMA_SYSTEM_HEADER
898 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
899 INCLUDE_NEXT
900 GETLOADAVG_LIBS
901 REPLACE_WCTOMB
902 REPLACE_UNSETENV
903 REPLACE_STRTOD
904 REPLACE_SETENV
905 REPLACE_REALPATH
906 REPLACE_REALLOC
907 REPLACE_RANDOM_R
908 REPLACE_PUTENV
909 REPLACE_PTSNAME_R
910 REPLACE_MKSTEMP
911 REPLACE_MBTOWC
912 REPLACE_MALLOC
913 REPLACE_CANONICALIZE_FILE_NAME
914 REPLACE_CALLOC
915 HAVE_DECL_UNSETENV
916 HAVE_UNLOCKPT
917 HAVE_SYS_LOADAVG_H
918 HAVE_STRUCT_RANDOM_DATA
919 HAVE_STRTOULL
920 HAVE_STRTOLL
921 HAVE_STRTOD
922 HAVE_DECL_SETENV
923 HAVE_SETENV
924 HAVE_RPMATCH
925 HAVE_REALPATH
926 HAVE_RANDOM_R
927 HAVE_RANDOM_H
928 HAVE_RANDOM
929 HAVE_PTSNAME_R
930 HAVE_PTSNAME
931 HAVE_POSIX_OPENPT
932 HAVE_MKSTEMPS
933 HAVE_MKSTEMP
934 HAVE_MKOSTEMPS
935 HAVE_MKOSTEMP
936 HAVE_MKDTEMP
937 HAVE_GRANTPT
938 HAVE_GETSUBOPT
939 HAVE_DECL_GETLOADAVG
940 HAVE_CANONICALIZE_FILE_NAME
941 HAVE_ATOLL
942 HAVE__EXIT
943 GNULIB_WCTOMB
944 GNULIB_UNSETENV
945 GNULIB_UNLOCKPT
946 GNULIB_SYSTEM_POSIX
947 GNULIB_STRTOULL
948 GNULIB_STRTOLL
949 GNULIB_STRTOD
950 GNULIB_SETENV
951 GNULIB_RPMATCH
952 GNULIB_REALPATH
953 GNULIB_REALLOC_POSIX
954 GNULIB_RANDOM_R
955 GNULIB_RANDOM
956 GNULIB_PUTENV
957 GNULIB_PTSNAME_R
958 GNULIB_PTSNAME
959 GNULIB_POSIX_OPENPT
960 GNULIB_MKSTEMPS
961 GNULIB_MKSTEMP
962 GNULIB_MKOSTEMPS
963 GNULIB_MKOSTEMP
964 GNULIB_MKDTEMP
965 GNULIB_MBTOWC
966 GNULIB_MALLOC_POSIX
967 GNULIB_GRANTPT
968 GNULIB_GETSUBOPT
969 GNULIB_GETLOADAVG
970 GNULIB_CANONICALIZE_FILE_NAME
971 GNULIB_CALLOC_POSIX
972 GNULIB_ATOLL
973 GNULIB__EXIT
974 GL_GENERATE_EXECINFO_H_FALSE
975 GL_GENERATE_EXECINFO_H_TRUE
976 LIB_EXECINFO
977 EXECINFO_H
978 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
979 UNISTD_H_HAVE_WINSOCK2_H
980 REPLACE_WRITE
981 REPLACE_USLEEP
982 REPLACE_UNLINKAT
983 REPLACE_UNLINK
984 REPLACE_TTYNAME_R
985 REPLACE_SYMLINK
986 REPLACE_SLEEP
987 REPLACE_RMDIR
988 REPLACE_READLINK
989 REPLACE_READ
990 REPLACE_PWRITE
991 REPLACE_PREAD
992 REPLACE_LSEEK
993 REPLACE_LINKAT
994 REPLACE_LINK
995 REPLACE_LCHOWN
996 REPLACE_ISATTY
997 REPLACE_GETPAGESIZE
998 REPLACE_GETGROUPS
999 REPLACE_GETLOGIN_R
1000 REPLACE_GETDOMAINNAME
1001 REPLACE_GETCWD
1002 REPLACE_FTRUNCATE
1003 REPLACE_FCHOWNAT
1004 REPLACE_DUP2
1005 REPLACE_DUP
1006 REPLACE_CLOSE
1007 REPLACE_CHOWN
1008 HAVE_SYS_PARAM_H
1009 HAVE_OS_H
1010 HAVE_DECL_TTYNAME_R
1011 HAVE_DECL_SETHOSTNAME
1012 HAVE_DECL_GETUSERSHELL
1013 HAVE_DECL_GETPAGESIZE
1014 HAVE_DECL_GETLOGIN_R
1015 HAVE_DECL_GETDOMAINNAME
1016 HAVE_DECL_FDATASYNC
1017 HAVE_DECL_FCHDIR
1018 HAVE_DECL_ENVIRON
1019 HAVE_USLEEP
1020 HAVE_UNLINKAT
1021 HAVE_SYMLINKAT
1022 HAVE_SYMLINK
1023 HAVE_SLEEP
1024 HAVE_SETHOSTNAME
1025 HAVE_READLINKAT
1026 HAVE_READLINK
1027 HAVE_PWRITE
1028 HAVE_PREAD
1029 HAVE_PIPE2
1030 HAVE_PIPE
1031 HAVE_LINKAT
1032 HAVE_LINK
1033 HAVE_LCHOWN
1034 HAVE_GROUP_MEMBER
1035 HAVE_GETPAGESIZE
1036 HAVE_GETLOGIN
1037 HAVE_GETHOSTNAME
1038 HAVE_GETGROUPS
1039 HAVE_GETDTABLESIZE
1040 HAVE_FTRUNCATE
1041 HAVE_FSYNC
1042 HAVE_FDATASYNC
1043 HAVE_FCHOWNAT
1044 HAVE_FCHDIR
1045 HAVE_FACCESSAT
1046 HAVE_EUIDACCESS
1047 HAVE_DUP3
1048 HAVE_DUP2
1049 HAVE_CHOWN
1050 GNULIB_WRITE
1051 GNULIB_USLEEP
1052 GNULIB_UNLINKAT
1053 GNULIB_UNLINK
1054 GNULIB_UNISTD_H_SIGPIPE
1055 GNULIB_UNISTD_H_NONBLOCKING
1056 GNULIB_TTYNAME_R
1057 GNULIB_SYMLINKAT
1058 GNULIB_SYMLINK
1059 GNULIB_SLEEP
1060 GNULIB_SETHOSTNAME
1061 GNULIB_RMDIR
1062 GNULIB_READLINKAT
1063 GNULIB_READLINK
1064 GNULIB_READ
1065 GNULIB_PWRITE
1066 GNULIB_PREAD
1067 GNULIB_PIPE2
1068 GNULIB_PIPE
1069 GNULIB_LSEEK
1070 GNULIB_LINKAT
1071 GNULIB_LINK
1072 GNULIB_LCHOWN
1073 GNULIB_ISATTY
1074 GNULIB_GROUP_MEMBER
1075 GNULIB_GETUSERSHELL
1076 GNULIB_GETPAGESIZE
1077 GNULIB_GETLOGIN_R
1078 GNULIB_GETLOGIN
1079 GNULIB_GETHOSTNAME
1080 GNULIB_GETGROUPS
1081 GNULIB_GETDTABLESIZE
1082 GNULIB_GETDOMAINNAME
1083 GNULIB_GETCWD
1084 GNULIB_FTRUNCATE
1085 GNULIB_FSYNC
1086 GNULIB_FDATASYNC
1087 GNULIB_FCHOWNAT
1088 GNULIB_FCHDIR
1089 GNULIB_FACCESSAT
1090 GNULIB_EUIDACCESS
1091 GNULIB_ENVIRON
1092 GNULIB_DUP3
1093 GNULIB_DUP2
1094 GNULIB_DUP
1095 GNULIB_CLOSE
1096 GNULIB_CHOWN
1097 GNULIB_CHDIR
1098 LIB_CLOCK_GETTIME
1099 GL_GENERATE_ALLOCA_H_FALSE
1100 GL_GENERATE_ALLOCA_H_TRUE
1101 ALLOCA_H
1102 ALLOCA
1103 GL_COND_LIBTOOL_FALSE
1104 GL_COND_LIBTOOL_TRUE
1105 POST_ALLOC_OBJ
1106 PRE_ALLOC_OBJ
1107 CYGWIN_OBJ
1108 RALLOC_OBJ
1109 OLDXMENU_DEPS
1110 LIBX_OTHER
1111 LIBXMENU
1112 OLDXMENU
1113 OLDXMENU_TARGET
1114 LIBXT_OTHER
1115 TOOLKIT_LIBW
1116 WIDGET_OBJ
1117 XOBJ
1118 XMENU_OBJ
1119 FONT_OBJ
1120 OTHER_FILES
1121 GNU_OBJC_CFLAGS
1122 ns_appsrc
1123 ns_appresdir
1124 ns_appbindir
1125 ns_appdir
1126 X_TOOLKIT_TYPE
1127 GNUSTEP_CFLAGS
1128 C_SWITCH_X_SITE
1129 LD_SWITCH_X_SITE
1130 gameuser
1131 gamedir
1132 bitmapdir
1133 archlibdir
1134 etcdir
1135 x_default_search_path
1136 lisppath
1137 locallisppath
1138 standardlisppath
1139 leimdir
1140 lispdir
1141 srcdir
1142 canonical
1143 configuration
1144 version
1145 KRB4LIB
1146 DESLIB
1147 KRB5LIB
1148 CRYPTOLIB
1149 COM_ERRLIB
1150 LIBRESOLV
1151 LIBHESIOD
1152 TERMCAP_OBJ
1153 LIBS_TERMCAP
1154 BLESSMAIL_TARGET
1155 LIBS_MAIL
1156 liblockfile
1157 LIBXML2_LIBS
1158 LIBXML2_CFLAGS
1159 LIBXSM
1160 LIBGPM
1161 LIBGIF
1162 LIBTIFF
1163 LIBPNG
1164 LIBJPEG
1165 LIBXPM
1166 M17N_FLT_LIBS
1167 M17N_FLT_CFLAGS
1168 LIBOTF_LIBS
1169 LIBOTF_CFLAGS
1170 FREETYPE_LIBS
1171 FREETYPE_CFLAGS
1172 XFT_LIBS
1173 XFT_CFLAGS
1174 FONTCONFIG_LIBS
1175 FONTCONFIG_CFLAGS
1176 LIBXMU
1177 LIBXTR6
1178 LIBGNUTLS_LIBS
1179 LIBGNUTLS_CFLAGS
1180 LIBSELINUX_LIBS
1181 SETTINGS_LIBS
1182 SETTINGS_CFLAGS
1183 GCONF_LIBS
1184 GCONF_CFLAGS
1185 GSETTINGS_LIBS
1186 GSETTINGS_CFLAGS
1187 DBUS_OBJ
1188 DBUS_LIBS
1189 DBUS_CFLAGS
1190 GTK_OBJ
1191 GTK_LIBS
1192 GTK_CFLAGS
1193 IMAGEMAGICK_LIBS
1194 IMAGEMAGICK_CFLAGS
1195 RSVG_LIBS
1196 RSVG_CFLAGS
1197 LIB_PTHREAD
1198 VMLIMIT_OBJ
1199 GMALLOC_OBJ
1200 HAVE_XSERVER
1201 LIB_STANDARD
1202 NS_OBJC_OBJ
1203 NS_OBJ
1204 ns_self_contained
1205 INSTALL_ARCH_INDEP_EXTRA
1206 TEMACS_LDFLAGS2
1207 LD_SWITCH_X_SITE_RPATH
1208 XMKMF
1209 DEPFLAGS
1210 MKDEPDIR
1211 CFLAGS_SOUND
1212 ALSA_LIBS
1213 ALSA_CFLAGS
1214 LIBSOUND
1215 PKG_CONFIG
1216 CRT_DIR
1217 START_FILES
1218 LIB_MATH
1219 LIBS_SYSTEM
1220 C_SWITCH_SYSTEM
1221 UNEXEC_OBJ
1222 C_SWITCH_MACHINE
1223 LD_SWITCH_SYSTEM
1224 CANNOT_DUMP
1225 INFO_OPTS
1226 INFO_EXT
1227 HAVE_MAKEINFO
1228 PAXCTL
1229 GZIP_PROG
1230 INSTALL_INFO
1231 LN_S
1232 GNULIB_WARN_CFLAGS
1233 WARN_CFLAGS
1234 WERROR_CFLAGS
1235 RANLIB
1236 ARFLAGS
1238 EGREP
1239 GREP
1241 am__fastdepCC_FALSE
1242 am__fastdepCC_TRUE
1243 CCDEPMODE
1244 AMDEPBACKSLASH
1245 AMDEP_FALSE
1246 AMDEP_TRUE
1247 am__quote
1248 am__include
1249 DEPDIR
1250 OBJEXT
1251 EXEEXT
1252 ac_ct_CC
1253 CPPFLAGS
1254 LDFLAGS
1255 CFLAGS
1257 host_os
1258 host_vendor
1259 host_cpu
1260 host
1261 build_os
1262 build_vendor
1263 build_cpu
1264 build
1265 PROFILING_CFLAGS
1266 GZIP_INFO
1267 cache_file
1268 am__untar
1269 am__tar
1270 AMTAR
1271 am__leading_dot
1272 SET_MAKE
1274 mkdir_p
1275 MKDIR_P
1276 INSTALL_STRIP_PROGRAM
1277 STRIP
1278 install_sh
1279 MAKEINFO
1280 AUTOHEADER
1281 AUTOMAKE
1282 AUTOCONF
1283 ACLOCAL
1284 VERSION
1285 PACKAGE
1286 CYGPATH_W
1287 am__isrc
1288 INSTALL_DATA
1289 INSTALL_SCRIPT
1290 INSTALL_PROGRAM
1291 target_alias
1292 host_alias
1293 build_alias
1294 LIBS
1295 ECHO_T
1296 ECHO_N
1297 ECHO_C
1298 DEFS
1299 mandir
1300 localedir
1301 libdir
1302 psdir
1303 pdfdir
1304 dvidir
1305 htmldir
1306 infodir
1307 docdir
1308 oldincludedir
1309 includedir
1310 localstatedir
1311 sharedstatedir
1312 sysconfdir
1313 datadir
1314 datarootdir
1315 libexecdir
1316 sbindir
1317 bindir
1318 program_transform_name
1319 prefix
1320 exec_prefix
1321 PACKAGE_URL
1322 PACKAGE_BUGREPORT
1323 PACKAGE_STRING
1324 PACKAGE_VERSION
1325 PACKAGE_TARNAME
1326 PACKAGE_NAME
1327 PATH_SEPARATOR
1328 SHELL'
1329 ac_subst_files='deps_frag
1330 lisp_frag
1331 ns_frag'
1332 ac_user_opts='
1333 enable_option_checking
1334 with_all
1335 with_pop
1336 with_kerberos
1337 with_kerberos5
1338 with_hesiod
1339 with_mmdf
1340 with_mail_unlink
1341 with_mailhost
1342 with_sound
1343 with_sync_input
1344 with_x_toolkit
1345 with_wide_int
1346 with_xpm
1347 with_jpeg
1348 with_tiff
1349 with_gif
1350 with_png
1351 with_rsvg
1352 with_xml2
1353 with_imagemagick
1354 with_xft
1355 with_libotf
1356 with_m17n_flt
1357 with_toolkit_scroll_bars
1358 with_xaw3d
1359 with_xim
1360 with_ns
1361 with_gpm
1362 with_dbus
1363 with_gconf
1364 with_gsettings
1365 with_selinux
1366 with_gnutls
1367 with_makeinfo
1368 with_compress_info
1369 with_pkg_config_prog
1370 with_crt_dir
1371 with_gameuser
1372 with_gnustep_conf
1373 enable_ns_self_contained
1374 enable_locallisppath
1375 enable_checking
1376 enable_check_lisp_object_type
1377 enable_profiling
1378 enable_autodepend
1379 enable_dependency_tracking
1380 enable_largefile
1381 enable_gcc_warnings
1382 enable_link_time_optimization
1383 with_x
1385 ac_precious_vars='build_alias
1386 host_alias
1387 target_alias
1389 CFLAGS
1390 LDFLAGS
1391 LIBS
1392 CPPFLAGS
1394 XMKMF'
1397 # Initialize some variables set by options.
1398 ac_init_help=
1399 ac_init_version=false
1400 ac_unrecognized_opts=
1401 ac_unrecognized_sep=
1402 # The variables have the same names as the options, with
1403 # dashes changed to underlines.
1404 cache_file=/dev/null
1405 exec_prefix=NONE
1406 no_create=
1407 no_recursion=
1408 prefix=NONE
1409 program_prefix=NONE
1410 program_suffix=NONE
1411 program_transform_name=s,x,x,
1412 silent=
1413 site=
1414 srcdir=
1415 verbose=
1416 x_includes=NONE
1417 x_libraries=NONE
1419 # Installation directory options.
1420 # These are left unexpanded so users can "make install exec_prefix=/foo"
1421 # and all the variables that are supposed to be based on exec_prefix
1422 # by default will actually change.
1423 # Use braces instead of parens because sh, perl, etc. also accept them.
1424 # (The list follows the same order as the GNU Coding Standards.)
1425 bindir='${exec_prefix}/bin'
1426 sbindir='${exec_prefix}/sbin'
1427 libexecdir='${exec_prefix}/libexec'
1428 datarootdir='${prefix}/share'
1429 datadir='${datarootdir}'
1430 sysconfdir='${prefix}/etc'
1431 sharedstatedir='${prefix}/com'
1432 localstatedir='${prefix}/var'
1433 includedir='${prefix}/include'
1434 oldincludedir='/usr/include'
1435 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1436 infodir='${datarootdir}/info'
1437 htmldir='${docdir}'
1438 dvidir='${docdir}'
1439 pdfdir='${docdir}'
1440 psdir='${docdir}'
1441 libdir='${exec_prefix}/lib'
1442 localedir='${datarootdir}/locale'
1443 mandir='${datarootdir}/man'
1445 ac_prev=
1446 ac_dashdash=
1447 for ac_option
1449 # If the previous option needs an argument, assign it.
1450 if test -n "$ac_prev"; then
1451 eval $ac_prev=\$ac_option
1452 ac_prev=
1453 continue
1456 case $ac_option in
1457 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1458 *) ac_optarg=yes ;;
1459 esac
1461 # Accept the important Cygnus configure options, so we can diagnose typos.
1463 case $ac_dashdash$ac_option in
1465 ac_dashdash=yes ;;
1467 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1468 ac_prev=bindir ;;
1469 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1470 bindir=$ac_optarg ;;
1472 -build | --build | --buil | --bui | --bu)
1473 ac_prev=build_alias ;;
1474 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1475 build_alias=$ac_optarg ;;
1477 -cache-file | --cache-file | --cache-fil | --cache-fi \
1478 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1479 ac_prev=cache_file ;;
1480 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1481 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1482 cache_file=$ac_optarg ;;
1484 --config-cache | -C)
1485 cache_file=config.cache ;;
1487 -datadir | --datadir | --datadi | --datad)
1488 ac_prev=datadir ;;
1489 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1490 datadir=$ac_optarg ;;
1492 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1493 | --dataroo | --dataro | --datar)
1494 ac_prev=datarootdir ;;
1495 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1496 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1497 datarootdir=$ac_optarg ;;
1499 -disable-* | --disable-*)
1500 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1501 # Reject names that are not valid shell variable names.
1502 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1503 as_fn_error "invalid feature name: $ac_useropt"
1504 ac_useropt_orig=$ac_useropt
1505 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1506 case $ac_user_opts in
1508 "enable_$ac_useropt"
1509 "*) ;;
1510 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1511 ac_unrecognized_sep=', ';;
1512 esac
1513 eval enable_$ac_useropt=no ;;
1515 -docdir | --docdir | --docdi | --doc | --do)
1516 ac_prev=docdir ;;
1517 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1518 docdir=$ac_optarg ;;
1520 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1521 ac_prev=dvidir ;;
1522 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1523 dvidir=$ac_optarg ;;
1525 -enable-* | --enable-*)
1526 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1527 # Reject names that are not valid shell variable names.
1528 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1529 as_fn_error "invalid feature name: $ac_useropt"
1530 ac_useropt_orig=$ac_useropt
1531 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1532 case $ac_user_opts in
1534 "enable_$ac_useropt"
1535 "*) ;;
1536 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1537 ac_unrecognized_sep=', ';;
1538 esac
1539 eval enable_$ac_useropt=\$ac_optarg ;;
1541 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1542 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1543 | --exec | --exe | --ex)
1544 ac_prev=exec_prefix ;;
1545 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1546 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1547 | --exec=* | --exe=* | --ex=*)
1548 exec_prefix=$ac_optarg ;;
1550 -gas | --gas | --ga | --g)
1551 # Obsolete; use --with-gas.
1552 with_gas=yes ;;
1554 -help | --help | --hel | --he | -h)
1555 ac_init_help=long ;;
1556 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1557 ac_init_help=recursive ;;
1558 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1559 ac_init_help=short ;;
1561 -host | --host | --hos | --ho)
1562 ac_prev=host_alias ;;
1563 -host=* | --host=* | --hos=* | --ho=*)
1564 host_alias=$ac_optarg ;;
1566 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1567 ac_prev=htmldir ;;
1568 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1569 | --ht=*)
1570 htmldir=$ac_optarg ;;
1572 -includedir | --includedir | --includedi | --included | --include \
1573 | --includ | --inclu | --incl | --inc)
1574 ac_prev=includedir ;;
1575 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1576 | --includ=* | --inclu=* | --incl=* | --inc=*)
1577 includedir=$ac_optarg ;;
1579 -infodir | --infodir | --infodi | --infod | --info | --inf)
1580 ac_prev=infodir ;;
1581 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1582 infodir=$ac_optarg ;;
1584 -libdir | --libdir | --libdi | --libd)
1585 ac_prev=libdir ;;
1586 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1587 libdir=$ac_optarg ;;
1589 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1590 | --libexe | --libex | --libe)
1591 ac_prev=libexecdir ;;
1592 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1593 | --libexe=* | --libex=* | --libe=*)
1594 libexecdir=$ac_optarg ;;
1596 -localedir | --localedir | --localedi | --localed | --locale)
1597 ac_prev=localedir ;;
1598 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1599 localedir=$ac_optarg ;;
1601 -localstatedir | --localstatedir | --localstatedi | --localstated \
1602 | --localstate | --localstat | --localsta | --localst | --locals)
1603 ac_prev=localstatedir ;;
1604 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1605 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1606 localstatedir=$ac_optarg ;;
1608 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1609 ac_prev=mandir ;;
1610 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1611 mandir=$ac_optarg ;;
1613 -nfp | --nfp | --nf)
1614 # Obsolete; use --without-fp.
1615 with_fp=no ;;
1617 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1618 | --no-cr | --no-c | -n)
1619 no_create=yes ;;
1621 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1622 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1623 no_recursion=yes ;;
1625 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1626 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1627 | --oldin | --oldi | --old | --ol | --o)
1628 ac_prev=oldincludedir ;;
1629 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1630 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1631 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1632 oldincludedir=$ac_optarg ;;
1634 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1635 ac_prev=prefix ;;
1636 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1637 prefix=$ac_optarg ;;
1639 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1640 | --program-pre | --program-pr | --program-p)
1641 ac_prev=program_prefix ;;
1642 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1643 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1644 program_prefix=$ac_optarg ;;
1646 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1647 | --program-suf | --program-su | --program-s)
1648 ac_prev=program_suffix ;;
1649 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1650 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1651 program_suffix=$ac_optarg ;;
1653 -program-transform-name | --program-transform-name \
1654 | --program-transform-nam | --program-transform-na \
1655 | --program-transform-n | --program-transform- \
1656 | --program-transform | --program-transfor \
1657 | --program-transfo | --program-transf \
1658 | --program-trans | --program-tran \
1659 | --progr-tra | --program-tr | --program-t)
1660 ac_prev=program_transform_name ;;
1661 -program-transform-name=* | --program-transform-name=* \
1662 | --program-transform-nam=* | --program-transform-na=* \
1663 | --program-transform-n=* | --program-transform-=* \
1664 | --program-transform=* | --program-transfor=* \
1665 | --program-transfo=* | --program-transf=* \
1666 | --program-trans=* | --program-tran=* \
1667 | --progr-tra=* | --program-tr=* | --program-t=*)
1668 program_transform_name=$ac_optarg ;;
1670 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1671 ac_prev=pdfdir ;;
1672 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1673 pdfdir=$ac_optarg ;;
1675 -psdir | --psdir | --psdi | --psd | --ps)
1676 ac_prev=psdir ;;
1677 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1678 psdir=$ac_optarg ;;
1680 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1681 | -silent | --silent | --silen | --sile | --sil)
1682 silent=yes ;;
1684 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1685 ac_prev=sbindir ;;
1686 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1687 | --sbi=* | --sb=*)
1688 sbindir=$ac_optarg ;;
1690 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1691 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1692 | --sharedst | --shareds | --shared | --share | --shar \
1693 | --sha | --sh)
1694 ac_prev=sharedstatedir ;;
1695 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1696 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1697 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1698 | --sha=* | --sh=*)
1699 sharedstatedir=$ac_optarg ;;
1701 -site | --site | --sit)
1702 ac_prev=site ;;
1703 -site=* | --site=* | --sit=*)
1704 site=$ac_optarg ;;
1706 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1707 ac_prev=srcdir ;;
1708 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1709 srcdir=$ac_optarg ;;
1711 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1712 | --syscon | --sysco | --sysc | --sys | --sy)
1713 ac_prev=sysconfdir ;;
1714 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1715 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1716 sysconfdir=$ac_optarg ;;
1718 -target | --target | --targe | --targ | --tar | --ta | --t)
1719 ac_prev=target_alias ;;
1720 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1721 target_alias=$ac_optarg ;;
1723 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1724 verbose=yes ;;
1726 -version | --version | --versio | --versi | --vers | -V)
1727 ac_init_version=: ;;
1729 -with-* | --with-*)
1730 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1731 # Reject names that are not valid shell variable names.
1732 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1733 as_fn_error "invalid package name: $ac_useropt"
1734 ac_useropt_orig=$ac_useropt
1735 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1736 case $ac_user_opts in
1738 "with_$ac_useropt"
1739 "*) ;;
1740 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1741 ac_unrecognized_sep=', ';;
1742 esac
1743 eval with_$ac_useropt=\$ac_optarg ;;
1745 -without-* | --without-*)
1746 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1747 # Reject names that are not valid shell variable names.
1748 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1749 as_fn_error "invalid package name: $ac_useropt"
1750 ac_useropt_orig=$ac_useropt
1751 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1752 case $ac_user_opts in
1754 "with_$ac_useropt"
1755 "*) ;;
1756 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1757 ac_unrecognized_sep=', ';;
1758 esac
1759 eval with_$ac_useropt=no ;;
1761 --x)
1762 # Obsolete; use --with-x.
1763 with_x=yes ;;
1765 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1766 | --x-incl | --x-inc | --x-in | --x-i)
1767 ac_prev=x_includes ;;
1768 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1769 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1770 x_includes=$ac_optarg ;;
1772 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1773 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1774 ac_prev=x_libraries ;;
1775 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1776 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1777 x_libraries=$ac_optarg ;;
1779 -*) as_fn_error "unrecognized option: \`$ac_option'
1780 Try \`$0 --help' for more information."
1783 *=*)
1784 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1785 # Reject names that are not valid shell variable names.
1786 case $ac_envvar in #(
1787 '' | [0-9]* | *[!_$as_cr_alnum]* )
1788 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1789 esac
1790 eval $ac_envvar=\$ac_optarg
1791 export $ac_envvar ;;
1794 # FIXME: should be removed in autoconf 3.0.
1795 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1796 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1797 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1798 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1801 esac
1802 done
1804 if test -n "$ac_prev"; then
1805 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1806 as_fn_error "missing argument to $ac_option"
1809 if test -n "$ac_unrecognized_opts"; then
1810 case $enable_option_checking in
1811 no) ;;
1812 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1813 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1814 esac
1817 # Check all directory arguments for consistency.
1818 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1819 datadir sysconfdir sharedstatedir localstatedir includedir \
1820 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1821 libdir localedir mandir
1823 eval ac_val=\$$ac_var
1824 # Remove trailing slashes.
1825 case $ac_val in
1826 */ )
1827 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1828 eval $ac_var=\$ac_val;;
1829 esac
1830 # Be sure to have absolute directory names.
1831 case $ac_val in
1832 [\\/$]* | ?:[\\/]* ) continue;;
1833 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1834 esac
1835 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1836 done
1838 # There might be people who depend on the old broken behavior: `$host'
1839 # used to hold the argument of --host etc.
1840 # FIXME: To remove some day.
1841 build=$build_alias
1842 host=$host_alias
1843 target=$target_alias
1845 # FIXME: To remove some day.
1846 if test "x$host_alias" != x; then
1847 if test "x$build_alias" = x; then
1848 cross_compiling=maybe
1849 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1850 If a cross compiler is detected then cross compile mode will be used." >&2
1851 elif test "x$build_alias" != "x$host_alias"; then
1852 cross_compiling=yes
1856 ac_tool_prefix=
1857 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1859 test "$silent" = yes && exec 6>/dev/null
1862 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1863 ac_ls_di=`ls -di .` &&
1864 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1865 as_fn_error "working directory cannot be determined"
1866 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1867 as_fn_error "pwd does not report name of working directory"
1870 # Find the source files, if location was not specified.
1871 if test -z "$srcdir"; then
1872 ac_srcdir_defaulted=yes
1873 # Try the directory containing this script, then the parent directory.
1874 ac_confdir=`$as_dirname -- "$as_myself" ||
1875 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1876 X"$as_myself" : 'X\(//\)[^/]' \| \
1877 X"$as_myself" : 'X\(//\)$' \| \
1878 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1879 $as_echo X"$as_myself" |
1880 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1881 s//\1/
1884 /^X\(\/\/\)[^/].*/{
1885 s//\1/
1888 /^X\(\/\/\)$/{
1889 s//\1/
1892 /^X\(\/\).*/{
1893 s//\1/
1896 s/.*/./; q'`
1897 srcdir=$ac_confdir
1898 if test ! -r "$srcdir/$ac_unique_file"; then
1899 srcdir=..
1901 else
1902 ac_srcdir_defaulted=no
1904 if test ! -r "$srcdir/$ac_unique_file"; then
1905 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1906 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1908 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1909 ac_abs_confdir=`(
1910 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1911 pwd)`
1912 # When building in place, set srcdir=.
1913 if test "$ac_abs_confdir" = "$ac_pwd"; then
1914 srcdir=.
1916 # Remove unnecessary trailing slashes from srcdir.
1917 # Double slashes in file names in object file debugging info
1918 # mess up M-x gdb in Emacs.
1919 case $srcdir in
1920 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1921 esac
1922 for ac_var in $ac_precious_vars; do
1923 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1924 eval ac_env_${ac_var}_value=\$${ac_var}
1925 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1926 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1927 done
1930 # Report the --help message.
1932 if test "$ac_init_help" = "long"; then
1933 # Omit some internal or obsolete options to make the list less imposing.
1934 # This message is too long to be a string in the A/UX 3.1 sh.
1935 cat <<_ACEOF
1936 \`configure' configures emacs 24.2.50 to adapt to many kinds of systems.
1938 Usage: $0 [OPTION]... [VAR=VALUE]...
1940 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1941 VAR=VALUE. See below for descriptions of some of the useful variables.
1943 Defaults for the options are specified in brackets.
1945 Configuration:
1946 -h, --help display this help and exit
1947 --help=short display options specific to this package
1948 --help=recursive display the short help of all the included packages
1949 -V, --version display version information and exit
1950 -q, --quiet, --silent do not print \`checking...' messages
1951 --cache-file=FILE cache test results in FILE [disabled]
1952 -C, --config-cache alias for \`--cache-file=config.cache'
1953 -n, --no-create do not create output files
1954 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1956 Installation directories:
1957 --prefix=PREFIX install architecture-independent files in PREFIX
1958 [$ac_default_prefix]
1959 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1960 [PREFIX]
1962 By default, \`make install' will install all the files in
1963 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1964 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1965 for instance \`--prefix=\$HOME'.
1967 For better control, use the options below.
1969 Fine tuning of the installation directories:
1970 --bindir=DIR user executables [EPREFIX/bin]
1971 --sbindir=DIR system admin executables [EPREFIX/sbin]
1972 --libexecdir=DIR program executables [EPREFIX/libexec]
1973 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1974 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1975 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1976 --libdir=DIR object code libraries [EPREFIX/lib]
1977 --includedir=DIR C header files [PREFIX/include]
1978 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1979 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1980 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1981 --infodir=DIR info documentation [DATAROOTDIR/info]
1982 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1983 --mandir=DIR man documentation [DATAROOTDIR/man]
1984 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1985 --htmldir=DIR html documentation [DOCDIR]
1986 --dvidir=DIR dvi documentation [DOCDIR]
1987 --pdfdir=DIR pdf documentation [DOCDIR]
1988 --psdir=DIR ps documentation [DOCDIR]
1989 _ACEOF
1991 cat <<\_ACEOF
1993 Program names:
1994 --program-prefix=PREFIX prepend PREFIX to installed program names
1995 --program-suffix=SUFFIX append SUFFIX to installed program names
1996 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1998 X features:
1999 --x-includes=DIR X include files are in DIR
2000 --x-libraries=DIR X library files are in DIR
2002 System types:
2003 --build=BUILD configure for building on BUILD [guessed]
2004 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2005 _ACEOF
2008 if test -n "$ac_init_help"; then
2009 case $ac_init_help in
2010 short | recursive ) echo "Configuration of emacs 24.2.50:";;
2011 esac
2012 cat <<\_ACEOF
2014 Optional Features:
2015 --disable-option-checking ignore unrecognized --enable/--with options
2016 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2017 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2018 --disable-ns-self-contained
2019 disable self contained build under NeXTstep
2020 --enable-locallisppath=PATH
2021 directories Emacs should search for lisp files
2022 specific to this site
2023 --enable-checking[=LIST]
2024 enable expensive run-time checks. With LIST, enable
2025 only specific categories of checks. Categories are:
2026 all,yes,no. Flags are: stringbytes, stringoverrun,
2027 stringfreelist, xmallocoverrun, conslist, glyphs
2028 --enable-check-lisp-object-type
2029 enable compile time checks for the Lisp_Object data
2030 type. This is useful for development for catching
2031 certain types of bugs.
2032 --enable-profiling build emacs with profiling support. This might not
2033 work on all platforms
2034 --enable-autodepend automatically generate dependencies to .h-files.
2035 Requires GNU Make and Gcc. Enabled if GNU Make and
2036 Gcc is found
2037 --disable-dependency-tracking speeds up one-time build
2038 --enable-dependency-tracking do not reject slow dependency extractors
2039 --disable-largefile omit support for large files
2040 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2041 developers, and may generate false alarms when used
2042 with older or non-GNU development tools.
2043 --enable-link-time-optimization
2044 build emacs with link-time optimization. This is
2045 supported only for GCC since 4.5.0.
2047 Optional Packages:
2048 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2049 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2050 --without-all omit almost all features and build small executable
2051 with minimal dependencies
2052 --without-pop don't support POP mail retrieval with movemail
2053 --with-kerberos support Kerberos-authenticated POP
2054 --with-kerberos5 support Kerberos version 5 authenticated POP
2055 --with-hesiod support Hesiod to get the POP server host
2056 --with-mmdf support MMDF mailboxes
2057 --with-mail-unlink unlink, rather than empty, mail spool after reading
2058 --with-mailhost=HOSTNAME
2059 string giving default POP mail host
2060 --without-sound don't compile with sound support
2061 --without-sync-input process async input synchronously
2062 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
2063 lucid or athena, motif, no)
2064 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2065 --without-xpm don't compile with XPM image support
2066 --without-jpeg don't compile with JPEG image support
2067 --without-tiff don't compile with TIFF image support
2068 --without-gif don't compile with GIF image support
2069 --without-png don't compile with PNG image support
2070 --without-rsvg don't compile with SVG image support
2071 --without-xml2 don't compile with XML parsing support
2072 --without-imagemagick don't compile with ImageMagick image support
2073 --without-xft don't use XFT for anti aliased fonts
2074 --without-libotf don't use libotf for OpenType font support
2075 --without-m17n-flt don't use m17n-flt for text shaping
2076 --without-toolkit-scroll-bars
2077 don't use Motif or Xaw3d scroll bars
2078 --without-xaw3d don't use Xaw3d
2079 --without-xim don't use X11 XIM
2080 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2081 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2082 console
2083 --without-dbus don't compile with D-Bus support
2084 --without-gconf don't compile with GConf support
2085 --without-gsettings don't compile with GSettings support
2086 --without-selinux don't compile with SELinux support
2087 --without-gnutls don't use -lgnutls for SSL/TLS support
2088 --without-makeinfo don't require makeinfo for building manuals
2089 --without-compress-info don't compress the installed Info pages
2090 --with-pkg-config-prog=PATH
2091 path to pkg-config for finding GTK and librsvg
2092 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2093 /usr/lib, or /usr/lib64 on some platforms.
2094 --with-gameuser=USER user for shared game score files
2095 --with-gnustep-conf=PATH
2096 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2097 or /etc/GNUstep/GNUstep.conf
2098 --with-x use the X Window System
2100 Some influential environment variables:
2101 CC C compiler command
2102 CFLAGS C compiler flags
2103 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2104 nonstandard directory <lib dir>
2105 LIBS libraries to pass to the linker, e.g. -l<library>
2106 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2107 you have headers in a nonstandard directory <include dir>
2108 CPP C preprocessor
2109 XMKMF Path to xmkmf, Makefile generator for X Window System
2111 Use these variables to override the choices made by `configure' or to help
2112 it to find libraries and programs with nonstandard names/locations.
2114 Report bugs to the package provider.
2115 _ACEOF
2116 ac_status=$?
2119 if test "$ac_init_help" = "recursive"; then
2120 # If there are subdirs, report their specific --help.
2121 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2122 test -d "$ac_dir" ||
2123 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2124 continue
2125 ac_builddir=.
2127 case "$ac_dir" in
2128 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2130 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2131 # A ".." for each directory in $ac_dir_suffix.
2132 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2133 case $ac_top_builddir_sub in
2134 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2135 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2136 esac ;;
2137 esac
2138 ac_abs_top_builddir=$ac_pwd
2139 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2140 # for backward compatibility:
2141 ac_top_builddir=$ac_top_build_prefix
2143 case $srcdir in
2144 .) # We are building in place.
2145 ac_srcdir=.
2146 ac_top_srcdir=$ac_top_builddir_sub
2147 ac_abs_top_srcdir=$ac_pwd ;;
2148 [\\/]* | ?:[\\/]* ) # Absolute name.
2149 ac_srcdir=$srcdir$ac_dir_suffix;
2150 ac_top_srcdir=$srcdir
2151 ac_abs_top_srcdir=$srcdir ;;
2152 *) # Relative name.
2153 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2154 ac_top_srcdir=$ac_top_build_prefix$srcdir
2155 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2156 esac
2157 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2159 cd "$ac_dir" || { ac_status=$?; continue; }
2160 # Check for guested configure.
2161 if test -f "$ac_srcdir/configure.gnu"; then
2162 echo &&
2163 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2164 elif test -f "$ac_srcdir/configure"; then
2165 echo &&
2166 $SHELL "$ac_srcdir/configure" --help=recursive
2167 else
2168 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2169 fi || ac_status=$?
2170 cd "$ac_pwd" || { ac_status=$?; break; }
2171 done
2174 test -n "$ac_init_help" && exit $ac_status
2175 if $ac_init_version; then
2176 cat <<\_ACEOF
2177 emacs configure 24.2.50
2178 generated by GNU Autoconf 2.65
2180 Copyright (C) 2009 Free Software Foundation, Inc.
2181 This configure script is free software; the Free Software Foundation
2182 gives unlimited permission to copy, distribute and modify it.
2183 _ACEOF
2184 exit
2187 ## ------------------------ ##
2188 ## Autoconf initialization. ##
2189 ## ------------------------ ##
2191 # ac_fn_c_try_compile LINENO
2192 # --------------------------
2193 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2194 ac_fn_c_try_compile ()
2196 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2197 rm -f conftest.$ac_objext
2198 if { { ac_try="$ac_compile"
2199 case "(($ac_try" in
2200 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2201 *) ac_try_echo=$ac_try;;
2202 esac
2203 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2204 $as_echo "$ac_try_echo"; } >&5
2205 (eval "$ac_compile") 2>conftest.err
2206 ac_status=$?
2207 if test -s conftest.err; then
2208 grep -v '^ *+' conftest.err >conftest.er1
2209 cat conftest.er1 >&5
2210 mv -f conftest.er1 conftest.err
2212 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2213 test $ac_status = 0; } && {
2214 test -z "$ac_c_werror_flag" ||
2215 test ! -s conftest.err
2216 } && test -s conftest.$ac_objext; then :
2217 ac_retval=0
2218 else
2219 $as_echo "$as_me: failed program was:" >&5
2220 sed 's/^/| /' conftest.$ac_ext >&5
2222 ac_retval=1
2224 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2225 as_fn_set_status $ac_retval
2227 } # ac_fn_c_try_compile
2229 # ac_fn_c_try_cpp LINENO
2230 # ----------------------
2231 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2232 ac_fn_c_try_cpp ()
2234 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2235 if { { ac_try="$ac_cpp conftest.$ac_ext"
2236 case "(($ac_try" in
2237 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2238 *) ac_try_echo=$ac_try;;
2239 esac
2240 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2241 $as_echo "$ac_try_echo"; } >&5
2242 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2243 ac_status=$?
2244 if test -s conftest.err; then
2245 grep -v '^ *+' conftest.err >conftest.er1
2246 cat conftest.er1 >&5
2247 mv -f conftest.er1 conftest.err
2249 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2250 test $ac_status = 0; } >/dev/null && {
2251 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2252 test ! -s conftest.err
2253 }; then :
2254 ac_retval=0
2255 else
2256 $as_echo "$as_me: failed program was:" >&5
2257 sed 's/^/| /' conftest.$ac_ext >&5
2259 ac_retval=1
2261 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2262 as_fn_set_status $ac_retval
2264 } # ac_fn_c_try_cpp
2266 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2267 # -------------------------------------------------------
2268 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2269 # the include files in INCLUDES and setting the cache variable VAR
2270 # accordingly.
2271 ac_fn_c_check_header_mongrel ()
2273 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2274 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2276 $as_echo_n "checking for $2... " >&6; }
2277 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2278 $as_echo_n "(cached) " >&6
2280 eval ac_res=\$$3
2281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2282 $as_echo "$ac_res" >&6; }
2283 else
2284 # Is the header compilable?
2285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2286 $as_echo_n "checking $2 usability... " >&6; }
2287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2288 /* end confdefs.h. */
2290 #include <$2>
2291 _ACEOF
2292 if ac_fn_c_try_compile "$LINENO"; then :
2293 ac_header_compiler=yes
2294 else
2295 ac_header_compiler=no
2297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2299 $as_echo "$ac_header_compiler" >&6; }
2301 # Is the header present?
2302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2303 $as_echo_n "checking $2 presence... " >&6; }
2304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2305 /* end confdefs.h. */
2306 #include <$2>
2307 _ACEOF
2308 if ac_fn_c_try_cpp "$LINENO"; then :
2309 ac_header_preproc=yes
2310 else
2311 ac_header_preproc=no
2313 rm -f conftest.err conftest.$ac_ext
2314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2315 $as_echo "$ac_header_preproc" >&6; }
2317 # So? What about this header?
2318 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2319 yes:no: )
2320 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2321 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2322 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2323 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2325 no:yes:* )
2326 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2327 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2328 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2329 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2330 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2331 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2332 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2333 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2334 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2335 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2337 esac
2338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2339 $as_echo_n "checking for $2... " >&6; }
2340 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2341 $as_echo_n "(cached) " >&6
2342 else
2343 eval "$3=\$ac_header_compiler"
2345 eval ac_res=\$$3
2346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2347 $as_echo "$ac_res" >&6; }
2349 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2351 } # ac_fn_c_check_header_mongrel
2353 # ac_fn_c_try_run LINENO
2354 # ----------------------
2355 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2356 # that executables *can* be run.
2357 ac_fn_c_try_run ()
2359 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2360 if { { ac_try="$ac_link"
2361 case "(($ac_try" in
2362 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2363 *) ac_try_echo=$ac_try;;
2364 esac
2365 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2366 $as_echo "$ac_try_echo"; } >&5
2367 (eval "$ac_link") 2>&5
2368 ac_status=$?
2369 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2370 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2371 { { case "(($ac_try" in
2372 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2373 *) ac_try_echo=$ac_try;;
2374 esac
2375 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2376 $as_echo "$ac_try_echo"; } >&5
2377 (eval "$ac_try") 2>&5
2378 ac_status=$?
2379 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2380 test $ac_status = 0; }; }; then :
2381 ac_retval=0
2382 else
2383 $as_echo "$as_me: program exited with status $ac_status" >&5
2384 $as_echo "$as_me: failed program was:" >&5
2385 sed 's/^/| /' conftest.$ac_ext >&5
2387 ac_retval=$ac_status
2389 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2390 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2391 as_fn_set_status $ac_retval
2393 } # ac_fn_c_try_run
2395 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2396 # -------------------------------------------------------
2397 # Tests whether HEADER exists and can be compiled using the include files in
2398 # INCLUDES, setting the cache variable VAR accordingly.
2399 ac_fn_c_check_header_compile ()
2401 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2403 $as_echo_n "checking for $2... " >&6; }
2404 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2405 $as_echo_n "(cached) " >&6
2406 else
2407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2408 /* end confdefs.h. */
2410 #include <$2>
2411 _ACEOF
2412 if ac_fn_c_try_compile "$LINENO"; then :
2413 eval "$3=yes"
2414 else
2415 eval "$3=no"
2417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2419 eval ac_res=\$$3
2420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2421 $as_echo "$ac_res" >&6; }
2422 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2424 } # ac_fn_c_check_header_compile
2426 # ac_fn_c_try_link LINENO
2427 # -----------------------
2428 # Try to link conftest.$ac_ext, and return whether this succeeded.
2429 ac_fn_c_try_link ()
2431 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2432 rm -f conftest.$ac_objext conftest$ac_exeext
2433 if { { ac_try="$ac_link"
2434 case "(($ac_try" in
2435 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2436 *) ac_try_echo=$ac_try;;
2437 esac
2438 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2439 $as_echo "$ac_try_echo"; } >&5
2440 (eval "$ac_link") 2>conftest.err
2441 ac_status=$?
2442 if test -s conftest.err; then
2443 grep -v '^ *+' conftest.err >conftest.er1
2444 cat conftest.er1 >&5
2445 mv -f conftest.er1 conftest.err
2447 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2448 test $ac_status = 0; } && {
2449 test -z "$ac_c_werror_flag" ||
2450 test ! -s conftest.err
2451 } && test -s conftest$ac_exeext && {
2452 test "$cross_compiling" = yes ||
2453 $as_test_x conftest$ac_exeext
2454 }; then :
2455 ac_retval=0
2456 else
2457 $as_echo "$as_me: failed program was:" >&5
2458 sed 's/^/| /' conftest.$ac_ext >&5
2460 ac_retval=1
2462 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2463 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2464 # interfere with the next link command; also delete a directory that is
2465 # left behind by Apple's compiler. We do this before executing the actions.
2466 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2467 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2468 as_fn_set_status $ac_retval
2470 } # ac_fn_c_try_link
2472 # ac_fn_c_check_decl LINENO SYMBOL VAR
2473 # ------------------------------------
2474 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2475 ac_fn_c_check_decl ()
2477 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2479 $as_echo_n "checking whether $2 is declared... " >&6; }
2480 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2481 $as_echo_n "(cached) " >&6
2482 else
2483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2484 /* end confdefs.h. */
2487 main ()
2489 #ifndef $2
2490 (void) $2;
2491 #endif
2494 return 0;
2496 _ACEOF
2497 if ac_fn_c_try_compile "$LINENO"; then :
2498 eval "$3=yes"
2499 else
2500 eval "$3=no"
2502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2504 eval ac_res=\$$3
2505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2506 $as_echo "$ac_res" >&6; }
2507 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2509 } # ac_fn_c_check_decl
2511 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2512 # ----------------------------------------------
2513 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2514 ac_fn_c_check_header_preproc ()
2516 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2518 $as_echo_n "checking for $2... " >&6; }
2519 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2520 $as_echo_n "(cached) " >&6
2521 else
2522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2523 /* end confdefs.h. */
2524 #include <$2>
2525 _ACEOF
2526 if ac_fn_c_try_cpp "$LINENO"; then :
2527 eval "$3=yes"
2528 else
2529 eval "$3=no"
2531 rm -f conftest.err conftest.$ac_ext
2533 eval ac_res=\$$3
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2535 $as_echo "$ac_res" >&6; }
2536 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2538 } # ac_fn_c_check_header_preproc
2540 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2541 # ----------------------------------------------------
2542 # Tries to find if the field MEMBER exists in type AGGR, after including
2543 # INCLUDES, setting cache variable VAR accordingly.
2544 ac_fn_c_check_member ()
2546 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2548 $as_echo_n "checking for $2.$3... " >&6; }
2549 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2550 $as_echo_n "(cached) " >&6
2551 else
2552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2553 /* end confdefs.h. */
2556 main ()
2558 static $2 ac_aggr;
2559 if (ac_aggr.$3)
2560 return 0;
2562 return 0;
2564 _ACEOF
2565 if ac_fn_c_try_compile "$LINENO"; then :
2566 eval "$4=yes"
2567 else
2568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2569 /* end confdefs.h. */
2572 main ()
2574 static $2 ac_aggr;
2575 if (sizeof ac_aggr.$3)
2576 return 0;
2578 return 0;
2580 _ACEOF
2581 if ac_fn_c_try_compile "$LINENO"; then :
2582 eval "$4=yes"
2583 else
2584 eval "$4=no"
2586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2590 eval ac_res=\$$4
2591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2592 $as_echo "$ac_res" >&6; }
2593 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2595 } # ac_fn_c_check_member
2597 # ac_fn_c_check_func LINENO FUNC VAR
2598 # ----------------------------------
2599 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2600 ac_fn_c_check_func ()
2602 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2604 $as_echo_n "checking for $2... " >&6; }
2605 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2606 $as_echo_n "(cached) " >&6
2607 else
2608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2609 /* end confdefs.h. */
2610 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2611 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2612 #define $2 innocuous_$2
2614 /* System header to define __stub macros and hopefully few prototypes,
2615 which can conflict with char $2 (); below.
2616 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2617 <limits.h> exists even on freestanding compilers. */
2619 #ifdef __STDC__
2620 # include <limits.h>
2621 #else
2622 # include <assert.h>
2623 #endif
2625 #undef $2
2627 /* Override any GCC internal prototype to avoid an error.
2628 Use char because int might match the return type of a GCC
2629 builtin and then its argument prototype would still apply. */
2630 #ifdef __cplusplus
2631 extern "C"
2632 #endif
2633 char $2 ();
2634 /* The GNU C library defines this for functions which it implements
2635 to always fail with ENOSYS. Some functions are actually named
2636 something starting with __ and the normal name is an alias. */
2637 #if defined __stub_$2 || defined __stub___$2
2638 choke me
2639 #endif
2642 main ()
2644 return $2 ();
2646 return 0;
2648 _ACEOF
2649 if ac_fn_c_try_link "$LINENO"; then :
2650 eval "$3=yes"
2651 else
2652 eval "$3=no"
2654 rm -f core conftest.err conftest.$ac_objext \
2655 conftest$ac_exeext conftest.$ac_ext
2657 eval ac_res=\$$3
2658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2659 $as_echo "$ac_res" >&6; }
2660 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2662 } # ac_fn_c_check_func
2664 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2665 # -------------------------------------------
2666 # Tests whether TYPE exists after having included INCLUDES, setting cache
2667 # variable VAR accordingly.
2668 ac_fn_c_check_type ()
2670 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2672 $as_echo_n "checking for $2... " >&6; }
2673 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2674 $as_echo_n "(cached) " >&6
2675 else
2676 eval "$3=no"
2677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2678 /* end confdefs.h. */
2681 main ()
2683 if (sizeof ($2))
2684 return 0;
2686 return 0;
2688 _ACEOF
2689 if ac_fn_c_try_compile "$LINENO"; then :
2690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2691 /* end confdefs.h. */
2694 main ()
2696 if (sizeof (($2)))
2697 return 0;
2699 return 0;
2701 _ACEOF
2702 if ac_fn_c_try_compile "$LINENO"; then :
2704 else
2705 eval "$3=yes"
2707 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2709 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2711 eval ac_res=\$$3
2712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2713 $as_echo "$ac_res" >&6; }
2714 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2716 } # ac_fn_c_check_type
2718 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2719 # --------------------------------------------
2720 # Tries to find the compile-time value of EXPR in a program that includes
2721 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2722 # computed
2723 ac_fn_c_compute_int ()
2725 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2726 if test "$cross_compiling" = yes; then
2727 # Depending upon the size, compute the lo and hi bounds.
2728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2729 /* end confdefs.h. */
2732 main ()
2734 static int test_array [1 - 2 * !(($2) >= 0)];
2735 test_array [0] = 0
2738 return 0;
2740 _ACEOF
2741 if ac_fn_c_try_compile "$LINENO"; then :
2742 ac_lo=0 ac_mid=0
2743 while :; do
2744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2745 /* end confdefs.h. */
2748 main ()
2750 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2751 test_array [0] = 0
2754 return 0;
2756 _ACEOF
2757 if ac_fn_c_try_compile "$LINENO"; then :
2758 ac_hi=$ac_mid; break
2759 else
2760 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2761 if test $ac_lo -le $ac_mid; then
2762 ac_lo= ac_hi=
2763 break
2765 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2768 done
2769 else
2770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2771 /* end confdefs.h. */
2774 main ()
2776 static int test_array [1 - 2 * !(($2) < 0)];
2777 test_array [0] = 0
2780 return 0;
2782 _ACEOF
2783 if ac_fn_c_try_compile "$LINENO"; then :
2784 ac_hi=-1 ac_mid=-1
2785 while :; do
2786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2787 /* end confdefs.h. */
2790 main ()
2792 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2793 test_array [0] = 0
2796 return 0;
2798 _ACEOF
2799 if ac_fn_c_try_compile "$LINENO"; then :
2800 ac_lo=$ac_mid; break
2801 else
2802 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2803 if test $ac_mid -le $ac_hi; then
2804 ac_lo= ac_hi=
2805 break
2807 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2809 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2810 done
2811 else
2812 ac_lo= ac_hi=
2814 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2817 # Binary search between lo and hi bounds.
2818 while test "x$ac_lo" != "x$ac_hi"; do
2819 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2821 /* end confdefs.h. */
2824 main ()
2826 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2827 test_array [0] = 0
2830 return 0;
2832 _ACEOF
2833 if ac_fn_c_try_compile "$LINENO"; then :
2834 ac_hi=$ac_mid
2835 else
2836 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2839 done
2840 case $ac_lo in #((
2841 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2842 '') ac_retval=1 ;;
2843 esac
2844 else
2845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2846 /* end confdefs.h. */
2848 static long int longval () { return $2; }
2849 static unsigned long int ulongval () { return $2; }
2850 #include <stdio.h>
2851 #include <stdlib.h>
2853 main ()
2856 FILE *f = fopen ("conftest.val", "w");
2857 if (! f)
2858 return 1;
2859 if (($2) < 0)
2861 long int i = longval ();
2862 if (i != ($2))
2863 return 1;
2864 fprintf (f, "%ld", i);
2866 else
2868 unsigned long int i = ulongval ();
2869 if (i != ($2))
2870 return 1;
2871 fprintf (f, "%lu", i);
2873 /* Do not output a trailing newline, as this causes \r\n confusion
2874 on some platforms. */
2875 return ferror (f) || fclose (f) != 0;
2878 return 0;
2880 _ACEOF
2881 if ac_fn_c_try_run "$LINENO"; then :
2882 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2883 else
2884 ac_retval=1
2886 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2887 conftest.$ac_objext conftest.beam conftest.$ac_ext
2888 rm -f conftest.val
2891 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2892 as_fn_set_status $ac_retval
2894 } # ac_fn_c_compute_int
2895 cat >config.log <<_ACEOF
2896 This file contains any messages produced by compilers while
2897 running configure, to aid debugging if configure makes a mistake.
2899 It was created by emacs $as_me 24.2.50, which was
2900 generated by GNU Autoconf 2.65. Invocation command line was
2902 $ $0 $@
2904 _ACEOF
2905 exec 5>>config.log
2907 cat <<_ASUNAME
2908 ## --------- ##
2909 ## Platform. ##
2910 ## --------- ##
2912 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2913 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2914 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2915 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2916 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2918 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2919 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2921 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2922 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2923 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2924 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2925 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2926 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2927 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2929 _ASUNAME
2931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2932 for as_dir in $PATH
2934 IFS=$as_save_IFS
2935 test -z "$as_dir" && as_dir=.
2936 $as_echo "PATH: $as_dir"
2937 done
2938 IFS=$as_save_IFS
2940 } >&5
2942 cat >&5 <<_ACEOF
2945 ## ----------- ##
2946 ## Core tests. ##
2947 ## ----------- ##
2949 _ACEOF
2952 # Keep a trace of the command line.
2953 # Strip out --no-create and --no-recursion so they do not pile up.
2954 # Strip out --silent because we don't want to record it for future runs.
2955 # Also quote any args containing shell meta-characters.
2956 # Make two passes to allow for proper duplicate-argument suppression.
2957 ac_configure_args=
2958 ac_configure_args0=
2959 ac_configure_args1=
2960 ac_must_keep_next=false
2961 for ac_pass in 1 2
2963 for ac_arg
2965 case $ac_arg in
2966 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2967 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2968 | -silent | --silent | --silen | --sile | --sil)
2969 continue ;;
2970 *\'*)
2971 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2972 esac
2973 case $ac_pass in
2974 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2976 as_fn_append ac_configure_args1 " '$ac_arg'"
2977 if test $ac_must_keep_next = true; then
2978 ac_must_keep_next=false # Got value, back to normal.
2979 else
2980 case $ac_arg in
2981 *=* | --config-cache | -C | -disable-* | --disable-* \
2982 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2983 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2984 | -with-* | --with-* | -without-* | --without-* | --x)
2985 case "$ac_configure_args0 " in
2986 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2987 esac
2989 -* ) ac_must_keep_next=true ;;
2990 esac
2992 as_fn_append ac_configure_args " '$ac_arg'"
2994 esac
2995 done
2996 done
2997 { ac_configure_args0=; unset ac_configure_args0;}
2998 { ac_configure_args1=; unset ac_configure_args1;}
3000 # When interrupted or exit'd, cleanup temporary files, and complete
3001 # config.log. We remove comments because anyway the quotes in there
3002 # would cause problems or look ugly.
3003 # WARNING: Use '\'' to represent an apostrophe within the trap.
3004 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3005 trap 'exit_status=$?
3006 # Save into config.log some information that might help in debugging.
3008 echo
3010 cat <<\_ASBOX
3011 ## ---------------- ##
3012 ## Cache variables. ##
3013 ## ---------------- ##
3014 _ASBOX
3015 echo
3016 # The following way of writing the cache mishandles newlines in values,
3018 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3019 eval ac_val=\$$ac_var
3020 case $ac_val in #(
3021 *${as_nl}*)
3022 case $ac_var in #(
3023 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3024 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3025 esac
3026 case $ac_var in #(
3027 _ | IFS | as_nl) ;; #(
3028 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3029 *) { eval $ac_var=; unset $ac_var;} ;;
3030 esac ;;
3031 esac
3032 done
3033 (set) 2>&1 |
3034 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3035 *${as_nl}ac_space=\ *)
3036 sed -n \
3037 "s/'\''/'\''\\\\'\'''\''/g;
3038 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3039 ;; #(
3041 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3043 esac |
3044 sort
3046 echo
3048 cat <<\_ASBOX
3049 ## ----------------- ##
3050 ## Output variables. ##
3051 ## ----------------- ##
3052 _ASBOX
3053 echo
3054 for ac_var in $ac_subst_vars
3056 eval ac_val=\$$ac_var
3057 case $ac_val in
3058 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3059 esac
3060 $as_echo "$ac_var='\''$ac_val'\''"
3061 done | sort
3062 echo
3064 if test -n "$ac_subst_files"; then
3065 cat <<\_ASBOX
3066 ## ------------------- ##
3067 ## File substitutions. ##
3068 ## ------------------- ##
3069 _ASBOX
3070 echo
3071 for ac_var in $ac_subst_files
3073 eval ac_val=\$$ac_var
3074 case $ac_val in
3075 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3076 esac
3077 $as_echo "$ac_var='\''$ac_val'\''"
3078 done | sort
3079 echo
3082 if test -s confdefs.h; then
3083 cat <<\_ASBOX
3084 ## ----------- ##
3085 ## confdefs.h. ##
3086 ## ----------- ##
3087 _ASBOX
3088 echo
3089 cat confdefs.h
3090 echo
3092 test "$ac_signal" != 0 &&
3093 $as_echo "$as_me: caught signal $ac_signal"
3094 $as_echo "$as_me: exit $exit_status"
3095 } >&5
3096 rm -f core *.core core.conftest.* &&
3097 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3098 exit $exit_status
3100 for ac_signal in 1 2 13 15; do
3101 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3102 done
3103 ac_signal=0
3105 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3106 rm -f -r conftest* confdefs.h
3108 $as_echo "/* confdefs.h */" > confdefs.h
3110 # Predefined preprocessor variables.
3112 cat >>confdefs.h <<_ACEOF
3113 #define PACKAGE_NAME "$PACKAGE_NAME"
3114 _ACEOF
3116 cat >>confdefs.h <<_ACEOF
3117 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3118 _ACEOF
3120 cat >>confdefs.h <<_ACEOF
3121 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3122 _ACEOF
3124 cat >>confdefs.h <<_ACEOF
3125 #define PACKAGE_STRING "$PACKAGE_STRING"
3126 _ACEOF
3128 cat >>confdefs.h <<_ACEOF
3129 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3130 _ACEOF
3132 cat >>confdefs.h <<_ACEOF
3133 #define PACKAGE_URL "$PACKAGE_URL"
3134 _ACEOF
3137 # Let the site file select an alternate cache file if it wants to.
3138 # Prefer an explicitly selected file to automatically selected ones.
3139 ac_site_file1=NONE
3140 ac_site_file2=NONE
3141 if test -n "$CONFIG_SITE"; then
3142 ac_site_file1=$CONFIG_SITE
3143 elif test "x$prefix" != xNONE; then
3144 ac_site_file1=$prefix/share/config.site
3145 ac_site_file2=$prefix/etc/config.site
3146 else
3147 ac_site_file1=$ac_default_prefix/share/config.site
3148 ac_site_file2=$ac_default_prefix/etc/config.site
3150 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3152 test "x$ac_site_file" = xNONE && continue
3153 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3154 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3155 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3156 sed 's/^/| /' "$ac_site_file" >&5
3157 . "$ac_site_file"
3159 done
3161 if test -r "$cache_file"; then
3162 # Some versions of bash will fail to source /dev/null (special files
3163 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3164 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3165 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3166 $as_echo "$as_me: loading cache $cache_file" >&6;}
3167 case $cache_file in
3168 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3169 *) . "./$cache_file";;
3170 esac
3172 else
3173 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3174 $as_echo "$as_me: creating cache $cache_file" >&6;}
3175 >$cache_file
3178 as_fn_append ac_header_list " linux/version.h"
3179 as_fn_append ac_header_list " sys/systeminfo.h"
3180 as_fn_append ac_header_list " stdio_ext.h"
3181 as_fn_append ac_header_list " fcntl.h"
3182 as_fn_append ac_header_list " coff.h"
3183 as_fn_append ac_header_list " pty.h"
3184 as_fn_append ac_header_list " sys/vlimit.h"
3185 as_fn_append ac_header_list " sys/resource.h"
3186 as_fn_append ac_header_list " sys/utsname.h"
3187 as_fn_append ac_header_list " pwd.h"
3188 as_fn_append ac_header_list " utmp.h"
3189 as_fn_append ac_header_list " dirent.h"
3190 as_fn_append ac_header_list " util.h"
3191 as_fn_append ac_header_list " sys/socket.h"
3192 as_fn_append ac_header_list " stdlib.h"
3193 as_fn_append ac_header_list " unistd.h"
3194 as_fn_append ac_header_list " sys/param.h"
3195 as_fn_append ac_header_list " pthread.h"
3196 as_fn_append ac_header_list " malloc/malloc.h"
3197 as_fn_append ac_header_list " maillock.h"
3198 as_fn_append ac_header_list " sys/un.h"
3199 as_fn_append ac_func_list " tzset"
3200 as_fn_append ac_func_list " readlinkat"
3201 as_fn_append ac_header_list " execinfo.h"
3202 gl_getopt_required=GNU
3203 as_fn_append ac_header_list " getopt.h"
3204 as_fn_append ac_func_list " gettimeofday"
3205 as_fn_append ac_func_list " nanotime"
3206 as_fn_append ac_header_list " sys/time.h"
3207 as_fn_append ac_header_list " wchar.h"
3208 as_fn_append ac_header_list " stdint.h"
3209 as_fn_append ac_header_list " inttypes.h"
3210 as_fn_append ac_func_list " lstat"
3211 as_fn_append ac_func_list " alarm"
3212 as_fn_append ac_header_list " sys/select.h"
3213 as_fn_append ac_func_list " pselect"
3214 as_fn_append ac_func_list " pthread_sigmask"
3215 as_fn_append ac_func_list " readlink"
3216 as_fn_append ac_func_list " strtoimax"
3217 as_fn_append ac_func_list " strtoumax"
3218 as_fn_append ac_func_list " symlink"
3219 as_fn_append ac_header_list " sys/stat.h"
3220 as_fn_append ac_func_list " localtime_r"
3221 as_fn_append ac_header_list " utime.h"
3222 as_fn_append ac_func_list " futimes"
3223 as_fn_append ac_func_list " futimesat"
3224 as_fn_append ac_func_list " futimens"
3225 as_fn_append ac_func_list " utimensat"
3226 as_fn_append ac_func_list " lutimes"
3227 # Check that the precious variables saved in the cache have kept the same
3228 # value.
3229 ac_cache_corrupted=false
3230 for ac_var in $ac_precious_vars; do
3231 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3232 eval ac_new_set=\$ac_env_${ac_var}_set
3233 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3234 eval ac_new_val=\$ac_env_${ac_var}_value
3235 case $ac_old_set,$ac_new_set in
3236 set,)
3237 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3238 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3239 ac_cache_corrupted=: ;;
3240 ,set)
3241 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3242 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3243 ac_cache_corrupted=: ;;
3244 ,);;
3246 if test "x$ac_old_val" != "x$ac_new_val"; then
3247 # differences in whitespace do not lead to failure.
3248 ac_old_val_w=`echo x $ac_old_val`
3249 ac_new_val_w=`echo x $ac_new_val`
3250 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3251 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3252 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3253 ac_cache_corrupted=:
3254 else
3255 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3256 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3257 eval $ac_var=\$ac_old_val
3259 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3260 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3261 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3262 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3263 fi;;
3264 esac
3265 # Pass precious variables to config.status.
3266 if test "$ac_new_set" = set; then
3267 case $ac_new_val in
3268 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3269 *) ac_arg=$ac_var=$ac_new_val ;;
3270 esac
3271 case " $ac_configure_args " in
3272 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3273 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3274 esac
3276 done
3277 if $ac_cache_corrupted; then
3278 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3279 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3280 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3281 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3282 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3284 ## -------------------- ##
3285 ## Main body of script. ##
3286 ## -------------------- ##
3288 ac_ext=c
3289 ac_cpp='$CPP $CPPFLAGS'
3290 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3291 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3292 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3295 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3298 ac_aux_dir=
3299 for ac_dir in build-aux "$srcdir"/build-aux; do
3300 for ac_t in install-sh install.sh shtool; do
3301 if test -f "$ac_dir/$ac_t"; then
3302 ac_aux_dir=$ac_dir
3303 ac_install_sh="$ac_aux_dir/$ac_t -c"
3304 break 2
3306 done
3307 done
3308 if test -z "$ac_aux_dir"; then
3309 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3312 # These three variables are undocumented and unsupported,
3313 # and are intended to be withdrawn in a future Autoconf release.
3314 # They can cause serious problems if a builder's source tree is in a directory
3315 # whose full name contains unusual characters.
3316 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3317 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3318 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3321 am__api_version='1.11'
3323 # Find a good install program. We prefer a C program (faster),
3324 # so one script is as good as another. But avoid the broken or
3325 # incompatible versions:
3326 # SysV /etc/install, /usr/sbin/install
3327 # SunOS /usr/etc/install
3328 # IRIX /sbin/install
3329 # AIX /bin/install
3330 # AmigaOS /C/install, which installs bootblocks on floppy discs
3331 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3332 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3333 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3334 # OS/2's system install, which has a completely different semantic
3335 # ./install, which can be erroneously created by make from ./install.sh.
3336 # Reject install programs that cannot install multiple files.
3337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3338 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3339 if test -z "$INSTALL"; then
3340 if test "${ac_cv_path_install+set}" = set; then :
3341 $as_echo_n "(cached) " >&6
3342 else
3343 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3344 for as_dir in $PATH
3346 IFS=$as_save_IFS
3347 test -z "$as_dir" && as_dir=.
3348 # Account for people who put trailing slashes in PATH elements.
3349 case $as_dir/ in #((
3350 ./ | .// | /[cC]/* | \
3351 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3352 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3353 /usr/ucb/* ) ;;
3355 # OSF1 and SCO ODT 3.0 have their own names for install.
3356 # Don't use installbsd from OSF since it installs stuff as root
3357 # by default.
3358 for ac_prog in ginstall scoinst install; do
3359 for ac_exec_ext in '' $ac_executable_extensions; do
3360 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3361 if test $ac_prog = install &&
3362 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3363 # AIX install. It has an incompatible calling convention.
3365 elif test $ac_prog = install &&
3366 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3367 # program-specific install script used by HP pwplus--don't use.
3369 else
3370 rm -rf conftest.one conftest.two conftest.dir
3371 echo one > conftest.one
3372 echo two > conftest.two
3373 mkdir conftest.dir
3374 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3375 test -s conftest.one && test -s conftest.two &&
3376 test -s conftest.dir/conftest.one &&
3377 test -s conftest.dir/conftest.two
3378 then
3379 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3380 break 3
3384 done
3385 done
3387 esac
3389 done
3390 IFS=$as_save_IFS
3392 rm -rf conftest.one conftest.two conftest.dir
3395 if test "${ac_cv_path_install+set}" = set; then
3396 INSTALL=$ac_cv_path_install
3397 else
3398 # As a last resort, use the slow shell script. Don't cache a
3399 # value for INSTALL within a source directory, because that will
3400 # break other packages using the cache if that directory is
3401 # removed, or if the value is a relative name.
3402 INSTALL=$ac_install_sh
3405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3406 $as_echo "$INSTALL" >&6; }
3408 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3409 # It thinks the first close brace ends the variable substitution.
3410 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3412 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3414 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3417 $as_echo_n "checking whether build environment is sane... " >&6; }
3418 # Just in case
3419 sleep 1
3420 echo timestamp > conftest.file
3421 # Reject unsafe characters in $srcdir or the absolute working directory
3422 # name. Accept space and tab only in the latter.
3423 am_lf='
3425 case `pwd` in
3426 *[\\\"\#\$\&\'\`$am_lf]*)
3427 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3428 esac
3429 case $srcdir in
3430 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3431 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3432 esac
3434 # Do `set' in a subshell so we don't clobber the current shell's
3435 # arguments. Must try -L first in case configure is actually a
3436 # symlink; some systems play weird games with the mod time of symlinks
3437 # (eg FreeBSD returns the mod time of the symlink's containing
3438 # directory).
3439 if (
3440 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3441 if test "$*" = "X"; then
3442 # -L didn't work.
3443 set X `ls -t "$srcdir/configure" conftest.file`
3445 rm -f conftest.file
3446 if test "$*" != "X $srcdir/configure conftest.file" \
3447 && test "$*" != "X conftest.file $srcdir/configure"; then
3449 # If neither matched, then we have a broken ls. This can happen
3450 # if, for instance, CONFIG_SHELL is bash and it inherits a
3451 # broken ls alias from the environment. This has actually
3452 # happened. Such a system could not be considered "sane".
3453 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3454 alias in your environment" "$LINENO" 5
3457 test "$2" = conftest.file
3459 then
3460 # Ok.
3462 else
3463 as_fn_error "newly created file is older than distributed files!
3464 Check your system clock" "$LINENO" 5
3466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3467 $as_echo "yes" >&6; }
3468 test "$program_prefix" != NONE &&
3469 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3470 # Use a double $ so make ignores it.
3471 test "$program_suffix" != NONE &&
3472 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3473 # Double any \ or $.
3474 # By default was `s,x,x', remove it if useless.
3475 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3476 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3478 # expand $ac_aux_dir to an absolute path
3479 am_aux_dir=`cd $ac_aux_dir && pwd`
3481 if test x"${MISSING+set}" != xset; then
3482 case $am_aux_dir in
3483 *\ * | *\ *)
3484 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3486 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3487 esac
3489 # Use eval to expand $SHELL
3490 if eval "$MISSING --run true"; then
3491 am_missing_run="$MISSING --run "
3492 else
3493 am_missing_run=
3494 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3495 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3498 if test x"${install_sh}" != xset; then
3499 case $am_aux_dir in
3500 *\ * | *\ *)
3501 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3503 install_sh="\${SHELL} $am_aux_dir/install-sh"
3504 esac
3507 # Installed binaries are usually stripped using `strip' when the user
3508 # run `make install-strip'. However `strip' might not be the right
3509 # tool to use in cross-compilation environments, therefore Automake
3510 # will honor the `STRIP' environment variable to overrule this program.
3511 if test "$cross_compiling" != no; then
3512 if test -n "$ac_tool_prefix"; then
3513 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3514 set dummy ${ac_tool_prefix}strip; ac_word=$2
3515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3516 $as_echo_n "checking for $ac_word... " >&6; }
3517 if test "${ac_cv_prog_STRIP+set}" = set; then :
3518 $as_echo_n "(cached) " >&6
3519 else
3520 if test -n "$STRIP"; then
3521 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3522 else
3523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3524 for as_dir in $PATH
3526 IFS=$as_save_IFS
3527 test -z "$as_dir" && as_dir=.
3528 for ac_exec_ext in '' $ac_executable_extensions; do
3529 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3530 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3532 break 2
3534 done
3535 done
3536 IFS=$as_save_IFS
3540 STRIP=$ac_cv_prog_STRIP
3541 if test -n "$STRIP"; then
3542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3543 $as_echo "$STRIP" >&6; }
3544 else
3545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3546 $as_echo "no" >&6; }
3551 if test -z "$ac_cv_prog_STRIP"; then
3552 ac_ct_STRIP=$STRIP
3553 # Extract the first word of "strip", so it can be a program name with args.
3554 set dummy strip; ac_word=$2
3555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3556 $as_echo_n "checking for $ac_word... " >&6; }
3557 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3558 $as_echo_n "(cached) " >&6
3559 else
3560 if test -n "$ac_ct_STRIP"; then
3561 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3562 else
3563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3564 for as_dir in $PATH
3566 IFS=$as_save_IFS
3567 test -z "$as_dir" && as_dir=.
3568 for ac_exec_ext in '' $ac_executable_extensions; do
3569 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3570 ac_cv_prog_ac_ct_STRIP="strip"
3571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3572 break 2
3574 done
3575 done
3576 IFS=$as_save_IFS
3580 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3581 if test -n "$ac_ct_STRIP"; then
3582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3583 $as_echo "$ac_ct_STRIP" >&6; }
3584 else
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3586 $as_echo "no" >&6; }
3589 if test "x$ac_ct_STRIP" = x; then
3590 STRIP=":"
3591 else
3592 case $cross_compiling:$ac_tool_warned in
3593 yes:)
3594 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3595 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3596 ac_tool_warned=yes ;;
3597 esac
3598 STRIP=$ac_ct_STRIP
3600 else
3601 STRIP="$ac_cv_prog_STRIP"
3605 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3608 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3609 if test -z "$MKDIR_P"; then
3610 if test "${ac_cv_path_mkdir+set}" = set; then :
3611 $as_echo_n "(cached) " >&6
3612 else
3613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3614 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3616 IFS=$as_save_IFS
3617 test -z "$as_dir" && as_dir=.
3618 for ac_prog in mkdir gmkdir; do
3619 for ac_exec_ext in '' $ac_executable_extensions; do
3620 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3621 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3622 'mkdir (GNU coreutils) '* | \
3623 'mkdir (coreutils) '* | \
3624 'mkdir (fileutils) '4.1*)
3625 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3626 break 3;;
3627 esac
3628 done
3629 done
3630 done
3631 IFS=$as_save_IFS
3635 test -d ./--version && rmdir ./--version
3636 if test "${ac_cv_path_mkdir+set}" = set; then
3637 MKDIR_P="$ac_cv_path_mkdir -p"
3638 else
3639 # As a last resort, use the slow shell script. Don't cache a
3640 # value for MKDIR_P within a source directory, because that will
3641 # break other packages using the cache if that directory is
3642 # removed, or if the value is a relative name.
3643 MKDIR_P="$ac_install_sh -d"
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3647 $as_echo "$MKDIR_P" >&6; }
3650 mkdir_p="$MKDIR_P"
3651 case $mkdir_p in
3652 [\\/$]* | ?:[\\/]*) ;;
3653 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3654 esac
3656 for ac_prog in gawk mawk nawk awk
3658 # Extract the first word of "$ac_prog", so it can be a program name with args.
3659 set dummy $ac_prog; ac_word=$2
3660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3661 $as_echo_n "checking for $ac_word... " >&6; }
3662 if test "${ac_cv_prog_AWK+set}" = set; then :
3663 $as_echo_n "(cached) " >&6
3664 else
3665 if test -n "$AWK"; then
3666 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3667 else
3668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3669 for as_dir in $PATH
3671 IFS=$as_save_IFS
3672 test -z "$as_dir" && as_dir=.
3673 for ac_exec_ext in '' $ac_executable_extensions; do
3674 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3675 ac_cv_prog_AWK="$ac_prog"
3676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3677 break 2
3679 done
3680 done
3681 IFS=$as_save_IFS
3685 AWK=$ac_cv_prog_AWK
3686 if test -n "$AWK"; then
3687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3688 $as_echo "$AWK" >&6; }
3689 else
3690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3691 $as_echo "no" >&6; }
3695 test -n "$AWK" && break
3696 done
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3699 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3700 set x ${MAKE-make}
3701 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3702 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3703 $as_echo_n "(cached) " >&6
3704 else
3705 cat >conftest.make <<\_ACEOF
3706 SHELL = /bin/sh
3707 all:
3708 @echo '@@@%%%=$(MAKE)=@@@%%%'
3709 _ACEOF
3710 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3711 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3712 *@@@%%%=?*=@@@%%%*)
3713 eval ac_cv_prog_make_${ac_make}_set=yes;;
3715 eval ac_cv_prog_make_${ac_make}_set=no;;
3716 esac
3717 rm -f conftest.make
3719 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3721 $as_echo "yes" >&6; }
3722 SET_MAKE=
3723 else
3724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3725 $as_echo "no" >&6; }
3726 SET_MAKE="MAKE=${MAKE-make}"
3729 rm -rf .tst 2>/dev/null
3730 mkdir .tst 2>/dev/null
3731 if test -d .tst; then
3732 am__leading_dot=.
3733 else
3734 am__leading_dot=_
3736 rmdir .tst 2>/dev/null
3738 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3739 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3740 # is not polluted with repeated "-I."
3741 am__isrc=' -I$(srcdir)'
3742 # test to see if srcdir already configured
3743 if test -f $srcdir/config.status; then
3744 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3748 # test whether we have cygpath
3749 if test -z "$CYGPATH_W"; then
3750 if (cygpath --version) >/dev/null 2>/dev/null; then
3751 CYGPATH_W='cygpath -w'
3752 else
3753 CYGPATH_W=echo
3758 # Define the identity of the package.
3759 PACKAGE='emacs'
3760 VERSION='24.2.50'
3763 cat >>confdefs.h <<_ACEOF
3764 #define PACKAGE "$PACKAGE"
3765 _ACEOF
3768 cat >>confdefs.h <<_ACEOF
3769 #define VERSION "$VERSION"
3770 _ACEOF
3772 # Some tools Automake needs.
3774 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3777 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3780 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3783 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3786 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3788 # We need awk for the "check" target. The system "awk" is bad on
3789 # some platforms.
3790 # Always define AMTAR for backward compatibility.
3792 AMTAR=${AMTAR-"${am_missing_run}tar"}
3794 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3803 lispdir='${datadir}/emacs/${version}/lisp'
3804 leimdir='${datadir}/emacs/${version}/leim'
3805 standardlisppath='${lispdir}:${leimdir}'
3806 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3807 '${datadir}/emacs/site-lisp'
3808 lisppath='${locallisppath}:${standardlisppath}'
3809 etcdir='${datadir}/emacs/${version}/etc'
3810 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3811 docdir='${datadir}/emacs/${version}/etc'
3812 gamedir='${localstatedir}/games/emacs'
3815 # Check whether --with-all was given.
3816 if test "${with_all+set}" = set; then :
3817 withval=$with_all; with_features=$withval
3818 else
3819 with_features=yes
3826 # Check whether --with-pop was given.
3827 if test "${with_pop+set}" = set; then :
3828 withval=$with_pop;
3829 else
3830 with_pop=$with_features
3833 if test "$with_pop" = yes; then
3834 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3839 # Check whether --with-kerberos was given.
3840 if test "${with_kerberos+set}" = set; then :
3841 withval=$with_kerberos;
3842 else
3843 with_kerberos=no
3846 if test "$with_kerberos" != no; then
3847 $as_echo "#define KERBEROS 1" >>confdefs.h
3852 # Check whether --with-kerberos5 was given.
3853 if test "${with_kerberos5+set}" = set; then :
3854 withval=$with_kerberos5;
3855 else
3856 with_kerberos5=no
3859 if test "${with_kerberos5}" != no; then
3860 if test "${with_kerberos}" = no; then
3861 with_kerberos=yes
3862 $as_echo "#define KERBEROS 1" >>confdefs.h
3866 $as_echo "#define KERBEROS5 1" >>confdefs.h
3871 # Check whether --with-hesiod was given.
3872 if test "${with_hesiod+set}" = set; then :
3873 withval=$with_hesiod;
3874 else
3875 with_hesiod=no
3878 if test "$with_hesiod" != no; then
3880 $as_echo "#define HESIOD 1" >>confdefs.h
3885 # Check whether --with-mmdf was given.
3886 if test "${with_mmdf+set}" = set; then :
3887 withval=$with_mmdf;
3888 else
3889 with_mmdf=no
3892 if test "$with_mmdf" != no; then
3894 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3899 # Check whether --with-mail-unlink was given.
3900 if test "${with_mail_unlink+set}" = set; then :
3901 withval=$with_mail_unlink;
3902 else
3903 with_mail_unlink=no
3906 if test "$with_mail_unlink" != no; then
3908 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3913 # Check whether --with-mailhost was given.
3914 if test "${with_mailhost+set}" = set; then :
3915 withval=$with_mailhost;
3916 cat >>confdefs.h <<_ACEOF
3917 #define MAILHOST "$withval"
3918 _ACEOF
3924 # Check whether --with-sound was given.
3925 if test "${with_sound+set}" = set; then :
3926 withval=$with_sound;
3927 else
3928 with_sound=$with_features
3933 # Check whether --with-sync-input was given.
3934 if test "${with_sync_input+set}" = set; then :
3935 withval=$with_sync_input;
3936 else
3937 with_sync_input=$with_features
3940 if test "$with_sync_input" = yes; then
3942 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
3947 # Check whether --with-x-toolkit was given.
3948 if test "${with_x_toolkit+set}" = set; then :
3949 withval=$with_x_toolkit; case "${withval}" in
3950 y | ye | yes ) val=gtk ;;
3951 n | no ) val=no ;;
3952 l | lu | luc | luci | lucid ) val=lucid ;;
3953 a | at | ath | athe | athen | athena ) val=athena ;;
3954 m | mo | mot | moti | motif ) val=motif ;;
3955 g | gt | gtk ) val=gtk ;;
3956 gtk3 ) val=gtk3 ;;
3958 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3959 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3960 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3962 esac
3963 with_x_toolkit=$val
3969 # Check whether --with-wide-int was given.
3970 if test "${with_wide_int+set}" = set; then :
3971 withval=$with_wide_int;
3972 else
3973 with_wide_int=no
3976 if test "$with_wide_int" = yes; then
3978 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3983 # Check whether --with-xpm was given.
3984 if test "${with_xpm+set}" = set; then :
3985 withval=$with_xpm;
3986 else
3987 with_xpm=$with_features
3991 # Check whether --with-jpeg was given.
3992 if test "${with_jpeg+set}" = set; then :
3993 withval=$with_jpeg;
3994 else
3995 with_jpeg=$with_features
3999 # Check whether --with-tiff was given.
4000 if test "${with_tiff+set}" = set; then :
4001 withval=$with_tiff;
4002 else
4003 with_tiff=$with_features
4007 # Check whether --with-gif was given.
4008 if test "${with_gif+set}" = set; then :
4009 withval=$with_gif;
4010 else
4011 with_gif=$with_features
4015 # Check whether --with-png was given.
4016 if test "${with_png+set}" = set; then :
4017 withval=$with_png;
4018 else
4019 with_png=$with_features
4023 # Check whether --with-rsvg was given.
4024 if test "${with_rsvg+set}" = set; then :
4025 withval=$with_rsvg;
4026 else
4027 with_rsvg=$with_features
4031 # Check whether --with-xml2 was given.
4032 if test "${with_xml2+set}" = set; then :
4033 withval=$with_xml2;
4034 else
4035 with_xml2=$with_features
4039 # Check whether --with-imagemagick was given.
4040 if test "${with_imagemagick+set}" = set; then :
4041 withval=$with_imagemagick;
4042 else
4043 with_imagemagick=$with_features
4048 # Check whether --with-xft was given.
4049 if test "${with_xft+set}" = set; then :
4050 withval=$with_xft;
4051 else
4052 with_xft=$with_features
4056 # Check whether --with-libotf was given.
4057 if test "${with_libotf+set}" = set; then :
4058 withval=$with_libotf;
4059 else
4060 with_libotf=$with_features
4064 # Check whether --with-m17n-flt was given.
4065 if test "${with_m17n_flt+set}" = set; then :
4066 withval=$with_m17n_flt;
4067 else
4068 with_m17n_flt=$with_features
4073 # Check whether --with-toolkit-scroll-bars was given.
4074 if test "${with_toolkit_scroll_bars+set}" = set; then :
4075 withval=$with_toolkit_scroll_bars;
4076 else
4077 with_toolkit_scroll_bars=$with_features
4081 # Check whether --with-xaw3d was given.
4082 if test "${with_xaw3d+set}" = set; then :
4083 withval=$with_xaw3d;
4084 else
4085 with_xaw3d=$with_features
4089 # Check whether --with-xim was given.
4090 if test "${with_xim+set}" = set; then :
4091 withval=$with_xim;
4092 else
4093 with_xim=$with_features
4097 # Check whether --with-ns was given.
4098 if test "${with_ns+set}" = set; then :
4099 withval=$with_ns;
4100 else
4101 with_ns=no
4106 # Check whether --with-gpm was given.
4107 if test "${with_gpm+set}" = set; then :
4108 withval=$with_gpm;
4109 else
4110 with_gpm=$with_features
4114 # Check whether --with-dbus was given.
4115 if test "${with_dbus+set}" = set; then :
4116 withval=$with_dbus;
4117 else
4118 with_dbus=$with_features
4122 # Check whether --with-gconf was given.
4123 if test "${with_gconf+set}" = set; then :
4124 withval=$with_gconf;
4125 else
4126 with_gconf=$with_features
4130 # Check whether --with-gsettings was given.
4131 if test "${with_gsettings+set}" = set; then :
4132 withval=$with_gsettings;
4133 else
4134 with_gsettings=$with_features
4138 # Check whether --with-selinux was given.
4139 if test "${with_selinux+set}" = set; then :
4140 withval=$with_selinux;
4141 else
4142 with_selinux=$with_features
4146 # Check whether --with-gnutls was given.
4147 if test "${with_gnutls+set}" = set; then :
4148 withval=$with_gnutls;
4149 else
4150 with_gnutls=$with_features
4154 ## For the times when you want to build Emacs but don't have
4155 ## a suitable makeinfo, and can live without the manuals.
4157 # Check whether --with-makeinfo was given.
4158 if test "${with_makeinfo+set}" = set; then :
4159 withval=$with_makeinfo;
4160 else
4161 with_makeinfo=$with_features
4165 ## Makefile.in needs the cache file name.
4168 ## This is an option because I do not know if all info/man support
4169 ## compressed files, nor how to test if they do so.
4171 # Check whether --with-compress-info was given.
4172 if test "${with_compress_info+set}" = set; then :
4173 withval=$with_compress_info;
4174 else
4175 with_compress_info=$with_features
4178 if test $with_compress_info = yes; then
4179 GZIP_INFO=yes
4180 else
4181 GZIP_INFO=
4186 # Check whether --with-pkg-config-prog was given.
4187 if test "${with_pkg_config_prog+set}" = set; then :
4188 withval=$with_pkg_config_prog;
4191 if test "X${with_pkg_config_prog}" != X; then
4192 if test "${with_pkg_config_prog}" != yes; then
4193 PKG_CONFIG="${with_pkg_config_prog}"
4197 CRT_DIR=
4199 # Check whether --with-crt-dir was given.
4200 if test "${with_crt_dir+set}" = set; then :
4201 withval=$with_crt_dir;
4204 CRT_DIR="${with_crt_dir}"
4207 # Check whether --with-gameuser was given.
4208 if test "${with_gameuser+set}" = set; then :
4209 withval=$with_gameuser;
4212 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4213 && gameuser="${with_gameuser}"
4214 test "X$gameuser" = X && gameuser=games
4217 # Check whether --with-gnustep-conf was given.
4218 if test "${with_gnustep_conf+set}" = set; then :
4219 withval=$with_gnustep_conf;
4222 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4223 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4224 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4225 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4227 # Check whether --enable-ns-self-contained was given.
4228 if test "${enable_ns_self_contained+set}" = set; then :
4229 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4230 else
4231 EN_NS_SELF_CONTAINED=yes
4235 # Check whether --enable-locallisppath was given.
4236 if test "${enable_locallisppath+set}" = set; then :
4237 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4238 locallisppath=
4239 elif test "${enableval}" != "yes"; then
4240 locallisppath=${enableval}
4245 # Check whether --enable-checking was given.
4246 if test "${enable_checking+set}" = set; then :
4247 enableval=$enable_checking; ac_checking_flags="${enableval}"
4250 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4251 for check in $ac_checking_flags
4253 case $check in
4254 # these set all the flags to specific states
4255 yes) ac_enable_checking=1 ;;
4256 no) ac_enable_checking= ;
4257 ac_gc_check_stringbytes= ;
4258 ac_gc_check_string_overrun= ;
4259 ac_gc_check_string_free_list= ;
4260 ac_xmalloc_overrun= ;
4261 ac_gc_check_cons_list= ;
4262 ac_glyphs_debug= ;;
4263 all) ac_enable_checking=1 ;
4264 ac_gc_check_stringbytes=1 ;
4265 ac_gc_check_string_overrun=1 ;
4266 ac_gc_check_string_free_list=1 ;
4267 ac_xmalloc_overrun=1 ;
4268 ac_gc_check_cons_list=1 ;
4269 ac_glyphs_debug=1 ;;
4270 # these enable particular checks
4271 stringbytes) ac_gc_check_stringbytes=1 ;;
4272 stringoverrun) ac_gc_check_string_overrun=1 ;;
4273 stringfreelist) ac_gc_check_string_free_list=1 ;;
4274 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4275 conslist) ac_gc_check_cons_list=1 ;;
4276 glyphs) ac_glyphs_debug=1 ;;
4277 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4278 esac
4279 done
4280 IFS="$ac_save_IFS"
4282 if test x$ac_enable_checking != x ; then
4284 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4287 if test x$ac_gc_check_stringbytes != x ; then
4289 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4292 if test x$ac_gc_check_string_overrun != x ; then
4294 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4297 if test x$ac_gc_check_string_free_list != x ; then
4299 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4302 if test x$ac_xmalloc_overrun != x ; then
4304 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4307 if test x$ac_gc_check_cons_list != x ; then
4309 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4312 if test x$ac_glyphs_debug != x ; then
4314 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4318 # Check whether --enable-check-lisp-object-type was given.
4319 if test "${enable_check_lisp_object_type+set}" = set; then :
4320 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4322 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4329 # Check whether --enable-profiling was given.
4330 if test "${enable_profiling+set}" = set; then :
4331 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4334 if test x$ac_enable_profiling != x ; then
4335 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4336 else
4337 PROFILING_CFLAGS=
4341 # Check whether --enable-autodepend was given.
4342 if test "${enable_autodepend+set}" = set; then :
4343 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4344 else
4345 ac_enable_autodepend=yes
4349 #### Make srcdir absolute, if it isn't already. It's important to
4350 #### avoid running the path through pwd unnecessarily, since pwd can
4351 #### give you automounter prefixes, which can go away. We do all this
4352 #### so Emacs can find its files when run uninstalled.
4353 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4354 unset CDPATH
4355 case "${srcdir}" in
4356 /* ) ;;
4358 ## We may be able to use the $PWD environment variable to make this
4359 ## absolute. But sometimes PWD is inaccurate.
4360 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4361 ## but that tested only for a well-formed and valid PWD,
4362 ## it did not object when PWD was well-formed and valid but just wrong.
4363 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4364 then
4365 srcdir="$PWD"
4366 else
4367 srcdir="`(cd ${srcdir}; pwd)`"
4370 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4371 esac
4373 ### Canonicalize the configuration name.
4375 # Make sure we can run config.sub.
4376 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4377 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4380 $as_echo_n "checking build system type... " >&6; }
4381 if test "${ac_cv_build+set}" = set; then :
4382 $as_echo_n "(cached) " >&6
4383 else
4384 ac_build_alias=$build_alias
4385 test "x$ac_build_alias" = x &&
4386 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4387 test "x$ac_build_alias" = x &&
4388 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4389 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4390 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4394 $as_echo "$ac_cv_build" >&6; }
4395 case $ac_cv_build in
4396 *-*-*) ;;
4397 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4398 esac
4399 build=$ac_cv_build
4400 ac_save_IFS=$IFS; IFS='-'
4401 set x $ac_cv_build
4402 shift
4403 build_cpu=$1
4404 build_vendor=$2
4405 shift; shift
4406 # Remember, the first character of IFS is used to create $*,
4407 # except with old shells:
4408 build_os=$*
4409 IFS=$ac_save_IFS
4410 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4414 $as_echo_n "checking host system type... " >&6; }
4415 if test "${ac_cv_host+set}" = set; then :
4416 $as_echo_n "(cached) " >&6
4417 else
4418 if test "x$host_alias" = x; then
4419 ac_cv_host=$ac_cv_build
4420 else
4421 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4422 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4427 $as_echo "$ac_cv_host" >&6; }
4428 case $ac_cv_host in
4429 *-*-*) ;;
4430 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4431 esac
4432 host=$ac_cv_host
4433 ac_save_IFS=$IFS; IFS='-'
4434 set x $ac_cv_host
4435 shift
4436 host_cpu=$1
4437 host_vendor=$2
4438 shift; shift
4439 # Remember, the first character of IFS is used to create $*,
4440 # except with old shells:
4441 host_os=$*
4442 IFS=$ac_save_IFS
4443 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4446 canonical=$host
4447 configuration=${host_alias-${build_alias-$host}}
4451 ### If you add support for a new configuration, add code to this
4452 ### switch statement to recognize your configuration name and select
4453 ### the appropriate operating system file.
4455 ### You would hope that you could choose an s/*.h
4456 ### file based on the operating system portion. However, it turns out
4457 ### that each s/*.h file is pretty manufacturer-specific.
4458 ### So we basically have to have a special case for each
4459 ### configuration name.
4461 ### As far as handling version numbers on operating systems is
4462 ### concerned, make sure things will fail in a fixable way. If
4463 ### /etc/MACHINES doesn't say anything about version numbers, be
4464 ### prepared to handle anything reasonably. If version numbers
4465 ### matter, be sure /etc/MACHINES says something about it.
4467 opsys='' unported=no
4468 case "${canonical}" in
4470 ## GNU/Linux and similar ports
4471 *-*-linux* )
4472 opsys=gnu-linux
4475 ## FreeBSD ports
4476 *-*-freebsd* )
4477 opsys=freebsd
4480 ## FreeBSD kernel + glibc based userland
4481 *-*-kfreebsd*gnu* )
4482 opsys=gnu-kfreebsd
4485 ## NetBSD ports
4486 *-*-netbsd* )
4487 opsys=netbsd
4490 ## OpenBSD ports
4491 *-*-openbsd* )
4492 opsys=openbsd
4495 ## Apple Darwin / Mac OS X
4496 *-apple-darwin* )
4497 case "${canonical}" in
4498 i[3456]86-* ) ;;
4499 powerpc-* ) ;;
4500 x86_64-* ) ;;
4501 * ) unported=yes ;;
4502 esac
4503 opsys=darwin
4504 ## Use fink packages if available.
4505 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4506 ## if test -d /sw/include && test -d /sw/lib; then
4507 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4508 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4509 ## fi
4512 ## HP 9000 series 700 and 800, running HP/UX
4513 hppa*-hp-hpux10.2* )
4514 opsys=hpux10-20
4516 hppa*-hp-hpux1[1-9]* )
4517 opsys=hpux11
4518 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4521 ## IBM machines
4522 rs6000-ibm-aix4.[23]* )
4523 opsys=aix4-2
4525 powerpc-ibm-aix4.[23]* )
4526 opsys=aix4-2
4528 rs6000-ibm-aix[56]* )
4529 opsys=aix4-2
4531 powerpc-ibm-aix[56]* )
4532 opsys=aix4-2
4535 ## Silicon Graphics machines
4536 ## Iris 4D
4537 mips-sgi-irix6.5 )
4538 opsys=irix6-5
4539 # Without defining _LANGUAGE_C, things get masked out in the headers
4540 # so that, for instance, grepping for `free' in stdlib.h fails and
4541 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4542 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4545 ## Suns
4546 *-sun-solaris* \
4547 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4548 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4549 case "${canonical}" in
4550 i[3456]86-*-* ) ;;
4551 amd64-*-*|x86_64-*-*) ;;
4552 sparc* ) ;;
4553 * ) unported=yes ;;
4554 esac
4555 case "${canonical}" in
4556 *-sunos5.6* | *-solaris2.6* )
4557 opsys=sol2-6
4558 RANLIB="ar -ts"
4560 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4561 opsys=sol2-6
4562 emacs_check_sunpro_c=yes
4564 *-sunos5* | *-solaris* )
4565 opsys=sol2-10
4566 emacs_check_sunpro_c=yes
4568 esac
4569 ## Watch out for a compiler that we know will not work.
4570 case "${canonical}" in
4571 *-solaris* | *-sunos5* )
4572 if [ "x$CC" = x/usr/ucb/cc ]; then
4573 ## /usr/ucb/cc doesn't work;
4574 ## we should find some other compiler that does work.
4575 unset CC
4578 *) ;;
4579 esac
4582 ## Intel 386 machines where we don't care about the manufacturer.
4583 i[3456]86-*-* )
4584 case "${canonical}" in
4585 *-cygwin ) opsys=cygwin ;;
4586 *-darwin* ) opsys=darwin ;;
4587 *-sysv4.2uw* ) opsys=unixware ;;
4588 *-sysv5uw* ) opsys=unixware ;;
4589 *-sysv5OpenUNIX* ) opsys=unixware ;;
4590 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4591 esac
4595 unported=yes
4597 esac
4599 ### If the code above didn't choose an operating system, just choose
4600 ### an operating system based on the configuration name. You really
4601 ### only want to use this when you have no idea what the right
4602 ### operating system is; if you know what operating systems a machine
4603 ### runs, it's cleaner to make it explicit in the case statement
4604 ### above.
4605 if test x"${opsys}" = x; then
4606 case "${canonical}" in
4607 *-gnu* ) opsys=gnu ;;
4609 unported=yes
4611 esac
4616 if test $unported = yes; then
4617 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4618 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4622 #### Choose a compiler.
4624 ac_ext=c
4625 ac_cpp='$CPP $CPPFLAGS'
4626 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4627 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4628 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4629 if test -n "$ac_tool_prefix"; then
4630 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4631 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4633 $as_echo_n "checking for $ac_word... " >&6; }
4634 if test "${ac_cv_prog_CC+set}" = set; then :
4635 $as_echo_n "(cached) " >&6
4636 else
4637 if test -n "$CC"; then
4638 ac_cv_prog_CC="$CC" # Let the user override the test.
4639 else
4640 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4641 for as_dir in $PATH
4643 IFS=$as_save_IFS
4644 test -z "$as_dir" && as_dir=.
4645 for ac_exec_ext in '' $ac_executable_extensions; do
4646 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4647 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4648 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4649 break 2
4651 done
4652 done
4653 IFS=$as_save_IFS
4657 CC=$ac_cv_prog_CC
4658 if test -n "$CC"; then
4659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4660 $as_echo "$CC" >&6; }
4661 else
4662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4663 $as_echo "no" >&6; }
4668 if test -z "$ac_cv_prog_CC"; then
4669 ac_ct_CC=$CC
4670 # Extract the first word of "gcc", so it can be a program name with args.
4671 set dummy gcc; ac_word=$2
4672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4673 $as_echo_n "checking for $ac_word... " >&6; }
4674 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4675 $as_echo_n "(cached) " >&6
4676 else
4677 if test -n "$ac_ct_CC"; then
4678 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4679 else
4680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4681 for as_dir in $PATH
4683 IFS=$as_save_IFS
4684 test -z "$as_dir" && as_dir=.
4685 for ac_exec_ext in '' $ac_executable_extensions; do
4686 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4687 ac_cv_prog_ac_ct_CC="gcc"
4688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4689 break 2
4691 done
4692 done
4693 IFS=$as_save_IFS
4697 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4698 if test -n "$ac_ct_CC"; then
4699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4700 $as_echo "$ac_ct_CC" >&6; }
4701 else
4702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4703 $as_echo "no" >&6; }
4706 if test "x$ac_ct_CC" = x; then
4707 CC=""
4708 else
4709 case $cross_compiling:$ac_tool_warned in
4710 yes:)
4711 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4712 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4713 ac_tool_warned=yes ;;
4714 esac
4715 CC=$ac_ct_CC
4717 else
4718 CC="$ac_cv_prog_CC"
4721 if test -z "$CC"; then
4722 if test -n "$ac_tool_prefix"; then
4723 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4724 set dummy ${ac_tool_prefix}cc; ac_word=$2
4725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4726 $as_echo_n "checking for $ac_word... " >&6; }
4727 if test "${ac_cv_prog_CC+set}" = set; then :
4728 $as_echo_n "(cached) " >&6
4729 else
4730 if test -n "$CC"; then
4731 ac_cv_prog_CC="$CC" # Let the user override the test.
4732 else
4733 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4734 for as_dir in $PATH
4736 IFS=$as_save_IFS
4737 test -z "$as_dir" && as_dir=.
4738 for ac_exec_ext in '' $ac_executable_extensions; do
4739 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4740 ac_cv_prog_CC="${ac_tool_prefix}cc"
4741 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4742 break 2
4744 done
4745 done
4746 IFS=$as_save_IFS
4750 CC=$ac_cv_prog_CC
4751 if test -n "$CC"; then
4752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4753 $as_echo "$CC" >&6; }
4754 else
4755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4756 $as_echo "no" >&6; }
4762 if test -z "$CC"; then
4763 # Extract the first word of "cc", so it can be a program name with args.
4764 set dummy cc; ac_word=$2
4765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4766 $as_echo_n "checking for $ac_word... " >&6; }
4767 if test "${ac_cv_prog_CC+set}" = set; then :
4768 $as_echo_n "(cached) " >&6
4769 else
4770 if test -n "$CC"; then
4771 ac_cv_prog_CC="$CC" # Let the user override the test.
4772 else
4773 ac_prog_rejected=no
4774 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4775 for as_dir in $PATH
4777 IFS=$as_save_IFS
4778 test -z "$as_dir" && as_dir=.
4779 for ac_exec_ext in '' $ac_executable_extensions; do
4780 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4781 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4782 ac_prog_rejected=yes
4783 continue
4785 ac_cv_prog_CC="cc"
4786 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4787 break 2
4789 done
4790 done
4791 IFS=$as_save_IFS
4793 if test $ac_prog_rejected = yes; then
4794 # We found a bogon in the path, so make sure we never use it.
4795 set dummy $ac_cv_prog_CC
4796 shift
4797 if test $# != 0; then
4798 # We chose a different compiler from the bogus one.
4799 # However, it has the same basename, so the bogon will be chosen
4800 # first if we set CC to just the basename; use the full file name.
4801 shift
4802 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4807 CC=$ac_cv_prog_CC
4808 if test -n "$CC"; then
4809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4810 $as_echo "$CC" >&6; }
4811 else
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4813 $as_echo "no" >&6; }
4818 if test -z "$CC"; then
4819 if test -n "$ac_tool_prefix"; then
4820 for ac_prog in cl.exe
4822 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4823 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4825 $as_echo_n "checking for $ac_word... " >&6; }
4826 if test "${ac_cv_prog_CC+set}" = set; then :
4827 $as_echo_n "(cached) " >&6
4828 else
4829 if test -n "$CC"; then
4830 ac_cv_prog_CC="$CC" # Let the user override the test.
4831 else
4832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4833 for as_dir in $PATH
4835 IFS=$as_save_IFS
4836 test -z "$as_dir" && as_dir=.
4837 for ac_exec_ext in '' $ac_executable_extensions; do
4838 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4839 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4841 break 2
4843 done
4844 done
4845 IFS=$as_save_IFS
4849 CC=$ac_cv_prog_CC
4850 if test -n "$CC"; then
4851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4852 $as_echo "$CC" >&6; }
4853 else
4854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4855 $as_echo "no" >&6; }
4859 test -n "$CC" && break
4860 done
4862 if test -z "$CC"; then
4863 ac_ct_CC=$CC
4864 for ac_prog in cl.exe
4866 # Extract the first word of "$ac_prog", so it can be a program name with args.
4867 set dummy $ac_prog; ac_word=$2
4868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4869 $as_echo_n "checking for $ac_word... " >&6; }
4870 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4871 $as_echo_n "(cached) " >&6
4872 else
4873 if test -n "$ac_ct_CC"; then
4874 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4875 else
4876 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4877 for as_dir in $PATH
4879 IFS=$as_save_IFS
4880 test -z "$as_dir" && as_dir=.
4881 for ac_exec_ext in '' $ac_executable_extensions; do
4882 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4883 ac_cv_prog_ac_ct_CC="$ac_prog"
4884 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4885 break 2
4887 done
4888 done
4889 IFS=$as_save_IFS
4893 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4894 if test -n "$ac_ct_CC"; then
4895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4896 $as_echo "$ac_ct_CC" >&6; }
4897 else
4898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4899 $as_echo "no" >&6; }
4903 test -n "$ac_ct_CC" && break
4904 done
4906 if test "x$ac_ct_CC" = x; then
4907 CC=""
4908 else
4909 case $cross_compiling:$ac_tool_warned in
4910 yes:)
4911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4912 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4913 ac_tool_warned=yes ;;
4914 esac
4915 CC=$ac_ct_CC
4922 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4923 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4924 as_fn_error "no acceptable C compiler found in \$PATH
4925 See \`config.log' for more details." "$LINENO" 5; }
4927 # Provide some information about the compiler.
4928 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4929 set X $ac_compile
4930 ac_compiler=$2
4931 for ac_option in --version -v -V -qversion; do
4932 { { ac_try="$ac_compiler $ac_option >&5"
4933 case "(($ac_try" in
4934 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4935 *) ac_try_echo=$ac_try;;
4936 esac
4937 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4938 $as_echo "$ac_try_echo"; } >&5
4939 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4940 ac_status=$?
4941 if test -s conftest.err; then
4942 sed '10a\
4943 ... rest of stderr output deleted ...
4944 10q' conftest.err >conftest.er1
4945 cat conftest.er1 >&5
4947 rm -f conftest.er1 conftest.err
4948 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4949 test $ac_status = 0; }
4950 done
4952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4953 /* end confdefs.h. */
4956 main ()
4960 return 0;
4962 _ACEOF
4963 ac_clean_files_save=$ac_clean_files
4964 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4965 # Try to create an executable without -o first, disregard a.out.
4966 # It will help us diagnose broken compilers, and finding out an intuition
4967 # of exeext.
4968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4969 $as_echo_n "checking whether the C compiler works... " >&6; }
4970 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4972 # The possible output files:
4973 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4975 ac_rmfiles=
4976 for ac_file in $ac_files
4978 case $ac_file in
4979 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4980 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4981 esac
4982 done
4983 rm -f $ac_rmfiles
4985 if { { ac_try="$ac_link_default"
4986 case "(($ac_try" in
4987 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4988 *) ac_try_echo=$ac_try;;
4989 esac
4990 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4991 $as_echo "$ac_try_echo"; } >&5
4992 (eval "$ac_link_default") 2>&5
4993 ac_status=$?
4994 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4995 test $ac_status = 0; }; then :
4996 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4997 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4998 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4999 # so that the user can short-circuit this test for compilers unknown to
5000 # Autoconf.
5001 for ac_file in $ac_files ''
5003 test -f "$ac_file" || continue
5004 case $ac_file in
5005 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5007 [ab].out )
5008 # We found the default executable, but exeext='' is most
5009 # certainly right.
5010 break;;
5011 *.* )
5012 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5013 then :; else
5014 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5016 # We set ac_cv_exeext here because the later test for it is not
5017 # safe: cross compilers may not add the suffix if given an `-o'
5018 # argument, so we may need to know it at that point already.
5019 # Even if this section looks crufty: it has the advantage of
5020 # actually working.
5021 break;;
5023 break;;
5024 esac
5025 done
5026 test "$ac_cv_exeext" = no && ac_cv_exeext=
5028 else
5029 ac_file=''
5031 if test -z "$ac_file"; then :
5032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5033 $as_echo "no" >&6; }
5034 $as_echo "$as_me: failed program was:" >&5
5035 sed 's/^/| /' conftest.$ac_ext >&5
5037 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5038 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5039 { as_fn_set_status 77
5040 as_fn_error "C compiler cannot create executables
5041 See \`config.log' for more details." "$LINENO" 5; }; }
5042 else
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5044 $as_echo "yes" >&6; }
5046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5047 $as_echo_n "checking for C compiler default output file name... " >&6; }
5048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5049 $as_echo "$ac_file" >&6; }
5050 ac_exeext=$ac_cv_exeext
5052 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5053 ac_clean_files=$ac_clean_files_save
5054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5055 $as_echo_n "checking for suffix of executables... " >&6; }
5056 if { { ac_try="$ac_link"
5057 case "(($ac_try" in
5058 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5059 *) ac_try_echo=$ac_try;;
5060 esac
5061 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5062 $as_echo "$ac_try_echo"; } >&5
5063 (eval "$ac_link") 2>&5
5064 ac_status=$?
5065 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5066 test $ac_status = 0; }; then :
5067 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5068 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5069 # work properly (i.e., refer to `conftest.exe'), while it won't with
5070 # `rm'.
5071 for ac_file in conftest.exe conftest conftest.*; do
5072 test -f "$ac_file" || continue
5073 case $ac_file in
5074 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5075 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5076 break;;
5077 * ) break;;
5078 esac
5079 done
5080 else
5081 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5082 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5083 as_fn_error "cannot compute suffix of executables: cannot compile and link
5084 See \`config.log' for more details." "$LINENO" 5; }
5086 rm -f conftest conftest$ac_cv_exeext
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5088 $as_echo "$ac_cv_exeext" >&6; }
5090 rm -f conftest.$ac_ext
5091 EXEEXT=$ac_cv_exeext
5092 ac_exeext=$EXEEXT
5093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5094 /* end confdefs.h. */
5095 #include <stdio.h>
5097 main ()
5099 FILE *f = fopen ("conftest.out", "w");
5100 return ferror (f) || fclose (f) != 0;
5103 return 0;
5105 _ACEOF
5106 ac_clean_files="$ac_clean_files conftest.out"
5107 # Check that the compiler produces executables we can run. If not, either
5108 # the compiler is broken, or we cross compile.
5109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5110 $as_echo_n "checking whether we are cross compiling... " >&6; }
5111 if test "$cross_compiling" != yes; then
5112 { { ac_try="$ac_link"
5113 case "(($ac_try" in
5114 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5115 *) ac_try_echo=$ac_try;;
5116 esac
5117 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5118 $as_echo "$ac_try_echo"; } >&5
5119 (eval "$ac_link") 2>&5
5120 ac_status=$?
5121 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5122 test $ac_status = 0; }
5123 if { ac_try='./conftest$ac_cv_exeext'
5124 { { case "(($ac_try" in
5125 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5126 *) ac_try_echo=$ac_try;;
5127 esac
5128 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5129 $as_echo "$ac_try_echo"; } >&5
5130 (eval "$ac_try") 2>&5
5131 ac_status=$?
5132 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5133 test $ac_status = 0; }; }; then
5134 cross_compiling=no
5135 else
5136 if test "$cross_compiling" = maybe; then
5137 cross_compiling=yes
5138 else
5139 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5140 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5141 as_fn_error "cannot run C compiled programs.
5142 If you meant to cross compile, use \`--host'.
5143 See \`config.log' for more details." "$LINENO" 5; }
5147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5148 $as_echo "$cross_compiling" >&6; }
5150 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5151 ac_clean_files=$ac_clean_files_save
5152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5153 $as_echo_n "checking for suffix of object files... " >&6; }
5154 if test "${ac_cv_objext+set}" = set; then :
5155 $as_echo_n "(cached) " >&6
5156 else
5157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5158 /* end confdefs.h. */
5161 main ()
5165 return 0;
5167 _ACEOF
5168 rm -f conftest.o conftest.obj
5169 if { { ac_try="$ac_compile"
5170 case "(($ac_try" in
5171 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5172 *) ac_try_echo=$ac_try;;
5173 esac
5174 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5175 $as_echo "$ac_try_echo"; } >&5
5176 (eval "$ac_compile") 2>&5
5177 ac_status=$?
5178 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5179 test $ac_status = 0; }; then :
5180 for ac_file in conftest.o conftest.obj conftest.*; do
5181 test -f "$ac_file" || continue;
5182 case $ac_file in
5183 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5184 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5185 break;;
5186 esac
5187 done
5188 else
5189 $as_echo "$as_me: failed program was:" >&5
5190 sed 's/^/| /' conftest.$ac_ext >&5
5192 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5193 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5194 as_fn_error "cannot compute suffix of object files: cannot compile
5195 See \`config.log' for more details." "$LINENO" 5; }
5197 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5200 $as_echo "$ac_cv_objext" >&6; }
5201 OBJEXT=$ac_cv_objext
5202 ac_objext=$OBJEXT
5203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5204 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5205 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5206 $as_echo_n "(cached) " >&6
5207 else
5208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5209 /* end confdefs.h. */
5212 main ()
5214 #ifndef __GNUC__
5215 choke me
5216 #endif
5219 return 0;
5221 _ACEOF
5222 if ac_fn_c_try_compile "$LINENO"; then :
5223 ac_compiler_gnu=yes
5224 else
5225 ac_compiler_gnu=no
5227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5228 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5232 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5233 if test $ac_compiler_gnu = yes; then
5234 GCC=yes
5235 else
5236 GCC=
5238 ac_test_CFLAGS=${CFLAGS+set}
5239 ac_save_CFLAGS=$CFLAGS
5240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5241 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5242 if test "${ac_cv_prog_cc_g+set}" = set; then :
5243 $as_echo_n "(cached) " >&6
5244 else
5245 ac_save_c_werror_flag=$ac_c_werror_flag
5246 ac_c_werror_flag=yes
5247 ac_cv_prog_cc_g=no
5248 CFLAGS="-g"
5249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5250 /* end confdefs.h. */
5253 main ()
5257 return 0;
5259 _ACEOF
5260 if ac_fn_c_try_compile "$LINENO"; then :
5261 ac_cv_prog_cc_g=yes
5262 else
5263 CFLAGS=""
5264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5265 /* end confdefs.h. */
5268 main ()
5272 return 0;
5274 _ACEOF
5275 if ac_fn_c_try_compile "$LINENO"; then :
5277 else
5278 ac_c_werror_flag=$ac_save_c_werror_flag
5279 CFLAGS="-g"
5280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5281 /* end confdefs.h. */
5284 main ()
5288 return 0;
5290 _ACEOF
5291 if ac_fn_c_try_compile "$LINENO"; then :
5292 ac_cv_prog_cc_g=yes
5294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5296 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5299 ac_c_werror_flag=$ac_save_c_werror_flag
5301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5302 $as_echo "$ac_cv_prog_cc_g" >&6; }
5303 if test "$ac_test_CFLAGS" = set; then
5304 CFLAGS=$ac_save_CFLAGS
5305 elif test $ac_cv_prog_cc_g = yes; then
5306 if test "$GCC" = yes; then
5307 CFLAGS="-g -O2"
5308 else
5309 CFLAGS="-g"
5311 else
5312 if test "$GCC" = yes; then
5313 CFLAGS="-O2"
5314 else
5315 CFLAGS=
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5319 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5320 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5321 $as_echo_n "(cached) " >&6
5322 else
5323 ac_cv_prog_cc_c89=no
5324 ac_save_CC=$CC
5325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5326 /* end confdefs.h. */
5327 #include <stdarg.h>
5328 #include <stdio.h>
5329 #include <sys/types.h>
5330 #include <sys/stat.h>
5331 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5332 struct buf { int x; };
5333 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5334 static char *e (p, i)
5335 char **p;
5336 int i;
5338 return p[i];
5340 static char *f (char * (*g) (char **, int), char **p, ...)
5342 char *s;
5343 va_list v;
5344 va_start (v,p);
5345 s = g (p, va_arg (v,int));
5346 va_end (v);
5347 return s;
5350 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5351 function prototypes and stuff, but not '\xHH' hex character constants.
5352 These don't provoke an error unfortunately, instead are silently treated
5353 as 'x'. The following induces an error, until -std is added to get
5354 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5355 array size at least. It's necessary to write '\x00'==0 to get something
5356 that's true only with -std. */
5357 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5359 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5360 inside strings and character constants. */
5361 #define FOO(x) 'x'
5362 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5364 int test (int i, double x);
5365 struct s1 {int (*f) (int a);};
5366 struct s2 {int (*f) (double a);};
5367 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5368 int argc;
5369 char **argv;
5371 main ()
5373 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5375 return 0;
5377 _ACEOF
5378 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5379 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5381 CC="$ac_save_CC $ac_arg"
5382 if ac_fn_c_try_compile "$LINENO"; then :
5383 ac_cv_prog_cc_c89=$ac_arg
5385 rm -f core conftest.err conftest.$ac_objext
5386 test "x$ac_cv_prog_cc_c89" != "xno" && break
5387 done
5388 rm -f conftest.$ac_ext
5389 CC=$ac_save_CC
5392 # AC_CACHE_VAL
5393 case "x$ac_cv_prog_cc_c89" in
5395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5396 $as_echo "none needed" >&6; } ;;
5397 xno)
5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5399 $as_echo "unsupported" >&6; } ;;
5401 CC="$CC $ac_cv_prog_cc_c89"
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5403 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5404 esac
5405 if test "x$ac_cv_prog_cc_c89" != xno; then :
5409 ac_ext=c
5410 ac_cpp='$CPP $CPPFLAGS'
5411 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5412 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5413 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5414 DEPDIR="${am__leading_dot}deps"
5416 ac_config_commands="$ac_config_commands depfiles"
5419 am_make=${MAKE-make}
5420 cat > confinc << 'END'
5421 am__doit:
5422 @echo this is the am__doit target
5423 .PHONY: am__doit
5425 # If we don't find an include directive, just comment out the code.
5426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5427 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5428 am__include="#"
5429 am__quote=
5430 _am_result=none
5431 # First try GNU make style include.
5432 echo "include confinc" > confmf
5433 # Ignore all kinds of additional output from `make'.
5434 case `$am_make -s -f confmf 2> /dev/null` in #(
5435 *the\ am__doit\ target*)
5436 am__include=include
5437 am__quote=
5438 _am_result=GNU
5440 esac
5441 # Now try BSD make style include.
5442 if test "$am__include" = "#"; then
5443 echo '.include "confinc"' > confmf
5444 case `$am_make -s -f confmf 2> /dev/null` in #(
5445 *the\ am__doit\ target*)
5446 am__include=.include
5447 am__quote="\""
5448 _am_result=BSD
5450 esac
5454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5455 $as_echo "$_am_result" >&6; }
5456 rm -f confinc confmf
5458 # Check whether --enable-dependency-tracking was given.
5459 if test "${enable_dependency_tracking+set}" = set; then :
5460 enableval=$enable_dependency_tracking;
5463 if test "x$enable_dependency_tracking" != xno; then
5464 am_depcomp="$ac_aux_dir/depcomp"
5465 AMDEPBACKSLASH='\'
5467 if test "x$enable_dependency_tracking" != xno; then
5468 AMDEP_TRUE=
5469 AMDEP_FALSE='#'
5470 else
5471 AMDEP_TRUE='#'
5472 AMDEP_FALSE=
5477 depcc="$CC" am_compiler_list=
5479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5480 $as_echo_n "checking dependency style of $depcc... " >&6; }
5481 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5482 $as_echo_n "(cached) " >&6
5483 else
5484 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5485 # We make a subdir and do the tests there. Otherwise we can end up
5486 # making bogus files that we don't know about and never remove. For
5487 # instance it was reported that on HP-UX the gcc test will end up
5488 # making a dummy file named `D' -- because `-MD' means `put the output
5489 # in D'.
5490 mkdir conftest.dir
5491 # Copy depcomp to subdir because otherwise we won't find it if we're
5492 # using a relative directory.
5493 cp "$am_depcomp" conftest.dir
5494 cd conftest.dir
5495 # We will build objects and dependencies in a subdirectory because
5496 # it helps to detect inapplicable dependency modes. For instance
5497 # both Tru64's cc and ICC support -MD to output dependencies as a
5498 # side effect of compilation, but ICC will put the dependencies in
5499 # the current directory while Tru64 will put them in the object
5500 # directory.
5501 mkdir sub
5503 am_cv_CC_dependencies_compiler_type=none
5504 if test "$am_compiler_list" = ""; then
5505 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5507 am__universal=false
5508 case " $depcc " in #(
5509 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5510 esac
5512 for depmode in $am_compiler_list; do
5513 # Setup a source with many dependencies, because some compilers
5514 # like to wrap large dependency lists on column 80 (with \), and
5515 # we should not choose a depcomp mode which is confused by this.
5517 # We need to recreate these files for each test, as the compiler may
5518 # overwrite some of them when testing with obscure command lines.
5519 # This happens at least with the AIX C compiler.
5520 : > sub/conftest.c
5521 for i in 1 2 3 4 5 6; do
5522 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5523 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5524 # Solaris 8's {/usr,}/bin/sh.
5525 touch sub/conftst$i.h
5526 done
5527 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5529 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5530 # mode. It turns out that the SunPro C++ compiler does not properly
5531 # handle `-M -o', and we need to detect this. Also, some Intel
5532 # versions had trouble with output in subdirs
5533 am__obj=sub/conftest.${OBJEXT-o}
5534 am__minus_obj="-o $am__obj"
5535 case $depmode in
5536 gcc)
5537 # This depmode causes a compiler race in universal mode.
5538 test "$am__universal" = false || continue
5540 nosideeffect)
5541 # after this tag, mechanisms are not by side-effect, so they'll
5542 # only be used when explicitly requested
5543 if test "x$enable_dependency_tracking" = xyes; then
5544 continue
5545 else
5546 break
5549 msvisualcpp | msvcmsys)
5550 # This compiler won't grok `-c -o', but also, the minuso test has
5551 # not run yet. These depmodes are late enough in the game, and
5552 # so weak that their functioning should not be impacted.
5553 am__obj=conftest.${OBJEXT-o}
5554 am__minus_obj=
5556 none) break ;;
5557 esac
5558 if depmode=$depmode \
5559 source=sub/conftest.c object=$am__obj \
5560 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5561 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5562 >/dev/null 2>conftest.err &&
5563 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5564 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5565 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5566 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5567 # icc doesn't choke on unknown options, it will just issue warnings
5568 # or remarks (even with -Werror). So we grep stderr for any message
5569 # that says an option was ignored or not supported.
5570 # When given -MP, icc 7.0 and 7.1 complain thusly:
5571 # icc: Command line warning: ignoring option '-M'; no argument required
5572 # The diagnosis changed in icc 8.0:
5573 # icc: Command line remark: option '-MP' not supported
5574 if (grep 'ignoring option' conftest.err ||
5575 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5576 am_cv_CC_dependencies_compiler_type=$depmode
5577 break
5580 done
5582 cd ..
5583 rm -rf conftest.dir
5584 else
5585 am_cv_CC_dependencies_compiler_type=none
5589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5590 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5591 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5594 test "x$enable_dependency_tracking" != xno \
5595 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5596 am__fastdepCC_TRUE=
5597 am__fastdepCC_FALSE='#'
5598 else
5599 am__fastdepCC_TRUE='#'
5600 am__fastdepCC_FALSE=
5604 if test "x$CC" != xcc; then
5605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5606 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5607 else
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5609 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5611 set dummy $CC; ac_cc=`$as_echo "$2" |
5612 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5613 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5614 $as_echo_n "(cached) " >&6
5615 else
5616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5617 /* end confdefs.h. */
5620 main ()
5624 return 0;
5626 _ACEOF
5627 # Make sure it works both with $CC and with simple cc.
5628 # We do the test twice because some compilers refuse to overwrite an
5629 # existing .o file with -o, though they will create one.
5630 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5631 rm -f conftest2.*
5632 if { { case "(($ac_try" in
5633 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5634 *) ac_try_echo=$ac_try;;
5635 esac
5636 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5637 $as_echo "$ac_try_echo"; } >&5
5638 (eval "$ac_try") 2>&5
5639 ac_status=$?
5640 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5641 test $ac_status = 0; } &&
5642 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5643 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5644 *) ac_try_echo=$ac_try;;
5645 esac
5646 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5647 $as_echo "$ac_try_echo"; } >&5
5648 (eval "$ac_try") 2>&5
5649 ac_status=$?
5650 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5651 test $ac_status = 0; };
5652 then
5653 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5654 if test "x$CC" != xcc; then
5655 # Test first that cc exists at all.
5656 if { ac_try='cc -c conftest.$ac_ext >&5'
5657 { { case "(($ac_try" in
5658 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5659 *) ac_try_echo=$ac_try;;
5660 esac
5661 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5662 $as_echo "$ac_try_echo"; } >&5
5663 (eval "$ac_try") 2>&5
5664 ac_status=$?
5665 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5666 test $ac_status = 0; }; }; then
5667 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5668 rm -f conftest2.*
5669 if { { case "(($ac_try" in
5670 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5671 *) ac_try_echo=$ac_try;;
5672 esac
5673 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5674 $as_echo "$ac_try_echo"; } >&5
5675 (eval "$ac_try") 2>&5
5676 ac_status=$?
5677 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5678 test $ac_status = 0; } &&
5679 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5680 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5681 *) ac_try_echo=$ac_try;;
5682 esac
5683 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5684 $as_echo "$ac_try_echo"; } >&5
5685 (eval "$ac_try") 2>&5
5686 ac_status=$?
5687 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5688 test $ac_status = 0; };
5689 then
5690 # cc works too.
5692 else
5693 # cc exists but doesn't like -o.
5694 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5698 else
5699 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5701 rm -f core conftest*
5704 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5706 $as_echo "yes" >&6; }
5707 else
5708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5709 $as_echo "no" >&6; }
5711 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5715 # FIXME: we rely on the cache variable name because
5716 # there is no other way.
5717 set dummy $CC
5718 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5719 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5720 if test "$am_t" != yes; then
5721 # Losing compiler, so override with the script.
5722 # FIXME: It is wrong to rewrite CC.
5723 # But if we don't then we get into trouble of one sort or another.
5724 # A longer-term fix would be to have automake use am__CC in this case,
5725 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5726 CC="$am_aux_dir/compile $CC"
5731 if test x$GCC = xyes; then
5732 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5733 else
5734 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5737 # Initialize gnulib right after choosing the compiler.
5739 ac_ext=c
5740 ac_cpp='$CPP $CPPFLAGS'
5741 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5742 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5743 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5745 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5746 # On Suns, sometimes $CPP names a directory.
5747 if test -n "$CPP" && test -d "$CPP"; then
5748 CPP=
5750 if test -z "$CPP"; then
5751 if test "${ac_cv_prog_CPP+set}" = set; then :
5752 $as_echo_n "(cached) " >&6
5753 else
5754 # Double quotes because CPP needs to be expanded
5755 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5757 ac_preproc_ok=false
5758 for ac_c_preproc_warn_flag in '' yes
5760 # Use a header file that comes with gcc, so configuring glibc
5761 # with a fresh cross-compiler works.
5762 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5763 # <limits.h> exists even on freestanding compilers.
5764 # On the NeXT, cc -E runs the code through the compiler's parser,
5765 # not just through cpp. "Syntax error" is here to catch this case.
5766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5767 /* end confdefs.h. */
5768 #ifdef __STDC__
5769 # include <limits.h>
5770 #else
5771 # include <assert.h>
5772 #endif
5773 Syntax error
5774 _ACEOF
5775 if ac_fn_c_try_cpp "$LINENO"; then :
5777 else
5778 # Broken: fails on valid input.
5779 continue
5781 rm -f conftest.err conftest.$ac_ext
5783 # OK, works on sane cases. Now check whether nonexistent headers
5784 # can be detected and how.
5785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5786 /* end confdefs.h. */
5787 #include <ac_nonexistent.h>
5788 _ACEOF
5789 if ac_fn_c_try_cpp "$LINENO"; then :
5790 # Broken: success on invalid input.
5791 continue
5792 else
5793 # Passes both tests.
5794 ac_preproc_ok=:
5795 break
5797 rm -f conftest.err conftest.$ac_ext
5799 done
5800 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5801 rm -f conftest.err conftest.$ac_ext
5802 if $ac_preproc_ok; then :
5803 break
5806 done
5807 ac_cv_prog_CPP=$CPP
5810 CPP=$ac_cv_prog_CPP
5811 else
5812 ac_cv_prog_CPP=$CPP
5814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5815 $as_echo "$CPP" >&6; }
5816 ac_preproc_ok=false
5817 for ac_c_preproc_warn_flag in '' yes
5819 # Use a header file that comes with gcc, so configuring glibc
5820 # with a fresh cross-compiler works.
5821 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5822 # <limits.h> exists even on freestanding compilers.
5823 # On the NeXT, cc -E runs the code through the compiler's parser,
5824 # not just through cpp. "Syntax error" is here to catch this case.
5825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5826 /* end confdefs.h. */
5827 #ifdef __STDC__
5828 # include <limits.h>
5829 #else
5830 # include <assert.h>
5831 #endif
5832 Syntax error
5833 _ACEOF
5834 if ac_fn_c_try_cpp "$LINENO"; then :
5836 else
5837 # Broken: fails on valid input.
5838 continue
5840 rm -f conftest.err conftest.$ac_ext
5842 # OK, works on sane cases. Now check whether nonexistent headers
5843 # can be detected and how.
5844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5845 /* end confdefs.h. */
5846 #include <ac_nonexistent.h>
5847 _ACEOF
5848 if ac_fn_c_try_cpp "$LINENO"; then :
5849 # Broken: success on invalid input.
5850 continue
5851 else
5852 # Passes both tests.
5853 ac_preproc_ok=:
5854 break
5856 rm -f conftest.err conftest.$ac_ext
5858 done
5859 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5860 rm -f conftest.err conftest.$ac_ext
5861 if $ac_preproc_ok; then :
5863 else
5864 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5865 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5866 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5867 See \`config.log' for more details." "$LINENO" 5; }
5870 ac_ext=c
5871 ac_cpp='$CPP $CPPFLAGS'
5872 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5873 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5874 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5878 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5879 if test "${ac_cv_path_GREP+set}" = set; then :
5880 $as_echo_n "(cached) " >&6
5881 else
5882 if test -z "$GREP"; then
5883 ac_path_GREP_found=false
5884 # Loop through the user's path and test for each of PROGNAME-LIST
5885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5886 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5888 IFS=$as_save_IFS
5889 test -z "$as_dir" && as_dir=.
5890 for ac_prog in grep ggrep; do
5891 for ac_exec_ext in '' $ac_executable_extensions; do
5892 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5893 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5894 # Check for GNU ac_path_GREP and select it if it is found.
5895 # Check for GNU $ac_path_GREP
5896 case `"$ac_path_GREP" --version 2>&1` in
5897 *GNU*)
5898 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5900 ac_count=0
5901 $as_echo_n 0123456789 >"conftest.in"
5902 while :
5904 cat "conftest.in" "conftest.in" >"conftest.tmp"
5905 mv "conftest.tmp" "conftest.in"
5906 cp "conftest.in" "conftest.nl"
5907 $as_echo 'GREP' >> "conftest.nl"
5908 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5909 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5910 as_fn_arith $ac_count + 1 && ac_count=$as_val
5911 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5912 # Best one so far, save it but keep looking for a better one
5913 ac_cv_path_GREP="$ac_path_GREP"
5914 ac_path_GREP_max=$ac_count
5916 # 10*(2^10) chars as input seems more than enough
5917 test $ac_count -gt 10 && break
5918 done
5919 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5920 esac
5922 $ac_path_GREP_found && break 3
5923 done
5924 done
5925 done
5926 IFS=$as_save_IFS
5927 if test -z "$ac_cv_path_GREP"; then
5928 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5930 else
5931 ac_cv_path_GREP=$GREP
5935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5936 $as_echo "$ac_cv_path_GREP" >&6; }
5937 GREP="$ac_cv_path_GREP"
5940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5941 $as_echo_n "checking for egrep... " >&6; }
5942 if test "${ac_cv_path_EGREP+set}" = set; then :
5943 $as_echo_n "(cached) " >&6
5944 else
5945 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5946 then ac_cv_path_EGREP="$GREP -E"
5947 else
5948 if test -z "$EGREP"; then
5949 ac_path_EGREP_found=false
5950 # Loop through the user's path and test for each of PROGNAME-LIST
5951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5952 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5954 IFS=$as_save_IFS
5955 test -z "$as_dir" && as_dir=.
5956 for ac_prog in egrep; do
5957 for ac_exec_ext in '' $ac_executable_extensions; do
5958 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5959 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5960 # Check for GNU ac_path_EGREP and select it if it is found.
5961 # Check for GNU $ac_path_EGREP
5962 case `"$ac_path_EGREP" --version 2>&1` in
5963 *GNU*)
5964 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5966 ac_count=0
5967 $as_echo_n 0123456789 >"conftest.in"
5968 while :
5970 cat "conftest.in" "conftest.in" >"conftest.tmp"
5971 mv "conftest.tmp" "conftest.in"
5972 cp "conftest.in" "conftest.nl"
5973 $as_echo 'EGREP' >> "conftest.nl"
5974 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5975 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5976 as_fn_arith $ac_count + 1 && ac_count=$as_val
5977 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5978 # Best one so far, save it but keep looking for a better one
5979 ac_cv_path_EGREP="$ac_path_EGREP"
5980 ac_path_EGREP_max=$ac_count
5982 # 10*(2^10) chars as input seems more than enough
5983 test $ac_count -gt 10 && break
5984 done
5985 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5986 esac
5988 $ac_path_EGREP_found && break 3
5989 done
5990 done
5991 done
5992 IFS=$as_save_IFS
5993 if test -z "$ac_cv_path_EGREP"; then
5994 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5996 else
5997 ac_cv_path_EGREP=$EGREP
6002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6003 $as_echo "$ac_cv_path_EGREP" >&6; }
6004 EGREP="$ac_cv_path_EGREP"
6009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6010 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6011 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6012 $as_echo_n "(cached) " >&6
6013 else
6015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6016 /* end confdefs.h. */
6018 #ifdef __ACK__
6019 Amsterdam
6020 #endif
6022 _ACEOF
6023 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6024 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6025 gl_cv_c_amsterdam_compiler=yes
6026 else
6027 gl_cv_c_amsterdam_compiler=no
6029 rm -f conftest*
6033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6034 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6035 if test -z "$AR"; then
6036 if test $gl_cv_c_amsterdam_compiler = yes; then
6037 AR='cc -c.a'
6038 if test -z "$ARFLAGS"; then
6039 ARFLAGS='-o'
6041 else
6042 if test -n "$ac_tool_prefix"; then
6043 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6044 set dummy ${ac_tool_prefix}ar; ac_word=$2
6045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6046 $as_echo_n "checking for $ac_word... " >&6; }
6047 if test "${ac_cv_prog_AR+set}" = set; then :
6048 $as_echo_n "(cached) " >&6
6049 else
6050 if test -n "$AR"; then
6051 ac_cv_prog_AR="$AR" # Let the user override the test.
6052 else
6053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6054 for as_dir in $PATH
6056 IFS=$as_save_IFS
6057 test -z "$as_dir" && as_dir=.
6058 for ac_exec_ext in '' $ac_executable_extensions; do
6059 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6060 ac_cv_prog_AR="${ac_tool_prefix}ar"
6061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6062 break 2
6064 done
6065 done
6066 IFS=$as_save_IFS
6070 AR=$ac_cv_prog_AR
6071 if test -n "$AR"; then
6072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6073 $as_echo "$AR" >&6; }
6074 else
6075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6076 $as_echo "no" >&6; }
6081 if test -z "$ac_cv_prog_AR"; then
6082 ac_ct_AR=$AR
6083 # Extract the first word of "ar", so it can be a program name with args.
6084 set dummy ar; ac_word=$2
6085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6086 $as_echo_n "checking for $ac_word... " >&6; }
6087 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6088 $as_echo_n "(cached) " >&6
6089 else
6090 if test -n "$ac_ct_AR"; then
6091 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6092 else
6093 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6094 for as_dir in $PATH
6096 IFS=$as_save_IFS
6097 test -z "$as_dir" && as_dir=.
6098 for ac_exec_ext in '' $ac_executable_extensions; do
6099 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6100 ac_cv_prog_ac_ct_AR="ar"
6101 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6102 break 2
6104 done
6105 done
6106 IFS=$as_save_IFS
6110 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6111 if test -n "$ac_ct_AR"; then
6112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6113 $as_echo "$ac_ct_AR" >&6; }
6114 else
6115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6116 $as_echo "no" >&6; }
6119 if test "x$ac_ct_AR" = x; then
6120 AR="ar"
6121 else
6122 case $cross_compiling:$ac_tool_warned in
6123 yes:)
6124 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6125 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6126 ac_tool_warned=yes ;;
6127 esac
6128 AR=$ac_ct_AR
6130 else
6131 AR="$ac_cv_prog_AR"
6134 if test -z "$ARFLAGS"; then
6135 ARFLAGS='cru'
6138 else
6139 if test -z "$ARFLAGS"; then
6140 ARFLAGS='cru'
6145 if test -z "$RANLIB"; then
6146 if test $gl_cv_c_amsterdam_compiler = yes; then
6147 RANLIB=':'
6148 else
6149 if test -n "$ac_tool_prefix"; then
6150 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6151 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6153 $as_echo_n "checking for $ac_word... " >&6; }
6154 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6155 $as_echo_n "(cached) " >&6
6156 else
6157 if test -n "$RANLIB"; then
6158 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6159 else
6160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6161 for as_dir in $PATH
6163 IFS=$as_save_IFS
6164 test -z "$as_dir" && as_dir=.
6165 for ac_exec_ext in '' $ac_executable_extensions; do
6166 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6167 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6169 break 2
6171 done
6172 done
6173 IFS=$as_save_IFS
6177 RANLIB=$ac_cv_prog_RANLIB
6178 if test -n "$RANLIB"; then
6179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6180 $as_echo "$RANLIB" >&6; }
6181 else
6182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6183 $as_echo "no" >&6; }
6188 if test -z "$ac_cv_prog_RANLIB"; then
6189 ac_ct_RANLIB=$RANLIB
6190 # Extract the first word of "ranlib", so it can be a program name with args.
6191 set dummy ranlib; ac_word=$2
6192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6193 $as_echo_n "checking for $ac_word... " >&6; }
6194 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6195 $as_echo_n "(cached) " >&6
6196 else
6197 if test -n "$ac_ct_RANLIB"; then
6198 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6199 else
6200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6201 for as_dir in $PATH
6203 IFS=$as_save_IFS
6204 test -z "$as_dir" && as_dir=.
6205 for ac_exec_ext in '' $ac_executable_extensions; do
6206 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6207 ac_cv_prog_ac_ct_RANLIB="ranlib"
6208 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6209 break 2
6211 done
6212 done
6213 IFS=$as_save_IFS
6217 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6218 if test -n "$ac_ct_RANLIB"; then
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6220 $as_echo "$ac_ct_RANLIB" >&6; }
6221 else
6222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6223 $as_echo "no" >&6; }
6226 if test "x$ac_ct_RANLIB" = x; then
6227 RANLIB=":"
6228 else
6229 case $cross_compiling:$ac_tool_warned in
6230 yes:)
6231 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6232 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6233 ac_tool_warned=yes ;;
6234 esac
6235 RANLIB=$ac_ct_RANLIB
6237 else
6238 RANLIB="$ac_cv_prog_RANLIB"
6245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6246 $as_echo_n "checking for ANSI C header files... " >&6; }
6247 if test "${ac_cv_header_stdc+set}" = set; then :
6248 $as_echo_n "(cached) " >&6
6249 else
6250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6251 /* end confdefs.h. */
6252 #include <stdlib.h>
6253 #include <stdarg.h>
6254 #include <string.h>
6255 #include <float.h>
6258 main ()
6262 return 0;
6264 _ACEOF
6265 if ac_fn_c_try_compile "$LINENO"; then :
6266 ac_cv_header_stdc=yes
6267 else
6268 ac_cv_header_stdc=no
6270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6272 if test $ac_cv_header_stdc = yes; then
6273 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6275 /* end confdefs.h. */
6276 #include <string.h>
6278 _ACEOF
6279 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6280 $EGREP "memchr" >/dev/null 2>&1; then :
6282 else
6283 ac_cv_header_stdc=no
6285 rm -f conftest*
6289 if test $ac_cv_header_stdc = yes; then
6290 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6292 /* end confdefs.h. */
6293 #include <stdlib.h>
6295 _ACEOF
6296 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6297 $EGREP "free" >/dev/null 2>&1; then :
6299 else
6300 ac_cv_header_stdc=no
6302 rm -f conftest*
6306 if test $ac_cv_header_stdc = yes; then
6307 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6308 if test "$cross_compiling" = yes; then :
6310 else
6311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6312 /* end confdefs.h. */
6313 #include <ctype.h>
6314 #include <stdlib.h>
6315 #if ((' ' & 0x0FF) == 0x020)
6316 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6317 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6318 #else
6319 # define ISLOWER(c) \
6320 (('a' <= (c) && (c) <= 'i') \
6321 || ('j' <= (c) && (c) <= 'r') \
6322 || ('s' <= (c) && (c) <= 'z'))
6323 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6324 #endif
6326 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6328 main ()
6330 int i;
6331 for (i = 0; i < 256; i++)
6332 if (XOR (islower (i), ISLOWER (i))
6333 || toupper (i) != TOUPPER (i))
6334 return 2;
6335 return 0;
6337 _ACEOF
6338 if ac_fn_c_try_run "$LINENO"; then :
6340 else
6341 ac_cv_header_stdc=no
6343 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6344 conftest.$ac_objext conftest.beam conftest.$ac_ext
6349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6350 $as_echo "$ac_cv_header_stdc" >&6; }
6351 if test $ac_cv_header_stdc = yes; then
6353 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6357 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6358 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6359 inttypes.h stdint.h unistd.h
6360 do :
6361 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6362 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6364 eval as_val=\$$as_ac_Header
6365 if test "x$as_val" = x""yes; then :
6366 cat >>confdefs.h <<_ACEOF
6367 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6368 _ACEOF
6372 done
6378 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6379 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6380 MINIX=yes
6381 else
6382 MINIX=
6386 if test "$MINIX" = yes; then
6388 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6391 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6394 $as_echo "#define _MINIX 1" >>confdefs.h
6398 case "$host_os" in
6399 hpux*)
6401 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6404 esac
6407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6408 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6409 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6410 $as_echo_n "(cached) " >&6
6411 else
6412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6413 /* end confdefs.h. */
6415 # define __EXTENSIONS__ 1
6416 $ac_includes_default
6418 main ()
6422 return 0;
6424 _ACEOF
6425 if ac_fn_c_try_compile "$LINENO"; then :
6426 ac_cv_safe_to_define___extensions__=yes
6427 else
6428 ac_cv_safe_to_define___extensions__=no
6430 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6433 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6434 test $ac_cv_safe_to_define___extensions__ = yes &&
6435 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6437 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6439 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6441 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6443 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6445 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6454 # Check whether --enable-largefile was given.
6455 if test "${enable_largefile+set}" = set; then :
6456 enableval=$enable_largefile;
6459 if test "$enable_largefile" != no; then
6461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6462 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6463 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6464 $as_echo_n "(cached) " >&6
6465 else
6466 ac_cv_sys_largefile_CC=no
6467 if test "$GCC" != yes; then
6468 ac_save_CC=$CC
6469 while :; do
6470 # IRIX 6.2 and later do not support large files by default,
6471 # so use the C compiler's -n32 option if that helps.
6472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6473 /* end confdefs.h. */
6474 #include <sys/types.h>
6475 /* Check that off_t can represent 2**63 - 1 correctly.
6476 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6477 since some C++ compilers masquerading as C compilers
6478 incorrectly reject 9223372036854775807. */
6479 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6480 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6481 && LARGE_OFF_T % 2147483647 == 1)
6482 ? 1 : -1];
6484 main ()
6488 return 0;
6490 _ACEOF
6491 if ac_fn_c_try_compile "$LINENO"; then :
6492 break
6494 rm -f core conftest.err conftest.$ac_objext
6495 CC="$CC -n32"
6496 if ac_fn_c_try_compile "$LINENO"; then :
6497 ac_cv_sys_largefile_CC=' -n32'; break
6499 rm -f core conftest.err conftest.$ac_objext
6500 break
6501 done
6502 CC=$ac_save_CC
6503 rm -f conftest.$ac_ext
6506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6507 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6508 if test "$ac_cv_sys_largefile_CC" != no; then
6509 CC=$CC$ac_cv_sys_largefile_CC
6512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6513 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6514 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6515 $as_echo_n "(cached) " >&6
6516 else
6517 while :; do
6518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6519 /* end confdefs.h. */
6520 #include <sys/types.h>
6521 /* Check that off_t can represent 2**63 - 1 correctly.
6522 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6523 since some C++ compilers masquerading as C compilers
6524 incorrectly reject 9223372036854775807. */
6525 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6526 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6527 && LARGE_OFF_T % 2147483647 == 1)
6528 ? 1 : -1];
6530 main ()
6534 return 0;
6536 _ACEOF
6537 if ac_fn_c_try_compile "$LINENO"; then :
6538 ac_cv_sys_file_offset_bits=no; break
6540 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6542 /* end confdefs.h. */
6543 #define _FILE_OFFSET_BITS 64
6544 #include <sys/types.h>
6545 /* Check that off_t can represent 2**63 - 1 correctly.
6546 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6547 since some C++ compilers masquerading as C compilers
6548 incorrectly reject 9223372036854775807. */
6549 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6550 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6551 && LARGE_OFF_T % 2147483647 == 1)
6552 ? 1 : -1];
6554 main ()
6558 return 0;
6560 _ACEOF
6561 if ac_fn_c_try_compile "$LINENO"; then :
6562 ac_cv_sys_file_offset_bits=64; break
6564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6565 ac_cv_sys_file_offset_bits=unknown
6566 break
6567 done
6569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6570 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6571 case $ac_cv_sys_file_offset_bits in #(
6572 no | unknown) ;;
6574 cat >>confdefs.h <<_ACEOF
6575 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6576 _ACEOF
6578 esac
6579 rm -rf conftest*
6580 if test $ac_cv_sys_file_offset_bits = unknown; then
6581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6582 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6583 if test "${ac_cv_sys_large_files+set}" = set; then :
6584 $as_echo_n "(cached) " >&6
6585 else
6586 while :; do
6587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6588 /* end confdefs.h. */
6589 #include <sys/types.h>
6590 /* Check that off_t can represent 2**63 - 1 correctly.
6591 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6592 since some C++ compilers masquerading as C compilers
6593 incorrectly reject 9223372036854775807. */
6594 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6595 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6596 && LARGE_OFF_T % 2147483647 == 1)
6597 ? 1 : -1];
6599 main ()
6603 return 0;
6605 _ACEOF
6606 if ac_fn_c_try_compile "$LINENO"; then :
6607 ac_cv_sys_large_files=no; break
6609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6611 /* end confdefs.h. */
6612 #define _LARGE_FILES 1
6613 #include <sys/types.h>
6614 /* Check that off_t can represent 2**63 - 1 correctly.
6615 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6616 since some C++ compilers masquerading as C compilers
6617 incorrectly reject 9223372036854775807. */
6618 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6619 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6620 && LARGE_OFF_T % 2147483647 == 1)
6621 ? 1 : -1];
6623 main ()
6627 return 0;
6629 _ACEOF
6630 if ac_fn_c_try_compile "$LINENO"; then :
6631 ac_cv_sys_large_files=1; break
6633 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6634 ac_cv_sys_large_files=unknown
6635 break
6636 done
6638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6639 $as_echo "$ac_cv_sys_large_files" >&6; }
6640 case $ac_cv_sys_large_files in #(
6641 no | unknown) ;;
6643 cat >>confdefs.h <<_ACEOF
6644 #define _LARGE_FILES $ac_cv_sys_large_files
6645 _ACEOF
6647 esac
6648 rm -rf conftest*
6654 case $ac_cv_prog_cc_stdc in #(
6655 no) :
6656 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6657 *) :
6658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6659 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6660 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6661 $as_echo_n "(cached) " >&6
6662 else
6663 ac_cv_prog_cc_c99=no
6664 ac_save_CC=$CC
6665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6666 /* end confdefs.h. */
6667 #include <stdarg.h>
6668 #include <stdbool.h>
6669 #include <stdlib.h>
6670 #include <wchar.h>
6671 #include <stdio.h>
6673 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6674 #define debug(...) fprintf (stderr, __VA_ARGS__)
6675 #define showlist(...) puts (#__VA_ARGS__)
6676 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6677 static void
6678 test_varargs_macros (void)
6680 int x = 1234;
6681 int y = 5678;
6682 debug ("Flag");
6683 debug ("X = %d\n", x);
6684 showlist (The first, second, and third items.);
6685 report (x>y, "x is %d but y is %d", x, y);
6688 // Check long long types.
6689 #define BIG64 18446744073709551615ull
6690 #define BIG32 4294967295ul
6691 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6692 #if !BIG_OK
6693 your preprocessor is broken;
6694 #endif
6695 #if BIG_OK
6696 #else
6697 your preprocessor is broken;
6698 #endif
6699 static long long int bignum = -9223372036854775807LL;
6700 static unsigned long long int ubignum = BIG64;
6702 struct incomplete_array
6704 int datasize;
6705 double data[];
6708 struct named_init {
6709 int number;
6710 const wchar_t *name;
6711 double average;
6714 typedef const char *ccp;
6716 static inline int
6717 test_restrict (ccp restrict text)
6719 // See if C++-style comments work.
6720 // Iterate through items via the restricted pointer.
6721 // Also check for declarations in for loops.
6722 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6723 continue;
6724 return 0;
6727 // Check varargs and va_copy.
6728 static void
6729 test_varargs (const char *format, ...)
6731 va_list args;
6732 va_start (args, format);
6733 va_list args_copy;
6734 va_copy (args_copy, args);
6736 const char *str;
6737 int number;
6738 float fnumber;
6740 while (*format)
6742 switch (*format++)
6744 case 's': // string
6745 str = va_arg (args_copy, const char *);
6746 break;
6747 case 'd': // int
6748 number = va_arg (args_copy, int);
6749 break;
6750 case 'f': // float
6751 fnumber = va_arg (args_copy, double);
6752 break;
6753 default:
6754 break;
6757 va_end (args_copy);
6758 va_end (args);
6762 main ()
6765 // Check bool.
6766 _Bool success = false;
6768 // Check restrict.
6769 if (test_restrict ("String literal") == 0)
6770 success = true;
6771 char *restrict newvar = "Another string";
6773 // Check varargs.
6774 test_varargs ("s, d' f .", "string", 65, 34.234);
6775 test_varargs_macros ();
6777 // Check flexible array members.
6778 struct incomplete_array *ia =
6779 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6780 ia->datasize = 10;
6781 for (int i = 0; i < ia->datasize; ++i)
6782 ia->data[i] = i * 1.234;
6784 // Check named initializers.
6785 struct named_init ni = {
6786 .number = 34,
6787 .name = L"Test wide string",
6788 .average = 543.34343,
6791 ni.number = 58;
6793 int dynamic_array[ni.number];
6794 dynamic_array[ni.number - 1] = 543;
6796 // work around unused variable warnings
6797 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6798 || dynamic_array[ni.number - 1] != 543);
6801 return 0;
6803 _ACEOF
6804 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6806 CC="$ac_save_CC $ac_arg"
6807 if ac_fn_c_try_compile "$LINENO"; then :
6808 ac_cv_prog_cc_c99=$ac_arg
6810 rm -f core conftest.err conftest.$ac_objext
6811 test "x$ac_cv_prog_cc_c99" != "xno" && break
6812 done
6813 rm -f conftest.$ac_ext
6814 CC=$ac_save_CC
6817 # AC_CACHE_VAL
6818 case "x$ac_cv_prog_cc_c99" in
6820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6821 $as_echo "none needed" >&6; } ;;
6822 xno)
6823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6824 $as_echo "unsupported" >&6; } ;;
6826 CC="$CC $ac_cv_prog_cc_c99"
6827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6828 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6829 esac
6830 if test "x$ac_cv_prog_cc_c99" != xno; then :
6831 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6832 else
6833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6834 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6835 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6836 $as_echo_n "(cached) " >&6
6837 else
6838 ac_cv_prog_cc_c89=no
6839 ac_save_CC=$CC
6840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6841 /* end confdefs.h. */
6842 #include <stdarg.h>
6843 #include <stdio.h>
6844 #include <sys/types.h>
6845 #include <sys/stat.h>
6846 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6847 struct buf { int x; };
6848 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6849 static char *e (p, i)
6850 char **p;
6851 int i;
6853 return p[i];
6855 static char *f (char * (*g) (char **, int), char **p, ...)
6857 char *s;
6858 va_list v;
6859 va_start (v,p);
6860 s = g (p, va_arg (v,int));
6861 va_end (v);
6862 return s;
6865 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6866 function prototypes and stuff, but not '\xHH' hex character constants.
6867 These don't provoke an error unfortunately, instead are silently treated
6868 as 'x'. The following induces an error, until -std is added to get
6869 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6870 array size at least. It's necessary to write '\x00'==0 to get something
6871 that's true only with -std. */
6872 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6874 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6875 inside strings and character constants. */
6876 #define FOO(x) 'x'
6877 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6879 int test (int i, double x);
6880 struct s1 {int (*f) (int a);};
6881 struct s2 {int (*f) (double a);};
6882 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6883 int argc;
6884 char **argv;
6886 main ()
6888 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6890 return 0;
6892 _ACEOF
6893 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6894 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6896 CC="$ac_save_CC $ac_arg"
6897 if ac_fn_c_try_compile "$LINENO"; then :
6898 ac_cv_prog_cc_c89=$ac_arg
6900 rm -f core conftest.err conftest.$ac_objext
6901 test "x$ac_cv_prog_cc_c89" != "xno" && break
6902 done
6903 rm -f conftest.$ac_ext
6904 CC=$ac_save_CC
6907 # AC_CACHE_VAL
6908 case "x$ac_cv_prog_cc_c89" in
6910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6911 $as_echo "none needed" >&6; } ;;
6912 xno)
6913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6914 $as_echo "unsupported" >&6; } ;;
6916 CC="$CC $ac_cv_prog_cc_c89"
6917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6918 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6919 esac
6920 if test "x$ac_cv_prog_cc_c89" != xno; then :
6921 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6922 else
6923 ac_cv_prog_cc_stdc=no
6928 esac
6929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6930 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6931 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6932 $as_echo_n "(cached) " >&6
6935 case $ac_cv_prog_cc_stdc in #(
6936 no) :
6937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6938 $as_echo "unsupported" >&6; } ;; #(
6939 '') :
6940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6941 $as_echo "none needed" >&6; } ;; #(
6942 *) :
6943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6944 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6945 esac
6949 # Code from module alloca-opt:
6950 # Code from module allocator:
6951 # Code from module c-ctype:
6952 # Code from module c-strcase:
6953 # Code from module careadlinkat:
6954 # Code from module clock-time:
6955 # Code from module crypto/md5:
6956 # Code from module crypto/sha1:
6957 # Code from module crypto/sha256:
6958 # Code from module crypto/sha512:
6959 # Code from module dosname:
6960 # Code from module dtoastr:
6961 # Code from module dtotimespec:
6962 # Code from module dup2:
6963 # Code from module environ:
6964 # Code from module execinfo:
6965 # Code from module extensions:
6967 # Code from module extern-inline:
6968 # Code from module filemode:
6969 # Code from module getloadavg:
6970 # Code from module getopt-gnu:
6971 # Code from module getopt-posix:
6972 # Code from module gettext-h:
6973 # Code from module gettime:
6974 # Code from module gettimeofday:
6975 # Code from module ignore-value:
6976 # Code from module include_next:
6977 # Code from module intprops:
6978 # Code from module inttypes-incomplete:
6979 # Code from module largefile:
6981 # Code from module lstat:
6982 # Code from module manywarnings:
6983 # Code from module mktime:
6984 # Code from module multiarch:
6985 # Code from module nocrash:
6986 # Code from module pathmax:
6987 # Code from module pselect:
6988 # Code from module pthread_sigmask:
6989 # Code from module readlink:
6990 # Code from module signal-h:
6991 # Code from module snippet/_Noreturn:
6992 # Code from module snippet/arg-nonnull:
6993 # Code from module snippet/c++defs:
6994 # Code from module snippet/warn-on-use:
6995 # Code from module socklen:
6996 # Code from module ssize_t:
6997 # Code from module stat:
6998 # Code from module stat-time:
6999 # Code from module stdalign:
7000 # Code from module stdarg:
7004 # Code from module stdbool:
7005 # Code from module stddef:
7006 # Code from module stdint:
7007 # Code from module stdio:
7008 # Code from module stdlib:
7009 # Code from module strftime:
7010 # Code from module strtoimax:
7011 # Code from module strtoll:
7012 # Code from module strtoull:
7013 # Code from module strtoumax:
7014 # Code from module symlink:
7015 # Code from module sys_select:
7016 # Code from module sys_stat:
7017 # Code from module sys_time:
7018 # Code from module time:
7019 # Code from module time_r:
7020 # Code from module timespec:
7021 # Code from module timespec-add:
7022 # Code from module timespec-sub:
7023 # Code from module u64:
7024 # Code from module unistd:
7025 # Code from module utimens:
7026 # Code from module verify:
7027 # Code from module warnings:
7030 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7031 # if -g3 works and the user does not specify CFLAGS.
7032 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7033 if test "$ac_test_CFLAGS" != set; then
7034 case $CFLAGS in
7035 '-g')
7036 emacs_g3_CFLAGS='-g3';;
7037 '-g -O2')
7038 emacs_g3_CFLAGS='-g3 -O2';;
7040 emacs_g3_CFLAGS='';;
7041 esac
7042 if test -n "$emacs_g3_CFLAGS"; then
7043 emacs_save_CFLAGS=$CFLAGS
7044 CFLAGS=$emacs_g3_CFLAGS
7045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7046 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7047 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7048 $as_echo_n "(cached) " >&6
7049 else
7050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7051 /* end confdefs.h. */
7054 main ()
7058 return 0;
7060 _ACEOF
7061 if ac_fn_c_try_link "$LINENO"; then :
7062 emacs_cv_prog_cc_g3=yes
7063 else
7064 emacs_cv_prog_cc_g3=no
7066 rm -f core conftest.err conftest.$ac_objext \
7067 conftest$ac_exeext conftest.$ac_ext
7069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7070 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7071 if test $emacs_cv_prog_cc_g3 = yes; then
7072 CFLAGS=$emacs_g3_CFLAGS
7073 else
7074 CFLAGS=$emacs_save_CFLAGS
7079 # Check whether --enable-gcc-warnings was given.
7080 if test "${enable_gcc_warnings+set}" = set; then :
7081 enableval=$enable_gcc_warnings; case $enableval in
7082 yes|no) ;;
7083 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7084 esac
7085 gl_gcc_warnings=$enableval
7086 else
7087 gl_gcc_warnings=no
7092 # Check whether --enable-link-time-optimization was given.
7093 if test "${enable_link_time_optimization+set}" = set; then :
7094 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7096 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7097 ac_lto_supported=no
7098 if test x$GCC = xyes; then
7099 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7100 if test x$CPUS != x; then
7101 LTO="-flto=$CPUS"
7102 else
7103 LTO="-flto"
7105 old_CFLAGS=$CFLAGS
7106 CFLAGS="$CFLAGS $LTO"
7107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7108 /* end confdefs.h. */
7111 main ()
7115 return 0;
7117 _ACEOF
7118 if ac_fn_c_try_compile "$LINENO"; then :
7119 ac_lto_supported=yes
7120 else
7121 ac_lto_supported=no
7123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7124 CFLAGS="$old_CFLAGS"
7126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7127 $as_echo "$ac_lto_supported" >&6; }
7128 if test "$ac_lto_supported" = "yes"; then
7129 CFLAGS="$CFLAGS $LTO"
7135 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7136 # ------------------------------------------------
7137 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7138 # Otherwise, run RUN-IF-NOT-FOUND.
7141 # When compiling with GCC, prefer -isystem to -I when including system
7142 # include files, to avoid generating useless diagnostics for the files.
7143 if test "$gl_gcc_warnings" != yes; then
7144 isystem='-I'
7145 else
7146 isystem='-isystem '
7148 # This, $nw, is the list of warnings we disable.
7151 case $with_x_toolkit in
7152 lucid | athena | motif)
7153 # Old toolkits mishandle 'const'.
7154 nw="$nw -Wwrite-strings"
7157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7158 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7159 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7160 $as_echo_n "(cached) " >&6
7161 else
7163 gl_save_compiler_FLAGS="$CFLAGS"
7164 as_fn_append CFLAGS " -Werror"
7165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7166 /* end confdefs.h. */
7169 main ()
7173 return 0;
7175 _ACEOF
7176 if ac_fn_c_try_compile "$LINENO"; then :
7177 gl_cv_warn_c__Werror=yes
7178 else
7179 gl_cv_warn_c__Werror=no
7181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7182 CFLAGS="$gl_save_compiler_FLAGS"
7185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7186 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7187 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7188 as_fn_append WERROR_CFLAGS " -Werror"
7193 esac
7196 nw="$nw -Waggregate-return" # anachronistic
7197 nw="$nw -Wlong-long" # C90 is anachronistic
7198 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7199 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7200 nw="$nw -Wtraditional" # Warns on #elif which we use often
7201 nw="$nw -Wcast-qual" # Too many warnings for now
7202 nw="$nw -Wconversion" # Too many warnings for now
7203 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7204 nw="$nw -Wsign-conversion" # Too many warnings for now
7205 nw="$nw -Woverlength-strings" # Not a problem these days
7206 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7207 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7208 nw="$nw -Wpadded" # Our structs are not padded
7209 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7210 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7211 nw="$nw -Wformat-nonliteral" # we do this a lot
7212 nw="$nw -Wvla" # warnings in gettext.h
7213 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7214 nw="$nw -Wswitch-enum" # Too many warnings for now
7215 nw="$nw -Wswitch-default" # Too many warnings for now
7216 nw="$nw -Wfloat-equal" # warns about high-quality code
7217 nw="$nw -Winline" # OK to ignore 'inline'
7218 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7219 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7221 # Emacs doesn't care about shadowing; see
7222 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7223 nw="$nw -Wshadow"
7225 # The following lines should be removable at some point.
7226 nw="$nw -Wstack-protector"
7227 nw="$nw -Wstrict-overflow"
7228 nw="$nw -Wsuggest-attribute=pure"
7232 if test -n "$GCC"; then
7234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7235 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7236 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7237 $as_echo_n "(cached) " >&6
7238 else
7240 gl_save_CFLAGS="$CFLAGS"
7241 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7243 /* end confdefs.h. */
7246 main ()
7250 return 0;
7252 _ACEOF
7253 if ac_fn_c_try_compile "$LINENO"; then :
7254 gl_cv_cc_nomfi_supported=yes
7255 else
7256 gl_cv_cc_nomfi_supported=no
7258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7259 CFLAGS="$gl_save_CFLAGS"
7262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7263 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7265 if test "$gl_cv_cc_nomfi_supported" = yes; then
7266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7267 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7268 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7269 $as_echo_n "(cached) " >&6
7270 else
7272 gl_save_CFLAGS="$CFLAGS"
7273 CFLAGS="$CFLAGS -W -Werror"
7274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7275 /* end confdefs.h. */
7276 void f (void)
7278 typedef struct { int a; int b; } s_t;
7279 s_t s1 = { 0, };
7283 main ()
7287 return 0;
7289 _ACEOF
7290 if ac_fn_c_try_compile "$LINENO"; then :
7291 gl_cv_cc_nomfi_needed=no
7292 else
7293 gl_cv_cc_nomfi_needed=yes
7295 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7296 CFLAGS="$gl_save_CFLAGS"
7300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7301 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7305 gl_manywarn_set=
7306 for gl_manywarn_item in \
7307 -Wall \
7308 -W \
7309 -Wformat-y2k \
7310 -Wformat-nonliteral \
7311 -Wformat-security \
7312 -Winit-self \
7313 -Wmissing-include-dirs \
7314 -Wswitch-default \
7315 -Wswitch-enum \
7316 -Wunused \
7317 -Wunknown-pragmas \
7318 -Wstrict-aliasing \
7319 -Wstrict-overflow \
7320 -Wsystem-headers \
7321 -Wfloat-equal \
7322 -Wtraditional \
7323 -Wtraditional-conversion \
7324 -Wdeclaration-after-statement \
7325 -Wundef \
7326 -Wshadow \
7327 -Wunsafe-loop-optimizations \
7328 -Wpointer-arith \
7329 -Wbad-function-cast \
7330 -Wc++-compat \
7331 -Wcast-qual \
7332 -Wcast-align \
7333 -Wwrite-strings \
7334 -Wconversion \
7335 -Wsign-conversion \
7336 -Wlogical-op \
7337 -Waggregate-return \
7338 -Wstrict-prototypes \
7339 -Wold-style-definition \
7340 -Wmissing-prototypes \
7341 -Wmissing-declarations \
7342 -Wmissing-noreturn \
7343 -Wmissing-format-attribute \
7344 -Wpacked \
7345 -Wpadded \
7346 -Wredundant-decls \
7347 -Wnested-externs \
7348 -Wunreachable-code \
7349 -Winline \
7350 -Winvalid-pch \
7351 -Wlong-long \
7352 -Wvla \
7353 -Wvolatile-register-var \
7354 -Wdisabled-optimization \
7355 -Wstack-protector \
7356 -Woverlength-strings \
7357 -Wbuiltin-macro-redefined \
7358 -Wmudflap \
7359 -Wpacked-bitfield-compat \
7360 -Wsync-nand \
7361 ; do
7362 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7363 done
7364 # The following are not documented in the manual but are included in
7365 # output from gcc --help=warnings.
7366 for gl_manywarn_item in \
7367 -Wattributes \
7368 -Wcoverage-mismatch \
7369 -Wunused-macros \
7370 ; do
7371 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7372 done
7373 # More warnings from gcc 4.6.2 --help=warnings.
7374 for gl_manywarn_item in \
7375 -Wabi \
7376 -Wcpp \
7377 -Wdeprecated \
7378 -Wdeprecated-declarations \
7379 -Wdiv-by-zero \
7380 -Wdouble-promotion \
7381 -Wendif-labels \
7382 -Wextra \
7383 -Wformat-contains-nul \
7384 -Wformat-extra-args \
7385 -Wformat-zero-length \
7386 -Wformat=2 \
7387 -Wmultichar \
7388 -Wnormalized=nfc \
7389 -Woverflow \
7390 -Wpointer-to-int-cast \
7391 -Wpragmas \
7392 -Wsuggest-attribute=const \
7393 -Wsuggest-attribute=noreturn \
7394 -Wsuggest-attribute=pure \
7395 -Wtrampolines \
7396 ; do
7397 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7398 done
7400 # Disable the missing-field-initializers warning if needed
7401 if test "$gl_cv_cc_nomfi_needed" = yes; then
7402 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7405 ws=$gl_manywarn_set
7408 gl_warn_set=
7409 set x $ws; shift
7410 for gl_warn_item
7412 case " $nw " in
7413 *" $gl_warn_item "*)
7416 gl_warn_set="$gl_warn_set $gl_warn_item"
7418 esac
7419 done
7420 ws=$gl_warn_set
7422 for w in $ws; do
7423 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7425 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7426 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7427 $as_echo_n "(cached) " >&6
7428 else
7430 gl_save_compiler_FLAGS="$CFLAGS"
7431 as_fn_append CFLAGS " $w"
7432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7433 /* end confdefs.h. */
7436 main ()
7440 return 0;
7442 _ACEOF
7443 if ac_fn_c_try_compile "$LINENO"; then :
7444 eval "$as_gl_Warn=yes"
7445 else
7446 eval "$as_gl_Warn=no"
7448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7449 CFLAGS="$gl_save_compiler_FLAGS"
7452 eval ac_res=\$$as_gl_Warn
7453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7454 $as_echo "$ac_res" >&6; }
7455 eval as_val=\$$as_gl_Warn
7456 if test "x$as_val" = x""yes; then :
7457 as_fn_append WARN_CFLAGS " $w"
7461 done
7462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7463 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7464 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7465 $as_echo_n "(cached) " >&6
7466 else
7468 gl_save_compiler_FLAGS="$CFLAGS"
7469 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7471 /* end confdefs.h. */
7474 main ()
7478 return 0;
7480 _ACEOF
7481 if ac_fn_c_try_compile "$LINENO"; then :
7482 gl_cv_warn_c__Wno_missing_field_initializers=yes
7483 else
7484 gl_cv_warn_c__Wno_missing_field_initializers=no
7486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7487 CFLAGS="$gl_save_compiler_FLAGS"
7490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7491 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7492 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7493 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7496 # We need this one
7497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7498 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7499 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7500 $as_echo_n "(cached) " >&6
7501 else
7503 gl_save_compiler_FLAGS="$CFLAGS"
7504 as_fn_append CFLAGS " -Wno-sign-compare"
7505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7506 /* end confdefs.h. */
7509 main ()
7513 return 0;
7515 _ACEOF
7516 if ac_fn_c_try_compile "$LINENO"; then :
7517 gl_cv_warn_c__Wno_sign_compare=yes
7518 else
7519 gl_cv_warn_c__Wno_sign_compare=no
7521 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7522 CFLAGS="$gl_save_compiler_FLAGS"
7525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7526 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7527 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7528 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7531 # Too many warnings for now
7532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7533 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7534 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7535 $as_echo_n "(cached) " >&6
7536 else
7538 gl_save_compiler_FLAGS="$CFLAGS"
7539 as_fn_append CFLAGS " -Wno-type-limits"
7540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7541 /* end confdefs.h. */
7544 main ()
7548 return 0;
7550 _ACEOF
7551 if ac_fn_c_try_compile "$LINENO"; then :
7552 gl_cv_warn_c__Wno_type_limits=yes
7553 else
7554 gl_cv_warn_c__Wno_type_limits=no
7556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7557 CFLAGS="$gl_save_compiler_FLAGS"
7560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7561 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7562 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7563 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7566 # Too many warnings for now
7567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7568 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7569 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7570 $as_echo_n "(cached) " >&6
7571 else
7573 gl_save_compiler_FLAGS="$CFLAGS"
7574 as_fn_append CFLAGS " -Wno-switch"
7575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7576 /* end confdefs.h. */
7579 main ()
7583 return 0;
7585 _ACEOF
7586 if ac_fn_c_try_compile "$LINENO"; then :
7587 gl_cv_warn_c__Wno_switch=yes
7588 else
7589 gl_cv_warn_c__Wno_switch=no
7591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7592 CFLAGS="$gl_save_compiler_FLAGS"
7595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7596 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7597 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7598 as_fn_append WARN_CFLAGS " -Wno-switch"
7601 # Too many warnings for now
7602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7603 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7604 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7605 $as_echo_n "(cached) " >&6
7606 else
7608 gl_save_compiler_FLAGS="$CFLAGS"
7609 as_fn_append CFLAGS " -Wno-unused-parameter"
7610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7611 /* end confdefs.h. */
7614 main ()
7618 return 0;
7620 _ACEOF
7621 if ac_fn_c_try_compile "$LINENO"; then :
7622 gl_cv_warn_c__Wno_unused_parameter=yes
7623 else
7624 gl_cv_warn_c__Wno_unused_parameter=no
7626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7627 CFLAGS="$gl_save_compiler_FLAGS"
7630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7631 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7632 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7633 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7636 # Too many warnings for now
7637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7638 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7639 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7640 $as_echo_n "(cached) " >&6
7641 else
7643 gl_save_compiler_FLAGS="$CFLAGS"
7644 as_fn_append CFLAGS " -Wno-format-nonliteral"
7645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7646 /* end confdefs.h. */
7649 main ()
7653 return 0;
7655 _ACEOF
7656 if ac_fn_c_try_compile "$LINENO"; then :
7657 gl_cv_warn_c__Wno_format_nonliteral=yes
7658 else
7659 gl_cv_warn_c__Wno_format_nonliteral=no
7661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7662 CFLAGS="$gl_save_compiler_FLAGS"
7665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7666 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7667 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7668 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7673 # In spite of excluding -Wlogical-op above, it is enabled, as of
7674 # gcc 4.5.0 20090517.
7675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7676 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7677 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7678 $as_echo_n "(cached) " >&6
7679 else
7681 gl_save_compiler_FLAGS="$CFLAGS"
7682 as_fn_append CFLAGS " -Wno-logical-op"
7683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7684 /* end confdefs.h. */
7687 main ()
7691 return 0;
7693 _ACEOF
7694 if ac_fn_c_try_compile "$LINENO"; then :
7695 gl_cv_warn_c__Wno_logical_op=yes
7696 else
7697 gl_cv_warn_c__Wno_logical_op=no
7699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7700 CFLAGS="$gl_save_compiler_FLAGS"
7703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7704 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7705 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7706 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7712 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7713 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7714 $as_echo_n "(cached) " >&6
7715 else
7717 gl_save_compiler_FLAGS="$CFLAGS"
7718 as_fn_append CFLAGS " -fdiagnostics-show-option"
7719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7720 /* end confdefs.h. */
7723 main ()
7727 return 0;
7729 _ACEOF
7730 if ac_fn_c_try_compile "$LINENO"; then :
7731 gl_cv_warn_c__fdiagnostics_show_option=yes
7732 else
7733 gl_cv_warn_c__fdiagnostics_show_option=no
7735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7736 CFLAGS="$gl_save_compiler_FLAGS"
7739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7740 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7741 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7742 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7747 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7748 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7749 $as_echo_n "(cached) " >&6
7750 else
7752 gl_save_compiler_FLAGS="$CFLAGS"
7753 as_fn_append CFLAGS " -funit-at-a-time"
7754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7755 /* end confdefs.h. */
7758 main ()
7762 return 0;
7764 _ACEOF
7765 if ac_fn_c_try_compile "$LINENO"; then :
7766 gl_cv_warn_c__funit_at_a_time=yes
7767 else
7768 gl_cv_warn_c__funit_at_a_time=no
7770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7771 CFLAGS="$gl_save_compiler_FLAGS"
7774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7775 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7776 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7777 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7783 $as_echo "#define lint 1" >>confdefs.h
7786 $as_echo "#define _FORTIFY_SOURCE 2" >>confdefs.h
7789 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7792 # We use a slightly smaller set of warning options for lib/.
7793 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7795 nw="$nw -Wunused-macros"
7798 gl_warn_set=
7799 set x $WARN_CFLAGS; shift
7800 for gl_warn_item
7802 case " $nw " in
7803 *" $gl_warn_item "*)
7806 gl_warn_set="$gl_warn_set $gl_warn_item"
7808 esac
7809 done
7810 GNULIB_WARN_CFLAGS=$gl_warn_set
7817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7818 $as_echo_n "checking whether ln -s works... " >&6; }
7819 LN_S=$as_ln_s
7820 if test "$LN_S" = "ln -s"; then
7821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7822 $as_echo "yes" >&6; }
7823 else
7824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7825 $as_echo "no, using $LN_S" >&6; }
7829 # Extract the first word of "install-info", so it can be a program name with args.
7830 set dummy install-info; ac_word=$2
7831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7832 $as_echo_n "checking for $ac_word... " >&6; }
7833 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7834 $as_echo_n "(cached) " >&6
7835 else
7836 case $INSTALL_INFO in
7837 [\\/]* | ?:[\\/]*)
7838 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7841 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7842 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7844 IFS=$as_save_IFS
7845 test -z "$as_dir" && as_dir=.
7846 for ac_exec_ext in '' $ac_executable_extensions; do
7847 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7848 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7849 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7850 break 2
7852 done
7853 done
7854 IFS=$as_save_IFS
7856 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7858 esac
7860 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7861 if test -n "$INSTALL_INFO"; then
7862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7863 $as_echo "$INSTALL_INFO" >&6; }
7864 else
7865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7866 $as_echo "no" >&6; }
7870 # Extract the first word of "gzip", so it can be a program name with args.
7871 set dummy gzip; ac_word=$2
7872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7873 $as_echo_n "checking for $ac_word... " >&6; }
7874 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7875 $as_echo_n "(cached) " >&6
7876 else
7877 case $GZIP_PROG in
7878 [\\/]* | ?:[\\/]*)
7879 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7882 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7883 for as_dir in $PATH
7885 IFS=$as_save_IFS
7886 test -z "$as_dir" && as_dir=.
7887 for ac_exec_ext in '' $ac_executable_extensions; do
7888 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7889 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7891 break 2
7893 done
7894 done
7895 IFS=$as_save_IFS
7898 esac
7900 GZIP_PROG=$ac_cv_path_GZIP_PROG
7901 if test -n "$GZIP_PROG"; then
7902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7903 $as_echo "$GZIP_PROG" >&6; }
7904 else
7905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7906 $as_echo "no" >&6; }
7911 if test $opsys = gnu-linux; then
7912 # Extract the first word of "paxctl", so it can be a program name with args.
7913 set dummy paxctl; ac_word=$2
7914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7915 $as_echo_n "checking for $ac_word... " >&6; }
7916 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7917 $as_echo_n "(cached) " >&6
7918 else
7919 case $PAXCTL in
7920 [\\/]* | ?:[\\/]*)
7921 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7925 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7927 IFS=$as_save_IFS
7928 test -z "$as_dir" && as_dir=.
7929 for ac_exec_ext in '' $ac_executable_extensions; do
7930 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7931 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
7932 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7933 break 2
7935 done
7936 done
7937 IFS=$as_save_IFS
7940 esac
7942 PAXCTL=$ac_cv_path_PAXCTL
7943 if test -n "$PAXCTL"; then
7944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
7945 $as_echo "$PAXCTL" >&6; }
7946 else
7947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7948 $as_echo "no" >&6; }
7952 if test "X$PAXCTL" != X; then
7953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
7954 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
7955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7956 /* end confdefs.h. */
7959 main ()
7963 return 0;
7965 _ACEOF
7966 if ac_fn_c_try_link "$LINENO"; then :
7967 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7968 $as_echo "yes" >&6; }
7969 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7970 $as_echo "no" >&6; }; PAXCTL=""; fi
7972 rm -f core conftest.err conftest.$ac_objext \
7973 conftest$ac_exeext conftest.$ac_ext
7977 ## Need makeinfo >= 4.7 (?) to build the manuals.
7978 # Extract the first word of "makeinfo", so it can be a program name with args.
7979 set dummy makeinfo; ac_word=$2
7980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7981 $as_echo_n "checking for $ac_word... " >&6; }
7982 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
7983 $as_echo_n "(cached) " >&6
7984 else
7985 case $MAKEINFO in
7986 [\\/]* | ?:[\\/]*)
7987 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7991 for as_dir in $PATH
7993 IFS=$as_save_IFS
7994 test -z "$as_dir" && as_dir=.
7995 for ac_exec_ext in '' $ac_executable_extensions; do
7996 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7997 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
7998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7999 break 2
8001 done
8002 done
8003 IFS=$as_save_IFS
8005 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8007 esac
8009 MAKEINFO=$ac_cv_path_MAKEINFO
8010 if test -n "$MAKEINFO"; then
8011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8012 $as_echo "$MAKEINFO" >&6; }
8013 else
8014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8015 $as_echo "no" >&6; }
8019 if test "$MAKEINFO" != "no" && \
8020 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'`" = x; then
8021 MAKEINFO=no
8024 ## Makeinfo is unusual. For a released Emacs, the manuals are
8025 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8026 ## therefore in the category of "special tools" not normally required, which
8027 ## configure does not have to check for (eg autoconf itself).
8028 ## In a Bazaar checkout on the other hand, the manuals are not included.
8029 ## So makeinfo is a requirement to build from Bazaar, and configure
8030 ## should test for it as it does for any other build requirement.
8031 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8032 ## with pre-built manuals, from a Bazaar checkout.
8033 HAVE_MAKEINFO=yes
8035 if test "$MAKEINFO" = "no"; then
8036 MAKEINFO=makeinfo
8037 if test "x${with_makeinfo}" = "xno"; then
8038 HAVE_MAKEINFO=no
8039 elif test ! -e $srcdir/info/emacs; then
8040 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8041 source tree does not seem to have pre-built manuals in the \`info' directory.
8042 Either install a suitable version of makeinfo, or re-run configure
8043 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8048 INFO_EXT=.info
8049 INFO_OPTS=--no-split
8054 if test x$GCC = xyes; then
8055 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8056 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8057 else
8058 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8059 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8063 late_LDFLAGS=$LDFLAGS
8064 if test x$GCC = xyes; then
8065 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8066 else
8067 LDFLAGS="$LDFLAGS -znocombreloc"
8070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8071 $as_echo_n "checking for -znocombreloc... " >&6; }
8072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8073 /* end confdefs.h. */
8076 main ()
8080 return 0;
8082 _ACEOF
8083 if ac_fn_c_try_link "$LINENO"; then :
8084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8085 $as_echo "yes" >&6; }
8086 else
8087 LDFLAGS=$late_LDFLAGS
8088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8089 $as_echo "no" >&6; }
8091 rm -f core conftest.err conftest.$ac_objext \
8092 conftest$ac_exeext conftest.$ac_ext
8095 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8096 case "$opsys" in
8097 your-opsys-here) CANNOT_DUMP=yes ;;
8098 esac
8100 test "$CANNOT_DUMP" = "yes" && \
8102 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8108 UNEXEC_OBJ=unexelf.o
8109 case "$opsys" in
8110 # MSDOS uses unexcoff.o
8111 # MSWindows uses unexw32.o
8112 aix4-2)
8113 UNEXEC_OBJ=unexaix.o
8115 cygwin)
8116 UNEXEC_OBJ=unexcw.o
8118 darwin)
8119 UNEXEC_OBJ=unexmacosx.o
8121 hpux10-20 | hpux11)
8122 UNEXEC_OBJ=unexhp9k800.o
8124 sol2-10)
8125 # Use the Solaris dldump() function, called from unexsol.c, to dump
8126 # emacs, instead of the generic ELF dump code found in unexelf.c.
8127 # The resulting binary has a complete symbol table, and is better
8128 # for debugging and other observability tools (debuggers, pstack, etc).
8130 # If you encounter a problem using dldump(), please consider sending
8131 # a message to the OpenSolaris tools-linking mailing list:
8132 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8134 # It is likely that dldump() works with older Solaris too, but this has
8135 # not been tested, so for now this change is for Solaris 10 or newer.
8136 UNEXEC_OBJ=unexsol.o
8138 esac
8140 LD_SWITCH_SYSTEM=
8141 case "$opsys" in
8142 freebsd)
8143 ## Let `ld' find image libs and similar things in /usr/local/lib.
8144 ## The system compiler, GCC, has apparently been modified to not
8145 ## look there, contrary to what a stock GCC would do.
8146 ### It's not our place to do this. See bug#10313#17.
8147 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8151 gnu-linux)
8152 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8153 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8156 netbsd)
8157 ### It's not our place to do this. See bug#10313#17.
8158 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8162 openbsd)
8163 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8164 ## otherwise Emacs dumps core on elf systems.
8165 LD_SWITCH_SYSTEM="-Z"
8167 esac
8170 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8172 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8173 ## which has not been defined yet. When this was handled with cpp,
8174 ## it was expanded to null when configure sourced the s/*.h file.
8175 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8176 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8177 ## (or somesuch), but because it is supposed to go at the _front_
8178 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8179 ## Compare with the gnu-linux case below, which added to the end
8180 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8181 ## LD_SWITCH_SYSTEM_TEMACS.
8182 case "$opsys" in
8183 netbsd|openbsd)
8184 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8185 esac
8188 C_SWITCH_MACHINE=
8189 case $canonical in
8190 alpha*)
8191 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8192 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8196 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8197 ## With ELF, make sure that all common symbols get allocated to in the
8198 ## data section. Otherwise, the dump of temacs may miss variables in
8199 ## the shared library that have been initialized. For example, with
8200 ## GNU libc, __malloc_initialized would normally be resolved to the
8201 ## shared library's .bss section, which is fatal.
8202 if test "x$GCC" = "xyes"; then
8203 C_SWITCH_MACHINE="-fno-common"
8204 else
8205 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8207 else
8208 UNEXEC_OBJ=unexalpha.o
8211 esac
8216 C_SWITCH_SYSTEM=
8217 ## Some programs in src produce warnings saying certain subprograms
8218 ## are too complex and need a MAXMEM value greater than 2000 for
8219 ## additional optimization. --nils@exp-math.uni-essen.de
8220 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8221 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8222 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8223 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8227 LIBS_SYSTEM=
8228 case "$opsys" in
8229 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8230 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8232 freebsd) LIBS_SYSTEM="-lutil" ;;
8234 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8236 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8238 ## Motif needs -lgen.
8239 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8240 esac
8244 ### Make sure subsequent tests use flags consistent with the build flags.
8246 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8247 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8248 else
8249 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8252 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8254 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8258 LIB_MATH=-lm
8259 LIB_STANDARD=
8260 START_FILES=
8261 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8263 case $opsys in
8264 cygwin )
8265 LIB_MATH=
8266 START_FILES='pre-crt0.o'
8268 darwin )
8269 ## Adding -lm confuses the dynamic linker, so omit it.
8270 LIB_MATH=
8271 START_FILES='pre-crt0.o'
8273 freebsd )
8274 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8275 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8276 SYSTEM_TYPE=berkeley-unix
8278 gnu-linux | gnu-kfreebsd )
8279 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8280 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8282 hpux10-20 | hpux11 )
8283 LIB_STANDARD=-lc
8284 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8286 netbsd | openbsd )
8287 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8288 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8289 SYSTEM_TYPE=berkeley-unix
8292 sol2* | unixware )
8293 SYSTEM_TYPE=usg-unix-v
8296 esac
8301 cat >>confdefs.h <<_ACEOF
8302 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8303 _ACEOF
8306 crt_files=
8308 for file in x $LIB_STANDARD $START_FILES; do
8309 case "$file" in
8310 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8311 esac
8312 done
8314 if test "x$crt_files" != x; then
8316 ## If user specified a crt-dir, use that unconditionally.
8317 crt_gcc=no
8319 if test "X$CRT_DIR" = "X"; then
8321 CRT_DIR=/usr/lib # default
8323 case "$canonical" in
8324 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8325 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8326 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8327 ## For anything else (eg /usr/lib32), it is up the user to specify
8328 ## the location (bug#5655).
8329 ## Test for crtn.o, not just the directory, because sometimes the
8330 ## directory exists but does not have the relevant files (bug#1287).
8331 ## FIXME better to test for binary compatibility somehow.
8332 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8335 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8336 esac
8338 case "$opsys" in
8339 hpux10-20) CRT_DIR=/lib ;;
8340 esac
8342 test "x${GCC}" = xyes && crt_gcc=yes
8344 fi # CRT_DIR = ""
8346 crt_missing=
8348 for file in $crt_files; do
8350 ## If we're using gcc, try to determine it automatically by asking
8351 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8352 ## system-dependent default from above.]
8353 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8355 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8356 case "$crt_file" in
8357 */*)
8358 CRT_DIR=`$as_dirname -- "$crt_file" ||
8359 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8360 X"$crt_file" : 'X\(//\)[^/]' \| \
8361 X"$crt_file" : 'X\(//\)$' \| \
8362 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8363 $as_echo X"$crt_file" |
8364 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8365 s//\1/
8368 /^X\(\/\/\)[^/].*/{
8369 s//\1/
8372 /^X\(\/\/\)$/{
8373 s//\1/
8376 /^X\(\/\).*/{
8377 s//\1/
8380 s/.*/./; q'`
8382 esac
8385 crt_gcc=no
8387 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8388 done # $crt_files
8390 test "x$crt_missing" = x || \
8391 as_fn_error "Required file(s) not found:$crt_missing
8392 Try using the --with-crt-dir option." "$LINENO" 5
8394 fi # crt_files != ""
8398 case $opsys in
8399 netbsd | openbsd )
8400 if test -f $CRT_DIR/crti.o; then
8402 test -f $CRT_DIR/crtn.o || \
8403 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8405 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8406 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8409 esac
8412 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8413 pre_PKG_CONFIG_LIBS=$LIBS
8415 # Extract the first word of "pkg-config", so it can be a program name with args.
8416 set dummy pkg-config; ac_word=$2
8417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8418 $as_echo_n "checking for $ac_word... " >&6; }
8419 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8420 $as_echo_n "(cached) " >&6
8421 else
8422 case $PKG_CONFIG in
8423 [\\/]* | ?:[\\/]*)
8424 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8427 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8428 for as_dir in $PATH
8430 IFS=$as_save_IFS
8431 test -z "$as_dir" && as_dir=.
8432 for ac_exec_ext in '' $ac_executable_extensions; do
8433 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8434 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8435 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8436 break 2
8438 done
8439 done
8440 IFS=$as_save_IFS
8442 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8444 esac
8446 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8447 if test -n "$PKG_CONFIG"; then
8448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8449 $as_echo "$PKG_CONFIG" >&6; }
8450 else
8451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8452 $as_echo "no" >&6; }
8460 if test "${with_sound}" != "no"; then
8461 # Sound support for GNU/Linux and the free BSDs.
8462 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8463 do :
8464 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8465 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8466 eval as_val=\$$as_ac_Header
8467 if test "x$as_val" = x""yes; then :
8468 cat >>confdefs.h <<_ACEOF
8469 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8470 _ACEOF
8471 have_sound_header=yes
8474 done
8476 # Emulation library used on NetBSD.
8477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8478 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8479 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8480 $as_echo_n "(cached) " >&6
8481 else
8482 ac_check_lib_save_LIBS=$LIBS
8483 LIBS="-lossaudio $LIBS"
8484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8485 /* end confdefs.h. */
8487 /* Override any GCC internal prototype to avoid an error.
8488 Use char because int might match the return type of a GCC
8489 builtin and then its argument prototype would still apply. */
8490 #ifdef __cplusplus
8491 extern "C"
8492 #endif
8493 char _oss_ioctl ();
8495 main ()
8497 return _oss_ioctl ();
8499 return 0;
8501 _ACEOF
8502 if ac_fn_c_try_link "$LINENO"; then :
8503 ac_cv_lib_ossaudio__oss_ioctl=yes
8504 else
8505 ac_cv_lib_ossaudio__oss_ioctl=no
8507 rm -f core conftest.err conftest.$ac_objext \
8508 conftest$ac_exeext conftest.$ac_ext
8509 LIBS=$ac_check_lib_save_LIBS
8511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8512 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8513 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8514 LIBSOUND=-lossaudio
8515 else
8516 LIBSOUND=
8521 ALSA_REQUIRED=1.0.0
8522 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8524 succeeded=no
8526 if test "$PKG_CONFIG" = "no" ; then
8527 HAVE_ALSA=no
8528 else
8529 PKG_CONFIG_MIN_VERSION=0.9.0
8530 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8532 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8534 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8535 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8536 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8537 edit_cflags="
8538 s,///*,/,g
8539 s/^/ /
8540 s/ -I/ $isystem/g
8541 s/^ //
8543 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8544 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8546 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8547 succeeded=yes
8548 else
8549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8550 $as_echo "no" >&6; }
8551 ALSA_CFLAGS=""
8552 ALSA_LIBS=""
8553 ## If we have a custom action on failure, don't print errors, but
8554 ## do set a variable so people can do so.
8555 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
8561 else
8562 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8563 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8567 if test $succeeded = yes; then
8568 HAVE_ALSA=yes
8569 else
8570 HAVE_ALSA=no
8573 if test $HAVE_ALSA = yes; then
8574 SAVE_CFLAGS="$CFLAGS"
8575 SAVE_LIBS="$LIBS"
8576 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8577 LIBS="$ALSA_LIBS $LIBS"
8578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8579 /* end confdefs.h. */
8580 #include <asoundlib.h>
8582 main ()
8584 snd_lib_error_set_handler (0);
8586 return 0;
8588 _ACEOF
8589 if ac_fn_c_try_compile "$LINENO"; then :
8590 emacs_alsa_normal=yes
8591 else
8592 emacs_alsa_normal=no
8594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8595 if test "$emacs_alsa_normal" != yes; then
8596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8597 /* end confdefs.h. */
8598 #include <alsa/asoundlib.h>
8600 main ()
8602 snd_lib_error_set_handler (0);
8604 return 0;
8606 _ACEOF
8607 if ac_fn_c_try_compile "$LINENO"; then :
8608 emacs_alsa_subdir=yes
8609 else
8610 emacs_alsa_subdir=no
8612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8613 if test "$emacs_alsa_subdir" != yes; then
8614 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8616 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8619 CFLAGS="$SAVE_CFLAGS"
8620 LIBS="$SAVE_LIBS"
8621 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8622 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8624 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8628 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8629 case "$opsys" in
8630 gnu-linux|freebsd|netbsd)
8632 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8635 esac
8644 for ac_header in $ac_header_list
8645 do :
8646 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8647 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8649 eval as_val=\$$as_ac_Header
8650 if test "x$as_val" = x""yes; then :
8651 cat >>confdefs.h <<_ACEOF
8652 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8653 _ACEOF
8657 done
8687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8688 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8690 /* end confdefs.h. */
8691 #include <sys/personality.h>
8693 main ()
8695 personality (PER_LINUX32)
8697 return 0;
8699 _ACEOF
8700 if ac_fn_c_try_compile "$LINENO"; then :
8701 emacs_cv_personality_linux32=yes
8702 else
8703 emacs_cv_personality_linux32=no
8705 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8707 $as_echo "$emacs_cv_personality_linux32" >&6; }
8709 if test $emacs_cv_personality_linux32 = yes; then
8711 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8715 for ac_header in term.h
8716 do :
8717 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8718 if test "x$ac_cv_header_term_h" = x""yes; then :
8719 cat >>confdefs.h <<_ACEOF
8720 #define HAVE_TERM_H 1
8721 _ACEOF
8725 done
8727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8728 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8729 if test "${ac_cv_header_time+set}" = set; then :
8730 $as_echo_n "(cached) " >&6
8731 else
8732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8733 /* end confdefs.h. */
8734 #include <sys/types.h>
8735 #include <sys/time.h>
8736 #include <time.h>
8739 main ()
8741 if ((struct tm *) 0)
8742 return 0;
8744 return 0;
8746 _ACEOF
8747 if ac_fn_c_try_compile "$LINENO"; then :
8748 ac_cv_header_time=yes
8749 else
8750 ac_cv_header_time=no
8752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8755 $as_echo "$ac_cv_header_time" >&6; }
8756 if test $ac_cv_header_time = yes; then
8758 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8762 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8763 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8764 ac_have_decl=1
8765 else
8766 ac_have_decl=0
8769 cat >>confdefs.h <<_ACEOF
8770 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8771 _ACEOF
8773 if test $ac_cv_have_decl_sys_siglist != yes; then
8774 # For Tru64, at least:
8775 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8776 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8777 ac_have_decl=1
8778 else
8779 ac_have_decl=0
8782 cat >>confdefs.h <<_ACEOF
8783 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8784 _ACEOF
8786 if test $ac_cv_have_decl___sys_siglist = yes; then
8788 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8793 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8794 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8795 $as_echo_n "(cached) " >&6
8796 else
8797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8798 /* end confdefs.h. */
8799 #include <sys/types.h>
8800 #include <sys/wait.h>
8801 #ifndef WEXITSTATUS
8802 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8803 #endif
8804 #ifndef WIFEXITED
8805 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8806 #endif
8809 main ()
8811 int s;
8812 wait (&s);
8813 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8815 return 0;
8817 _ACEOF
8818 if ac_fn_c_try_compile "$LINENO"; then :
8819 ac_cv_header_sys_wait_h=yes
8820 else
8821 ac_cv_header_sys_wait_h=no
8823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8826 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8827 if test $ac_cv_header_sys_wait_h = yes; then
8829 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8835 $as_echo_n "checking for speed_t... " >&6; }
8836 if test "${emacs_cv_speed_t+set}" = set; then :
8837 $as_echo_n "(cached) " >&6
8838 else
8839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8840 /* end confdefs.h. */
8841 #include <termios.h>
8843 main ()
8845 speed_t x = 1;
8847 return 0;
8849 _ACEOF
8850 if ac_fn_c_try_compile "$LINENO"; then :
8851 emacs_cv_speed_t=yes
8852 else
8853 emacs_cv_speed_t=no
8855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8858 $as_echo "$emacs_cv_speed_t" >&6; }
8859 if test $emacs_cv_speed_t = yes; then
8861 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8866 $as_echo_n "checking for struct exception... " >&6; }
8867 if test "${emacs_cv_struct_exception+set}" = set; then :
8868 $as_echo_n "(cached) " >&6
8869 else
8870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8871 /* end confdefs.h. */
8872 #include <math.h>
8874 main ()
8876 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8878 return 0;
8880 _ACEOF
8881 if ac_fn_c_try_compile "$LINENO"; then :
8882 emacs_cv_struct_exception=yes
8883 else
8884 emacs_cv_struct_exception=no
8886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8889 $as_echo "$emacs_cv_struct_exception" >&6; }
8890 HAVE_EXCEPTION=$emacs_cv_struct_exception
8891 if test $emacs_cv_struct_exception != yes || test $opsys = darwin; then
8893 $as_echo "#define NO_MATHERR 1" >>confdefs.h
8900 for ac_header in net/if.h
8901 do :
8902 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8903 #if HAVE_SYS_SOCKET_H
8904 #include <sys/socket.h>
8905 #endif
8907 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8908 cat >>confdefs.h <<_ACEOF
8909 #define HAVE_NET_IF_H 1
8910 _ACEOF
8914 done
8916 for ac_header in ifaddrs.h
8917 do :
8918 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8919 #if HAVE_SYS_SOCKET_H
8920 #include <sys/socket.h>
8921 #endif
8923 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8924 cat >>confdefs.h <<_ACEOF
8925 #define HAVE_IFADDRS_H 1
8926 _ACEOF
8930 done
8932 for ac_header in net/if_dl.h
8933 do :
8934 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8935 #if HAVE_SYS_SOCKET_H
8936 #include <sys/socket.h>
8937 #endif
8939 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8940 cat >>confdefs.h <<_ACEOF
8941 #define HAVE_NET_IF_DL_H 1
8942 _ACEOF
8946 done
8949 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8950 #if HAVE_SYS_SOCKET_H
8951 #include <sys/socket.h>
8952 #endif
8953 #if HAVE_NET_IF_H
8954 #include <net/if.h>
8955 #endif
8957 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8959 cat >>confdefs.h <<_ACEOF
8960 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8961 _ACEOF
8965 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8966 #if HAVE_SYS_SOCKET_H
8967 #include <sys/socket.h>
8968 #endif
8969 #if HAVE_NET_IF_H
8970 #include <net/if.h>
8971 #endif
8973 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8975 cat >>confdefs.h <<_ACEOF
8976 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8977 _ACEOF
8981 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8982 #if HAVE_SYS_SOCKET_H
8983 #include <sys/socket.h>
8984 #endif
8985 #if HAVE_NET_IF_H
8986 #include <net/if.h>
8987 #endif
8989 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
8991 cat >>confdefs.h <<_ACEOF
8992 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8993 _ACEOF
8997 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8998 #if HAVE_SYS_SOCKET_H
8999 #include <sys/socket.h>
9000 #endif
9001 #if HAVE_NET_IF_H
9002 #include <net/if.h>
9003 #endif
9005 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9007 cat >>confdefs.h <<_ACEOF
9008 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9009 _ACEOF
9013 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9014 #if HAVE_SYS_SOCKET_H
9015 #include <sys/socket.h>
9016 #endif
9017 #if HAVE_NET_IF_H
9018 #include <net/if.h>
9019 #endif
9021 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9023 cat >>confdefs.h <<_ACEOF
9024 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9025 _ACEOF
9029 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9030 #if HAVE_SYS_SOCKET_H
9031 #include <sys/socket.h>
9032 #endif
9033 #if HAVE_NET_IF_H
9034 #include <net/if.h>
9035 #endif
9037 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9039 cat >>confdefs.h <<_ACEOF
9040 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9041 _ACEOF
9049 DEPFLAGS=
9050 MKDEPDIR=":"
9051 deps_frag=deps.mk
9052 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9054 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9055 HAVE_GNU_MAKE=no
9056 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9057 if test "x$testval" != x; then
9058 HAVE_GNU_MAKE=yes
9059 else
9060 ac_enable_autodepend=no
9062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9063 $as_echo "$HAVE_GNU_MAKE" >&6; }
9064 if test $HAVE_GNU_MAKE = yes; then
9065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9066 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9067 SAVE_CFLAGS="$CFLAGS"
9068 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9070 /* end confdefs.h. */
9073 main ()
9077 return 0;
9079 _ACEOF
9080 if ac_fn_c_try_compile "$LINENO"; then :
9082 else
9083 ac_enable_autodepend=no
9085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9086 CFLAGS="$SAVE_CFLAGS"
9087 test -f deps.d || ac_enable_autodepend=no
9088 rm -rf deps.d
9089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9090 $as_echo "$ac_enable_autodepend" >&6; }
9092 if test $ac_enable_autodepend = yes; then
9093 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9094 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9095 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9096 deps_frag=autodeps.mk
9099 deps_frag=$srcdir/src/$deps_frag
9105 lisp_frag=$srcdir/src/lisp.mk
9109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9110 $as_echo_n "checking for long file names... " >&6; }
9111 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9112 $as_echo_n "(cached) " >&6
9113 else
9114 ac_cv_sys_long_file_names=yes
9115 # Test for long file names in all the places we know might matter:
9116 # . the current directory, where building will happen
9117 # $prefix/lib where we will be installing things
9118 # $exec_prefix/lib likewise
9119 # $TMPDIR if set, where it might want to write temporary files
9120 # /tmp where it might want to write temporary files
9121 # /var/tmp likewise
9122 # /usr/tmp likewise
9123 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9124 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9125 # in the usual case where exec_prefix is '${prefix}'.
9126 case $ac_dir in #(
9127 . | /* | ?:[\\/]*) ;; #(
9128 *) continue;;
9129 esac
9130 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9131 ac_xdir=$ac_dir/cf$$
9132 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9133 ac_tf1=$ac_xdir/conftest9012345
9134 ac_tf2=$ac_xdir/conftest9012346
9135 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9136 ac_cv_sys_long_file_names=no
9137 rm -f -r "$ac_xdir" 2>/dev/null
9138 test $ac_cv_sys_long_file_names = no && break
9139 done
9141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9142 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9143 if test $ac_cv_sys_long_file_names = yes; then
9145 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9150 #### Choose a window system.
9152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9153 $as_echo_n "checking for X... " >&6; }
9156 # Check whether --with-x was given.
9157 if test "${with_x+set}" = set; then :
9158 withval=$with_x;
9161 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9162 if test "x$with_x" = xno; then
9163 # The user explicitly disabled X.
9164 have_x=disabled
9165 else
9166 case $x_includes,$x_libraries in #(
9167 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9168 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9169 $as_echo_n "(cached) " >&6
9170 else
9171 # One or both of the vars are not set, and there is no cached value.
9172 ac_x_includes=no ac_x_libraries=no
9173 rm -f -r conftest.dir
9174 if mkdir conftest.dir; then
9175 cd conftest.dir
9176 cat >Imakefile <<'_ACEOF'
9177 incroot:
9178 @echo incroot='${INCROOT}'
9179 usrlibdir:
9180 @echo usrlibdir='${USRLIBDIR}'
9181 libdir:
9182 @echo libdir='${LIBDIR}'
9183 _ACEOF
9184 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9185 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9186 for ac_var in incroot usrlibdir libdir; do
9187 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9188 done
9189 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9190 for ac_extension in a so sl dylib la dll; do
9191 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9192 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9193 ac_im_usrlibdir=$ac_im_libdir; break
9195 done
9196 # Screen out bogus values from the imake configuration. They are
9197 # bogus both because they are the default anyway, and because
9198 # using them would break gcc on systems where it needs fixed includes.
9199 case $ac_im_incroot in
9200 /usr/include) ac_x_includes= ;;
9201 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9202 esac
9203 case $ac_im_usrlibdir in
9204 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9205 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9206 esac
9208 cd ..
9209 rm -f -r conftest.dir
9212 # Standard set of common directories for X headers.
9213 # Check X11 before X11Rn because it is often a symlink to the current release.
9214 ac_x_header_dirs='
9215 /usr/X11/include
9216 /usr/X11R7/include
9217 /usr/X11R6/include
9218 /usr/X11R5/include
9219 /usr/X11R4/include
9221 /usr/include/X11
9222 /usr/include/X11R7
9223 /usr/include/X11R6
9224 /usr/include/X11R5
9225 /usr/include/X11R4
9227 /usr/local/X11/include
9228 /usr/local/X11R7/include
9229 /usr/local/X11R6/include
9230 /usr/local/X11R5/include
9231 /usr/local/X11R4/include
9233 /usr/local/include/X11
9234 /usr/local/include/X11R7
9235 /usr/local/include/X11R6
9236 /usr/local/include/X11R5
9237 /usr/local/include/X11R4
9239 /usr/X386/include
9240 /usr/x386/include
9241 /usr/XFree86/include/X11
9243 /usr/include
9244 /usr/local/include
9245 /usr/unsupported/include
9246 /usr/athena/include
9247 /usr/local/x11r5/include
9248 /usr/lpp/Xamples/include
9250 /usr/openwin/include
9251 /usr/openwin/share/include'
9253 if test "$ac_x_includes" = no; then
9254 # Guess where to find include files, by looking for Xlib.h.
9255 # First, try using that file with no special directory specified.
9256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9257 /* end confdefs.h. */
9258 #include <X11/Xlib.h>
9259 _ACEOF
9260 if ac_fn_c_try_cpp "$LINENO"; then :
9261 # We can compile using X headers with no special include directory.
9262 ac_x_includes=
9263 else
9264 for ac_dir in $ac_x_header_dirs; do
9265 if test -r "$ac_dir/X11/Xlib.h"; then
9266 ac_x_includes=$ac_dir
9267 break
9269 done
9271 rm -f conftest.err conftest.$ac_ext
9272 fi # $ac_x_includes = no
9274 if test "$ac_x_libraries" = no; then
9275 # Check for the libraries.
9276 # See if we find them without any special options.
9277 # Don't add to $LIBS permanently.
9278 ac_save_LIBS=$LIBS
9279 LIBS="-lX11 $LIBS"
9280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9281 /* end confdefs.h. */
9282 #include <X11/Xlib.h>
9284 main ()
9286 XrmInitialize ()
9288 return 0;
9290 _ACEOF
9291 if ac_fn_c_try_link "$LINENO"; then :
9292 LIBS=$ac_save_LIBS
9293 # We can link X programs with no special library path.
9294 ac_x_libraries=
9295 else
9296 LIBS=$ac_save_LIBS
9297 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9299 # Don't even attempt the hair of trying to link an X program!
9300 for ac_extension in a so sl dylib la dll; do
9301 if test -r "$ac_dir/libX11.$ac_extension"; then
9302 ac_x_libraries=$ac_dir
9303 break 2
9305 done
9306 done
9308 rm -f core conftest.err conftest.$ac_objext \
9309 conftest$ac_exeext conftest.$ac_ext
9310 fi # $ac_x_libraries = no
9312 case $ac_x_includes,$ac_x_libraries in #(
9313 no,* | *,no | *\'*)
9314 # Didn't find X, or a directory has "'" in its name.
9315 ac_cv_have_x="have_x=no";; #(
9317 # Record where we found X for the cache.
9318 ac_cv_have_x="have_x=yes\
9319 ac_x_includes='$ac_x_includes'\
9320 ac_x_libraries='$ac_x_libraries'"
9321 esac
9323 ;; #(
9324 *) have_x=yes;;
9325 esac
9326 eval "$ac_cv_have_x"
9327 fi # $with_x != no
9329 if test "$have_x" != yes; then
9330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9331 $as_echo "$have_x" >&6; }
9332 no_x=yes
9333 else
9334 # If each of the values was on the command line, it overrides each guess.
9335 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9336 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9337 # Update the cache value to reflect the command line values.
9338 ac_cv_have_x="have_x=yes\
9339 ac_x_includes='$x_includes'\
9340 ac_x_libraries='$x_libraries'"
9341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9342 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9345 if test "$no_x" = yes; then
9346 window_system=none
9347 else
9348 window_system=x11
9351 LD_SWITCH_X_SITE_RPATH=
9352 if test "${x_libraries}" != NONE; then
9353 if test -n "${x_libraries}"; then
9354 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9355 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9357 x_default_search_path=""
9358 x_search_path=${x_libraries}
9359 if test -z "${x_search_path}"; then
9360 x_search_path=/usr/lib
9362 for x_library in `echo ${x_search_path}: | \
9363 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9364 x_search_path="\
9365 ${x_library}/X11/%L/%T/%N%C%S:\
9366 ${x_library}/X11/%l/%T/%N%C%S:\
9367 ${x_library}/X11/%T/%N%C%S:\
9368 ${x_library}/X11/%L/%T/%N%S:\
9369 ${x_library}/X11/%l/%T/%N%S:\
9370 ${x_library}/X11/%T/%N%S"
9371 if test x"${x_default_search_path}" = x; then
9372 x_default_search_path=${x_search_path}
9373 else
9374 x_default_search_path="${x_search_path}:${x_default_search_path}"
9376 done
9380 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9381 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9384 if test x"${x_includes}" = x; then
9385 bitmapdir=/usr/include/X11/bitmaps
9386 else
9387 # accumulate include directories that have X11 bitmap subdirectories
9388 bmd_acc="dummyval"
9389 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9390 if test -d "${bmd}/X11/bitmaps"; then
9391 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9393 if test -d "${bmd}/bitmaps"; then
9394 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9396 done
9397 if test ${bmd_acc} != "dummyval"; then
9398 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9402 HAVE_NS=no
9403 NS_IMPL_COCOA=no
9404 NS_IMPL_GNUSTEP=no
9405 tmp_CPPFLAGS="$CPPFLAGS"
9406 tmp_CFLAGS="$CFLAGS"
9407 CPPFLAGS="$CPPFLAGS -x objective-c"
9408 CFLAGS="$CFLAGS -x objective-c"
9409 TEMACS_LDFLAGS2="\${LDFLAGS}"
9410 GNU_OBJC_CFLAGS=
9411 if test "${with_ns}" != no; then
9412 if test "${opsys}" = darwin; then
9413 NS_IMPL_COCOA=yes
9414 ns_appdir=`pwd`/nextstep/Emacs.app
9415 ns_appbindir=${ns_appdir}/Contents/MacOS
9416 ns_appresdir=${ns_appdir}/Contents/Resources
9417 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9418 elif test -f $GNUSTEP_CONFIG_FILE; then
9419 NS_IMPL_GNUSTEP=yes
9420 ns_appdir=`pwd`/nextstep/Emacs.app
9421 ns_appbindir=${ns_appdir}
9422 ns_appresdir=${ns_appdir}/Resources
9423 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9424 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9425 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9426 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9427 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9428 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9429 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9430 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9431 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9432 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9433 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9434 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9435 LIB_STANDARD=
9436 START_FILES=
9437 TEMACS_LDFLAGS2=
9438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9439 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9440 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9441 $as_echo_n "(cached) " >&6
9442 else
9443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9444 /* end confdefs.h. */
9445 #include <GNUstepBase/GSConfig.h>
9447 main ()
9449 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9451 #else
9452 fail;
9453 #endif
9455 return 0;
9457 _ACEOF
9458 if ac_fn_c_try_compile "$LINENO"; then :
9459 emacs_cv_objc_exceptions=yes
9460 else
9461 emacs_cv_objc_exceptions=no
9463 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9466 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9467 if test $emacs_cv_objc_exceptions = yes; then
9469 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9471 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9475 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9477 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9478 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9479 HAVE_NS=yes
9480 else
9481 as_fn_error "\`--with-ns' was specified, but the include
9482 files are missing or cannot be compiled." "$LINENO" 5
9486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9487 /* end confdefs.h. */
9488 #include <Foundation/NSObjCRuntime.h>
9490 main ()
9492 NSInteger i;
9494 return 0;
9496 _ACEOF
9497 if ac_fn_c_try_compile "$LINENO"; then :
9498 ns_have_nsinteger=yes
9499 else
9500 ns_have_nsinteger=no
9502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9503 if test $ns_have_nsinteger = yes; then
9505 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9511 INSTALL_ARCH_INDEP_EXTRA=install-etc
9512 ns_self_contained=no
9513 ns_frag=/dev/null
9514 NS_OBJ=
9515 NS_OBJC_OBJ=
9516 if test "${HAVE_NS}" = yes; then
9517 if test "$with_toolkit_scroll_bars" = "no"; then
9518 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9521 window_system=nextstep
9522 with_xft=no
9523 # set up packaging dirs
9524 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9525 ns_self_contained=yes
9526 prefix=${ns_appresdir}
9527 exec_prefix=${ns_appbindir}
9528 libexecdir="\${ns_appbindir}/libexec"
9529 archlibdir="\${ns_appbindir}/libexec"
9530 docdir="\${ns_appresdir}/etc"
9531 etcdir="\${ns_appresdir}/etc"
9532 infodir="\${ns_appresdir}/info"
9533 mandir="\${ns_appresdir}/man"
9534 lispdir="\${ns_appresdir}/lisp"
9535 leimdir="\${ns_appresdir}/leim"
9536 INSTALL_ARCH_INDEP_EXTRA=
9538 ns_frag=$srcdir/src/ns.mk
9539 NS_OBJ="fontset.o fringe.o image.o"
9540 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9542 CFLAGS="$tmp_CFLAGS"
9543 CPPFLAGS="$tmp_CPPFLAGS"
9551 case "${window_system}" in
9552 x11 )
9553 HAVE_X_WINDOWS=yes
9554 HAVE_X11=yes
9555 case "${with_x_toolkit}" in
9556 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9557 motif ) USE_X_TOOLKIT=MOTIF ;;
9558 gtk ) with_gtk=yes
9559 USE_X_TOOLKIT=none ;;
9560 gtk3 ) with_gtk3=yes
9561 USE_X_TOOLKIT=none ;;
9562 no ) USE_X_TOOLKIT=none ;;
9563 * ) USE_X_TOOLKIT=maybe ;;
9564 esac
9566 nextstep | none )
9567 HAVE_X_WINDOWS=no
9568 HAVE_X11=no
9569 USE_X_TOOLKIT=none
9571 esac
9573 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9574 # Extract the first word of "X", so it can be a program name with args.
9575 set dummy X; ac_word=$2
9576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9577 $as_echo_n "checking for $ac_word... " >&6; }
9578 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9579 $as_echo_n "(cached) " >&6
9580 else
9581 if test -n "$HAVE_XSERVER"; then
9582 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9583 else
9584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9585 for as_dir in $PATH
9587 IFS=$as_save_IFS
9588 test -z "$as_dir" && as_dir=.
9589 for ac_exec_ext in '' $ac_executable_extensions; do
9590 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9591 ac_cv_prog_HAVE_XSERVER="true"
9592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9593 break 2
9595 done
9596 done
9597 IFS=$as_save_IFS
9599 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9602 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9603 if test -n "$HAVE_XSERVER"; then
9604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9605 $as_echo "$HAVE_XSERVER" >&6; }
9606 else
9607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9608 $as_echo "no" >&6; }
9612 if test "$HAVE_XSERVER" = true ||
9613 test -n "$DISPLAY" ||
9614 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9615 as_fn_error "You seem to be running X, but no X development libraries
9616 were found. You should install the relevant development files for X
9617 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9618 sure you have development files for image handling, i.e.
9619 tiff, gif, jpeg, png and xpm.
9620 If you are sure you want Emacs compiled without X window support, pass
9621 --without-x
9622 to configure." "$LINENO" 5
9626 ### If we're using X11, we should use the X menu package.
9627 HAVE_MENUS=no
9628 case ${HAVE_X11} in
9629 yes ) HAVE_MENUS=yes ;;
9630 esac
9632 # Does the opsystem file prohibit the use of the GNU malloc?
9633 # Assume not, until told otherwise.
9634 GNU_MALLOC=yes
9636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9637 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9638 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9639 $as_echo_n "(cached) " >&6
9640 else
9641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9642 /* end confdefs.h. */
9643 #include <malloc.h>
9644 static void hook (void) {}
9646 main ()
9648 malloc_set_state (malloc_get_state ());
9649 __after_morecore_hook = hook;
9650 __malloc_initialize_hook = hook;
9652 return 0;
9654 _ACEOF
9655 if ac_fn_c_try_link "$LINENO"; then :
9656 emacs_cv_var_doug_lea_malloc=yes
9657 else
9658 emacs_cv_var_doug_lea_malloc=no
9660 rm -f core conftest.err conftest.$ac_objext \
9661 conftest$ac_exeext conftest.$ac_ext
9663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9664 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9665 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9668 system_malloc=no
9669 case "$opsys" in
9670 ## darwin ld insists on the use of malloc routines in the System framework.
9671 darwin|sol2-10) system_malloc=yes ;;
9672 esac
9674 if test "${system_malloc}" = "yes"; then
9676 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9678 GNU_MALLOC=no
9679 GNU_MALLOC_reason="
9680 (The GNU allocators don't work with this system configuration.)"
9681 GMALLOC_OBJ=
9682 VMLIMIT_OBJ=
9683 else
9684 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9685 VMLIMIT_OBJ=vm-limit.o
9690 if test "$doug_lea_malloc" = "yes" ; then
9691 if test "$GNU_MALLOC" = yes ; then
9692 GNU_MALLOC_reason="
9693 (Using Doug Lea's new malloc from the GNU C Library.)"
9696 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9699 ## Use mmap directly for allocating larger buffers.
9700 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9701 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9702 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9703 case "$opsys" in
9704 gnu*) REL_ALLOC=no ;;
9705 esac
9708 if test x"${REL_ALLOC}" = x; then
9709 REL_ALLOC=${GNU_MALLOC}
9712 use_mmap_for_buffers=no
9713 case "$opsys" in
9714 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9715 esac
9724 for ac_func in getpagesize
9725 do :
9726 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9727 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9728 cat >>confdefs.h <<_ACEOF
9729 #define HAVE_GETPAGESIZE 1
9730 _ACEOF
9733 done
9735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9736 $as_echo_n "checking for working mmap... " >&6; }
9737 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9738 $as_echo_n "(cached) " >&6
9739 else
9740 if test "$cross_compiling" = yes; then :
9741 ac_cv_func_mmap_fixed_mapped=no
9742 else
9743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9744 /* end confdefs.h. */
9745 $ac_includes_default
9746 /* malloc might have been renamed as rpl_malloc. */
9747 #undef malloc
9749 /* Thanks to Mike Haertel and Jim Avera for this test.
9750 Here is a matrix of mmap possibilities:
9751 mmap private not fixed
9752 mmap private fixed at somewhere currently unmapped
9753 mmap private fixed at somewhere already mapped
9754 mmap shared not fixed
9755 mmap shared fixed at somewhere currently unmapped
9756 mmap shared fixed at somewhere already mapped
9757 For private mappings, we should verify that changes cannot be read()
9758 back from the file, nor mmap's back from the file at a different
9759 address. (There have been systems where private was not correctly
9760 implemented like the infamous i386 svr4.0, and systems where the
9761 VM page cache was not coherent with the file system buffer cache
9762 like early versions of FreeBSD and possibly contemporary NetBSD.)
9763 For shared mappings, we should conversely verify that changes get
9764 propagated back to all the places they're supposed to be.
9766 Grep wants private fixed already mapped.
9767 The main things grep needs to know about mmap are:
9768 * does it exist and is it safe to write into the mmap'd area
9769 * how to use it (BSD variants) */
9771 #include <fcntl.h>
9772 #include <sys/mman.h>
9774 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9775 char *malloc ();
9776 #endif
9778 /* This mess was copied from the GNU getpagesize.h. */
9779 #ifndef HAVE_GETPAGESIZE
9780 # ifdef _SC_PAGESIZE
9781 # define getpagesize() sysconf(_SC_PAGESIZE)
9782 # else /* no _SC_PAGESIZE */
9783 # ifdef HAVE_SYS_PARAM_H
9784 # include <sys/param.h>
9785 # ifdef EXEC_PAGESIZE
9786 # define getpagesize() EXEC_PAGESIZE
9787 # else /* no EXEC_PAGESIZE */
9788 # ifdef NBPG
9789 # define getpagesize() NBPG * CLSIZE
9790 # ifndef CLSIZE
9791 # define CLSIZE 1
9792 # endif /* no CLSIZE */
9793 # else /* no NBPG */
9794 # ifdef NBPC
9795 # define getpagesize() NBPC
9796 # else /* no NBPC */
9797 # ifdef PAGESIZE
9798 # define getpagesize() PAGESIZE
9799 # endif /* PAGESIZE */
9800 # endif /* no NBPC */
9801 # endif /* no NBPG */
9802 # endif /* no EXEC_PAGESIZE */
9803 # else /* no HAVE_SYS_PARAM_H */
9804 # define getpagesize() 8192 /* punt totally */
9805 # endif /* no HAVE_SYS_PARAM_H */
9806 # endif /* no _SC_PAGESIZE */
9808 #endif /* no HAVE_GETPAGESIZE */
9811 main ()
9813 char *data, *data2, *data3;
9814 const char *cdata2;
9815 int i, pagesize;
9816 int fd, fd2;
9818 pagesize = getpagesize ();
9820 /* First, make a file with some known garbage in it. */
9821 data = (char *) malloc (pagesize);
9822 if (!data)
9823 return 1;
9824 for (i = 0; i < pagesize; ++i)
9825 *(data + i) = rand ();
9826 umask (0);
9827 fd = creat ("conftest.mmap", 0600);
9828 if (fd < 0)
9829 return 2;
9830 if (write (fd, data, pagesize) != pagesize)
9831 return 3;
9832 close (fd);
9834 /* Next, check that the tail of a page is zero-filled. File must have
9835 non-zero length, otherwise we risk SIGBUS for entire page. */
9836 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9837 if (fd2 < 0)
9838 return 4;
9839 cdata2 = "";
9840 if (write (fd2, cdata2, 1) != 1)
9841 return 5;
9842 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9843 if (data2 == MAP_FAILED)
9844 return 6;
9845 for (i = 0; i < pagesize; ++i)
9846 if (*(data2 + i))
9847 return 7;
9848 close (fd2);
9849 if (munmap (data2, pagesize))
9850 return 8;
9852 /* Next, try to mmap the file at a fixed address which already has
9853 something else allocated at it. If we can, also make sure that
9854 we see the same garbage. */
9855 fd = open ("conftest.mmap", O_RDWR);
9856 if (fd < 0)
9857 return 9;
9858 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9859 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9860 return 10;
9861 for (i = 0; i < pagesize; ++i)
9862 if (*(data + i) != *(data2 + i))
9863 return 11;
9865 /* Finally, make sure that changes to the mapped area do not
9866 percolate back to the file as seen by read(). (This is a bug on
9867 some variants of i386 svr4.0.) */
9868 for (i = 0; i < pagesize; ++i)
9869 *(data2 + i) = *(data2 + i) + 1;
9870 data3 = (char *) malloc (pagesize);
9871 if (!data3)
9872 return 12;
9873 if (read (fd, data3, pagesize) != pagesize)
9874 return 13;
9875 for (i = 0; i < pagesize; ++i)
9876 if (*(data + i) != *(data3 + i))
9877 return 14;
9878 close (fd);
9879 return 0;
9881 _ACEOF
9882 if ac_fn_c_try_run "$LINENO"; then :
9883 ac_cv_func_mmap_fixed_mapped=yes
9884 else
9885 ac_cv_func_mmap_fixed_mapped=no
9887 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9888 conftest.$ac_objext conftest.beam conftest.$ac_ext
9892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9893 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9894 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9896 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9899 rm -f conftest.mmap conftest.txt
9901 if test $use_mmap_for_buffers = yes; then
9903 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9905 REL_ALLOC=no
9908 LIBS="$LIBS_SYSTEM $LIBS"
9910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9911 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
9912 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
9913 $as_echo_n "(cached) " >&6
9914 else
9915 ac_check_lib_save_LIBS=$LIBS
9916 LIBS="-ldnet $LIBS"
9917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9918 /* end confdefs.h. */
9920 /* Override any GCC internal prototype to avoid an error.
9921 Use char because int might match the return type of a GCC
9922 builtin and then its argument prototype would still apply. */
9923 #ifdef __cplusplus
9924 extern "C"
9925 #endif
9926 char dnet_ntoa ();
9928 main ()
9930 return dnet_ntoa ();
9932 return 0;
9934 _ACEOF
9935 if ac_fn_c_try_link "$LINENO"; then :
9936 ac_cv_lib_dnet_dnet_ntoa=yes
9937 else
9938 ac_cv_lib_dnet_dnet_ntoa=no
9940 rm -f core conftest.err conftest.$ac_objext \
9941 conftest$ac_exeext conftest.$ac_ext
9942 LIBS=$ac_check_lib_save_LIBS
9944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9945 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
9946 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
9947 cat >>confdefs.h <<_ACEOF
9948 #define HAVE_LIBDNET 1
9949 _ACEOF
9951 LIBS="-ldnet $LIBS"
9956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
9957 $as_echo_n "checking for main in -lXbsd... " >&6; }
9958 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
9959 $as_echo_n "(cached) " >&6
9960 else
9961 ac_check_lib_save_LIBS=$LIBS
9962 LIBS="-lXbsd $LIBS"
9963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9964 /* end confdefs.h. */
9968 main ()
9970 return main ();
9972 return 0;
9974 _ACEOF
9975 if ac_fn_c_try_link "$LINENO"; then :
9976 ac_cv_lib_Xbsd_main=yes
9977 else
9978 ac_cv_lib_Xbsd_main=no
9980 rm -f core conftest.err conftest.$ac_objext \
9981 conftest$ac_exeext conftest.$ac_ext
9982 LIBS=$ac_check_lib_save_LIBS
9984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
9985 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
9986 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
9987 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9991 LIB_PTHREAD=
9995 if test "$ac_cv_header_pthread_h"; then
9996 if test "$GMALLOC_OBJ" = gmalloc.o; then
9997 emacs_pthread_function=pthread_atfork
9998 else
9999 emacs_pthread_function=pthread_self
10001 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10003 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10004 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10005 $as_echo_n "(cached) " >&6
10006 else
10007 ac_check_lib_save_LIBS=$LIBS
10008 LIBS="-lpthread $LIBS"
10009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10010 /* end confdefs.h. */
10012 /* Override any GCC internal prototype to avoid an error.
10013 Use char because int might match the return type of a GCC
10014 builtin and then its argument prototype would still apply. */
10015 #ifdef __cplusplus
10016 extern "C"
10017 #endif
10018 char $emacs_pthread_function ();
10020 main ()
10022 return $emacs_pthread_function ();
10024 return 0;
10026 _ACEOF
10027 if ac_fn_c_try_link "$LINENO"; then :
10028 eval "$as_ac_Lib=yes"
10029 else
10030 eval "$as_ac_Lib=no"
10032 rm -f core conftest.err conftest.$ac_objext \
10033 conftest$ac_exeext conftest.$ac_ext
10034 LIBS=$ac_check_lib_save_LIBS
10036 eval ac_res=\$$as_ac_Lib
10037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10038 $as_echo "$ac_res" >&6; }
10039 eval as_val=\$$as_ac_Lib
10040 if test "x$as_val" = x""yes; then :
10041 HAVE_PTHREAD=yes
10045 if test "$HAVE_PTHREAD" = yes; then
10046 case "${canonical}" in
10047 *-hpux*) ;;
10048 *) LIB_PTHREAD="-lpthread"
10049 LIBS="$LIB_PTHREAD $LIBS" ;;
10050 esac
10052 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10058 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10059 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10060 $as_echo_n "(cached) " >&6
10061 else
10062 ac_check_lib_save_LIBS=$LIBS
10063 LIBS="-lpthreads $LIBS"
10064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10065 /* end confdefs.h. */
10067 /* Override any GCC internal prototype to avoid an error.
10068 Use char because int might match the return type of a GCC
10069 builtin and then its argument prototype would still apply. */
10070 #ifdef __cplusplus
10071 extern "C"
10072 #endif
10073 char cma_open ();
10075 main ()
10077 return cma_open ();
10079 return 0;
10081 _ACEOF
10082 if ac_fn_c_try_link "$LINENO"; then :
10083 ac_cv_lib_pthreads_cma_open=yes
10084 else
10085 ac_cv_lib_pthreads_cma_open=no
10087 rm -f core conftest.err conftest.$ac_objext \
10088 conftest$ac_exeext conftest.$ac_ext
10089 LIBS=$ac_check_lib_save_LIBS
10091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10092 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10093 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10094 cat >>confdefs.h <<_ACEOF
10095 #define HAVE_LIBPTHREADS 1
10096 _ACEOF
10098 LIBS="-lpthreads $LIBS"
10103 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10104 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10105 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10106 ## added to LIBS in configure would never contain the pthreads part,
10107 ## but the value used in Makefiles might. FIXME?
10109 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10110 ## be harmless on older versions of X where it happens to exist.
10111 test "$opsys" = "aix4-2" && \
10112 test $ac_cv_lib_pthreads_cma_open = yes && \
10113 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10116 case ${host_os} in
10117 aix*)
10118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10119 $as_echo_n "checking for -bbigtoc option... " >&6; }
10120 if test "${gdb_cv_bigtoc+set}" = set; then :
10121 $as_echo_n "(cached) " >&6
10122 else
10124 case $GCC in
10125 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10126 *) gdb_cv_bigtoc=-bbigtoc ;;
10127 esac
10129 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10131 /* end confdefs.h. */
10134 main ()
10136 int i;
10138 return 0;
10140 _ACEOF
10141 if ac_fn_c_try_link "$LINENO"; then :
10143 else
10144 gdb_cv_bigtoc=
10146 rm -f core conftest.err conftest.$ac_objext \
10147 conftest$ac_exeext conftest.$ac_ext
10150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10151 $as_echo "$gdb_cv_bigtoc" >&6; }
10153 esac
10155 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10156 # used for the tests that follow. We set them back to REAL_CFLAGS and
10157 # REAL_CPPFLAGS later on.
10159 REAL_CFLAGS="$CFLAGS"
10160 REAL_CPPFLAGS="$CPPFLAGS"
10162 if test "${HAVE_X11}" = "yes"; then
10163 DEFS="$C_SWITCH_X_SITE $DEFS"
10164 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10165 LIBS="-lX11 $LIBS"
10166 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10167 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10169 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10170 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10171 # but it's more convenient here to set LD_RUN_PATH since this
10172 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10173 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10174 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10175 export LD_RUN_PATH
10178 if test "${opsys}" = "gnu-linux"; then
10179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10180 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10182 /* end confdefs.h. */
10185 main ()
10187 XOpenDisplay ("foo");
10189 return 0;
10191 _ACEOF
10192 if ac_fn_c_try_link "$LINENO"; then :
10193 xgnu_linux_first_failure=no
10194 else
10195 xgnu_linux_first_failure=yes
10197 rm -f core conftest.err conftest.$ac_objext \
10198 conftest$ac_exeext conftest.$ac_ext
10199 if test "${xgnu_linux_first_failure}" = "yes"; then
10200 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10201 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10202 OLD_CPPFLAGS="$CPPFLAGS"
10203 OLD_LIBS="$LIBS"
10204 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10205 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10206 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10207 LIBS="$LIBS -b i486-linuxaout"
10208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10209 /* end confdefs.h. */
10212 main ()
10214 XOpenDisplay ("foo");
10216 return 0;
10218 _ACEOF
10219 if ac_fn_c_try_link "$LINENO"; then :
10220 xgnu_linux_second_failure=no
10221 else
10222 xgnu_linux_second_failure=yes
10224 rm -f core conftest.err conftest.$ac_objext \
10225 conftest$ac_exeext conftest.$ac_ext
10226 if test "${xgnu_linux_second_failure}" = "yes"; then
10227 # If we get the same failure with -b, there is no use adding -b.
10228 # So take it out. This plays safe.
10229 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10230 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10231 CPPFLAGS="$OLD_CPPFLAGS"
10232 LIBS="$OLD_LIBS"
10233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10234 $as_echo "no" >&6; }
10235 else
10236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10237 $as_echo "yes" >&6; }
10239 else
10240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10241 $as_echo "no" >&6; }
10245 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10246 # header files included from there.
10247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10248 $as_echo_n "checking for Xkb... " >&6; }
10249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10250 /* end confdefs.h. */
10251 #include <X11/Xlib.h>
10252 #include <X11/XKBlib.h>
10254 main ()
10256 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10258 return 0;
10260 _ACEOF
10261 if ac_fn_c_try_link "$LINENO"; then :
10262 emacs_xkb=yes
10263 else
10264 emacs_xkb=no
10266 rm -f core conftest.err conftest.$ac_objext \
10267 conftest$ac_exeext conftest.$ac_ext
10268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10269 $as_echo "$emacs_xkb" >&6; }
10270 if test $emacs_xkb = yes; then
10272 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10276 for ac_func in XrmSetDatabase XScreenResourceString \
10277 XScreenNumberOfScreen
10278 do :
10279 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10280 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10281 eval as_val=\$$as_ac_var
10282 if test "x$as_val" = x""yes; then :
10283 cat >>confdefs.h <<_ACEOF
10284 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10285 _ACEOF
10288 done
10292 if test "${window_system}" = "x11"; then
10293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10294 $as_echo_n "checking X11 version 6... " >&6; }
10295 if test "${emacs_cv_x11_version_6+set}" = set; then :
10296 $as_echo_n "(cached) " >&6
10297 else
10298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10299 /* end confdefs.h. */
10300 #include <X11/Xlib.h>
10302 main ()
10304 #if XlibSpecificationRelease < 6
10305 fail;
10306 #endif
10309 return 0;
10311 _ACEOF
10312 if ac_fn_c_try_link "$LINENO"; then :
10313 emacs_cv_x11_version_6=yes
10314 else
10315 emacs_cv_x11_version_6=no
10317 rm -f core conftest.err conftest.$ac_objext \
10318 conftest$ac_exeext conftest.$ac_ext
10321 if test $emacs_cv_x11_version_6 = yes; then
10322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10323 $as_echo "6 or newer" >&6; }
10325 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10328 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10330 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10331 ## XIM support.
10332 case "$opsys" in
10333 sol2-*) : ;;
10335 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10338 esac
10339 else
10340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10341 $as_echo "before 6" >&6; }
10346 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10347 HAVE_RSVG=no
10348 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10349 if test "${with_rsvg}" != "no"; then
10350 RSVG_REQUIRED=2.11.0
10351 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10354 succeeded=no
10356 if test "$PKG_CONFIG" = "no" ; then
10358 else
10359 PKG_CONFIG_MIN_VERSION=0.9.0
10360 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10362 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10364 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10365 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10366 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10367 edit_cflags="
10368 s,///*,/,g
10369 s/^/ /
10370 s/ -I/ $isystem/g
10371 s/^ //
10373 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10374 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10376 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10377 succeeded=yes
10378 else
10379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10380 $as_echo "no" >&6; }
10381 RSVG_CFLAGS=""
10382 RSVG_LIBS=""
10383 ## If we have a custom action on failure, don't print errors, but
10384 ## do set a variable so people can do so.
10385 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10391 else
10392 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10393 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10397 if test $succeeded = yes; then
10398 HAVE_RSVG=yes
10399 else
10406 if test $HAVE_RSVG = yes; then
10408 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10410 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10411 LIBS="$RSVG_LIBS $LIBS"
10416 HAVE_IMAGEMAGICK=no
10417 if test "${HAVE_X11}" = "yes"; then
10418 if test "${with_imagemagick}" != "no"; then
10419 ## 6.2.8 is the earliest version known to work, but earlier versions
10420 ## might work - let us know if you find one.
10421 ## 6.0.7 does not work. See bug#7955.
10422 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10424 succeeded=no
10426 if test "$PKG_CONFIG" = "no" ; then
10428 else
10429 PKG_CONFIG_MIN_VERSION=0.9.0
10430 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10432 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10434 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10435 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10436 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10437 edit_cflags="
10438 s,///*,/,g
10439 s/^/ /
10440 s/ -I/ $isystem/g
10441 s/^ //
10443 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10444 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10446 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10447 succeeded=yes
10448 else
10449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10450 $as_echo "no" >&6; }
10451 IMAGEMAGICK_CFLAGS=""
10452 IMAGEMAGICK_LIBS=""
10453 ## If we have a custom action on failure, don't print errors, but
10454 ## do set a variable so people can do so.
10455 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10461 else
10462 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10463 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10467 if test $succeeded = yes; then
10468 HAVE_IMAGEMAGICK=yes
10469 else
10476 if test $HAVE_IMAGEMAGICK = yes; then
10478 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10480 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10481 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10482 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10483 do :
10484 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10485 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10486 eval as_val=\$$as_ac_var
10487 if test "x$as_val" = x""yes; then :
10488 cat >>confdefs.h <<_ACEOF
10489 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10490 _ACEOF
10493 done
10500 HAVE_GTK=no
10501 GTK_OBJ=
10502 if test "${with_gtk3}" = "yes"; then
10503 GLIB_REQUIRED=2.28
10504 GTK_REQUIRED=3.0
10505 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10508 succeeded=no
10510 if test "$PKG_CONFIG" = "no" ; then
10511 pkg_check_gtk=no
10512 else
10513 PKG_CONFIG_MIN_VERSION=0.9.0
10514 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10516 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10518 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10519 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10520 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10521 edit_cflags="
10522 s,///*,/,g
10523 s/^/ /
10524 s/ -I/ $isystem/g
10525 s/^ //
10527 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10528 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10530 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10531 succeeded=yes
10532 else
10533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10534 $as_echo "no" >&6; }
10535 GTK_CFLAGS=""
10536 GTK_LIBS=""
10537 ## If we have a custom action on failure, don't print errors, but
10538 ## do set a variable so people can do so.
10539 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10545 else
10546 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10547 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10551 if test $succeeded = yes; then
10552 pkg_check_gtk=yes
10553 else
10554 pkg_check_gtk=no
10557 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10558 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10561 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10563 GTK_OBJ=emacsgtkfixed.o
10566 if test "$pkg_check_gtk" != "yes"; then
10567 HAVE_GTK=no
10568 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10569 GLIB_REQUIRED=2.10
10570 GTK_REQUIRED=2.10
10571 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10574 succeeded=no
10576 if test "$PKG_CONFIG" = "no" ; then
10577 pkg_check_gtk=no
10578 else
10579 PKG_CONFIG_MIN_VERSION=0.9.0
10580 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10582 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10584 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10585 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10586 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10587 edit_cflags="
10588 s,///*,/,g
10589 s/^/ /
10590 s/ -I/ $isystem/g
10591 s/^ //
10593 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10594 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10596 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10597 succeeded=yes
10598 else
10599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10600 $as_echo "no" >&6; }
10601 GTK_CFLAGS=""
10602 GTK_LIBS=""
10603 ## If we have a custom action on failure, don't print errors, but
10604 ## do set a variable so people can do so.
10605 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10611 else
10612 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10613 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10617 if test $succeeded = yes; then
10618 pkg_check_gtk=yes
10619 else
10620 pkg_check_gtk=no
10623 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10624 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10629 if test x"$pkg_check_gtk" = xyes; then
10633 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10634 CFLAGS="$CFLAGS $GTK_CFLAGS"
10635 LIBS="$GTK_LIBS $LIBS"
10636 GTK_COMPILES=no
10637 for ac_func in gtk_main
10638 do :
10639 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10640 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10641 cat >>confdefs.h <<_ACEOF
10642 #define HAVE_GTK_MAIN 1
10643 _ACEOF
10644 GTK_COMPILES=yes
10646 done
10648 if test "${GTK_COMPILES}" != "yes"; then
10649 if test "$USE_X_TOOLKIT" != "maybe"; then
10650 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10652 else
10653 HAVE_GTK=yes
10655 $as_echo "#define USE_GTK 1" >>confdefs.h
10657 GTK_OBJ="gtkutil.o $GTK_OBJ"
10658 USE_X_TOOLKIT=none
10659 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10661 else
10662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10663 closing open displays. This is no problem if you just use
10664 one display, but if you use more than one and close one of them
10665 Emacs may crash." >&5
10666 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10667 closing open displays. This is no problem if you just use
10668 one display, but if you use more than one and close one of them
10669 Emacs may crash." >&2;}
10670 sleep 3
10678 if test "${HAVE_GTK}" = "yes"; then
10680 if test "$with_toolkit_scroll_bars" != no; then
10681 with_toolkit_scroll_bars=yes
10684 HAVE_GTK_FILE_SELECTION=no
10685 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10686 #include <gtk/gtk.h>
10688 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10689 HAVE_GTK_FILE_SELECTION=yes
10690 else
10691 HAVE_GTK_FILE_SELECTION=no
10694 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10695 for ac_func in gtk_file_selection_new
10696 do :
10697 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10698 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10699 cat >>confdefs.h <<_ACEOF
10700 #define HAVE_GTK_FILE_SELECTION_NEW 1
10701 _ACEOF
10704 done
10709 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10710 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10711 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10712 gtk_orientable_set_orientation \
10713 gtk_window_set_has_resize_grip
10714 do :
10715 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10716 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10717 eval as_val=\$$as_ac_var
10718 if test "x$as_val" = x""yes; then :
10719 cat >>confdefs.h <<_ACEOF
10720 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10721 _ACEOF
10724 done
10728 HAVE_DBUS=no
10729 DBUS_OBJ=
10730 if test "${with_dbus}" = "yes"; then
10732 succeeded=no
10734 if test "$PKG_CONFIG" = "no" ; then
10735 HAVE_DBUS=no
10736 else
10737 PKG_CONFIG_MIN_VERSION=0.9.0
10738 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10740 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10742 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10743 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10744 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10745 edit_cflags="
10746 s,///*,/,g
10747 s/^/ /
10748 s/ -I/ $isystem/g
10749 s/^ //
10751 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10752 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10754 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10755 succeeded=yes
10756 else
10757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10758 $as_echo "no" >&6; }
10759 DBUS_CFLAGS=""
10760 DBUS_LIBS=""
10761 ## If we have a custom action on failure, don't print errors, but
10762 ## do set a variable so people can do so.
10763 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
10769 else
10770 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10771 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10775 if test $succeeded = yes; then
10776 HAVE_DBUS=yes
10777 else
10778 HAVE_DBUS=no
10781 if test "$HAVE_DBUS" = yes; then
10782 LIBS="$LIBS $DBUS_LIBS"
10784 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10786 for ac_func in dbus_watch_get_unix_fd \
10787 dbus_type_is_valid \
10788 dbus_validate_bus_name \
10789 dbus_validate_path \
10790 dbus_validate_interface \
10791 dbus_validate_member
10792 do :
10793 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10794 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10795 eval as_val=\$$as_ac_var
10796 if test "x$as_val" = x""yes; then :
10797 cat >>confdefs.h <<_ACEOF
10798 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10799 _ACEOF
10802 done
10804 DBUS_OBJ=dbusbind.o
10809 HAVE_GSETTINGS=no
10810 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10812 succeeded=no
10814 if test "$PKG_CONFIG" = "no" ; then
10815 HAVE_GSETTINGS=no
10816 else
10817 PKG_CONFIG_MIN_VERSION=0.9.0
10818 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10820 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10822 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10823 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10824 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10825 edit_cflags="
10826 s,///*,/,g
10827 s/^/ /
10828 s/ -I/ $isystem/g
10829 s/^ //
10831 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10832 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10834 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10835 succeeded=yes
10836 else
10837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10838 $as_echo "no" >&6; }
10839 GSETTINGS_CFLAGS=""
10840 GSETTINGS_LIBS=""
10841 ## If we have a custom action on failure, don't print errors, but
10842 ## do set a variable so people can do so.
10843 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gio-2.0 >= 2.26"`
10849 else
10850 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10851 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10855 if test $succeeded = yes; then
10856 HAVE_GSETTINGS=yes
10857 else
10858 HAVE_GSETTINGS=no
10861 if test "$HAVE_GSETTINGS" = "yes"; then
10863 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
10865 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
10866 SETTINGS_LIBS="$GSETTINGS_LIBS"
10870 HAVE_GCONF=no
10871 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
10873 succeeded=no
10875 if test "$PKG_CONFIG" = "no" ; then
10876 HAVE_GCONF=no
10877 else
10878 PKG_CONFIG_MIN_VERSION=0.9.0
10879 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
10881 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
10883 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
10884 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
10885 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
10886 edit_cflags="
10887 s,///*,/,g
10888 s/^/ /
10889 s/ -I/ $isystem/g
10890 s/^ //
10892 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
10893 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
10894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
10895 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
10896 succeeded=yes
10897 else
10898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10899 $as_echo "no" >&6; }
10900 GCONF_CFLAGS=""
10901 GCONF_LIBS=""
10902 ## If we have a custom action on failure, don't print errors, but
10903 ## do set a variable so people can do so.
10904 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
10910 else
10911 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10912 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10916 if test $succeeded = yes; then
10917 HAVE_GCONF=yes
10918 else
10919 HAVE_GCONF=no
10922 if test "$HAVE_GCONF" = yes; then
10924 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
10926 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
10927 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
10931 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
10932 SAVE_CFLAGS="$CFLAGS"
10933 SAVE_LIBS="$LIBS"
10934 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
10935 LIBS="$SETTINGS_LIBS $LIBS"
10936 for ac_func in g_type_init
10937 do :
10938 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
10939 if test "x$ac_cv_func_g_type_init" = x""yes; then :
10940 cat >>confdefs.h <<_ACEOF
10941 #define HAVE_G_TYPE_INIT 1
10942 _ACEOF
10945 done
10947 CFLAGS="$SAVE_CFLAGS"
10948 LIBS="$SAVE_LIBS"
10954 HAVE_LIBSELINUX=no
10955 LIBSELINUX_LIBS=
10956 if test "${with_selinux}" = "yes"; then
10957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
10958 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
10959 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
10960 $as_echo_n "(cached) " >&6
10961 else
10962 ac_check_lib_save_LIBS=$LIBS
10963 LIBS="-lselinux $LIBS"
10964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10965 /* end confdefs.h. */
10967 /* Override any GCC internal prototype to avoid an error.
10968 Use char because int might match the return type of a GCC
10969 builtin and then its argument prototype would still apply. */
10970 #ifdef __cplusplus
10971 extern "C"
10972 #endif
10973 char lgetfilecon ();
10975 main ()
10977 return lgetfilecon ();
10979 return 0;
10981 _ACEOF
10982 if ac_fn_c_try_link "$LINENO"; then :
10983 ac_cv_lib_selinux_lgetfilecon=yes
10984 else
10985 ac_cv_lib_selinux_lgetfilecon=no
10987 rm -f core conftest.err conftest.$ac_objext \
10988 conftest$ac_exeext conftest.$ac_ext
10989 LIBS=$ac_check_lib_save_LIBS
10991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
10992 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
10993 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
10994 HAVE_LIBSELINUX=yes
10995 else
10996 HAVE_LIBSELINUX=no
10999 if test "$HAVE_LIBSELINUX" = yes; then
11001 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11003 LIBSELINUX_LIBS=-lselinux
11008 HAVE_GNUTLS=no
11009 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11010 if test "${with_gnutls}" = "yes" ; then
11012 succeeded=no
11014 if test "$PKG_CONFIG" = "no" ; then
11015 HAVE_GNUTLS=no
11016 else
11017 PKG_CONFIG_MIN_VERSION=0.9.0
11018 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11020 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11022 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11023 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11024 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11025 edit_cflags="
11026 s,///*,/,g
11027 s/^/ /
11028 s/ -I/ $isystem/g
11029 s/^ //
11031 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11032 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11034 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11035 succeeded=yes
11036 else
11037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11038 $as_echo "no" >&6; }
11039 LIBGNUTLS_CFLAGS=""
11040 LIBGNUTLS_LIBS=""
11041 ## If we have a custom action on failure, don't print errors, but
11042 ## do set a variable so people can do so.
11043 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.6"`
11049 else
11050 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11051 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11055 if test $succeeded = yes; then
11056 HAVE_GNUTLS=yes
11057 else
11058 HAVE_GNUTLS=no
11061 if test "${HAVE_GNUTLS}" = "yes"; then
11063 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11067 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11068 LIBS="$LIBGNUTLS_LIBS $LIBS"
11069 for ac_func in gnutls_certificate_set_verify_function
11070 do :
11071 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11072 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11073 cat >>confdefs.h <<_ACEOF
11074 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11075 _ACEOF
11076 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11078 done
11081 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11083 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11091 HAVE_XAW3D=no
11092 LUCID_LIBW=
11093 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11094 if test "$with_xaw3d" != no; then
11095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11096 $as_echo_n "checking for xaw3d... " >&6; }
11097 if test "${emacs_cv_xaw3d+set}" = set; then :
11098 $as_echo_n "(cached) " >&6
11099 else
11100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11101 /* end confdefs.h. */
11103 #include <X11/Intrinsic.h>
11104 #include <X11/Xaw3d/Simple.h>
11106 main ()
11110 return 0;
11112 _ACEOF
11113 if ac_fn_c_try_link "$LINENO"; then :
11114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11115 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11116 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11117 $as_echo_n "(cached) " >&6
11118 else
11119 ac_check_lib_save_LIBS=$LIBS
11120 LIBS="-lXaw3d $LIBS"
11121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11122 /* end confdefs.h. */
11124 /* Override any GCC internal prototype to avoid an error.
11125 Use char because int might match the return type of a GCC
11126 builtin and then its argument prototype would still apply. */
11127 #ifdef __cplusplus
11128 extern "C"
11129 #endif
11130 char XawScrollbarSetThumb ();
11132 main ()
11134 return XawScrollbarSetThumb ();
11136 return 0;
11138 _ACEOF
11139 if ac_fn_c_try_link "$LINENO"; then :
11140 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11141 else
11142 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11144 rm -f core conftest.err conftest.$ac_objext \
11145 conftest$ac_exeext conftest.$ac_ext
11146 LIBS=$ac_check_lib_save_LIBS
11148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11149 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11150 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11151 emacs_cv_xaw3d=yes
11152 else
11153 emacs_cv_xaw3d=no
11156 else
11157 emacs_cv_xaw3d=no
11159 rm -f core conftest.err conftest.$ac_objext \
11160 conftest$ac_exeext conftest.$ac_ext
11163 else
11164 emacs_cv_xaw3d=no
11166 if test $emacs_cv_xaw3d = yes; then
11167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11168 $as_echo "yes; using Lucid toolkit" >&6; }
11169 USE_X_TOOLKIT=LUCID
11170 HAVE_XAW3D=yes
11171 LUCID_LIBW=-lXaw3d
11173 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11175 else
11176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11177 $as_echo "no" >&6; }
11178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11179 $as_echo_n "checking for libXaw... " >&6; }
11180 if test "${emacs_cv_xaw+set}" = set; then :
11181 $as_echo_n "(cached) " >&6
11182 else
11183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11184 /* end confdefs.h. */
11186 #include <X11/Intrinsic.h>
11187 #include <X11/Xaw/Simple.h>
11189 main ()
11193 return 0;
11195 _ACEOF
11196 if ac_fn_c_try_link "$LINENO"; then :
11197 emacs_cv_xaw=yes
11198 else
11199 emacs_cv_xaw=no
11201 rm -f core conftest.err conftest.$ac_objext \
11202 conftest$ac_exeext conftest.$ac_ext
11205 if test $emacs_cv_xaw = yes; then
11206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11207 $as_echo "yes; using Lucid toolkit" >&6; }
11208 USE_X_TOOLKIT=LUCID
11209 LUCID_LIBW=-lXaw
11210 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11211 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11212 else
11213 as_fn_error "No X toolkit could be found.
11214 If you are sure you want Emacs compiled without an X toolkit, pass
11215 --with-x-toolkit=no
11216 to configure. Otherwise, install the development libraries for the toolkit
11217 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11222 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11224 LIBXTR6=
11225 if test "${USE_X_TOOLKIT}" != "none"; then
11226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11227 $as_echo_n "checking X11 toolkit version... " >&6; }
11228 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11229 $as_echo_n "(cached) " >&6
11230 else
11231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11232 /* end confdefs.h. */
11233 #include <X11/Intrinsic.h>
11235 main ()
11237 #if XtSpecificationRelease < 6
11238 fail;
11239 #endif
11242 return 0;
11244 _ACEOF
11245 if ac_fn_c_try_link "$LINENO"; then :
11246 emacs_cv_x11_toolkit_version_6=yes
11247 else
11248 emacs_cv_x11_toolkit_version_6=no
11250 rm -f core conftest.err conftest.$ac_objext \
11251 conftest$ac_exeext conftest.$ac_ext
11254 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11255 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11257 $as_echo "6 or newer" >&6; }
11259 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11261 LIBXTR6="-lSM -lICE"
11262 case "$opsys" in
11263 ## Use libw.a along with X11R6 Xt.
11264 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11265 esac
11266 else
11267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11268 $as_echo "before 6" >&6; }
11271 OLDLIBS="$LIBS"
11272 if test x$HAVE_X11XTR6 = xyes; then
11273 LIBS="-lXt -lSM -lICE $LIBS"
11274 else
11275 LIBS="-lXt $LIBS"
11277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11278 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11279 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11280 $as_echo_n "(cached) " >&6
11281 else
11282 ac_check_lib_save_LIBS=$LIBS
11283 LIBS="-lXmu $LIBS"
11284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11285 /* end confdefs.h. */
11287 /* Override any GCC internal prototype to avoid an error.
11288 Use char because int might match the return type of a GCC
11289 builtin and then its argument prototype would still apply. */
11290 #ifdef __cplusplus
11291 extern "C"
11292 #endif
11293 char XmuConvertStandardSelection ();
11295 main ()
11297 return XmuConvertStandardSelection ();
11299 return 0;
11301 _ACEOF
11302 if ac_fn_c_try_link "$LINENO"; then :
11303 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11304 else
11305 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11307 rm -f core conftest.err conftest.$ac_objext \
11308 conftest$ac_exeext conftest.$ac_ext
11309 LIBS=$ac_check_lib_save_LIBS
11311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11312 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11313 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11314 cat >>confdefs.h <<_ACEOF
11315 #define HAVE_LIBXMU 1
11316 _ACEOF
11318 LIBS="-lXmu $LIBS"
11322 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11326 LIBXMU=-lXmu
11327 case $opsys in
11328 ## These systems don't supply Xmu.
11329 hpux* | aix4-2 )
11330 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11332 esac
11335 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11336 if test "${HAVE_X11}" = "yes"; then
11337 if test "${USE_X_TOOLKIT}" != "none"; then
11338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11339 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11340 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11341 $as_echo_n "(cached) " >&6
11342 else
11343 ac_check_lib_save_LIBS=$LIBS
11344 LIBS="-lXext $LIBS"
11345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11346 /* end confdefs.h. */
11348 /* Override any GCC internal prototype to avoid an error.
11349 Use char because int might match the return type of a GCC
11350 builtin and then its argument prototype would still apply. */
11351 #ifdef __cplusplus
11352 extern "C"
11353 #endif
11354 char XShapeQueryExtension ();
11356 main ()
11358 return XShapeQueryExtension ();
11360 return 0;
11362 _ACEOF
11363 if ac_fn_c_try_link "$LINENO"; then :
11364 ac_cv_lib_Xext_XShapeQueryExtension=yes
11365 else
11366 ac_cv_lib_Xext_XShapeQueryExtension=no
11368 rm -f core conftest.err conftest.$ac_objext \
11369 conftest$ac_exeext conftest.$ac_ext
11370 LIBS=$ac_check_lib_save_LIBS
11372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11373 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11374 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11375 cat >>confdefs.h <<_ACEOF
11376 #define HAVE_LIBXEXT 1
11377 _ACEOF
11379 LIBS="-lXext $LIBS"
11386 LIBXP=
11387 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11388 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11389 if test -d /usr/include/openmotif; then
11390 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11391 emacs_cv_openmotif=yes
11392 case "$canonical" in
11393 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11394 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11397 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11398 esac
11399 else
11400 emacs_cv_openmotif=no
11402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11403 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11404 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11405 $as_echo_n "(cached) " >&6
11406 else
11407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11408 /* end confdefs.h. */
11409 #include <Xm/Xm.h>
11411 main ()
11413 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11414 int x = 5;
11415 #else
11416 Motif version prior to 2.1.
11417 #endif
11419 return 0;
11421 _ACEOF
11422 if ac_fn_c_try_compile "$LINENO"; then :
11423 emacs_cv_motif_version_2_1=yes
11424 else
11425 emacs_cv_motif_version_2_1=no
11427 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11430 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11431 if test $emacs_cv_motif_version_2_1 = yes; then
11432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11433 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11434 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11435 $as_echo_n "(cached) " >&6
11436 else
11437 ac_check_lib_save_LIBS=$LIBS
11438 LIBS="-lXp $LIBS"
11439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11440 /* end confdefs.h. */
11442 /* Override any GCC internal prototype to avoid an error.
11443 Use char because int might match the return type of a GCC
11444 builtin and then its argument prototype would still apply. */
11445 #ifdef __cplusplus
11446 extern "C"
11447 #endif
11448 char XpCreateContext ();
11450 main ()
11452 return XpCreateContext ();
11454 return 0;
11456 _ACEOF
11457 if ac_fn_c_try_link "$LINENO"; then :
11458 ac_cv_lib_Xp_XpCreateContext=yes
11459 else
11460 ac_cv_lib_Xp_XpCreateContext=no
11462 rm -f core conftest.err conftest.$ac_objext \
11463 conftest$ac_exeext conftest.$ac_ext
11464 LIBS=$ac_check_lib_save_LIBS
11466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11467 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11468 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11469 LIBXP=-lXp
11472 if test x$emacs_cv_openmotif = xyes; then
11473 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11475 else
11476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11477 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11478 if test "${emacs_cv_lesstif+set}" = set; then :
11479 $as_echo_n "(cached) " >&6
11480 else
11481 # We put this in CFLAGS temporarily to precede other -I options
11482 # that might be in CFLAGS temporarily.
11483 # We put this in CPPFLAGS where it precedes the other -I options.
11484 OLD_CPPFLAGS=$CPPFLAGS
11485 OLD_CFLAGS=$CFLAGS
11486 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11487 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11489 /* end confdefs.h. */
11490 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11492 main ()
11494 int x = 5;
11496 return 0;
11498 _ACEOF
11499 if ac_fn_c_try_compile "$LINENO"; then :
11500 emacs_cv_lesstif=yes
11501 else
11502 emacs_cv_lesstif=no
11504 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11507 $as_echo "$emacs_cv_lesstif" >&6; }
11508 if test $emacs_cv_lesstif = yes; then
11509 # Make sure this -I option remains in CPPFLAGS after it is set
11510 # back to REAL_CPPFLAGS.
11511 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11512 # have those other -I options anyway. Ultimately, having this
11513 # directory ultimately in CPPFLAGS will be enough.
11514 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11515 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11516 else
11517 CFLAGS=$OLD_CFLAGS
11518 CPPFLAGS=$OLD_CPPFLAGS
11521 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11522 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11524 else
11525 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11532 USE_TOOLKIT_SCROLL_BARS=no
11533 if test "${with_toolkit_scroll_bars}" != "no"; then
11534 if test "${USE_X_TOOLKIT}" != "none"; then
11535 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11536 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11538 HAVE_XAW3D=no
11539 USE_TOOLKIT_SCROLL_BARS=yes
11540 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11541 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11543 USE_TOOLKIT_SCROLL_BARS=yes
11545 elif test "${HAVE_GTK}" = "yes"; then
11546 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11548 USE_TOOLKIT_SCROLL_BARS=yes
11549 elif test "${HAVE_NS}" = "yes"; then
11550 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11552 USE_TOOLKIT_SCROLL_BARS=yes
11556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11557 /* end confdefs.h. */
11559 #include <X11/Xlib.h>
11560 #include <X11/Xresource.h>
11562 main ()
11564 XIMProc callback;
11566 return 0;
11568 _ACEOF
11569 if ac_fn_c_try_compile "$LINENO"; then :
11570 HAVE_XIM=yes
11572 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11574 else
11575 HAVE_XIM=no
11577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11580 if test "${with_xim}" != "no"; then
11582 $as_echo "#define USE_XIM 1" >>confdefs.h
11587 if test "${HAVE_XIM}" != "no"; then
11588 late_CFLAGS=$CFLAGS
11589 if test "$GCC" = yes; then
11590 CFLAGS="$CFLAGS --pedantic-errors"
11592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11593 /* end confdefs.h. */
11595 #include <X11/Xlib.h>
11596 #include <X11/Xresource.h>
11598 main ()
11600 Display *display;
11601 XrmDatabase db;
11602 char *res_name;
11603 char *res_class;
11604 XIMProc callback;
11605 XPointer *client_data;
11606 #ifndef __GNUC__
11607 /* If we're not using GCC, it's probably not XFree86, and this is
11608 probably right, but we can't use something like --pedantic-errors. */
11609 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11610 char*, XIMProc, XPointer*);
11611 #endif
11612 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11613 client_data);
11615 return 0;
11617 _ACEOF
11618 if ac_fn_c_try_compile "$LINENO"; then :
11619 emacs_cv_arg6_star=yes
11621 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11622 if test "$emacs_cv_arg6_star" = yes; then
11623 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11625 else
11626 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11629 CFLAGS=$late_CFLAGS
11632 ### Start of font-backend (under any platform) section.
11633 # (nothing here yet -- this is a placeholder)
11634 ### End of font-backend (under any platform) section.
11636 ### Start of font-backend (under X11) section.
11637 if test "${HAVE_X11}" = "yes"; then
11639 succeeded=no
11641 if test "$PKG_CONFIG" = "no" ; then
11642 HAVE_FC=no
11643 else
11644 PKG_CONFIG_MIN_VERSION=0.9.0
11645 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11647 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11649 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11650 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11651 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11652 edit_cflags="
11653 s,///*,/,g
11654 s/^/ /
11655 s/ -I/ $isystem/g
11656 s/^ //
11658 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11659 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11661 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11662 succeeded=yes
11663 else
11664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11665 $as_echo "no" >&6; }
11666 FONTCONFIG_CFLAGS=""
11667 FONTCONFIG_LIBS=""
11668 ## If we have a custom action on failure, don't print errors, but
11669 ## do set a variable so people can do so.
11670 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
11676 else
11677 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11678 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11682 if test $succeeded = yes; then
11683 HAVE_FC=yes
11684 else
11685 HAVE_FC=no
11689 ## Use -lXft if available, unless `--with-xft=no'.
11690 HAVE_XFT=maybe
11691 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11692 with_xft="no";
11694 if test "x${with_xft}" != "xno"; then
11697 succeeded=no
11699 if test "$PKG_CONFIG" = "no" ; then
11700 HAVE_XFT=no
11701 else
11702 PKG_CONFIG_MIN_VERSION=0.9.0
11703 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11705 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11707 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11708 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11709 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11710 edit_cflags="
11711 s,///*,/,g
11712 s/^/ /
11713 s/ -I/ $isystem/g
11714 s/^ //
11716 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11717 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11719 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11720 succeeded=yes
11721 else
11722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11723 $as_echo "no" >&6; }
11724 XFT_CFLAGS=""
11725 XFT_LIBS=""
11726 ## If we have a custom action on failure, don't print errors, but
11727 ## do set a variable so people can do so.
11728 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
11734 else
11735 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11736 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11740 if test $succeeded = yes; then
11742 else
11743 HAVE_XFT=no
11746 ## Because xftfont.c uses XRenderQueryExtension, we also
11747 ## need to link to -lXrender.
11748 HAVE_XRENDER=no
11749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11750 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11751 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11752 $as_echo_n "(cached) " >&6
11753 else
11754 ac_check_lib_save_LIBS=$LIBS
11755 LIBS="-lXrender $LIBS"
11756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11757 /* end confdefs.h. */
11759 /* Override any GCC internal prototype to avoid an error.
11760 Use char because int might match the return type of a GCC
11761 builtin and then its argument prototype would still apply. */
11762 #ifdef __cplusplus
11763 extern "C"
11764 #endif
11765 char XRenderQueryExtension ();
11767 main ()
11769 return XRenderQueryExtension ();
11771 return 0;
11773 _ACEOF
11774 if ac_fn_c_try_link "$LINENO"; then :
11775 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11776 else
11777 ac_cv_lib_Xrender_XRenderQueryExtension=no
11779 rm -f core conftest.err conftest.$ac_objext \
11780 conftest$ac_exeext conftest.$ac_ext
11781 LIBS=$ac_check_lib_save_LIBS
11783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11784 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11785 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11786 HAVE_XRENDER=yes
11789 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11790 OLD_CPPFLAGS="$CPPFLAGS"
11791 OLD_CFLAGS="$CFLAGS"
11792 OLD_LIBS="$LIBS"
11793 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11794 CFLAGS="$CFLAGS $XFT_CFLAGS"
11795 XFT_LIBS="-lXrender $XFT_LIBS"
11796 LIBS="$XFT_LIBS $LIBS"
11797 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
11798 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
11799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
11800 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
11801 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
11802 $as_echo_n "(cached) " >&6
11803 else
11804 ac_check_lib_save_LIBS=$LIBS
11805 LIBS="-lXft $XFT_LIBS $LIBS"
11806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11807 /* end confdefs.h. */
11809 /* Override any GCC internal prototype to avoid an error.
11810 Use char because int might match the return type of a GCC
11811 builtin and then its argument prototype would still apply. */
11812 #ifdef __cplusplus
11813 extern "C"
11814 #endif
11815 char XftFontOpen ();
11817 main ()
11819 return XftFontOpen ();
11821 return 0;
11823 _ACEOF
11824 if ac_fn_c_try_link "$LINENO"; then :
11825 ac_cv_lib_Xft_XftFontOpen=yes
11826 else
11827 ac_cv_lib_Xft_XftFontOpen=no
11829 rm -f core conftest.err conftest.$ac_objext \
11830 conftest$ac_exeext conftest.$ac_ext
11831 LIBS=$ac_check_lib_save_LIBS
11833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11834 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
11835 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
11836 HAVE_XFT=yes
11843 if test "${HAVE_XFT}" = "yes"; then
11845 $as_echo "#define HAVE_XFT 1" >>confdefs.h
11848 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
11849 else
11850 CPPFLAGS="$OLD_CPPFLAGS"
11851 CFLAGS="$OLD_CFLAGS"
11852 LIBS="$OLD_LIBS"
11853 fi # "${HAVE_XFT}" = "yes"
11854 fi # "$HAVE_XFT" != no
11855 fi # "x${with_xft}" != "xno"
11857 ## We used to allow building with FreeType and without Xft.
11858 ## However, the ftx font backend driver is not in good shape.
11859 if test "$HAVE_XFT" != "yes"; then
11860 HAVE_XFT=no
11861 HAVE_FREETYPE=no
11862 else
11864 succeeded=no
11866 if test "$PKG_CONFIG" = "no" ; then
11867 HAVE_FREETYPE=no
11868 else
11869 PKG_CONFIG_MIN_VERSION=0.9.0
11870 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
11872 $as_echo_n "checking for freetype2... " >&6; }
11874 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
11875 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
11876 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
11877 edit_cflags="
11878 s,///*,/,g
11879 s/^/ /
11880 s/ -I/ $isystem/g
11881 s/^ //
11883 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
11884 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
11885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
11886 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
11887 succeeded=yes
11888 else
11889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11890 $as_echo "no" >&6; }
11891 FREETYPE_CFLAGS=""
11892 FREETYPE_LIBS=""
11893 ## If we have a custom action on failure, don't print errors, but
11894 ## do set a variable so people can do so.
11895 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
11901 else
11902 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11903 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11907 if test $succeeded = yes; then
11908 HAVE_FREETYPE=yes
11909 else
11910 HAVE_FREETYPE=no
11914 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
11917 HAVE_LIBOTF=no
11918 if test "${HAVE_FREETYPE}" = "yes"; then
11920 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
11922 if test "${with_libotf}" != "no"; then
11924 succeeded=no
11926 if test "$PKG_CONFIG" = "no" ; then
11927 HAVE_LIBOTF=no
11928 else
11929 PKG_CONFIG_MIN_VERSION=0.9.0
11930 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
11932 $as_echo_n "checking for libotf... " >&6; }
11934 if $PKG_CONFIG --exists "libotf" 2>&5 &&
11935 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
11936 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
11937 edit_cflags="
11938 s,///*,/,g
11939 s/^/ /
11940 s/ -I/ $isystem/g
11941 s/^ //
11943 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
11944 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
11945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
11946 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
11947 succeeded=yes
11948 else
11949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11950 $as_echo "no" >&6; }
11951 LIBOTF_CFLAGS=""
11952 LIBOTF_LIBS=""
11953 ## If we have a custom action on failure, don't print errors, but
11954 ## do set a variable so people can do so.
11955 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
11961 else
11962 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11963 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11967 if test $succeeded = yes; then
11968 HAVE_LIBOTF=yes
11969 else
11970 HAVE_LIBOTF=no
11973 if test "$HAVE_LIBOTF" = "yes"; then
11975 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
11977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
11978 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
11979 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
11980 $as_echo_n "(cached) " >&6
11981 else
11982 ac_check_lib_save_LIBS=$LIBS
11983 LIBS="-lotf $LIBS"
11984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11985 /* end confdefs.h. */
11987 /* Override any GCC internal prototype to avoid an error.
11988 Use char because int might match the return type of a GCC
11989 builtin and then its argument prototype would still apply. */
11990 #ifdef __cplusplus
11991 extern "C"
11992 #endif
11993 char OTF_get_variation_glyphs ();
11995 main ()
11997 return OTF_get_variation_glyphs ();
11999 return 0;
12001 _ACEOF
12002 if ac_fn_c_try_link "$LINENO"; then :
12003 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12004 else
12005 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12007 rm -f core conftest.err conftest.$ac_objext \
12008 conftest$ac_exeext conftest.$ac_ext
12009 LIBS=$ac_check_lib_save_LIBS
12011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12012 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12013 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12014 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12015 else
12016 HAVE_OTF_GET_VARIATION_GLYPHS=no
12019 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12021 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12028 HAVE_M17N_FLT=no
12029 if test "${HAVE_LIBOTF}" = yes; then
12030 if test "${with_m17n_flt}" != "no"; then
12032 succeeded=no
12034 if test "$PKG_CONFIG" = "no" ; then
12035 HAVE_M17N_FLT=no
12036 else
12037 PKG_CONFIG_MIN_VERSION=0.9.0
12038 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12040 $as_echo_n "checking for m17n-flt... " >&6; }
12042 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12043 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12044 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12045 edit_cflags="
12046 s,///*,/,g
12047 s/^/ /
12048 s/ -I/ $isystem/g
12049 s/^ //
12051 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12052 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12054 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12055 succeeded=yes
12056 else
12057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12058 $as_echo "no" >&6; }
12059 M17N_FLT_CFLAGS=""
12060 M17N_FLT_LIBS=""
12061 ## If we have a custom action on failure, don't print errors, but
12062 ## do set a variable so people can do so.
12063 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
12069 else
12070 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12071 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12075 if test $succeeded = yes; then
12076 HAVE_M17N_FLT=yes
12077 else
12078 HAVE_M17N_FLT=no
12081 if test "$HAVE_M17N_FLT" = "yes"; then
12083 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12088 else
12089 HAVE_XFT=no
12090 HAVE_FREETYPE=no
12091 HAVE_LIBOTF=no
12092 HAVE_M17N_FLT=no
12095 ### End of font-backend (under X11) section.
12106 ### Use -lXpm if available, unless `--with-xpm=no'.
12107 HAVE_XPM=no
12108 LIBXPM=
12109 if test "${HAVE_X11}" = "yes"; then
12110 if test "${with_xpm}" != "no"; then
12111 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12112 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12114 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12115 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12116 $as_echo_n "(cached) " >&6
12117 else
12118 ac_check_lib_save_LIBS=$LIBS
12119 LIBS="-lXpm -lX11 $LIBS"
12120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12121 /* end confdefs.h. */
12123 /* Override any GCC internal prototype to avoid an error.
12124 Use char because int might match the return type of a GCC
12125 builtin and then its argument prototype would still apply. */
12126 #ifdef __cplusplus
12127 extern "C"
12128 #endif
12129 char XpmReadFileToPixmap ();
12131 main ()
12133 return XpmReadFileToPixmap ();
12135 return 0;
12137 _ACEOF
12138 if ac_fn_c_try_link "$LINENO"; then :
12139 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12140 else
12141 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12143 rm -f core conftest.err conftest.$ac_objext \
12144 conftest$ac_exeext conftest.$ac_ext
12145 LIBS=$ac_check_lib_save_LIBS
12147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12148 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12149 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12150 HAVE_XPM=yes
12156 if test "${HAVE_XPM}" = "yes"; then
12157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12158 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12160 /* end confdefs.h. */
12161 #include "X11/xpm.h"
12162 #ifndef XpmReturnAllocPixels
12163 no_return_alloc_pixels
12164 #endif
12166 _ACEOF
12167 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12168 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12169 HAVE_XPM=no
12170 else
12171 HAVE_XPM=yes
12173 rm -f conftest*
12176 if test "${HAVE_XPM}" = "yes"; then
12177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12178 $as_echo "yes" >&6; }
12179 else
12180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12181 $as_echo "no" >&6; }
12186 if test "${HAVE_XPM}" = "yes"; then
12188 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12190 LIBXPM=-lXpm
12195 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12196 HAVE_JPEG=no
12197 LIBJPEG=
12198 if test "${HAVE_X11}" = "yes"; then
12199 if test "${with_jpeg}" != "no"; then
12200 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12201 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12203 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12204 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12205 $as_echo_n "(cached) " >&6
12206 else
12207 ac_check_lib_save_LIBS=$LIBS
12208 LIBS="-ljpeg $LIBS"
12209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12210 /* end confdefs.h. */
12212 /* Override any GCC internal prototype to avoid an error.
12213 Use char because int might match the return type of a GCC
12214 builtin and then its argument prototype would still apply. */
12215 #ifdef __cplusplus
12216 extern "C"
12217 #endif
12218 char jpeg_destroy_compress ();
12220 main ()
12222 return jpeg_destroy_compress ();
12224 return 0;
12226 _ACEOF
12227 if ac_fn_c_try_link "$LINENO"; then :
12228 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12229 else
12230 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12232 rm -f core conftest.err conftest.$ac_objext \
12233 conftest$ac_exeext conftest.$ac_ext
12234 LIBS=$ac_check_lib_save_LIBS
12236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12237 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12238 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12239 HAVE_JPEG=yes
12247 if test "${HAVE_JPEG}" = "yes"; then
12248 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12251 /* end confdefs.h. */
12252 #include <jpeglib.h>
12253 version=JPEG_LIB_VERSION
12255 _ACEOF
12256 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12257 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12258 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12260 else
12261 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12262 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12263 HAVE_JPEG=no
12265 rm -f conftest*
12268 if test "${HAVE_JPEG}" = "yes"; then
12269 LIBJPEG=-ljpeg
12274 ### Use -lpng if available, unless `--with-png=no'.
12275 HAVE_PNG=no
12276 LIBPNG=
12277 if test "${HAVE_X11}" = "yes"; then
12278 if test "${with_png}" != "no"; then
12279 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12280 # in /usr/include/libpng.
12281 for ac_header in png.h libpng/png.h
12282 do :
12283 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12284 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12285 eval as_val=\$$as_ac_Header
12286 if test "x$as_val" = x""yes; then :
12287 cat >>confdefs.h <<_ACEOF
12288 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12289 _ACEOF
12290 break
12293 done
12295 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12297 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12298 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12299 $as_echo_n "(cached) " >&6
12300 else
12301 ac_check_lib_save_LIBS=$LIBS
12302 LIBS="-lpng -lz -lm $LIBS"
12303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12304 /* end confdefs.h. */
12306 /* Override any GCC internal prototype to avoid an error.
12307 Use char because int might match the return type of a GCC
12308 builtin and then its argument prototype would still apply. */
12309 #ifdef __cplusplus
12310 extern "C"
12311 #endif
12312 char png_get_channels ();
12314 main ()
12316 return png_get_channels ();
12318 return 0;
12320 _ACEOF
12321 if ac_fn_c_try_link "$LINENO"; then :
12322 ac_cv_lib_png_png_get_channels=yes
12323 else
12324 ac_cv_lib_png_png_get_channels=no
12326 rm -f core conftest.err conftest.$ac_objext \
12327 conftest$ac_exeext conftest.$ac_ext
12328 LIBS=$ac_check_lib_save_LIBS
12330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12331 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12332 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12333 HAVE_PNG=yes
12339 if test "${HAVE_PNG}" = "yes"; then
12341 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12343 LIBPNG="-lpng -lz -lm"
12345 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12346 # include <libpng/png.h>
12347 #else
12348 # include <png.h>
12349 #endif
12352 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12354 else
12356 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12364 ### Use -ltiff if available, unless `--with-tiff=no'.
12365 HAVE_TIFF=no
12366 LIBTIFF=
12367 if test "${HAVE_X11}" = "yes"; then
12368 if test "${with_tiff}" != "no"; then
12369 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12370 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12371 tifflibs="-lz -lm"
12372 # At least one tiff package requires the jpeg library.
12373 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12375 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12376 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12377 $as_echo_n "(cached) " >&6
12378 else
12379 ac_check_lib_save_LIBS=$LIBS
12380 LIBS="-ltiff $tifflibs $LIBS"
12381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12382 /* end confdefs.h. */
12384 /* Override any GCC internal prototype to avoid an error.
12385 Use char because int might match the return type of a GCC
12386 builtin and then its argument prototype would still apply. */
12387 #ifdef __cplusplus
12388 extern "C"
12389 #endif
12390 char TIFFGetVersion ();
12392 main ()
12394 return TIFFGetVersion ();
12396 return 0;
12398 _ACEOF
12399 if ac_fn_c_try_link "$LINENO"; then :
12400 ac_cv_lib_tiff_TIFFGetVersion=yes
12401 else
12402 ac_cv_lib_tiff_TIFFGetVersion=no
12404 rm -f core conftest.err conftest.$ac_objext \
12405 conftest$ac_exeext conftest.$ac_ext
12406 LIBS=$ac_check_lib_save_LIBS
12408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12409 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12410 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12411 HAVE_TIFF=yes
12419 if test "${HAVE_TIFF}" = "yes"; then
12421 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12423 LIBTIFF=-ltiff
12428 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12429 HAVE_GIF=no
12430 LIBGIF=
12431 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12432 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12433 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12434 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12435 # Earlier versions can crash Emacs.
12436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12437 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12438 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12439 $as_echo_n "(cached) " >&6
12440 else
12441 ac_check_lib_save_LIBS=$LIBS
12442 LIBS="-lgif $LIBS"
12443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12444 /* end confdefs.h. */
12446 /* Override any GCC internal prototype to avoid an error.
12447 Use char because int might match the return type of a GCC
12448 builtin and then its argument prototype would still apply. */
12449 #ifdef __cplusplus
12450 extern "C"
12451 #endif
12452 char EGifPutExtensionLast ();
12454 main ()
12456 return EGifPutExtensionLast ();
12458 return 0;
12460 _ACEOF
12461 if ac_fn_c_try_link "$LINENO"; then :
12462 ac_cv_lib_gif_EGifPutExtensionLast=yes
12463 else
12464 ac_cv_lib_gif_EGifPutExtensionLast=no
12466 rm -f core conftest.err conftest.$ac_objext \
12467 conftest$ac_exeext conftest.$ac_ext
12468 LIBS=$ac_check_lib_save_LIBS
12470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12471 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12472 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12473 HAVE_GIF=yes
12474 else
12475 HAVE_GIF=maybe
12482 if test "$HAVE_GIF" = yes; then
12483 LIBGIF=-lgif
12484 elif test "$HAVE_GIF" = maybe; then
12485 # If gif_lib.h but no libgif, try libungif.
12486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12487 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12488 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12489 $as_echo_n "(cached) " >&6
12490 else
12491 ac_check_lib_save_LIBS=$LIBS
12492 LIBS="-lungif $LIBS"
12493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12494 /* end confdefs.h. */
12496 /* Override any GCC internal prototype to avoid an error.
12497 Use char because int might match the return type of a GCC
12498 builtin and then its argument prototype would still apply. */
12499 #ifdef __cplusplus
12500 extern "C"
12501 #endif
12502 char EGifPutExtensionLast ();
12504 main ()
12506 return EGifPutExtensionLast ();
12508 return 0;
12510 _ACEOF
12511 if ac_fn_c_try_link "$LINENO"; then :
12512 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12513 else
12514 ac_cv_lib_ungif_EGifPutExtensionLast=no
12516 rm -f core conftest.err conftest.$ac_objext \
12517 conftest$ac_exeext conftest.$ac_ext
12518 LIBS=$ac_check_lib_save_LIBS
12520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12521 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12522 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12523 HAVE_GIF=yes
12524 else
12525 HAVE_GIF=no
12528 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12531 if test "${HAVE_GIF}" = "yes"; then
12533 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12539 if test "${HAVE_X11}" = "yes"; then
12540 MISSING=""
12541 WITH_NO=""
12542 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12543 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12544 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12545 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12546 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12547 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12548 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12549 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12550 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12551 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12553 if test "X${MISSING}" != X; then
12554 as_fn_error "The following required libraries were not found:
12555 $MISSING
12556 Maybe some development libraries/packages are missing?
12557 If you don't want to link with them give
12558 $WITH_NO
12559 as options to configure" "$LINENO" 5
12563 ### Use -lgpm if available, unless `--with-gpm=no'.
12564 HAVE_GPM=no
12565 LIBGPM=
12566 if test "${with_gpm}" != "no"; then
12567 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12568 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12570 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12571 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12572 $as_echo_n "(cached) " >&6
12573 else
12574 ac_check_lib_save_LIBS=$LIBS
12575 LIBS="-lgpm $LIBS"
12576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12577 /* end confdefs.h. */
12579 /* Override any GCC internal prototype to avoid an error.
12580 Use char because int might match the return type of a GCC
12581 builtin and then its argument prototype would still apply. */
12582 #ifdef __cplusplus
12583 extern "C"
12584 #endif
12585 char Gpm_Open ();
12587 main ()
12589 return Gpm_Open ();
12591 return 0;
12593 _ACEOF
12594 if ac_fn_c_try_link "$LINENO"; then :
12595 ac_cv_lib_gpm_Gpm_Open=yes
12596 else
12597 ac_cv_lib_gpm_Gpm_Open=no
12599 rm -f core conftest.err conftest.$ac_objext \
12600 conftest$ac_exeext conftest.$ac_ext
12601 LIBS=$ac_check_lib_save_LIBS
12603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12604 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12605 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12606 HAVE_GPM=yes
12613 if test "${HAVE_GPM}" = "yes"; then
12615 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12617 LIBGPM=-lgpm
12626 GNUSTEP_CFLAGS=
12627 ### Use NeXTstep API to implement GUI.
12628 if test "${HAVE_NS}" = "yes"; then
12630 $as_echo "#define HAVE_NS 1" >>confdefs.h
12632 if test "${NS_IMPL_COCOA}" = "yes"; then
12634 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12637 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12639 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12641 # See also .m.o rule in Makefile.in */
12642 # FIXME: are all these flags really needed? Document here why. */
12643 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12644 ## Extra CFLAGS applied to src/*.m files.
12645 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"
12647 # We also have mouse menus.
12648 HAVE_MENUS=yes
12649 OTHER_FILES=ns-app
12653 ### Use session management (-lSM -lICE) if available
12654 HAVE_X_SM=no
12655 LIBXSM=
12656 if test "${HAVE_X11}" = "yes"; then
12657 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12658 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12660 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12661 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12662 $as_echo_n "(cached) " >&6
12663 else
12664 ac_check_lib_save_LIBS=$LIBS
12665 LIBS="-lSM -lICE $LIBS"
12666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12667 /* end confdefs.h. */
12669 /* Override any GCC internal prototype to avoid an error.
12670 Use char because int might match the return type of a GCC
12671 builtin and then its argument prototype would still apply. */
12672 #ifdef __cplusplus
12673 extern "C"
12674 #endif
12675 char SmcOpenConnection ();
12677 main ()
12679 return SmcOpenConnection ();
12681 return 0;
12683 _ACEOF
12684 if ac_fn_c_try_link "$LINENO"; then :
12685 ac_cv_lib_SM_SmcOpenConnection=yes
12686 else
12687 ac_cv_lib_SM_SmcOpenConnection=no
12689 rm -f core conftest.err conftest.$ac_objext \
12690 conftest$ac_exeext conftest.$ac_ext
12691 LIBS=$ac_check_lib_save_LIBS
12693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
12694 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
12695 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
12696 HAVE_X_SM=yes
12703 if test "${HAVE_X_SM}" = "yes"; then
12705 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
12707 LIBXSM="-lSM -lICE"
12708 case "$LIBS" in
12709 *-lSM*) ;;
12710 *) LIBS="$LIBXSM $LIBS" ;;
12711 esac
12716 ### Use libxml (-lxml2) if available
12717 HAVE_LIBXML2=no
12718 if test "${with_xml2}" != "no"; then
12719 ### I'm not sure what the version number should be, so I just guessed.
12721 succeeded=no
12723 if test "$PKG_CONFIG" = "no" ; then
12724 HAVE_LIBXML2=no
12725 else
12726 PKG_CONFIG_MIN_VERSION=0.9.0
12727 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
12729 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
12731 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
12732 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
12733 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
12734 edit_cflags="
12735 s,///*,/,g
12736 s/^/ /
12737 s/ -I/ $isystem/g
12738 s/^ //
12740 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
12741 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
12742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
12743 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
12744 succeeded=yes
12745 else
12746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12747 $as_echo "no" >&6; }
12748 LIBXML2_CFLAGS=""
12749 LIBXML2_LIBS=""
12750 ## If we have a custom action on failure, don't print errors, but
12751 ## do set a variable so people can do so.
12752 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
12758 else
12759 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12760 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12764 if test $succeeded = yes; then
12765 HAVE_LIBXML2=yes
12766 else
12767 HAVE_LIBXML2=no
12770 if test "${HAVE_LIBXML2}" = "yes"; then
12771 LIBS="$LIBXML2_LIBS $LIBS"
12772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
12773 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
12774 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
12775 $as_echo_n "(cached) " >&6
12776 else
12777 ac_check_lib_save_LIBS=$LIBS
12778 LIBS="-lxml2 $LIBS"
12779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12780 /* end confdefs.h. */
12782 /* Override any GCC internal prototype to avoid an error.
12783 Use char because int might match the return type of a GCC
12784 builtin and then its argument prototype would still apply. */
12785 #ifdef __cplusplus
12786 extern "C"
12787 #endif
12788 char htmlReadMemory ();
12790 main ()
12792 return htmlReadMemory ();
12794 return 0;
12796 _ACEOF
12797 if ac_fn_c_try_link "$LINENO"; then :
12798 ac_cv_lib_xml2_htmlReadMemory=yes
12799 else
12800 ac_cv_lib_xml2_htmlReadMemory=no
12802 rm -f core conftest.err conftest.$ac_objext \
12803 conftest$ac_exeext conftest.$ac_ext
12804 LIBS=$ac_check_lib_save_LIBS
12806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
12807 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
12808 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
12809 HAVE_LIBXML2=yes
12810 else
12811 HAVE_LIBXML2=no
12814 if test "${HAVE_LIBXML2}" = "yes"; then
12816 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
12818 else
12819 LIBXML2_LIBS=""
12820 LIBXML2_CFLAGS=""
12827 # If netdb.h doesn't declare h_errno, we must declare it by hand.
12828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
12829 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
12830 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
12831 $as_echo_n "(cached) " >&6
12832 else
12833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12834 /* end confdefs.h. */
12835 #include <netdb.h>
12837 main ()
12839 return h_errno;
12841 return 0;
12843 _ACEOF
12844 if ac_fn_c_try_link "$LINENO"; then :
12845 emacs_cv_netdb_declares_h_errno=yes
12846 else
12847 emacs_cv_netdb_declares_h_errno=no
12849 rm -f core conftest.err conftest.$ac_objext \
12850 conftest$ac_exeext conftest.$ac_ext
12852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
12853 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
12854 if test $emacs_cv_netdb_declares_h_errno = yes; then
12856 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
12860 # fmod, logb, and frexp are found in -lm on most systems.
12861 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
12863 $as_echo_n "checking for sqrt in -lm... " >&6; }
12864 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
12865 $as_echo_n "(cached) " >&6
12866 else
12867 ac_check_lib_save_LIBS=$LIBS
12868 LIBS="-lm $LIBS"
12869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12870 /* end confdefs.h. */
12872 /* Override any GCC internal prototype to avoid an error.
12873 Use char because int might match the return type of a GCC
12874 builtin and then its argument prototype would still apply. */
12875 #ifdef __cplusplus
12876 extern "C"
12877 #endif
12878 char sqrt ();
12880 main ()
12882 return sqrt ();
12884 return 0;
12886 _ACEOF
12887 if ac_fn_c_try_link "$LINENO"; then :
12888 ac_cv_lib_m_sqrt=yes
12889 else
12890 ac_cv_lib_m_sqrt=no
12892 rm -f core conftest.err conftest.$ac_objext \
12893 conftest$ac_exeext conftest.$ac_ext
12894 LIBS=$ac_check_lib_save_LIBS
12896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
12897 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
12898 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
12899 cat >>confdefs.h <<_ACEOF
12900 #define HAVE_LIBM 1
12901 _ACEOF
12903 LIBS="-lm $LIBS"
12908 # Check for mail-locking functions in a "mail" library. Probably this should
12909 # have the same check as for liblockfile below.
12910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
12911 $as_echo_n "checking for maillock in -lmail... " >&6; }
12912 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
12913 $as_echo_n "(cached) " >&6
12914 else
12915 ac_check_lib_save_LIBS=$LIBS
12916 LIBS="-lmail $LIBS"
12917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12918 /* end confdefs.h. */
12920 /* Override any GCC internal prototype to avoid an error.
12921 Use char because int might match the return type of a GCC
12922 builtin and then its argument prototype would still apply. */
12923 #ifdef __cplusplus
12924 extern "C"
12925 #endif
12926 char maillock ();
12928 main ()
12930 return maillock ();
12932 return 0;
12934 _ACEOF
12935 if ac_fn_c_try_link "$LINENO"; then :
12936 ac_cv_lib_mail_maillock=yes
12937 else
12938 ac_cv_lib_mail_maillock=no
12940 rm -f core conftest.err conftest.$ac_objext \
12941 conftest$ac_exeext conftest.$ac_ext
12942 LIBS=$ac_check_lib_save_LIBS
12944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
12945 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
12946 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
12947 have_mail=yes
12948 else
12949 have_mail=no
12952 if test $have_mail = yes; then
12953 LIBS_MAIL=-lmail
12954 LIBS="$LIBS_MAIL $LIBS"
12956 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
12958 else
12959 LIBS_MAIL=
12961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
12962 $as_echo_n "checking for maillock in -llockfile... " >&6; }
12963 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
12964 $as_echo_n "(cached) " >&6
12965 else
12966 ac_check_lib_save_LIBS=$LIBS
12967 LIBS="-llockfile $LIBS"
12968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12969 /* end confdefs.h. */
12971 /* Override any GCC internal prototype to avoid an error.
12972 Use char because int might match the return type of a GCC
12973 builtin and then its argument prototype would still apply. */
12974 #ifdef __cplusplus
12975 extern "C"
12976 #endif
12977 char maillock ();
12979 main ()
12981 return maillock ();
12983 return 0;
12985 _ACEOF
12986 if ac_fn_c_try_link "$LINENO"; then :
12987 ac_cv_lib_lockfile_maillock=yes
12988 else
12989 ac_cv_lib_lockfile_maillock=no
12991 rm -f core conftest.err conftest.$ac_objext \
12992 conftest$ac_exeext conftest.$ac_ext
12993 LIBS=$ac_check_lib_save_LIBS
12995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
12996 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
12997 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
12998 have_lockfile=yes
12999 else
13000 have_lockfile=no
13003 if test $have_lockfile = yes; then
13004 LIBS_MAIL=-llockfile
13005 LIBS="$LIBS_MAIL $LIBS"
13007 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13009 else
13010 # If we have the shared liblockfile, assume we must use it for mail
13011 # locking (e.g. Debian). If we couldn't link against liblockfile
13012 # (no liblockfile.a installed), ensure that we don't need to.
13013 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13014 set dummy liblockfile.so; ac_word=$2
13015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13016 $as_echo_n "checking for $ac_word... " >&6; }
13017 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13018 $as_echo_n "(cached) " >&6
13019 else
13020 if test -n "$liblockfile"; then
13021 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13022 else
13023 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13024 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13025 for as_dir in $as_dummy
13027 IFS=$as_save_IFS
13028 test -z "$as_dir" && as_dir=.
13029 for ac_exec_ext in '' $ac_executable_extensions; do
13030 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13031 ac_cv_prog_liblockfile="yes"
13032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13033 break 2
13035 done
13036 done
13037 IFS=$as_save_IFS
13039 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13042 liblockfile=$ac_cv_prog_liblockfile
13043 if test -n "$liblockfile"; then
13044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13045 $as_echo "$liblockfile" >&6; }
13046 else
13047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13048 $as_echo "no" >&6; }
13052 if test $ac_cv_prog_liblockfile = yes; then
13053 as_fn_error "Shared liblockfile found but can't link against it.
13054 This probably means that movemail could lose mail.
13055 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13063 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13064 ## interlock access to the mail spool. The alternative is a lock file named
13065 ## /usr/spool/mail/$USER.lock.
13066 mail_lock=no
13067 case "$opsys" in
13068 aix4-2) mail_lock="lockf" ;;
13070 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13072 ## On GNU/Linux systems, both methods are used by various mail programs.
13073 ## I assume most people are using newer mailers that have heard of flock.
13074 ## Change this if you need to.
13075 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13076 ## configure gets the right answers, and that means *NOT* using flock.
13077 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13078 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13079 ## Debian maintainer hasn't provided a clean fix for Emacs.
13080 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13081 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13082 ## correct logic. -- fx
13083 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13084 ## liblockfile is a Free Software replacement for libmail, used on
13085 ## Debian systems and elsewhere. -rfr.
13086 gnu-*)
13087 mail_lock="flock"
13088 if test $have_mail = yes || test $have_lockfile = yes; then
13089 test $ac_cv_header_maillock_h = yes && mail_lock=no
13092 esac
13094 BLESSMAIL_TARGET=
13095 case "$mail_lock" in
13096 flock)
13097 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13100 lockf)
13101 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13104 *) BLESSMAIL_TARGET="need-blessmail" ;;
13105 esac
13109 for ac_func in gethostname \
13110 closedir getrusage get_current_dir_name \
13111 lrand48 logb frexp fmod cbrt setsid \
13112 fpathconf select euidaccess getpagesize setlocale \
13113 utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
13114 __fpending strsignal setitimer \
13115 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13116 gai_strerror mkstemp getline getdelim fsync sync \
13117 difftime posix_memalign \
13118 getpwent endpwent getgrent endgrent \
13119 touchlock \
13120 cfmakeraw cfsetspeed copysign __executable_start
13121 do :
13122 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13123 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13124 eval as_val=\$$as_ac_var
13125 if test "x$as_val" = x""yes; then :
13126 cat >>confdefs.h <<_ACEOF
13127 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13128 _ACEOF
13131 done
13134 if test $opsys = unixware; then
13136 $as_echo "#define BROKEN_GETWD 1" >>confdefs.h
13138 else
13139 for ac_func in getwd
13140 do :
13141 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13142 if test "x$ac_cv_func_getwd" = x""yes; then :
13143 cat >>confdefs.h <<_ACEOF
13144 #define HAVE_GETWD 1
13145 _ACEOF
13148 done
13152 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13153 ## has a broken `rint' in some library versions including math library
13154 ## version number A.09.05.
13155 ## You can fix the math library by installing patch number PHSS_4630.
13156 ## But we can fix it more reliably for Emacs by just not using rint.
13157 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13158 case $opsys in
13159 hpux*) : ;;
13160 *) for ac_func in random rint
13161 do :
13162 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13163 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13164 eval as_val=\$$as_ac_var
13165 if test "x$as_val" = x""yes; then :
13166 cat >>confdefs.h <<_ACEOF
13167 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13168 _ACEOF
13171 done
13173 esac
13175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13176 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13177 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13178 $as_echo_n "(cached) " >&6
13179 else
13180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13181 /* end confdefs.h. */
13184 main ()
13186 __builtin_unwind_init ();
13188 return 0;
13190 _ACEOF
13191 if ac_fn_c_try_link "$LINENO"; then :
13192 emacs_cv_func___builtin_unwind_init=yes
13193 else
13194 emacs_cv_func___builtin_unwind_init=no
13196 rm -f core conftest.err conftest.$ac_objext \
13197 conftest$ac_exeext conftest.$ac_ext
13199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13200 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13201 if test $emacs_cv_func___builtin_unwind_init = yes; then
13203 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13212 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13213 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13214 $as_echo_n "(cached) " >&6
13215 else
13216 while :; do
13217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13218 /* end confdefs.h. */
13219 #include <sys/types.h> /* for off_t */
13220 #include <stdio.h>
13222 main ()
13224 int (*fp) (FILE *, off_t, int) = fseeko;
13225 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13227 return 0;
13229 _ACEOF
13230 if ac_fn_c_try_link "$LINENO"; then :
13231 ac_cv_sys_largefile_source=no; break
13233 rm -f core conftest.err conftest.$ac_objext \
13234 conftest$ac_exeext conftest.$ac_ext
13235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13236 /* end confdefs.h. */
13237 #define _LARGEFILE_SOURCE 1
13238 #include <sys/types.h> /* for off_t */
13239 #include <stdio.h>
13241 main ()
13243 int (*fp) (FILE *, off_t, int) = fseeko;
13244 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13246 return 0;
13248 _ACEOF
13249 if ac_fn_c_try_link "$LINENO"; then :
13250 ac_cv_sys_largefile_source=1; break
13252 rm -f core conftest.err conftest.$ac_objext \
13253 conftest$ac_exeext conftest.$ac_ext
13254 ac_cv_sys_largefile_source=unknown
13255 break
13256 done
13258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13259 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13260 case $ac_cv_sys_largefile_source in #(
13261 no | unknown) ;;
13263 cat >>confdefs.h <<_ACEOF
13264 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13265 _ACEOF
13267 esac
13268 rm -rf conftest*
13270 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13271 # in glibc 2.1.3, but that breaks too many other things.
13272 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13273 if test $ac_cv_sys_largefile_source != unknown; then
13275 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13281 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13282 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13283 $as_echo_n "(cached) " >&6
13284 else
13285 # Use it with a single arg.
13286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13287 /* end confdefs.h. */
13288 $ac_includes_default
13290 main ()
13292 getpgrp (0);
13294 return 0;
13296 _ACEOF
13297 if ac_fn_c_try_compile "$LINENO"; then :
13298 ac_cv_func_getpgrp_void=no
13299 else
13300 ac_cv_func_getpgrp_void=yes
13302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13306 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13307 if test $ac_cv_func_getpgrp_void = yes; then
13309 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13314 # UNIX98 PTYs.
13315 for ac_func in grantpt
13316 do :
13317 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13318 if test "x$ac_cv_func_grantpt" = x""yes; then :
13319 cat >>confdefs.h <<_ACEOF
13320 #define HAVE_GRANTPT 1
13321 _ACEOF
13324 done
13327 # PTY-related GNU extensions.
13328 for ac_func in getpt posix_openpt
13329 do :
13330 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13331 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13332 eval as_val=\$$as_ac_var
13333 if test "x$as_val" = x""yes; then :
13334 cat >>confdefs.h <<_ACEOF
13335 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13336 _ACEOF
13339 done
13342 # Check this now, so that we will NOT find the above functions in ncurses.
13343 # That is because we have not set up to link ncurses in lib-src.
13344 # It's better to believe a function is not available
13345 # than to expect to find it in ncurses.
13346 # Also we need tputs and friends to be able to build at all.
13347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13348 $as_echo_n "checking for library containing tputs... " >&6; }
13349 # Run a test program that contains a call to tputs, a call that is
13350 # never executed. This tests whether a pre-'main' dynamic linker
13351 # works with the library. It's too much trouble to actually call
13352 # tputs in the test program, due to portability hassles. When
13353 # cross-compiling, assume the test program will run if it links.
13355 # Maybe curses should be tried earlier?
13356 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13357 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13358 OLIBS=$LIBS
13359 if test -z "$tputs_library"; then
13360 LIBS_TERMCAP=
13361 msg='none required'
13362 else
13363 LIBS_TERMCAP=-l$tputs_library
13364 msg=$LIBS_TERMCAP
13365 LIBS="$LIBS_TERMCAP $LIBS"
13367 if test "$cross_compiling" = yes; then :
13368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13369 /* end confdefs.h. */
13371 extern void tputs (const char *, int, int (*)(int));
13372 int main (int argc, char **argv)
13374 if (argc == 10000)
13375 tputs (argv[0], 0, 0);
13376 return 0;
13379 _ACEOF
13380 if ac_fn_c_try_link "$LINENO"; then :
13382 else
13383 msg=no
13385 rm -f core conftest.err conftest.$ac_objext \
13386 conftest$ac_exeext conftest.$ac_ext
13387 else
13388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13389 /* end confdefs.h. */
13391 extern void tputs (const char *, int, int (*)(int));
13392 int main (int argc, char **argv)
13394 if (argc == 10000)
13395 tputs (argv[0], 0, 0);
13396 return 0;
13399 _ACEOF
13400 if ac_fn_c_try_run "$LINENO"; then :
13402 else
13403 msg=no
13405 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13406 conftest.$ac_objext conftest.beam conftest.$ac_ext
13409 LIBS=$OLIBS
13410 if test "X$msg" != Xno; then
13411 break
13413 done
13414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13415 $as_echo "$msg" >&6; }
13416 if test "X$msg" = Xno; then
13417 as_fn_error "The required function \`tputs' was not found in any library.
13418 The following libraries were tried (in order):
13419 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13420 Please try installing whichever of these libraries is most appropriate
13421 for your system, together with its header files.
13422 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13425 ## Use termcap instead of terminfo?
13426 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13427 TERMINFO=yes
13428 ## FIXME? In the cases below where we unconditionally set
13429 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13430 ## if that was found above to have tputs.
13431 ## Should we use the gnu* logic everywhere?
13432 case "$opsys" in
13433 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13434 ## The ncurses library has been moved out of the System framework in
13435 ## Mac OS X 10.2. So if configure detects it, set the command-line
13436 ## option to use it.
13437 darwin) LIBS_TERMCAP="-lncurses" ;;
13439 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13441 freebsd)
13442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13443 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13444 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13445 $as_echo_n "(cached) " >&6
13446 else
13447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13448 /* end confdefs.h. */
13449 #include <osreldate.h>
13451 main ()
13453 #if __FreeBSD_version < 400000
13454 fail;
13455 #endif
13458 return 0;
13460 _ACEOF
13461 if ac_fn_c_try_link "$LINENO"; then :
13462 emacs_cv_freebsd_terminfo=yes
13463 else
13464 emacs_cv_freebsd_terminfo=no
13466 rm -f core conftest.err conftest.$ac_objext \
13467 conftest$ac_exeext conftest.$ac_ext
13471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13472 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13474 if test $emacs_cv_freebsd_terminfo = yes; then
13475 LIBS_TERMCAP="-lncurses"
13476 else
13477 TERMINFO=no
13478 LIBS_TERMCAP="-ltermcap"
13482 netbsd)
13483 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13484 TERMINFO=no
13485 LIBS_TERMCAP="-ltermcap"
13489 openbsd) LIBS_TERMCAP="-lncurses" ;;
13491 ## hpux: Make sure we get select from libc rather than from libcurses
13492 ## because libcurses on HPUX 10.10 has a broken version of select.
13493 ## We used to use -lc -lcurses, but this may be cleaner.
13494 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13495 # set that way, now it uses the default). Isn't this a contradiction?
13496 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13498 esac
13500 TERMCAP_OBJ=tparam.o
13501 if test $TERMINFO = yes; then
13503 $as_echo "#define TERMINFO 1" >>confdefs.h
13505 TERMCAP_OBJ=terminfo.o
13511 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13512 # On Darwin, res_init appears not to be useful: see bug#562 and
13513 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13514 resolv=no
13516 if test $opsys != darwin; then
13518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13519 /* end confdefs.h. */
13520 #include <netinet/in.h>
13521 #include <arpa/nameser.h>
13522 #include <resolv.h>
13524 main ()
13526 return res_init();
13528 return 0;
13530 _ACEOF
13531 if ac_fn_c_try_link "$LINENO"; then :
13532 have_res_init=yes
13533 else
13534 have_res_init=no
13536 rm -f core conftest.err conftest.$ac_objext \
13537 conftest$ac_exeext conftest.$ac_ext
13538 if test "$have_res_init" = no; then
13539 OLIBS="$LIBS"
13540 LIBS="$LIBS -lresolv"
13541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13542 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13544 /* end confdefs.h. */
13545 #include <netinet/in.h>
13546 #include <arpa/nameser.h>
13547 #include <resolv.h>
13549 main ()
13551 return res_init();
13553 return 0;
13555 _ACEOF
13556 if ac_fn_c_try_link "$LINENO"; then :
13557 have_res_init=yes
13558 else
13559 have_res_init=no
13561 rm -f core conftest.err conftest.$ac_objext \
13562 conftest$ac_exeext conftest.$ac_ext
13563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13564 $as_echo "$have_res_init" >&6; }
13565 if test "$have_res_init" = yes ; then
13566 resolv=yes
13568 LIBS="$OLIBS"
13571 if test "$have_res_init" = yes; then
13573 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13577 # Do we need the Hesiod library to provide the support routines?
13578 LIBHESIOD=
13579 if test "$with_hesiod" != no ; then
13580 # Don't set $LIBS here -- see comments above. FIXME which comments?
13581 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13582 if test "x$ac_cv_func_res_send" = x""yes; then :
13584 else
13585 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13586 if test "x$ac_cv_func___res_send" = x""yes; then :
13588 else
13589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13590 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13591 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13592 $as_echo_n "(cached) " >&6
13593 else
13594 ac_check_lib_save_LIBS=$LIBS
13595 LIBS="-lresolv $LIBS"
13596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13597 /* end confdefs.h. */
13599 /* Override any GCC internal prototype to avoid an error.
13600 Use char because int might match the return type of a GCC
13601 builtin and then its argument prototype would still apply. */
13602 #ifdef __cplusplus
13603 extern "C"
13604 #endif
13605 char res_send ();
13607 main ()
13609 return res_send ();
13611 return 0;
13613 _ACEOF
13614 if ac_fn_c_try_link "$LINENO"; then :
13615 ac_cv_lib_resolv_res_send=yes
13616 else
13617 ac_cv_lib_resolv_res_send=no
13619 rm -f core conftest.err conftest.$ac_objext \
13620 conftest$ac_exeext conftest.$ac_ext
13621 LIBS=$ac_check_lib_save_LIBS
13623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13624 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13625 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13626 resolv=yes
13627 else
13628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13629 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13630 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13631 $as_echo_n "(cached) " >&6
13632 else
13633 ac_check_lib_save_LIBS=$LIBS
13634 LIBS="-lresolv $LIBS"
13635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13636 /* end confdefs.h. */
13638 /* Override any GCC internal prototype to avoid an error.
13639 Use char because int might match the return type of a GCC
13640 builtin and then its argument prototype would still apply. */
13641 #ifdef __cplusplus
13642 extern "C"
13643 #endif
13644 char __res_send ();
13646 main ()
13648 return __res_send ();
13650 return 0;
13652 _ACEOF
13653 if ac_fn_c_try_link "$LINENO"; then :
13654 ac_cv_lib_resolv___res_send=yes
13655 else
13656 ac_cv_lib_resolv___res_send=no
13658 rm -f core conftest.err conftest.$ac_objext \
13659 conftest$ac_exeext conftest.$ac_ext
13660 LIBS=$ac_check_lib_save_LIBS
13662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13663 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13664 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13665 resolv=yes
13674 if test "$resolv" = yes ; then
13675 RESOLVLIB=-lresolv
13676 else
13677 RESOLVLIB=
13679 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13680 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13682 else
13683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13684 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13685 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13686 $as_echo_n "(cached) " >&6
13687 else
13688 ac_check_lib_save_LIBS=$LIBS
13689 LIBS="-lhesiod $RESOLVLIB $LIBS"
13690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13691 /* end confdefs.h. */
13693 /* Override any GCC internal prototype to avoid an error.
13694 Use char because int might match the return type of a GCC
13695 builtin and then its argument prototype would still apply. */
13696 #ifdef __cplusplus
13697 extern "C"
13698 #endif
13699 char hes_getmailhost ();
13701 main ()
13703 return hes_getmailhost ();
13705 return 0;
13707 _ACEOF
13708 if ac_fn_c_try_link "$LINENO"; then :
13709 ac_cv_lib_hesiod_hes_getmailhost=yes
13710 else
13711 ac_cv_lib_hesiod_hes_getmailhost=no
13713 rm -f core conftest.err conftest.$ac_objext \
13714 conftest$ac_exeext conftest.$ac_ext
13715 LIBS=$ac_check_lib_save_LIBS
13717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
13718 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
13719 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
13720 hesiod=yes
13721 else
13728 if test x"$hesiod" = xyes; then
13730 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
13732 LIBHESIOD=-lhesiod
13737 # Do we need libresolv (due to res_init or Hesiod)?
13738 if test "$resolv" = yes && test $opsys != darwin; then
13740 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
13742 LIBRESOLV=-lresolv
13743 else
13744 LIBRESOLV=
13748 # These tell us which Kerberos-related libraries to use.
13749 COM_ERRLIB=
13750 CRYPTOLIB=
13751 KRB5LIB=
13752 DESLIB=
13753 KRB4LIB=
13755 if test "${with_kerberos}" != no; then
13756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
13757 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
13758 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
13759 $as_echo_n "(cached) " >&6
13760 else
13761 ac_check_lib_save_LIBS=$LIBS
13762 LIBS="-lcom_err $LIBS"
13763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13764 /* end confdefs.h. */
13766 /* Override any GCC internal prototype to avoid an error.
13767 Use char because int might match the return type of a GCC
13768 builtin and then its argument prototype would still apply. */
13769 #ifdef __cplusplus
13770 extern "C"
13771 #endif
13772 char com_err ();
13774 main ()
13776 return com_err ();
13778 return 0;
13780 _ACEOF
13781 if ac_fn_c_try_link "$LINENO"; then :
13782 ac_cv_lib_com_err_com_err=yes
13783 else
13784 ac_cv_lib_com_err_com_err=no
13786 rm -f core conftest.err conftest.$ac_objext \
13787 conftest$ac_exeext conftest.$ac_ext
13788 LIBS=$ac_check_lib_save_LIBS
13790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
13791 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
13792 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
13793 have_com_err=yes
13794 else
13795 have_com_err=no
13798 if test $have_com_err = yes; then
13799 COM_ERRLIB=-lcom_err
13800 LIBS="$COM_ERRLIB $LIBS"
13802 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
13805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
13806 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
13807 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
13808 $as_echo_n "(cached) " >&6
13809 else
13810 ac_check_lib_save_LIBS=$LIBS
13811 LIBS="-lcrypto $LIBS"
13812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13813 /* end confdefs.h. */
13815 /* Override any GCC internal prototype to avoid an error.
13816 Use char because int might match the return type of a GCC
13817 builtin and then its argument prototype would still apply. */
13818 #ifdef __cplusplus
13819 extern "C"
13820 #endif
13821 char mit_des_cbc_encrypt ();
13823 main ()
13825 return mit_des_cbc_encrypt ();
13827 return 0;
13829 _ACEOF
13830 if ac_fn_c_try_link "$LINENO"; then :
13831 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
13832 else
13833 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
13835 rm -f core conftest.err conftest.$ac_objext \
13836 conftest$ac_exeext conftest.$ac_ext
13837 LIBS=$ac_check_lib_save_LIBS
13839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
13840 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
13841 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
13842 have_crypto=yes
13843 else
13844 have_crypto=no
13847 if test $have_crypto = yes; then
13848 CRYPTOLIB=-lcrypto
13849 LIBS="$CRYPTOLIB $LIBS"
13851 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
13854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
13855 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
13856 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
13857 $as_echo_n "(cached) " >&6
13858 else
13859 ac_check_lib_save_LIBS=$LIBS
13860 LIBS="-lk5crypto $LIBS"
13861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13862 /* end confdefs.h. */
13864 /* Override any GCC internal prototype to avoid an error.
13865 Use char because int might match the return type of a GCC
13866 builtin and then its argument prototype would still apply. */
13867 #ifdef __cplusplus
13868 extern "C"
13869 #endif
13870 char mit_des_cbc_encrypt ();
13872 main ()
13874 return mit_des_cbc_encrypt ();
13876 return 0;
13878 _ACEOF
13879 if ac_fn_c_try_link "$LINENO"; then :
13880 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
13881 else
13882 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
13884 rm -f core conftest.err conftest.$ac_objext \
13885 conftest$ac_exeext conftest.$ac_ext
13886 LIBS=$ac_check_lib_save_LIBS
13888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
13889 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
13890 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
13891 have_k5crypto=yes
13892 else
13893 have_k5crypto=no
13896 if test $have_k5crypto = yes; then
13897 CRYPTOLIB=-lk5crypto
13898 LIBS="$CRYPTOLIB $LIBS"
13900 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
13903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
13904 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
13905 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
13906 $as_echo_n "(cached) " >&6
13907 else
13908 ac_check_lib_save_LIBS=$LIBS
13909 LIBS="-lkrb5 $LIBS"
13910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13911 /* end confdefs.h. */
13913 /* Override any GCC internal prototype to avoid an error.
13914 Use char because int might match the return type of a GCC
13915 builtin and then its argument prototype would still apply. */
13916 #ifdef __cplusplus
13917 extern "C"
13918 #endif
13919 char krb5_init_context ();
13921 main ()
13923 return krb5_init_context ();
13925 return 0;
13927 _ACEOF
13928 if ac_fn_c_try_link "$LINENO"; then :
13929 ac_cv_lib_krb5_krb5_init_context=yes
13930 else
13931 ac_cv_lib_krb5_krb5_init_context=no
13933 rm -f core conftest.err conftest.$ac_objext \
13934 conftest$ac_exeext conftest.$ac_ext
13935 LIBS=$ac_check_lib_save_LIBS
13937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
13938 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
13939 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
13940 have_krb5=yes
13941 else
13942 have_krb5=no
13945 if test $have_krb5=yes; then
13946 KRB5LIB=-lkrb5
13947 LIBS="$KRB5LIB $LIBS"
13949 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
13952 if test "${with_kerberos5}" = no; then
13953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
13954 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
13955 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
13956 $as_echo_n "(cached) " >&6
13957 else
13958 ac_check_lib_save_LIBS=$LIBS
13959 LIBS="-ldes425 $LIBS"
13960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13961 /* end confdefs.h. */
13963 /* Override any GCC internal prototype to avoid an error.
13964 Use char because int might match the return type of a GCC
13965 builtin and then its argument prototype would still apply. */
13966 #ifdef __cplusplus
13967 extern "C"
13968 #endif
13969 char des_cbc_encrypt ();
13971 main ()
13973 return des_cbc_encrypt ();
13975 return 0;
13977 _ACEOF
13978 if ac_fn_c_try_link "$LINENO"; then :
13979 ac_cv_lib_des425_des_cbc_encrypt=yes
13980 else
13981 ac_cv_lib_des425_des_cbc_encrypt=no
13983 rm -f core conftest.err conftest.$ac_objext \
13984 conftest$ac_exeext conftest.$ac_ext
13985 LIBS=$ac_check_lib_save_LIBS
13987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
13988 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
13989 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
13990 have_des425=yes
13991 else
13992 have_des425=no
13995 if test $have_des425 = yes; then
13996 DESLIB=-ldes425
13997 LIBS="$DESLIB $LIBS"
13999 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14001 else
14002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14003 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14004 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14005 $as_echo_n "(cached) " >&6
14006 else
14007 ac_check_lib_save_LIBS=$LIBS
14008 LIBS="-ldes $LIBS"
14009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14010 /* end confdefs.h. */
14012 /* Override any GCC internal prototype to avoid an error.
14013 Use char because int might match the return type of a GCC
14014 builtin and then its argument prototype would still apply. */
14015 #ifdef __cplusplus
14016 extern "C"
14017 #endif
14018 char des_cbc_encrypt ();
14020 main ()
14022 return des_cbc_encrypt ();
14024 return 0;
14026 _ACEOF
14027 if ac_fn_c_try_link "$LINENO"; then :
14028 ac_cv_lib_des_des_cbc_encrypt=yes
14029 else
14030 ac_cv_lib_des_des_cbc_encrypt=no
14032 rm -f core conftest.err conftest.$ac_objext \
14033 conftest$ac_exeext conftest.$ac_ext
14034 LIBS=$ac_check_lib_save_LIBS
14036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14037 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14038 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14039 have_des=yes
14040 else
14041 have_des=no
14044 if test $have_des = yes; then
14045 DESLIB=-ldes
14046 LIBS="$DESLIB $LIBS"
14048 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14053 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14054 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14055 $as_echo_n "(cached) " >&6
14056 else
14057 ac_check_lib_save_LIBS=$LIBS
14058 LIBS="-lkrb4 $LIBS"
14059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14060 /* end confdefs.h. */
14062 /* Override any GCC internal prototype to avoid an error.
14063 Use char because int might match the return type of a GCC
14064 builtin and then its argument prototype would still apply. */
14065 #ifdef __cplusplus
14066 extern "C"
14067 #endif
14068 char krb_get_cred ();
14070 main ()
14072 return krb_get_cred ();
14074 return 0;
14076 _ACEOF
14077 if ac_fn_c_try_link "$LINENO"; then :
14078 ac_cv_lib_krb4_krb_get_cred=yes
14079 else
14080 ac_cv_lib_krb4_krb_get_cred=no
14082 rm -f core conftest.err conftest.$ac_objext \
14083 conftest$ac_exeext conftest.$ac_ext
14084 LIBS=$ac_check_lib_save_LIBS
14086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14087 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14088 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14089 have_krb4=yes
14090 else
14091 have_krb4=no
14094 if test $have_krb4 = yes; then
14095 KRB4LIB=-lkrb4
14096 LIBS="$KRB4LIB $LIBS"
14098 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14100 else
14101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14102 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14103 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14104 $as_echo_n "(cached) " >&6
14105 else
14106 ac_check_lib_save_LIBS=$LIBS
14107 LIBS="-lkrb $LIBS"
14108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14109 /* end confdefs.h. */
14111 /* Override any GCC internal prototype to avoid an error.
14112 Use char because int might match the return type of a GCC
14113 builtin and then its argument prototype would still apply. */
14114 #ifdef __cplusplus
14115 extern "C"
14116 #endif
14117 char krb_get_cred ();
14119 main ()
14121 return krb_get_cred ();
14123 return 0;
14125 _ACEOF
14126 if ac_fn_c_try_link "$LINENO"; then :
14127 ac_cv_lib_krb_krb_get_cred=yes
14128 else
14129 ac_cv_lib_krb_krb_get_cred=no
14131 rm -f core conftest.err conftest.$ac_objext \
14132 conftest$ac_exeext conftest.$ac_ext
14133 LIBS=$ac_check_lib_save_LIBS
14135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14136 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14137 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14138 have_krb=yes
14139 else
14140 have_krb=no
14143 if test $have_krb = yes; then
14144 KRB4LIB=-lkrb
14145 LIBS="$KRB4LIB $LIBS"
14147 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14153 if test "${with_kerberos5}" != no; then
14154 for ac_header in krb5.h
14155 do :
14156 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14157 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14158 cat >>confdefs.h <<_ACEOF
14159 #define HAVE_KRB5_H 1
14160 _ACEOF
14161 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14163 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14165 cat >>confdefs.h <<_ACEOF
14166 #define HAVE_KRB5_ERROR_TEXT 1
14167 _ACEOF
14171 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14173 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14175 cat >>confdefs.h <<_ACEOF
14176 #define HAVE_KRB5_ERROR_E_TEXT 1
14177 _ACEOF
14184 done
14186 else
14187 for ac_header in des.h
14188 do :
14189 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14190 if test "x$ac_cv_header_des_h" = x""yes; then :
14191 cat >>confdefs.h <<_ACEOF
14192 #define HAVE_DES_H 1
14193 _ACEOF
14195 else
14196 for ac_header in kerberosIV/des.h
14197 do :
14198 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14199 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14200 cat >>confdefs.h <<_ACEOF
14201 #define HAVE_KERBEROSIV_DES_H 1
14202 _ACEOF
14204 else
14205 for ac_header in kerberos/des.h
14206 do :
14207 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14208 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14209 cat >>confdefs.h <<_ACEOF
14210 #define HAVE_KERBEROS_DES_H 1
14211 _ACEOF
14215 done
14219 done
14223 done
14225 for ac_header in krb.h
14226 do :
14227 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14228 if test "x$ac_cv_header_krb_h" = x""yes; then :
14229 cat >>confdefs.h <<_ACEOF
14230 #define HAVE_KRB_H 1
14231 _ACEOF
14233 else
14234 for ac_header in kerberosIV/krb.h
14235 do :
14236 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14237 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14238 cat >>confdefs.h <<_ACEOF
14239 #define HAVE_KERBEROSIV_KRB_H 1
14240 _ACEOF
14242 else
14243 for ac_header in kerberos/krb.h
14244 do :
14245 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14246 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14247 cat >>confdefs.h <<_ACEOF
14248 #define HAVE_KERBEROS_KRB_H 1
14249 _ACEOF
14253 done
14257 done
14261 done
14264 for ac_header in com_err.h
14265 do :
14266 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14267 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14268 cat >>confdefs.h <<_ACEOF
14269 #define HAVE_COM_ERR_H 1
14270 _ACEOF
14274 done
14287 for ac_func in $ac_func_list
14288 do :
14289 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14290 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14291 eval as_val=\$$as_ac_var
14292 if test "x$as_val" = x""yes; then :
14293 cat >>confdefs.h <<_ACEOF
14294 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14295 _ACEOF
14298 done
14303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14304 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14305 if test "${emacs_cv_localtime_cache+set}" = set; then :
14306 $as_echo_n "(cached) " >&6
14307 else
14308 if test x$ac_cv_func_tzset = xyes; then
14309 if test "$cross_compiling" = yes; then :
14310 # If we have tzset, assume the worst when cross-compiling.
14311 emacs_cv_localtime_cache=yes
14312 else
14313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14314 /* end confdefs.h. */
14315 #include <time.h>
14316 char TZ_GMT0[] = "TZ=GMT0";
14317 char TZ_PST8[] = "TZ=PST8";
14318 main()
14320 time_t now = time ((time_t *) 0);
14321 int hour_GMT0, hour_unset;
14322 if (putenv (TZ_GMT0) != 0)
14323 exit (1);
14324 hour_GMT0 = localtime (&now)->tm_hour;
14325 unsetenv("TZ");
14326 hour_unset = localtime (&now)->tm_hour;
14327 if (putenv (TZ_PST8) != 0)
14328 exit (1);
14329 if (localtime (&now)->tm_hour == hour_GMT0)
14330 exit (1);
14331 unsetenv("TZ");
14332 if (localtime (&now)->tm_hour != hour_unset)
14333 exit (1);
14334 exit (0);
14336 _ACEOF
14337 if ac_fn_c_try_run "$LINENO"; then :
14338 emacs_cv_localtime_cache=no
14339 else
14340 emacs_cv_localtime_cache=yes
14342 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14343 conftest.$ac_objext conftest.beam conftest.$ac_ext
14346 else
14347 # If we lack tzset, report that localtime does not cache TZ,
14348 # since we can't invalidate the cache if we don't have tzset.
14349 emacs_cv_localtime_cache=no
14352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14353 $as_echo "$emacs_cv_localtime_cache" >&6; }
14354 if test $emacs_cv_localtime_cache = yes; then
14356 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14360 ok_so_far=yes
14361 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14362 if test "x$ac_cv_func_socket" = x""yes; then :
14364 else
14365 ok_so_far=no
14368 if test $ok_so_far = yes; then
14369 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14370 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14372 else
14373 ok_so_far=no
14378 if test $ok_so_far = yes; then
14379 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14380 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14382 else
14383 ok_so_far=no
14388 if test $ok_so_far = yes; then
14390 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14394 if test -f /usr/lpp/X11/bin/smt.exp; then
14396 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14401 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14402 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14404 $as_echo "yes" >&6; }
14406 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14408 else
14409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14410 $as_echo "no" >&6; }
14413 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14414 if test "x$ac_cv_type_pid_t" = x""yes; then :
14416 else
14418 cat >>confdefs.h <<_ACEOF
14419 #define pid_t int
14420 _ACEOF
14424 for ac_header in vfork.h
14425 do :
14426 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14427 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14428 cat >>confdefs.h <<_ACEOF
14429 #define HAVE_VFORK_H 1
14430 _ACEOF
14434 done
14436 for ac_func in fork vfork
14437 do :
14438 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14439 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14440 eval as_val=\$$as_ac_var
14441 if test "x$as_val" = x""yes; then :
14442 cat >>confdefs.h <<_ACEOF
14443 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14444 _ACEOF
14447 done
14449 if test "x$ac_cv_func_fork" = xyes; then
14450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14451 $as_echo_n "checking for working fork... " >&6; }
14452 if test "${ac_cv_func_fork_works+set}" = set; then :
14453 $as_echo_n "(cached) " >&6
14454 else
14455 if test "$cross_compiling" = yes; then :
14456 ac_cv_func_fork_works=cross
14457 else
14458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14459 /* end confdefs.h. */
14460 $ac_includes_default
14462 main ()
14465 /* By Ruediger Kuhlmann. */
14466 return fork () < 0;
14469 return 0;
14471 _ACEOF
14472 if ac_fn_c_try_run "$LINENO"; then :
14473 ac_cv_func_fork_works=yes
14474 else
14475 ac_cv_func_fork_works=no
14477 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14478 conftest.$ac_objext conftest.beam conftest.$ac_ext
14482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14483 $as_echo "$ac_cv_func_fork_works" >&6; }
14485 else
14486 ac_cv_func_fork_works=$ac_cv_func_fork
14488 if test "x$ac_cv_func_fork_works" = xcross; then
14489 case $host in
14490 *-*-amigaos* | *-*-msdosdjgpp*)
14491 # Override, as these systems have only a dummy fork() stub
14492 ac_cv_func_fork_works=no
14495 ac_cv_func_fork_works=yes
14497 esac
14498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14499 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14501 ac_cv_func_vfork_works=$ac_cv_func_vfork
14502 if test "x$ac_cv_func_vfork" = xyes; then
14503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14504 $as_echo_n "checking for working vfork... " >&6; }
14505 if test "${ac_cv_func_vfork_works+set}" = set; then :
14506 $as_echo_n "(cached) " >&6
14507 else
14508 if test "$cross_compiling" = yes; then :
14509 ac_cv_func_vfork_works=cross
14510 else
14511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14512 /* end confdefs.h. */
14513 /* Thanks to Paul Eggert for this test. */
14514 $ac_includes_default
14515 #include <sys/wait.h>
14516 #ifdef HAVE_VFORK_H
14517 # include <vfork.h>
14518 #endif
14519 /* On some sparc systems, changes by the child to local and incoming
14520 argument registers are propagated back to the parent. The compiler
14521 is told about this with #include <vfork.h>, but some compilers
14522 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14523 static variable whose address is put into a register that is
14524 clobbered by the vfork. */
14525 static void
14526 #ifdef __cplusplus
14527 sparc_address_test (int arg)
14528 # else
14529 sparc_address_test (arg) int arg;
14530 #endif
14532 static pid_t child;
14533 if (!child) {
14534 child = vfork ();
14535 if (child < 0) {
14536 perror ("vfork");
14537 _exit(2);
14539 if (!child) {
14540 arg = getpid();
14541 write(-1, "", 0);
14542 _exit (arg);
14548 main ()
14550 pid_t parent = getpid ();
14551 pid_t child;
14553 sparc_address_test (0);
14555 child = vfork ();
14557 if (child == 0) {
14558 /* Here is another test for sparc vfork register problems. This
14559 test uses lots of local variables, at least as many local
14560 variables as main has allocated so far including compiler
14561 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14562 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14563 reuse the register of parent for one of the local variables,
14564 since it will think that parent can't possibly be used any more
14565 in this routine. Assigning to the local variable will thus
14566 munge parent in the parent process. */
14567 pid_t
14568 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14569 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14570 /* Convince the compiler that p..p7 are live; otherwise, it might
14571 use the same hardware register for all 8 local variables. */
14572 if (p != p1 || p != p2 || p != p3 || p != p4
14573 || p != p5 || p != p6 || p != p7)
14574 _exit(1);
14576 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14577 from child file descriptors. If the child closes a descriptor
14578 before it execs or exits, this munges the parent's descriptor
14579 as well. Test for this by closing stdout in the child. */
14580 _exit(close(fileno(stdout)) != 0);
14581 } else {
14582 int status;
14583 struct stat st;
14585 while (wait(&status) != child)
14587 return (
14588 /* Was there some problem with vforking? */
14589 child < 0
14591 /* Did the child fail? (This shouldn't happen.) */
14592 || status
14594 /* Did the vfork/compiler bug occur? */
14595 || parent != getpid()
14597 /* Did the file descriptor bug occur? */
14598 || fstat(fileno(stdout), &st) != 0
14602 _ACEOF
14603 if ac_fn_c_try_run "$LINENO"; then :
14604 ac_cv_func_vfork_works=yes
14605 else
14606 ac_cv_func_vfork_works=no
14608 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14609 conftest.$ac_objext conftest.beam conftest.$ac_ext
14613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14614 $as_echo "$ac_cv_func_vfork_works" >&6; }
14617 if test "x$ac_cv_func_fork_works" = xcross; then
14618 ac_cv_func_vfork_works=$ac_cv_func_vfork
14619 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14620 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14623 if test "x$ac_cv_func_vfork_works" = xyes; then
14625 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14627 else
14629 $as_echo "#define vfork fork" >>confdefs.h
14632 if test "x$ac_cv_func_fork_works" = xyes; then
14634 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14639 for ac_func in snprintf
14640 do :
14641 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14642 if test "x$ac_cv_func_snprintf" = x""yes; then :
14643 cat >>confdefs.h <<_ACEOF
14644 #define HAVE_SNPRINTF 1
14645 _ACEOF
14648 done
14651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14652 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14653 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14654 $as_echo_n "(cached) " >&6
14655 else
14656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14657 /* end confdefs.h. */
14658 #include <langinfo.h>
14660 main ()
14662 char* cs = nl_langinfo(CODESET);
14664 return 0;
14666 _ACEOF
14667 if ac_fn_c_try_link "$LINENO"; then :
14668 emacs_cv_langinfo_codeset=yes
14669 else
14670 emacs_cv_langinfo_codeset=no
14672 rm -f core conftest.err conftest.$ac_objext \
14673 conftest$ac_exeext conftest.$ac_ext
14676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14677 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14678 if test $emacs_cv_langinfo_codeset = yes; then
14680 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14685 $as_echo_n "checking for mbstate_t... " >&6; }
14686 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14687 $as_echo_n "(cached) " >&6
14688 else
14689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14690 /* end confdefs.h. */
14691 $ac_includes_default
14692 # include <wchar.h>
14694 main ()
14696 mbstate_t x; return sizeof x;
14698 return 0;
14700 _ACEOF
14701 if ac_fn_c_try_compile "$LINENO"; then :
14702 ac_cv_type_mbstate_t=yes
14703 else
14704 ac_cv_type_mbstate_t=no
14706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
14709 $as_echo "$ac_cv_type_mbstate_t" >&6; }
14710 if test $ac_cv_type_mbstate_t = yes; then
14712 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
14714 else
14716 $as_echo "#define mbstate_t int" >>confdefs.h
14720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
14721 $as_echo_n "checking for C restricted array declarations... " >&6; }
14722 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
14723 $as_echo_n "(cached) " >&6
14724 else
14725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14726 /* end confdefs.h. */
14727 void fred (int x[__restrict]);
14729 main ()
14733 return 0;
14735 _ACEOF
14736 if ac_fn_c_try_compile "$LINENO"; then :
14737 emacs_cv_c_restrict_arr=yes
14738 else
14739 emacs_cv_c_restrict_arr=no
14741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
14744 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
14745 if test "$emacs_cv_c_restrict_arr" = yes; then
14747 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
14753 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
14757 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
14764 ## Note: PTYs are broken on darwin <6. Use at your own risk.
14766 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
14770 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
14776 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
14780 $as_echo "#define SEPCHAR ':'" >>confdefs.h
14784 $as_echo "#define subprocesses 1" >>confdefs.h
14788 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
14793 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
14799 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
14803 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
14807 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
14813 case $opsys in
14814 aix4-2)
14815 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
14816 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14821 hpux*)
14822 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14825 esac
14828 case $opsys in
14829 darwin | gnu | hpux* | *bsd )
14831 $as_echo "#define NO_TERMIO 1" >>confdefs.h
14835 irix6-5 | sol2* | unixware )
14837 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
14840 esac
14843 case $opsys in
14844 hpux* | irix6-5 | openbsd | sol2* | unixware )
14846 $as_echo "#define BROKEN_SIGIO 1" >>confdefs.h
14850 aix4-2)
14852 $as_echo "#define BROKEN_FIONREAD 1" >>confdefs.h
14855 $as_echo "#define BROKEN_SIGAIO 1" >>confdefs.h
14858 $as_echo "#define BROKEN_SIGPOLL 1" >>confdefs.h
14861 $as_echo "#define BROKEN_SIGPTY 1" >>confdefs.h
14865 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
14869 freebsd)
14871 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
14875 darwin)
14877 $as_echo "#define NO_ABORT 1" >>confdefs.h
14880 esac
14882 case $opsys in
14883 gnu-* | sol2-10 )
14885 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
14888 esac
14890 case $opsys in
14891 darwin | freebsd | netbsd | openbsd )
14893 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
14896 esac
14898 case $opsys in
14899 netbsd | openbsd) sound_device="/dev/audio" ;;
14900 *) sound_device="/dev/dsp" ;;
14901 esac
14904 cat >>confdefs.h <<_ACEOF
14905 #define DEFAULT_SOUND_DEVICE "$sound_device"
14906 _ACEOF
14910 case $opsys in
14911 darwin | gnu-linux | gnu-kfreebsd )
14913 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
14916 esac
14919 case $opsys in
14920 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
14922 $as_echo "#define NARROWPROTO 1" >>confdefs.h
14925 esac
14934 case $opsys in
14935 aix4-2 )
14936 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
14938 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
14940 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
14944 cygwin )
14945 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
14947 $as_echo "#define PTY_OPEN do { int dummy; SIGMASKTYPE mask; mask = sigblock (sigmask (SIGCHLD)); if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) fd = -1; sigsetmask (mask); if (fd >= 0) emacs_close (dummy); } while (0)" >>confdefs.h
14949 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
14951 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
14955 darwin )
14956 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
14958 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14960 $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
14962 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
14964 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
14968 gnu | openbsd )
14969 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14973 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
14974 if test "x$ac_cv_func_grantpt" = xyes; then
14976 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
14978 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
14980 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname; sigblock (sigmask (SIGCHLD)); if (grantpt (fd) == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname(fd))) { sigunblock (sigmask (SIGCHLD)); close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); sigunblock (sigmask (SIGCHLD)); }" >>confdefs.h
14982 if test "x$ac_cv_func_posix_openpt" = xyes; then
14983 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
14985 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
14987 elif test "x$ac_cv_func_getpt" = xyes; then
14988 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
14990 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
14992 else
14993 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
14996 else
14997 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15002 hpux*)
15003 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15005 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15007 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15011 irix6-5 )
15012 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15014 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15016 $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(SIGCLD, &cstat, &ocstat); name = _getpty (&fd, O_RDWR | O_NDELAY, 0600, 0); sigaction(SIGCLD, &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
15018 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15020 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15024 sol2* )
15025 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; sigblock (sigmask (SIGCLD)); if (grantpt (fd) == -1) { emacs_close (fd); return -1; } sigunblock (sigmask (SIGCLD)); if (unlockpt (fd) == -1) { emacs_close (fd); return -1; } if (!(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15029 unixware )
15030 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; sigblock(sigmask(SIGCLD)); if (grantpt(fd) == -1) fatal(\"could not grant slave pty\"); sigunblock(sigmask(SIGCLD)); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15033 esac
15036 case $opsys in
15037 sol2* | unixware )
15038 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15040 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15043 $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
15046 esac
15051 case $opsys in
15052 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15053 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15057 gnu-linux | gnu-kfreebsd )
15059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15060 $as_echo_n "checking for signals via characters... " >&6; }
15061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15062 /* end confdefs.h. */
15064 #include <linux/version.h>
15065 #if LINUX_VERSION_CODE < 0x20400
15066 # error "Linux version too old"
15067 #endif
15070 main ()
15074 return 0;
15076 _ACEOF
15077 if ac_fn_c_try_cpp "$LINENO"; then :
15078 emacs_signals_via_chars=yes
15079 else
15080 emacs_signals_via_chars=no
15082 rm -f conftest.err conftest.$ac_ext
15084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15085 $as_echo "$emacs_signals_via_chars" >&6; }
15086 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15089 esac
15094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C library" >&5
15095 $as_echo_n "checking whether we are using the GNU C library... " >&6; }
15096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15097 /* end confdefs.h. */
15099 #include <features.h>
15100 #ifndef __GNU_LIBRARY__
15101 # error "this is not the GNU C library"
15102 #endif
15105 main ()
15109 return 0;
15111 _ACEOF
15112 if ac_fn_c_try_cpp "$LINENO"; then :
15113 emacs_glibc=yes
15114 else
15115 emacs_glibc=no
15117 rm -f conftest.err conftest.$ac_ext
15118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_glibc" >&5
15119 $as_echo "$emacs_glibc" >&6; }
15121 if test $emacs_glibc = yes; then
15123 emacs_pending_output=unknown
15125 case $opsys in
15126 gnu | gnu-linux | gnu-kfreebsd )
15127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of pending output formalism" >&5
15128 $as_echo_n "checking for style of pending output formalism... " >&6; }
15129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15130 /* end confdefs.h. */
15132 #include <stdio.h>
15133 #if !defined (_IO_STDIO_H) && !defined (_STDIO_USES_IOSTREAM)
15134 # error "stdio definitions not found"
15135 #endif
15138 main ()
15142 return 0;
15144 _ACEOF
15145 if ac_fn_c_try_cpp "$LINENO"; then :
15146 emacs_pending_output=new
15148 rm -f conftest.err conftest.$ac_ext
15150 if test $emacs_pending_output = unknown; then
15151 case $opsys in
15152 gnu-linux | gnu-kfreebsd)
15153 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15154 /* end confdefs.h. */
15156 #include <stdio.h>
15157 #ifndef __UCLIBC__
15158 # error "not using uclibc"
15159 #endif
15162 main ()
15166 return 0;
15168 _ACEOF
15169 if ac_fn_c_try_cpp "$LINENO"; then :
15170 emacs_pending_output=uclibc
15171 else
15172 emacs_pending_output=old
15174 rm -f conftest.err conftest.$ac_ext
15176 esac
15179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_pending_output" >&5
15180 $as_echo "$emacs_pending_output" >&6; }
15182 case $emacs_pending_output in
15183 new)
15184 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_IO_write_ptr - (FILE)->_IO_write_base)" >>confdefs.h
15187 uclibc)
15188 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufpos - (FILE)->__bufstart)" >>confdefs.h
15191 old)
15192 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_pptr - (FILE)->_pbase)" >>confdefs.h
15195 esac
15197 esac
15198 if test $emacs_pending_output = unknown; then
15199 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufp - (FILE)->__buffer)" >>confdefs.h
15203 else
15204 case $opsys in
15205 cygwin | darwin | freebsd | netbsd | openbsd )
15206 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)" >>confdefs.h
15210 unixware)
15211 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__ptr - (FILE)->__base)" >>confdefs.h
15216 if test x$ac_cv_header_stdio_ext_h = xyes && \
15217 test x$ac_cv_func___fpending = xyes; then
15218 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) __fpending (FILE)" >>confdefs.h
15221 $as_echo "#define DISPNEW_NEEDS_STDIO_EXT 1" >>confdefs.h
15223 else
15224 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_ptr - (FILE)->_base)" >>confdefs.h
15228 esac
15234 case $opsys in
15235 gnu)
15236 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15240 hpux*)
15241 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15243 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15246 irix6-5)
15247 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15249 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15252 esac
15258 case $opsys in
15259 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15262 gnu | freebsd | netbsd | openbsd )
15264 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15266 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15270 gnu-linux | gnu-kfreebsd )
15271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15272 /* end confdefs.h. */
15274 #ifndef __i386__
15275 # error "not i386"
15276 #endif
15279 main ()
15283 return 0;
15285 _ACEOF
15286 if ac_fn_c_try_cpp "$LINENO"; then :
15287 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15290 rm -f conftest.err conftest.$ac_ext
15292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15293 /* end confdefs.h. */
15295 #ifndef __ia64__
15296 # error "not ia64"
15297 #endif
15300 main ()
15304 return 0;
15306 _ACEOF
15307 if ac_fn_c_try_cpp "$LINENO"; then :
15309 $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
15312 rm -f conftest.err conftest.$ac_ext
15315 hpux*)
15317 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15321 irix6-5)
15322 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15325 esac
15333 case $opsys in
15334 aix4-2 | hpux* | unixware)
15335 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15339 gnu-linux | gnu-kfreebsd )
15340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15341 /* end confdefs.h. */
15343 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15344 || defined __alpha__ || defined __mips__ || defined __s390__ \
15345 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15346 || defined __ia64__ || defined __sh__
15347 /* ok */
15348 #else
15349 # error "setjmp not known to work on this arch"
15350 #endif
15353 main ()
15357 return 0;
15359 _ACEOF
15360 if ac_fn_c_try_cpp "$LINENO"; then :
15361 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15363 else
15364 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15367 rm -f conftest.err conftest.$ac_ext
15369 esac
15372 if test x$GCC = xyes; then
15373 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15375 else
15376 case $opsys in
15377 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15378 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15381 esac
15384 case $opsys in
15385 sol2* | unixware )
15387 $as_echo "#define _setjmp setjmp" >>confdefs.h
15390 $as_echo "#define _longjmp longjmp" >>confdefs.h
15393 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15396 esac
15399 case $opsys in
15400 hpux* | sol2* )
15402 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15406 netbsd | openbsd )
15408 $as_echo "#define SIGNAL_H_AHB 1" >>confdefs.h
15411 esac
15422 case $opsys in
15423 aix4-2)
15424 $as_echo "#define USG /**/" >>confdefs.h
15426 $as_echo "#define USG5 /**/" >>confdefs.h
15428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15429 /* end confdefs.h. */
15431 #ifndef _AIX
15432 # error "_AIX not defined"
15433 #endif
15436 main ()
15440 return 0;
15442 _ACEOF
15443 if ac_fn_c_try_cpp "$LINENO"; then :
15445 else
15447 $as_echo "#define _AIX /**/" >>confdefs.h
15450 rm -f conftest.err conftest.$ac_ext
15453 cygwin)
15455 $as_echo "#define CYGWIN 1" >>confdefs.h
15459 darwin)
15460 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15462 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15465 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15469 freebsd)
15470 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15473 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15477 gnu | netbsd | openbsd )
15478 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15481 /* end confdefs.h. */
15483 #ifndef BSD_SYSTEM
15484 # error "BSD_SYSTEM not defined"
15485 #endif
15488 main ()
15492 return 0;
15494 _ACEOF
15495 if ac_fn_c_try_cpp "$LINENO"; then :
15497 else
15498 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15501 rm -f conftest.err conftest.$ac_ext
15504 gnu-linux | gnu-kfreebsd )
15505 $as_echo "#define USG /**/" >>confdefs.h
15508 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15512 hpux*)
15513 $as_echo "#define USG /**/" >>confdefs.h
15515 $as_echo "#define USG5 /**/" >>confdefs.h
15518 $as_echo "#define HPUX /**/" >>confdefs.h
15522 irix6-5)
15523 $as_echo "#define USG /**/" >>confdefs.h
15525 $as_echo "#define USG5 /**/" >>confdefs.h
15527 $as_echo "#define USG5_4 /**/" >>confdefs.h
15530 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15534 sol2*)
15535 $as_echo "#define USG /**/" >>confdefs.h
15537 $as_echo "#define USG5 /**/" >>confdefs.h
15539 $as_echo "#define USG5_4 /**/" >>confdefs.h
15542 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15546 unixware)
15547 $as_echo "#define USG /**/" >>confdefs.h
15549 $as_echo "#define USG5 /**/" >>confdefs.h
15551 $as_echo "#define USG5_4 /**/" >>confdefs.h
15554 esac
15557 case $opsys in
15558 cygwin)
15560 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15564 hpux11)
15566 $as_echo "#define BROKEN_SA_RESTART 1" >>confdefs.h
15569 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15573 irix6-5)
15575 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15578 $as_echo "#define SETPGRP_RELEASES_CTTY 1" >>confdefs.h
15582 sol2-10)
15584 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15587 esac
15589 # Set up the CFLAGS for real compilation, so we can substitute it.
15590 CFLAGS="$REAL_CFLAGS"
15591 CPPFLAGS="$REAL_CPPFLAGS"
15593 ## Hack to detect a buggy GCC version.
15594 if test "x$GCC" = xyes \
15595 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15596 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15597 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15598 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15601 version=$PACKAGE_VERSION
15603 ### Specify what sort of things we'll be editing into Makefile and config.h.
15604 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15607 ## Unused?
15630 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15631 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15632 ## end of LIBX_BASE, but nothing ever set it.
15637 ## Used in lwlib/Makefile.in.
15647 cat >>confdefs.h <<_ACEOF
15648 #define EMACS_CONFIGURATION "${canonical}"
15649 _ACEOF
15652 cat >>confdefs.h <<_ACEOF
15653 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15654 _ACEOF
15658 XMENU_OBJ=
15659 XOBJ=
15660 FONT_OBJ=
15661 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15663 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15665 XMENU_OBJ=xmenu.o
15666 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
15667 FONT_OBJ=xfont.o
15668 if test "$HAVE_XFT" = "yes"; then
15669 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15670 elif test "$HAVE_FREETYPE" = "yes"; then
15671 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15679 WIDGET_OBJ=
15680 MOTIF_LIBW=
15681 if test "${USE_X_TOOLKIT}" != "none" ; then
15682 WIDGET_OBJ=widget.o
15684 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15686 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15688 $as_echo "#define USE_LUCID 1" >>confdefs.h
15690 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15692 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15694 MOTIF_LIBW=-lXm
15695 case "$opsys" in
15696 gnu-linux)
15697 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15698 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15701 unixware)
15702 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15703 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15704 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15707 aix4-2)
15708 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15709 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15711 esac
15712 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15717 TOOLKIT_LIBW=
15718 case "$USE_X_TOOLKIT" in
15719 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15720 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15721 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15722 esac
15725 if test "$USE_X_TOOLKIT" = "none"; then
15726 LIBXT_OTHER="\$(LIBXSM)"
15727 OLDXMENU_TARGET="really-oldXMenu"
15728 else
15729 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15730 OLDXMENU_TARGET="really-lwlib"
15734 ## The X Menu stuff is present in the X10 distribution, but missing
15735 ## from X11. If we have X10, just use the installed library;
15736 ## otherwise, use our own copy.
15737 if test "${HAVE_X11}" = "yes" ; then
15739 $as_echo "#define HAVE_X11 1" >>confdefs.h
15742 if test "$USE_X_TOOLKIT" = "none"; then
15743 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15744 else
15745 OLDXMENU="\${lwlibdir}/liblw.a"
15747 LIBXMENU="\$(OLDXMENU)"
15748 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15749 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
15750 else
15751 ## For a syntactically valid Makefile; not actually used for anything.
15752 ## See comments in src/Makefile.in.
15753 OLDXMENU=nothing
15754 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15755 if test "${HAVE_X_WINDOWS}" = "yes"; then
15756 LIBXMENU="-lXMenu"
15757 else
15758 LIBXMENU=
15760 LIBX_OTHER=
15761 OLDXMENU_DEPS=
15764 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15765 OLDXMENU_TARGET=
15766 OLDXMENU=nothing
15767 LIBXMENU=
15768 OLDXMENU_DEPS=
15777 if test "${HAVE_MENUS}" = "yes" ; then
15779 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
15783 if test "${GNU_MALLOC}" = "yes" ; then
15785 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
15789 RALLOC_OBJ=
15790 if test "${REL_ALLOC}" = "yes" ; then
15792 $as_echo "#define REL_ALLOC 1" >>confdefs.h
15795 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
15799 if test "$opsys" = "cygwin"; then
15800 CYGWIN_OBJ="sheap.o"
15801 ## Cygwin differs because of its unexec().
15802 PRE_ALLOC_OBJ=
15803 POST_ALLOC_OBJ=lastfile.o
15804 else
15805 CYGWIN_OBJ=
15806 PRE_ALLOC_OBJ=lastfile.o
15807 POST_ALLOC_OBJ=
15813 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
15814 # it temporarily reverts them to their pre-pkg-config values,
15815 # because gnulib needs to work with both src (which uses the
15816 # pkg-config stuff) and lib-src (which does not). For example, gnulib
15817 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
15818 # and it therefore needs to run in an environment where LIBS does not
15819 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
15820 # for some package unrelated to lib-src.
15821 SAVE_CFLAGS=$CFLAGS
15822 SAVE_LIBS=$LIBS
15823 CFLAGS=$pre_PKG_CONFIG_CFLAGS
15824 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
15836 LIBC_FATAL_STDERR_=1
15837 export LIBC_FATAL_STDERR_
15839 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15840 # for constant arguments. Useless!
15841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15842 $as_echo_n "checking for working alloca.h... " >&6; }
15843 if test "${ac_cv_working_alloca_h+set}" = set; then :
15844 $as_echo_n "(cached) " >&6
15845 else
15846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15847 /* end confdefs.h. */
15848 #include <alloca.h>
15850 main ()
15852 char *p = (char *) alloca (2 * sizeof (int));
15853 if (p) return 0;
15855 return 0;
15857 _ACEOF
15858 if ac_fn_c_try_link "$LINENO"; then :
15859 ac_cv_working_alloca_h=yes
15860 else
15861 ac_cv_working_alloca_h=no
15863 rm -f core conftest.err conftest.$ac_objext \
15864 conftest$ac_exeext conftest.$ac_ext
15866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
15867 $as_echo "$ac_cv_working_alloca_h" >&6; }
15868 if test $ac_cv_working_alloca_h = yes; then
15870 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
15874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
15875 $as_echo_n "checking for alloca... " >&6; }
15876 if test "${ac_cv_func_alloca_works+set}" = set; then :
15877 $as_echo_n "(cached) " >&6
15878 else
15879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15880 /* end confdefs.h. */
15881 #ifdef __GNUC__
15882 # define alloca __builtin_alloca
15883 #else
15884 # ifdef _MSC_VER
15885 # include <malloc.h>
15886 # define alloca _alloca
15887 # else
15888 # ifdef HAVE_ALLOCA_H
15889 # include <alloca.h>
15890 # else
15891 # ifdef _AIX
15892 #pragma alloca
15893 # else
15894 # ifndef alloca /* predefined by HP cc +Olibcalls */
15895 char *alloca ();
15896 # endif
15897 # endif
15898 # endif
15899 # endif
15900 #endif
15903 main ()
15905 char *p = (char *) alloca (1);
15906 if (p) return 0;
15908 return 0;
15910 _ACEOF
15911 if ac_fn_c_try_link "$LINENO"; then :
15912 ac_cv_func_alloca_works=yes
15913 else
15914 ac_cv_func_alloca_works=no
15916 rm -f core conftest.err conftest.$ac_objext \
15917 conftest$ac_exeext conftest.$ac_ext
15919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
15920 $as_echo "$ac_cv_func_alloca_works" >&6; }
15922 if test $ac_cv_func_alloca_works = yes; then
15924 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
15926 else
15927 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
15928 # that cause trouble. Some versions do not even contain alloca or
15929 # contain a buggy version. If you still want to use their alloca,
15930 # use ar to extract alloca.o from them instead of compiling alloca.c.
15936 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
15938 $as_echo "#define C_ALLOCA 1" >>confdefs.h
15941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
15942 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
15943 if test "${ac_cv_os_cray+set}" = set; then :
15944 $as_echo_n "(cached) " >&6
15945 else
15946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15947 /* end confdefs.h. */
15948 #if defined CRAY && ! defined CRAY2
15949 webecray
15950 #else
15951 wenotbecray
15952 #endif
15954 _ACEOF
15955 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15956 $EGREP "webecray" >/dev/null 2>&1; then :
15957 ac_cv_os_cray=yes
15958 else
15959 ac_cv_os_cray=no
15961 rm -f conftest*
15964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
15965 $as_echo "$ac_cv_os_cray" >&6; }
15966 if test $ac_cv_os_cray = yes; then
15967 for ac_func in _getb67 GETB67 getb67; do
15968 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15969 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15970 eval as_val=\$$as_ac_var
15971 if test "x$as_val" = x""yes; then :
15973 cat >>confdefs.h <<_ACEOF
15974 #define CRAY_STACKSEG_END $ac_func
15975 _ACEOF
15977 break
15980 done
15983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
15984 $as_echo_n "checking stack direction for C alloca... " >&6; }
15985 if test "${ac_cv_c_stack_direction+set}" = set; then :
15986 $as_echo_n "(cached) " >&6
15987 else
15988 if test "$cross_compiling" = yes; then :
15989 ac_cv_c_stack_direction=0
15990 else
15991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15992 /* end confdefs.h. */
15993 $ac_includes_default
15995 find_stack_direction (int *addr, int depth)
15997 int dir, dummy = 0;
15998 if (! addr)
15999 addr = &dummy;
16000 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16001 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16002 return dir + dummy;
16006 main (int argc, char **argv)
16008 return find_stack_direction (0, argc + !argv + 20) < 0;
16010 _ACEOF
16011 if ac_fn_c_try_run "$LINENO"; then :
16012 ac_cv_c_stack_direction=1
16013 else
16014 ac_cv_c_stack_direction=-1
16016 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16017 conftest.$ac_objext conftest.beam conftest.$ac_ext
16021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16022 $as_echo "$ac_cv_c_stack_direction" >&6; }
16023 cat >>confdefs.h <<_ACEOF
16024 #define STACK_DIRECTION $ac_cv_c_stack_direction
16025 _ACEOF
16033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16034 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16035 if test "${ac_cv_c_bigendian+set}" = set; then :
16036 $as_echo_n "(cached) " >&6
16037 else
16038 ac_cv_c_bigendian=unknown
16039 # See if we're dealing with a universal compiler.
16040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16041 /* end confdefs.h. */
16042 #ifndef __APPLE_CC__
16043 not a universal capable compiler
16044 #endif
16045 typedef int dummy;
16047 _ACEOF
16048 if ac_fn_c_try_compile "$LINENO"; then :
16050 # Check for potential -arch flags. It is not universal unless
16051 # there are at least two -arch flags with different values.
16052 ac_arch=
16053 ac_prev=
16054 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16055 if test -n "$ac_prev"; then
16056 case $ac_word in
16057 i?86 | x86_64 | ppc | ppc64)
16058 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16059 ac_arch=$ac_word
16060 else
16061 ac_cv_c_bigendian=universal
16062 break
16065 esac
16066 ac_prev=
16067 elif test "x$ac_word" = "x-arch"; then
16068 ac_prev=arch
16070 done
16072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16073 if test $ac_cv_c_bigendian = unknown; then
16074 # See if sys/param.h defines the BYTE_ORDER macro.
16075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16076 /* end confdefs.h. */
16077 #include <sys/types.h>
16078 #include <sys/param.h>
16081 main ()
16083 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16084 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16085 && LITTLE_ENDIAN)
16086 bogus endian macros
16087 #endif
16090 return 0;
16092 _ACEOF
16093 if ac_fn_c_try_compile "$LINENO"; then :
16094 # It does; now see whether it defined to BIG_ENDIAN or not.
16095 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16096 /* end confdefs.h. */
16097 #include <sys/types.h>
16098 #include <sys/param.h>
16101 main ()
16103 #if BYTE_ORDER != BIG_ENDIAN
16104 not big endian
16105 #endif
16108 return 0;
16110 _ACEOF
16111 if ac_fn_c_try_compile "$LINENO"; then :
16112 ac_cv_c_bigendian=yes
16113 else
16114 ac_cv_c_bigendian=no
16116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16120 if test $ac_cv_c_bigendian = unknown; then
16121 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16123 /* end confdefs.h. */
16124 #include <limits.h>
16127 main ()
16129 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16130 bogus endian macros
16131 #endif
16134 return 0;
16136 _ACEOF
16137 if ac_fn_c_try_compile "$LINENO"; then :
16138 # It does; now see whether it defined to _BIG_ENDIAN or not.
16139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16140 /* end confdefs.h. */
16141 #include <limits.h>
16144 main ()
16146 #ifndef _BIG_ENDIAN
16147 not big endian
16148 #endif
16151 return 0;
16153 _ACEOF
16154 if ac_fn_c_try_compile "$LINENO"; then :
16155 ac_cv_c_bigendian=yes
16156 else
16157 ac_cv_c_bigendian=no
16159 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16161 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16163 if test $ac_cv_c_bigendian = unknown; then
16164 # Compile a test program.
16165 if test "$cross_compiling" = yes; then :
16166 # Try to guess by grepping values from an object file.
16167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16168 /* end confdefs.h. */
16169 short int ascii_mm[] =
16170 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16171 short int ascii_ii[] =
16172 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16173 int use_ascii (int i) {
16174 return ascii_mm[i] + ascii_ii[i];
16176 short int ebcdic_ii[] =
16177 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16178 short int ebcdic_mm[] =
16179 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16180 int use_ebcdic (int i) {
16181 return ebcdic_mm[i] + ebcdic_ii[i];
16183 extern int foo;
16186 main ()
16188 return use_ascii (foo) == use_ebcdic (foo);
16190 return 0;
16192 _ACEOF
16193 if ac_fn_c_try_compile "$LINENO"; then :
16194 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16195 ac_cv_c_bigendian=yes
16197 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16198 if test "$ac_cv_c_bigendian" = unknown; then
16199 ac_cv_c_bigendian=no
16200 else
16201 # finding both strings is unlikely to happen, but who knows?
16202 ac_cv_c_bigendian=unknown
16206 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16207 else
16208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16209 /* end confdefs.h. */
16210 $ac_includes_default
16212 main ()
16215 /* Are we little or big endian? From Harbison&Steele. */
16216 union
16218 long int l;
16219 char c[sizeof (long int)];
16220 } u;
16221 u.l = 1;
16222 return u.c[sizeof (long int) - 1] == 1;
16225 return 0;
16227 _ACEOF
16228 if ac_fn_c_try_run "$LINENO"; then :
16229 ac_cv_c_bigendian=no
16230 else
16231 ac_cv_c_bigendian=yes
16233 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16234 conftest.$ac_objext conftest.beam conftest.$ac_ext
16239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16240 $as_echo "$ac_cv_c_bigendian" >&6; }
16241 case $ac_cv_c_bigendian in #(
16242 yes)
16243 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16244 ;; #(
16246 ;; #(
16247 universal)
16249 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16251 ;; #(
16253 as_fn_error "unknown endianness
16254 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16255 esac
16258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16259 $as_echo_n "checking for inline... " >&6; }
16260 if test "${ac_cv_c_inline+set}" = set; then :
16261 $as_echo_n "(cached) " >&6
16262 else
16263 ac_cv_c_inline=no
16264 for ac_kw in inline __inline__ __inline; do
16265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16266 /* end confdefs.h. */
16267 #ifndef __cplusplus
16268 typedef int foo_t;
16269 static $ac_kw foo_t static_foo () {return 0; }
16270 $ac_kw foo_t foo () {return 0; }
16271 #endif
16273 _ACEOF
16274 if ac_fn_c_try_compile "$LINENO"; then :
16275 ac_cv_c_inline=$ac_kw
16277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16278 test "$ac_cv_c_inline" != no && break
16279 done
16282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16283 $as_echo "$ac_cv_c_inline" >&6; }
16285 case $ac_cv_c_inline in
16286 inline | yes) ;;
16288 case $ac_cv_c_inline in
16289 no) ac_val=;;
16290 *) ac_val=$ac_cv_c_inline;;
16291 esac
16292 cat >>confdefs.h <<_ACEOF
16293 #ifndef __cplusplus
16294 #define inline $ac_val
16295 #endif
16296 _ACEOF
16298 esac
16301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16302 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16303 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16304 $as_echo_n "(cached) " >&6
16305 else
16306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16307 /* end confdefs.h. */
16308 /* On HP-UX before 11.23, strtold returns a struct instead of
16309 long double. Reject implementations like that, by requiring
16310 compatibility with the C99 prototype. */
16311 #include <stdlib.h>
16312 static long double (*p) (char const *, char **) = strtold;
16313 static long double
16314 test (char const *nptr, char **endptr)
16316 long double r;
16317 r = strtold (nptr, endptr);
16318 return r;
16321 main ()
16323 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16325 return 0;
16327 _ACEOF
16328 if ac_fn_c_try_link "$LINENO"; then :
16329 gl_cv_func_c99_strtold=yes
16330 else
16331 gl_cv_func_c99_strtold=no
16333 rm -f core conftest.err conftest.$ac_objext \
16334 conftest$ac_exeext conftest.$ac_ext
16336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16337 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16338 if test $gl_cv_func_c99_strtold = yes; then
16340 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16345 GNULIB_CHDIR=0;
16346 GNULIB_CHOWN=0;
16347 GNULIB_CLOSE=0;
16348 GNULIB_DUP=0;
16349 GNULIB_DUP2=0;
16350 GNULIB_DUP3=0;
16351 GNULIB_ENVIRON=0;
16352 GNULIB_EUIDACCESS=0;
16353 GNULIB_FACCESSAT=0;
16354 GNULIB_FCHDIR=0;
16355 GNULIB_FCHOWNAT=0;
16356 GNULIB_FDATASYNC=0;
16357 GNULIB_FSYNC=0;
16358 GNULIB_FTRUNCATE=0;
16359 GNULIB_GETCWD=0;
16360 GNULIB_GETDOMAINNAME=0;
16361 GNULIB_GETDTABLESIZE=0;
16362 GNULIB_GETGROUPS=0;
16363 GNULIB_GETHOSTNAME=0;
16364 GNULIB_GETLOGIN=0;
16365 GNULIB_GETLOGIN_R=0;
16366 GNULIB_GETPAGESIZE=0;
16367 GNULIB_GETUSERSHELL=0;
16368 GNULIB_GROUP_MEMBER=0;
16369 GNULIB_ISATTY=0;
16370 GNULIB_LCHOWN=0;
16371 GNULIB_LINK=0;
16372 GNULIB_LINKAT=0;
16373 GNULIB_LSEEK=0;
16374 GNULIB_PIPE=0;
16375 GNULIB_PIPE2=0;
16376 GNULIB_PREAD=0;
16377 GNULIB_PWRITE=0;
16378 GNULIB_READ=0;
16379 GNULIB_READLINK=0;
16380 GNULIB_READLINKAT=0;
16381 GNULIB_RMDIR=0;
16382 GNULIB_SETHOSTNAME=0;
16383 GNULIB_SLEEP=0;
16384 GNULIB_SYMLINK=0;
16385 GNULIB_SYMLINKAT=0;
16386 GNULIB_TTYNAME_R=0;
16387 GNULIB_UNISTD_H_NONBLOCKING=0;
16388 GNULIB_UNISTD_H_SIGPIPE=0;
16389 GNULIB_UNLINK=0;
16390 GNULIB_UNLINKAT=0;
16391 GNULIB_USLEEP=0;
16392 GNULIB_WRITE=0;
16393 HAVE_CHOWN=1;
16394 HAVE_DUP2=1;
16395 HAVE_DUP3=1;
16396 HAVE_EUIDACCESS=1;
16397 HAVE_FACCESSAT=1;
16398 HAVE_FCHDIR=1;
16399 HAVE_FCHOWNAT=1;
16400 HAVE_FDATASYNC=1;
16401 HAVE_FSYNC=1;
16402 HAVE_FTRUNCATE=1;
16403 HAVE_GETDTABLESIZE=1;
16404 HAVE_GETGROUPS=1;
16405 HAVE_GETHOSTNAME=1;
16406 HAVE_GETLOGIN=1;
16407 HAVE_GETPAGESIZE=1;
16408 HAVE_GROUP_MEMBER=1;
16409 HAVE_LCHOWN=1;
16410 HAVE_LINK=1;
16411 HAVE_LINKAT=1;
16412 HAVE_PIPE=1;
16413 HAVE_PIPE2=1;
16414 HAVE_PREAD=1;
16415 HAVE_PWRITE=1;
16416 HAVE_READLINK=1;
16417 HAVE_READLINKAT=1;
16418 HAVE_SETHOSTNAME=1;
16419 HAVE_SLEEP=1;
16420 HAVE_SYMLINK=1;
16421 HAVE_SYMLINKAT=1;
16422 HAVE_UNLINKAT=1;
16423 HAVE_USLEEP=1;
16424 HAVE_DECL_ENVIRON=1;
16425 HAVE_DECL_FCHDIR=1;
16426 HAVE_DECL_FDATASYNC=1;
16427 HAVE_DECL_GETDOMAINNAME=1;
16428 HAVE_DECL_GETLOGIN_R=1;
16429 HAVE_DECL_GETPAGESIZE=1;
16430 HAVE_DECL_GETUSERSHELL=1;
16431 HAVE_DECL_SETHOSTNAME=1;
16432 HAVE_DECL_TTYNAME_R=1;
16433 HAVE_OS_H=0;
16434 HAVE_SYS_PARAM_H=0;
16435 REPLACE_CHOWN=0;
16436 REPLACE_CLOSE=0;
16437 REPLACE_DUP=0;
16438 REPLACE_DUP2=0;
16439 REPLACE_FCHOWNAT=0;
16440 REPLACE_FTRUNCATE=0;
16441 REPLACE_GETCWD=0;
16442 REPLACE_GETDOMAINNAME=0;
16443 REPLACE_GETLOGIN_R=0;
16444 REPLACE_GETGROUPS=0;
16445 REPLACE_GETPAGESIZE=0;
16446 REPLACE_ISATTY=0;
16447 REPLACE_LCHOWN=0;
16448 REPLACE_LINK=0;
16449 REPLACE_LINKAT=0;
16450 REPLACE_LSEEK=0;
16451 REPLACE_PREAD=0;
16452 REPLACE_PWRITE=0;
16453 REPLACE_READ=0;
16454 REPLACE_READLINK=0;
16455 REPLACE_RMDIR=0;
16456 REPLACE_SLEEP=0;
16457 REPLACE_SYMLINK=0;
16458 REPLACE_TTYNAME_R=0;
16459 REPLACE_UNLINK=0;
16460 REPLACE_UNLINKAT=0;
16461 REPLACE_USLEEP=0;
16462 REPLACE_WRITE=0;
16463 UNISTD_H_HAVE_WINSOCK2_H=0;
16464 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16475 $as_echo_n "checking if environ is properly declared... " >&6; }
16476 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16477 $as_echo_n "(cached) " >&6
16478 else
16480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16481 /* end confdefs.h. */
16482 #if HAVE_UNISTD_H
16483 #include <unistd.h>
16484 #endif
16485 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16486 #include <stdlib.h>
16488 extern struct { int foo; } environ;
16490 main ()
16492 environ.foo = 1;
16494 return 0;
16496 _ACEOF
16497 if ac_fn_c_try_compile "$LINENO"; then :
16498 gt_cv_var_environ_declaration=no
16499 else
16500 gt_cv_var_environ_declaration=yes
16502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16506 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16507 if test $gt_cv_var_environ_declaration = yes; then
16509 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16514 if test $gt_cv_var_environ_declaration != yes; then
16515 HAVE_DECL_ENVIRON=0
16524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16525 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16526 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16527 $as_echo_n "(cached) " >&6
16528 else
16529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16530 /* end confdefs.h. */
16532 #include <sys/types.h>
16533 #include <sys/stat.h>
16535 main ()
16537 struct stat s; s.st_dm_mode;
16539 return 0;
16541 _ACEOF
16542 if ac_fn_c_try_compile "$LINENO"; then :
16543 ac_cv_struct_st_dm_mode=yes
16544 else
16545 ac_cv_struct_st_dm_mode=no
16547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16550 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16552 if test $ac_cv_struct_st_dm_mode = yes; then
16554 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16559 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16560 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16561 ac_have_decl=1
16562 else
16563 ac_have_decl=0
16566 cat >>confdefs.h <<_ACEOF
16567 #define HAVE_DECL_STRMODE $ac_have_decl
16568 _ACEOF
16571 GNULIB__EXIT=0;
16572 GNULIB_ATOLL=0;
16573 GNULIB_CALLOC_POSIX=0;
16574 GNULIB_CANONICALIZE_FILE_NAME=0;
16575 GNULIB_GETLOADAVG=0;
16576 GNULIB_GETSUBOPT=0;
16577 GNULIB_GRANTPT=0;
16578 GNULIB_MALLOC_POSIX=0;
16579 GNULIB_MBTOWC=0;
16580 GNULIB_MKDTEMP=0;
16581 GNULIB_MKOSTEMP=0;
16582 GNULIB_MKOSTEMPS=0;
16583 GNULIB_MKSTEMP=0;
16584 GNULIB_MKSTEMPS=0;
16585 GNULIB_POSIX_OPENPT=0;
16586 GNULIB_PTSNAME=0;
16587 GNULIB_PTSNAME_R=0;
16588 GNULIB_PUTENV=0;
16589 GNULIB_RANDOM=0;
16590 GNULIB_RANDOM_R=0;
16591 GNULIB_REALLOC_POSIX=0;
16592 GNULIB_REALPATH=0;
16593 GNULIB_RPMATCH=0;
16594 GNULIB_SETENV=0;
16595 GNULIB_STRTOD=0;
16596 GNULIB_STRTOLL=0;
16597 GNULIB_STRTOULL=0;
16598 GNULIB_SYSTEM_POSIX=0;
16599 GNULIB_UNLOCKPT=0;
16600 GNULIB_UNSETENV=0;
16601 GNULIB_WCTOMB=0;
16602 HAVE__EXIT=1;
16603 HAVE_ATOLL=1;
16604 HAVE_CANONICALIZE_FILE_NAME=1;
16605 HAVE_DECL_GETLOADAVG=1;
16606 HAVE_GETSUBOPT=1;
16607 HAVE_GRANTPT=1;
16608 HAVE_MKDTEMP=1;
16609 HAVE_MKOSTEMP=1;
16610 HAVE_MKOSTEMPS=1;
16611 HAVE_MKSTEMP=1;
16612 HAVE_MKSTEMPS=1;
16613 HAVE_POSIX_OPENPT=1;
16614 HAVE_PTSNAME=1;
16615 HAVE_PTSNAME_R=1;
16616 HAVE_RANDOM=1;
16617 HAVE_RANDOM_H=1;
16618 HAVE_RANDOM_R=1;
16619 HAVE_REALPATH=1;
16620 HAVE_RPMATCH=1;
16621 HAVE_SETENV=1;
16622 HAVE_DECL_SETENV=1;
16623 HAVE_STRTOD=1;
16624 HAVE_STRTOLL=1;
16625 HAVE_STRTOULL=1;
16626 HAVE_STRUCT_RANDOM_DATA=1;
16627 HAVE_SYS_LOADAVG_H=0;
16628 HAVE_UNLOCKPT=1;
16629 HAVE_DECL_UNSETENV=1;
16630 REPLACE_CALLOC=0;
16631 REPLACE_CANONICALIZE_FILE_NAME=0;
16632 REPLACE_MALLOC=0;
16633 REPLACE_MBTOWC=0;
16634 REPLACE_MKSTEMP=0;
16635 REPLACE_PTSNAME_R=0;
16636 REPLACE_PUTENV=0;
16637 REPLACE_RANDOM_R=0;
16638 REPLACE_REALLOC=0;
16639 REPLACE_REALPATH=0;
16640 REPLACE_SETENV=0;
16641 REPLACE_STRTOD=0;
16642 REPLACE_UNSETENV=0;
16643 REPLACE_WCTOMB=0;
16647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16648 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16649 if test "${gl_cv_have_include_next+set}" = set; then :
16650 $as_echo_n "(cached) " >&6
16651 else
16652 rm -rf conftestd1a conftestd1b conftestd2
16653 mkdir conftestd1a conftestd1b conftestd2
16654 cat <<EOF > conftestd1a/conftest.h
16655 #define DEFINED_IN_CONFTESTD1
16656 #include_next <conftest.h>
16657 #ifdef DEFINED_IN_CONFTESTD2
16658 int foo;
16659 #else
16660 #error "include_next doesn't work"
16661 #endif
16663 cat <<EOF > conftestd1b/conftest.h
16664 #define DEFINED_IN_CONFTESTD1
16665 #include <stdio.h>
16666 #include_next <conftest.h>
16667 #ifdef DEFINED_IN_CONFTESTD2
16668 int foo;
16669 #else
16670 #error "include_next doesn't work"
16671 #endif
16673 cat <<EOF > conftestd2/conftest.h
16674 #ifndef DEFINED_IN_CONFTESTD1
16675 #error "include_next test doesn't work"
16676 #endif
16677 #define DEFINED_IN_CONFTESTD2
16679 gl_save_CPPFLAGS="$CPPFLAGS"
16680 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16682 /* end confdefs.h. */
16683 #include <conftest.h>
16684 _ACEOF
16685 if ac_fn_c_try_compile "$LINENO"; then :
16686 gl_cv_have_include_next=yes
16687 else
16688 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16690 /* end confdefs.h. */
16691 #include <conftest.h>
16692 _ACEOF
16693 if ac_fn_c_try_compile "$LINENO"; then :
16694 gl_cv_have_include_next=buggy
16695 else
16696 gl_cv_have_include_next=no
16698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16701 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16702 CPPFLAGS="$gl_save_CPPFLAGS"
16703 rm -rf conftestd1a conftestd1b conftestd2
16706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16707 $as_echo "$gl_cv_have_include_next" >&6; }
16708 PRAGMA_SYSTEM_HEADER=
16709 if test $gl_cv_have_include_next = yes; then
16710 INCLUDE_NEXT=include_next
16711 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16712 if test -n "$GCC"; then
16713 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16715 else
16716 if test $gl_cv_have_include_next = buggy; then
16717 INCLUDE_NEXT=include
16718 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16719 else
16720 INCLUDE_NEXT=include
16721 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16728 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16729 if test "${gl_cv_pragma_columns+set}" = set; then :
16730 $as_echo_n "(cached) " >&6
16731 else
16732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16733 /* end confdefs.h. */
16735 #ifdef __TANDEM
16736 choke me
16737 #endif
16739 _ACEOF
16740 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16741 $EGREP "choke me" >/dev/null 2>&1; then :
16742 gl_cv_pragma_columns=yes
16743 else
16744 gl_cv_pragma_columns=no
16746 rm -f conftest*
16750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16751 $as_echo "$gl_cv_pragma_columns" >&6; }
16752 if test $gl_cv_pragma_columns = yes; then
16753 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16754 else
16755 PRAGMA_COLUMNS=
16774 if test $gl_cv_have_include_next = yes; then
16775 gl_cv_next_getopt_h='<'getopt.h'>'
16776 else
16777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16778 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
16779 if test "${gl_cv_next_getopt_h+set}" = set; then :
16780 $as_echo_n "(cached) " >&6
16781 else
16783 if test $ac_cv_header_getopt_h = yes; then
16786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16787 /* end confdefs.h. */
16788 #include <getopt.h>
16790 _ACEOF
16791 case "$host_os" in
16792 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16793 *) gl_absname_cpp="$ac_cpp" ;;
16794 esac
16796 case "$host_os" in
16797 mingw*)
16798 gl_dirsep_regex='[/\\]'
16801 gl_dirsep_regex='\/'
16803 esac
16804 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16806 gl_header_literal_regex=`echo 'getopt.h' \
16807 | sed -e "$gl_make_literal_regex_sed"`
16808 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16809 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16810 s|^/[^/]|//&|
16814 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16815 sed -n "$gl_absolute_header_sed"`'"'
16816 else
16817 gl_cv_next_getopt_h='<'getopt.h'>'
16822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
16823 $as_echo "$gl_cv_next_getopt_h" >&6; }
16825 NEXT_GETOPT_H=$gl_cv_next_getopt_h
16827 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16828 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16829 gl_next_as_first_directive='<'getopt.h'>'
16830 else
16831 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16832 gl_next_as_first_directive=$gl_cv_next_getopt_h
16834 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
16839 if test $ac_cv_header_getopt_h = yes; then
16840 HAVE_GETOPT_H=1
16841 else
16842 HAVE_GETOPT_H=0
16846 gl_replace_getopt=
16848 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16849 for ac_header in getopt.h
16850 do :
16851 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
16852 if test "x$ac_cv_header_getopt_h" = x""yes; then :
16853 cat >>confdefs.h <<_ACEOF
16854 #define HAVE_GETOPT_H 1
16855 _ACEOF
16857 else
16858 gl_replace_getopt=yes
16861 done
16865 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16866 for ac_func in getopt_long_only
16867 do :
16868 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
16869 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
16870 cat >>confdefs.h <<_ACEOF
16871 #define HAVE_GETOPT_LONG_ONLY 1
16872 _ACEOF
16874 else
16875 gl_replace_getopt=yes
16877 done
16881 if test -z "$gl_replace_getopt"; then
16882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
16883 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
16884 if test "${gl_cv_func_getopt_posix+set}" = set; then :
16885 $as_echo_n "(cached) " >&6
16886 else
16888 if test $cross_compiling = no; then
16889 if test "$cross_compiling" = yes; then :
16890 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16891 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16892 as_fn_error "cannot run test program while cross compiling
16893 See \`config.log' for more details." "$LINENO" 5; }
16894 else
16895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16896 /* end confdefs.h. */
16898 #include <unistd.h>
16899 #include <stdlib.h>
16900 #include <string.h>
16903 main ()
16905 static char program[] = "program";
16906 static char a[] = "-a";
16907 static char foo[] = "foo";
16908 static char bar[] = "bar";
16909 char *argv[] = { program, a, foo, bar, NULL };
16910 int c;
16912 c = getopt (4, argv, "ab");
16913 if (!(c == 'a'))
16914 return 1;
16915 c = getopt (4, argv, "ab");
16916 if (!(c == -1))
16917 return 2;
16918 if (!(optind == 2))
16919 return 3;
16920 return 0;
16923 _ACEOF
16924 if ac_fn_c_try_run "$LINENO"; then :
16925 gl_cv_func_getopt_posix=maybe
16926 else
16927 gl_cv_func_getopt_posix=no
16929 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16930 conftest.$ac_objext conftest.beam conftest.$ac_ext
16933 if test $gl_cv_func_getopt_posix = maybe; then
16934 if test "$cross_compiling" = yes; then :
16935 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16936 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16937 as_fn_error "cannot run test program while cross compiling
16938 See \`config.log' for more details." "$LINENO" 5; }
16939 else
16940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16941 /* end confdefs.h. */
16943 #include <unistd.h>
16944 #include <stdlib.h>
16945 #include <string.h>
16948 main ()
16950 static char program[] = "program";
16951 static char donald[] = "donald";
16952 static char p[] = "-p";
16953 static char billy[] = "billy";
16954 static char duck[] = "duck";
16955 static char a[] = "-a";
16956 static char bar[] = "bar";
16957 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
16958 int c;
16960 c = getopt (7, argv, "+abp:q:");
16961 if (!(c == -1))
16962 return 4;
16963 if (!(strcmp (argv[0], "program") == 0))
16964 return 5;
16965 if (!(strcmp (argv[1], "donald") == 0))
16966 return 6;
16967 if (!(strcmp (argv[2], "-p") == 0))
16968 return 7;
16969 if (!(strcmp (argv[3], "billy") == 0))
16970 return 8;
16971 if (!(strcmp (argv[4], "duck") == 0))
16972 return 9;
16973 if (!(strcmp (argv[5], "-a") == 0))
16974 return 10;
16975 if (!(strcmp (argv[6], "bar") == 0))
16976 return 11;
16977 if (!(optind == 1))
16978 return 12;
16979 return 0;
16982 _ACEOF
16983 if ac_fn_c_try_run "$LINENO"; then :
16984 gl_cv_func_getopt_posix=maybe
16985 else
16986 gl_cv_func_getopt_posix=no
16988 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16989 conftest.$ac_objext conftest.beam conftest.$ac_ext
16993 if test $gl_cv_func_getopt_posix = maybe; then
16994 if test "$cross_compiling" = yes; then :
16995 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16996 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16997 as_fn_error "cannot run test program while cross compiling
16998 See \`config.log' for more details." "$LINENO" 5; }
16999 else
17000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17001 /* end confdefs.h. */
17003 #include <unistd.h>
17004 #include <stdlib.h>
17005 #include <string.h>
17008 main ()
17010 static char program[] = "program";
17011 static char ab[] = "-ab";
17012 char *argv[3] = { program, ab, NULL };
17013 if (getopt (2, argv, "ab:") != 'a')
17014 return 13;
17015 if (getopt (2, argv, "ab:") != '?')
17016 return 14;
17017 if (optopt != 'b')
17018 return 15;
17019 if (optind != 2)
17020 return 16;
17021 return 0;
17024 _ACEOF
17025 if ac_fn_c_try_run "$LINENO"; then :
17026 gl_cv_func_getopt_posix=yes
17027 else
17028 gl_cv_func_getopt_posix=no
17030 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17031 conftest.$ac_objext conftest.beam conftest.$ac_ext
17035 else
17036 case "$host_os" in
17037 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17038 *) gl_cv_func_getopt_posix="guessing yes";;
17039 esac
17043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17044 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17045 case "$gl_cv_func_getopt_posix" in
17046 *no) gl_replace_getopt=yes ;;
17047 esac
17050 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17052 $as_echo_n "checking for working GNU getopt function... " >&6; }
17053 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17054 $as_echo_n "(cached) " >&6
17055 else
17056 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17057 # optstring is necessary for programs like m4 that have POSIX-mandated
17058 # semantics for supporting options interspersed with files.
17059 # Also, since getopt_long is a GNU extension, we require optind=0.
17060 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17061 # so take care to revert to the correct (non-)export state.
17062 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17063 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17064 xx) gl_had_POSIXLY_CORRECT=exported ;;
17065 x) gl_had_POSIXLY_CORRECT=yes ;;
17066 *) gl_had_POSIXLY_CORRECT= ;;
17067 esac
17068 POSIXLY_CORRECT=1
17069 export POSIXLY_CORRECT
17070 if test "$cross_compiling" = yes; then :
17071 gl_cv_func_getopt_gnu="guessing no"
17073 else
17074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17075 /* end confdefs.h. */
17076 #include <getopt.h>
17077 #include <stddef.h>
17078 #include <string.h>
17080 #include <stdlib.h>
17081 #if defined __MACH__ && defined __APPLE__
17082 /* Avoid a crash on Mac OS X. */
17083 #include <mach/mach.h>
17084 #include <mach/mach_error.h>
17085 #include <mach/thread_status.h>
17086 #include <mach/exception.h>
17087 #include <mach/task.h>
17088 #include <pthread.h>
17089 /* The exception port on which our thread listens. */
17090 static mach_port_t our_exception_port;
17091 /* The main function of the thread listening for exceptions of type
17092 EXC_BAD_ACCESS. */
17093 static void *
17094 mach_exception_thread (void *arg)
17096 /* Buffer for a message to be received. */
17097 struct {
17098 mach_msg_header_t head;
17099 mach_msg_body_t msgh_body;
17100 char data[1024];
17101 } msg;
17102 mach_msg_return_t retval;
17103 /* Wait for a message on the exception port. */
17104 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17105 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17106 if (retval != MACH_MSG_SUCCESS)
17107 abort ();
17108 exit (1);
17110 static void
17111 nocrash_init (void)
17113 mach_port_t self = mach_task_self ();
17114 /* Allocate a port on which the thread shall listen for exceptions. */
17115 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17116 == KERN_SUCCESS) {
17117 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17118 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17119 MACH_MSG_TYPE_MAKE_SEND)
17120 == KERN_SUCCESS) {
17121 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17122 for us. */
17123 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17124 /* Create the thread listening on the exception port. */
17125 pthread_attr_t attr;
17126 pthread_t thread;
17127 if (pthread_attr_init (&attr) == 0
17128 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17129 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17130 pthread_attr_destroy (&attr);
17131 /* Replace the exception port info for these exceptions with our own.
17132 Note that we replace the exception port for the entire task, not only
17133 for a particular thread. This has the effect that when our exception
17134 port gets the message, the thread specific exception port has already
17135 been asked, and we don't need to bother about it.
17136 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17137 task_set_exception_ports (self, mask, our_exception_port,
17138 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17143 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17144 /* Avoid a crash on native Windows. */
17145 #define WIN32_LEAN_AND_MEAN
17146 #include <windows.h>
17147 #include <winerror.h>
17148 static LONG WINAPI
17149 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17151 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17153 case EXCEPTION_ACCESS_VIOLATION:
17154 case EXCEPTION_IN_PAGE_ERROR:
17155 case EXCEPTION_STACK_OVERFLOW:
17156 case EXCEPTION_GUARD_PAGE:
17157 case EXCEPTION_PRIV_INSTRUCTION:
17158 case EXCEPTION_ILLEGAL_INSTRUCTION:
17159 case EXCEPTION_DATATYPE_MISALIGNMENT:
17160 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17161 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17162 exit (1);
17164 return EXCEPTION_CONTINUE_SEARCH;
17166 static void
17167 nocrash_init (void)
17169 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17171 #else
17172 /* Avoid a crash on POSIX systems. */
17173 #include <signal.h>
17174 /* A POSIX signal handler. */
17175 static void
17176 exception_handler (int sig)
17178 exit (1);
17180 static void
17181 nocrash_init (void)
17183 #ifdef SIGSEGV
17184 signal (SIGSEGV, exception_handler);
17185 #endif
17186 #ifdef SIGBUS
17187 signal (SIGBUS, exception_handler);
17188 #endif
17190 #endif
17194 main ()
17197 int result = 0;
17199 nocrash_init();
17201 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17202 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17203 OSF/1 5.1, Solaris 10. */
17205 static char conftest[] = "conftest";
17206 static char plus[] = "-+";
17207 char *argv[3] = { conftest, plus, NULL };
17208 opterr = 0;
17209 if (getopt (2, argv, "+a") != '?')
17210 result |= 1;
17212 /* This code succeeds on glibc 2.8, mingw,
17213 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17214 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17216 static char program[] = "program";
17217 static char p[] = "-p";
17218 static char foo[] = "foo";
17219 static char bar[] = "bar";
17220 char *argv[] = { program, p, foo, bar, NULL };
17222 optind = 1;
17223 if (getopt (4, argv, "p::") != 'p')
17224 result |= 2;
17225 else if (optarg != NULL)
17226 result |= 4;
17227 else if (getopt (4, argv, "p::") != -1)
17228 result |= 6;
17229 else if (optind != 2)
17230 result |= 8;
17232 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17234 static char program[] = "program";
17235 static char foo[] = "foo";
17236 static char p[] = "-p";
17237 char *argv[] = { program, foo, p, NULL };
17238 optind = 0;
17239 if (getopt (3, argv, "-p") != 1)
17240 result |= 16;
17241 else if (getopt (3, argv, "-p") != 'p')
17242 result |= 16;
17244 /* This code fails on glibc 2.11. */
17246 static char program[] = "program";
17247 static char b[] = "-b";
17248 static char a[] = "-a";
17249 char *argv[] = { program, b, a, NULL };
17250 optind = opterr = 0;
17251 if (getopt (3, argv, "+:a:b") != 'b')
17252 result |= 32;
17253 else if (getopt (3, argv, "+:a:b") != ':')
17254 result |= 32;
17256 /* This code dumps core on glibc 2.14. */
17258 static char program[] = "program";
17259 static char w[] = "-W";
17260 static char dummy[] = "dummy";
17261 char *argv[] = { program, w, dummy, NULL };
17262 optind = opterr = 1;
17263 if (getopt (3, argv, "W;") != 'W')
17264 result |= 64;
17266 return result;
17269 return 0;
17271 _ACEOF
17272 if ac_fn_c_try_run "$LINENO"; then :
17273 gl_cv_func_getopt_gnu=yes
17274 else
17275 gl_cv_func_getopt_gnu=no
17277 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17278 conftest.$ac_objext conftest.beam conftest.$ac_ext
17281 case $gl_had_POSIXLY_CORRECT in
17282 exported) ;;
17283 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17284 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17285 esac
17288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17289 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17290 if test "$gl_cv_func_getopt_gnu" != yes; then
17291 gl_replace_getopt=yes
17292 else
17293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17294 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17295 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17296 $as_echo_n "(cached) " >&6
17297 else
17298 if test "$cross_compiling" = yes; then :
17299 case "$host_os" in
17300 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17301 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17302 esac
17304 else
17305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17306 /* end confdefs.h. */
17307 #include <getopt.h>
17308 #include <stddef.h>
17309 #include <string.h>
17312 main ()
17314 static const struct option long_options[] =
17316 { "xtremely-",no_argument, NULL, 1003 },
17317 { "xtra", no_argument, NULL, 1001 },
17318 { "xtreme", no_argument, NULL, 1002 },
17319 { "xtremely", no_argument, NULL, 1003 },
17320 { NULL, 0, NULL, 0 }
17322 /* This code fails on OpenBSD 5.0. */
17324 static char program[] = "program";
17325 static char xtremel[] = "--xtremel";
17326 char *argv[] = { program, xtremel, NULL };
17327 int option_index;
17328 optind = 1; opterr = 0;
17329 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17330 return 1;
17332 return 0;
17335 return 0;
17337 _ACEOF
17338 if ac_fn_c_try_run "$LINENO"; then :
17339 gl_cv_func_getopt_long_gnu=yes
17340 else
17341 gl_cv_func_getopt_long_gnu=no
17343 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17344 conftest.$ac_objext conftest.beam conftest.$ac_ext
17349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17350 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17351 case "$gl_cv_func_getopt_long_gnu" in
17352 *yes) ;;
17353 *) gl_replace_getopt=yes ;;
17354 esac
17363 REPLACE_GETOPT=0
17364 if test -n "$gl_replace_getopt"; then
17365 REPLACE_GETOPT=1
17368 if test $REPLACE_GETOPT = 1; then
17370 GETOPT_H=getopt.h
17372 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17378 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17379 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17380 ac_have_decl=1
17381 else
17382 ac_have_decl=0
17385 cat >>confdefs.h <<_ACEOF
17386 #define HAVE_DECL_GETENV $ac_have_decl
17387 _ACEOF
17394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17395 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17396 if test "${ac_cv_c_restrict+set}" = set; then :
17397 $as_echo_n "(cached) " >&6
17398 else
17399 ac_cv_c_restrict=no
17400 # The order here caters to the fact that C++ does not require restrict.
17401 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17403 /* end confdefs.h. */
17404 typedef int * int_ptr;
17405 int foo (int_ptr $ac_kw ip) {
17406 return ip[0];
17409 main ()
17411 int s[1];
17412 int * $ac_kw t = s;
17413 t[0] = 0;
17414 return foo(t)
17416 return 0;
17418 _ACEOF
17419 if ac_fn_c_try_compile "$LINENO"; then :
17420 ac_cv_c_restrict=$ac_kw
17422 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17423 test "$ac_cv_c_restrict" != no && break
17424 done
17427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17428 $as_echo "$ac_cv_c_restrict" >&6; }
17430 case $ac_cv_c_restrict in
17431 restrict) ;;
17432 no) $as_echo "#define restrict /**/" >>confdefs.h
17434 *) cat >>confdefs.h <<_ACEOF
17435 #define restrict $ac_cv_c_restrict
17436 _ACEOF
17438 esac
17441 GNULIB_GETTIMEOFDAY=0;
17442 HAVE_GETTIMEOFDAY=1;
17443 HAVE_STRUCT_TIMEVAL=1;
17444 HAVE_SYS_TIME_H=1;
17445 REPLACE_GETTIMEOFDAY=0;
17446 REPLACE_STRUCT_TIMEVAL=0;
17463 if test $gl_cv_have_include_next = yes; then
17464 gl_cv_next_sys_time_h='<'sys/time.h'>'
17465 else
17466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17467 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17468 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17469 $as_echo_n "(cached) " >&6
17470 else
17472 if test $ac_cv_header_sys_time_h = yes; then
17475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17476 /* end confdefs.h. */
17477 #include <sys/time.h>
17479 _ACEOF
17480 case "$host_os" in
17481 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17482 *) gl_absname_cpp="$ac_cpp" ;;
17483 esac
17485 case "$host_os" in
17486 mingw*)
17487 gl_dirsep_regex='[/\\]'
17490 gl_dirsep_regex='\/'
17492 esac
17493 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17495 gl_header_literal_regex=`echo 'sys/time.h' \
17496 | sed -e "$gl_make_literal_regex_sed"`
17497 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17498 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17499 s|^/[^/]|//&|
17503 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17504 sed -n "$gl_absolute_header_sed"`'"'
17505 else
17506 gl_cv_next_sys_time_h='<'sys/time.h'>'
17511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17512 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17514 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17516 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17517 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17518 gl_next_as_first_directive='<'sys/time.h'>'
17519 else
17520 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17521 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17523 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17529 if test $ac_cv_header_sys_time_h != yes; then
17530 HAVE_SYS_TIME_H=0
17537 if test $ac_cv_header_sys_socket_h != yes; then
17538 for ac_header in winsock2.h
17539 do :
17540 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17541 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17542 cat >>confdefs.h <<_ACEOF
17543 #define HAVE_WINSOCK2_H 1
17544 _ACEOF
17548 done
17551 if test "$ac_cv_header_winsock2_h" = yes; then
17552 HAVE_WINSOCK2_H=1
17553 UNISTD_H_HAVE_WINSOCK2_H=1
17554 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17555 else
17556 HAVE_WINSOCK2_H=0
17560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17561 $as_echo_n "checking for struct timeval... " >&6; }
17562 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17563 $as_echo_n "(cached) " >&6
17564 else
17565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17566 /* end confdefs.h. */
17567 #if HAVE_SYS_TIME_H
17568 #include <sys/time.h>
17569 #endif
17570 #include <time.h>
17571 #if HAVE_WINSOCK2_H
17572 # include <winsock2.h>
17573 #endif
17576 main ()
17578 static struct timeval x; x.tv_sec = x.tv_usec;
17580 return 0;
17582 _ACEOF
17583 if ac_fn_c_try_compile "$LINENO"; then :
17584 gl_cv_sys_struct_timeval=yes
17585 else
17586 gl_cv_sys_struct_timeval=no
17588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
17592 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
17593 if test $gl_cv_sys_struct_timeval != yes; then
17594 HAVE_STRUCT_TIMEVAL=0
17595 else
17596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
17597 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
17598 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
17599 $as_echo_n "(cached) " >&6
17600 else
17601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17602 /* end confdefs.h. */
17603 #if HAVE_SYS_TIME_H
17604 #include <sys/time.h>
17605 #endif
17606 #include <time.h>
17607 #if HAVE_WINSOCK2_H
17608 # include <winsock2.h>
17609 #endif
17612 main ()
17614 static struct timeval x;
17615 typedef int verify_tv_sec_type[
17616 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
17620 return 0;
17622 _ACEOF
17623 if ac_fn_c_try_compile "$LINENO"; then :
17624 gl_cv_sys_struct_timeval_tv_sec=yes
17625 else
17626 gl_cv_sys_struct_timeval_tv_sec=no
17628 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
17632 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
17633 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
17634 REPLACE_STRUCT_TIMEVAL=1
17644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17645 $as_echo_n "checking for unsigned long long int... " >&6; }
17646 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17647 $as_echo_n "(cached) " >&6
17648 else
17649 ac_cv_type_unsigned_long_long_int=yes
17650 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17652 /* end confdefs.h. */
17654 /* For now, do not test the preprocessor; as of 2007 there are too many
17655 implementations with broken preprocessors. Perhaps this can
17656 be revisited in 2012. In the meantime, code should not expect
17657 #if to work with literals wider than 32 bits. */
17658 /* Test literals. */
17659 long long int ll = 9223372036854775807ll;
17660 long long int nll = -9223372036854775807LL;
17661 unsigned long long int ull = 18446744073709551615ULL;
17662 /* Test constant expressions. */
17663 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17664 ? 1 : -1)];
17665 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17666 ? 1 : -1)];
17667 int i = 63;
17669 main ()
17671 /* Test availability of runtime routines for shift and division. */
17672 long long int llmax = 9223372036854775807ll;
17673 unsigned long long int ullmax = 18446744073709551615ull;
17674 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17675 | (llmax / ll) | (llmax % ll)
17676 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17677 | (ullmax / ull) | (ullmax % ull));
17679 return 0;
17682 _ACEOF
17683 if ac_fn_c_try_link "$LINENO"; then :
17685 else
17686 ac_cv_type_unsigned_long_long_int=no
17688 rm -f core conftest.err conftest.$ac_objext \
17689 conftest$ac_exeext conftest.$ac_ext
17692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17693 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17694 if test $ac_cv_type_unsigned_long_long_int = yes; then
17696 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17703 $as_echo_n "checking for long long int... " >&6; }
17704 if test "${ac_cv_type_long_long_int+set}" = set; then :
17705 $as_echo_n "(cached) " >&6
17706 else
17707 ac_cv_type_long_long_int=yes
17708 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17709 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17710 if test $ac_cv_type_long_long_int = yes; then
17711 if test "$cross_compiling" = yes; then :
17713 else
17714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17715 /* end confdefs.h. */
17716 #include <limits.h>
17717 #ifndef LLONG_MAX
17718 # define HALF \
17719 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17720 # define LLONG_MAX (HALF - 1 + HALF)
17721 #endif
17723 main ()
17725 long long int n = 1;
17726 int i;
17727 for (i = 0; ; i++)
17729 long long int m = n << i;
17730 if (m >> i != n)
17731 return 1;
17732 if (LLONG_MAX / 2 < m)
17733 break;
17735 return 0;
17737 return 0;
17739 _ACEOF
17740 if ac_fn_c_try_run "$LINENO"; then :
17742 else
17743 ac_cv_type_long_long_int=no
17745 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17746 conftest.$ac_objext conftest.beam conftest.$ac_ext
17752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17753 $as_echo "$ac_cv_type_long_long_int" >&6; }
17754 if test $ac_cv_type_long_long_int = yes; then
17756 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
17765 gl_cv_c_multiarch=no
17766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17767 /* end confdefs.h. */
17768 #ifndef __APPLE_CC__
17769 not a universal capable compiler
17770 #endif
17771 typedef int dummy;
17773 _ACEOF
17774 if ac_fn_c_try_compile "$LINENO"; then :
17776 arch=
17777 prev=
17778 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17779 if test -n "$prev"; then
17780 case $word in
17781 i?86 | x86_64 | ppc | ppc64)
17782 if test -z "$arch" || test "$arch" = "$word"; then
17783 arch="$word"
17784 else
17785 gl_cv_c_multiarch=yes
17788 esac
17789 prev=
17790 else
17791 if test "x$word" = "x-arch"; then
17792 prev=arch
17795 done
17798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17799 if test $gl_cv_c_multiarch = yes; then
17800 APPLE_UNIVERSAL_BUILD=1
17801 else
17802 APPLE_UNIVERSAL_BUILD=0
17809 if test $ac_cv_type_long_long_int = yes; then
17810 HAVE_LONG_LONG_INT=1
17811 else
17812 HAVE_LONG_LONG_INT=0
17816 if test $ac_cv_type_unsigned_long_long_int = yes; then
17817 HAVE_UNSIGNED_LONG_LONG_INT=1
17818 else
17819 HAVE_UNSIGNED_LONG_LONG_INT=0
17824 if test $ac_cv_header_wchar_h = yes; then
17825 HAVE_WCHAR_H=1
17826 else
17827 HAVE_WCHAR_H=0
17831 if test $ac_cv_header_inttypes_h = yes; then
17832 HAVE_INTTYPES_H=1
17833 else
17834 HAVE_INTTYPES_H=0
17838 if test $ac_cv_header_sys_types_h = yes; then
17839 HAVE_SYS_TYPES_H=1
17840 else
17841 HAVE_SYS_TYPES_H=0
17854 if test $gl_cv_have_include_next = yes; then
17855 gl_cv_next_stdint_h='<'stdint.h'>'
17856 else
17857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17858 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
17859 if test "${gl_cv_next_stdint_h+set}" = set; then :
17860 $as_echo_n "(cached) " >&6
17861 else
17863 if test $ac_cv_header_stdint_h = yes; then
17866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17867 /* end confdefs.h. */
17868 #include <stdint.h>
17870 _ACEOF
17871 case "$host_os" in
17872 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17873 *) gl_absname_cpp="$ac_cpp" ;;
17874 esac
17876 case "$host_os" in
17877 mingw*)
17878 gl_dirsep_regex='[/\\]'
17881 gl_dirsep_regex='\/'
17883 esac
17884 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17886 gl_header_literal_regex=`echo 'stdint.h' \
17887 | sed -e "$gl_make_literal_regex_sed"`
17888 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17889 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17890 s|^/[^/]|//&|
17894 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17895 sed -n "$gl_absolute_header_sed"`'"'
17896 else
17897 gl_cv_next_stdint_h='<'stdint.h'>'
17902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
17903 $as_echo "$gl_cv_next_stdint_h" >&6; }
17905 NEXT_STDINT_H=$gl_cv_next_stdint_h
17907 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17908 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17909 gl_next_as_first_directive='<'stdint.h'>'
17910 else
17911 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17912 gl_next_as_first_directive=$gl_cv_next_stdint_h
17914 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
17919 if test $ac_cv_header_stdint_h = yes; then
17920 HAVE_STDINT_H=1
17921 else
17922 HAVE_STDINT_H=0
17926 if test $ac_cv_header_stdint_h = yes; then
17927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
17928 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
17929 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
17930 $as_echo_n "(cached) " >&6
17931 else
17932 gl_cv_header_working_stdint_h=no
17933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17934 /* end confdefs.h. */
17937 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17938 #include <stdint.h>
17939 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
17940 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
17941 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
17942 #endif
17945 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17946 included before <wchar.h>. */
17947 #include <stddef.h>
17948 #include <signal.h>
17949 #if HAVE_WCHAR_H
17950 # include <stdio.h>
17951 # include <time.h>
17952 # include <wchar.h>
17953 #endif
17956 #ifdef INT8_MAX
17957 int8_t a1 = INT8_MAX;
17958 int8_t a1min = INT8_MIN;
17959 #endif
17960 #ifdef INT16_MAX
17961 int16_t a2 = INT16_MAX;
17962 int16_t a2min = INT16_MIN;
17963 #endif
17964 #ifdef INT32_MAX
17965 int32_t a3 = INT32_MAX;
17966 int32_t a3min = INT32_MIN;
17967 #endif
17968 #ifdef INT64_MAX
17969 int64_t a4 = INT64_MAX;
17970 int64_t a4min = INT64_MIN;
17971 #endif
17972 #ifdef UINT8_MAX
17973 uint8_t b1 = UINT8_MAX;
17974 #else
17975 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
17976 #endif
17977 #ifdef UINT16_MAX
17978 uint16_t b2 = UINT16_MAX;
17979 #endif
17980 #ifdef UINT32_MAX
17981 uint32_t b3 = UINT32_MAX;
17982 #endif
17983 #ifdef UINT64_MAX
17984 uint64_t b4 = UINT64_MAX;
17985 #endif
17986 int_least8_t c1 = INT8_C (0x7f);
17987 int_least8_t c1max = INT_LEAST8_MAX;
17988 int_least8_t c1min = INT_LEAST8_MIN;
17989 int_least16_t c2 = INT16_C (0x7fff);
17990 int_least16_t c2max = INT_LEAST16_MAX;
17991 int_least16_t c2min = INT_LEAST16_MIN;
17992 int_least32_t c3 = INT32_C (0x7fffffff);
17993 int_least32_t c3max = INT_LEAST32_MAX;
17994 int_least32_t c3min = INT_LEAST32_MIN;
17995 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
17996 int_least64_t c4max = INT_LEAST64_MAX;
17997 int_least64_t c4min = INT_LEAST64_MIN;
17998 uint_least8_t d1 = UINT8_C (0xff);
17999 uint_least8_t d1max = UINT_LEAST8_MAX;
18000 uint_least16_t d2 = UINT16_C (0xffff);
18001 uint_least16_t d2max = UINT_LEAST16_MAX;
18002 uint_least32_t d3 = UINT32_C (0xffffffff);
18003 uint_least32_t d3max = UINT_LEAST32_MAX;
18004 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18005 uint_least64_t d4max = UINT_LEAST64_MAX;
18006 int_fast8_t e1 = INT_FAST8_MAX;
18007 int_fast8_t e1min = INT_FAST8_MIN;
18008 int_fast16_t e2 = INT_FAST16_MAX;
18009 int_fast16_t e2min = INT_FAST16_MIN;
18010 int_fast32_t e3 = INT_FAST32_MAX;
18011 int_fast32_t e3min = INT_FAST32_MIN;
18012 int_fast64_t e4 = INT_FAST64_MAX;
18013 int_fast64_t e4min = INT_FAST64_MIN;
18014 uint_fast8_t f1 = UINT_FAST8_MAX;
18015 uint_fast16_t f2 = UINT_FAST16_MAX;
18016 uint_fast32_t f3 = UINT_FAST32_MAX;
18017 uint_fast64_t f4 = UINT_FAST64_MAX;
18018 #ifdef INTPTR_MAX
18019 intptr_t g = INTPTR_MAX;
18020 intptr_t gmin = INTPTR_MIN;
18021 #endif
18022 #ifdef UINTPTR_MAX
18023 uintptr_t h = UINTPTR_MAX;
18024 #endif
18025 intmax_t i = INTMAX_MAX;
18026 uintmax_t j = UINTMAX_MAX;
18028 #include <limits.h> /* for CHAR_BIT */
18029 #define TYPE_MINIMUM(t) \
18030 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18031 #define TYPE_MAXIMUM(t) \
18032 ((t) ((t) 0 < (t) -1 \
18033 ? (t) -1 \
18034 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18035 struct s {
18036 int check_PTRDIFF:
18037 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18038 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18039 ? 1 : -1;
18040 /* Detect bug in FreeBSD 6.0 / ia64. */
18041 int check_SIG_ATOMIC:
18042 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18043 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18044 ? 1 : -1;
18045 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18046 int check_WCHAR:
18047 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18048 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18049 ? 1 : -1;
18050 /* Detect bug in mingw. */
18051 int check_WINT:
18052 WINT_MIN == TYPE_MINIMUM (wint_t)
18053 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18054 ? 1 : -1;
18056 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18057 int check_UINT8_C:
18058 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18059 int check_UINT16_C:
18060 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18062 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18063 #ifdef UINT8_MAX
18064 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18065 #endif
18066 #ifdef UINT16_MAX
18067 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18068 #endif
18069 #ifdef UINT32_MAX
18070 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18071 #endif
18072 #ifdef UINT64_MAX
18073 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18074 #endif
18075 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18076 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18077 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18078 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18079 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18080 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18081 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18082 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18083 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18084 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18085 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18089 main ()
18093 return 0;
18095 _ACEOF
18096 if ac_fn_c_try_compile "$LINENO"; then :
18097 if test "$cross_compiling" = yes; then :
18098 gl_cv_header_working_stdint_h=yes
18100 else
18101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18102 /* end confdefs.h. */
18105 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18106 #include <stdint.h>
18109 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18110 included before <wchar.h>. */
18111 #include <stddef.h>
18112 #include <signal.h>
18113 #if HAVE_WCHAR_H
18114 # include <stdio.h>
18115 # include <time.h>
18116 # include <wchar.h>
18117 #endif
18120 #include <stdio.h>
18121 #include <string.h>
18122 #define MVAL(macro) MVAL1(macro)
18123 #define MVAL1(expression) #expression
18124 static const char *macro_values[] =
18126 #ifdef INT8_MAX
18127 MVAL (INT8_MAX),
18128 #endif
18129 #ifdef INT16_MAX
18130 MVAL (INT16_MAX),
18131 #endif
18132 #ifdef INT32_MAX
18133 MVAL (INT32_MAX),
18134 #endif
18135 #ifdef INT64_MAX
18136 MVAL (INT64_MAX),
18137 #endif
18138 #ifdef UINT8_MAX
18139 MVAL (UINT8_MAX),
18140 #endif
18141 #ifdef UINT16_MAX
18142 MVAL (UINT16_MAX),
18143 #endif
18144 #ifdef UINT32_MAX
18145 MVAL (UINT32_MAX),
18146 #endif
18147 #ifdef UINT64_MAX
18148 MVAL (UINT64_MAX),
18149 #endif
18150 NULL
18154 main ()
18157 const char **mv;
18158 for (mv = macro_values; *mv != NULL; mv++)
18160 const char *value = *mv;
18161 /* Test whether it looks like a cast expression. */
18162 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18163 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18164 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18165 || strncmp (value, "((int)"/*)*/, 6) == 0
18166 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18167 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18168 return mv - macro_values + 1;
18170 return 0;
18173 return 0;
18175 _ACEOF
18176 if ac_fn_c_try_run "$LINENO"; then :
18177 gl_cv_header_working_stdint_h=yes
18179 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18180 conftest.$ac_objext conftest.beam conftest.$ac_ext
18185 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18189 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18191 if test "$gl_cv_header_working_stdint_h" = yes; then
18192 STDINT_H=
18193 else
18194 for ac_header in sys/inttypes.h sys/bitypes.h
18195 do :
18196 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18197 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18198 eval as_val=\$$as_ac_Header
18199 if test "x$as_val" = x""yes; then :
18200 cat >>confdefs.h <<_ACEOF
18201 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18202 _ACEOF
18206 done
18208 if test $ac_cv_header_sys_inttypes_h = yes; then
18209 HAVE_SYS_INTTYPES_H=1
18210 else
18211 HAVE_SYS_INTTYPES_H=0
18214 if test $ac_cv_header_sys_bitypes_h = yes; then
18215 HAVE_SYS_BITYPES_H=1
18216 else
18217 HAVE_SYS_BITYPES_H=0
18223 if test $APPLE_UNIVERSAL_BUILD = 0; then
18226 for gltype in ptrdiff_t size_t ; do
18227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18228 $as_echo_n "checking for bit size of $gltype... " >&6; }
18229 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18230 $as_echo_n "(cached) " >&6
18231 else
18232 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18233 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18234 included before <wchar.h>. */
18235 #include <stddef.h>
18236 #include <signal.h>
18237 #if HAVE_WCHAR_H
18238 # include <stdio.h>
18239 # include <time.h>
18240 # include <wchar.h>
18241 #endif
18243 #include <limits.h>"; then :
18245 else
18246 result=unknown
18249 eval gl_cv_bitsizeof_${gltype}=\$result
18252 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18254 $as_echo "$ac_res" >&6; }
18255 eval result=\$gl_cv_bitsizeof_${gltype}
18256 if test $result = unknown; then
18257 result=0
18259 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18260 cat >>confdefs.h <<_ACEOF
18261 #define BITSIZEOF_${GLTYPE} $result
18262 _ACEOF
18264 eval BITSIZEOF_${GLTYPE}=\$result
18265 done
18271 for gltype in sig_atomic_t wchar_t wint_t ; do
18272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18273 $as_echo_n "checking for bit size of $gltype... " >&6; }
18274 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18275 $as_echo_n "(cached) " >&6
18276 else
18277 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18278 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18279 included before <wchar.h>. */
18280 #include <stddef.h>
18281 #include <signal.h>
18282 #if HAVE_WCHAR_H
18283 # include <stdio.h>
18284 # include <time.h>
18285 # include <wchar.h>
18286 #endif
18288 #include <limits.h>"; then :
18290 else
18291 result=unknown
18294 eval gl_cv_bitsizeof_${gltype}=\$result
18297 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18299 $as_echo "$ac_res" >&6; }
18300 eval result=\$gl_cv_bitsizeof_${gltype}
18301 if test $result = unknown; then
18302 result=0
18304 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18305 cat >>confdefs.h <<_ACEOF
18306 #define BITSIZEOF_${GLTYPE} $result
18307 _ACEOF
18309 eval BITSIZEOF_${GLTYPE}=\$result
18310 done
18315 for gltype in sig_atomic_t wchar_t wint_t ; do
18316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18317 $as_echo_n "checking whether $gltype is signed... " >&6; }
18318 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18319 $as_echo_n "(cached) " >&6
18320 else
18321 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18322 /* end confdefs.h. */
18324 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18325 included before <wchar.h>. */
18326 #include <stddef.h>
18327 #include <signal.h>
18328 #if HAVE_WCHAR_H
18329 # include <stdio.h>
18330 # include <time.h>
18331 # include <wchar.h>
18332 #endif
18334 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18336 main ()
18340 return 0;
18342 _ACEOF
18343 if ac_fn_c_try_compile "$LINENO"; then :
18344 result=yes
18345 else
18346 result=no
18348 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18349 eval gl_cv_type_${gltype}_signed=\$result
18352 eval ac_res=\$gl_cv_type_${gltype}_signed
18353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18354 $as_echo "$ac_res" >&6; }
18355 eval result=\$gl_cv_type_${gltype}_signed
18356 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18357 if test "$result" = yes; then
18358 cat >>confdefs.h <<_ACEOF
18359 #define HAVE_SIGNED_${GLTYPE} 1
18360 _ACEOF
18362 eval HAVE_SIGNED_${GLTYPE}=1
18363 else
18364 eval HAVE_SIGNED_${GLTYPE}=0
18366 done
18369 gl_cv_type_ptrdiff_t_signed=yes
18370 gl_cv_type_size_t_signed=no
18371 if test $APPLE_UNIVERSAL_BUILD = 0; then
18374 for gltype in ptrdiff_t size_t ; do
18375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18376 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18377 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18378 $as_echo_n "(cached) " >&6
18379 else
18380 eval gl_cv_type_${gltype}_suffix=no
18381 eval result=\$gl_cv_type_${gltype}_signed
18382 if test "$result" = yes; then
18383 glsufu=
18384 else
18385 glsufu=u
18387 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18388 case $glsuf in
18389 '') gltype1='int';;
18390 l) gltype1='long int';;
18391 ll) gltype1='long long int';;
18392 i64) gltype1='__int64';;
18393 u) gltype1='unsigned int';;
18394 ul) gltype1='unsigned long int';;
18395 ull) gltype1='unsigned long long int';;
18396 ui64)gltype1='unsigned __int64';;
18397 esac
18398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18399 /* end confdefs.h. */
18401 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18402 included before <wchar.h>. */
18403 #include <stddef.h>
18404 #include <signal.h>
18405 #if HAVE_WCHAR_H
18406 # include <stdio.h>
18407 # include <time.h>
18408 # include <wchar.h>
18409 #endif
18411 extern $gltype foo;
18412 extern $gltype1 foo;
18414 main ()
18418 return 0;
18420 _ACEOF
18421 if ac_fn_c_try_compile "$LINENO"; then :
18422 eval gl_cv_type_${gltype}_suffix=\$glsuf
18424 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18425 eval result=\$gl_cv_type_${gltype}_suffix
18426 test "$result" != no && break
18427 done
18429 eval ac_res=\$gl_cv_type_${gltype}_suffix
18430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18431 $as_echo "$ac_res" >&6; }
18432 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18433 eval result=\$gl_cv_type_${gltype}_suffix
18434 test "$result" = no && result=
18435 eval ${GLTYPE}_SUFFIX=\$result
18436 cat >>confdefs.h <<_ACEOF
18437 #define ${GLTYPE}_SUFFIX $result
18438 _ACEOF
18440 done
18446 for gltype in sig_atomic_t wchar_t wint_t ; do
18447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18448 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18449 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18450 $as_echo_n "(cached) " >&6
18451 else
18452 eval gl_cv_type_${gltype}_suffix=no
18453 eval result=\$gl_cv_type_${gltype}_signed
18454 if test "$result" = yes; then
18455 glsufu=
18456 else
18457 glsufu=u
18459 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18460 case $glsuf in
18461 '') gltype1='int';;
18462 l) gltype1='long int';;
18463 ll) gltype1='long long int';;
18464 i64) gltype1='__int64';;
18465 u) gltype1='unsigned int';;
18466 ul) gltype1='unsigned long int';;
18467 ull) gltype1='unsigned long long int';;
18468 ui64)gltype1='unsigned __int64';;
18469 esac
18470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18471 /* end confdefs.h. */
18473 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18474 included before <wchar.h>. */
18475 #include <stddef.h>
18476 #include <signal.h>
18477 #if HAVE_WCHAR_H
18478 # include <stdio.h>
18479 # include <time.h>
18480 # include <wchar.h>
18481 #endif
18483 extern $gltype foo;
18484 extern $gltype1 foo;
18486 main ()
18490 return 0;
18492 _ACEOF
18493 if ac_fn_c_try_compile "$LINENO"; then :
18494 eval gl_cv_type_${gltype}_suffix=\$glsuf
18496 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18497 eval result=\$gl_cv_type_${gltype}_suffix
18498 test "$result" != no && break
18499 done
18501 eval ac_res=\$gl_cv_type_${gltype}_suffix
18502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18503 $as_echo "$ac_res" >&6; }
18504 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18505 eval result=\$gl_cv_type_${gltype}_suffix
18506 test "$result" = no && result=
18507 eval ${GLTYPE}_SUFFIX=\$result
18508 cat >>confdefs.h <<_ACEOF
18509 #define ${GLTYPE}_SUFFIX $result
18510 _ACEOF
18512 done
18516 if test $BITSIZEOF_WINT_T -lt 32; then
18517 BITSIZEOF_WINT_T=32
18520 STDINT_H=stdint.h
18523 if test -n "$STDINT_H"; then
18524 GL_GENERATE_STDINT_H_TRUE=
18525 GL_GENERATE_STDINT_H_FALSE='#'
18526 else
18527 GL_GENERATE_STDINT_H_TRUE='#'
18528 GL_GENERATE_STDINT_H_FALSE=
18535 GNULIB_IMAXABS=0;
18536 GNULIB_IMAXDIV=0;
18537 GNULIB_STRTOIMAX=0;
18538 GNULIB_STRTOUMAX=0;
18539 HAVE_DECL_IMAXABS=1;
18540 HAVE_DECL_IMAXDIV=1;
18541 HAVE_DECL_STRTOIMAX=1;
18542 HAVE_DECL_STRTOUMAX=1;
18543 REPLACE_STRTOIMAX=0;
18544 INT32_MAX_LT_INTMAX_MAX=1;
18545 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18546 PRI_MACROS_BROKEN=0;
18547 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18548 UINT32_MAX_LT_UINTMAX_MAX=1;
18549 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18565 if test $gl_cv_have_include_next = yes; then
18566 gl_cv_next_inttypes_h='<'inttypes.h'>'
18567 else
18568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18569 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18570 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18571 $as_echo_n "(cached) " >&6
18572 else
18574 if test $ac_cv_header_inttypes_h = yes; then
18577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18578 /* end confdefs.h. */
18579 #include <inttypes.h>
18581 _ACEOF
18582 case "$host_os" in
18583 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18584 *) gl_absname_cpp="$ac_cpp" ;;
18585 esac
18587 case "$host_os" in
18588 mingw*)
18589 gl_dirsep_regex='[/\\]'
18592 gl_dirsep_regex='\/'
18594 esac
18595 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18597 gl_header_literal_regex=`echo 'inttypes.h' \
18598 | sed -e "$gl_make_literal_regex_sed"`
18599 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18600 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18601 s|^/[^/]|//&|
18605 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18606 sed -n "$gl_absolute_header_sed"`'"'
18607 else
18608 gl_cv_next_inttypes_h='<'inttypes.h'>'
18613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18614 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18616 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18618 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18619 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18620 gl_next_as_first_directive='<'inttypes.h'>'
18621 else
18622 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18623 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18625 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18637 case "$host_os" in
18638 mingw*)
18639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
18640 $as_echo_n "checking for 64-bit off_t... " >&6; }
18641 if test "${gl_cv_type_off_t_64+set}" = set; then :
18642 $as_echo_n "(cached) " >&6
18643 else
18644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18645 /* end confdefs.h. */
18646 #include <sys/types.h>
18647 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
18650 main ()
18654 return 0;
18656 _ACEOF
18657 if ac_fn_c_try_compile "$LINENO"; then :
18658 gl_cv_type_off_t_64=yes
18659 else
18660 gl_cv_type_off_t_64=no
18662 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
18666 $as_echo "$gl_cv_type_off_t_64" >&6; }
18667 if test $gl_cv_type_off_t_64 = no; then
18668 WINDOWS_64_BIT_OFF_T=1
18669 else
18670 WINDOWS_64_BIT_OFF_T=0
18672 WINDOWS_64_BIT_ST_SIZE=1
18675 WINDOWS_64_BIT_OFF_T=0
18676 WINDOWS_64_BIT_ST_SIZE=0
18678 esac
18681 GNULIB_FCHMODAT=0;
18682 GNULIB_FSTAT=0;
18683 GNULIB_FSTATAT=0;
18684 GNULIB_FUTIMENS=0;
18685 GNULIB_LCHMOD=0;
18686 GNULIB_LSTAT=0;
18687 GNULIB_MKDIRAT=0;
18688 GNULIB_MKFIFO=0;
18689 GNULIB_MKFIFOAT=0;
18690 GNULIB_MKNOD=0;
18691 GNULIB_MKNODAT=0;
18692 GNULIB_STAT=0;
18693 GNULIB_UTIMENSAT=0;
18694 HAVE_FCHMODAT=1;
18695 HAVE_FSTATAT=1;
18696 HAVE_FUTIMENS=1;
18697 HAVE_LCHMOD=1;
18698 HAVE_LSTAT=1;
18699 HAVE_MKDIRAT=1;
18700 HAVE_MKFIFO=1;
18701 HAVE_MKFIFOAT=1;
18702 HAVE_MKNOD=1;
18703 HAVE_MKNODAT=1;
18704 HAVE_UTIMENSAT=1;
18705 REPLACE_FSTAT=0;
18706 REPLACE_FSTATAT=0;
18707 REPLACE_FUTIMENS=0;
18708 REPLACE_LSTAT=0;
18709 REPLACE_MKDIR=0;
18710 REPLACE_MKFIFO=0;
18711 REPLACE_MKNOD=0;
18712 REPLACE_STAT=0;
18713 REPLACE_UTIMENSAT=0;
18718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18719 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18720 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18721 $as_echo_n "(cached) " >&6
18722 else
18723 rm -f conftest.sym conftest.file
18724 echo >conftest.file
18725 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18726 if test "$cross_compiling" = yes; then :
18727 case "$host_os" in
18728 # Guess yes on glibc systems.
18729 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18730 # If we don't know, assume the worst.
18731 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18732 esac
18734 else
18735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18736 /* end confdefs.h. */
18737 $ac_includes_default
18739 main ()
18741 struct stat sbuf;
18742 /* Linux will dereference the symlink and fail, as required by
18743 POSIX. That is better in the sense that it means we will not
18744 have to compile and use the lstat wrapper. */
18745 return lstat ("conftest.sym/", &sbuf) == 0;
18748 return 0;
18750 _ACEOF
18751 if ac_fn_c_try_run "$LINENO"; then :
18752 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18753 else
18754 gl_cv_func_lstat_dereferences_slashed_symlink=no
18756 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18757 conftest.$ac_objext conftest.beam conftest.$ac_ext
18760 else
18761 # If the 'ln -s' command failed, then we probably don't even
18762 # have an lstat function.
18763 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18765 rm -f conftest.sym conftest.file
18768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18769 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18770 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18771 *yes)
18773 cat >>confdefs.h <<_ACEOF
18774 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18775 _ACEOF
18778 esac
18781 GNULIB_MKTIME=0;
18782 GNULIB_NANOSLEEP=0;
18783 GNULIB_STRPTIME=0;
18784 GNULIB_TIMEGM=0;
18785 GNULIB_TIME_R=0;
18786 HAVE_DECL_LOCALTIME_R=1;
18787 HAVE_NANOSLEEP=1;
18788 HAVE_STRPTIME=1;
18789 HAVE_TIMEGM=1;
18790 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18791 REPLACE_MKTIME=GNULIB_PORTCHECK;
18792 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18793 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18798 GNULIB_PSELECT=0;
18799 GNULIB_SELECT=0;
18800 HAVE_PSELECT=1;
18801 REPLACE_PSELECT=0;
18802 REPLACE_SELECT=0;
18809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
18810 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
18811 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
18812 $as_echo_n "(cached) " >&6
18813 else
18815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18816 /* end confdefs.h. */
18817 #include <sys/select.h>
18819 main ()
18821 struct timeval b;
18823 return 0;
18825 _ACEOF
18826 if ac_fn_c_try_compile "$LINENO"; then :
18827 gl_cv_header_sys_select_h_selfcontained=yes
18828 else
18829 gl_cv_header_sys_select_h_selfcontained=no
18831 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18832 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
18833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18834 /* end confdefs.h. */
18835 #include <sys/select.h>
18837 main ()
18839 int memset; int bzero;
18841 return 0;
18844 _ACEOF
18845 if ac_fn_c_try_compile "$LINENO"; then :
18846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18847 /* end confdefs.h. */
18848 #include <sys/select.h>
18850 main ()
18853 #undef memset
18854 #define memset nonexistent_memset
18855 extern
18856 #ifdef __cplusplus
18858 #endif
18859 void *memset (void *, int, unsigned long);
18860 #undef bzero
18861 #define bzero nonexistent_bzero
18862 extern
18863 #ifdef __cplusplus
18865 #endif
18866 void bzero (void *, unsigned long);
18867 fd_set fds;
18868 FD_ZERO (&fds);
18871 return 0;
18874 _ACEOF
18875 if ac_fn_c_try_link "$LINENO"; then :
18877 else
18878 gl_cv_header_sys_select_h_selfcontained=no
18880 rm -f core conftest.err conftest.$ac_objext \
18881 conftest$ac_exeext conftest.$ac_ext
18884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
18889 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
18899 if test $gl_cv_have_include_next = yes; then
18900 gl_cv_next_sys_select_h='<'sys/select.h'>'
18901 else
18902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
18903 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
18904 if test "${gl_cv_next_sys_select_h+set}" = set; then :
18905 $as_echo_n "(cached) " >&6
18906 else
18908 if test $ac_cv_header_sys_select_h = yes; then
18911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18912 /* end confdefs.h. */
18913 #include <sys/select.h>
18915 _ACEOF
18916 case "$host_os" in
18917 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18918 *) gl_absname_cpp="$ac_cpp" ;;
18919 esac
18921 case "$host_os" in
18922 mingw*)
18923 gl_dirsep_regex='[/\\]'
18926 gl_dirsep_regex='\/'
18928 esac
18929 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18931 gl_header_literal_regex=`echo 'sys/select.h' \
18932 | sed -e "$gl_make_literal_regex_sed"`
18933 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18934 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18935 s|^/[^/]|//&|
18939 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18940 sed -n "$gl_absolute_header_sed"`'"'
18941 else
18942 gl_cv_next_sys_select_h='<'sys/select.h'>'
18947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
18948 $as_echo "$gl_cv_next_sys_select_h" >&6; }
18950 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
18952 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18953 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18954 gl_next_as_first_directive='<'sys/select.h'>'
18955 else
18956 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18957 gl_next_as_first_directive=$gl_cv_next_sys_select_h
18959 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
18964 if test $ac_cv_header_sys_select_h = yes; then
18965 HAVE_SYS_SELECT_H=1
18966 else
18967 HAVE_SYS_SELECT_H=0
18974 if test $ac_cv_header_sys_socket_h != yes; then
18975 for ac_header in winsock2.h
18976 do :
18977 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
18978 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
18979 cat >>confdefs.h <<_ACEOF
18980 #define HAVE_WINSOCK2_H 1
18981 _ACEOF
18985 done
18988 if test "$ac_cv_header_winsock2_h" = yes; then
18989 HAVE_WINSOCK2_H=1
18990 UNISTD_H_HAVE_WINSOCK2_H=1
18991 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
18992 else
18993 HAVE_WINSOCK2_H=0
19003 GNULIB_PTHREAD_SIGMASK=0;
19004 GNULIB_RAISE=0;
19005 GNULIB_SIGNAL_H_SIGPIPE=0;
19006 GNULIB_SIGPROCMASK=0;
19007 GNULIB_SIGACTION=0;
19008 HAVE_POSIX_SIGNALBLOCKING=1;
19009 HAVE_PTHREAD_SIGMASK=1;
19010 HAVE_RAISE=1;
19011 HAVE_SIGSET_T=1;
19012 HAVE_SIGINFO_T=1;
19013 HAVE_SIGACTION=1;
19014 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19016 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19018 HAVE_SIGHANDLER_T=1;
19019 REPLACE_PTHREAD_SIGMASK=0;
19020 REPLACE_RAISE=0;
19027 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19028 #include <signal.h>
19029 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19030 #include <sys/types.h>
19033 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19035 cat >>confdefs.h <<_ACEOF
19036 #define HAVE_SIGSET_T 1
19037 _ACEOF
19039 gl_cv_type_sigset_t=yes
19040 else
19041 gl_cv_type_sigset_t=no
19044 if test $gl_cv_type_sigset_t != yes; then
19045 HAVE_SIGSET_T=0
19050 if test $ac_cv_header_sys_socket_h = no; then
19051 for ac_header in ws2tcpip.h
19052 do :
19053 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19054 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19055 cat >>confdefs.h <<_ACEOF
19056 #define HAVE_WS2TCPIP_H 1
19057 _ACEOF
19061 done
19065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19066 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19067 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19068 $as_echo_n "(cached) " >&6
19069 else
19070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19071 /* end confdefs.h. */
19073 #include <stdbool.h>
19074 #ifndef bool
19075 "error: bool is not defined"
19076 #endif
19077 #ifndef false
19078 "error: false is not defined"
19079 #endif
19080 #if false
19081 "error: false is not 0"
19082 #endif
19083 #ifndef true
19084 "error: true is not defined"
19085 #endif
19086 #if true != 1
19087 "error: true is not 1"
19088 #endif
19089 #ifndef __bool_true_false_are_defined
19090 "error: __bool_true_false_are_defined is not defined"
19091 #endif
19093 struct s { _Bool s: 1; _Bool t; } s;
19095 char a[true == 1 ? 1 : -1];
19096 char b[false == 0 ? 1 : -1];
19097 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19098 char d[(bool) 0.5 == true ? 1 : -1];
19099 /* See body of main program for 'e'. */
19100 char f[(_Bool) 0.0 == false ? 1 : -1];
19101 char g[true];
19102 char h[sizeof (_Bool)];
19103 char i[sizeof s.t];
19104 enum { j = false, k = true, l = false * true, m = true * 256 };
19105 /* The following fails for
19106 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19107 _Bool n[m];
19108 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19109 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19110 /* Catch a bug in an HP-UX C compiler. See
19111 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19112 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19114 _Bool q = true;
19115 _Bool *pq = &q;
19118 main ()
19121 bool e = &s;
19122 *pq |= q;
19123 *pq |= ! q;
19124 /* Refer to every declared value, to avoid compiler optimizations. */
19125 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19126 + !m + !n + !o + !p + !q + !pq);
19129 return 0;
19131 _ACEOF
19132 if ac_fn_c_try_compile "$LINENO"; then :
19133 ac_cv_header_stdbool_h=yes
19134 else
19135 ac_cv_header_stdbool_h=no
19137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19140 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19141 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19142 if test "x$ac_cv_type__Bool" = x""yes; then :
19144 cat >>confdefs.h <<_ACEOF
19145 #define HAVE__BOOL 1
19146 _ACEOF
19153 REPLACE_NULL=0;
19154 HAVE_WCHAR_T=1;
19157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19158 $as_echo_n "checking for wchar_t... " >&6; }
19159 if test "${gt_cv_c_wchar_t+set}" = set; then :
19160 $as_echo_n "(cached) " >&6
19161 else
19162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19163 /* end confdefs.h. */
19164 #include <stddef.h>
19165 wchar_t foo = (wchar_t)'\0';
19167 main ()
19171 return 0;
19173 _ACEOF
19174 if ac_fn_c_try_compile "$LINENO"; then :
19175 gt_cv_c_wchar_t=yes
19176 else
19177 gt_cv_c_wchar_t=no
19179 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19182 $as_echo "$gt_cv_c_wchar_t" >&6; }
19183 if test $gt_cv_c_wchar_t = yes; then
19185 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19190 GNULIB_DPRINTF=0;
19191 GNULIB_FCLOSE=0;
19192 GNULIB_FDOPEN=0;
19193 GNULIB_FFLUSH=0;
19194 GNULIB_FGETC=0;
19195 GNULIB_FGETS=0;
19196 GNULIB_FOPEN=0;
19197 GNULIB_FPRINTF=0;
19198 GNULIB_FPRINTF_POSIX=0;
19199 GNULIB_FPURGE=0;
19200 GNULIB_FPUTC=0;
19201 GNULIB_FPUTS=0;
19202 GNULIB_FREAD=0;
19203 GNULIB_FREOPEN=0;
19204 GNULIB_FSCANF=0;
19205 GNULIB_FSEEK=0;
19206 GNULIB_FSEEKO=0;
19207 GNULIB_FTELL=0;
19208 GNULIB_FTELLO=0;
19209 GNULIB_FWRITE=0;
19210 GNULIB_GETC=0;
19211 GNULIB_GETCHAR=0;
19212 GNULIB_GETDELIM=0;
19213 GNULIB_GETLINE=0;
19214 GNULIB_OBSTACK_PRINTF=0;
19215 GNULIB_OBSTACK_PRINTF_POSIX=0;
19216 GNULIB_PCLOSE=0;
19217 GNULIB_PERROR=0;
19218 GNULIB_POPEN=0;
19219 GNULIB_PRINTF=0;
19220 GNULIB_PRINTF_POSIX=0;
19221 GNULIB_PUTC=0;
19222 GNULIB_PUTCHAR=0;
19223 GNULIB_PUTS=0;
19224 GNULIB_REMOVE=0;
19225 GNULIB_RENAME=0;
19226 GNULIB_RENAMEAT=0;
19227 GNULIB_SCANF=0;
19228 GNULIB_SNPRINTF=0;
19229 GNULIB_SPRINTF_POSIX=0;
19230 GNULIB_STDIO_H_NONBLOCKING=0;
19231 GNULIB_STDIO_H_SIGPIPE=0;
19232 GNULIB_TMPFILE=0;
19233 GNULIB_VASPRINTF=0;
19234 GNULIB_VFSCANF=0;
19235 GNULIB_VSCANF=0;
19236 GNULIB_VDPRINTF=0;
19237 GNULIB_VFPRINTF=0;
19238 GNULIB_VFPRINTF_POSIX=0;
19239 GNULIB_VPRINTF=0;
19240 GNULIB_VPRINTF_POSIX=0;
19241 GNULIB_VSNPRINTF=0;
19242 GNULIB_VSPRINTF_POSIX=0;
19243 HAVE_DECL_FPURGE=1;
19244 HAVE_DECL_FSEEKO=1;
19245 HAVE_DECL_FTELLO=1;
19246 HAVE_DECL_GETDELIM=1;
19247 HAVE_DECL_GETLINE=1;
19248 HAVE_DECL_OBSTACK_PRINTF=1;
19249 HAVE_DECL_SNPRINTF=1;
19250 HAVE_DECL_VSNPRINTF=1;
19251 HAVE_DPRINTF=1;
19252 HAVE_FSEEKO=1;
19253 HAVE_FTELLO=1;
19254 HAVE_PCLOSE=1;
19255 HAVE_POPEN=1;
19256 HAVE_RENAMEAT=1;
19257 HAVE_VASPRINTF=1;
19258 HAVE_VDPRINTF=1;
19259 REPLACE_DPRINTF=0;
19260 REPLACE_FCLOSE=0;
19261 REPLACE_FDOPEN=0;
19262 REPLACE_FFLUSH=0;
19263 REPLACE_FOPEN=0;
19264 REPLACE_FPRINTF=0;
19265 REPLACE_FPURGE=0;
19266 REPLACE_FREOPEN=0;
19267 REPLACE_FSEEK=0;
19268 REPLACE_FSEEKO=0;
19269 REPLACE_FTELL=0;
19270 REPLACE_FTELLO=0;
19271 REPLACE_GETDELIM=0;
19272 REPLACE_GETLINE=0;
19273 REPLACE_OBSTACK_PRINTF=0;
19274 REPLACE_PERROR=0;
19275 REPLACE_POPEN=0;
19276 REPLACE_PRINTF=0;
19277 REPLACE_REMOVE=0;
19278 REPLACE_RENAME=0;
19279 REPLACE_RENAMEAT=0;
19280 REPLACE_SNPRINTF=0;
19281 REPLACE_SPRINTF=0;
19282 REPLACE_STDIO_READ_FUNCS=0;
19283 REPLACE_STDIO_WRITE_FUNCS=0;
19284 REPLACE_TMPFILE=0;
19285 REPLACE_VASPRINTF=0;
19286 REPLACE_VDPRINTF=0;
19287 REPLACE_VFPRINTF=0;
19288 REPLACE_VPRINTF=0;
19289 REPLACE_VSNPRINTF=0;
19290 REPLACE_VSPRINTF=0;
19292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19293 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19294 if test "${ac_cv_struct_tm+set}" = set; then :
19295 $as_echo_n "(cached) " >&6
19296 else
19297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19298 /* end confdefs.h. */
19299 #include <sys/types.h>
19300 #include <time.h>
19303 main ()
19305 struct tm tm;
19306 int *p = &tm.tm_sec;
19307 return !p;
19309 return 0;
19311 _ACEOF
19312 if ac_fn_c_try_compile "$LINENO"; then :
19313 ac_cv_struct_tm=time.h
19314 else
19315 ac_cv_struct_tm=sys/time.h
19317 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19320 $as_echo "$ac_cv_struct_tm" >&6; }
19321 if test $ac_cv_struct_tm = sys/time.h; then
19323 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19327 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19328 #include <$ac_cv_struct_tm>
19331 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19333 cat >>confdefs.h <<_ACEOF
19334 #define HAVE_STRUCT_TM_TM_ZONE 1
19335 _ACEOF
19340 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19342 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19344 else
19345 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19347 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19348 ac_have_decl=1
19349 else
19350 ac_have_decl=0
19353 cat >>confdefs.h <<_ACEOF
19354 #define HAVE_DECL_TZNAME $ac_have_decl
19355 _ACEOF
19357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19358 $as_echo_n "checking for tzname... " >&6; }
19359 if test "${ac_cv_var_tzname+set}" = set; then :
19360 $as_echo_n "(cached) " >&6
19361 else
19362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19363 /* end confdefs.h. */
19364 #include <time.h>
19365 #if !HAVE_DECL_TZNAME
19366 extern char *tzname[];
19367 #endif
19370 main ()
19372 return tzname[0][0];
19374 return 0;
19376 _ACEOF
19377 if ac_fn_c_try_link "$LINENO"; then :
19378 ac_cv_var_tzname=yes
19379 else
19380 ac_cv_var_tzname=no
19382 rm -f core conftest.err conftest.$ac_objext \
19383 conftest$ac_exeext conftest.$ac_ext
19385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19386 $as_echo "$ac_cv_var_tzname" >&6; }
19387 if test $ac_cv_var_tzname = yes; then
19389 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19395 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19397 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19399 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19406 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19407 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19408 ac_have_decl=1
19409 else
19410 ac_have_decl=0
19413 cat >>confdefs.h <<_ACEOF
19414 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19415 _ACEOF
19419 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19420 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19421 ac_have_decl=1
19422 else
19423 ac_have_decl=0
19426 cat >>confdefs.h <<_ACEOF
19427 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19428 _ACEOF
19432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19433 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19434 if test "${ac_cv_header_stat_broken+set}" = set; then :
19435 $as_echo_n "(cached) " >&6
19436 else
19437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19438 /* end confdefs.h. */
19439 #include <sys/types.h>
19440 #include <sys/stat.h>
19442 #if defined S_ISBLK && defined S_IFDIR
19443 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19444 #endif
19446 #if defined S_ISBLK && defined S_IFCHR
19447 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19448 #endif
19450 #if defined S_ISLNK && defined S_IFREG
19451 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19452 #endif
19454 #if defined S_ISSOCK && defined S_IFREG
19455 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19456 #endif
19458 _ACEOF
19459 if ac_fn_c_try_compile "$LINENO"; then :
19460 ac_cv_header_stat_broken=no
19461 else
19462 ac_cv_header_stat_broken=yes
19464 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19467 $as_echo "$ac_cv_header_stat_broken" >&6; }
19468 if test $ac_cv_header_stat_broken = yes; then
19470 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19476 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19477 if test "x$ac_cv_type_mode_t" = x""yes; then :
19479 else
19481 cat >>confdefs.h <<_ACEOF
19482 #define mode_t int
19483 _ACEOF
19489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19490 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19491 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19492 $as_echo_n "(cached) " >&6
19493 else
19494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19495 /* end confdefs.h. */
19496 #include <time.h>
19499 main ()
19501 static struct timespec x; x.tv_sec = x.tv_nsec;
19503 return 0;
19505 _ACEOF
19506 if ac_fn_c_try_compile "$LINENO"; then :
19507 gl_cv_sys_struct_timespec_in_time_h=yes
19508 else
19509 gl_cv_sys_struct_timespec_in_time_h=no
19511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19514 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19516 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19517 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19518 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19519 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19520 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19521 else
19522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19523 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19524 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19525 $as_echo_n "(cached) " >&6
19526 else
19527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19528 /* end confdefs.h. */
19529 #include <sys/time.h>
19532 main ()
19534 static struct timespec x; x.tv_sec = x.tv_nsec;
19536 return 0;
19538 _ACEOF
19539 if ac_fn_c_try_compile "$LINENO"; then :
19540 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19541 else
19542 gl_cv_sys_struct_timespec_in_sys_time_h=no
19544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19547 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19548 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19549 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19550 else
19551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19552 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19553 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19554 $as_echo_n "(cached) " >&6
19555 else
19556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19557 /* end confdefs.h. */
19558 #include <pthread.h>
19561 main ()
19563 static struct timespec x; x.tv_sec = x.tv_nsec;
19565 return 0;
19567 _ACEOF
19568 if ac_fn_c_try_compile "$LINENO"; then :
19569 gl_cv_sys_struct_timespec_in_pthread_h=yes
19570 else
19571 gl_cv_sys_struct_timespec_in_pthread_h=no
19573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19576 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19577 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19578 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19597 if test $gl_cv_have_include_next = yes; then
19598 gl_cv_next_time_h='<'time.h'>'
19599 else
19600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19601 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19602 if test "${gl_cv_next_time_h+set}" = set; then :
19603 $as_echo_n "(cached) " >&6
19604 else
19606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19607 /* end confdefs.h. */
19608 #include <time.h>
19610 _ACEOF
19611 case "$host_os" in
19612 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19613 *) gl_absname_cpp="$ac_cpp" ;;
19614 esac
19616 case "$host_os" in
19617 mingw*)
19618 gl_dirsep_regex='[/\\]'
19621 gl_dirsep_regex='\/'
19623 esac
19624 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19626 gl_header_literal_regex=`echo 'time.h' \
19627 | sed -e "$gl_make_literal_regex_sed"`
19628 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19629 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19630 s|^/[^/]|//&|
19634 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19635 sed -n "$gl_absolute_header_sed"`'"'
19639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19640 $as_echo "$gl_cv_next_time_h" >&6; }
19642 NEXT_TIME_H=$gl_cv_next_time_h
19644 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19645 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19646 gl_next_as_first_directive='<'time.h'>'
19647 else
19648 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19649 gl_next_as_first_directive=$gl_cv_next_time_h
19651 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
19668 $as_echo_n "checking whether the utimes function works... " >&6; }
19669 if test "${gl_cv_func_working_utimes+set}" = set; then :
19670 $as_echo_n "(cached) " >&6
19671 else
19673 if test "$cross_compiling" = yes; then :
19674 gl_cv_func_working_utimes=no
19675 else
19676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19677 /* end confdefs.h. */
19679 #include <sys/types.h>
19680 #include <sys/stat.h>
19681 #include <fcntl.h>
19682 #include <sys/time.h>
19683 #include <time.h>
19684 #include <unistd.h>
19685 #include <stdlib.h>
19686 #include <stdio.h>
19687 #include <utime.h>
19689 static int
19690 inorder (time_t a, time_t b, time_t c)
19692 return a <= b && b <= c;
19696 main ()
19698 int result = 0;
19699 char const *file = "conftest.utimes";
19700 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
19702 /* Test whether utimes() essentially works. */
19704 struct stat sbuf;
19705 FILE *f = fopen (file, "w");
19706 if (f == NULL)
19707 result |= 1;
19708 else if (fclose (f) != 0)
19709 result |= 1;
19710 else if (utimes (file, timeval) != 0)
19711 result |= 2;
19712 else if (lstat (file, &sbuf) != 0)
19713 result |= 1;
19714 else if (!(sbuf.st_atime == timeval[0].tv_sec
19715 && sbuf.st_mtime == timeval[1].tv_sec))
19716 result |= 4;
19717 if (unlink (file) != 0)
19718 result |= 1;
19721 /* Test whether utimes() with a NULL argument sets the file's timestamp
19722 to the current time. Use 'fstat' as well as 'time' to
19723 determine the "current" time, to accommodate NFS file systems
19724 if there is a time skew between the host and the NFS server. */
19726 int fd = open (file, O_WRONLY|O_CREAT, 0644);
19727 if (fd < 0)
19728 result |= 1;
19729 else
19731 time_t t0, t2;
19732 struct stat st0, st1, st2;
19733 if (time (&t0) == (time_t) -1)
19734 result |= 1;
19735 else if (fstat (fd, &st0) != 0)
19736 result |= 1;
19737 else if (utimes (file, timeval) != 0)
19738 result |= 2;
19739 else if (utimes (file, NULL) != 0)
19740 result |= 8;
19741 else if (fstat (fd, &st1) != 0)
19742 result |= 1;
19743 else if (write (fd, "\n", 1) != 1)
19744 result |= 1;
19745 else if (fstat (fd, &st2) != 0)
19746 result |= 1;
19747 else if (time (&t2) == (time_t) -1)
19748 result |= 1;
19749 else
19751 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
19752 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
19753 if (! (st1.st_atime == st1.st_mtime))
19754 result |= 16;
19755 if (! (m_ok_POSIX || m_ok_NFS))
19756 result |= 32;
19758 if (close (fd) != 0)
19759 result |= 1;
19761 if (unlink (file) != 0)
19762 result |= 1;
19765 /* Test whether utimes() with a NULL argument works on read-only files. */
19767 int fd = open (file, O_WRONLY|O_CREAT, 0444);
19768 if (fd < 0)
19769 result |= 1;
19770 else if (close (fd) != 0)
19771 result |= 1;
19772 else if (utimes (file, NULL) != 0)
19773 result |= 64;
19774 if (unlink (file) != 0)
19775 result |= 1;
19778 return result;
19781 _ACEOF
19782 if ac_fn_c_try_run "$LINENO"; then :
19783 gl_cv_func_working_utimes=yes
19784 else
19785 gl_cv_func_working_utimes=no
19787 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19788 conftest.$ac_objext conftest.beam conftest.$ac_ext
19792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
19793 $as_echo "$gl_cv_func_working_utimes" >&6; }
19795 if test $gl_cv_func_working_utimes = yes; then
19797 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
19805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
19806 $as_echo_n "checking for struct utimbuf... " >&6; }
19807 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
19808 $as_echo_n "(cached) " >&6
19809 else
19810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19811 /* end confdefs.h. */
19812 #if HAVE_SYS_TIME_H
19813 #include <sys/time.h>
19814 #endif
19815 #include <time.h>
19816 #ifdef HAVE_UTIME_H
19817 #include <utime.h>
19818 #endif
19821 main ()
19823 static struct utimbuf x; x.actime = x.modtime;
19825 return 0;
19827 _ACEOF
19828 if ac_fn_c_try_compile "$LINENO"; then :
19829 gl_cv_sys_struct_utimbuf=yes
19830 else
19831 gl_cv_sys_struct_utimbuf=no
19833 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
19836 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
19838 if test $gl_cv_sys_struct_utimbuf = yes; then
19840 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
19855 if false; then
19856 GL_COND_LIBTOOL_TRUE=
19857 GL_COND_LIBTOOL_FALSE='#'
19858 else
19859 GL_COND_LIBTOOL_TRUE='#'
19860 GL_COND_LIBTOOL_FALSE=
19863 gl_cond_libtool=false
19864 gl_libdeps=
19865 gl_ltlibdeps=
19866 gl_m4_base='m4'
19876 gl_source_base='lib'
19879 if test $ac_cv_func_alloca_works = no; then
19883 # Define an additional variable used in the Makefile substitution.
19884 if test $ac_cv_working_alloca_h = yes; then
19885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
19886 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
19887 if test "${gl_cv_rpl_alloca+set}" = set; then :
19888 $as_echo_n "(cached) " >&6
19889 else
19891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19892 /* end confdefs.h. */
19894 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
19895 Need own alloca
19896 #endif
19898 _ACEOF
19899 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19900 $EGREP "Need own alloca" >/dev/null 2>&1; then :
19901 gl_cv_rpl_alloca=yes
19902 else
19903 gl_cv_rpl_alloca=no
19905 rm -f conftest*
19909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
19910 $as_echo "$gl_cv_rpl_alloca" >&6; }
19911 if test $gl_cv_rpl_alloca = yes; then
19913 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
19915 ALLOCA_H=alloca.h
19916 else
19917 ALLOCA_H=
19919 else
19920 ALLOCA_H=alloca.h
19923 if test -n "$ALLOCA_H"; then
19924 GL_GENERATE_ALLOCA_H_TRUE=
19925 GL_GENERATE_ALLOCA_H_FALSE='#'
19926 else
19927 GL_GENERATE_ALLOCA_H_TRUE='#'
19928 GL_GENERATE_ALLOCA_H_FALSE=
19936 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
19937 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
19939 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
19940 # programs in the package would end up linked with that potentially-shared
19941 # library, inducing unnecessary run-time overhead.
19942 LIB_CLOCK_GETTIME=
19944 gl_saved_libs=$LIBS
19945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19946 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19947 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19948 $as_echo_n "(cached) " >&6
19949 else
19950 ac_func_search_save_LIBS=$LIBS
19951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19952 /* end confdefs.h. */
19954 /* Override any GCC internal prototype to avoid an error.
19955 Use char because int might match the return type of a GCC
19956 builtin and then its argument prototype would still apply. */
19957 #ifdef __cplusplus
19958 extern "C"
19959 #endif
19960 char clock_gettime ();
19962 main ()
19964 return clock_gettime ();
19966 return 0;
19968 _ACEOF
19969 for ac_lib in '' rt posix4; do
19970 if test -z "$ac_lib"; then
19971 ac_res="none required"
19972 else
19973 ac_res=-l$ac_lib
19974 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19976 if ac_fn_c_try_link "$LINENO"; then :
19977 ac_cv_search_clock_gettime=$ac_res
19979 rm -f core conftest.err conftest.$ac_objext \
19980 conftest$ac_exeext
19981 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19982 break
19984 done
19985 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19987 else
19988 ac_cv_search_clock_gettime=no
19990 rm conftest.$ac_ext
19991 LIBS=$ac_func_search_save_LIBS
19993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19994 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19995 ac_res=$ac_cv_search_clock_gettime
19996 if test "$ac_res" != no; then :
19997 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19998 test "$ac_cv_search_clock_gettime" = "none required" ||
19999 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20002 for ac_func in clock_gettime clock_settime
20003 do :
20004 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20005 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20006 eval as_val=\$$as_ac_var
20007 if test "x$as_val" = x""yes; then :
20008 cat >>confdefs.h <<_ACEOF
20009 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20010 _ACEOF
20013 done
20015 LIBS=$gl_saved_libs
20041 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20044 if test $HAVE_DUP2 = 1; then
20045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20046 $as_echo_n "checking whether dup2 works... " >&6; }
20047 if test "${gl_cv_func_dup2_works+set}" = set; then :
20048 $as_echo_n "(cached) " >&6
20049 else
20050 if test "$cross_compiling" = yes; then :
20051 case "$host_os" in
20052 mingw*) # on this platform, dup2 always returns 0 for success
20053 gl_cv_func_dup2_works="guessing no" ;;
20054 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20055 gl_cv_func_dup2_works="guessing no" ;;
20056 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20057 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20058 gl_cv_func_dup2_works="guessing no" ;;
20059 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20060 gl_cv_func_dup2_works="guessing no" ;;
20061 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20062 gl_cv_func_dup2_works="guessing no" ;;
20063 *) gl_cv_func_dup2_works="guessing yes" ;;
20064 esac
20065 else
20066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20067 /* end confdefs.h. */
20069 #include <unistd.h>
20070 #include <fcntl.h>
20071 #include <errno.h>
20073 main ()
20075 int result = 0;
20076 #ifdef FD_CLOEXEC
20077 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20078 result |= 1;
20079 #endif
20080 if (dup2 (1, 1) == 0)
20081 result |= 2;
20082 #ifdef FD_CLOEXEC
20083 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20084 result |= 4;
20085 #endif
20086 close (0);
20087 if (dup2 (0, 0) != -1)
20088 result |= 8;
20089 /* Many gnulib modules require POSIX conformance of EBADF. */
20090 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20091 result |= 16;
20092 return result;
20095 return 0;
20098 _ACEOF
20099 if ac_fn_c_try_run "$LINENO"; then :
20100 gl_cv_func_dup2_works=yes
20101 else
20102 gl_cv_func_dup2_works=no
20104 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20105 conftest.$ac_objext conftest.beam conftest.$ac_ext
20110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20111 $as_echo "$gl_cv_func_dup2_works" >&6; }
20112 case "$gl_cv_func_dup2_works" in
20113 *yes) ;;
20115 REPLACE_DUP2=1
20117 esac
20121 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20130 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20139 GNULIB_DUP2=1
20151 GNULIB_ENVIRON=1
20160 LIB_EXECINFO=''
20161 EXECINFO_H='execinfo.h'
20163 if test $ac_cv_header_execinfo_h = yes; then
20164 gl_saved_libs=$LIBS
20165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20166 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20167 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20168 $as_echo_n "(cached) " >&6
20169 else
20170 ac_func_search_save_LIBS=$LIBS
20171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20172 /* end confdefs.h. */
20174 /* Override any GCC internal prototype to avoid an error.
20175 Use char because int might match the return type of a GCC
20176 builtin and then its argument prototype would still apply. */
20177 #ifdef __cplusplus
20178 extern "C"
20179 #endif
20180 char backtrace_symbols_fd ();
20182 main ()
20184 return backtrace_symbols_fd ();
20186 return 0;
20188 _ACEOF
20189 for ac_lib in '' execinfo; do
20190 if test -z "$ac_lib"; then
20191 ac_res="none required"
20192 else
20193 ac_res=-l$ac_lib
20194 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20196 if ac_fn_c_try_link "$LINENO"; then :
20197 ac_cv_search_backtrace_symbols_fd=$ac_res
20199 rm -f core conftest.err conftest.$ac_objext \
20200 conftest$ac_exeext
20201 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20202 break
20204 done
20205 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20207 else
20208 ac_cv_search_backtrace_symbols_fd=no
20210 rm conftest.$ac_ext
20211 LIBS=$ac_func_search_save_LIBS
20213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20214 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20215 ac_res=$ac_cv_search_backtrace_symbols_fd
20216 if test "$ac_res" != no; then :
20217 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20218 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20219 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20222 LIBS=$gl_saved_libs
20223 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20226 if test -n "$EXECINFO_H"; then
20235 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20241 if test -n "$EXECINFO_H"; then
20242 GL_GENERATE_EXECINFO_H_TRUE=
20243 GL_GENERATE_EXECINFO_H_FALSE='#'
20244 else
20245 GL_GENERATE_EXECINFO_H_TRUE='#'
20246 GL_GENERATE_EXECINFO_H_FALSE=
20257 # Persuade glibc <stdlib.h> to declare getloadavg().
20260 gl_save_LIBS=$LIBS
20262 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20263 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20264 HAVE_GETLOADAVG=1
20265 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20266 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20268 else
20269 gl_func_getloadavg_done=no
20271 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20272 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20273 # to get the right answer into the cache.
20274 # For kstat on solaris, we need to test for libelf and libkvm to force the
20275 # definition of SVR4 below.
20276 if test $gl_func_getloadavg_done = no; then
20277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20278 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20279 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20280 $as_echo_n "(cached) " >&6
20281 else
20282 ac_check_lib_save_LIBS=$LIBS
20283 LIBS="-lelf $LIBS"
20284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20285 /* end confdefs.h. */
20287 /* Override any GCC internal prototype to avoid an error.
20288 Use char because int might match the return type of a GCC
20289 builtin and then its argument prototype would still apply. */
20290 #ifdef __cplusplus
20291 extern "C"
20292 #endif
20293 char elf_begin ();
20295 main ()
20297 return elf_begin ();
20299 return 0;
20301 _ACEOF
20302 if ac_fn_c_try_link "$LINENO"; then :
20303 ac_cv_lib_elf_elf_begin=yes
20304 else
20305 ac_cv_lib_elf_elf_begin=no
20307 rm -f core conftest.err conftest.$ac_objext \
20308 conftest$ac_exeext conftest.$ac_ext
20309 LIBS=$ac_check_lib_save_LIBS
20311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20312 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20313 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20314 LIBS="-lelf $LIBS"
20317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20318 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20319 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20320 $as_echo_n "(cached) " >&6
20321 else
20322 ac_check_lib_save_LIBS=$LIBS
20323 LIBS="-lkvm $LIBS"
20324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20325 /* end confdefs.h. */
20327 /* Override any GCC internal prototype to avoid an error.
20328 Use char because int might match the return type of a GCC
20329 builtin and then its argument prototype would still apply. */
20330 #ifdef __cplusplus
20331 extern "C"
20332 #endif
20333 char kvm_open ();
20335 main ()
20337 return kvm_open ();
20339 return 0;
20341 _ACEOF
20342 if ac_fn_c_try_link "$LINENO"; then :
20343 ac_cv_lib_kvm_kvm_open=yes
20344 else
20345 ac_cv_lib_kvm_kvm_open=no
20347 rm -f core conftest.err conftest.$ac_objext \
20348 conftest$ac_exeext conftest.$ac_ext
20349 LIBS=$ac_check_lib_save_LIBS
20351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20352 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20353 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20354 LIBS="-lkvm $LIBS"
20357 # Check for the 4.4BSD definition of getloadavg.
20358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20359 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20360 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20361 $as_echo_n "(cached) " >&6
20362 else
20363 ac_check_lib_save_LIBS=$LIBS
20364 LIBS="-lutil $LIBS"
20365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20366 /* end confdefs.h. */
20368 /* Override any GCC internal prototype to avoid an error.
20369 Use char because int might match the return type of a GCC
20370 builtin and then its argument prototype would still apply. */
20371 #ifdef __cplusplus
20372 extern "C"
20373 #endif
20374 char getloadavg ();
20376 main ()
20378 return getloadavg ();
20380 return 0;
20382 _ACEOF
20383 if ac_fn_c_try_link "$LINENO"; then :
20384 ac_cv_lib_util_getloadavg=yes
20385 else
20386 ac_cv_lib_util_getloadavg=no
20388 rm -f core conftest.err conftest.$ac_objext \
20389 conftest$ac_exeext conftest.$ac_ext
20390 LIBS=$ac_check_lib_save_LIBS
20392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20393 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20394 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20395 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20400 if test $gl_func_getloadavg_done = no; then
20401 # There is a commonly available library for RS/6000 AIX.
20402 # Since it is not a standard part of AIX, it might be installed locally.
20403 gl_getloadavg_LIBS=$LIBS
20404 LIBS="-L/usr/local/lib $LIBS"
20405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20406 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20407 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20408 $as_echo_n "(cached) " >&6
20409 else
20410 ac_check_lib_save_LIBS=$LIBS
20411 LIBS="-lgetloadavg $LIBS"
20412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20413 /* end confdefs.h. */
20415 /* Override any GCC internal prototype to avoid an error.
20416 Use char because int might match the return type of a GCC
20417 builtin and then its argument prototype would still apply. */
20418 #ifdef __cplusplus
20419 extern "C"
20420 #endif
20421 char getloadavg ();
20423 main ()
20425 return getloadavg ();
20427 return 0;
20429 _ACEOF
20430 if ac_fn_c_try_link "$LINENO"; then :
20431 ac_cv_lib_getloadavg_getloadavg=yes
20432 else
20433 ac_cv_lib_getloadavg_getloadavg=no
20435 rm -f core conftest.err conftest.$ac_objext \
20436 conftest$ac_exeext conftest.$ac_ext
20437 LIBS=$ac_check_lib_save_LIBS
20439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
20440 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20441 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20442 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20443 else
20444 LIBS=$gl_getloadavg_LIBS
20449 # Set up the replacement function if necessary.
20450 if test $gl_func_getloadavg_done = no; then
20451 HAVE_GETLOADAVG=0
20453 # Solaris has libkstat which does not require root.
20454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20455 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20456 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20457 $as_echo_n "(cached) " >&6
20458 else
20459 ac_check_lib_save_LIBS=$LIBS
20460 LIBS="-lkstat $LIBS"
20461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20462 /* end confdefs.h. */
20464 /* Override any GCC internal prototype to avoid an error.
20465 Use char because int might match the return type of a GCC
20466 builtin and then its argument prototype would still apply. */
20467 #ifdef __cplusplus
20468 extern "C"
20469 #endif
20470 char kstat_open ();
20472 main ()
20474 return kstat_open ();
20476 return 0;
20478 _ACEOF
20479 if ac_fn_c_try_link "$LINENO"; then :
20480 ac_cv_lib_kstat_kstat_open=yes
20481 else
20482 ac_cv_lib_kstat_kstat_open=no
20484 rm -f core conftest.err conftest.$ac_objext \
20485 conftest$ac_exeext conftest.$ac_ext
20486 LIBS=$ac_check_lib_save_LIBS
20488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20489 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20490 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20491 cat >>confdefs.h <<_ACEOF
20492 #define HAVE_LIBKSTAT 1
20493 _ACEOF
20495 LIBS="-lkstat $LIBS"
20499 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20501 # AIX has libperfstat which does not require root
20502 if test $gl_func_getloadavg_done = no; then
20503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20504 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20505 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20506 $as_echo_n "(cached) " >&6
20507 else
20508 ac_check_lib_save_LIBS=$LIBS
20509 LIBS="-lperfstat $LIBS"
20510 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20511 /* end confdefs.h. */
20513 /* Override any GCC internal prototype to avoid an error.
20514 Use char because int might match the return type of a GCC
20515 builtin and then its argument prototype would still apply. */
20516 #ifdef __cplusplus
20517 extern "C"
20518 #endif
20519 char perfstat_cpu_total ();
20521 main ()
20523 return perfstat_cpu_total ();
20525 return 0;
20527 _ACEOF
20528 if ac_fn_c_try_link "$LINENO"; then :
20529 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20530 else
20531 ac_cv_lib_perfstat_perfstat_cpu_total=no
20533 rm -f core conftest.err conftest.$ac_objext \
20534 conftest$ac_exeext conftest.$ac_ext
20535 LIBS=$ac_check_lib_save_LIBS
20537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20538 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20539 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20540 cat >>confdefs.h <<_ACEOF
20541 #define HAVE_LIBPERFSTAT 1
20542 _ACEOF
20544 LIBS="-lperfstat $LIBS"
20548 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20551 if test $gl_func_getloadavg_done = no; then
20552 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20553 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20554 gl_func_getloadavg_done=yes
20556 $as_echo "#define DGUX 1" >>confdefs.h
20558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20559 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20560 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20561 $as_echo_n "(cached) " >&6
20562 else
20563 ac_check_lib_save_LIBS=$LIBS
20564 LIBS="-ldgc $LIBS"
20565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20566 /* end confdefs.h. */
20568 /* Override any GCC internal prototype to avoid an error.
20569 Use char because int might match the return type of a GCC
20570 builtin and then its argument prototype would still apply. */
20571 #ifdef __cplusplus
20572 extern "C"
20573 #endif
20574 char dg_sys_info ();
20576 main ()
20578 return dg_sys_info ();
20580 return 0;
20582 _ACEOF
20583 if ac_fn_c_try_link "$LINENO"; then :
20584 ac_cv_lib_dgc_dg_sys_info=yes
20585 else
20586 ac_cv_lib_dgc_dg_sys_info=no
20588 rm -f core conftest.err conftest.$ac_objext \
20589 conftest$ac_exeext conftest.$ac_ext
20590 LIBS=$ac_check_lib_save_LIBS
20592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
20593 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
20594 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
20595 cat >>confdefs.h <<_ACEOF
20596 #define HAVE_LIBDGC 1
20597 _ACEOF
20599 LIBS="-ldgc $LIBS"
20611 if test "x$gl_save_LIBS" = x; then
20612 GETLOADAVG_LIBS=$LIBS
20613 else
20614 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
20616 LIBS=$gl_save_LIBS
20619 # Test whether the system declares getloadavg. Solaris has the function
20620 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
20621 for ac_header in sys/loadavg.h
20622 do :
20623 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
20624 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
20625 cat >>confdefs.h <<_ACEOF
20626 #define HAVE_SYS_LOADAVG_H 1
20627 _ACEOF
20631 done
20633 if test $ac_cv_header_sys_loadavg_h = yes; then
20634 HAVE_SYS_LOADAVG_H=1
20635 else
20636 HAVE_SYS_LOADAVG_H=0
20638 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
20639 # include <sys/loadavg.h>
20640 #endif
20641 #include <stdlib.h>
20643 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
20645 else
20646 HAVE_DECL_GETLOADAVG=0
20650 if test $HAVE_GETLOADAVG = 0; then
20659 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
20662 # Figure out what our getloadavg.c needs.
20666 # On HPUX9, an unprivileged user can get load averages this way.
20667 if test $gl_func_getloadavg_done = no; then
20668 for ac_func in pstat_getdynamic
20669 do :
20670 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
20671 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
20672 cat >>confdefs.h <<_ACEOF
20673 #define HAVE_PSTAT_GETDYNAMIC 1
20674 _ACEOF
20675 gl_func_getloadavg_done=yes
20677 done
20681 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
20682 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
20683 # Irix 4.0.5F has the header but not the library.
20684 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
20685 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
20686 gl_func_getloadavg_done=yes
20688 $as_echo "#define SVR4 1" >>confdefs.h
20692 if test $gl_func_getloadavg_done = no; then
20693 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
20694 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
20695 gl_func_getloadavg_done=yes
20697 $as_echo "#define UMAX 1" >>confdefs.h
20700 $as_echo "#define UMAX4_3 1" >>confdefs.h
20707 if test $gl_func_getloadavg_done = no; then
20708 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
20709 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
20710 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
20717 if test $gl_func_getloadavg_done = no; then
20718 for ac_header in mach/mach.h
20719 do :
20720 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
20721 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
20722 cat >>confdefs.h <<_ACEOF
20723 #define HAVE_MACH_MACH_H 1
20724 _ACEOF
20728 done
20732 for ac_header in nlist.h
20733 do :
20734 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
20735 if test "x$ac_cv_header_nlist_h" = x""yes; then :
20736 cat >>confdefs.h <<_ACEOF
20737 #define HAVE_NLIST_H 1
20738 _ACEOF
20739 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
20741 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
20743 cat >>confdefs.h <<_ACEOF
20744 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
20745 _ACEOF
20750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20751 /* end confdefs.h. */
20752 #include <nlist.h>
20754 main ()
20756 struct nlist x;
20757 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
20758 x.n_un.n_name = "";
20759 #else
20760 x.n_name = "";
20761 #endif
20763 return 0;
20765 _ACEOF
20766 if ac_fn_c_try_link "$LINENO"; then :
20768 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
20771 rm -f core conftest.err conftest.$ac_objext \
20772 conftest$ac_exeext conftest.$ac_ext
20776 done
20784 GNULIB_GETLOADAVG=1
20795 if test $REPLACE_GETOPT = 1; then
20804 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20814 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20819 GNULIB_GL_UNISTD_H_GETOPT=1
20828 REPLACE_GETOPT=0
20829 if test -n "$gl_replace_getopt"; then
20830 REPLACE_GETOPT=1
20833 if test $REPLACE_GETOPT = 1; then
20835 GETOPT_H=getopt.h
20837 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
20843 if test $REPLACE_GETOPT = 1; then
20852 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20862 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20867 GNULIB_GL_UNISTD_H_GETOPT=1
20881 gl_gettimeofday_timezone=void
20882 if test $ac_cv_func_gettimeofday != yes; then
20883 HAVE_GETTIMEOFDAY=0
20884 else
20888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
20889 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
20890 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
20891 $as_echo_n "(cached) " >&6
20892 else
20893 if test "$cross_compiling" = yes; then :
20894 # When cross-compiling:
20895 case "$host_os" in
20896 # Guess all is fine on glibc systems.
20897 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
20898 # If we don't know, assume the worst.
20899 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
20900 esac
20902 else
20903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20904 /* end confdefs.h. */
20905 #include <string.h>
20906 #include <sys/time.h>
20907 #include <time.h>
20908 #include <stdlib.h>
20911 main ()
20914 time_t t = 0;
20915 struct tm *lt;
20916 struct tm saved_lt;
20917 struct timeval tv;
20918 lt = localtime (&t);
20919 saved_lt = *lt;
20920 gettimeofday (&tv, NULL);
20921 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
20924 return 0;
20926 _ACEOF
20927 if ac_fn_c_try_run "$LINENO"; then :
20928 gl_cv_func_gettimeofday_clobber=no
20929 else
20930 gl_cv_func_gettimeofday_clobber=yes
20932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20933 conftest.$ac_objext conftest.beam conftest.$ac_ext
20937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
20938 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
20940 case "$gl_cv_func_gettimeofday_clobber" in
20941 *yes)
20942 REPLACE_GETTIMEOFDAY=1
20945 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
20948 $as_echo "#define localtime rpl_localtime" >>confdefs.h
20952 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
20955 esac
20957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
20958 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
20959 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
20960 $as_echo_n "(cached) " >&6
20961 else
20962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20963 /* end confdefs.h. */
20964 #include <sys/time.h>
20965 struct timeval c;
20966 int gettimeofday (struct timeval *restrict, void *restrict);
20969 main ()
20971 /* glibc uses struct timezone * rather than the POSIX void *
20972 if _GNU_SOURCE is defined. However, since the only portable
20973 use of gettimeofday uses NULL as the second parameter, and
20974 since the glibc definition is actually more typesafe, it is
20975 not worth wrapping this to get a compliant signature. */
20976 int (*f) (struct timeval *restrict, void *restrict)
20977 = gettimeofday;
20978 int x = f (&c, 0);
20979 return !(x | c.tv_sec | c.tv_usec);
20982 return 0;
20984 _ACEOF
20985 if ac_fn_c_try_compile "$LINENO"; then :
20986 gl_cv_func_gettimeofday_posix_signature=yes
20987 else
20988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20989 /* end confdefs.h. */
20990 #include <sys/time.h>
20991 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
20994 main ()
20998 return 0;
21000 _ACEOF
21001 if ac_fn_c_try_compile "$LINENO"; then :
21002 gl_cv_func_gettimeofday_posix_signature=almost
21003 else
21004 gl_cv_func_gettimeofday_posix_signature=no
21006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21008 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21011 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21012 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21013 gl_gettimeofday_timezone='struct timezone'
21014 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21015 REPLACE_GETTIMEOFDAY=1
21017 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21018 REPLACE_GETTIMEOFDAY=1
21023 cat >>confdefs.h <<_ACEOF
21024 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21025 _ACEOF
21028 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21037 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21040 for ac_header in sys/timeb.h
21041 do :
21042 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21043 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21044 cat >>confdefs.h <<_ACEOF
21045 #define HAVE_SYS_TIMEB_H 1
21046 _ACEOF
21050 done
21052 for ac_func in _ftime
21053 do :
21054 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21055 if test "x$ac_cv_func__ftime" = x""yes; then :
21056 cat >>confdefs.h <<_ACEOF
21057 #define HAVE__FTIME 1
21058 _ACEOF
21061 done
21070 GNULIB_GETTIMEOFDAY=1
21081 if test $ac_cv_func_lstat = yes; then
21083 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21084 *no)
21085 REPLACE_LSTAT=1
21087 esac
21088 else
21089 HAVE_LSTAT=0
21092 if test $REPLACE_LSTAT = 1; then
21101 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21113 GNULIB_LSTAT=1
21125 if test $APPLE_UNIVERSAL_BUILD = 1; then
21126 # A universal build on Apple Mac OS X platforms.
21127 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21128 # But we need a configuration result that is valid in both modes.
21129 gl_cv_func_working_mktime=no
21131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21132 $as_echo_n "checking for working mktime... " >&6; }
21133 if test "${gl_cv_func_working_mktime+set}" = set; then :
21134 $as_echo_n "(cached) " >&6
21135 else
21136 if test "$cross_compiling" = yes; then :
21137 gl_cv_func_working_mktime=no
21138 else
21139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21140 /* end confdefs.h. */
21141 /* Test program from Paul Eggert and Tony Leneis. */
21142 #include <limits.h>
21143 #include <stdlib.h>
21144 #include <time.h>
21146 #ifdef HAVE_UNISTD_H
21147 # include <unistd.h>
21148 #endif
21150 #ifndef HAVE_ALARM
21151 # define alarm(X) /* empty */
21152 #endif
21154 /* Work around redefinition to rpl_putenv by other config tests. */
21155 #undef putenv
21157 static time_t time_t_max;
21158 static time_t time_t_min;
21160 /* Values we'll use to set the TZ environment variable. */
21161 static char *tz_strings[] = {
21162 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21163 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21165 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21167 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21168 Based on a problem report from Andreas Jaeger. */
21169 static int
21170 spring_forward_gap ()
21172 /* glibc (up to about 1998-10-07) failed this test. */
21173 struct tm tm;
21175 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21176 instead of "TZ=America/Vancouver" in order to detect the bug even
21177 on systems that don't support the Olson extension, or don't have the
21178 full zoneinfo tables installed. */
21179 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21181 tm.tm_year = 98;
21182 tm.tm_mon = 3;
21183 tm.tm_mday = 5;
21184 tm.tm_hour = 2;
21185 tm.tm_min = 0;
21186 tm.tm_sec = 0;
21187 tm.tm_isdst = -1;
21188 return mktime (&tm) != (time_t) -1;
21191 static int
21192 mktime_test1 (time_t now)
21194 struct tm *lt;
21195 return ! (lt = localtime (&now)) || mktime (lt) == now;
21198 static int
21199 mktime_test (time_t now)
21201 return (mktime_test1 (now)
21202 && mktime_test1 ((time_t) (time_t_max - now))
21203 && mktime_test1 ((time_t) (time_t_min + now)));
21206 static int
21207 irix_6_4_bug ()
21209 /* Based on code from Ariel Faigon. */
21210 struct tm tm;
21211 tm.tm_year = 96;
21212 tm.tm_mon = 3;
21213 tm.tm_mday = 0;
21214 tm.tm_hour = 0;
21215 tm.tm_min = 0;
21216 tm.tm_sec = 0;
21217 tm.tm_isdst = -1;
21218 mktime (&tm);
21219 return tm.tm_mon == 2 && tm.tm_mday == 31;
21222 static int
21223 bigtime_test (int j)
21225 struct tm tm;
21226 time_t now;
21227 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21228 now = mktime (&tm);
21229 if (now != (time_t) -1)
21231 struct tm *lt = localtime (&now);
21232 if (! (lt
21233 && lt->tm_year == tm.tm_year
21234 && lt->tm_mon == tm.tm_mon
21235 && lt->tm_mday == tm.tm_mday
21236 && lt->tm_hour == tm.tm_hour
21237 && lt->tm_min == tm.tm_min
21238 && lt->tm_sec == tm.tm_sec
21239 && lt->tm_yday == tm.tm_yday
21240 && lt->tm_wday == tm.tm_wday
21241 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21242 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21243 return 0;
21245 return 1;
21248 static int
21249 year_2050_test ()
21251 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21252 ignoring leap seconds. */
21253 unsigned long int answer = 2527315200UL;
21255 struct tm tm;
21256 time_t t;
21257 tm.tm_year = 2050 - 1900;
21258 tm.tm_mon = 2 - 1;
21259 tm.tm_mday = 1;
21260 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21261 tm.tm_isdst = -1;
21263 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21264 instead of "TZ=America/Vancouver" in order to detect the bug even
21265 on systems that don't support the Olson extension, or don't have the
21266 full zoneinfo tables installed. */
21267 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21269 t = mktime (&tm);
21271 /* Check that the result is either a failure, or close enough
21272 to the correct answer that we can assume the discrepancy is
21273 due to leap seconds. */
21274 return (t == (time_t) -1
21275 || (0 < t && answer - 120 <= t && t <= answer + 120));
21279 main ()
21281 int result = 0;
21282 time_t t, delta;
21283 int i, j;
21284 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21285 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21287 /* This test makes some buggy mktime implementations loop.
21288 Give up after 60 seconds; a mktime slower than that
21289 isn't worth using anyway. */
21290 alarm (60);
21292 time_t_max = (! time_t_signed
21293 ? (time_t) -1
21294 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21295 * 2 + 1));
21296 time_t_min = (! time_t_signed
21297 ? (time_t) 0
21298 : time_t_signed_magnitude
21299 ? ~ (time_t) 0
21300 : ~ time_t_max);
21302 delta = time_t_max / 997; /* a suitable prime number */
21303 for (i = 0; i < N_STRINGS; i++)
21305 if (tz_strings[i])
21306 putenv (tz_strings[i]);
21308 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21309 if (! mktime_test (t))
21310 result |= 1;
21311 if ((result & 2) == 0
21312 && ! (mktime_test ((time_t) 1)
21313 && mktime_test ((time_t) (60 * 60))
21314 && mktime_test ((time_t) (60 * 60 * 24))))
21315 result |= 2;
21317 for (j = 1; (result & 4) == 0; j <<= 1)
21319 if (! bigtime_test (j))
21320 result |= 4;
21321 if (INT_MAX / 2 < j)
21322 break;
21324 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21325 result |= 8;
21327 if (! irix_6_4_bug ())
21328 result |= 16;
21329 if (! spring_forward_gap ())
21330 result |= 32;
21331 if (! year_2050_test ())
21332 result |= 64;
21333 return result;
21335 _ACEOF
21336 if ac_fn_c_try_run "$LINENO"; then :
21337 gl_cv_func_working_mktime=yes
21338 else
21339 gl_cv_func_working_mktime=no
21341 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21342 conftest.$ac_objext conftest.beam conftest.$ac_ext
21347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21348 $as_echo "$gl_cv_func_working_mktime" >&6; }
21350 if test $gl_cv_func_working_mktime = no; then
21351 REPLACE_MKTIME=1
21352 else
21353 REPLACE_MKTIME=0
21356 if test $REPLACE_MKTIME = 1; then
21365 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21374 GNULIB_MKTIME=1
21386 if test $ac_cv_func_pselect = yes; then
21387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21388 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21389 if test "${gl_cv_sig_pselect+set}" = set; then :
21390 $as_echo_n "(cached) " >&6
21391 else
21392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21393 /* end confdefs.h. */
21394 #include <sys/select.h>
21397 main ()
21399 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21400 struct timespec const *restrict,
21401 sigset_t const *restrict) = pselect;
21402 return !p;
21404 return 0;
21406 _ACEOF
21407 if ac_fn_c_try_link "$LINENO"; then :
21408 gl_cv_sig_pselect=yes
21409 else
21410 gl_cv_sig_pselect=no
21412 rm -f core conftest.err conftest.$ac_objext \
21413 conftest$ac_exeext conftest.$ac_ext
21415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21416 $as_echo "$gl_cv_sig_pselect" >&6; }
21419 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21420 REPLACE_PSELECT=1
21423 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21432 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21440 GNULIB_PSELECT=1
21450 LIB_PTHREAD_SIGMASK=
21453 if test $ac_cv_func_pthread_sigmask = yes; then
21455 else
21456 HAVE_PTHREAD_SIGMASK=0
21457 REPLACE_PTHREAD_SIGMASK=1
21463 if test $HAVE_PTHREAD_SIGMASK = 1; then
21466 if test -z "$LIB_PTHREAD_SIGMASK"; then
21467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
21468 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
21469 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
21470 $as_echo_n "(cached) " >&6
21471 else
21473 if test "$cross_compiling" = yes; then :
21475 case "$host_os" in
21476 freebsd* | hpux* | solaris | solaris2.[2-9]*)
21477 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
21479 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
21480 esac
21482 else
21483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21484 /* end confdefs.h. */
21486 #include <pthread.h>
21487 #include <signal.h>
21488 #include <stddef.h>
21489 int main ()
21491 sigset_t set;
21492 sigemptyset (&set);
21493 return pthread_sigmask (1729, &set, NULL) != 0;
21495 _ACEOF
21496 if ac_fn_c_try_run "$LINENO"; then :
21497 gl_cv_func_pthread_sigmask_in_libc_works=no
21498 else
21499 gl_cv_func_pthread_sigmask_in_libc_works=yes
21501 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21502 conftest.$ac_objext conftest.beam conftest.$ac_ext
21507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
21508 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
21509 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
21510 *no)
21511 REPLACE_PTHREAD_SIGMASK=1
21513 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
21516 esac
21519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
21520 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
21521 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
21522 $as_echo_n "(cached) " >&6
21523 else
21525 gl_save_LIBS="$LIBS"
21526 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
21527 if test "$cross_compiling" = yes; then :
21528 case "$host_os" in
21529 cygwin*)
21530 gl_cv_func_pthread_sigmask_return_works="guessing no";;
21532 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
21533 esac
21535 else
21536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21537 /* end confdefs.h. */
21539 #include <pthread.h>
21540 #include <signal.h>
21541 #include <stddef.h>
21542 int main ()
21544 sigset_t set;
21545 sigemptyset (&set);
21546 if (pthread_sigmask (1729, &set, NULL) == -1)
21547 return 1;
21548 return 0;
21550 _ACEOF
21551 if ac_fn_c_try_run "$LINENO"; then :
21552 gl_cv_func_pthread_sigmask_return_works=yes
21553 else
21554 gl_cv_func_pthread_sigmask_return_works=no
21556 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21557 conftest.$ac_objext conftest.beam conftest.$ac_ext
21560 LIBS="$gl_save_LIBS"
21563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
21564 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
21565 case "$gl_cv_func_pthread_sigmask_return_works" in
21566 *no)
21567 REPLACE_PTHREAD_SIGMASK=1
21569 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
21572 esac
21574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
21575 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
21576 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
21577 $as_echo_n "(cached) " >&6
21578 else
21580 case "$host_os" in
21581 irix*)
21582 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
21584 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
21585 esac
21586 gl_save_LIBS="$LIBS"
21587 LIBS="$LIBS $LIBMULTITHREAD"
21588 if test "$cross_compiling" = yes; then :
21590 else
21591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21592 /* end confdefs.h. */
21594 #include <pthread.h>
21595 #include <signal.h>
21596 #include <stdio.h>
21597 #include <stdlib.h>
21598 #include <unistd.h>
21599 static volatile int sigint_occurred;
21600 static void
21601 sigint_handler (int sig)
21603 sigint_occurred++;
21605 int main ()
21607 sigset_t set;
21608 int pid = getpid ();
21609 char command[80];
21610 signal (SIGINT, sigint_handler);
21611 sigemptyset (&set);
21612 sigaddset (&set, SIGINT);
21613 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
21614 return 1;
21615 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
21616 if (!(system (command) == 0))
21617 return 2;
21618 sleep (2);
21619 if (!(sigint_occurred == 0))
21620 return 3;
21621 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
21622 return 4;
21623 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
21624 return 5;
21625 return 0;
21627 _ACEOF
21628 if ac_fn_c_try_run "$LINENO"; then :
21630 else
21631 gl_cv_func_pthread_sigmask_unblock_works=no
21633 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21634 conftest.$ac_objext conftest.beam conftest.$ac_ext
21637 LIBS="$gl_save_LIBS"
21640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
21641 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
21642 case "$gl_cv_func_pthread_sigmask_unblock_works" in
21643 *no)
21644 REPLACE_PTHREAD_SIGMASK=1
21646 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
21649 esac
21652 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
21661 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
21664 if test $HAVE_PTHREAD_SIGMASK = 1; then
21666 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
21676 GNULIB_PTHREAD_SIGMASK=1
21685 if test $ac_cv_func_readlink = no; then
21686 HAVE_READLINK=0
21687 else
21688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
21689 $as_echo_n "checking whether readlink signature is correct... " >&6; }
21690 if test "${gl_cv_decl_readlink_works+set}" = set; then :
21691 $as_echo_n "(cached) " >&6
21692 else
21693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21694 /* end confdefs.h. */
21695 #include <unistd.h>
21696 /* Cause compilation failure if original declaration has wrong type. */
21697 ssize_t readlink (const char *, char *, size_t);
21699 main ()
21703 return 0;
21705 _ACEOF
21706 if ac_fn_c_try_compile "$LINENO"; then :
21707 gl_cv_decl_readlink_works=yes
21708 else
21709 gl_cv_decl_readlink_works=no
21711 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
21714 $as_echo "$gl_cv_decl_readlink_works" >&6; }
21715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
21716 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
21717 if test "${gl_cv_func_readlink_works+set}" = set; then :
21718 $as_echo_n "(cached) " >&6
21719 else
21720 # We have readlink, so assume ln -s works.
21721 ln -s conftest.no-such conftest.link
21722 ln -s conftest.link conftest.lnk2
21723 if test "$cross_compiling" = yes; then :
21724 case "$host_os" in
21725 # Guess yes on glibc systems.
21726 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
21727 # If we don't know, assume the worst.
21728 *) gl_cv_func_readlink_works="guessing no" ;;
21729 esac
21731 else
21732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21733 /* end confdefs.h. */
21734 #include <unistd.h>
21737 main ()
21739 char buf[20];
21740 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
21742 return 0;
21744 _ACEOF
21745 if ac_fn_c_try_run "$LINENO"; then :
21746 gl_cv_func_readlink_works=yes
21747 else
21748 gl_cv_func_readlink_works=no
21750 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21751 conftest.$ac_objext conftest.beam conftest.$ac_ext
21754 rm -f conftest.link conftest.lnk2
21756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
21757 $as_echo "$gl_cv_func_readlink_works" >&6; }
21758 case "$gl_cv_func_readlink_works" in
21759 *yes)
21760 if test "$gl_cv_decl_readlink_works" != yes; then
21761 REPLACE_READLINK=1
21766 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
21768 REPLACE_READLINK=1
21770 esac
21773 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
21782 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
21793 GNULIB_READLINK=1
21810 if test $gl_cv_have_include_next = yes; then
21811 gl_cv_next_signal_h='<'signal.h'>'
21812 else
21813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
21814 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
21815 if test "${gl_cv_next_signal_h+set}" = set; then :
21816 $as_echo_n "(cached) " >&6
21817 else
21819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21820 /* end confdefs.h. */
21821 #include <signal.h>
21823 _ACEOF
21824 case "$host_os" in
21825 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21826 *) gl_absname_cpp="$ac_cpp" ;;
21827 esac
21829 case "$host_os" in
21830 mingw*)
21831 gl_dirsep_regex='[/\\]'
21834 gl_dirsep_regex='\/'
21836 esac
21837 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21839 gl_header_literal_regex=`echo 'signal.h' \
21840 | sed -e "$gl_make_literal_regex_sed"`
21841 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21842 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21843 s|^/[^/]|//&|
21847 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21848 sed -n "$gl_absolute_header_sed"`'"'
21852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
21853 $as_echo "$gl_cv_next_signal_h" >&6; }
21855 NEXT_SIGNAL_H=$gl_cv_next_signal_h
21857 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21858 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21859 gl_next_as_first_directive='<'signal.h'>'
21860 else
21861 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21862 gl_next_as_first_directive=$gl_cv_next_signal_h
21864 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
21870 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
21871 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
21872 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
21873 #include <signal.h>
21876 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
21878 else
21879 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
21888 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
21889 #include <signal.h>
21892 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
21894 else
21895 HAVE_SIGHANDLER_T=0
21901 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
21902 /* <sys/types.h> is not needed according to POSIX, but the
21903 <sys/socket.h> in i386-unknown-freebsd4.10 and
21904 powerpc-apple-darwin5.5 required it. */
21905 #include <sys/types.h>
21906 #if HAVE_SYS_SOCKET_H
21907 # include <sys/socket.h>
21908 #elif HAVE_WS2TCPIP_H
21909 # include <ws2tcpip.h>
21910 #endif
21913 if test "x$ac_cv_type_socklen_t" = x""yes; then :
21915 else
21916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
21917 $as_echo_n "checking for socklen_t equivalent... " >&6; }
21918 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
21919 $as_echo_n "(cached) " >&6
21920 else
21921 # Systems have either "struct sockaddr *" or
21922 # "void *" as the second argument to getpeername
21923 gl_cv_socklen_t_equiv=
21924 for arg2 in "struct sockaddr" void; do
21925 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
21926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21927 /* end confdefs.h. */
21928 #include <sys/types.h>
21929 #include <sys/socket.h>
21931 int getpeername (int, $arg2 *, $t *);
21933 main ()
21935 $t len;
21936 getpeername (0, 0, &len);
21938 return 0;
21940 _ACEOF
21941 if ac_fn_c_try_compile "$LINENO"; then :
21942 gl_cv_socklen_t_equiv="$t"
21944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21945 test "$gl_cv_socklen_t_equiv" != "" && break
21946 done
21947 test "$gl_cv_socklen_t_equiv" != "" && break
21948 done
21952 if test "$gl_cv_socklen_t_equiv" = ""; then
21953 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
21955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
21956 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
21958 cat >>confdefs.h <<_ACEOF
21959 #define socklen_t $gl_cv_socklen_t_equiv
21960 _ACEOF
21965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
21966 $as_echo_n "checking for ssize_t... " >&6; }
21967 if test "${gt_cv_ssize_t+set}" = set; then :
21968 $as_echo_n "(cached) " >&6
21969 else
21970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21971 /* end confdefs.h. */
21972 #include <sys/types.h>
21974 main ()
21976 int x = sizeof (ssize_t *) + sizeof (ssize_t);
21977 return !x;
21979 return 0;
21981 _ACEOF
21982 if ac_fn_c_try_compile "$LINENO"; then :
21983 gt_cv_ssize_t=yes
21984 else
21985 gt_cv_ssize_t=no
21987 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
21990 $as_echo "$gt_cv_ssize_t" >&6; }
21991 if test $gt_cv_ssize_t = no; then
21993 $as_echo "#define ssize_t int" >>confdefs.h
22001 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>
22002 #include <sys/stat.h>
22004 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
22006 cat >>confdefs.h <<_ACEOF
22007 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
22008 _ACEOF
22010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
22011 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
22012 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
22013 $as_echo_n "(cached) " >&6
22014 else
22015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22016 /* end confdefs.h. */
22018 #include <sys/types.h>
22019 #include <sys/stat.h>
22020 #if HAVE_SYS_TIME_H
22021 # include <sys/time.h>
22022 #endif
22023 #include <time.h>
22024 struct timespec ts;
22025 struct stat st;
22028 main ()
22031 st.st_atim = ts;
22034 return 0;
22036 _ACEOF
22037 if ac_fn_c_try_compile "$LINENO"; then :
22038 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
22039 else
22040 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
22042 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
22045 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
22046 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
22048 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
22051 else
22052 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>
22053 #include <sys/stat.h>
22055 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
22057 cat >>confdefs.h <<_ACEOF
22058 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
22059 _ACEOF
22062 else
22063 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
22064 #include <sys/stat.h>
22066 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
22068 cat >>confdefs.h <<_ACEOF
22069 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
22070 _ACEOF
22073 else
22074 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>
22075 #include <sys/stat.h>
22077 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
22079 cat >>confdefs.h <<_ACEOF
22080 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
22081 _ACEOF
22096 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>
22097 #include <sys/stat.h>
22099 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
22101 cat >>confdefs.h <<_ACEOF
22102 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
22103 _ACEOF
22106 else
22107 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
22108 #include <sys/stat.h>
22110 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
22112 cat >>confdefs.h <<_ACEOF
22113 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
22114 _ACEOF
22117 else
22118 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>
22119 #include <sys/stat.h>
22121 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
22123 cat >>confdefs.h <<_ACEOF
22124 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
22125 _ACEOF
22136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
22137 $as_echo_n "checking for working stdalign.h... " >&6; }
22138 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
22139 $as_echo_n "(cached) " >&6
22140 else
22141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22142 /* end confdefs.h. */
22143 #include <stdalign.h>
22144 #include <stddef.h>
22146 /* Test that alignof yields a result consistent with offsetof.
22147 This catches GCC bug 52023
22148 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
22149 #ifdef __cplusplus
22150 template <class t> struct alignof_helper { char a; t b; };
22151 # define ao(type) offsetof (alignof_helper<type>, b)
22152 #else
22153 # define ao(type) offsetof (struct { char a; type b; }, b)
22154 #endif
22155 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
22156 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
22157 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
22159 /* Test _Alignas only on platforms where gnulib can help. */
22160 #if \
22161 (__GNUC__ || __IBMC__ || __IBMCPP__ \
22162 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
22163 int alignas (8) alignas_int = 1;
22164 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
22165 #endif
22168 main ()
22172 return 0;
22174 _ACEOF
22175 if ac_fn_c_try_compile "$LINENO"; then :
22176 gl_cv_header_working_stdalign_h=yes
22177 else
22178 gl_cv_header_working_stdalign_h=no
22180 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
22183 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
22185 if test $gl_cv_header_working_stdalign_h = yes; then
22186 STDALIGN_H=''
22187 else
22188 STDALIGN_H='stdalign.h'
22192 if test -n "$STDALIGN_H"; then
22193 GL_GENERATE_STDALIGN_H_TRUE=
22194 GL_GENERATE_STDALIGN_H_FALSE='#'
22195 else
22196 GL_GENERATE_STDALIGN_H_TRUE='#'
22197 GL_GENERATE_STDALIGN_H_FALSE=
22202 STDARG_H=''
22203 NEXT_STDARG_H='<stdarg.h>'
22204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
22205 $as_echo_n "checking for va_copy... " >&6; }
22206 if test "${gl_cv_func_va_copy+set}" = set; then :
22207 $as_echo_n "(cached) " >&6
22208 else
22210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22211 /* end confdefs.h. */
22212 #include <stdarg.h>
22214 main ()
22217 #ifndef va_copy
22218 void (*func) (va_list, va_list) = va_copy;
22219 #endif
22222 return 0;
22224 _ACEOF
22225 if ac_fn_c_try_compile "$LINENO"; then :
22226 gl_cv_func_va_copy=yes
22227 else
22228 gl_cv_func_va_copy=no
22230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
22234 $as_echo "$gl_cv_func_va_copy" >&6; }
22235 if test $gl_cv_func_va_copy = no; then
22236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22237 /* end confdefs.h. */
22238 #if defined _AIX && !defined __GNUC__
22239 AIX vaccine
22240 #endif
22242 _ACEOF
22243 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22244 $EGREP "vaccine" >/dev/null 2>&1; then :
22245 gl_aixcc=yes
22246 else
22247 gl_aixcc=no
22249 rm -f conftest*
22251 if test $gl_aixcc = yes; then
22252 STDARG_H=stdarg.h
22261 if test $gl_cv_have_include_next = yes; then
22262 gl_cv_next_stdarg_h='<'stdarg.h'>'
22263 else
22264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22265 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22266 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22267 $as_echo_n "(cached) " >&6
22268 else
22270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22271 /* end confdefs.h. */
22272 #include <stdarg.h>
22274 _ACEOF
22275 case "$host_os" in
22276 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22277 *) gl_absname_cpp="$ac_cpp" ;;
22278 esac
22280 case "$host_os" in
22281 mingw*)
22282 gl_dirsep_regex='[/\\]'
22285 gl_dirsep_regex='\/'
22287 esac
22288 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22290 gl_header_literal_regex=`echo 'stdarg.h' \
22291 | sed -e "$gl_make_literal_regex_sed"`
22292 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22293 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22294 s|^/[^/]|//&|
22298 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22299 sed -n "$gl_absolute_header_sed"`'"'
22303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22304 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22306 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22308 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22309 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22310 gl_next_as_first_directive='<'stdarg.h'>'
22311 else
22312 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22313 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22315 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22320 if test "$gl_cv_next_stdarg_h" = '""'; then
22321 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22322 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22324 else
22326 saved_as_echo_n="$as_echo_n"
22327 as_echo_n=':'
22328 if test "${gl_cv_func___va_copy+set}" = set; then :
22329 $as_echo_n "(cached) " >&6
22330 else
22332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22333 /* end confdefs.h. */
22334 #include <stdarg.h>
22336 main ()
22339 #ifndef __va_copy
22340 error, bail out
22341 #endif
22344 return 0;
22346 _ACEOF
22347 if ac_fn_c_try_compile "$LINENO"; then :
22348 gl_cv_func___va_copy=yes
22349 else
22350 gl_cv_func___va_copy=no
22352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22355 as_echo_n="$saved_as_echo_n"
22357 if test $gl_cv_func___va_copy = yes; then
22359 $as_echo "#define va_copy __va_copy" >>confdefs.h
22361 else
22364 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22370 if test -n "$STDARG_H"; then
22371 GL_GENERATE_STDARG_H_TRUE=
22372 GL_GENERATE_STDARG_H_FALSE='#'
22373 else
22374 GL_GENERATE_STDARG_H_TRUE='#'
22375 GL_GENERATE_STDARG_H_FALSE=
22383 # Define two additional variables used in the Makefile substitution.
22385 if test "$ac_cv_header_stdbool_h" = yes; then
22386 STDBOOL_H=''
22387 else
22388 STDBOOL_H='stdbool.h'
22391 if test -n "$STDBOOL_H"; then
22392 GL_GENERATE_STDBOOL_H_TRUE=
22393 GL_GENERATE_STDBOOL_H_FALSE='#'
22394 else
22395 GL_GENERATE_STDBOOL_H_TRUE='#'
22396 GL_GENERATE_STDBOOL_H_FALSE=
22400 if test "$ac_cv_type__Bool" = yes; then
22401 HAVE__BOOL=1
22402 else
22403 HAVE__BOOL=0
22410 STDDEF_H=
22411 if test $gt_cv_c_wchar_t = no; then
22412 HAVE_WCHAR_T=0
22413 STDDEF_H=stddef.h
22415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22416 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22417 if test "${gl_cv_decl_null_works+set}" = set; then :
22418 $as_echo_n "(cached) " >&6
22419 else
22420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22421 /* end confdefs.h. */
22422 #include <stddef.h>
22423 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22426 main ()
22430 return 0;
22432 _ACEOF
22433 if ac_fn_c_try_compile "$LINENO"; then :
22434 gl_cv_decl_null_works=yes
22435 else
22436 gl_cv_decl_null_works=no
22438 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22441 $as_echo "$gl_cv_decl_null_works" >&6; }
22442 if test $gl_cv_decl_null_works = no; then
22443 REPLACE_NULL=1
22444 STDDEF_H=stddef.h
22447 if test -n "$STDDEF_H"; then
22448 GL_GENERATE_STDDEF_H_TRUE=
22449 GL_GENERATE_STDDEF_H_FALSE='#'
22450 else
22451 GL_GENERATE_STDDEF_H_TRUE='#'
22452 GL_GENERATE_STDDEF_H_FALSE=
22455 if test -n "$STDDEF_H"; then
22464 if test $gl_cv_have_include_next = yes; then
22465 gl_cv_next_stddef_h='<'stddef.h'>'
22466 else
22467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22468 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22469 if test "${gl_cv_next_stddef_h+set}" = set; then :
22470 $as_echo_n "(cached) " >&6
22471 else
22473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22474 /* end confdefs.h. */
22475 #include <stddef.h>
22477 _ACEOF
22478 case "$host_os" in
22479 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22480 *) gl_absname_cpp="$ac_cpp" ;;
22481 esac
22483 case "$host_os" in
22484 mingw*)
22485 gl_dirsep_regex='[/\\]'
22488 gl_dirsep_regex='\/'
22490 esac
22491 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22493 gl_header_literal_regex=`echo 'stddef.h' \
22494 | sed -e "$gl_make_literal_regex_sed"`
22495 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22496 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22497 s|^/[^/]|//&|
22501 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22502 sed -n "$gl_absolute_header_sed"`'"'
22506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
22507 $as_echo "$gl_cv_next_stddef_h" >&6; }
22509 NEXT_STDDEF_H=$gl_cv_next_stddef_h
22511 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22512 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22513 gl_next_as_first_directive='<'stddef.h'>'
22514 else
22515 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22516 gl_next_as_first_directive=$gl_cv_next_stddef_h
22518 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
22537 if test $gl_cv_have_include_next = yes; then
22538 gl_cv_next_stdio_h='<'stdio.h'>'
22539 else
22540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
22541 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
22542 if test "${gl_cv_next_stdio_h+set}" = set; then :
22543 $as_echo_n "(cached) " >&6
22544 else
22546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22547 /* end confdefs.h. */
22548 #include <stdio.h>
22550 _ACEOF
22551 case "$host_os" in
22552 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22553 *) gl_absname_cpp="$ac_cpp" ;;
22554 esac
22556 case "$host_os" in
22557 mingw*)
22558 gl_dirsep_regex='[/\\]'
22561 gl_dirsep_regex='\/'
22563 esac
22564 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22566 gl_header_literal_regex=`echo 'stdio.h' \
22567 | sed -e "$gl_make_literal_regex_sed"`
22568 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22569 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22570 s|^/[^/]|//&|
22574 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22575 sed -n "$gl_absolute_header_sed"`'"'
22579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
22580 $as_echo "$gl_cv_next_stdio_h" >&6; }
22582 NEXT_STDIO_H=$gl_cv_next_stdio_h
22584 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22585 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22586 gl_next_as_first_directive='<'stdio.h'>'
22587 else
22588 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22589 gl_next_as_first_directive=$gl_cv_next_stdio_h
22591 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
22597 GNULIB_FSCANF=1
22600 cat >>confdefs.h <<_ACEOF
22601 #define GNULIB_FSCANF 1
22602 _ACEOF
22605 GNULIB_SCANF=1
22608 cat >>confdefs.h <<_ACEOF
22609 #define GNULIB_SCANF 1
22610 _ACEOF
22613 GNULIB_FGETC=1
22614 GNULIB_GETC=1
22615 GNULIB_GETCHAR=1
22616 GNULIB_FGETS=1
22617 GNULIB_FREAD=1
22620 GNULIB_FPRINTF=1
22621 GNULIB_PRINTF=1
22622 GNULIB_VFPRINTF=1
22623 GNULIB_VPRINTF=1
22624 GNULIB_FPUTC=1
22625 GNULIB_PUTC=1
22626 GNULIB_PUTCHAR=1
22627 GNULIB_FPUTS=1
22628 GNULIB_PUTS=1
22629 GNULIB_FWRITE=1
22645 if test $gl_cv_have_include_next = yes; then
22646 gl_cv_next_stdlib_h='<'stdlib.h'>'
22647 else
22648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
22649 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
22650 if test "${gl_cv_next_stdlib_h+set}" = set; then :
22651 $as_echo_n "(cached) " >&6
22652 else
22654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22655 /* end confdefs.h. */
22656 #include <stdlib.h>
22658 _ACEOF
22659 case "$host_os" in
22660 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22661 *) gl_absname_cpp="$ac_cpp" ;;
22662 esac
22664 case "$host_os" in
22665 mingw*)
22666 gl_dirsep_regex='[/\\]'
22669 gl_dirsep_regex='\/'
22671 esac
22672 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22674 gl_header_literal_regex=`echo 'stdlib.h' \
22675 | sed -e "$gl_make_literal_regex_sed"`
22676 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22677 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22678 s|^/[^/]|//&|
22682 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22683 sed -n "$gl_absolute_header_sed"`'"'
22687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
22688 $as_echo "$gl_cv_next_stdlib_h" >&6; }
22690 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
22692 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22693 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22694 gl_next_as_first_directive='<'stdlib.h'>'
22695 else
22696 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22697 gl_next_as_first_directive=$gl_cv_next_stdlib_h
22699 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
22709 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
22717 $as_echo "#define my_strftime nstrftime" >>confdefs.h
22726 if test "$ac_cv_have_decl_strtoimax" != yes; then
22727 HAVE_DECL_STRTOIMAX=0
22730 if test $ac_cv_func_strtoimax = yes; then
22731 HAVE_STRTOIMAX=1
22732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
22733 $as_echo_n "checking whether strtoimax works... " >&6; }
22734 if test "${gl_cv_func_strtoimax+set}" = set; then :
22735 $as_echo_n "(cached) " >&6
22736 else
22737 if test "$cross_compiling" = yes; then :
22738 case "$host_os" in
22739 # Guess no on AIX 5.
22740 aix5*) gl_cv_func_strtoimax="guessing no" ;;
22741 # Guess yes otherwise.
22742 *) gl_cv_func_strtoimax="guessing yes" ;;
22743 esac
22745 else
22746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22747 /* end confdefs.h. */
22749 #include <errno.h>
22750 #include <string.h>
22751 #include <inttypes.h>
22752 int main ()
22754 if (sizeof (intmax_t) > sizeof (int))
22756 const char *s = "4294967295";
22757 char *p;
22758 intmax_t res;
22759 errno = 0;
22760 res = strtoimax (s, &p, 10);
22761 if (p != s + strlen (s))
22762 return 1;
22763 if (errno != 0)
22764 return 2;
22765 if (res != (intmax_t) 65535 * (intmax_t) 65537)
22766 return 3;
22768 else
22770 const char *s = "2147483647";
22771 char *p;
22772 intmax_t res;
22773 errno = 0;
22774 res = strtoimax (s, &p, 10);
22775 if (p != s + strlen (s))
22776 return 1;
22777 if (errno != 0)
22778 return 2;
22779 if (res != 2147483647)
22780 return 3;
22782 return 0;
22785 _ACEOF
22786 if ac_fn_c_try_run "$LINENO"; then :
22787 gl_cv_func_strtoimax=yes
22788 else
22789 gl_cv_func_strtoimax=no
22791 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22792 conftest.$ac_objext conftest.beam conftest.$ac_ext
22797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
22798 $as_echo "$gl_cv_func_strtoimax" >&6; }
22799 case "$gl_cv_func_strtoimax" in
22800 *no) REPLACE_STRTOIMAX=1 ;;
22801 esac
22802 else
22803 HAVE_STRTOIMAX=0
22806 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
22815 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
22818 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
22819 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
22820 ac_have_decl=1
22821 else
22822 ac_have_decl=0
22825 cat >>confdefs.h <<_ACEOF
22826 #define HAVE_DECL_STRTOLL $ac_have_decl
22827 _ACEOF
22837 GNULIB_STRTOIMAX=1
22847 if test "$ac_cv_have_decl_strtoumax" != yes; then
22848 HAVE_DECL_STRTOUMAX=0
22851 if test $ac_cv_func_strtoumax = no; then
22860 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
22863 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
22864 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
22865 ac_have_decl=1
22866 else
22867 ac_have_decl=0
22870 cat >>confdefs.h <<_ACEOF
22871 #define HAVE_DECL_STRTOULL $ac_have_decl
22872 _ACEOF
22882 GNULIB_STRTOUMAX=1
22890 if test $ac_cv_func_symlink = no; then
22891 HAVE_SYMLINK=0
22892 else
22893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
22894 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
22895 if test "${gl_cv_func_symlink_works+set}" = set; then :
22896 $as_echo_n "(cached) " >&6
22897 else
22898 if test "$cross_compiling" = yes; then :
22899 case "$host_os" in
22900 # Guess yes on glibc systems.
22901 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
22902 # If we don't know, assume the worst.
22903 *) gl_cv_func_symlink_works="guessing no" ;;
22904 esac
22906 else
22907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22908 /* end confdefs.h. */
22909 #include <unistd.h>
22912 main ()
22914 int result = 0;
22915 if (!symlink ("a", "conftest.link/"))
22916 result |= 1;
22917 if (symlink ("conftest.f", "conftest.lnk2"))
22918 result |= 2;
22919 else if (!symlink ("a", "conftest.lnk2/"))
22920 result |= 4;
22921 return result;
22924 return 0;
22926 _ACEOF
22927 if ac_fn_c_try_run "$LINENO"; then :
22928 gl_cv_func_symlink_works=yes
22929 else
22930 gl_cv_func_symlink_works=no
22932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22933 conftest.$ac_objext conftest.beam conftest.$ac_ext
22936 rm -f conftest.f conftest.link conftest.lnk2
22938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
22939 $as_echo "$gl_cv_func_symlink_works" >&6; }
22940 case "$gl_cv_func_symlink_works" in
22941 *yes) ;;
22943 REPLACE_SYMLINK=1
22945 esac
22948 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
22957 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
22965 GNULIB_SYMLINK=1
22974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
22975 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
22976 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
22977 $as_echo_n "(cached) " >&6
22978 else
22980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22981 /* end confdefs.h. */
22982 #include <sys/select.h>
22984 main ()
22986 struct timeval b;
22988 return 0;
22990 _ACEOF
22991 if ac_fn_c_try_compile "$LINENO"; then :
22992 gl_cv_header_sys_select_h_selfcontained=yes
22993 else
22994 gl_cv_header_sys_select_h_selfcontained=no
22996 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22997 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
22998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22999 /* end confdefs.h. */
23000 #include <sys/select.h>
23002 main ()
23004 int memset; int bzero;
23006 return 0;
23009 _ACEOF
23010 if ac_fn_c_try_compile "$LINENO"; then :
23011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23012 /* end confdefs.h. */
23013 #include <sys/select.h>
23015 main ()
23018 #undef memset
23019 #define memset nonexistent_memset
23020 extern
23021 #ifdef __cplusplus
23023 #endif
23024 void *memset (void *, int, unsigned long);
23025 #undef bzero
23026 #define bzero nonexistent_bzero
23027 extern
23028 #ifdef __cplusplus
23030 #endif
23031 void bzero (void *, unsigned long);
23032 fd_set fds;
23033 FD_ZERO (&fds);
23036 return 0;
23039 _ACEOF
23040 if ac_fn_c_try_link "$LINENO"; then :
23042 else
23043 gl_cv_header_sys_select_h_selfcontained=no
23045 rm -f core conftest.err conftest.$ac_objext \
23046 conftest$ac_exeext conftest.$ac_ext
23049 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
23054 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
23064 if test $gl_cv_have_include_next = yes; then
23065 gl_cv_next_sys_select_h='<'sys/select.h'>'
23066 else
23067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
23068 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
23069 if test "${gl_cv_next_sys_select_h+set}" = set; then :
23070 $as_echo_n "(cached) " >&6
23071 else
23073 if test $ac_cv_header_sys_select_h = yes; then
23076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23077 /* end confdefs.h. */
23078 #include <sys/select.h>
23080 _ACEOF
23081 case "$host_os" in
23082 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23083 *) gl_absname_cpp="$ac_cpp" ;;
23084 esac
23086 case "$host_os" in
23087 mingw*)
23088 gl_dirsep_regex='[/\\]'
23091 gl_dirsep_regex='\/'
23093 esac
23094 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23096 gl_header_literal_regex=`echo 'sys/select.h' \
23097 | sed -e "$gl_make_literal_regex_sed"`
23098 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23099 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23100 s|^/[^/]|//&|
23104 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23105 sed -n "$gl_absolute_header_sed"`'"'
23106 else
23107 gl_cv_next_sys_select_h='<'sys/select.h'>'
23112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
23113 $as_echo "$gl_cv_next_sys_select_h" >&6; }
23115 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
23117 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23118 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23119 gl_next_as_first_directive='<'sys/select.h'>'
23120 else
23121 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23122 gl_next_as_first_directive=$gl_cv_next_sys_select_h
23124 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
23129 if test $ac_cv_header_sys_select_h = yes; then
23130 HAVE_SYS_SELECT_H=1
23131 else
23132 HAVE_SYS_SELECT_H=0
23139 if test $ac_cv_header_sys_socket_h != yes; then
23140 for ac_header in winsock2.h
23141 do :
23142 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23143 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
23144 cat >>confdefs.h <<_ACEOF
23145 #define HAVE_WINSOCK2_H 1
23146 _ACEOF
23150 done
23153 if test "$ac_cv_header_winsock2_h" = yes; then
23154 HAVE_WINSOCK2_H=1
23155 UNISTD_H_HAVE_WINSOCK2_H=1
23156 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23157 else
23158 HAVE_WINSOCK2_H=0
23182 if test $gl_cv_have_include_next = yes; then
23183 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23184 else
23185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23186 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23187 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
23188 $as_echo_n "(cached) " >&6
23189 else
23191 if test $ac_cv_header_sys_stat_h = yes; then
23194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23195 /* end confdefs.h. */
23196 #include <sys/stat.h>
23198 _ACEOF
23199 case "$host_os" in
23200 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23201 *) gl_absname_cpp="$ac_cpp" ;;
23202 esac
23204 case "$host_os" in
23205 mingw*)
23206 gl_dirsep_regex='[/\\]'
23209 gl_dirsep_regex='\/'
23211 esac
23212 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23214 gl_header_literal_regex=`echo 'sys/stat.h' \
23215 | sed -e "$gl_make_literal_regex_sed"`
23216 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23217 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23218 s|^/[^/]|//&|
23222 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23223 sed -n "$gl_absolute_header_sed"`'"'
23224 else
23225 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23231 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23233 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23235 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23236 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23237 gl_next_as_first_directive='<'sys/stat.h'>'
23238 else
23239 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23240 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23242 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23254 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23256 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23260 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23261 #include <sys/stat.h>
23263 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23265 else
23267 $as_echo "#define nlink_t int" >>confdefs.h
23288 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23290 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23291 ac_have_decl=1
23292 else
23293 ac_have_decl=0
23296 cat >>confdefs.h <<_ACEOF
23297 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23298 _ACEOF
23300 if test $ac_cv_have_decl_localtime_r = no; then
23301 HAVE_DECL_LOCALTIME_R=0
23305 if test $ac_cv_func_localtime_r = yes; then
23306 HAVE_LOCALTIME_R=1
23307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23308 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23309 if test "${gl_cv_time_r_posix+set}" = set; then :
23310 $as_echo_n "(cached) " >&6
23311 else
23312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23313 /* end confdefs.h. */
23314 #include <time.h>
23316 main ()
23318 /* We don't need to append 'restrict's to the argument types,
23319 even though the POSIX signature has the 'restrict's,
23320 since C99 says they can't affect type compatibility. */
23321 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23322 if (ptr) return 0;
23323 /* Check the return type is a pointer.
23324 On HP-UX 10 it is 'int'. */
23325 *localtime_r (0, 0);
23327 return 0;
23330 _ACEOF
23331 if ac_fn_c_try_compile "$LINENO"; then :
23332 gl_cv_time_r_posix=yes
23333 else
23334 gl_cv_time_r_posix=no
23336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23340 $as_echo "$gl_cv_time_r_posix" >&6; }
23341 if test $gl_cv_time_r_posix = yes; then
23342 REPLACE_LOCALTIME_R=0
23343 else
23344 REPLACE_LOCALTIME_R=1
23346 else
23347 HAVE_LOCALTIME_R=0
23350 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23359 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23370 GNULIB_TIME_R=1
23390 if test $gl_cv_have_include_next = yes; then
23391 gl_cv_next_unistd_h='<'unistd.h'>'
23392 else
23393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23394 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23395 if test "${gl_cv_next_unistd_h+set}" = set; then :
23396 $as_echo_n "(cached) " >&6
23397 else
23399 if test $ac_cv_header_unistd_h = yes; then
23402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23403 /* end confdefs.h. */
23404 #include <unistd.h>
23406 _ACEOF
23407 case "$host_os" in
23408 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23409 *) gl_absname_cpp="$ac_cpp" ;;
23410 esac
23412 case "$host_os" in
23413 mingw*)
23414 gl_dirsep_regex='[/\\]'
23417 gl_dirsep_regex='\/'
23419 esac
23420 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23422 gl_header_literal_regex=`echo 'unistd.h' \
23423 | sed -e "$gl_make_literal_regex_sed"`
23424 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23425 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23426 s|^/[^/]|//&|
23430 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23431 sed -n "$gl_absolute_header_sed"`'"'
23432 else
23433 gl_cv_next_unistd_h='<'unistd.h'>'
23438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
23439 $as_echo "$gl_cv_next_unistd_h" >&6; }
23441 NEXT_UNISTD_H=$gl_cv_next_unistd_h
23443 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23444 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23445 gl_next_as_first_directive='<'unistd.h'>'
23446 else
23447 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23448 gl_next_as_first_directive=$gl_cv_next_unistd_h
23450 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
23455 if test $ac_cv_header_unistd_h = yes; then
23456 HAVE_UNISTD_H=1
23457 else
23458 HAVE_UNISTD_H=0
23474 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
23475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
23476 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
23477 if test "${gl_cv_func_futimesat_works+set}" = set; then :
23478 $as_echo_n "(cached) " >&6
23479 else
23480 touch conftest.file
23481 if test "$cross_compiling" = yes; then :
23482 case "$host_os" in
23483 # Guess yes on glibc systems.
23484 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
23485 # If we don't know, assume the worst.
23486 *) gl_cv_func_futimesat_works="guessing no" ;;
23487 esac
23489 else
23490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23491 /* end confdefs.h. */
23493 #include <stddef.h>
23494 #include <sys/times.h>
23495 #include <fcntl.h>
23498 main ()
23500 int fd = open ("conftest.file", O_RDWR);
23501 if (fd < 0) return 1;
23502 if (futimesat (fd, NULL, NULL)) return 2;
23505 return 0;
23507 _ACEOF
23508 if ac_fn_c_try_run "$LINENO"; then :
23509 gl_cv_func_futimesat_works=yes
23510 else
23511 gl_cv_func_futimesat_works=no
23513 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23514 conftest.$ac_objext conftest.beam conftest.$ac_ext
23517 rm -f conftest.file
23519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
23520 $as_echo "$gl_cv_func_futimesat_works" >&6; }
23521 case "$gl_cv_func_futimesat_works" in
23522 *yes) ;;
23525 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
23528 esac
23531 gl_gnulib_enabled_dosname=false
23532 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
23533 gl_gnulib_enabled_pathmax=false
23534 gl_gnulib_enabled_stat=false
23535 gl_gnulib_enabled_strtoll=false
23536 gl_gnulib_enabled_strtoull=false
23537 gl_gnulib_enabled_verify=false
23538 func_gl_gnulib_m4code_dosname ()
23540 if ! $gl_gnulib_enabled_dosname; then
23541 gl_gnulib_enabled_dosname=true
23544 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
23546 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23549 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
23552 func_gl_gnulib_m4code_pathmax ()
23554 if ! $gl_gnulib_enabled_pathmax; then
23558 gl_gnulib_enabled_pathmax=true
23561 func_gl_gnulib_m4code_stat ()
23563 if ! $gl_gnulib_enabled_stat; then
23567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
23568 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
23569 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
23570 $as_echo_n "(cached) " >&6
23571 else
23572 if test "$cross_compiling" = yes; then :
23573 case $host_os in
23574 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
23575 *) gl_cv_func_stat_dir_slash="guessing yes";;
23576 esac
23577 else
23578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23579 /* end confdefs.h. */
23580 #include <sys/stat.h>
23583 main ()
23585 struct stat st; return stat (".", &st) != stat ("./", &st);
23587 return 0;
23589 _ACEOF
23590 if ac_fn_c_try_run "$LINENO"; then :
23591 gl_cv_func_stat_dir_slash=yes
23592 else
23593 gl_cv_func_stat_dir_slash=no
23595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23596 conftest.$ac_objext conftest.beam conftest.$ac_ext
23600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
23601 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
23602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
23603 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
23604 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
23605 $as_echo_n "(cached) " >&6
23606 else
23607 touch conftest.tmp
23608 # Assume that if we have lstat, we can also check symlinks.
23609 if test $ac_cv_func_lstat = yes; then
23610 ln -s conftest.tmp conftest.lnk
23612 if test "$cross_compiling" = yes; then :
23613 case "$host_os" in
23614 # Guess yes on glibc systems.
23615 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
23616 # If we don't know, assume the worst.
23617 *) gl_cv_func_stat_file_slash="guessing no" ;;
23618 esac
23620 else
23621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23622 /* end confdefs.h. */
23623 #include <sys/stat.h>
23626 main ()
23628 int result = 0;
23629 struct stat st;
23630 if (!stat ("conftest.tmp/", &st))
23631 result |= 1;
23632 #if HAVE_LSTAT
23633 if (!stat ("conftest.lnk/", &st))
23634 result |= 2;
23635 #endif
23636 return result;
23639 return 0;
23641 _ACEOF
23642 if ac_fn_c_try_run "$LINENO"; then :
23643 gl_cv_func_stat_file_slash=yes
23644 else
23645 gl_cv_func_stat_file_slash=no
23647 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23648 conftest.$ac_objext conftest.beam conftest.$ac_ext
23651 rm -f conftest.tmp conftest.lnk
23653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
23654 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
23655 case $gl_cv_func_stat_dir_slash in
23656 *no) REPLACE_STAT=1
23658 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
23660 esac
23661 case $gl_cv_func_stat_file_slash in
23662 *no) REPLACE_STAT=1
23664 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
23666 esac
23668 if test $REPLACE_STAT = 1; then
23677 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
23689 GNULIB_STAT=1
23695 gl_gnulib_enabled_stat=true
23696 if test $REPLACE_STAT = 1; then
23697 func_gl_gnulib_m4code_dosname
23699 if test $REPLACE_STAT = 1; then
23700 func_gl_gnulib_m4code_pathmax
23702 if test $REPLACE_STAT = 1; then
23703 func_gl_gnulib_m4code_verify
23707 func_gl_gnulib_m4code_strtoll ()
23709 if ! $gl_gnulib_enabled_strtoll; then
23713 if test "$ac_cv_type_long_long_int" = yes; then
23714 for ac_func in strtoll
23715 do :
23716 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
23717 if test "x$ac_cv_func_strtoll" = x""yes; then :
23718 cat >>confdefs.h <<_ACEOF
23719 #define HAVE_STRTOLL 1
23720 _ACEOF
23723 done
23725 if test $ac_cv_func_strtoll = no; then
23726 HAVE_STRTOLL=0
23730 if test $HAVE_STRTOLL = 0; then
23739 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
23750 GNULIB_STRTOLL=1
23756 gl_gnulib_enabled_strtoll=true
23759 func_gl_gnulib_m4code_strtoull ()
23761 if ! $gl_gnulib_enabled_strtoull; then
23765 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
23766 for ac_func in strtoull
23767 do :
23768 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
23769 if test "x$ac_cv_func_strtoull" = x""yes; then :
23770 cat >>confdefs.h <<_ACEOF
23771 #define HAVE_STRTOULL 1
23772 _ACEOF
23775 done
23777 if test $ac_cv_func_strtoull = no; then
23778 HAVE_STRTOULL=0
23782 if test $HAVE_STRTOULL = 0; then
23791 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
23802 GNULIB_STRTOULL=1
23808 gl_gnulib_enabled_strtoull=true
23811 func_gl_gnulib_m4code_verify ()
23813 if ! $gl_gnulib_enabled_verify; then
23814 gl_gnulib_enabled_verify=true
23817 if test $REPLACE_GETOPT = 1; then
23818 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
23820 if test $REPLACE_LSTAT = 1; then
23821 func_gl_gnulib_m4code_dosname
23823 if test $REPLACE_LSTAT = 1; then
23824 func_gl_gnulib_m4code_stat
23826 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
23827 func_gl_gnulib_m4code_stat
23829 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
23830 func_gl_gnulib_m4code_strtoll
23832 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23833 func_gl_gnulib_m4code_verify
23835 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
23836 func_gl_gnulib_m4code_strtoull
23838 if test $ac_cv_func_strtoumax = no; then
23839 func_gl_gnulib_m4code_verify
23842 if $gl_gnulib_enabled_dosname; then
23843 gl_GNULIB_ENABLED_dosname_TRUE=
23844 gl_GNULIB_ENABLED_dosname_FALSE='#'
23845 else
23846 gl_GNULIB_ENABLED_dosname_TRUE='#'
23847 gl_GNULIB_ENABLED_dosname_FALSE=
23850 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23851 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
23852 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
23853 else
23854 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
23855 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
23858 if $gl_gnulib_enabled_pathmax; then
23859 gl_GNULIB_ENABLED_pathmax_TRUE=
23860 gl_GNULIB_ENABLED_pathmax_FALSE='#'
23861 else
23862 gl_GNULIB_ENABLED_pathmax_TRUE='#'
23863 gl_GNULIB_ENABLED_pathmax_FALSE=
23866 if $gl_gnulib_enabled_stat; then
23867 gl_GNULIB_ENABLED_stat_TRUE=
23868 gl_GNULIB_ENABLED_stat_FALSE='#'
23869 else
23870 gl_GNULIB_ENABLED_stat_TRUE='#'
23871 gl_GNULIB_ENABLED_stat_FALSE=
23874 if $gl_gnulib_enabled_strtoll; then
23875 gl_GNULIB_ENABLED_strtoll_TRUE=
23876 gl_GNULIB_ENABLED_strtoll_FALSE='#'
23877 else
23878 gl_GNULIB_ENABLED_strtoll_TRUE='#'
23879 gl_GNULIB_ENABLED_strtoll_FALSE=
23882 if $gl_gnulib_enabled_strtoull; then
23883 gl_GNULIB_ENABLED_strtoull_TRUE=
23884 gl_GNULIB_ENABLED_strtoull_FALSE='#'
23885 else
23886 gl_GNULIB_ENABLED_strtoull_TRUE='#'
23887 gl_GNULIB_ENABLED_strtoull_FALSE=
23890 if $gl_gnulib_enabled_verify; then
23891 gl_GNULIB_ENABLED_verify_TRUE=
23892 gl_GNULIB_ENABLED_verify_FALSE='#'
23893 else
23894 gl_GNULIB_ENABLED_verify_TRUE='#'
23895 gl_GNULIB_ENABLED_verify_FALSE=
23898 # End of code from modules
23908 gltests_libdeps=
23909 gltests_ltlibdeps=
23919 gl_source_base='tests'
23920 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
23922 gl_module_indicator_condition=$gltests_WITNESS
23933 LIBGNU_LIBDEPS="$gl_libdeps"
23935 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
23938 CFLAGS=$SAVE_CFLAGS
23939 LIBS=$SAVE_LIBS
23941 case "$opsys" in
23942 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
23944 darwin)
23945 ## The -headerpad option tells ld (see man page) to leave room at the
23946 ## end of the header for adding load commands. Needed for dumping.
23947 ## 0x690 is the total size of 30 segment load commands (at 56
23948 ## each); under Cocoa 31 commands are required.
23949 if test "$HAVE_NS" = "yes"; then
23950 libs_nsgui="-framework AppKit"
23951 headerpad_extra=6C8
23952 else
23953 libs_nsgui=
23954 headerpad_extra=690
23956 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
23958 ## This is here because src/Makefile.in did some extra fiddling around
23959 ## with LD_SWITCH_SYSTEM. The cpp logic was:
23960 ## #ifndef LD_SWITCH_SYSTEM
23961 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
23962 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
23963 ## not using gcc, darwin.
23964 ## Because this was done in src/Makefile.in, the resulting part of
23965 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
23966 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
23967 ## rather than LD_SWITCH_SYSTEM.
23968 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
23969 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
23972 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
23973 ## find X at run-time.
23974 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
23975 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
23976 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
23977 ## had different values in configure (in ac_link) and src/Makefile.in.
23978 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
23979 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
23981 *) LD_SWITCH_SYSTEM_TEMACS= ;;
23982 esac
23984 if test "$NS_IMPL_GNUSTEP" = "yes"; then
23985 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
23991 LD_FIRSTFLAG=
23992 ORDINARY_LINK=
23993 case "$opsys" in
23994 ## gnu: GNU needs its own crt0.
23995 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
23997 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
23998 ## library search parth, i.e. it won't search /usr/lib for libc and
23999 ## friends. Using -nostartfiles instead avoids this problem, and
24000 ## will also work on earlier NetBSD releases.
24001 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
24003 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
24004 ## MkLinux/LinuxPPC needs this.
24005 ## s390x-* only supports opsys = gnu-linux so it can be added here.
24006 gnu-*)
24007 case "$canonical" in
24008 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
24009 esac
24011 esac
24014 if test "x$ORDINARY_LINK" = "xyes"; then
24016 LD_FIRSTFLAG=""
24018 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
24021 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
24022 ## freebsd, gnu-* not on powerpc*|s390x*.
24023 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
24025 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
24026 ## places that are difficult to figure out at make time. Fortunately,
24027 ## these same versions allow you to pass arbitrary flags on to the
24028 ## linker, so there is no reason not to use it as a linker.
24030 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
24031 ## searching for libraries in its internal directories, so we have to
24032 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
24033 LD_FIRSTFLAG="-nostdlib"
24036 ## FIXME? What setting of EDIT_LDFLAGS should this have?
24037 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
24042 ## FIXME? The logic here is not precisely the same as that above.
24043 ## There is no check here for a pre-defined LD_FIRSTFLAG.
24044 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
24045 LIB_GCC=
24046 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
24048 case "$opsys" in
24049 freebsd|netbsd|openbsd) LIB_GCC= ;;
24051 gnu-*)
24052 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
24053 ## build on ARM EABI under GNU/Linux. (Bug#5518)
24054 case $host_cpu in
24055 arm*)
24056 LIB_GCC="-lgcc_s"
24059 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
24060 ## immediately undefine it again and redefine it to empty.
24061 ## Was the C_SWITCH_X_SITE part really necessary?
24062 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
24063 LIB_GCC=
24065 esac
24068 ## Ask GCC where to find libgcc.a.
24069 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
24070 esac
24074 ## If we're using X11/GNUstep, define some consequences.
24075 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
24077 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
24080 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
24087 #### Report on what we decided to do.
24088 #### Report GTK as a toolkit, even if it doesn't use Xt.
24089 #### It makes printing result more understandable as using GTK sets
24090 #### toolkit_scroll_bars to yes by default.
24091 if test "${HAVE_GTK}" = "yes"; then
24092 if test "${with_gtk3}" = "yes"; then
24093 USE_X_TOOLKIT=GTK3
24094 else
24095 USE_X_TOOLKIT=GTK
24099 echo "
24100 Configured for \`${canonical}'.
24102 Where should the build process find the source code? ${srcdir}
24103 What compiler should emacs be built with? ${CC} ${CFLAGS}
24104 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
24105 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
24106 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
24107 What window system should Emacs use? ${window_system}
24108 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
24110 if test -n "${x_includes}"; then
24111 echo " Where do we find X Windows header files? ${x_includes}"
24112 else
24113 echo " Where do we find X Windows header files? Standard dirs"
24115 if test -n "${x_libraries}"; then
24116 echo " Where do we find X Windows libraries? ${x_libraries}"
24117 else
24118 echo " Where do we find X Windows libraries? Standard dirs"
24121 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
24122 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
24123 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
24124 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
24125 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
24126 echo " Does Emacs use -lpng? ${HAVE_PNG}"
24127 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
24128 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
24130 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
24131 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
24132 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
24133 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
24134 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
24135 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
24136 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
24138 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
24139 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
24140 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
24141 echo " Does Emacs use -lxft? ${HAVE_XFT}"
24143 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
24144 echo
24146 if test -n "${EMACSDATA}"; then
24147 echo " Environment variable EMACSDATA set to: $EMACSDATA"
24149 if test -n "${EMACSDOC}"; then
24150 echo " Environment variable EMACSDOC set to: $EMACSDOC"
24153 echo
24155 if test "$HAVE_NS" = "yes"; then
24156 echo
24157 echo "You must run \"${MAKE-make} install\" in order to test the built application.
24158 The installed application will go to nextstep/Emacs.app and can be
24159 run or moved from there."
24160 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
24161 echo "The application will be fully self-contained."
24162 else
24163 echo "The lisp resources for the application will be installed under ${prefix}.
24164 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
24165 to run if these resources are not installed."
24167 echo
24170 if test "${opsys}" = "cygwin"; then
24171 case `uname -r` in
24172 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
24173 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
24174 echo
24176 esac
24179 # Remove any trailing slashes in these variables.
24180 test "${prefix}" != NONE &&
24181 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
24182 test "${exec_prefix}" != NONE &&
24183 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
24185 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"
24187 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"
24190 opt_makefile=test/automated/Makefile
24192 if test -f $srcdir/${opt_makefile}.in; then
24193 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24194 ac_config_files="$ac_config_files test/automated/Makefile"
24199 opt_makefile=admin/unidata/Makefile
24201 if test -f $srcdir/${opt_makefile}.in; then
24202 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24203 ac_config_files="$ac_config_files admin/unidata/Makefile"
24208 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
24212 ac_config_commands="$ac_config_commands mkdirs"
24215 ac_config_commands="$ac_config_commands epaths"
24218 ac_config_commands="$ac_config_commands gdbinit"
24221 cat >confcache <<\_ACEOF
24222 # This file is a shell script that caches the results of configure
24223 # tests run on this system so they can be shared between configure
24224 # scripts and configure runs, see configure's option --config-cache.
24225 # It is not useful on other systems. If it contains results you don't
24226 # want to keep, you may remove or edit it.
24228 # config.status only pays attention to the cache file if you give it
24229 # the --recheck option to rerun configure.
24231 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24232 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24233 # following values.
24235 _ACEOF
24237 # The following way of writing the cache mishandles newlines in values,
24238 # but we know of no workaround that is simple, portable, and efficient.
24239 # So, we kill variables containing newlines.
24240 # Ultrix sh set writes to stderr and can't be redirected directly,
24241 # and sets the high bit in the cache file unless we assign to the vars.
24243 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24244 eval ac_val=\$$ac_var
24245 case $ac_val in #(
24246 *${as_nl}*)
24247 case $ac_var in #(
24248 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24249 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24250 esac
24251 case $ac_var in #(
24252 _ | IFS | as_nl) ;; #(
24253 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24254 *) { eval $ac_var=; unset $ac_var;} ;;
24255 esac ;;
24256 esac
24257 done
24259 (set) 2>&1 |
24260 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24261 *${as_nl}ac_space=\ *)
24262 # `set' does not quote correctly, so add quotes: double-quote
24263 # substitution turns \\\\ into \\, and sed turns \\ into \.
24264 sed -n \
24265 "s/'/'\\\\''/g;
24266 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24267 ;; #(
24269 # `set' quotes correctly as required by POSIX, so do not add quotes.
24270 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24272 esac |
24273 sort
24275 sed '
24276 /^ac_cv_env_/b end
24277 t clear
24278 :clear
24279 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24280 t end
24281 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24282 :end' >>confcache
24283 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24284 if test -w "$cache_file"; then
24285 test "x$cache_file" != "x/dev/null" &&
24286 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24287 $as_echo "$as_me: updating cache $cache_file" >&6;}
24288 cat confcache >$cache_file
24289 else
24290 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24291 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24294 rm -f confcache
24296 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24297 # Let make expand exec_prefix.
24298 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24300 DEFS=-DHAVE_CONFIG_H
24302 ac_libobjs=
24303 ac_ltlibobjs=
24304 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24305 # 1. Remove the extension, and $U if already installed.
24306 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24307 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24308 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24309 # will be set to the directory where LIBOBJS objects are built.
24310 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24311 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24312 done
24313 LIBOBJS=$ac_libobjs
24315 LTLIBOBJS=$ac_ltlibobjs
24318 if test -n "$EXEEXT"; then
24319 am__EXEEXT_TRUE=
24320 am__EXEEXT_FALSE='#'
24321 else
24322 am__EXEEXT_TRUE='#'
24323 am__EXEEXT_FALSE=
24326 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24327 as_fn_error "conditional \"AMDEP\" was never defined.
24328 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24330 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24331 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24332 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24334 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24335 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24336 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24338 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24339 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24340 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24343 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
24344 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
24345 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24347 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24348 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24349 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24351 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
24352 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
24353 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24355 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
24356 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
24357 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24359 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24360 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24361 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24363 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24364 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24365 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24367 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
24368 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
24369 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24371 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
24372 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
24373 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24375 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
24376 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
24377 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24379 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
24380 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
24381 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24383 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
24384 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
24385 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24387 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
24388 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
24389 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24391 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
24392 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
24393 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24396 gl_libobjs=
24397 gl_ltlibobjs=
24398 if test -n "$gl_LIBOBJS"; then
24399 # Remove the extension.
24400 sed_drop_objext='s/\.o$//;s/\.obj$//'
24401 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24402 gl_libobjs="$gl_libobjs $i.$ac_objext"
24403 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
24404 done
24406 gl_LIBOBJS=$gl_libobjs
24408 gl_LTLIBOBJS=$gl_ltlibobjs
24412 gltests_libobjs=
24413 gltests_ltlibobjs=
24414 if test -n "$gltests_LIBOBJS"; then
24415 # Remove the extension.
24416 sed_drop_objext='s/\.o$//;s/\.obj$//'
24417 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24418 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
24419 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
24420 done
24422 gltests_LIBOBJS=$gltests_libobjs
24424 gltests_LTLIBOBJS=$gltests_ltlibobjs
24428 : ${CONFIG_STATUS=./config.status}
24429 ac_write_fail=0
24430 ac_clean_files_save=$ac_clean_files
24431 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24432 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
24433 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
24434 as_write_fail=0
24435 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
24436 #! $SHELL
24437 # Generated by $as_me.
24438 # Run this file to recreate the current configuration.
24439 # Compiler output produced by configure, useful for debugging
24440 # configure, is in config.log if it exists.
24442 debug=false
24443 ac_cs_recheck=false
24444 ac_cs_silent=false
24446 SHELL=\${CONFIG_SHELL-$SHELL}
24447 export SHELL
24448 _ASEOF
24449 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
24450 ## -------------------- ##
24451 ## M4sh Initialization. ##
24452 ## -------------------- ##
24454 # Be more Bourne compatible
24455 DUALCASE=1; export DUALCASE # for MKS sh
24456 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24457 emulate sh
24458 NULLCMD=:
24459 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
24460 # is contrary to our usage. Disable this feature.
24461 alias -g '${1+"$@"}'='"$@"'
24462 setopt NO_GLOB_SUBST
24463 else
24464 case `(set -o) 2>/dev/null` in #(
24465 *posix*) :
24466 set -o posix ;; #(
24467 *) :
24469 esac
24473 as_nl='
24475 export as_nl
24476 # Printing a long string crashes Solaris 7 /usr/bin/printf.
24477 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
24478 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
24479 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
24480 # Prefer a ksh shell builtin over an external printf program on Solaris,
24481 # but without wasting forks for bash or zsh.
24482 if test -z "$BASH_VERSION$ZSH_VERSION" \
24483 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
24484 as_echo='print -r --'
24485 as_echo_n='print -rn --'
24486 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
24487 as_echo='printf %s\n'
24488 as_echo_n='printf %s'
24489 else
24490 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
24491 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
24492 as_echo_n='/usr/ucb/echo -n'
24493 else
24494 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
24495 as_echo_n_body='eval
24496 arg=$1;
24497 case $arg in #(
24498 *"$as_nl"*)
24499 expr "X$arg" : "X\\(.*\\)$as_nl";
24500 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
24501 esac;
24502 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
24504 export as_echo_n_body
24505 as_echo_n='sh -c $as_echo_n_body as_echo'
24507 export as_echo_body
24508 as_echo='sh -c $as_echo_body as_echo'
24511 # The user is always right.
24512 if test "${PATH_SEPARATOR+set}" != set; then
24513 PATH_SEPARATOR=:
24514 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
24515 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
24516 PATH_SEPARATOR=';'
24521 # IFS
24522 # We need space, tab and new line, in precisely that order. Quoting is
24523 # there to prevent editors from complaining about space-tab.
24524 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
24525 # splitting by setting IFS to empty value.)
24526 IFS=" "" $as_nl"
24528 # Find who we are. Look in the path if we contain no directory separator.
24529 case $0 in #((
24530 *[\\/]* ) as_myself=$0 ;;
24531 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24532 for as_dir in $PATH
24534 IFS=$as_save_IFS
24535 test -z "$as_dir" && as_dir=.
24536 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
24537 done
24538 IFS=$as_save_IFS
24541 esac
24542 # We did not find ourselves, most probably we were run as `sh COMMAND'
24543 # in which case we are not to be found in the path.
24544 if test "x$as_myself" = x; then
24545 as_myself=$0
24547 if test ! -f "$as_myself"; then
24548 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
24549 exit 1
24552 # Unset variables that we do not need and which cause bugs (e.g. in
24553 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
24554 # suppresses any "Segmentation fault" message there. '((' could
24555 # trigger a bug in pdksh 5.2.14.
24556 for as_var in BASH_ENV ENV MAIL MAILPATH
24557 do eval test x\${$as_var+set} = xset \
24558 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
24559 done
24560 PS1='$ '
24561 PS2='> '
24562 PS4='+ '
24564 # NLS nuisances.
24565 LC_ALL=C
24566 export LC_ALL
24567 LANGUAGE=C
24568 export LANGUAGE
24570 # CDPATH.
24571 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
24574 # as_fn_error ERROR [LINENO LOG_FD]
24575 # ---------------------------------
24576 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
24577 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
24578 # script with status $?, using 1 if that was 0.
24579 as_fn_error ()
24581 as_status=$?; test $as_status -eq 0 && as_status=1
24582 if test "$3"; then
24583 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
24584 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
24586 $as_echo "$as_me: error: $1" >&2
24587 as_fn_exit $as_status
24588 } # as_fn_error
24591 # as_fn_set_status STATUS
24592 # -----------------------
24593 # Set $? to STATUS, without forking.
24594 as_fn_set_status ()
24596 return $1
24597 } # as_fn_set_status
24599 # as_fn_exit STATUS
24600 # -----------------
24601 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
24602 as_fn_exit ()
24604 set +e
24605 as_fn_set_status $1
24606 exit $1
24607 } # as_fn_exit
24609 # as_fn_unset VAR
24610 # ---------------
24611 # Portably unset VAR.
24612 as_fn_unset ()
24614 { eval $1=; unset $1;}
24616 as_unset=as_fn_unset
24617 # as_fn_append VAR VALUE
24618 # ----------------------
24619 # Append the text in VALUE to the end of the definition contained in VAR. Take
24620 # advantage of any shell optimizations that allow amortized linear growth over
24621 # repeated appends, instead of the typical quadratic growth present in naive
24622 # implementations.
24623 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
24624 eval 'as_fn_append ()
24626 eval $1+=\$2
24628 else
24629 as_fn_append ()
24631 eval $1=\$$1\$2
24633 fi # as_fn_append
24635 # as_fn_arith ARG...
24636 # ------------------
24637 # Perform arithmetic evaluation on the ARGs, and store the result in the
24638 # global $as_val. Take advantage of shells that can avoid forks. The arguments
24639 # must be portable across $(()) and expr.
24640 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
24641 eval 'as_fn_arith ()
24643 as_val=$(( $* ))
24645 else
24646 as_fn_arith ()
24648 as_val=`expr "$@" || test $? -eq 1`
24650 fi # as_fn_arith
24653 if expr a : '\(a\)' >/dev/null 2>&1 &&
24654 test "X`expr 00001 : '.*\(...\)'`" = X001; then
24655 as_expr=expr
24656 else
24657 as_expr=false
24660 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
24661 as_basename=basename
24662 else
24663 as_basename=false
24666 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
24667 as_dirname=dirname
24668 else
24669 as_dirname=false
24672 as_me=`$as_basename -- "$0" ||
24673 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
24674 X"$0" : 'X\(//\)$' \| \
24675 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
24676 $as_echo X/"$0" |
24677 sed '/^.*\/\([^/][^/]*\)\/*$/{
24678 s//\1/
24681 /^X\/\(\/\/\)$/{
24682 s//\1/
24685 /^X\/\(\/\).*/{
24686 s//\1/
24689 s/.*/./; q'`
24691 # Avoid depending upon Character Ranges.
24692 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
24693 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
24694 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
24695 as_cr_digits='0123456789'
24696 as_cr_alnum=$as_cr_Letters$as_cr_digits
24698 ECHO_C= ECHO_N= ECHO_T=
24699 case `echo -n x` in #(((((
24700 -n*)
24701 case `echo 'xy\c'` in
24702 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
24703 xy) ECHO_C='\c';;
24704 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
24705 ECHO_T=' ';;
24706 esac;;
24708 ECHO_N='-n';;
24709 esac
24711 rm -f conf$$ conf$$.exe conf$$.file
24712 if test -d conf$$.dir; then
24713 rm -f conf$$.dir/conf$$.file
24714 else
24715 rm -f conf$$.dir
24716 mkdir conf$$.dir 2>/dev/null
24718 if (echo >conf$$.file) 2>/dev/null; then
24719 if ln -s conf$$.file conf$$ 2>/dev/null; then
24720 as_ln_s='ln -s'
24721 # ... but there are two gotchas:
24722 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
24723 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
24724 # In both cases, we have to default to `cp -p'.
24725 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
24726 as_ln_s='cp -p'
24727 elif ln conf$$.file conf$$ 2>/dev/null; then
24728 as_ln_s=ln
24729 else
24730 as_ln_s='cp -p'
24732 else
24733 as_ln_s='cp -p'
24735 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
24736 rmdir conf$$.dir 2>/dev/null
24739 # as_fn_mkdir_p
24740 # -------------
24741 # Create "$as_dir" as a directory, including parents if necessary.
24742 as_fn_mkdir_p ()
24745 case $as_dir in #(
24746 -*) as_dir=./$as_dir;;
24747 esac
24748 test -d "$as_dir" || eval $as_mkdir_p || {
24749 as_dirs=
24750 while :; do
24751 case $as_dir in #(
24752 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
24753 *) as_qdir=$as_dir;;
24754 esac
24755 as_dirs="'$as_qdir' $as_dirs"
24756 as_dir=`$as_dirname -- "$as_dir" ||
24757 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24758 X"$as_dir" : 'X\(//\)[^/]' \| \
24759 X"$as_dir" : 'X\(//\)$' \| \
24760 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24761 $as_echo X"$as_dir" |
24762 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24763 s//\1/
24766 /^X\(\/\/\)[^/].*/{
24767 s//\1/
24770 /^X\(\/\/\)$/{
24771 s//\1/
24774 /^X\(\/\).*/{
24775 s//\1/
24778 s/.*/./; q'`
24779 test -d "$as_dir" && break
24780 done
24781 test -z "$as_dirs" || eval "mkdir $as_dirs"
24782 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
24785 } # as_fn_mkdir_p
24786 if mkdir -p . 2>/dev/null; then
24787 as_mkdir_p='mkdir -p "$as_dir"'
24788 else
24789 test -d ./-p && rmdir ./-p
24790 as_mkdir_p=false
24793 if test -x / >/dev/null 2>&1; then
24794 as_test_x='test -x'
24795 else
24796 if ls -dL / >/dev/null 2>&1; then
24797 as_ls_L_option=L
24798 else
24799 as_ls_L_option=
24801 as_test_x='
24802 eval sh -c '\''
24803 if test -d "$1"; then
24804 test -d "$1/.";
24805 else
24806 case $1 in #(
24807 -*)set "./$1";;
24808 esac;
24809 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
24810 ???[sx]*):;;*)false;;esac;fi
24811 '\'' sh
24814 as_executable_p=$as_test_x
24816 # Sed expression to map a string onto a valid CPP name.
24817 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
24819 # Sed expression to map a string onto a valid variable name.
24820 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
24823 exec 6>&1
24824 ## ----------------------------------- ##
24825 ## Main body of $CONFIG_STATUS script. ##
24826 ## ----------------------------------- ##
24827 _ASEOF
24828 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
24830 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24831 # Save the log message, to keep $0 and so on meaningful, and to
24832 # report actual input values of CONFIG_FILES etc. instead of their
24833 # values after options handling.
24834 ac_log="
24835 This file was extended by emacs $as_me 24.2.50, which was
24836 generated by GNU Autoconf 2.65. Invocation command line was
24838 CONFIG_FILES = $CONFIG_FILES
24839 CONFIG_HEADERS = $CONFIG_HEADERS
24840 CONFIG_LINKS = $CONFIG_LINKS
24841 CONFIG_COMMANDS = $CONFIG_COMMANDS
24842 $ $0 $@
24844 on `(hostname || uname -n) 2>/dev/null | sed 1q`
24847 _ACEOF
24849 case $ac_config_files in *"
24850 "*) set x $ac_config_files; shift; ac_config_files=$*;;
24851 esac
24853 case $ac_config_headers in *"
24854 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
24855 esac
24858 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24859 # Files that config.status was made for.
24860 config_files="$ac_config_files"
24861 config_headers="$ac_config_headers"
24862 config_commands="$ac_config_commands"
24864 _ACEOF
24866 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24867 ac_cs_usage="\
24868 \`$as_me' instantiates files and other configuration actions
24869 from templates according to the current configuration. Unless the files
24870 and actions are specified as TAGs, all are instantiated by default.
24872 Usage: $0 [OPTION]... [TAG]...
24874 -h, --help print this help, then exit
24875 -V, --version print version number and configuration settings, then exit
24876 --config print configuration, then exit
24877 -q, --quiet, --silent
24878 do not print progress messages
24879 -d, --debug don't remove temporary files
24880 --recheck update $as_me by reconfiguring in the same conditions
24881 --file=FILE[:TEMPLATE]
24882 instantiate the configuration file FILE
24883 --header=FILE[:TEMPLATE]
24884 instantiate the configuration header FILE
24886 Configuration files:
24887 $config_files
24889 Configuration headers:
24890 $config_headers
24892 Configuration commands:
24893 $config_commands
24895 Report bugs to the package provider."
24897 _ACEOF
24898 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24899 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
24900 ac_cs_version="\\
24901 emacs config.status 24.2.50
24902 configured by $0, generated by GNU Autoconf 2.65,
24903 with options \\"\$ac_cs_config\\"
24905 Copyright (C) 2009 Free Software Foundation, Inc.
24906 This config.status script is free software; the Free Software Foundation
24907 gives unlimited permission to copy, distribute and modify it."
24909 ac_pwd='$ac_pwd'
24910 srcdir='$srcdir'
24911 INSTALL='$INSTALL'
24912 MKDIR_P='$MKDIR_P'
24913 AWK='$AWK'
24914 test -n "\$AWK" || AWK=awk
24915 _ACEOF
24917 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24918 # The default lists apply if the user does not specify any file.
24919 ac_need_defaults=:
24920 while test $# != 0
24922 case $1 in
24923 --*=*)
24924 ac_option=`expr "X$1" : 'X\([^=]*\)='`
24925 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
24926 ac_shift=:
24929 ac_option=$1
24930 ac_optarg=$2
24931 ac_shift=shift
24933 esac
24935 case $ac_option in
24936 # Handling of the options.
24937 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
24938 ac_cs_recheck=: ;;
24939 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
24940 $as_echo "$ac_cs_version"; exit ;;
24941 --config | --confi | --conf | --con | --co | --c )
24942 $as_echo "$ac_cs_config"; exit ;;
24943 --debug | --debu | --deb | --de | --d | -d )
24944 debug=: ;;
24945 --file | --fil | --fi | --f )
24946 $ac_shift
24947 case $ac_optarg in
24948 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24949 esac
24950 as_fn_append CONFIG_FILES " '$ac_optarg'"
24951 ac_need_defaults=false;;
24952 --header | --heade | --head | --hea )
24953 $ac_shift
24954 case $ac_optarg in
24955 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24956 esac
24957 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
24958 ac_need_defaults=false;;
24959 --he | --h)
24960 # Conflict between --help and --header
24961 as_fn_error "ambiguous option: \`$1'
24962 Try \`$0 --help' for more information.";;
24963 --help | --hel | -h )
24964 $as_echo "$ac_cs_usage"; exit ;;
24965 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
24966 | -silent | --silent | --silen | --sile | --sil | --si | --s)
24967 ac_cs_silent=: ;;
24969 # This is an error.
24970 -*) as_fn_error "unrecognized option: \`$1'
24971 Try \`$0 --help' for more information." ;;
24973 *) as_fn_append ac_config_targets " $1"
24974 ac_need_defaults=false ;;
24976 esac
24977 shift
24978 done
24980 ac_configure_extra_args=
24982 if $ac_cs_silent; then
24983 exec 6>/dev/null
24984 ac_configure_extra_args="$ac_configure_extra_args --silent"
24987 _ACEOF
24988 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24989 if \$ac_cs_recheck; then
24990 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
24991 shift
24992 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
24993 CONFIG_SHELL='$SHELL'
24994 export CONFIG_SHELL
24995 exec "\$@"
24998 _ACEOF
24999 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25000 exec 5>>config.log
25002 echo
25003 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25004 ## Running $as_me. ##
25005 _ASBOX
25006 $as_echo "$ac_log"
25007 } >&5
25009 _ACEOF
25010 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25012 # INIT-COMMANDS
25014 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
25015 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
25017 _ACEOF
25019 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25021 # Handling of arguments.
25022 for ac_config_target in $ac_config_targets
25024 case $ac_config_target in
25025 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
25026 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25027 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25028 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
25029 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
25030 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
25031 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
25032 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
25033 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
25034 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
25035 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
25036 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
25037 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
25038 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
25039 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
25040 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
25041 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
25042 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
25043 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
25045 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25046 esac
25047 done
25050 # If the user did not use the arguments to specify the items to instantiate,
25051 # then the envvar interface is used. Set only those that are not.
25052 # We use the long form for the default assignment because of an extremely
25053 # bizarre bug on SunOS 4.1.3.
25054 if $ac_need_defaults; then
25055 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25056 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25057 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25060 # Have a temporary directory for convenience. Make it in the build tree
25061 # simply because there is no reason against having it here, and in addition,
25062 # creating and moving files from /tmp can sometimes cause problems.
25063 # Hook for its removal unless debugging.
25064 # Note that there is a small window in which the directory will not be cleaned:
25065 # after its creation but before its name has been assigned to `$tmp'.
25066 $debug ||
25068 tmp=
25069 trap 'exit_status=$?
25070 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25072 trap 'as_fn_exit 1' 1 2 13 15
25074 # Create a (secure) tmp directory for tmp files.
25077 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25078 test -n "$tmp" && test -d "$tmp"
25079 } ||
25081 tmp=./conf$$-$RANDOM
25082 (umask 077 && mkdir "$tmp")
25083 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25085 # Set up the scripts for CONFIG_FILES section.
25086 # No need to generate them if there are no CONFIG_FILES.
25087 # This happens for instance with `./config.status config.h'.
25088 if test -n "$CONFIG_FILES"; then
25090 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
25091 ac_cs_awk_getline=:
25092 ac_cs_awk_pipe_init=
25093 ac_cs_awk_read_file='
25094 while ((getline aline < (F[key])) > 0)
25095 print(aline)
25096 close(F[key])'
25097 ac_cs_awk_pipe_fini=
25098 else
25099 ac_cs_awk_getline=false
25100 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
25101 ac_cs_awk_read_file='
25102 print "|#_!!_#|"
25103 print "cat " F[key] " &&"
25104 '$ac_cs_awk_pipe_init
25105 # The final `:' finishes the AND list.
25106 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
25108 ac_cr=`echo X | tr X '\015'`
25109 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25110 # But we know of no other shell where ac_cr would be empty at this
25111 # point, so we can use a bashism as a fallback.
25112 if test "x$ac_cr" = x; then
25113 eval ac_cr=\$\'\\r\'
25115 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25116 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25117 ac_cs_awk_cr='\r'
25118 else
25119 ac_cs_awk_cr=$ac_cr
25122 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25123 _ACEOF
25125 # Create commands to substitute file output variables.
25127 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
25128 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
25129 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
25130 echo "_ACAWK" &&
25131 echo "_ACEOF"
25132 } >conf$$files.sh &&
25133 . ./conf$$files.sh ||
25134 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25135 rm -f conf$$files.sh
25138 echo "cat >conf$$subs.awk <<_ACEOF" &&
25139 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25140 echo "_ACEOF"
25141 } >conf$$subs.sh ||
25142 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25143 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25144 ac_delim='%!_!# '
25145 for ac_last_try in false false false false false :; do
25146 . ./conf$$subs.sh ||
25147 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25149 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25150 if test $ac_delim_n = $ac_delim_num; then
25151 break
25152 elif $ac_last_try; then
25153 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25154 else
25155 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25157 done
25158 rm -f conf$$subs.sh
25160 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25161 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25162 _ACEOF
25163 sed -n '
25165 s/^/S["/; s/!.*/"]=/
25168 s/^[^!]*!//
25169 :repl
25170 t repl
25171 s/'"$ac_delim"'$//
25172 t delim
25175 s/\(.\{148\}\)..*/\1/
25176 t more1
25177 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25180 b repl
25181 :more1
25182 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25185 s/.\{148\}//
25186 t nl
25187 :delim
25189 s/\(.\{148\}\)..*/\1/
25190 t more2
25191 s/["\\]/\\&/g; s/^/"/; s/$/"/
25194 :more2
25195 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25198 s/.\{148\}//
25199 t delim
25200 ' <conf$$subs.awk | sed '
25201 /^[^""]/{
25203 s/\n//
25205 ' >>$CONFIG_STATUS || ac_write_fail=1
25206 rm -f conf$$subs.awk
25207 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25208 _ACAWK
25209 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25210 for (key in S) S_is_set[key] = 1
25211 FS = "\a"
25212 \$ac_cs_awk_pipe_init
25215 line = $ 0
25216 nfields = split(line, field, "@")
25217 substed = 0
25218 len = length(field[1])
25219 for (i = 2; i < nfields; i++) {
25220 key = field[i]
25221 keylen = length(key)
25222 if (S_is_set[key]) {
25223 value = S[key]
25224 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25225 len += length(value) + length(field[++i])
25226 substed = 1
25227 } else
25228 len += 1 + keylen
25230 if (nfields == 3 && !substed) {
25231 key = field[2]
25232 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
25233 \$ac_cs_awk_read_file
25234 next
25237 print line
25239 \$ac_cs_awk_pipe_fini
25240 _ACAWK
25241 _ACEOF
25242 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25243 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25244 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25245 else
25247 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25248 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25249 _ACEOF
25251 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25252 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25253 # trailing colons and then remove the whole line if VPATH becomes empty
25254 # (actually we leave an empty line to preserve line numbers).
25255 if test "x$srcdir" = x.; then
25256 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25257 s/:*\$(srcdir):*/:/
25258 s/:*\${srcdir}:*/:/
25259 s/:*@srcdir@:*/:/
25260 s/^\([^=]*=[ ]*\):*/\1/
25261 s/:*$//
25262 s/^[^=]*=[ ]*$//
25266 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25267 fi # test -n "$CONFIG_FILES"
25269 # Set up the scripts for CONFIG_HEADERS section.
25270 # No need to generate them if there are no CONFIG_HEADERS.
25271 # This happens for instance with `./config.status Makefile'.
25272 if test -n "$CONFIG_HEADERS"; then
25273 cat >"$tmp/defines.awk" <<\_ACAWK ||
25274 BEGIN {
25275 _ACEOF
25277 # Transform confdefs.h into an awk script `defines.awk', embedded as
25278 # here-document in config.status, that substitutes the proper values into
25279 # config.h.in to produce config.h.
25281 # Create a delimiter string that does not exist in confdefs.h, to ease
25282 # handling of long lines.
25283 ac_delim='%!_!# '
25284 for ac_last_try in false false :; do
25285 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25286 if test -z "$ac_t"; then
25287 break
25288 elif $ac_last_try; then
25289 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25290 else
25291 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25293 done
25295 # For the awk script, D is an array of macro values keyed by name,
25296 # likewise P contains macro parameters if any. Preserve backslash
25297 # newline sequences.
25299 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25300 sed -n '
25301 s/.\{148\}/&'"$ac_delim"'/g
25302 t rset
25303 :rset
25304 s/^[ ]*#[ ]*define[ ][ ]*/ /
25305 t def
25307 :def
25308 s/\\$//
25309 t bsnl
25310 s/["\\]/\\&/g
25311 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25312 D["\1"]=" \3"/p
25313 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25315 :bsnl
25316 s/["\\]/\\&/g
25317 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25318 D["\1"]=" \3\\\\\\n"\\/p
25319 t cont
25320 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25321 t cont
25323 :cont
25325 s/.\{148\}/&'"$ac_delim"'/g
25326 t clear
25327 :clear
25328 s/\\$//
25329 t bsnlc
25330 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25332 :bsnlc
25333 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25334 b cont
25335 ' <confdefs.h | sed '
25336 s/'"$ac_delim"'/"\\\
25337 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25339 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25340 for (key in D) D_is_set[key] = 1
25341 FS = "\a"
25343 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25344 line = \$ 0
25345 split(line, arg, " ")
25346 if (arg[1] == "#") {
25347 defundef = arg[2]
25348 mac1 = arg[3]
25349 } else {
25350 defundef = substr(arg[1], 2)
25351 mac1 = arg[2]
25353 split(mac1, mac2, "(") #)
25354 macro = mac2[1]
25355 prefix = substr(line, 1, index(line, defundef) - 1)
25356 if (D_is_set[macro]) {
25357 # Preserve the white space surrounding the "#".
25358 print prefix "define", macro P[macro] D[macro]
25359 next
25360 } else {
25361 # Replace #undef with comments. This is necessary, for example,
25362 # in the case of _POSIX_SOURCE, which is predefined and required
25363 # on some systems where configure will not decide to define it.
25364 if (defundef == "undef") {
25365 print "/*", prefix defundef, macro, "*/"
25366 next
25370 { print }
25371 _ACAWK
25372 _ACEOF
25373 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25374 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25375 fi # test -n "$CONFIG_HEADERS"
25378 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25379 shift
25380 for ac_tag
25382 case $ac_tag in
25383 :[FHLC]) ac_mode=$ac_tag; continue;;
25384 esac
25385 case $ac_mode$ac_tag in
25386 :[FHL]*:*);;
25387 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25388 :[FH]-) ac_tag=-:-;;
25389 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25390 esac
25391 ac_save_IFS=$IFS
25392 IFS=:
25393 set x $ac_tag
25394 IFS=$ac_save_IFS
25395 shift
25396 ac_file=$1
25397 shift
25399 case $ac_mode in
25400 :L) ac_source=$1;;
25401 :[FH])
25402 ac_file_inputs=
25403 for ac_f
25405 case $ac_f in
25406 -) ac_f="$tmp/stdin";;
25407 *) # Look for the file first in the build tree, then in the source tree
25408 # (if the path is not absolute). The absolute path cannot be DOS-style,
25409 # because $ac_f cannot contain `:'.
25410 test -f "$ac_f" ||
25411 case $ac_f in
25412 [\\/$]*) false;;
25413 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
25414 esac ||
25415 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
25416 esac
25417 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
25418 as_fn_append ac_file_inputs " '$ac_f'"
25419 done
25421 # Let's still pretend it is `configure' which instantiates (i.e., don't
25422 # use $as_me), people would be surprised to read:
25423 # /* config.h. Generated by config.status. */
25424 configure_input='Generated from '`
25425 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
25426 `' by configure.'
25427 if test x"$ac_file" != x-; then
25428 configure_input="$ac_file. $configure_input"
25429 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
25430 $as_echo "$as_me: creating $ac_file" >&6;}
25432 # Neutralize special characters interpreted by sed in replacement strings.
25433 case $configure_input in #(
25434 *\&* | *\|* | *\\* )
25435 ac_sed_conf_input=`$as_echo "$configure_input" |
25436 sed 's/[\\\\&|]/\\\\&/g'`;; #(
25437 *) ac_sed_conf_input=$configure_input;;
25438 esac
25440 case $ac_tag in
25441 *:-:* | *:-) cat >"$tmp/stdin" \
25442 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
25443 esac
25445 esac
25447 ac_dir=`$as_dirname -- "$ac_file" ||
25448 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25449 X"$ac_file" : 'X\(//\)[^/]' \| \
25450 X"$ac_file" : 'X\(//\)$' \| \
25451 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
25452 $as_echo X"$ac_file" |
25453 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25454 s//\1/
25457 /^X\(\/\/\)[^/].*/{
25458 s//\1/
25461 /^X\(\/\/\)$/{
25462 s//\1/
25465 /^X\(\/\).*/{
25466 s//\1/
25469 s/.*/./; q'`
25470 as_dir="$ac_dir"; as_fn_mkdir_p
25471 ac_builddir=.
25473 case "$ac_dir" in
25474 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
25476 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
25477 # A ".." for each directory in $ac_dir_suffix.
25478 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
25479 case $ac_top_builddir_sub in
25480 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
25481 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
25482 esac ;;
25483 esac
25484 ac_abs_top_builddir=$ac_pwd
25485 ac_abs_builddir=$ac_pwd$ac_dir_suffix
25486 # for backward compatibility:
25487 ac_top_builddir=$ac_top_build_prefix
25489 case $srcdir in
25490 .) # We are building in place.
25491 ac_srcdir=.
25492 ac_top_srcdir=$ac_top_builddir_sub
25493 ac_abs_top_srcdir=$ac_pwd ;;
25494 [\\/]* | ?:[\\/]* ) # Absolute name.
25495 ac_srcdir=$srcdir$ac_dir_suffix;
25496 ac_top_srcdir=$srcdir
25497 ac_abs_top_srcdir=$srcdir ;;
25498 *) # Relative name.
25499 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
25500 ac_top_srcdir=$ac_top_build_prefix$srcdir
25501 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
25502 esac
25503 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
25506 case $ac_mode in
25509 # CONFIG_FILE
25512 case $INSTALL in
25513 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
25514 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
25515 esac
25516 ac_MKDIR_P=$MKDIR_P
25517 case $MKDIR_P in
25518 [\\/$]* | ?:[\\/]* ) ;;
25519 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
25520 esac
25521 _ACEOF
25523 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25524 # If the template does not know about datarootdir, expand it.
25525 # FIXME: This hack should be removed a few years after 2.60.
25526 ac_datarootdir_hack=; ac_datarootdir_seen=
25527 ac_sed_dataroot='
25528 /datarootdir/ {
25532 /@datadir@/p
25533 /@docdir@/p
25534 /@infodir@/p
25535 /@localedir@/p
25536 /@mandir@/p'
25537 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
25538 *datarootdir*) ac_datarootdir_seen=yes;;
25539 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
25540 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
25541 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
25542 _ACEOF
25543 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25544 ac_datarootdir_hack='
25545 s&@datadir@&$datadir&g
25546 s&@docdir@&$docdir&g
25547 s&@infodir@&$infodir&g
25548 s&@localedir@&$localedir&g
25549 s&@mandir@&$mandir&g
25550 s&\\\${datarootdir}&$datarootdir&g' ;;
25551 esac
25552 _ACEOF
25554 # Neutralize VPATH when `$srcdir' = `.'.
25555 # Shell code in configure.ac might set extrasub.
25556 # FIXME: do we really want to maintain this feature?
25557 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25558 ac_sed_extra="$ac_vpsub
25559 $extrasub
25560 _ACEOF
25561 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25563 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
25564 s|@configure_input@|$ac_sed_conf_input|;t t
25565 s&@top_builddir@&$ac_top_builddir_sub&;t t
25566 s&@top_build_prefix@&$ac_top_build_prefix&;t t
25567 s&@srcdir@&$ac_srcdir&;t t
25568 s&@abs_srcdir@&$ac_abs_srcdir&;t t
25569 s&@top_srcdir@&$ac_top_srcdir&;t t
25570 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
25571 s&@builddir@&$ac_builddir&;t t
25572 s&@abs_builddir@&$ac_abs_builddir&;t t
25573 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
25574 s&@INSTALL@&$ac_INSTALL&;t t
25575 s&@MKDIR_P@&$ac_MKDIR_P&;t t
25576 $ac_datarootdir_hack
25578 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
25579 if $ac_cs_awk_getline; then
25580 $AWK -f "$tmp/subs.awk"
25581 else
25582 $AWK -f "$tmp/subs.awk" | $SHELL
25583 fi >$tmp/out \
25584 || as_fn_error "could not create $ac_file" "$LINENO" 5
25586 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
25587 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
25588 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
25589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25590 which seems to be undefined. Please make sure it is defined." >&5
25591 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25592 which seems to be undefined. Please make sure it is defined." >&2;}
25594 rm -f "$tmp/stdin"
25595 case $ac_file in
25596 -) cat "$tmp/out" && rm -f "$tmp/out";;
25597 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
25598 esac \
25599 || as_fn_error "could not create $ac_file" "$LINENO" 5
25603 # CONFIG_HEADER
25605 if test x"$ac_file" != x-; then
25607 $as_echo "/* $configure_input */" \
25608 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
25609 } >"$tmp/config.h" \
25610 || as_fn_error "could not create $ac_file" "$LINENO" 5
25611 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
25612 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
25613 $as_echo "$as_me: $ac_file is unchanged" >&6;}
25614 else
25615 rm -f "$ac_file"
25616 mv "$tmp/config.h" "$ac_file" \
25617 || as_fn_error "could not create $ac_file" "$LINENO" 5
25619 else
25620 $as_echo "/* $configure_input */" \
25621 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
25622 || as_fn_error "could not create -" "$LINENO" 5
25624 # Compute "$ac_file"'s index in $config_headers.
25625 _am_arg="$ac_file"
25626 _am_stamp_count=1
25627 for _am_header in $config_headers :; do
25628 case $_am_header in
25629 $_am_arg | $_am_arg:* )
25630 break ;;
25632 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
25633 esac
25634 done
25635 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
25636 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25637 X"$_am_arg" : 'X\(//\)[^/]' \| \
25638 X"$_am_arg" : 'X\(//\)$' \| \
25639 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
25640 $as_echo X"$_am_arg" |
25641 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25642 s//\1/
25645 /^X\(\/\/\)[^/].*/{
25646 s//\1/
25649 /^X\(\/\/\)$/{
25650 s//\1/
25653 /^X\(\/\).*/{
25654 s//\1/
25657 s/.*/./; q'`/stamp-h$_am_stamp_count
25660 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
25661 $as_echo "$as_me: executing $ac_file commands" >&6;}
25663 esac
25666 case $ac_file$ac_mode in
25667 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
25668 # Autoconf 2.62 quotes --file arguments for eval, but not when files
25669 # are listed without --file. Let's play safe and only enable the eval
25670 # if we detect the quoting.
25671 case $CONFIG_FILES in
25672 *\'*) eval set x "$CONFIG_FILES" ;;
25673 *) set x $CONFIG_FILES ;;
25674 esac
25675 shift
25676 for mf
25678 # Strip MF so we end up with the name of the file.
25679 mf=`echo "$mf" | sed -e 's/:.*$//'`
25680 # Check whether this is an Automake generated Makefile or not.
25681 # We used to match only the files named `Makefile.in', but
25682 # some people rename them; so instead we look at the file content.
25683 # Grep'ing the first line is not enough: some people post-process
25684 # each Makefile.in and add a new line on top of each file to say so.
25685 # Grep'ing the whole file is not good either: AIX grep has a line
25686 # limit of 2048, but all sed's we know have understand at least 4000.
25687 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
25688 dirpart=`$as_dirname -- "$mf" ||
25689 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25690 X"$mf" : 'X\(//\)[^/]' \| \
25691 X"$mf" : 'X\(//\)$' \| \
25692 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
25693 $as_echo X"$mf" |
25694 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25695 s//\1/
25698 /^X\(\/\/\)[^/].*/{
25699 s//\1/
25702 /^X\(\/\/\)$/{
25703 s//\1/
25706 /^X\(\/\).*/{
25707 s//\1/
25710 s/.*/./; q'`
25711 else
25712 continue
25714 # Extract the definition of DEPDIR, am__include, and am__quote
25715 # from the Makefile without running `make'.
25716 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
25717 test -z "$DEPDIR" && continue
25718 am__include=`sed -n 's/^am__include = //p' < "$mf"`
25719 test -z "am__include" && continue
25720 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
25721 # When using ansi2knr, U may be empty or an underscore; expand it
25722 U=`sed -n 's/^U = //p' < "$mf"`
25723 # Find all dependency output files, they are included files with
25724 # $(DEPDIR) in their names. We invoke sed twice because it is the
25725 # simplest approach to changing $(DEPDIR) to its actual value in the
25726 # expansion.
25727 for file in `sed -n "
25728 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
25729 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
25730 # Make sure the directory exists.
25731 test -f "$dirpart/$file" && continue
25732 fdir=`$as_dirname -- "$file" ||
25733 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25734 X"$file" : 'X\(//\)[^/]' \| \
25735 X"$file" : 'X\(//\)$' \| \
25736 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
25737 $as_echo X"$file" |
25738 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25739 s//\1/
25742 /^X\(\/\/\)[^/].*/{
25743 s//\1/
25746 /^X\(\/\/\)$/{
25747 s//\1/
25750 /^X\(\/\).*/{
25751 s//\1/
25754 s/.*/./; q'`
25755 as_dir=$dirpart/$fdir; as_fn_mkdir_p
25756 # echo "creating $dirpart/$file"
25757 echo '# dummy' > "$dirpart/$file"
25758 done
25759 done
25762 "mkdirs":C)
25763 for dir in etc lisp ; do
25764 test -d ${dir} || mkdir ${dir}
25765 done
25767 "epaths":C)
25768 echo creating src/epaths.h
25769 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
25771 "gdbinit":C)
25772 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
25773 echo creating src/.gdbinit
25774 echo source $srcdir/src/.gdbinit > src/.gdbinit
25778 esac
25779 done # for ac_tag
25782 as_fn_exit 0
25783 _ACEOF
25784 ac_clean_files=$ac_clean_files_save
25786 test $ac_write_fail = 0 ||
25787 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
25790 # configure is writing to config.log, and then calls config.status.
25791 # config.status does its own redirection, appending to config.log.
25792 # Unfortunately, on DOS this fails, as config.log is still kept open
25793 # by configure, so config.status won't be able to write to it; its
25794 # output is simply discarded. So we exec the FD to /dev/null,
25795 # effectively closing config.log, so it can be properly (re)opened and
25796 # appended to by config.status. When coming back to configure, we
25797 # need to make the FD available again.
25798 if test "$no_create" != yes; then
25799 ac_cs_success=:
25800 ac_config_status_args=
25801 test "$silent" = yes &&
25802 ac_config_status_args="$ac_config_status_args --quiet"
25803 exec 5>/dev/null
25804 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
25805 exec 5>>config.log
25806 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
25807 # would make configure fail if this is the last instruction.
25808 $ac_cs_success || as_fn_exit $?
25810 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
25811 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
25812 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}