Alphabetical order
[emacs.git] / autogen / configure
blob0bd4882232488c750e18bce88ea8056a3f0a8143
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.1.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.1.50'
553 PACKAGE_STRING='emacs 24.1.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 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
975 UNISTD_H_HAVE_WINSOCK2_H
976 REPLACE_WRITE
977 REPLACE_USLEEP
978 REPLACE_UNLINKAT
979 REPLACE_UNLINK
980 REPLACE_TTYNAME_R
981 REPLACE_SYMLINK
982 REPLACE_SLEEP
983 REPLACE_RMDIR
984 REPLACE_READLINK
985 REPLACE_READ
986 REPLACE_PWRITE
987 REPLACE_PREAD
988 REPLACE_LSEEK
989 REPLACE_LINKAT
990 REPLACE_LINK
991 REPLACE_LCHOWN
992 REPLACE_ISATTY
993 REPLACE_GETPAGESIZE
994 REPLACE_GETGROUPS
995 REPLACE_GETLOGIN_R
996 REPLACE_GETDOMAINNAME
997 REPLACE_GETCWD
998 REPLACE_FTRUNCATE
999 REPLACE_FCHOWNAT
1000 REPLACE_DUP2
1001 REPLACE_DUP
1002 REPLACE_CLOSE
1003 REPLACE_CHOWN
1004 HAVE_SYS_PARAM_H
1005 HAVE_OS_H
1006 HAVE_DECL_TTYNAME_R
1007 HAVE_DECL_SETHOSTNAME
1008 HAVE_DECL_GETUSERSHELL
1009 HAVE_DECL_GETPAGESIZE
1010 HAVE_DECL_GETLOGIN_R
1011 HAVE_DECL_GETDOMAINNAME
1012 HAVE_DECL_FDATASYNC
1013 HAVE_DECL_FCHDIR
1014 HAVE_DECL_ENVIRON
1015 HAVE_USLEEP
1016 HAVE_UNLINKAT
1017 HAVE_SYMLINKAT
1018 HAVE_SYMLINK
1019 HAVE_SLEEP
1020 HAVE_SETHOSTNAME
1021 HAVE_READLINKAT
1022 HAVE_READLINK
1023 HAVE_PWRITE
1024 HAVE_PREAD
1025 HAVE_PIPE2
1026 HAVE_PIPE
1027 HAVE_LINKAT
1028 HAVE_LINK
1029 HAVE_LCHOWN
1030 HAVE_GROUP_MEMBER
1031 HAVE_GETPAGESIZE
1032 HAVE_GETLOGIN
1033 HAVE_GETHOSTNAME
1034 HAVE_GETGROUPS
1035 HAVE_GETDTABLESIZE
1036 HAVE_FTRUNCATE
1037 HAVE_FSYNC
1038 HAVE_FDATASYNC
1039 HAVE_FCHOWNAT
1040 HAVE_FCHDIR
1041 HAVE_FACCESSAT
1042 HAVE_EUIDACCESS
1043 HAVE_DUP3
1044 HAVE_DUP2
1045 HAVE_CHOWN
1046 GNULIB_WRITE
1047 GNULIB_USLEEP
1048 GNULIB_UNLINKAT
1049 GNULIB_UNLINK
1050 GNULIB_UNISTD_H_SIGPIPE
1051 GNULIB_UNISTD_H_NONBLOCKING
1052 GNULIB_TTYNAME_R
1053 GNULIB_SYMLINKAT
1054 GNULIB_SYMLINK
1055 GNULIB_SLEEP
1056 GNULIB_SETHOSTNAME
1057 GNULIB_RMDIR
1058 GNULIB_READLINKAT
1059 GNULIB_READLINK
1060 GNULIB_READ
1061 GNULIB_PWRITE
1062 GNULIB_PREAD
1063 GNULIB_PIPE2
1064 GNULIB_PIPE
1065 GNULIB_LSEEK
1066 GNULIB_LINKAT
1067 GNULIB_LINK
1068 GNULIB_LCHOWN
1069 GNULIB_ISATTY
1070 GNULIB_GROUP_MEMBER
1071 GNULIB_GETUSERSHELL
1072 GNULIB_GETPAGESIZE
1073 GNULIB_GETLOGIN_R
1074 GNULIB_GETLOGIN
1075 GNULIB_GETHOSTNAME
1076 GNULIB_GETGROUPS
1077 GNULIB_GETDTABLESIZE
1078 GNULIB_GETDOMAINNAME
1079 GNULIB_GETCWD
1080 GNULIB_FTRUNCATE
1081 GNULIB_FSYNC
1082 GNULIB_FDATASYNC
1083 GNULIB_FCHOWNAT
1084 GNULIB_FCHDIR
1085 GNULIB_FACCESSAT
1086 GNULIB_EUIDACCESS
1087 GNULIB_ENVIRON
1088 GNULIB_DUP3
1089 GNULIB_DUP2
1090 GNULIB_DUP
1091 GNULIB_CLOSE
1092 GNULIB_CHOWN
1093 GNULIB_CHDIR
1094 LIB_CLOCK_GETTIME
1095 GL_GENERATE_ALLOCA_H_FALSE
1096 GL_GENERATE_ALLOCA_H_TRUE
1097 ALLOCA_H
1098 ALLOCA
1099 GL_COND_LIBTOOL_FALSE
1100 GL_COND_LIBTOOL_TRUE
1101 POST_ALLOC_OBJ
1102 PRE_ALLOC_OBJ
1103 CYGWIN_OBJ
1104 RALLOC_OBJ
1105 OLDXMENU_DEPS
1106 LIBX_OTHER
1107 LIBXMENU
1108 OLDXMENU
1109 OLDXMENU_TARGET
1110 LIBXT_OTHER
1111 TOOLKIT_LIBW
1112 WIDGET_OBJ
1113 XOBJ
1114 XMENU_OBJ
1115 FONT_OBJ
1116 OTHER_FILES
1117 GNU_OBJC_CFLAGS
1118 ns_appsrc
1119 ns_appresdir
1120 ns_appbindir
1121 ns_appdir
1122 X_TOOLKIT_TYPE
1123 GNUSTEP_CFLAGS
1124 C_SWITCH_X_SITE
1125 LD_SWITCH_X_SITE
1126 gameuser
1127 gamedir
1128 bitmapdir
1129 archlibdir
1130 etcdir
1131 x_default_search_path
1132 lisppath
1133 locallisppath
1134 standardlisppath
1135 leimdir
1136 lispdir
1137 srcdir
1138 canonical
1139 configuration
1140 version
1141 KRB4LIB
1142 DESLIB
1143 KRB5LIB
1144 CRYPTOLIB
1145 COM_ERRLIB
1146 LIBRESOLV
1147 LIBHESIOD
1148 TERMCAP_OBJ
1149 LIBS_TERMCAP
1150 BLESSMAIL_TARGET
1151 LIBS_MAIL
1152 liblockfile
1153 LIBXML2_LIBS
1154 LIBXML2_CFLAGS
1155 LIBXSM
1156 LIBGPM
1157 LIBGIF
1158 LIBTIFF
1159 LIBPNG
1160 LIBJPEG
1161 LIBXPM
1162 M17N_FLT_LIBS
1163 M17N_FLT_CFLAGS
1164 LIBOTF_LIBS
1165 LIBOTF_CFLAGS
1166 FREETYPE_LIBS
1167 FREETYPE_CFLAGS
1168 XFT_LIBS
1169 XFT_CFLAGS
1170 FONTCONFIG_LIBS
1171 FONTCONFIG_CFLAGS
1172 LIBXMU
1173 LIBXTR6
1174 LIBGNUTLS_LIBS
1175 LIBGNUTLS_CFLAGS
1176 LIBSELINUX_LIBS
1177 SETTINGS_LIBS
1178 SETTINGS_CFLAGS
1179 GCONF_LIBS
1180 GCONF_CFLAGS
1181 GSETTINGS_LIBS
1182 GSETTINGS_CFLAGS
1183 DBUS_OBJ
1184 DBUS_LIBS
1185 DBUS_CFLAGS
1186 GTK_OBJ
1187 GTK_LIBS
1188 GTK_CFLAGS
1189 IMAGEMAGICK_LIBS
1190 IMAGEMAGICK_CFLAGS
1191 RSVG_LIBS
1192 RSVG_CFLAGS
1193 LIB_PTHREAD
1194 VMLIMIT_OBJ
1195 GMALLOC_OBJ
1196 HAVE_XSERVER
1197 LIB_STANDARD
1198 NS_OBJC_OBJ
1199 NS_OBJ
1200 ns_self_contained
1201 INSTALL_ARCH_INDEP_EXTRA
1202 TEMACS_LDFLAGS2
1203 LD_SWITCH_X_SITE_RPATH
1204 XMKMF
1205 DEPFLAGS
1206 MKDEPDIR
1207 CFLAGS_SOUND
1208 ALSA_LIBS
1209 ALSA_CFLAGS
1210 LIBSOUND
1211 PKG_CONFIG
1212 CRT_DIR
1213 START_FILES
1214 LIB_MATH
1215 LIBS_SYSTEM
1216 C_SWITCH_SYSTEM
1217 UNEXEC_OBJ
1218 C_SWITCH_MACHINE
1219 LD_SWITCH_SYSTEM
1220 CANNOT_DUMP
1221 INFO_OPTS
1222 INFO_EXT
1223 HAVE_MAKEINFO
1224 PAXCTL
1225 GZIP_PROG
1226 INSTALL_INFO
1227 GNULIB_WARN_CFLAGS
1228 WARN_CFLAGS
1229 WERROR_CFLAGS
1230 RANLIB
1231 ARFLAGS
1233 EGREP
1234 GREP
1236 am__fastdepCC_FALSE
1237 am__fastdepCC_TRUE
1238 CCDEPMODE
1239 AMDEPBACKSLASH
1240 AMDEP_FALSE
1241 AMDEP_TRUE
1242 am__quote
1243 am__include
1244 DEPDIR
1245 OBJEXT
1246 EXEEXT
1247 ac_ct_CC
1248 CPPFLAGS
1249 LDFLAGS
1250 CFLAGS
1252 host_os
1253 host_vendor
1254 host_cpu
1255 host
1256 build_os
1257 build_vendor
1258 build_cpu
1259 build
1260 PROFILING_CFLAGS
1261 GZIP_INFO
1262 cache_file
1263 am__untar
1264 am__tar
1265 AMTAR
1266 am__leading_dot
1267 SET_MAKE
1269 mkdir_p
1270 MKDIR_P
1271 INSTALL_STRIP_PROGRAM
1272 STRIP
1273 install_sh
1274 MAKEINFO
1275 AUTOHEADER
1276 AUTOMAKE
1277 AUTOCONF
1278 ACLOCAL
1279 VERSION
1280 PACKAGE
1281 CYGPATH_W
1282 am__isrc
1283 INSTALL_DATA
1284 INSTALL_SCRIPT
1285 INSTALL_PROGRAM
1286 target_alias
1287 host_alias
1288 build_alias
1289 LIBS
1290 ECHO_T
1291 ECHO_N
1292 ECHO_C
1293 DEFS
1294 mandir
1295 localedir
1296 libdir
1297 psdir
1298 pdfdir
1299 dvidir
1300 htmldir
1301 infodir
1302 docdir
1303 oldincludedir
1304 includedir
1305 localstatedir
1306 sharedstatedir
1307 sysconfdir
1308 datadir
1309 datarootdir
1310 libexecdir
1311 sbindir
1312 bindir
1313 program_transform_name
1314 prefix
1315 exec_prefix
1316 PACKAGE_URL
1317 PACKAGE_BUGREPORT
1318 PACKAGE_STRING
1319 PACKAGE_VERSION
1320 PACKAGE_TARNAME
1321 PACKAGE_NAME
1322 PATH_SEPARATOR
1323 SHELL'
1324 ac_subst_files='deps_frag
1325 lisp_frag
1326 ns_frag'
1327 ac_user_opts='
1328 enable_option_checking
1329 with_pop
1330 with_kerberos
1331 with_kerberos5
1332 with_hesiod
1333 with_mmdf
1334 with_mail_unlink
1335 with_mailhost
1336 with_sound
1337 with_sync_input
1338 with_x_toolkit
1339 with_wide_int
1340 with_xpm
1341 with_jpeg
1342 with_tiff
1343 with_gif
1344 with_png
1345 with_rsvg
1346 with_xml2
1347 with_imagemagick
1348 with_xft
1349 with_libotf
1350 with_m17n_flt
1351 with_toolkit_scroll_bars
1352 with_xaw3d
1353 with_xim
1354 with_ns
1355 with_gpm
1356 with_dbus
1357 with_gconf
1358 with_gsettings
1359 with_selinux
1360 with_gnutls
1361 with_makeinfo
1362 with_compress_info
1363 with_pkg_config_prog
1364 with_crt_dir
1365 with_gameuser
1366 with_gnustep_conf
1367 enable_ns_self_contained
1368 enable_locallisppath
1369 enable_checking
1370 enable_check_lisp_object_type
1371 enable_profiling
1372 enable_autodepend
1373 enable_dependency_tracking
1374 enable_largefile
1375 enable_gcc_warnings
1376 enable_link_time_optimization
1377 with_x
1379 ac_precious_vars='build_alias
1380 host_alias
1381 target_alias
1383 CFLAGS
1384 LDFLAGS
1385 LIBS
1386 CPPFLAGS
1388 XMKMF'
1391 # Initialize some variables set by options.
1392 ac_init_help=
1393 ac_init_version=false
1394 ac_unrecognized_opts=
1395 ac_unrecognized_sep=
1396 # The variables have the same names as the options, with
1397 # dashes changed to underlines.
1398 cache_file=/dev/null
1399 exec_prefix=NONE
1400 no_create=
1401 no_recursion=
1402 prefix=NONE
1403 program_prefix=NONE
1404 program_suffix=NONE
1405 program_transform_name=s,x,x,
1406 silent=
1407 site=
1408 srcdir=
1409 verbose=
1410 x_includes=NONE
1411 x_libraries=NONE
1413 # Installation directory options.
1414 # These are left unexpanded so users can "make install exec_prefix=/foo"
1415 # and all the variables that are supposed to be based on exec_prefix
1416 # by default will actually change.
1417 # Use braces instead of parens because sh, perl, etc. also accept them.
1418 # (The list follows the same order as the GNU Coding Standards.)
1419 bindir='${exec_prefix}/bin'
1420 sbindir='${exec_prefix}/sbin'
1421 libexecdir='${exec_prefix}/libexec'
1422 datarootdir='${prefix}/share'
1423 datadir='${datarootdir}'
1424 sysconfdir='${prefix}/etc'
1425 sharedstatedir='${prefix}/com'
1426 localstatedir='${prefix}/var'
1427 includedir='${prefix}/include'
1428 oldincludedir='/usr/include'
1429 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1430 infodir='${datarootdir}/info'
1431 htmldir='${docdir}'
1432 dvidir='${docdir}'
1433 pdfdir='${docdir}'
1434 psdir='${docdir}'
1435 libdir='${exec_prefix}/lib'
1436 localedir='${datarootdir}/locale'
1437 mandir='${datarootdir}/man'
1439 ac_prev=
1440 ac_dashdash=
1441 for ac_option
1443 # If the previous option needs an argument, assign it.
1444 if test -n "$ac_prev"; then
1445 eval $ac_prev=\$ac_option
1446 ac_prev=
1447 continue
1450 case $ac_option in
1451 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1452 *) ac_optarg=yes ;;
1453 esac
1455 # Accept the important Cygnus configure options, so we can diagnose typos.
1457 case $ac_dashdash$ac_option in
1459 ac_dashdash=yes ;;
1461 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1462 ac_prev=bindir ;;
1463 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1464 bindir=$ac_optarg ;;
1466 -build | --build | --buil | --bui | --bu)
1467 ac_prev=build_alias ;;
1468 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1469 build_alias=$ac_optarg ;;
1471 -cache-file | --cache-file | --cache-fil | --cache-fi \
1472 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1473 ac_prev=cache_file ;;
1474 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1475 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1476 cache_file=$ac_optarg ;;
1478 --config-cache | -C)
1479 cache_file=config.cache ;;
1481 -datadir | --datadir | --datadi | --datad)
1482 ac_prev=datadir ;;
1483 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1484 datadir=$ac_optarg ;;
1486 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1487 | --dataroo | --dataro | --datar)
1488 ac_prev=datarootdir ;;
1489 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1490 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1491 datarootdir=$ac_optarg ;;
1493 -disable-* | --disable-*)
1494 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1495 # Reject names that are not valid shell variable names.
1496 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1497 as_fn_error "invalid feature name: $ac_useropt"
1498 ac_useropt_orig=$ac_useropt
1499 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1500 case $ac_user_opts in
1502 "enable_$ac_useropt"
1503 "*) ;;
1504 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1505 ac_unrecognized_sep=', ';;
1506 esac
1507 eval enable_$ac_useropt=no ;;
1509 -docdir | --docdir | --docdi | --doc | --do)
1510 ac_prev=docdir ;;
1511 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1512 docdir=$ac_optarg ;;
1514 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1515 ac_prev=dvidir ;;
1516 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1517 dvidir=$ac_optarg ;;
1519 -enable-* | --enable-*)
1520 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1521 # Reject names that are not valid shell variable names.
1522 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1523 as_fn_error "invalid feature name: $ac_useropt"
1524 ac_useropt_orig=$ac_useropt
1525 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1526 case $ac_user_opts in
1528 "enable_$ac_useropt"
1529 "*) ;;
1530 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1531 ac_unrecognized_sep=', ';;
1532 esac
1533 eval enable_$ac_useropt=\$ac_optarg ;;
1535 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1536 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1537 | --exec | --exe | --ex)
1538 ac_prev=exec_prefix ;;
1539 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1540 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1541 | --exec=* | --exe=* | --ex=*)
1542 exec_prefix=$ac_optarg ;;
1544 -gas | --gas | --ga | --g)
1545 # Obsolete; use --with-gas.
1546 with_gas=yes ;;
1548 -help | --help | --hel | --he | -h)
1549 ac_init_help=long ;;
1550 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1551 ac_init_help=recursive ;;
1552 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1553 ac_init_help=short ;;
1555 -host | --host | --hos | --ho)
1556 ac_prev=host_alias ;;
1557 -host=* | --host=* | --hos=* | --ho=*)
1558 host_alias=$ac_optarg ;;
1560 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1561 ac_prev=htmldir ;;
1562 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1563 | --ht=*)
1564 htmldir=$ac_optarg ;;
1566 -includedir | --includedir | --includedi | --included | --include \
1567 | --includ | --inclu | --incl | --inc)
1568 ac_prev=includedir ;;
1569 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1570 | --includ=* | --inclu=* | --incl=* | --inc=*)
1571 includedir=$ac_optarg ;;
1573 -infodir | --infodir | --infodi | --infod | --info | --inf)
1574 ac_prev=infodir ;;
1575 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1576 infodir=$ac_optarg ;;
1578 -libdir | --libdir | --libdi | --libd)
1579 ac_prev=libdir ;;
1580 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1581 libdir=$ac_optarg ;;
1583 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1584 | --libexe | --libex | --libe)
1585 ac_prev=libexecdir ;;
1586 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1587 | --libexe=* | --libex=* | --libe=*)
1588 libexecdir=$ac_optarg ;;
1590 -localedir | --localedir | --localedi | --localed | --locale)
1591 ac_prev=localedir ;;
1592 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1593 localedir=$ac_optarg ;;
1595 -localstatedir | --localstatedir | --localstatedi | --localstated \
1596 | --localstate | --localstat | --localsta | --localst | --locals)
1597 ac_prev=localstatedir ;;
1598 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1599 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1600 localstatedir=$ac_optarg ;;
1602 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1603 ac_prev=mandir ;;
1604 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1605 mandir=$ac_optarg ;;
1607 -nfp | --nfp | --nf)
1608 # Obsolete; use --without-fp.
1609 with_fp=no ;;
1611 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1612 | --no-cr | --no-c | -n)
1613 no_create=yes ;;
1615 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1616 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1617 no_recursion=yes ;;
1619 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1620 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1621 | --oldin | --oldi | --old | --ol | --o)
1622 ac_prev=oldincludedir ;;
1623 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1624 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1625 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1626 oldincludedir=$ac_optarg ;;
1628 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1629 ac_prev=prefix ;;
1630 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1631 prefix=$ac_optarg ;;
1633 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1634 | --program-pre | --program-pr | --program-p)
1635 ac_prev=program_prefix ;;
1636 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1637 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1638 program_prefix=$ac_optarg ;;
1640 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1641 | --program-suf | --program-su | --program-s)
1642 ac_prev=program_suffix ;;
1643 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1644 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1645 program_suffix=$ac_optarg ;;
1647 -program-transform-name | --program-transform-name \
1648 | --program-transform-nam | --program-transform-na \
1649 | --program-transform-n | --program-transform- \
1650 | --program-transform | --program-transfor \
1651 | --program-transfo | --program-transf \
1652 | --program-trans | --program-tran \
1653 | --progr-tra | --program-tr | --program-t)
1654 ac_prev=program_transform_name ;;
1655 -program-transform-name=* | --program-transform-name=* \
1656 | --program-transform-nam=* | --program-transform-na=* \
1657 | --program-transform-n=* | --program-transform-=* \
1658 | --program-transform=* | --program-transfor=* \
1659 | --program-transfo=* | --program-transf=* \
1660 | --program-trans=* | --program-tran=* \
1661 | --progr-tra=* | --program-tr=* | --program-t=*)
1662 program_transform_name=$ac_optarg ;;
1664 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1665 ac_prev=pdfdir ;;
1666 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1667 pdfdir=$ac_optarg ;;
1669 -psdir | --psdir | --psdi | --psd | --ps)
1670 ac_prev=psdir ;;
1671 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1672 psdir=$ac_optarg ;;
1674 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1675 | -silent | --silent | --silen | --sile | --sil)
1676 silent=yes ;;
1678 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1679 ac_prev=sbindir ;;
1680 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1681 | --sbi=* | --sb=*)
1682 sbindir=$ac_optarg ;;
1684 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1685 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1686 | --sharedst | --shareds | --shared | --share | --shar \
1687 | --sha | --sh)
1688 ac_prev=sharedstatedir ;;
1689 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1690 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1691 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1692 | --sha=* | --sh=*)
1693 sharedstatedir=$ac_optarg ;;
1695 -site | --site | --sit)
1696 ac_prev=site ;;
1697 -site=* | --site=* | --sit=*)
1698 site=$ac_optarg ;;
1700 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1701 ac_prev=srcdir ;;
1702 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1703 srcdir=$ac_optarg ;;
1705 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1706 | --syscon | --sysco | --sysc | --sys | --sy)
1707 ac_prev=sysconfdir ;;
1708 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1709 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1710 sysconfdir=$ac_optarg ;;
1712 -target | --target | --targe | --targ | --tar | --ta | --t)
1713 ac_prev=target_alias ;;
1714 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1715 target_alias=$ac_optarg ;;
1717 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1718 verbose=yes ;;
1720 -version | --version | --versio | --versi | --vers | -V)
1721 ac_init_version=: ;;
1723 -with-* | --with-*)
1724 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1725 # Reject names that are not valid shell variable names.
1726 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1727 as_fn_error "invalid package name: $ac_useropt"
1728 ac_useropt_orig=$ac_useropt
1729 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1730 case $ac_user_opts in
1732 "with_$ac_useropt"
1733 "*) ;;
1734 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1735 ac_unrecognized_sep=', ';;
1736 esac
1737 eval with_$ac_useropt=\$ac_optarg ;;
1739 -without-* | --without-*)
1740 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1741 # Reject names that are not valid shell variable names.
1742 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1743 as_fn_error "invalid package name: $ac_useropt"
1744 ac_useropt_orig=$ac_useropt
1745 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1746 case $ac_user_opts in
1748 "with_$ac_useropt"
1749 "*) ;;
1750 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1751 ac_unrecognized_sep=', ';;
1752 esac
1753 eval with_$ac_useropt=no ;;
1755 --x)
1756 # Obsolete; use --with-x.
1757 with_x=yes ;;
1759 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1760 | --x-incl | --x-inc | --x-in | --x-i)
1761 ac_prev=x_includes ;;
1762 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1763 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1764 x_includes=$ac_optarg ;;
1766 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1767 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1768 ac_prev=x_libraries ;;
1769 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1770 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1771 x_libraries=$ac_optarg ;;
1773 -*) as_fn_error "unrecognized option: \`$ac_option'
1774 Try \`$0 --help' for more information."
1777 *=*)
1778 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1779 # Reject names that are not valid shell variable names.
1780 case $ac_envvar in #(
1781 '' | [0-9]* | *[!_$as_cr_alnum]* )
1782 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1783 esac
1784 eval $ac_envvar=\$ac_optarg
1785 export $ac_envvar ;;
1788 # FIXME: should be removed in autoconf 3.0.
1789 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1790 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1791 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1792 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1795 esac
1796 done
1798 if test -n "$ac_prev"; then
1799 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1800 as_fn_error "missing argument to $ac_option"
1803 if test -n "$ac_unrecognized_opts"; then
1804 case $enable_option_checking in
1805 no) ;;
1806 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1807 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1808 esac
1811 # Check all directory arguments for consistency.
1812 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1813 datadir sysconfdir sharedstatedir localstatedir includedir \
1814 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1815 libdir localedir mandir
1817 eval ac_val=\$$ac_var
1818 # Remove trailing slashes.
1819 case $ac_val in
1820 */ )
1821 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1822 eval $ac_var=\$ac_val;;
1823 esac
1824 # Be sure to have absolute directory names.
1825 case $ac_val in
1826 [\\/$]* | ?:[\\/]* ) continue;;
1827 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1828 esac
1829 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1830 done
1832 # There might be people who depend on the old broken behavior: `$host'
1833 # used to hold the argument of --host etc.
1834 # FIXME: To remove some day.
1835 build=$build_alias
1836 host=$host_alias
1837 target=$target_alias
1839 # FIXME: To remove some day.
1840 if test "x$host_alias" != x; then
1841 if test "x$build_alias" = x; then
1842 cross_compiling=maybe
1843 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1844 If a cross compiler is detected then cross compile mode will be used." >&2
1845 elif test "x$build_alias" != "x$host_alias"; then
1846 cross_compiling=yes
1850 ac_tool_prefix=
1851 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1853 test "$silent" = yes && exec 6>/dev/null
1856 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1857 ac_ls_di=`ls -di .` &&
1858 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1859 as_fn_error "working directory cannot be determined"
1860 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1861 as_fn_error "pwd does not report name of working directory"
1864 # Find the source files, if location was not specified.
1865 if test -z "$srcdir"; then
1866 ac_srcdir_defaulted=yes
1867 # Try the directory containing this script, then the parent directory.
1868 ac_confdir=`$as_dirname -- "$as_myself" ||
1869 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1870 X"$as_myself" : 'X\(//\)[^/]' \| \
1871 X"$as_myself" : 'X\(//\)$' \| \
1872 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1873 $as_echo X"$as_myself" |
1874 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1875 s//\1/
1878 /^X\(\/\/\)[^/].*/{
1879 s//\1/
1882 /^X\(\/\/\)$/{
1883 s//\1/
1886 /^X\(\/\).*/{
1887 s//\1/
1890 s/.*/./; q'`
1891 srcdir=$ac_confdir
1892 if test ! -r "$srcdir/$ac_unique_file"; then
1893 srcdir=..
1895 else
1896 ac_srcdir_defaulted=no
1898 if test ! -r "$srcdir/$ac_unique_file"; then
1899 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1900 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1902 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1903 ac_abs_confdir=`(
1904 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1905 pwd)`
1906 # When building in place, set srcdir=.
1907 if test "$ac_abs_confdir" = "$ac_pwd"; then
1908 srcdir=.
1910 # Remove unnecessary trailing slashes from srcdir.
1911 # Double slashes in file names in object file debugging info
1912 # mess up M-x gdb in Emacs.
1913 case $srcdir in
1914 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1915 esac
1916 for ac_var in $ac_precious_vars; do
1917 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1918 eval ac_env_${ac_var}_value=\$${ac_var}
1919 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1920 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1921 done
1924 # Report the --help message.
1926 if test "$ac_init_help" = "long"; then
1927 # Omit some internal or obsolete options to make the list less imposing.
1928 # This message is too long to be a string in the A/UX 3.1 sh.
1929 cat <<_ACEOF
1930 \`configure' configures emacs 24.1.50 to adapt to many kinds of systems.
1932 Usage: $0 [OPTION]... [VAR=VALUE]...
1934 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1935 VAR=VALUE. See below for descriptions of some of the useful variables.
1937 Defaults for the options are specified in brackets.
1939 Configuration:
1940 -h, --help display this help and exit
1941 --help=short display options specific to this package
1942 --help=recursive display the short help of all the included packages
1943 -V, --version display version information and exit
1944 -q, --quiet, --silent do not print \`checking...' messages
1945 --cache-file=FILE cache test results in FILE [disabled]
1946 -C, --config-cache alias for \`--cache-file=config.cache'
1947 -n, --no-create do not create output files
1948 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1950 Installation directories:
1951 --prefix=PREFIX install architecture-independent files in PREFIX
1952 [$ac_default_prefix]
1953 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1954 [PREFIX]
1956 By default, \`make install' will install all the files in
1957 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1958 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1959 for instance \`--prefix=\$HOME'.
1961 For better control, use the options below.
1963 Fine tuning of the installation directories:
1964 --bindir=DIR user executables [EPREFIX/bin]
1965 --sbindir=DIR system admin executables [EPREFIX/sbin]
1966 --libexecdir=DIR program executables [EPREFIX/libexec]
1967 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1968 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1969 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1970 --libdir=DIR object code libraries [EPREFIX/lib]
1971 --includedir=DIR C header files [PREFIX/include]
1972 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1973 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1974 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1975 --infodir=DIR info documentation [DATAROOTDIR/info]
1976 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1977 --mandir=DIR man documentation [DATAROOTDIR/man]
1978 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1979 --htmldir=DIR html documentation [DOCDIR]
1980 --dvidir=DIR dvi documentation [DOCDIR]
1981 --pdfdir=DIR pdf documentation [DOCDIR]
1982 --psdir=DIR ps documentation [DOCDIR]
1983 _ACEOF
1985 cat <<\_ACEOF
1987 Program names:
1988 --program-prefix=PREFIX prepend PREFIX to installed program names
1989 --program-suffix=SUFFIX append SUFFIX to installed program names
1990 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1992 X features:
1993 --x-includes=DIR X include files are in DIR
1994 --x-libraries=DIR X library files are in DIR
1996 System types:
1997 --build=BUILD configure for building on BUILD [guessed]
1998 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1999 _ACEOF
2002 if test -n "$ac_init_help"; then
2003 case $ac_init_help in
2004 short | recursive ) echo "Configuration of emacs 24.1.50:";;
2005 esac
2006 cat <<\_ACEOF
2008 Optional Features:
2009 --disable-option-checking ignore unrecognized --enable/--with options
2010 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2011 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2012 --disable-ns-self-contained
2013 disable self contained build under NeXTstep
2014 --enable-locallisppath=PATH
2015 directories Emacs should search for lisp files
2016 specific to this site
2017 --enable-checking[=LIST]
2018 enable expensive run-time checks. With LIST, enable
2019 only specific categories of checks. Categories are:
2020 all,yes,no. Flags are: stringbytes, stringoverrun,
2021 stringfreelist, xmallocoverrun, conslist, glyphs
2022 --enable-check-lisp-object-type
2023 enable compile time checks for the Lisp_Object data
2024 type. This is useful for development for catching
2025 certain types of bugs.
2026 --enable-profiling build emacs with profiling support. This might not
2027 work on all platforms
2028 --enable-autodepend automatically generate dependencies to .h-files.
2029 Requires GNU Make and Gcc. Enabled if GNU Make and
2030 Gcc is found
2031 --disable-dependency-tracking speeds up one-time build
2032 --enable-dependency-tracking do not reject slow dependency extractors
2033 --disable-largefile omit support for large files
2034 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2035 developers, and may generate false alarms when used
2036 with older or non-GNU development tools.
2037 --enable-link-time-optimization
2038 build emacs with link-time optimization. This is
2039 supported only for GCC since 4.5.0.
2041 Optional Packages:
2042 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2043 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2044 --without-pop don't support POP mail retrieval with movemail
2045 --with-kerberos support Kerberos-authenticated POP
2046 --with-kerberos5 support Kerberos version 5 authenticated POP
2047 --with-hesiod support Hesiod to get the POP server host
2048 --with-mmdf support MMDF mailboxes
2049 --with-mail-unlink unlink, rather than empty, mail spool after reading
2050 --with-mailhost=HOSTNAME
2051 string giving default POP mail host
2052 --without-sound don't compile with sound support
2053 --without-sync-input process async input synchronously
2054 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
2055 lucid or athena, motif, no)
2056 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2057 --without-xpm don't compile with XPM image support
2058 --without-jpeg don't compile with JPEG image support
2059 --without-tiff don't compile with TIFF image support
2060 --without-gif don't compile with GIF image support
2061 --without-png don't compile with PNG image support
2062 --without-rsvg don't compile with SVG image support
2063 --without-xml2 don't compile with XML parsing support
2064 --without-imagemagick don't compile with ImageMagick image support
2065 --without-xft don't use XFT for anti aliased fonts
2066 --without-libotf don't use libotf for OpenType font support
2067 --without-m17n-flt don't use m17n-flt for text shaping
2068 --without-toolkit-scroll-bars
2069 don't use Motif or Xaw3d scroll bars
2070 --without-xaw3d don't use Xaw3d
2071 --without-xim don't use X11 XIM
2072 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2073 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2074 console
2075 --without-dbus don't compile with D-Bus support
2076 --without-gconf don't compile with GConf support
2077 --without-gsettings don't compile with GSettings support
2078 --without-selinux don't compile with SELinux support
2079 --without-gnutls don't use -lgnutls for SSL/TLS support
2080 --without-makeinfo don't require makeinfo for building manuals
2081 --without-compress-info don't compress the installed Info pages
2082 --with-pkg-config-prog=PATH
2083 path to pkg-config for finding GTK and librsvg
2084 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2085 /usr/lib, or /usr/lib64 on some platforms.
2086 --with-gameuser=USER user for shared game score files
2087 --with-gnustep-conf=PATH
2088 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2089 or /etc/GNUstep/GNUstep.conf
2090 --with-x use the X Window System
2092 Some influential environment variables:
2093 CC C compiler command
2094 CFLAGS C compiler flags
2095 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2096 nonstandard directory <lib dir>
2097 LIBS libraries to pass to the linker, e.g. -l<library>
2098 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2099 you have headers in a nonstandard directory <include dir>
2100 CPP C preprocessor
2101 XMKMF Path to xmkmf, Makefile generator for X Window System
2103 Use these variables to override the choices made by `configure' or to help
2104 it to find libraries and programs with nonstandard names/locations.
2106 Report bugs to the package provider.
2107 _ACEOF
2108 ac_status=$?
2111 if test "$ac_init_help" = "recursive"; then
2112 # If there are subdirs, report their specific --help.
2113 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2114 test -d "$ac_dir" ||
2115 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2116 continue
2117 ac_builddir=.
2119 case "$ac_dir" in
2120 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2122 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2123 # A ".." for each directory in $ac_dir_suffix.
2124 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2125 case $ac_top_builddir_sub in
2126 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2127 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2128 esac ;;
2129 esac
2130 ac_abs_top_builddir=$ac_pwd
2131 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2132 # for backward compatibility:
2133 ac_top_builddir=$ac_top_build_prefix
2135 case $srcdir in
2136 .) # We are building in place.
2137 ac_srcdir=.
2138 ac_top_srcdir=$ac_top_builddir_sub
2139 ac_abs_top_srcdir=$ac_pwd ;;
2140 [\\/]* | ?:[\\/]* ) # Absolute name.
2141 ac_srcdir=$srcdir$ac_dir_suffix;
2142 ac_top_srcdir=$srcdir
2143 ac_abs_top_srcdir=$srcdir ;;
2144 *) # Relative name.
2145 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2146 ac_top_srcdir=$ac_top_build_prefix$srcdir
2147 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2148 esac
2149 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2151 cd "$ac_dir" || { ac_status=$?; continue; }
2152 # Check for guested configure.
2153 if test -f "$ac_srcdir/configure.gnu"; then
2154 echo &&
2155 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2156 elif test -f "$ac_srcdir/configure"; then
2157 echo &&
2158 $SHELL "$ac_srcdir/configure" --help=recursive
2159 else
2160 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2161 fi || ac_status=$?
2162 cd "$ac_pwd" || { ac_status=$?; break; }
2163 done
2166 test -n "$ac_init_help" && exit $ac_status
2167 if $ac_init_version; then
2168 cat <<\_ACEOF
2169 emacs configure 24.1.50
2170 generated by GNU Autoconf 2.65
2172 Copyright (C) 2009 Free Software Foundation, Inc.
2173 This configure script is free software; the Free Software Foundation
2174 gives unlimited permission to copy, distribute and modify it.
2175 _ACEOF
2176 exit
2179 ## ------------------------ ##
2180 ## Autoconf initialization. ##
2181 ## ------------------------ ##
2183 # ac_fn_c_try_compile LINENO
2184 # --------------------------
2185 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2186 ac_fn_c_try_compile ()
2188 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2189 rm -f conftest.$ac_objext
2190 if { { ac_try="$ac_compile"
2191 case "(($ac_try" in
2192 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2193 *) ac_try_echo=$ac_try;;
2194 esac
2195 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2196 $as_echo "$ac_try_echo"; } >&5
2197 (eval "$ac_compile") 2>conftest.err
2198 ac_status=$?
2199 if test -s conftest.err; then
2200 grep -v '^ *+' conftest.err >conftest.er1
2201 cat conftest.er1 >&5
2202 mv -f conftest.er1 conftest.err
2204 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2205 test $ac_status = 0; } && {
2206 test -z "$ac_c_werror_flag" ||
2207 test ! -s conftest.err
2208 } && test -s conftest.$ac_objext; then :
2209 ac_retval=0
2210 else
2211 $as_echo "$as_me: failed program was:" >&5
2212 sed 's/^/| /' conftest.$ac_ext >&5
2214 ac_retval=1
2216 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2217 as_fn_set_status $ac_retval
2219 } # ac_fn_c_try_compile
2221 # ac_fn_c_try_cpp LINENO
2222 # ----------------------
2223 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2224 ac_fn_c_try_cpp ()
2226 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2227 if { { ac_try="$ac_cpp conftest.$ac_ext"
2228 case "(($ac_try" in
2229 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2230 *) ac_try_echo=$ac_try;;
2231 esac
2232 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2233 $as_echo "$ac_try_echo"; } >&5
2234 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2235 ac_status=$?
2236 if test -s conftest.err; then
2237 grep -v '^ *+' conftest.err >conftest.er1
2238 cat conftest.er1 >&5
2239 mv -f conftest.er1 conftest.err
2241 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2242 test $ac_status = 0; } >/dev/null && {
2243 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2244 test ! -s conftest.err
2245 }; then :
2246 ac_retval=0
2247 else
2248 $as_echo "$as_me: failed program was:" >&5
2249 sed 's/^/| /' conftest.$ac_ext >&5
2251 ac_retval=1
2253 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2254 as_fn_set_status $ac_retval
2256 } # ac_fn_c_try_cpp
2258 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2259 # -------------------------------------------------------
2260 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2261 # the include files in INCLUDES and setting the cache variable VAR
2262 # accordingly.
2263 ac_fn_c_check_header_mongrel ()
2265 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2266 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2268 $as_echo_n "checking for $2... " >&6; }
2269 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2270 $as_echo_n "(cached) " >&6
2272 eval ac_res=\$$3
2273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2274 $as_echo "$ac_res" >&6; }
2275 else
2276 # Is the header compilable?
2277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2278 $as_echo_n "checking $2 usability... " >&6; }
2279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2280 /* end confdefs.h. */
2282 #include <$2>
2283 _ACEOF
2284 if ac_fn_c_try_compile "$LINENO"; then :
2285 ac_header_compiler=yes
2286 else
2287 ac_header_compiler=no
2289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2291 $as_echo "$ac_header_compiler" >&6; }
2293 # Is the header present?
2294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2295 $as_echo_n "checking $2 presence... " >&6; }
2296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2297 /* end confdefs.h. */
2298 #include <$2>
2299 _ACEOF
2300 if ac_fn_c_try_cpp "$LINENO"; then :
2301 ac_header_preproc=yes
2302 else
2303 ac_header_preproc=no
2305 rm -f conftest.err conftest.$ac_ext
2306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2307 $as_echo "$ac_header_preproc" >&6; }
2309 # So? What about this header?
2310 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2311 yes:no: )
2312 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2313 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2315 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2317 no:yes:* )
2318 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2319 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2320 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2321 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2322 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2323 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2324 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2325 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2326 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2327 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2329 esac
2330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2331 $as_echo_n "checking for $2... " >&6; }
2332 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2333 $as_echo_n "(cached) " >&6
2334 else
2335 eval "$3=\$ac_header_compiler"
2337 eval ac_res=\$$3
2338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2339 $as_echo "$ac_res" >&6; }
2341 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2343 } # ac_fn_c_check_header_mongrel
2345 # ac_fn_c_try_run LINENO
2346 # ----------------------
2347 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2348 # that executables *can* be run.
2349 ac_fn_c_try_run ()
2351 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2352 if { { ac_try="$ac_link"
2353 case "(($ac_try" in
2354 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2355 *) ac_try_echo=$ac_try;;
2356 esac
2357 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2358 $as_echo "$ac_try_echo"; } >&5
2359 (eval "$ac_link") 2>&5
2360 ac_status=$?
2361 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2362 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2363 { { case "(($ac_try" in
2364 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2365 *) ac_try_echo=$ac_try;;
2366 esac
2367 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2368 $as_echo "$ac_try_echo"; } >&5
2369 (eval "$ac_try") 2>&5
2370 ac_status=$?
2371 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2372 test $ac_status = 0; }; }; then :
2373 ac_retval=0
2374 else
2375 $as_echo "$as_me: program exited with status $ac_status" >&5
2376 $as_echo "$as_me: failed program was:" >&5
2377 sed 's/^/| /' conftest.$ac_ext >&5
2379 ac_retval=$ac_status
2381 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2382 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2383 as_fn_set_status $ac_retval
2385 } # ac_fn_c_try_run
2387 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2388 # -------------------------------------------------------
2389 # Tests whether HEADER exists and can be compiled using the include files in
2390 # INCLUDES, setting the cache variable VAR accordingly.
2391 ac_fn_c_check_header_compile ()
2393 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2395 $as_echo_n "checking for $2... " >&6; }
2396 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2397 $as_echo_n "(cached) " >&6
2398 else
2399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2400 /* end confdefs.h. */
2402 #include <$2>
2403 _ACEOF
2404 if ac_fn_c_try_compile "$LINENO"; then :
2405 eval "$3=yes"
2406 else
2407 eval "$3=no"
2409 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2411 eval ac_res=\$$3
2412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2413 $as_echo "$ac_res" >&6; }
2414 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2416 } # ac_fn_c_check_header_compile
2418 # ac_fn_c_try_link LINENO
2419 # -----------------------
2420 # Try to link conftest.$ac_ext, and return whether this succeeded.
2421 ac_fn_c_try_link ()
2423 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2424 rm -f conftest.$ac_objext conftest$ac_exeext
2425 if { { ac_try="$ac_link"
2426 case "(($ac_try" in
2427 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2428 *) ac_try_echo=$ac_try;;
2429 esac
2430 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2431 $as_echo "$ac_try_echo"; } >&5
2432 (eval "$ac_link") 2>conftest.err
2433 ac_status=$?
2434 if test -s conftest.err; then
2435 grep -v '^ *+' conftest.err >conftest.er1
2436 cat conftest.er1 >&5
2437 mv -f conftest.er1 conftest.err
2439 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2440 test $ac_status = 0; } && {
2441 test -z "$ac_c_werror_flag" ||
2442 test ! -s conftest.err
2443 } && test -s conftest$ac_exeext && {
2444 test "$cross_compiling" = yes ||
2445 $as_test_x conftest$ac_exeext
2446 }; then :
2447 ac_retval=0
2448 else
2449 $as_echo "$as_me: failed program was:" >&5
2450 sed 's/^/| /' conftest.$ac_ext >&5
2452 ac_retval=1
2454 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2455 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2456 # interfere with the next link command; also delete a directory that is
2457 # left behind by Apple's compiler. We do this before executing the actions.
2458 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2459 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2460 as_fn_set_status $ac_retval
2462 } # ac_fn_c_try_link
2464 # ac_fn_c_check_decl LINENO SYMBOL VAR
2465 # ------------------------------------
2466 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2467 ac_fn_c_check_decl ()
2469 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2471 $as_echo_n "checking whether $2 is declared... " >&6; }
2472 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2473 $as_echo_n "(cached) " >&6
2474 else
2475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2476 /* end confdefs.h. */
2479 main ()
2481 #ifndef $2
2482 (void) $2;
2483 #endif
2486 return 0;
2488 _ACEOF
2489 if ac_fn_c_try_compile "$LINENO"; then :
2490 eval "$3=yes"
2491 else
2492 eval "$3=no"
2494 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2496 eval ac_res=\$$3
2497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2498 $as_echo "$ac_res" >&6; }
2499 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2501 } # ac_fn_c_check_decl
2503 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2504 # ----------------------------------------------
2505 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2506 ac_fn_c_check_header_preproc ()
2508 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2510 $as_echo_n "checking for $2... " >&6; }
2511 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2512 $as_echo_n "(cached) " >&6
2513 else
2514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2515 /* end confdefs.h. */
2516 #include <$2>
2517 _ACEOF
2518 if ac_fn_c_try_cpp "$LINENO"; then :
2519 eval "$3=yes"
2520 else
2521 eval "$3=no"
2523 rm -f conftest.err conftest.$ac_ext
2525 eval ac_res=\$$3
2526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2527 $as_echo "$ac_res" >&6; }
2528 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2530 } # ac_fn_c_check_header_preproc
2532 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2533 # ----------------------------------------------------
2534 # Tries to find if the field MEMBER exists in type AGGR, after including
2535 # INCLUDES, setting cache variable VAR accordingly.
2536 ac_fn_c_check_member ()
2538 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2540 $as_echo_n "checking for $2.$3... " >&6; }
2541 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2542 $as_echo_n "(cached) " >&6
2543 else
2544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2545 /* end confdefs.h. */
2548 main ()
2550 static $2 ac_aggr;
2551 if (ac_aggr.$3)
2552 return 0;
2554 return 0;
2556 _ACEOF
2557 if ac_fn_c_try_compile "$LINENO"; then :
2558 eval "$4=yes"
2559 else
2560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2561 /* end confdefs.h. */
2564 main ()
2566 static $2 ac_aggr;
2567 if (sizeof ac_aggr.$3)
2568 return 0;
2570 return 0;
2572 _ACEOF
2573 if ac_fn_c_try_compile "$LINENO"; then :
2574 eval "$4=yes"
2575 else
2576 eval "$4=no"
2578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2582 eval ac_res=\$$4
2583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2584 $as_echo "$ac_res" >&6; }
2585 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2587 } # ac_fn_c_check_member
2589 # ac_fn_c_check_func LINENO FUNC VAR
2590 # ----------------------------------
2591 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2592 ac_fn_c_check_func ()
2594 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2596 $as_echo_n "checking for $2... " >&6; }
2597 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2598 $as_echo_n "(cached) " >&6
2599 else
2600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2601 /* end confdefs.h. */
2602 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2603 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2604 #define $2 innocuous_$2
2606 /* System header to define __stub macros and hopefully few prototypes,
2607 which can conflict with char $2 (); below.
2608 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2609 <limits.h> exists even on freestanding compilers. */
2611 #ifdef __STDC__
2612 # include <limits.h>
2613 #else
2614 # include <assert.h>
2615 #endif
2617 #undef $2
2619 /* Override any GCC internal prototype to avoid an error.
2620 Use char because int might match the return type of a GCC
2621 builtin and then its argument prototype would still apply. */
2622 #ifdef __cplusplus
2623 extern "C"
2624 #endif
2625 char $2 ();
2626 /* The GNU C library defines this for functions which it implements
2627 to always fail with ENOSYS. Some functions are actually named
2628 something starting with __ and the normal name is an alias. */
2629 #if defined __stub_$2 || defined __stub___$2
2630 choke me
2631 #endif
2634 main ()
2636 return $2 ();
2638 return 0;
2640 _ACEOF
2641 if ac_fn_c_try_link "$LINENO"; then :
2642 eval "$3=yes"
2643 else
2644 eval "$3=no"
2646 rm -f core conftest.err conftest.$ac_objext \
2647 conftest$ac_exeext conftest.$ac_ext
2649 eval ac_res=\$$3
2650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2651 $as_echo "$ac_res" >&6; }
2652 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2654 } # ac_fn_c_check_func
2656 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2657 # -------------------------------------------
2658 # Tests whether TYPE exists after having included INCLUDES, setting cache
2659 # variable VAR accordingly.
2660 ac_fn_c_check_type ()
2662 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2664 $as_echo_n "checking for $2... " >&6; }
2665 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2666 $as_echo_n "(cached) " >&6
2667 else
2668 eval "$3=no"
2669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2670 /* end confdefs.h. */
2673 main ()
2675 if (sizeof ($2))
2676 return 0;
2678 return 0;
2680 _ACEOF
2681 if ac_fn_c_try_compile "$LINENO"; then :
2682 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2683 /* end confdefs.h. */
2686 main ()
2688 if (sizeof (($2)))
2689 return 0;
2691 return 0;
2693 _ACEOF
2694 if ac_fn_c_try_compile "$LINENO"; then :
2696 else
2697 eval "$3=yes"
2699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2701 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2703 eval ac_res=\$$3
2704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2705 $as_echo "$ac_res" >&6; }
2706 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2708 } # ac_fn_c_check_type
2710 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2711 # --------------------------------------------
2712 # Tries to find the compile-time value of EXPR in a program that includes
2713 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2714 # computed
2715 ac_fn_c_compute_int ()
2717 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2718 if test "$cross_compiling" = yes; then
2719 # Depending upon the size, compute the lo and hi bounds.
2720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2721 /* end confdefs.h. */
2724 main ()
2726 static int test_array [1 - 2 * !(($2) >= 0)];
2727 test_array [0] = 0
2730 return 0;
2732 _ACEOF
2733 if ac_fn_c_try_compile "$LINENO"; then :
2734 ac_lo=0 ac_mid=0
2735 while :; do
2736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2737 /* end confdefs.h. */
2740 main ()
2742 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2743 test_array [0] = 0
2746 return 0;
2748 _ACEOF
2749 if ac_fn_c_try_compile "$LINENO"; then :
2750 ac_hi=$ac_mid; break
2751 else
2752 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2753 if test $ac_lo -le $ac_mid; then
2754 ac_lo= ac_hi=
2755 break
2757 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2760 done
2761 else
2762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2763 /* end confdefs.h. */
2766 main ()
2768 static int test_array [1 - 2 * !(($2) < 0)];
2769 test_array [0] = 0
2772 return 0;
2774 _ACEOF
2775 if ac_fn_c_try_compile "$LINENO"; then :
2776 ac_hi=-1 ac_mid=-1
2777 while :; do
2778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2779 /* end confdefs.h. */
2782 main ()
2784 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2785 test_array [0] = 0
2788 return 0;
2790 _ACEOF
2791 if ac_fn_c_try_compile "$LINENO"; then :
2792 ac_lo=$ac_mid; break
2793 else
2794 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2795 if test $ac_mid -le $ac_hi; then
2796 ac_lo= ac_hi=
2797 break
2799 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2801 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2802 done
2803 else
2804 ac_lo= ac_hi=
2806 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2808 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2809 # Binary search between lo and hi bounds.
2810 while test "x$ac_lo" != "x$ac_hi"; do
2811 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2813 /* end confdefs.h. */
2816 main ()
2818 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2819 test_array [0] = 0
2822 return 0;
2824 _ACEOF
2825 if ac_fn_c_try_compile "$LINENO"; then :
2826 ac_hi=$ac_mid
2827 else
2828 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2831 done
2832 case $ac_lo in #((
2833 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2834 '') ac_retval=1 ;;
2835 esac
2836 else
2837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2838 /* end confdefs.h. */
2840 static long int longval () { return $2; }
2841 static unsigned long int ulongval () { return $2; }
2842 #include <stdio.h>
2843 #include <stdlib.h>
2845 main ()
2848 FILE *f = fopen ("conftest.val", "w");
2849 if (! f)
2850 return 1;
2851 if (($2) < 0)
2853 long int i = longval ();
2854 if (i != ($2))
2855 return 1;
2856 fprintf (f, "%ld", i);
2858 else
2860 unsigned long int i = ulongval ();
2861 if (i != ($2))
2862 return 1;
2863 fprintf (f, "%lu", i);
2865 /* Do not output a trailing newline, as this causes \r\n confusion
2866 on some platforms. */
2867 return ferror (f) || fclose (f) != 0;
2870 return 0;
2872 _ACEOF
2873 if ac_fn_c_try_run "$LINENO"; then :
2874 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2875 else
2876 ac_retval=1
2878 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2879 conftest.$ac_objext conftest.beam conftest.$ac_ext
2880 rm -f conftest.val
2883 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2884 as_fn_set_status $ac_retval
2886 } # ac_fn_c_compute_int
2887 cat >config.log <<_ACEOF
2888 This file contains any messages produced by compilers while
2889 running configure, to aid debugging if configure makes a mistake.
2891 It was created by emacs $as_me 24.1.50, which was
2892 generated by GNU Autoconf 2.65. Invocation command line was
2894 $ $0 $@
2896 _ACEOF
2897 exec 5>>config.log
2899 cat <<_ASUNAME
2900 ## --------- ##
2901 ## Platform. ##
2902 ## --------- ##
2904 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2905 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2906 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2907 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2908 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2910 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2911 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2913 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2914 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2915 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2916 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2917 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2918 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2919 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2921 _ASUNAME
2923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2924 for as_dir in $PATH
2926 IFS=$as_save_IFS
2927 test -z "$as_dir" && as_dir=.
2928 $as_echo "PATH: $as_dir"
2929 done
2930 IFS=$as_save_IFS
2932 } >&5
2934 cat >&5 <<_ACEOF
2937 ## ----------- ##
2938 ## Core tests. ##
2939 ## ----------- ##
2941 _ACEOF
2944 # Keep a trace of the command line.
2945 # Strip out --no-create and --no-recursion so they do not pile up.
2946 # Strip out --silent because we don't want to record it for future runs.
2947 # Also quote any args containing shell meta-characters.
2948 # Make two passes to allow for proper duplicate-argument suppression.
2949 ac_configure_args=
2950 ac_configure_args0=
2951 ac_configure_args1=
2952 ac_must_keep_next=false
2953 for ac_pass in 1 2
2955 for ac_arg
2957 case $ac_arg in
2958 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2959 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2960 | -silent | --silent | --silen | --sile | --sil)
2961 continue ;;
2962 *\'*)
2963 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2964 esac
2965 case $ac_pass in
2966 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2968 as_fn_append ac_configure_args1 " '$ac_arg'"
2969 if test $ac_must_keep_next = true; then
2970 ac_must_keep_next=false # Got value, back to normal.
2971 else
2972 case $ac_arg in
2973 *=* | --config-cache | -C | -disable-* | --disable-* \
2974 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2975 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2976 | -with-* | --with-* | -without-* | --without-* | --x)
2977 case "$ac_configure_args0 " in
2978 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2979 esac
2981 -* ) ac_must_keep_next=true ;;
2982 esac
2984 as_fn_append ac_configure_args " '$ac_arg'"
2986 esac
2987 done
2988 done
2989 { ac_configure_args0=; unset ac_configure_args0;}
2990 { ac_configure_args1=; unset ac_configure_args1;}
2992 # When interrupted or exit'd, cleanup temporary files, and complete
2993 # config.log. We remove comments because anyway the quotes in there
2994 # would cause problems or look ugly.
2995 # WARNING: Use '\'' to represent an apostrophe within the trap.
2996 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2997 trap 'exit_status=$?
2998 # Save into config.log some information that might help in debugging.
3000 echo
3002 cat <<\_ASBOX
3003 ## ---------------- ##
3004 ## Cache variables. ##
3005 ## ---------------- ##
3006 _ASBOX
3007 echo
3008 # The following way of writing the cache mishandles newlines in values,
3010 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3011 eval ac_val=\$$ac_var
3012 case $ac_val in #(
3013 *${as_nl}*)
3014 case $ac_var in #(
3015 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3016 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3017 esac
3018 case $ac_var in #(
3019 _ | IFS | as_nl) ;; #(
3020 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3021 *) { eval $ac_var=; unset $ac_var;} ;;
3022 esac ;;
3023 esac
3024 done
3025 (set) 2>&1 |
3026 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3027 *${as_nl}ac_space=\ *)
3028 sed -n \
3029 "s/'\''/'\''\\\\'\'''\''/g;
3030 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3031 ;; #(
3033 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3035 esac |
3036 sort
3038 echo
3040 cat <<\_ASBOX
3041 ## ----------------- ##
3042 ## Output variables. ##
3043 ## ----------------- ##
3044 _ASBOX
3045 echo
3046 for ac_var in $ac_subst_vars
3048 eval ac_val=\$$ac_var
3049 case $ac_val in
3050 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3051 esac
3052 $as_echo "$ac_var='\''$ac_val'\''"
3053 done | sort
3054 echo
3056 if test -n "$ac_subst_files"; then
3057 cat <<\_ASBOX
3058 ## ------------------- ##
3059 ## File substitutions. ##
3060 ## ------------------- ##
3061 _ASBOX
3062 echo
3063 for ac_var in $ac_subst_files
3065 eval ac_val=\$$ac_var
3066 case $ac_val in
3067 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3068 esac
3069 $as_echo "$ac_var='\''$ac_val'\''"
3070 done | sort
3071 echo
3074 if test -s confdefs.h; then
3075 cat <<\_ASBOX
3076 ## ----------- ##
3077 ## confdefs.h. ##
3078 ## ----------- ##
3079 _ASBOX
3080 echo
3081 cat confdefs.h
3082 echo
3084 test "$ac_signal" != 0 &&
3085 $as_echo "$as_me: caught signal $ac_signal"
3086 $as_echo "$as_me: exit $exit_status"
3087 } >&5
3088 rm -f core *.core core.conftest.* &&
3089 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3090 exit $exit_status
3092 for ac_signal in 1 2 13 15; do
3093 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3094 done
3095 ac_signal=0
3097 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3098 rm -f -r conftest* confdefs.h
3100 $as_echo "/* confdefs.h */" > confdefs.h
3102 # Predefined preprocessor variables.
3104 cat >>confdefs.h <<_ACEOF
3105 #define PACKAGE_NAME "$PACKAGE_NAME"
3106 _ACEOF
3108 cat >>confdefs.h <<_ACEOF
3109 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3110 _ACEOF
3112 cat >>confdefs.h <<_ACEOF
3113 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3114 _ACEOF
3116 cat >>confdefs.h <<_ACEOF
3117 #define PACKAGE_STRING "$PACKAGE_STRING"
3118 _ACEOF
3120 cat >>confdefs.h <<_ACEOF
3121 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3122 _ACEOF
3124 cat >>confdefs.h <<_ACEOF
3125 #define PACKAGE_URL "$PACKAGE_URL"
3126 _ACEOF
3129 # Let the site file select an alternate cache file if it wants to.
3130 # Prefer an explicitly selected file to automatically selected ones.
3131 ac_site_file1=NONE
3132 ac_site_file2=NONE
3133 if test -n "$CONFIG_SITE"; then
3134 ac_site_file1=$CONFIG_SITE
3135 elif test "x$prefix" != xNONE; then
3136 ac_site_file1=$prefix/share/config.site
3137 ac_site_file2=$prefix/etc/config.site
3138 else
3139 ac_site_file1=$ac_default_prefix/share/config.site
3140 ac_site_file2=$ac_default_prefix/etc/config.site
3142 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3144 test "x$ac_site_file" = xNONE && continue
3145 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3146 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3147 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3148 sed 's/^/| /' "$ac_site_file" >&5
3149 . "$ac_site_file"
3151 done
3153 if test -r "$cache_file"; then
3154 # Some versions of bash will fail to source /dev/null (special files
3155 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3156 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3157 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3158 $as_echo "$as_me: loading cache $cache_file" >&6;}
3159 case $cache_file in
3160 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3161 *) . "./$cache_file";;
3162 esac
3164 else
3165 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3166 $as_echo "$as_me: creating cache $cache_file" >&6;}
3167 >$cache_file
3170 as_fn_append ac_header_list " linux/version.h"
3171 as_fn_append ac_header_list " sys/systeminfo.h"
3172 as_fn_append ac_header_list " stdio_ext.h"
3173 as_fn_append ac_header_list " fcntl.h"
3174 as_fn_append ac_header_list " coff.h"
3175 as_fn_append ac_header_list " pty.h"
3176 as_fn_append ac_header_list " sys/vlimit.h"
3177 as_fn_append ac_header_list " sys/resource.h"
3178 as_fn_append ac_header_list " sys/utsname.h"
3179 as_fn_append ac_header_list " pwd.h"
3180 as_fn_append ac_header_list " utmp.h"
3181 as_fn_append ac_header_list " dirent.h"
3182 as_fn_append ac_header_list " util.h"
3183 as_fn_append ac_header_list " sys/socket.h"
3184 as_fn_append ac_header_list " stdlib.h"
3185 as_fn_append ac_header_list " unistd.h"
3186 as_fn_append ac_header_list " sys/param.h"
3187 as_fn_append ac_header_list " pthread.h"
3188 as_fn_append ac_header_list " malloc/malloc.h"
3189 as_fn_append ac_header_list " maillock.h"
3190 as_fn_append ac_header_list " sys/un.h"
3191 as_fn_append ac_func_list " tzset"
3192 as_fn_append ac_func_list " readlinkat"
3193 gl_getopt_required=GNU
3194 as_fn_append ac_header_list " getopt.h"
3195 as_fn_append ac_func_list " gettimeofday"
3196 as_fn_append ac_func_list " nanotime"
3197 as_fn_append ac_header_list " sys/time.h"
3198 as_fn_append ac_header_list " wchar.h"
3199 as_fn_append ac_header_list " stdint.h"
3200 as_fn_append ac_header_list " inttypes.h"
3201 as_fn_append ac_func_list " lstat"
3202 as_fn_append ac_func_list " alarm"
3203 as_fn_append ac_header_list " sys/select.h"
3204 as_fn_append ac_func_list " pselect"
3205 as_fn_append ac_func_list " pthread_sigmask"
3206 as_fn_append ac_func_list " readlink"
3207 as_fn_append ac_func_list " strtoimax"
3208 as_fn_append ac_func_list " strtoumax"
3209 as_fn_append ac_func_list " symlink"
3210 as_fn_append ac_header_list " sys/stat.h"
3211 as_fn_append ac_func_list " localtime_r"
3212 as_fn_append ac_header_list " utime.h"
3213 as_fn_append ac_func_list " futimes"
3214 as_fn_append ac_func_list " futimesat"
3215 as_fn_append ac_func_list " futimens"
3216 as_fn_append ac_func_list " utimensat"
3217 as_fn_append ac_func_list " lutimes"
3218 # Check that the precious variables saved in the cache have kept the same
3219 # value.
3220 ac_cache_corrupted=false
3221 for ac_var in $ac_precious_vars; do
3222 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3223 eval ac_new_set=\$ac_env_${ac_var}_set
3224 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3225 eval ac_new_val=\$ac_env_${ac_var}_value
3226 case $ac_old_set,$ac_new_set in
3227 set,)
3228 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3229 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3230 ac_cache_corrupted=: ;;
3231 ,set)
3232 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3233 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3234 ac_cache_corrupted=: ;;
3235 ,);;
3237 if test "x$ac_old_val" != "x$ac_new_val"; then
3238 # differences in whitespace do not lead to failure.
3239 ac_old_val_w=`echo x $ac_old_val`
3240 ac_new_val_w=`echo x $ac_new_val`
3241 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3242 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3243 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3244 ac_cache_corrupted=:
3245 else
3246 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3247 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3248 eval $ac_var=\$ac_old_val
3250 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3251 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3252 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3253 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3254 fi;;
3255 esac
3256 # Pass precious variables to config.status.
3257 if test "$ac_new_set" = set; then
3258 case $ac_new_val in
3259 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3260 *) ac_arg=$ac_var=$ac_new_val ;;
3261 esac
3262 case " $ac_configure_args " in
3263 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3264 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3265 esac
3267 done
3268 if $ac_cache_corrupted; then
3269 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3270 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3271 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3272 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3273 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3275 ## -------------------- ##
3276 ## Main body of script. ##
3277 ## -------------------- ##
3279 ac_ext=c
3280 ac_cpp='$CPP $CPPFLAGS'
3281 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3282 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3283 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3286 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3289 ac_aux_dir=
3290 for ac_dir in build-aux "$srcdir"/build-aux; do
3291 for ac_t in install-sh install.sh shtool; do
3292 if test -f "$ac_dir/$ac_t"; then
3293 ac_aux_dir=$ac_dir
3294 ac_install_sh="$ac_aux_dir/$ac_t -c"
3295 break 2
3297 done
3298 done
3299 if test -z "$ac_aux_dir"; then
3300 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3303 # These three variables are undocumented and unsupported,
3304 # and are intended to be withdrawn in a future Autoconf release.
3305 # They can cause serious problems if a builder's source tree is in a directory
3306 # whose full name contains unusual characters.
3307 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3308 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3309 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3312 am__api_version='1.11'
3314 # Find a good install program. We prefer a C program (faster),
3315 # so one script is as good as another. But avoid the broken or
3316 # incompatible versions:
3317 # SysV /etc/install, /usr/sbin/install
3318 # SunOS /usr/etc/install
3319 # IRIX /sbin/install
3320 # AIX /bin/install
3321 # AmigaOS /C/install, which installs bootblocks on floppy discs
3322 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3323 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3324 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3325 # OS/2's system install, which has a completely different semantic
3326 # ./install, which can be erroneously created by make from ./install.sh.
3327 # Reject install programs that cannot install multiple files.
3328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3329 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3330 if test -z "$INSTALL"; then
3331 if test "${ac_cv_path_install+set}" = set; then :
3332 $as_echo_n "(cached) " >&6
3333 else
3334 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3335 for as_dir in $PATH
3337 IFS=$as_save_IFS
3338 test -z "$as_dir" && as_dir=.
3339 # Account for people who put trailing slashes in PATH elements.
3340 case $as_dir/ in #((
3341 ./ | .// | /[cC]/* | \
3342 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3343 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3344 /usr/ucb/* ) ;;
3346 # OSF1 and SCO ODT 3.0 have their own names for install.
3347 # Don't use installbsd from OSF since it installs stuff as root
3348 # by default.
3349 for ac_prog in ginstall scoinst install; do
3350 for ac_exec_ext in '' $ac_executable_extensions; do
3351 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3352 if test $ac_prog = install &&
3353 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3354 # AIX install. It has an incompatible calling convention.
3356 elif test $ac_prog = install &&
3357 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3358 # program-specific install script used by HP pwplus--don't use.
3360 else
3361 rm -rf conftest.one conftest.two conftest.dir
3362 echo one > conftest.one
3363 echo two > conftest.two
3364 mkdir conftest.dir
3365 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3366 test -s conftest.one && test -s conftest.two &&
3367 test -s conftest.dir/conftest.one &&
3368 test -s conftest.dir/conftest.two
3369 then
3370 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3371 break 3
3375 done
3376 done
3378 esac
3380 done
3381 IFS=$as_save_IFS
3383 rm -rf conftest.one conftest.two conftest.dir
3386 if test "${ac_cv_path_install+set}" = set; then
3387 INSTALL=$ac_cv_path_install
3388 else
3389 # As a last resort, use the slow shell script. Don't cache a
3390 # value for INSTALL within a source directory, because that will
3391 # break other packages using the cache if that directory is
3392 # removed, or if the value is a relative name.
3393 INSTALL=$ac_install_sh
3396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3397 $as_echo "$INSTALL" >&6; }
3399 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3400 # It thinks the first close brace ends the variable substitution.
3401 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3403 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3405 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3408 $as_echo_n "checking whether build environment is sane... " >&6; }
3409 # Just in case
3410 sleep 1
3411 echo timestamp > conftest.file
3412 # Reject unsafe characters in $srcdir or the absolute working directory
3413 # name. Accept space and tab only in the latter.
3414 am_lf='
3416 case `pwd` in
3417 *[\\\"\#\$\&\'\`$am_lf]*)
3418 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3419 esac
3420 case $srcdir in
3421 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3422 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3423 esac
3425 # Do `set' in a subshell so we don't clobber the current shell's
3426 # arguments. Must try -L first in case configure is actually a
3427 # symlink; some systems play weird games with the mod time of symlinks
3428 # (eg FreeBSD returns the mod time of the symlink's containing
3429 # directory).
3430 if (
3431 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3432 if test "$*" = "X"; then
3433 # -L didn't work.
3434 set X `ls -t "$srcdir/configure" conftest.file`
3436 rm -f conftest.file
3437 if test "$*" != "X $srcdir/configure conftest.file" \
3438 && test "$*" != "X conftest.file $srcdir/configure"; then
3440 # If neither matched, then we have a broken ls. This can happen
3441 # if, for instance, CONFIG_SHELL is bash and it inherits a
3442 # broken ls alias from the environment. This has actually
3443 # happened. Such a system could not be considered "sane".
3444 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3445 alias in your environment" "$LINENO" 5
3448 test "$2" = conftest.file
3450 then
3451 # Ok.
3453 else
3454 as_fn_error "newly created file is older than distributed files!
3455 Check your system clock" "$LINENO" 5
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3458 $as_echo "yes" >&6; }
3459 test "$program_prefix" != NONE &&
3460 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3461 # Use a double $ so make ignores it.
3462 test "$program_suffix" != NONE &&
3463 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3464 # Double any \ or $.
3465 # By default was `s,x,x', remove it if useless.
3466 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3467 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3469 # expand $ac_aux_dir to an absolute path
3470 am_aux_dir=`cd $ac_aux_dir && pwd`
3472 if test x"${MISSING+set}" != xset; then
3473 case $am_aux_dir in
3474 *\ * | *\ *)
3475 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3477 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3478 esac
3480 # Use eval to expand $SHELL
3481 if eval "$MISSING --run true"; then
3482 am_missing_run="$MISSING --run "
3483 else
3484 am_missing_run=
3485 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3486 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3489 if test x"${install_sh}" != xset; then
3490 case $am_aux_dir in
3491 *\ * | *\ *)
3492 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3494 install_sh="\${SHELL} $am_aux_dir/install-sh"
3495 esac
3498 # Installed binaries are usually stripped using `strip' when the user
3499 # run `make install-strip'. However `strip' might not be the right
3500 # tool to use in cross-compilation environments, therefore Automake
3501 # will honor the `STRIP' environment variable to overrule this program.
3502 if test "$cross_compiling" != no; then
3503 if test -n "$ac_tool_prefix"; then
3504 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3505 set dummy ${ac_tool_prefix}strip; ac_word=$2
3506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3507 $as_echo_n "checking for $ac_word... " >&6; }
3508 if test "${ac_cv_prog_STRIP+set}" = set; then :
3509 $as_echo_n "(cached) " >&6
3510 else
3511 if test -n "$STRIP"; then
3512 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3513 else
3514 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3515 for as_dir in $PATH
3517 IFS=$as_save_IFS
3518 test -z "$as_dir" && as_dir=.
3519 for ac_exec_ext in '' $ac_executable_extensions; do
3520 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3521 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3523 break 2
3525 done
3526 done
3527 IFS=$as_save_IFS
3531 STRIP=$ac_cv_prog_STRIP
3532 if test -n "$STRIP"; then
3533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3534 $as_echo "$STRIP" >&6; }
3535 else
3536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3537 $as_echo "no" >&6; }
3542 if test -z "$ac_cv_prog_STRIP"; then
3543 ac_ct_STRIP=$STRIP
3544 # Extract the first word of "strip", so it can be a program name with args.
3545 set dummy strip; ac_word=$2
3546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3547 $as_echo_n "checking for $ac_word... " >&6; }
3548 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3549 $as_echo_n "(cached) " >&6
3550 else
3551 if test -n "$ac_ct_STRIP"; then
3552 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3553 else
3554 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3555 for as_dir in $PATH
3557 IFS=$as_save_IFS
3558 test -z "$as_dir" && as_dir=.
3559 for ac_exec_ext in '' $ac_executable_extensions; do
3560 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3561 ac_cv_prog_ac_ct_STRIP="strip"
3562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3563 break 2
3565 done
3566 done
3567 IFS=$as_save_IFS
3571 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3572 if test -n "$ac_ct_STRIP"; then
3573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3574 $as_echo "$ac_ct_STRIP" >&6; }
3575 else
3576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3577 $as_echo "no" >&6; }
3580 if test "x$ac_ct_STRIP" = x; then
3581 STRIP=":"
3582 else
3583 case $cross_compiling:$ac_tool_warned in
3584 yes:)
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3586 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3587 ac_tool_warned=yes ;;
3588 esac
3589 STRIP=$ac_ct_STRIP
3591 else
3592 STRIP="$ac_cv_prog_STRIP"
3596 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3599 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3600 if test -z "$MKDIR_P"; then
3601 if test "${ac_cv_path_mkdir+set}" = set; then :
3602 $as_echo_n "(cached) " >&6
3603 else
3604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3605 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3607 IFS=$as_save_IFS
3608 test -z "$as_dir" && as_dir=.
3609 for ac_prog in mkdir gmkdir; do
3610 for ac_exec_ext in '' $ac_executable_extensions; do
3611 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3612 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3613 'mkdir (GNU coreutils) '* | \
3614 'mkdir (coreutils) '* | \
3615 'mkdir (fileutils) '4.1*)
3616 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3617 break 3;;
3618 esac
3619 done
3620 done
3621 done
3622 IFS=$as_save_IFS
3626 test -d ./--version && rmdir ./--version
3627 if test "${ac_cv_path_mkdir+set}" = set; then
3628 MKDIR_P="$ac_cv_path_mkdir -p"
3629 else
3630 # As a last resort, use the slow shell script. Don't cache a
3631 # value for MKDIR_P within a source directory, because that will
3632 # break other packages using the cache if that directory is
3633 # removed, or if the value is a relative name.
3634 MKDIR_P="$ac_install_sh -d"
3637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3638 $as_echo "$MKDIR_P" >&6; }
3641 mkdir_p="$MKDIR_P"
3642 case $mkdir_p in
3643 [\\/$]* | ?:[\\/]*) ;;
3644 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3645 esac
3647 for ac_prog in gawk mawk nawk awk
3649 # Extract the first word of "$ac_prog", so it can be a program name with args.
3650 set dummy $ac_prog; ac_word=$2
3651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3652 $as_echo_n "checking for $ac_word... " >&6; }
3653 if test "${ac_cv_prog_AWK+set}" = set; then :
3654 $as_echo_n "(cached) " >&6
3655 else
3656 if test -n "$AWK"; then
3657 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3658 else
3659 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3660 for as_dir in $PATH
3662 IFS=$as_save_IFS
3663 test -z "$as_dir" && as_dir=.
3664 for ac_exec_ext in '' $ac_executable_extensions; do
3665 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3666 ac_cv_prog_AWK="$ac_prog"
3667 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3668 break 2
3670 done
3671 done
3672 IFS=$as_save_IFS
3676 AWK=$ac_cv_prog_AWK
3677 if test -n "$AWK"; then
3678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3679 $as_echo "$AWK" >&6; }
3680 else
3681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3682 $as_echo "no" >&6; }
3686 test -n "$AWK" && break
3687 done
3689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3690 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3691 set x ${MAKE-make}
3692 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3693 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3694 $as_echo_n "(cached) " >&6
3695 else
3696 cat >conftest.make <<\_ACEOF
3697 SHELL = /bin/sh
3698 all:
3699 @echo '@@@%%%=$(MAKE)=@@@%%%'
3700 _ACEOF
3701 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3702 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3703 *@@@%%%=?*=@@@%%%*)
3704 eval ac_cv_prog_make_${ac_make}_set=yes;;
3706 eval ac_cv_prog_make_${ac_make}_set=no;;
3707 esac
3708 rm -f conftest.make
3710 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3712 $as_echo "yes" >&6; }
3713 SET_MAKE=
3714 else
3715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3716 $as_echo "no" >&6; }
3717 SET_MAKE="MAKE=${MAKE-make}"
3720 rm -rf .tst 2>/dev/null
3721 mkdir .tst 2>/dev/null
3722 if test -d .tst; then
3723 am__leading_dot=.
3724 else
3725 am__leading_dot=_
3727 rmdir .tst 2>/dev/null
3729 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3730 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3731 # is not polluted with repeated "-I."
3732 am__isrc=' -I$(srcdir)'
3733 # test to see if srcdir already configured
3734 if test -f $srcdir/config.status; then
3735 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3739 # test whether we have cygpath
3740 if test -z "$CYGPATH_W"; then
3741 if (cygpath --version) >/dev/null 2>/dev/null; then
3742 CYGPATH_W='cygpath -w'
3743 else
3744 CYGPATH_W=echo
3749 # Define the identity of the package.
3750 PACKAGE='emacs'
3751 VERSION='24.1.50'
3754 cat >>confdefs.h <<_ACEOF
3755 #define PACKAGE "$PACKAGE"
3756 _ACEOF
3759 cat >>confdefs.h <<_ACEOF
3760 #define VERSION "$VERSION"
3761 _ACEOF
3763 # Some tools Automake needs.
3765 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3768 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3771 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3774 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3777 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3779 # We need awk for the "check" target. The system "awk" is bad on
3780 # some platforms.
3781 # Always define AMTAR for backward compatibility.
3783 AMTAR=${AMTAR-"${am_missing_run}tar"}
3785 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3794 lispdir='${datadir}/emacs/${version}/lisp'
3795 leimdir='${datadir}/emacs/${version}/leim'
3796 standardlisppath='${lispdir}:${leimdir}'
3797 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3798 '${datadir}/emacs/site-lisp'
3799 lisppath='${locallisppath}:${standardlisppath}'
3800 etcdir='${datadir}/emacs/${version}/etc'
3801 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3802 docdir='${datadir}/emacs/${version}/etc'
3803 gamedir='${localstatedir}/games/emacs'
3808 # Check whether --with-pop was given.
3809 if test "${with_pop+set}" = set; then :
3810 withval=$with_pop;
3811 else
3812 with_pop=yes
3815 if test "$with_pop" = yes; then
3816 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3821 # Check whether --with-kerberos was given.
3822 if test "${with_kerberos+set}" = set; then :
3823 withval=$with_kerberos;
3824 else
3825 with_kerberos=no
3828 if test "$with_kerberos" != no; then
3829 $as_echo "#define KERBEROS 1" >>confdefs.h
3834 # Check whether --with-kerberos5 was given.
3835 if test "${with_kerberos5+set}" = set; then :
3836 withval=$with_kerberos5;
3837 else
3838 with_kerberos5=no
3841 if test "${with_kerberos5}" != no; then
3842 if test "${with_kerberos}" = no; then
3843 with_kerberos=yes
3844 $as_echo "#define KERBEROS 1" >>confdefs.h
3848 $as_echo "#define KERBEROS5 1" >>confdefs.h
3853 # Check whether --with-hesiod was given.
3854 if test "${with_hesiod+set}" = set; then :
3855 withval=$with_hesiod;
3856 else
3857 with_hesiod=no
3860 if test "$with_hesiod" != no; then
3862 $as_echo "#define HESIOD 1" >>confdefs.h
3867 # Check whether --with-mmdf was given.
3868 if test "${with_mmdf+set}" = set; then :
3869 withval=$with_mmdf;
3870 else
3871 with_mmdf=no
3874 if test "$with_mmdf" != no; then
3876 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3881 # Check whether --with-mail-unlink was given.
3882 if test "${with_mail_unlink+set}" = set; then :
3883 withval=$with_mail_unlink;
3884 else
3885 with_mail_unlink=no
3888 if test "$with_mail_unlink" != no; then
3890 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3895 # Check whether --with-mailhost was given.
3896 if test "${with_mailhost+set}" = set; then :
3897 withval=$with_mailhost;
3898 cat >>confdefs.h <<_ACEOF
3899 #define MAILHOST "$withval"
3900 _ACEOF
3906 # Check whether --with-sound was given.
3907 if test "${with_sound+set}" = set; then :
3908 withval=$with_sound;
3909 else
3910 with_sound=yes
3915 # Check whether --with-sync-input was given.
3916 if test "${with_sync_input+set}" = set; then :
3917 withval=$with_sync_input;
3918 else
3919 with_sync_input=yes
3922 if test "$with_sync_input" = yes; then
3924 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
3929 # Check whether --with-x-toolkit was given.
3930 if test "${with_x_toolkit+set}" = set; then :
3931 withval=$with_x_toolkit; case "${withval}" in
3932 y | ye | yes ) val=gtk ;;
3933 n | no ) val=no ;;
3934 l | lu | luc | luci | lucid ) val=lucid ;;
3935 a | at | ath | athe | athen | athena ) val=athena ;;
3936 m | mo | mot | moti | motif ) val=motif ;;
3937 g | gt | gtk ) val=gtk ;;
3938 gtk3 ) val=gtk3 ;;
3940 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3941 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3942 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3944 esac
3945 with_x_toolkit=$val
3951 # Check whether --with-wide-int was given.
3952 if test "${with_wide_int+set}" = set; then :
3953 withval=$with_wide_int;
3954 else
3955 with_wide_int=no
3958 if test "$with_wide_int" = yes; then
3960 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3965 # Check whether --with-xpm was given.
3966 if test "${with_xpm+set}" = set; then :
3967 withval=$with_xpm;
3968 else
3969 with_xpm=yes
3973 # Check whether --with-jpeg was given.
3974 if test "${with_jpeg+set}" = set; then :
3975 withval=$with_jpeg;
3976 else
3977 with_jpeg=yes
3981 # Check whether --with-tiff was given.
3982 if test "${with_tiff+set}" = set; then :
3983 withval=$with_tiff;
3984 else
3985 with_tiff=yes
3989 # Check whether --with-gif was given.
3990 if test "${with_gif+set}" = set; then :
3991 withval=$with_gif;
3992 else
3993 with_gif=yes
3997 # Check whether --with-png was given.
3998 if test "${with_png+set}" = set; then :
3999 withval=$with_png;
4000 else
4001 with_png=yes
4005 # Check whether --with-rsvg was given.
4006 if test "${with_rsvg+set}" = set; then :
4007 withval=$with_rsvg;
4008 else
4009 with_rsvg=yes
4013 # Check whether --with-xml2 was given.
4014 if test "${with_xml2+set}" = set; then :
4015 withval=$with_xml2;
4016 else
4017 with_xml2=yes
4021 # Check whether --with-imagemagick was given.
4022 if test "${with_imagemagick+set}" = set; then :
4023 withval=$with_imagemagick;
4024 else
4025 with_imagemagick=yes
4030 # Check whether --with-xft was given.
4031 if test "${with_xft+set}" = set; then :
4032 withval=$with_xft;
4033 else
4034 with_xft=yes
4038 # Check whether --with-libotf was given.
4039 if test "${with_libotf+set}" = set; then :
4040 withval=$with_libotf;
4041 else
4042 with_libotf=yes
4046 # Check whether --with-m17n-flt was given.
4047 if test "${with_m17n_flt+set}" = set; then :
4048 withval=$with_m17n_flt;
4049 else
4050 with_m17n_flt=yes
4055 # Check whether --with-toolkit-scroll-bars was given.
4056 if test "${with_toolkit_scroll_bars+set}" = set; then :
4057 withval=$with_toolkit_scroll_bars;
4058 else
4059 with_toolkit_scroll_bars=yes
4063 # Check whether --with-xaw3d was given.
4064 if test "${with_xaw3d+set}" = set; then :
4065 withval=$with_xaw3d;
4066 else
4067 with_xaw3d=yes
4071 # Check whether --with-xim was given.
4072 if test "${with_xim+set}" = set; then :
4073 withval=$with_xim;
4074 else
4075 with_xim=yes
4079 # Check whether --with-ns was given.
4080 if test "${with_ns+set}" = set; then :
4081 withval=$with_ns;
4082 else
4083 with_ns=no
4088 # Check whether --with-gpm was given.
4089 if test "${with_gpm+set}" = set; then :
4090 withval=$with_gpm;
4091 else
4092 with_gpm=yes
4096 # Check whether --with-dbus was given.
4097 if test "${with_dbus+set}" = set; then :
4098 withval=$with_dbus;
4099 else
4100 with_dbus=yes
4104 # Check whether --with-gconf was given.
4105 if test "${with_gconf+set}" = set; then :
4106 withval=$with_gconf;
4107 else
4108 with_gconf=yes
4112 # Check whether --with-gsettings was given.
4113 if test "${with_gsettings+set}" = set; then :
4114 withval=$with_gsettings;
4115 else
4116 with_gsettings=yes
4120 # Check whether --with-selinux was given.
4121 if test "${with_selinux+set}" = set; then :
4122 withval=$with_selinux;
4123 else
4124 with_selinux=yes
4128 # Check whether --with-gnutls was given.
4129 if test "${with_gnutls+set}" = set; then :
4130 withval=$with_gnutls;
4131 else
4132 with_gnutls=yes
4136 ## For the times when you want to build Emacs but don't have
4137 ## a suitable makeinfo, and can live without the manuals.
4139 # Check whether --with-makeinfo was given.
4140 if test "${with_makeinfo+set}" = set; then :
4141 withval=$with_makeinfo;
4142 else
4143 with_makeinfo=yes
4147 ## Makefile.in needs the cache file name.
4150 ## This is an option because I do not know if all info/man support
4151 ## compressed files, nor how to test if they do so.
4153 # Check whether --with-compress-info was given.
4154 if test "${with_compress_info+set}" = set; then :
4155 withval=$with_compress_info;
4156 else
4157 with_compress_info=yes
4160 if test $with_compress_info = yes; then
4161 GZIP_INFO=yes
4162 else
4163 GZIP_INFO=
4168 # Check whether --with-pkg-config-prog was given.
4169 if test "${with_pkg_config_prog+set}" = set; then :
4170 withval=$with_pkg_config_prog;
4173 if test "X${with_pkg_config_prog}" != X; then
4174 if test "${with_pkg_config_prog}" != yes; then
4175 PKG_CONFIG="${with_pkg_config_prog}"
4179 CRT_DIR=
4181 # Check whether --with-crt-dir was given.
4182 if test "${with_crt_dir+set}" = set; then :
4183 withval=$with_crt_dir;
4186 CRT_DIR="${with_crt_dir}"
4189 # Check whether --with-gameuser was given.
4190 if test "${with_gameuser+set}" = set; then :
4191 withval=$with_gameuser;
4194 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4195 && gameuser="${with_gameuser}"
4196 test "X$gameuser" = X && gameuser=games
4199 # Check whether --with-gnustep-conf was given.
4200 if test "${with_gnustep_conf+set}" = set; then :
4201 withval=$with_gnustep_conf;
4204 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4205 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4206 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4207 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4209 # Check whether --enable-ns-self-contained was given.
4210 if test "${enable_ns_self_contained+set}" = set; then :
4211 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4212 else
4213 EN_NS_SELF_CONTAINED=yes
4217 # Check whether --enable-locallisppath was given.
4218 if test "${enable_locallisppath+set}" = set; then :
4219 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4220 locallisppath=
4221 elif test "${enableval}" != "yes"; then
4222 locallisppath=${enableval}
4227 # Check whether --enable-checking was given.
4228 if test "${enable_checking+set}" = set; then :
4229 enableval=$enable_checking; ac_checking_flags="${enableval}"
4232 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4233 for check in $ac_checking_flags
4235 case $check in
4236 # these set all the flags to specific states
4237 yes) ac_enable_checking=1 ;;
4238 no) ac_enable_checking= ;
4239 ac_gc_check_stringbytes= ;
4240 ac_gc_check_string_overrun= ;
4241 ac_gc_check_string_free_list= ;
4242 ac_xmalloc_overrun= ;
4243 ac_gc_check_cons_list= ;
4244 ac_glyphs_debug= ;;
4245 all) ac_enable_checking=1 ;
4246 ac_gc_check_stringbytes=1 ;
4247 ac_gc_check_string_overrun=1 ;
4248 ac_gc_check_string_free_list=1 ;
4249 ac_xmalloc_overrun=1 ;
4250 ac_gc_check_cons_list=1 ;
4251 ac_glyphs_debug=1 ;;
4252 # these enable particular checks
4253 stringbytes) ac_gc_check_stringbytes=1 ;;
4254 stringoverrun) ac_gc_check_string_overrun=1 ;;
4255 stringfreelist) ac_gc_check_string_free_list=1 ;;
4256 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4257 conslist) ac_gc_check_cons_list=1 ;;
4258 glyphs) ac_glyphs_debug=1 ;;
4259 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4260 esac
4261 done
4262 IFS="$ac_save_IFS"
4264 if test x$ac_enable_checking != x ; then
4266 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4269 if test x$ac_gc_check_stringbytes != x ; then
4271 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4274 if test x$ac_gc_check_string_overrun != x ; then
4276 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4279 if test x$ac_gc_check_string_free_list != x ; then
4281 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4284 if test x$ac_xmalloc_overrun != x ; then
4286 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4289 if test x$ac_gc_check_cons_list != x ; then
4291 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4294 if test x$ac_glyphs_debug != x ; then
4296 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4300 # Check whether --enable-check-lisp-object-type was given.
4301 if test "${enable_check_lisp_object_type+set}" = set; then :
4302 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4304 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4311 # Check whether --enable-profiling was given.
4312 if test "${enable_profiling+set}" = set; then :
4313 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4316 if test x$ac_enable_profiling != x ; then
4317 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4318 else
4319 PROFILING_CFLAGS=
4323 # Check whether --enable-autodepend was given.
4324 if test "${enable_autodepend+set}" = set; then :
4325 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4326 else
4327 ac_enable_autodepend=yes
4331 #### Make srcdir absolute, if it isn't already. It's important to
4332 #### avoid running the path through pwd unnecessarily, since pwd can
4333 #### give you automounter prefixes, which can go away. We do all this
4334 #### so Emacs can find its files when run uninstalled.
4335 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4336 unset CDPATH
4337 case "${srcdir}" in
4338 /* ) ;;
4340 ## We may be able to use the $PWD environment variable to make this
4341 ## absolute. But sometimes PWD is inaccurate.
4342 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4343 ## but that tested only for a well-formed and valid PWD,
4344 ## it did not object when PWD was well-formed and valid but just wrong.
4345 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4346 then
4347 srcdir="$PWD"
4348 else
4349 srcdir="`(cd ${srcdir}; pwd)`"
4352 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4353 esac
4355 ### Canonicalize the configuration name.
4357 # Make sure we can run config.sub.
4358 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4359 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4362 $as_echo_n "checking build system type... " >&6; }
4363 if test "${ac_cv_build+set}" = set; then :
4364 $as_echo_n "(cached) " >&6
4365 else
4366 ac_build_alias=$build_alias
4367 test "x$ac_build_alias" = x &&
4368 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4369 test "x$ac_build_alias" = x &&
4370 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4371 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4372 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4376 $as_echo "$ac_cv_build" >&6; }
4377 case $ac_cv_build in
4378 *-*-*) ;;
4379 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4380 esac
4381 build=$ac_cv_build
4382 ac_save_IFS=$IFS; IFS='-'
4383 set x $ac_cv_build
4384 shift
4385 build_cpu=$1
4386 build_vendor=$2
4387 shift; shift
4388 # Remember, the first character of IFS is used to create $*,
4389 # except with old shells:
4390 build_os=$*
4391 IFS=$ac_save_IFS
4392 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4396 $as_echo_n "checking host system type... " >&6; }
4397 if test "${ac_cv_host+set}" = set; then :
4398 $as_echo_n "(cached) " >&6
4399 else
4400 if test "x$host_alias" = x; then
4401 ac_cv_host=$ac_cv_build
4402 else
4403 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4404 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4409 $as_echo "$ac_cv_host" >&6; }
4410 case $ac_cv_host in
4411 *-*-*) ;;
4412 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4413 esac
4414 host=$ac_cv_host
4415 ac_save_IFS=$IFS; IFS='-'
4416 set x $ac_cv_host
4417 shift
4418 host_cpu=$1
4419 host_vendor=$2
4420 shift; shift
4421 # Remember, the first character of IFS is used to create $*,
4422 # except with old shells:
4423 host_os=$*
4424 IFS=$ac_save_IFS
4425 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4428 canonical=$host
4429 configuration=${host_alias-${build_alias-$host}}
4433 ### If you add support for a new configuration, add code to this
4434 ### switch statement to recognize your configuration name and select
4435 ### the appropriate operating system file.
4437 ### You would hope that you could choose an s/*.h
4438 ### file based on the operating system portion. However, it turns out
4439 ### that each s/*.h file is pretty manufacturer-specific.
4440 ### So we basically have to have a special case for each
4441 ### configuration name.
4443 ### As far as handling version numbers on operating systems is
4444 ### concerned, make sure things will fail in a fixable way. If
4445 ### /etc/MACHINES doesn't say anything about version numbers, be
4446 ### prepared to handle anything reasonably. If version numbers
4447 ### matter, be sure /etc/MACHINES says something about it.
4449 opsys='' unported=no
4450 case "${canonical}" in
4452 ## GNU/Linux and similar ports
4453 *-*-linux* )
4454 opsys=gnu-linux
4457 ## FreeBSD ports
4458 *-*-freebsd* )
4459 opsys=freebsd
4462 ## FreeBSD kernel + glibc based userland
4463 *-*-kfreebsd*gnu* )
4464 opsys=gnu-kfreebsd
4467 ## NetBSD ports
4468 *-*-netbsd* )
4469 opsys=netbsd
4472 ## OpenBSD ports
4473 *-*-openbsd* )
4474 opsys=openbsd
4477 ## Apple Darwin / Mac OS X
4478 *-apple-darwin* )
4479 case "${canonical}" in
4480 i[3456]86-* ) ;;
4481 powerpc-* ) ;;
4482 x86_64-* ) ;;
4483 * ) unported=yes ;;
4484 esac
4485 opsys=darwin
4486 ## Use fink packages if available.
4487 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4488 ## if test -d /sw/include && test -d /sw/lib; then
4489 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4490 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4491 ## fi
4494 ## HP 9000 series 700 and 800, running HP/UX
4495 hppa*-hp-hpux10.2* )
4496 opsys=hpux10-20
4498 hppa*-hp-hpux1[1-9]* )
4499 opsys=hpux11
4500 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4503 ## IBM machines
4504 rs6000-ibm-aix4.[23]* )
4505 opsys=aix4-2
4507 powerpc-ibm-aix4.[23]* )
4508 opsys=aix4-2
4510 rs6000-ibm-aix[56]* )
4511 opsys=aix4-2
4513 powerpc-ibm-aix[56]* )
4514 opsys=aix4-2
4517 ## Silicon Graphics machines
4518 ## Iris 4D
4519 mips-sgi-irix6.5 )
4520 opsys=irix6-5
4521 # Without defining _LANGUAGE_C, things get masked out in the headers
4522 # so that, for instance, grepping for `free' in stdlib.h fails and
4523 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4524 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4527 ## Suns
4528 *-sun-solaris* \
4529 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4530 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4531 case "${canonical}" in
4532 i[3456]86-*-* ) ;;
4533 amd64-*-*|x86_64-*-*) ;;
4534 sparc* ) ;;
4535 * ) unported=yes ;;
4536 esac
4537 case "${canonical}" in
4538 *-sunos5.6* | *-solaris2.6* )
4539 opsys=sol2-6
4540 RANLIB="ar -ts"
4542 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4543 opsys=sol2-6
4544 emacs_check_sunpro_c=yes
4546 *-sunos5* | *-solaris* )
4547 opsys=sol2-10
4548 emacs_check_sunpro_c=yes
4550 esac
4551 ## Watch out for a compiler that we know will not work.
4552 case "${canonical}" in
4553 *-solaris* | *-sunos5* )
4554 if [ "x$CC" = x/usr/ucb/cc ]; then
4555 ## /usr/ucb/cc doesn't work;
4556 ## we should find some other compiler that does work.
4557 unset CC
4560 *) ;;
4561 esac
4564 ## Intel 386 machines where we don't care about the manufacturer.
4565 i[3456]86-*-* )
4566 case "${canonical}" in
4567 *-cygwin ) opsys=cygwin ;;
4568 *-darwin* ) opsys=darwin ;;
4569 *-sysv4.2uw* ) opsys=unixware ;;
4570 *-sysv5uw* ) opsys=unixware ;;
4571 *-sysv5OpenUNIX* ) opsys=unixware ;;
4572 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4573 esac
4577 unported=yes
4579 esac
4581 ### If the code above didn't choose an operating system, just choose
4582 ### an operating system based on the configuration name. You really
4583 ### only want to use this when you have no idea what the right
4584 ### operating system is; if you know what operating systems a machine
4585 ### runs, it's cleaner to make it explicit in the case statement
4586 ### above.
4587 if test x"${opsys}" = x; then
4588 case "${canonical}" in
4589 *-gnu* ) opsys=gnu ;;
4591 unported=yes
4593 esac
4598 if test $unported = yes; then
4599 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4600 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4604 #### Choose a compiler.
4606 ac_ext=c
4607 ac_cpp='$CPP $CPPFLAGS'
4608 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4609 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4610 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4611 if test -n "$ac_tool_prefix"; then
4612 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4613 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4615 $as_echo_n "checking for $ac_word... " >&6; }
4616 if test "${ac_cv_prog_CC+set}" = set; then :
4617 $as_echo_n "(cached) " >&6
4618 else
4619 if test -n "$CC"; then
4620 ac_cv_prog_CC="$CC" # Let the user override the test.
4621 else
4622 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4623 for as_dir in $PATH
4625 IFS=$as_save_IFS
4626 test -z "$as_dir" && as_dir=.
4627 for ac_exec_ext in '' $ac_executable_extensions; do
4628 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4629 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4630 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4631 break 2
4633 done
4634 done
4635 IFS=$as_save_IFS
4639 CC=$ac_cv_prog_CC
4640 if test -n "$CC"; then
4641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4642 $as_echo "$CC" >&6; }
4643 else
4644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4645 $as_echo "no" >&6; }
4650 if test -z "$ac_cv_prog_CC"; then
4651 ac_ct_CC=$CC
4652 # Extract the first word of "gcc", so it can be a program name with args.
4653 set dummy gcc; ac_word=$2
4654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4655 $as_echo_n "checking for $ac_word... " >&6; }
4656 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4657 $as_echo_n "(cached) " >&6
4658 else
4659 if test -n "$ac_ct_CC"; then
4660 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4661 else
4662 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4663 for as_dir in $PATH
4665 IFS=$as_save_IFS
4666 test -z "$as_dir" && as_dir=.
4667 for ac_exec_ext in '' $ac_executable_extensions; do
4668 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4669 ac_cv_prog_ac_ct_CC="gcc"
4670 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4671 break 2
4673 done
4674 done
4675 IFS=$as_save_IFS
4679 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4680 if test -n "$ac_ct_CC"; then
4681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4682 $as_echo "$ac_ct_CC" >&6; }
4683 else
4684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4685 $as_echo "no" >&6; }
4688 if test "x$ac_ct_CC" = x; then
4689 CC=""
4690 else
4691 case $cross_compiling:$ac_tool_warned in
4692 yes:)
4693 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4694 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4695 ac_tool_warned=yes ;;
4696 esac
4697 CC=$ac_ct_CC
4699 else
4700 CC="$ac_cv_prog_CC"
4703 if test -z "$CC"; then
4704 if test -n "$ac_tool_prefix"; then
4705 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4706 set dummy ${ac_tool_prefix}cc; ac_word=$2
4707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4708 $as_echo_n "checking for $ac_word... " >&6; }
4709 if test "${ac_cv_prog_CC+set}" = set; then :
4710 $as_echo_n "(cached) " >&6
4711 else
4712 if test -n "$CC"; then
4713 ac_cv_prog_CC="$CC" # Let the user override the test.
4714 else
4715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4716 for as_dir in $PATH
4718 IFS=$as_save_IFS
4719 test -z "$as_dir" && as_dir=.
4720 for ac_exec_ext in '' $ac_executable_extensions; do
4721 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4722 ac_cv_prog_CC="${ac_tool_prefix}cc"
4723 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4724 break 2
4726 done
4727 done
4728 IFS=$as_save_IFS
4732 CC=$ac_cv_prog_CC
4733 if test -n "$CC"; then
4734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4735 $as_echo "$CC" >&6; }
4736 else
4737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4738 $as_echo "no" >&6; }
4744 if test -z "$CC"; then
4745 # Extract the first word of "cc", so it can be a program name with args.
4746 set dummy cc; ac_word=$2
4747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4748 $as_echo_n "checking for $ac_word... " >&6; }
4749 if test "${ac_cv_prog_CC+set}" = set; then :
4750 $as_echo_n "(cached) " >&6
4751 else
4752 if test -n "$CC"; then
4753 ac_cv_prog_CC="$CC" # Let the user override the test.
4754 else
4755 ac_prog_rejected=no
4756 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4757 for as_dir in $PATH
4759 IFS=$as_save_IFS
4760 test -z "$as_dir" && as_dir=.
4761 for ac_exec_ext in '' $ac_executable_extensions; do
4762 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4763 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4764 ac_prog_rejected=yes
4765 continue
4767 ac_cv_prog_CC="cc"
4768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4769 break 2
4771 done
4772 done
4773 IFS=$as_save_IFS
4775 if test $ac_prog_rejected = yes; then
4776 # We found a bogon in the path, so make sure we never use it.
4777 set dummy $ac_cv_prog_CC
4778 shift
4779 if test $# != 0; then
4780 # We chose a different compiler from the bogus one.
4781 # However, it has the same basename, so the bogon will be chosen
4782 # first if we set CC to just the basename; use the full file name.
4783 shift
4784 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4789 CC=$ac_cv_prog_CC
4790 if test -n "$CC"; then
4791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4792 $as_echo "$CC" >&6; }
4793 else
4794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4795 $as_echo "no" >&6; }
4800 if test -z "$CC"; then
4801 if test -n "$ac_tool_prefix"; then
4802 for ac_prog in cl.exe
4804 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4805 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4807 $as_echo_n "checking for $ac_word... " >&6; }
4808 if test "${ac_cv_prog_CC+set}" = set; then :
4809 $as_echo_n "(cached) " >&6
4810 else
4811 if test -n "$CC"; then
4812 ac_cv_prog_CC="$CC" # Let the user override the test.
4813 else
4814 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4815 for as_dir in $PATH
4817 IFS=$as_save_IFS
4818 test -z "$as_dir" && as_dir=.
4819 for ac_exec_ext in '' $ac_executable_extensions; do
4820 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4821 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4822 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4823 break 2
4825 done
4826 done
4827 IFS=$as_save_IFS
4831 CC=$ac_cv_prog_CC
4832 if test -n "$CC"; then
4833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4834 $as_echo "$CC" >&6; }
4835 else
4836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4837 $as_echo "no" >&6; }
4841 test -n "$CC" && break
4842 done
4844 if test -z "$CC"; then
4845 ac_ct_CC=$CC
4846 for ac_prog in cl.exe
4848 # Extract the first word of "$ac_prog", so it can be a program name with args.
4849 set dummy $ac_prog; ac_word=$2
4850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4851 $as_echo_n "checking for $ac_word... " >&6; }
4852 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4853 $as_echo_n "(cached) " >&6
4854 else
4855 if test -n "$ac_ct_CC"; then
4856 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4857 else
4858 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4859 for as_dir in $PATH
4861 IFS=$as_save_IFS
4862 test -z "$as_dir" && as_dir=.
4863 for ac_exec_ext in '' $ac_executable_extensions; do
4864 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4865 ac_cv_prog_ac_ct_CC="$ac_prog"
4866 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4867 break 2
4869 done
4870 done
4871 IFS=$as_save_IFS
4875 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4876 if test -n "$ac_ct_CC"; then
4877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4878 $as_echo "$ac_ct_CC" >&6; }
4879 else
4880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4881 $as_echo "no" >&6; }
4885 test -n "$ac_ct_CC" && break
4886 done
4888 if test "x$ac_ct_CC" = x; then
4889 CC=""
4890 else
4891 case $cross_compiling:$ac_tool_warned in
4892 yes:)
4893 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4894 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4895 ac_tool_warned=yes ;;
4896 esac
4897 CC=$ac_ct_CC
4904 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4905 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4906 as_fn_error "no acceptable C compiler found in \$PATH
4907 See \`config.log' for more details." "$LINENO" 5; }
4909 # Provide some information about the compiler.
4910 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4911 set X $ac_compile
4912 ac_compiler=$2
4913 for ac_option in --version -v -V -qversion; do
4914 { { ac_try="$ac_compiler $ac_option >&5"
4915 case "(($ac_try" in
4916 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4917 *) ac_try_echo=$ac_try;;
4918 esac
4919 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4920 $as_echo "$ac_try_echo"; } >&5
4921 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4922 ac_status=$?
4923 if test -s conftest.err; then
4924 sed '10a\
4925 ... rest of stderr output deleted ...
4926 10q' conftest.err >conftest.er1
4927 cat conftest.er1 >&5
4929 rm -f conftest.er1 conftest.err
4930 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4931 test $ac_status = 0; }
4932 done
4934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4935 /* end confdefs.h. */
4938 main ()
4942 return 0;
4944 _ACEOF
4945 ac_clean_files_save=$ac_clean_files
4946 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4947 # Try to create an executable without -o first, disregard a.out.
4948 # It will help us diagnose broken compilers, and finding out an intuition
4949 # of exeext.
4950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4951 $as_echo_n "checking whether the C compiler works... " >&6; }
4952 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4954 # The possible output files:
4955 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4957 ac_rmfiles=
4958 for ac_file in $ac_files
4960 case $ac_file in
4961 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4962 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4963 esac
4964 done
4965 rm -f $ac_rmfiles
4967 if { { ac_try="$ac_link_default"
4968 case "(($ac_try" in
4969 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4970 *) ac_try_echo=$ac_try;;
4971 esac
4972 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4973 $as_echo "$ac_try_echo"; } >&5
4974 (eval "$ac_link_default") 2>&5
4975 ac_status=$?
4976 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4977 test $ac_status = 0; }; then :
4978 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4979 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4980 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4981 # so that the user can short-circuit this test for compilers unknown to
4982 # Autoconf.
4983 for ac_file in $ac_files ''
4985 test -f "$ac_file" || continue
4986 case $ac_file in
4987 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4989 [ab].out )
4990 # We found the default executable, but exeext='' is most
4991 # certainly right.
4992 break;;
4993 *.* )
4994 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4995 then :; else
4996 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4998 # We set ac_cv_exeext here because the later test for it is not
4999 # safe: cross compilers may not add the suffix if given an `-o'
5000 # argument, so we may need to know it at that point already.
5001 # Even if this section looks crufty: it has the advantage of
5002 # actually working.
5003 break;;
5005 break;;
5006 esac
5007 done
5008 test "$ac_cv_exeext" = no && ac_cv_exeext=
5010 else
5011 ac_file=''
5013 if test -z "$ac_file"; then :
5014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5015 $as_echo "no" >&6; }
5016 $as_echo "$as_me: failed program was:" >&5
5017 sed 's/^/| /' conftest.$ac_ext >&5
5019 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5020 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5021 { as_fn_set_status 77
5022 as_fn_error "C compiler cannot create executables
5023 See \`config.log' for more details." "$LINENO" 5; }; }
5024 else
5025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5026 $as_echo "yes" >&6; }
5028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5029 $as_echo_n "checking for C compiler default output file name... " >&6; }
5030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5031 $as_echo "$ac_file" >&6; }
5032 ac_exeext=$ac_cv_exeext
5034 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5035 ac_clean_files=$ac_clean_files_save
5036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5037 $as_echo_n "checking for suffix of executables... " >&6; }
5038 if { { ac_try="$ac_link"
5039 case "(($ac_try" in
5040 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5041 *) ac_try_echo=$ac_try;;
5042 esac
5043 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5044 $as_echo "$ac_try_echo"; } >&5
5045 (eval "$ac_link") 2>&5
5046 ac_status=$?
5047 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5048 test $ac_status = 0; }; then :
5049 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5050 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5051 # work properly (i.e., refer to `conftest.exe'), while it won't with
5052 # `rm'.
5053 for ac_file in conftest.exe conftest conftest.*; do
5054 test -f "$ac_file" || continue
5055 case $ac_file in
5056 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5057 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5058 break;;
5059 * ) break;;
5060 esac
5061 done
5062 else
5063 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5064 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5065 as_fn_error "cannot compute suffix of executables: cannot compile and link
5066 See \`config.log' for more details." "$LINENO" 5; }
5068 rm -f conftest conftest$ac_cv_exeext
5069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5070 $as_echo "$ac_cv_exeext" >&6; }
5072 rm -f conftest.$ac_ext
5073 EXEEXT=$ac_cv_exeext
5074 ac_exeext=$EXEEXT
5075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5076 /* end confdefs.h. */
5077 #include <stdio.h>
5079 main ()
5081 FILE *f = fopen ("conftest.out", "w");
5082 return ferror (f) || fclose (f) != 0;
5085 return 0;
5087 _ACEOF
5088 ac_clean_files="$ac_clean_files conftest.out"
5089 # Check that the compiler produces executables we can run. If not, either
5090 # the compiler is broken, or we cross compile.
5091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5092 $as_echo_n "checking whether we are cross compiling... " >&6; }
5093 if test "$cross_compiling" != yes; then
5094 { { ac_try="$ac_link"
5095 case "(($ac_try" in
5096 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5097 *) ac_try_echo=$ac_try;;
5098 esac
5099 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5100 $as_echo "$ac_try_echo"; } >&5
5101 (eval "$ac_link") 2>&5
5102 ac_status=$?
5103 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5104 test $ac_status = 0; }
5105 if { ac_try='./conftest$ac_cv_exeext'
5106 { { case "(($ac_try" in
5107 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5108 *) ac_try_echo=$ac_try;;
5109 esac
5110 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5111 $as_echo "$ac_try_echo"; } >&5
5112 (eval "$ac_try") 2>&5
5113 ac_status=$?
5114 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5115 test $ac_status = 0; }; }; then
5116 cross_compiling=no
5117 else
5118 if test "$cross_compiling" = maybe; then
5119 cross_compiling=yes
5120 else
5121 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5122 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5123 as_fn_error "cannot run C compiled programs.
5124 If you meant to cross compile, use \`--host'.
5125 See \`config.log' for more details." "$LINENO" 5; }
5129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5130 $as_echo "$cross_compiling" >&6; }
5132 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5133 ac_clean_files=$ac_clean_files_save
5134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5135 $as_echo_n "checking for suffix of object files... " >&6; }
5136 if test "${ac_cv_objext+set}" = set; then :
5137 $as_echo_n "(cached) " >&6
5138 else
5139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5140 /* end confdefs.h. */
5143 main ()
5147 return 0;
5149 _ACEOF
5150 rm -f conftest.o conftest.obj
5151 if { { ac_try="$ac_compile"
5152 case "(($ac_try" in
5153 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5154 *) ac_try_echo=$ac_try;;
5155 esac
5156 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5157 $as_echo "$ac_try_echo"; } >&5
5158 (eval "$ac_compile") 2>&5
5159 ac_status=$?
5160 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5161 test $ac_status = 0; }; then :
5162 for ac_file in conftest.o conftest.obj conftest.*; do
5163 test -f "$ac_file" || continue;
5164 case $ac_file in
5165 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5166 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5167 break;;
5168 esac
5169 done
5170 else
5171 $as_echo "$as_me: failed program was:" >&5
5172 sed 's/^/| /' conftest.$ac_ext >&5
5174 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5175 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5176 as_fn_error "cannot compute suffix of object files: cannot compile
5177 See \`config.log' for more details." "$LINENO" 5; }
5179 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5182 $as_echo "$ac_cv_objext" >&6; }
5183 OBJEXT=$ac_cv_objext
5184 ac_objext=$OBJEXT
5185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5186 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5187 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5188 $as_echo_n "(cached) " >&6
5189 else
5190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5191 /* end confdefs.h. */
5194 main ()
5196 #ifndef __GNUC__
5197 choke me
5198 #endif
5201 return 0;
5203 _ACEOF
5204 if ac_fn_c_try_compile "$LINENO"; then :
5205 ac_compiler_gnu=yes
5206 else
5207 ac_compiler_gnu=no
5209 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5210 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5214 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5215 if test $ac_compiler_gnu = yes; then
5216 GCC=yes
5217 else
5218 GCC=
5220 ac_test_CFLAGS=${CFLAGS+set}
5221 ac_save_CFLAGS=$CFLAGS
5222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5223 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5224 if test "${ac_cv_prog_cc_g+set}" = set; then :
5225 $as_echo_n "(cached) " >&6
5226 else
5227 ac_save_c_werror_flag=$ac_c_werror_flag
5228 ac_c_werror_flag=yes
5229 ac_cv_prog_cc_g=no
5230 CFLAGS="-g"
5231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5232 /* end confdefs.h. */
5235 main ()
5239 return 0;
5241 _ACEOF
5242 if ac_fn_c_try_compile "$LINENO"; then :
5243 ac_cv_prog_cc_g=yes
5244 else
5245 CFLAGS=""
5246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5247 /* end confdefs.h. */
5250 main ()
5254 return 0;
5256 _ACEOF
5257 if ac_fn_c_try_compile "$LINENO"; then :
5259 else
5260 ac_c_werror_flag=$ac_save_c_werror_flag
5261 CFLAGS="-g"
5262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5263 /* end confdefs.h. */
5266 main ()
5270 return 0;
5272 _ACEOF
5273 if ac_fn_c_try_compile "$LINENO"; then :
5274 ac_cv_prog_cc_g=yes
5276 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5278 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5280 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5281 ac_c_werror_flag=$ac_save_c_werror_flag
5283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5284 $as_echo "$ac_cv_prog_cc_g" >&6; }
5285 if test "$ac_test_CFLAGS" = set; then
5286 CFLAGS=$ac_save_CFLAGS
5287 elif test $ac_cv_prog_cc_g = yes; then
5288 if test "$GCC" = yes; then
5289 CFLAGS="-g -O2"
5290 else
5291 CFLAGS="-g"
5293 else
5294 if test "$GCC" = yes; then
5295 CFLAGS="-O2"
5296 else
5297 CFLAGS=
5300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5301 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5302 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5303 $as_echo_n "(cached) " >&6
5304 else
5305 ac_cv_prog_cc_c89=no
5306 ac_save_CC=$CC
5307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5308 /* end confdefs.h. */
5309 #include <stdarg.h>
5310 #include <stdio.h>
5311 #include <sys/types.h>
5312 #include <sys/stat.h>
5313 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5314 struct buf { int x; };
5315 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5316 static char *e (p, i)
5317 char **p;
5318 int i;
5320 return p[i];
5322 static char *f (char * (*g) (char **, int), char **p, ...)
5324 char *s;
5325 va_list v;
5326 va_start (v,p);
5327 s = g (p, va_arg (v,int));
5328 va_end (v);
5329 return s;
5332 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5333 function prototypes and stuff, but not '\xHH' hex character constants.
5334 These don't provoke an error unfortunately, instead are silently treated
5335 as 'x'. The following induces an error, until -std is added to get
5336 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5337 array size at least. It's necessary to write '\x00'==0 to get something
5338 that's true only with -std. */
5339 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5341 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5342 inside strings and character constants. */
5343 #define FOO(x) 'x'
5344 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5346 int test (int i, double x);
5347 struct s1 {int (*f) (int a);};
5348 struct s2 {int (*f) (double a);};
5349 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5350 int argc;
5351 char **argv;
5353 main ()
5355 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5357 return 0;
5359 _ACEOF
5360 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5361 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5363 CC="$ac_save_CC $ac_arg"
5364 if ac_fn_c_try_compile "$LINENO"; then :
5365 ac_cv_prog_cc_c89=$ac_arg
5367 rm -f core conftest.err conftest.$ac_objext
5368 test "x$ac_cv_prog_cc_c89" != "xno" && break
5369 done
5370 rm -f conftest.$ac_ext
5371 CC=$ac_save_CC
5374 # AC_CACHE_VAL
5375 case "x$ac_cv_prog_cc_c89" in
5377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5378 $as_echo "none needed" >&6; } ;;
5379 xno)
5380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5381 $as_echo "unsupported" >&6; } ;;
5383 CC="$CC $ac_cv_prog_cc_c89"
5384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5385 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5386 esac
5387 if test "x$ac_cv_prog_cc_c89" != xno; then :
5391 ac_ext=c
5392 ac_cpp='$CPP $CPPFLAGS'
5393 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5394 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5395 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5396 DEPDIR="${am__leading_dot}deps"
5398 ac_config_commands="$ac_config_commands depfiles"
5401 am_make=${MAKE-make}
5402 cat > confinc << 'END'
5403 am__doit:
5404 @echo this is the am__doit target
5405 .PHONY: am__doit
5407 # If we don't find an include directive, just comment out the code.
5408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5409 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5410 am__include="#"
5411 am__quote=
5412 _am_result=none
5413 # First try GNU make style include.
5414 echo "include confinc" > confmf
5415 # Ignore all kinds of additional output from `make'.
5416 case `$am_make -s -f confmf 2> /dev/null` in #(
5417 *the\ am__doit\ target*)
5418 am__include=include
5419 am__quote=
5420 _am_result=GNU
5422 esac
5423 # Now try BSD make style include.
5424 if test "$am__include" = "#"; then
5425 echo '.include "confinc"' > confmf
5426 case `$am_make -s -f confmf 2> /dev/null` in #(
5427 *the\ am__doit\ target*)
5428 am__include=.include
5429 am__quote="\""
5430 _am_result=BSD
5432 esac
5436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5437 $as_echo "$_am_result" >&6; }
5438 rm -f confinc confmf
5440 # Check whether --enable-dependency-tracking was given.
5441 if test "${enable_dependency_tracking+set}" = set; then :
5442 enableval=$enable_dependency_tracking;
5445 if test "x$enable_dependency_tracking" != xno; then
5446 am_depcomp="$ac_aux_dir/depcomp"
5447 AMDEPBACKSLASH='\'
5449 if test "x$enable_dependency_tracking" != xno; then
5450 AMDEP_TRUE=
5451 AMDEP_FALSE='#'
5452 else
5453 AMDEP_TRUE='#'
5454 AMDEP_FALSE=
5459 depcc="$CC" am_compiler_list=
5461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5462 $as_echo_n "checking dependency style of $depcc... " >&6; }
5463 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5464 $as_echo_n "(cached) " >&6
5465 else
5466 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5467 # We make a subdir and do the tests there. Otherwise we can end up
5468 # making bogus files that we don't know about and never remove. For
5469 # instance it was reported that on HP-UX the gcc test will end up
5470 # making a dummy file named `D' -- because `-MD' means `put the output
5471 # in D'.
5472 mkdir conftest.dir
5473 # Copy depcomp to subdir because otherwise we won't find it if we're
5474 # using a relative directory.
5475 cp "$am_depcomp" conftest.dir
5476 cd conftest.dir
5477 # We will build objects and dependencies in a subdirectory because
5478 # it helps to detect inapplicable dependency modes. For instance
5479 # both Tru64's cc and ICC support -MD to output dependencies as a
5480 # side effect of compilation, but ICC will put the dependencies in
5481 # the current directory while Tru64 will put them in the object
5482 # directory.
5483 mkdir sub
5485 am_cv_CC_dependencies_compiler_type=none
5486 if test "$am_compiler_list" = ""; then
5487 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5489 am__universal=false
5490 case " $depcc " in #(
5491 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5492 esac
5494 for depmode in $am_compiler_list; do
5495 # Setup a source with many dependencies, because some compilers
5496 # like to wrap large dependency lists on column 80 (with \), and
5497 # we should not choose a depcomp mode which is confused by this.
5499 # We need to recreate these files for each test, as the compiler may
5500 # overwrite some of them when testing with obscure command lines.
5501 # This happens at least with the AIX C compiler.
5502 : > sub/conftest.c
5503 for i in 1 2 3 4 5 6; do
5504 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5505 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5506 # Solaris 8's {/usr,}/bin/sh.
5507 touch sub/conftst$i.h
5508 done
5509 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5511 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5512 # mode. It turns out that the SunPro C++ compiler does not properly
5513 # handle `-M -o', and we need to detect this. Also, some Intel
5514 # versions had trouble with output in subdirs
5515 am__obj=sub/conftest.${OBJEXT-o}
5516 am__minus_obj="-o $am__obj"
5517 case $depmode in
5518 gcc)
5519 # This depmode causes a compiler race in universal mode.
5520 test "$am__universal" = false || continue
5522 nosideeffect)
5523 # after this tag, mechanisms are not by side-effect, so they'll
5524 # only be used when explicitly requested
5525 if test "x$enable_dependency_tracking" = xyes; then
5526 continue
5527 else
5528 break
5531 msvisualcpp | msvcmsys)
5532 # This compiler won't grok `-c -o', but also, the minuso test has
5533 # not run yet. These depmodes are late enough in the game, and
5534 # so weak that their functioning should not be impacted.
5535 am__obj=conftest.${OBJEXT-o}
5536 am__minus_obj=
5538 none) break ;;
5539 esac
5540 if depmode=$depmode \
5541 source=sub/conftest.c object=$am__obj \
5542 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5543 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5544 >/dev/null 2>conftest.err &&
5545 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5546 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5547 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5548 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5549 # icc doesn't choke on unknown options, it will just issue warnings
5550 # or remarks (even with -Werror). So we grep stderr for any message
5551 # that says an option was ignored or not supported.
5552 # When given -MP, icc 7.0 and 7.1 complain thusly:
5553 # icc: Command line warning: ignoring option '-M'; no argument required
5554 # The diagnosis changed in icc 8.0:
5555 # icc: Command line remark: option '-MP' not supported
5556 if (grep 'ignoring option' conftest.err ||
5557 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5558 am_cv_CC_dependencies_compiler_type=$depmode
5559 break
5562 done
5564 cd ..
5565 rm -rf conftest.dir
5566 else
5567 am_cv_CC_dependencies_compiler_type=none
5571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5572 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5573 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5576 test "x$enable_dependency_tracking" != xno \
5577 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5578 am__fastdepCC_TRUE=
5579 am__fastdepCC_FALSE='#'
5580 else
5581 am__fastdepCC_TRUE='#'
5582 am__fastdepCC_FALSE=
5586 if test "x$CC" != xcc; then
5587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5588 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5589 else
5590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5591 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5593 set dummy $CC; ac_cc=`$as_echo "$2" |
5594 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5595 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5596 $as_echo_n "(cached) " >&6
5597 else
5598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5599 /* end confdefs.h. */
5602 main ()
5606 return 0;
5608 _ACEOF
5609 # Make sure it works both with $CC and with simple cc.
5610 # We do the test twice because some compilers refuse to overwrite an
5611 # existing .o file with -o, though they will create one.
5612 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5613 rm -f conftest2.*
5614 if { { case "(($ac_try" in
5615 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5616 *) ac_try_echo=$ac_try;;
5617 esac
5618 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5619 $as_echo "$ac_try_echo"; } >&5
5620 (eval "$ac_try") 2>&5
5621 ac_status=$?
5622 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5623 test $ac_status = 0; } &&
5624 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5625 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5626 *) ac_try_echo=$ac_try;;
5627 esac
5628 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5629 $as_echo "$ac_try_echo"; } >&5
5630 (eval "$ac_try") 2>&5
5631 ac_status=$?
5632 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5633 test $ac_status = 0; };
5634 then
5635 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5636 if test "x$CC" != xcc; then
5637 # Test first that cc exists at all.
5638 if { ac_try='cc -c conftest.$ac_ext >&5'
5639 { { case "(($ac_try" in
5640 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5641 *) ac_try_echo=$ac_try;;
5642 esac
5643 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5644 $as_echo "$ac_try_echo"; } >&5
5645 (eval "$ac_try") 2>&5
5646 ac_status=$?
5647 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5648 test $ac_status = 0; }; }; then
5649 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5650 rm -f conftest2.*
5651 if { { case "(($ac_try" in
5652 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5653 *) ac_try_echo=$ac_try;;
5654 esac
5655 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5656 $as_echo "$ac_try_echo"; } >&5
5657 (eval "$ac_try") 2>&5
5658 ac_status=$?
5659 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5660 test $ac_status = 0; } &&
5661 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5662 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5663 *) ac_try_echo=$ac_try;;
5664 esac
5665 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5666 $as_echo "$ac_try_echo"; } >&5
5667 (eval "$ac_try") 2>&5
5668 ac_status=$?
5669 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5670 test $ac_status = 0; };
5671 then
5672 # cc works too.
5674 else
5675 # cc exists but doesn't like -o.
5676 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5680 else
5681 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5683 rm -f core conftest*
5686 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5688 $as_echo "yes" >&6; }
5689 else
5690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5691 $as_echo "no" >&6; }
5693 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5697 # FIXME: we rely on the cache variable name because
5698 # there is no other way.
5699 set dummy $CC
5700 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5701 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5702 if test "$am_t" != yes; then
5703 # Losing compiler, so override with the script.
5704 # FIXME: It is wrong to rewrite CC.
5705 # But if we don't then we get into trouble of one sort or another.
5706 # A longer-term fix would be to have automake use am__CC in this case,
5707 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5708 CC="$am_aux_dir/compile $CC"
5713 if test x$GCC = xyes; then
5714 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5715 else
5716 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5719 # Initialize gnulib right after choosing the compiler.
5721 ac_ext=c
5722 ac_cpp='$CPP $CPPFLAGS'
5723 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5724 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5725 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5727 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5728 # On Suns, sometimes $CPP names a directory.
5729 if test -n "$CPP" && test -d "$CPP"; then
5730 CPP=
5732 if test -z "$CPP"; then
5733 if test "${ac_cv_prog_CPP+set}" = set; then :
5734 $as_echo_n "(cached) " >&6
5735 else
5736 # Double quotes because CPP needs to be expanded
5737 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5739 ac_preproc_ok=false
5740 for ac_c_preproc_warn_flag in '' yes
5742 # Use a header file that comes with gcc, so configuring glibc
5743 # with a fresh cross-compiler works.
5744 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5745 # <limits.h> exists even on freestanding compilers.
5746 # On the NeXT, cc -E runs the code through the compiler's parser,
5747 # not just through cpp. "Syntax error" is here to catch this case.
5748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5749 /* end confdefs.h. */
5750 #ifdef __STDC__
5751 # include <limits.h>
5752 #else
5753 # include <assert.h>
5754 #endif
5755 Syntax error
5756 _ACEOF
5757 if ac_fn_c_try_cpp "$LINENO"; then :
5759 else
5760 # Broken: fails on valid input.
5761 continue
5763 rm -f conftest.err conftest.$ac_ext
5765 # OK, works on sane cases. Now check whether nonexistent headers
5766 # can be detected and how.
5767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5768 /* end confdefs.h. */
5769 #include <ac_nonexistent.h>
5770 _ACEOF
5771 if ac_fn_c_try_cpp "$LINENO"; then :
5772 # Broken: success on invalid input.
5773 continue
5774 else
5775 # Passes both tests.
5776 ac_preproc_ok=:
5777 break
5779 rm -f conftest.err conftest.$ac_ext
5781 done
5782 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5783 rm -f conftest.err conftest.$ac_ext
5784 if $ac_preproc_ok; then :
5785 break
5788 done
5789 ac_cv_prog_CPP=$CPP
5792 CPP=$ac_cv_prog_CPP
5793 else
5794 ac_cv_prog_CPP=$CPP
5796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5797 $as_echo "$CPP" >&6; }
5798 ac_preproc_ok=false
5799 for ac_c_preproc_warn_flag in '' yes
5801 # Use a header file that comes with gcc, so configuring glibc
5802 # with a fresh cross-compiler works.
5803 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5804 # <limits.h> exists even on freestanding compilers.
5805 # On the NeXT, cc -E runs the code through the compiler's parser,
5806 # not just through cpp. "Syntax error" is here to catch this case.
5807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5808 /* end confdefs.h. */
5809 #ifdef __STDC__
5810 # include <limits.h>
5811 #else
5812 # include <assert.h>
5813 #endif
5814 Syntax error
5815 _ACEOF
5816 if ac_fn_c_try_cpp "$LINENO"; then :
5818 else
5819 # Broken: fails on valid input.
5820 continue
5822 rm -f conftest.err conftest.$ac_ext
5824 # OK, works on sane cases. Now check whether nonexistent headers
5825 # can be detected and how.
5826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5827 /* end confdefs.h. */
5828 #include <ac_nonexistent.h>
5829 _ACEOF
5830 if ac_fn_c_try_cpp "$LINENO"; then :
5831 # Broken: success on invalid input.
5832 continue
5833 else
5834 # Passes both tests.
5835 ac_preproc_ok=:
5836 break
5838 rm -f conftest.err conftest.$ac_ext
5840 done
5841 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5842 rm -f conftest.err conftest.$ac_ext
5843 if $ac_preproc_ok; then :
5845 else
5846 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5847 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5848 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5849 See \`config.log' for more details." "$LINENO" 5; }
5852 ac_ext=c
5853 ac_cpp='$CPP $CPPFLAGS'
5854 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5855 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5856 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5860 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5861 if test "${ac_cv_path_GREP+set}" = set; then :
5862 $as_echo_n "(cached) " >&6
5863 else
5864 if test -z "$GREP"; then
5865 ac_path_GREP_found=false
5866 # Loop through the user's path and test for each of PROGNAME-LIST
5867 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5868 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5870 IFS=$as_save_IFS
5871 test -z "$as_dir" && as_dir=.
5872 for ac_prog in grep ggrep; do
5873 for ac_exec_ext in '' $ac_executable_extensions; do
5874 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5875 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5876 # Check for GNU ac_path_GREP and select it if it is found.
5877 # Check for GNU $ac_path_GREP
5878 case `"$ac_path_GREP" --version 2>&1` in
5879 *GNU*)
5880 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5882 ac_count=0
5883 $as_echo_n 0123456789 >"conftest.in"
5884 while :
5886 cat "conftest.in" "conftest.in" >"conftest.tmp"
5887 mv "conftest.tmp" "conftest.in"
5888 cp "conftest.in" "conftest.nl"
5889 $as_echo 'GREP' >> "conftest.nl"
5890 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5891 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5892 as_fn_arith $ac_count + 1 && ac_count=$as_val
5893 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5894 # Best one so far, save it but keep looking for a better one
5895 ac_cv_path_GREP="$ac_path_GREP"
5896 ac_path_GREP_max=$ac_count
5898 # 10*(2^10) chars as input seems more than enough
5899 test $ac_count -gt 10 && break
5900 done
5901 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5902 esac
5904 $ac_path_GREP_found && break 3
5905 done
5906 done
5907 done
5908 IFS=$as_save_IFS
5909 if test -z "$ac_cv_path_GREP"; then
5910 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5912 else
5913 ac_cv_path_GREP=$GREP
5917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5918 $as_echo "$ac_cv_path_GREP" >&6; }
5919 GREP="$ac_cv_path_GREP"
5922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5923 $as_echo_n "checking for egrep... " >&6; }
5924 if test "${ac_cv_path_EGREP+set}" = set; then :
5925 $as_echo_n "(cached) " >&6
5926 else
5927 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5928 then ac_cv_path_EGREP="$GREP -E"
5929 else
5930 if test -z "$EGREP"; then
5931 ac_path_EGREP_found=false
5932 # Loop through the user's path and test for each of PROGNAME-LIST
5933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5934 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5936 IFS=$as_save_IFS
5937 test -z "$as_dir" && as_dir=.
5938 for ac_prog in egrep; do
5939 for ac_exec_ext in '' $ac_executable_extensions; do
5940 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5941 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5942 # Check for GNU ac_path_EGREP and select it if it is found.
5943 # Check for GNU $ac_path_EGREP
5944 case `"$ac_path_EGREP" --version 2>&1` in
5945 *GNU*)
5946 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5948 ac_count=0
5949 $as_echo_n 0123456789 >"conftest.in"
5950 while :
5952 cat "conftest.in" "conftest.in" >"conftest.tmp"
5953 mv "conftest.tmp" "conftest.in"
5954 cp "conftest.in" "conftest.nl"
5955 $as_echo 'EGREP' >> "conftest.nl"
5956 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5957 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5958 as_fn_arith $ac_count + 1 && ac_count=$as_val
5959 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5960 # Best one so far, save it but keep looking for a better one
5961 ac_cv_path_EGREP="$ac_path_EGREP"
5962 ac_path_EGREP_max=$ac_count
5964 # 10*(2^10) chars as input seems more than enough
5965 test $ac_count -gt 10 && break
5966 done
5967 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5968 esac
5970 $ac_path_EGREP_found && break 3
5971 done
5972 done
5973 done
5974 IFS=$as_save_IFS
5975 if test -z "$ac_cv_path_EGREP"; then
5976 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5978 else
5979 ac_cv_path_EGREP=$EGREP
5984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5985 $as_echo "$ac_cv_path_EGREP" >&6; }
5986 EGREP="$ac_cv_path_EGREP"
5991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5992 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
5993 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
5994 $as_echo_n "(cached) " >&6
5995 else
5997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5998 /* end confdefs.h. */
6000 #ifdef __ACK__
6001 Amsterdam
6002 #endif
6004 _ACEOF
6005 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6006 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6007 gl_cv_c_amsterdam_compiler=yes
6008 else
6009 gl_cv_c_amsterdam_compiler=no
6011 rm -f conftest*
6015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6016 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6017 if test -z "$AR"; then
6018 if test $gl_cv_c_amsterdam_compiler = yes; then
6019 AR='cc -c.a'
6020 if test -z "$ARFLAGS"; then
6021 ARFLAGS='-o'
6023 else
6024 if test -n "$ac_tool_prefix"; then
6025 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6026 set dummy ${ac_tool_prefix}ar; ac_word=$2
6027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6028 $as_echo_n "checking for $ac_word... " >&6; }
6029 if test "${ac_cv_prog_AR+set}" = set; then :
6030 $as_echo_n "(cached) " >&6
6031 else
6032 if test -n "$AR"; then
6033 ac_cv_prog_AR="$AR" # Let the user override the test.
6034 else
6035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6036 for as_dir in $PATH
6038 IFS=$as_save_IFS
6039 test -z "$as_dir" && as_dir=.
6040 for ac_exec_ext in '' $ac_executable_extensions; do
6041 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6042 ac_cv_prog_AR="${ac_tool_prefix}ar"
6043 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6044 break 2
6046 done
6047 done
6048 IFS=$as_save_IFS
6052 AR=$ac_cv_prog_AR
6053 if test -n "$AR"; then
6054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6055 $as_echo "$AR" >&6; }
6056 else
6057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6058 $as_echo "no" >&6; }
6063 if test -z "$ac_cv_prog_AR"; then
6064 ac_ct_AR=$AR
6065 # Extract the first word of "ar", so it can be a program name with args.
6066 set dummy ar; ac_word=$2
6067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6068 $as_echo_n "checking for $ac_word... " >&6; }
6069 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6070 $as_echo_n "(cached) " >&6
6071 else
6072 if test -n "$ac_ct_AR"; then
6073 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6074 else
6075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6076 for as_dir in $PATH
6078 IFS=$as_save_IFS
6079 test -z "$as_dir" && as_dir=.
6080 for ac_exec_ext in '' $ac_executable_extensions; do
6081 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6082 ac_cv_prog_ac_ct_AR="ar"
6083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6084 break 2
6086 done
6087 done
6088 IFS=$as_save_IFS
6092 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6093 if test -n "$ac_ct_AR"; then
6094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6095 $as_echo "$ac_ct_AR" >&6; }
6096 else
6097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6098 $as_echo "no" >&6; }
6101 if test "x$ac_ct_AR" = x; then
6102 AR="ar"
6103 else
6104 case $cross_compiling:$ac_tool_warned in
6105 yes:)
6106 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6107 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6108 ac_tool_warned=yes ;;
6109 esac
6110 AR=$ac_ct_AR
6112 else
6113 AR="$ac_cv_prog_AR"
6116 if test -z "$ARFLAGS"; then
6117 ARFLAGS='cru'
6120 else
6121 if test -z "$ARFLAGS"; then
6122 ARFLAGS='cru'
6127 if test -z "$RANLIB"; then
6128 if test $gl_cv_c_amsterdam_compiler = yes; then
6129 RANLIB=':'
6130 else
6131 if test -n "$ac_tool_prefix"; then
6132 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6133 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6135 $as_echo_n "checking for $ac_word... " >&6; }
6136 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6137 $as_echo_n "(cached) " >&6
6138 else
6139 if test -n "$RANLIB"; then
6140 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6141 else
6142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6143 for as_dir in $PATH
6145 IFS=$as_save_IFS
6146 test -z "$as_dir" && as_dir=.
6147 for ac_exec_ext in '' $ac_executable_extensions; do
6148 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6149 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6150 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6151 break 2
6153 done
6154 done
6155 IFS=$as_save_IFS
6159 RANLIB=$ac_cv_prog_RANLIB
6160 if test -n "$RANLIB"; then
6161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6162 $as_echo "$RANLIB" >&6; }
6163 else
6164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6165 $as_echo "no" >&6; }
6170 if test -z "$ac_cv_prog_RANLIB"; then
6171 ac_ct_RANLIB=$RANLIB
6172 # Extract the first word of "ranlib", so it can be a program name with args.
6173 set dummy ranlib; ac_word=$2
6174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6175 $as_echo_n "checking for $ac_word... " >&6; }
6176 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6177 $as_echo_n "(cached) " >&6
6178 else
6179 if test -n "$ac_ct_RANLIB"; then
6180 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6181 else
6182 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6183 for as_dir in $PATH
6185 IFS=$as_save_IFS
6186 test -z "$as_dir" && as_dir=.
6187 for ac_exec_ext in '' $ac_executable_extensions; do
6188 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6189 ac_cv_prog_ac_ct_RANLIB="ranlib"
6190 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6191 break 2
6193 done
6194 done
6195 IFS=$as_save_IFS
6199 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6200 if test -n "$ac_ct_RANLIB"; then
6201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6202 $as_echo "$ac_ct_RANLIB" >&6; }
6203 else
6204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6205 $as_echo "no" >&6; }
6208 if test "x$ac_ct_RANLIB" = x; then
6209 RANLIB=":"
6210 else
6211 case $cross_compiling:$ac_tool_warned in
6212 yes:)
6213 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6214 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6215 ac_tool_warned=yes ;;
6216 esac
6217 RANLIB=$ac_ct_RANLIB
6219 else
6220 RANLIB="$ac_cv_prog_RANLIB"
6227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6228 $as_echo_n "checking for ANSI C header files... " >&6; }
6229 if test "${ac_cv_header_stdc+set}" = set; then :
6230 $as_echo_n "(cached) " >&6
6231 else
6232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6233 /* end confdefs.h. */
6234 #include <stdlib.h>
6235 #include <stdarg.h>
6236 #include <string.h>
6237 #include <float.h>
6240 main ()
6244 return 0;
6246 _ACEOF
6247 if ac_fn_c_try_compile "$LINENO"; then :
6248 ac_cv_header_stdc=yes
6249 else
6250 ac_cv_header_stdc=no
6252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6254 if test $ac_cv_header_stdc = yes; then
6255 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6257 /* end confdefs.h. */
6258 #include <string.h>
6260 _ACEOF
6261 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6262 $EGREP "memchr" >/dev/null 2>&1; then :
6264 else
6265 ac_cv_header_stdc=no
6267 rm -f conftest*
6271 if test $ac_cv_header_stdc = yes; then
6272 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6273 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6274 /* end confdefs.h. */
6275 #include <stdlib.h>
6277 _ACEOF
6278 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6279 $EGREP "free" >/dev/null 2>&1; then :
6281 else
6282 ac_cv_header_stdc=no
6284 rm -f conftest*
6288 if test $ac_cv_header_stdc = yes; then
6289 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6290 if test "$cross_compiling" = yes; then :
6292 else
6293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6294 /* end confdefs.h. */
6295 #include <ctype.h>
6296 #include <stdlib.h>
6297 #if ((' ' & 0x0FF) == 0x020)
6298 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6299 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6300 #else
6301 # define ISLOWER(c) \
6302 (('a' <= (c) && (c) <= 'i') \
6303 || ('j' <= (c) && (c) <= 'r') \
6304 || ('s' <= (c) && (c) <= 'z'))
6305 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6306 #endif
6308 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6310 main ()
6312 int i;
6313 for (i = 0; i < 256; i++)
6314 if (XOR (islower (i), ISLOWER (i))
6315 || toupper (i) != TOUPPER (i))
6316 return 2;
6317 return 0;
6319 _ACEOF
6320 if ac_fn_c_try_run "$LINENO"; then :
6322 else
6323 ac_cv_header_stdc=no
6325 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6326 conftest.$ac_objext conftest.beam conftest.$ac_ext
6331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6332 $as_echo "$ac_cv_header_stdc" >&6; }
6333 if test $ac_cv_header_stdc = yes; then
6335 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6339 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6340 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6341 inttypes.h stdint.h unistd.h
6342 do :
6343 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6344 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6346 eval as_val=\$$as_ac_Header
6347 if test "x$as_val" = x""yes; then :
6348 cat >>confdefs.h <<_ACEOF
6349 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6350 _ACEOF
6354 done
6360 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6361 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6362 MINIX=yes
6363 else
6364 MINIX=
6368 if test "$MINIX" = yes; then
6370 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6373 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6376 $as_echo "#define _MINIX 1" >>confdefs.h
6380 case "$host_os" in
6381 hpux*)
6383 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6386 esac
6389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6390 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6391 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6392 $as_echo_n "(cached) " >&6
6393 else
6394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6395 /* end confdefs.h. */
6397 # define __EXTENSIONS__ 1
6398 $ac_includes_default
6400 main ()
6404 return 0;
6406 _ACEOF
6407 if ac_fn_c_try_compile "$LINENO"; then :
6408 ac_cv_safe_to_define___extensions__=yes
6409 else
6410 ac_cv_safe_to_define___extensions__=no
6412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6415 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6416 test $ac_cv_safe_to_define___extensions__ = yes &&
6417 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6419 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6421 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6423 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6425 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6427 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6436 # Check whether --enable-largefile was given.
6437 if test "${enable_largefile+set}" = set; then :
6438 enableval=$enable_largefile;
6441 if test "$enable_largefile" != no; then
6443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6444 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6445 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6446 $as_echo_n "(cached) " >&6
6447 else
6448 ac_cv_sys_largefile_CC=no
6449 if test "$GCC" != yes; then
6450 ac_save_CC=$CC
6451 while :; do
6452 # IRIX 6.2 and later do not support large files by default,
6453 # so use the C compiler's -n32 option if that helps.
6454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6455 /* end confdefs.h. */
6456 #include <sys/types.h>
6457 /* Check that off_t can represent 2**63 - 1 correctly.
6458 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6459 since some C++ compilers masquerading as C compilers
6460 incorrectly reject 9223372036854775807. */
6461 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6462 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6463 && LARGE_OFF_T % 2147483647 == 1)
6464 ? 1 : -1];
6466 main ()
6470 return 0;
6472 _ACEOF
6473 if ac_fn_c_try_compile "$LINENO"; then :
6474 break
6476 rm -f core conftest.err conftest.$ac_objext
6477 CC="$CC -n32"
6478 if ac_fn_c_try_compile "$LINENO"; then :
6479 ac_cv_sys_largefile_CC=' -n32'; break
6481 rm -f core conftest.err conftest.$ac_objext
6482 break
6483 done
6484 CC=$ac_save_CC
6485 rm -f conftest.$ac_ext
6488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6489 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6490 if test "$ac_cv_sys_largefile_CC" != no; then
6491 CC=$CC$ac_cv_sys_largefile_CC
6494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6495 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6496 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6497 $as_echo_n "(cached) " >&6
6498 else
6499 while :; do
6500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6501 /* end confdefs.h. */
6502 #include <sys/types.h>
6503 /* Check that off_t can represent 2**63 - 1 correctly.
6504 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6505 since some C++ compilers masquerading as C compilers
6506 incorrectly reject 9223372036854775807. */
6507 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6508 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6509 && LARGE_OFF_T % 2147483647 == 1)
6510 ? 1 : -1];
6512 main ()
6516 return 0;
6518 _ACEOF
6519 if ac_fn_c_try_compile "$LINENO"; then :
6520 ac_cv_sys_file_offset_bits=no; break
6522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6524 /* end confdefs.h. */
6525 #define _FILE_OFFSET_BITS 64
6526 #include <sys/types.h>
6527 /* Check that off_t can represent 2**63 - 1 correctly.
6528 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6529 since some C++ compilers masquerading as C compilers
6530 incorrectly reject 9223372036854775807. */
6531 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6532 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6533 && LARGE_OFF_T % 2147483647 == 1)
6534 ? 1 : -1];
6536 main ()
6540 return 0;
6542 _ACEOF
6543 if ac_fn_c_try_compile "$LINENO"; then :
6544 ac_cv_sys_file_offset_bits=64; break
6546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6547 ac_cv_sys_file_offset_bits=unknown
6548 break
6549 done
6551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6552 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6553 case $ac_cv_sys_file_offset_bits in #(
6554 no | unknown) ;;
6556 cat >>confdefs.h <<_ACEOF
6557 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6558 _ACEOF
6560 esac
6561 rm -rf conftest*
6562 if test $ac_cv_sys_file_offset_bits = unknown; then
6563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6564 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6565 if test "${ac_cv_sys_large_files+set}" = set; then :
6566 $as_echo_n "(cached) " >&6
6567 else
6568 while :; do
6569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6570 /* end confdefs.h. */
6571 #include <sys/types.h>
6572 /* Check that off_t can represent 2**63 - 1 correctly.
6573 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6574 since some C++ compilers masquerading as C compilers
6575 incorrectly reject 9223372036854775807. */
6576 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6577 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6578 && LARGE_OFF_T % 2147483647 == 1)
6579 ? 1 : -1];
6581 main ()
6585 return 0;
6587 _ACEOF
6588 if ac_fn_c_try_compile "$LINENO"; then :
6589 ac_cv_sys_large_files=no; break
6591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6593 /* end confdefs.h. */
6594 #define _LARGE_FILES 1
6595 #include <sys/types.h>
6596 /* Check that off_t can represent 2**63 - 1 correctly.
6597 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6598 since some C++ compilers masquerading as C compilers
6599 incorrectly reject 9223372036854775807. */
6600 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6601 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6602 && LARGE_OFF_T % 2147483647 == 1)
6603 ? 1 : -1];
6605 main ()
6609 return 0;
6611 _ACEOF
6612 if ac_fn_c_try_compile "$LINENO"; then :
6613 ac_cv_sys_large_files=1; break
6615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6616 ac_cv_sys_large_files=unknown
6617 break
6618 done
6620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6621 $as_echo "$ac_cv_sys_large_files" >&6; }
6622 case $ac_cv_sys_large_files in #(
6623 no | unknown) ;;
6625 cat >>confdefs.h <<_ACEOF
6626 #define _LARGE_FILES $ac_cv_sys_large_files
6627 _ACEOF
6629 esac
6630 rm -rf conftest*
6636 case $ac_cv_prog_cc_stdc in #(
6637 no) :
6638 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6639 *) :
6640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6641 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6642 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6643 $as_echo_n "(cached) " >&6
6644 else
6645 ac_cv_prog_cc_c99=no
6646 ac_save_CC=$CC
6647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6648 /* end confdefs.h. */
6649 #include <stdarg.h>
6650 #include <stdbool.h>
6651 #include <stdlib.h>
6652 #include <wchar.h>
6653 #include <stdio.h>
6655 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6656 #define debug(...) fprintf (stderr, __VA_ARGS__)
6657 #define showlist(...) puts (#__VA_ARGS__)
6658 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6659 static void
6660 test_varargs_macros (void)
6662 int x = 1234;
6663 int y = 5678;
6664 debug ("Flag");
6665 debug ("X = %d\n", x);
6666 showlist (The first, second, and third items.);
6667 report (x>y, "x is %d but y is %d", x, y);
6670 // Check long long types.
6671 #define BIG64 18446744073709551615ull
6672 #define BIG32 4294967295ul
6673 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6674 #if !BIG_OK
6675 your preprocessor is broken;
6676 #endif
6677 #if BIG_OK
6678 #else
6679 your preprocessor is broken;
6680 #endif
6681 static long long int bignum = -9223372036854775807LL;
6682 static unsigned long long int ubignum = BIG64;
6684 struct incomplete_array
6686 int datasize;
6687 double data[];
6690 struct named_init {
6691 int number;
6692 const wchar_t *name;
6693 double average;
6696 typedef const char *ccp;
6698 static inline int
6699 test_restrict (ccp restrict text)
6701 // See if C++-style comments work.
6702 // Iterate through items via the restricted pointer.
6703 // Also check for declarations in for loops.
6704 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6705 continue;
6706 return 0;
6709 // Check varargs and va_copy.
6710 static void
6711 test_varargs (const char *format, ...)
6713 va_list args;
6714 va_start (args, format);
6715 va_list args_copy;
6716 va_copy (args_copy, args);
6718 const char *str;
6719 int number;
6720 float fnumber;
6722 while (*format)
6724 switch (*format++)
6726 case 's': // string
6727 str = va_arg (args_copy, const char *);
6728 break;
6729 case 'd': // int
6730 number = va_arg (args_copy, int);
6731 break;
6732 case 'f': // float
6733 fnumber = va_arg (args_copy, double);
6734 break;
6735 default:
6736 break;
6739 va_end (args_copy);
6740 va_end (args);
6744 main ()
6747 // Check bool.
6748 _Bool success = false;
6750 // Check restrict.
6751 if (test_restrict ("String literal") == 0)
6752 success = true;
6753 char *restrict newvar = "Another string";
6755 // Check varargs.
6756 test_varargs ("s, d' f .", "string", 65, 34.234);
6757 test_varargs_macros ();
6759 // Check flexible array members.
6760 struct incomplete_array *ia =
6761 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6762 ia->datasize = 10;
6763 for (int i = 0; i < ia->datasize; ++i)
6764 ia->data[i] = i * 1.234;
6766 // Check named initializers.
6767 struct named_init ni = {
6768 .number = 34,
6769 .name = L"Test wide string",
6770 .average = 543.34343,
6773 ni.number = 58;
6775 int dynamic_array[ni.number];
6776 dynamic_array[ni.number - 1] = 543;
6778 // work around unused variable warnings
6779 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6780 || dynamic_array[ni.number - 1] != 543);
6783 return 0;
6785 _ACEOF
6786 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6788 CC="$ac_save_CC $ac_arg"
6789 if ac_fn_c_try_compile "$LINENO"; then :
6790 ac_cv_prog_cc_c99=$ac_arg
6792 rm -f core conftest.err conftest.$ac_objext
6793 test "x$ac_cv_prog_cc_c99" != "xno" && break
6794 done
6795 rm -f conftest.$ac_ext
6796 CC=$ac_save_CC
6799 # AC_CACHE_VAL
6800 case "x$ac_cv_prog_cc_c99" in
6802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6803 $as_echo "none needed" >&6; } ;;
6804 xno)
6805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6806 $as_echo "unsupported" >&6; } ;;
6808 CC="$CC $ac_cv_prog_cc_c99"
6809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6810 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6811 esac
6812 if test "x$ac_cv_prog_cc_c99" != xno; then :
6813 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6814 else
6815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6816 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6817 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6818 $as_echo_n "(cached) " >&6
6819 else
6820 ac_cv_prog_cc_c89=no
6821 ac_save_CC=$CC
6822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6823 /* end confdefs.h. */
6824 #include <stdarg.h>
6825 #include <stdio.h>
6826 #include <sys/types.h>
6827 #include <sys/stat.h>
6828 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6829 struct buf { int x; };
6830 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6831 static char *e (p, i)
6832 char **p;
6833 int i;
6835 return p[i];
6837 static char *f (char * (*g) (char **, int), char **p, ...)
6839 char *s;
6840 va_list v;
6841 va_start (v,p);
6842 s = g (p, va_arg (v,int));
6843 va_end (v);
6844 return s;
6847 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6848 function prototypes and stuff, but not '\xHH' hex character constants.
6849 These don't provoke an error unfortunately, instead are silently treated
6850 as 'x'. The following induces an error, until -std is added to get
6851 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6852 array size at least. It's necessary to write '\x00'==0 to get something
6853 that's true only with -std. */
6854 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6856 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6857 inside strings and character constants. */
6858 #define FOO(x) 'x'
6859 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6861 int test (int i, double x);
6862 struct s1 {int (*f) (int a);};
6863 struct s2 {int (*f) (double a);};
6864 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6865 int argc;
6866 char **argv;
6868 main ()
6870 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6872 return 0;
6874 _ACEOF
6875 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6876 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6878 CC="$ac_save_CC $ac_arg"
6879 if ac_fn_c_try_compile "$LINENO"; then :
6880 ac_cv_prog_cc_c89=$ac_arg
6882 rm -f core conftest.err conftest.$ac_objext
6883 test "x$ac_cv_prog_cc_c89" != "xno" && break
6884 done
6885 rm -f conftest.$ac_ext
6886 CC=$ac_save_CC
6889 # AC_CACHE_VAL
6890 case "x$ac_cv_prog_cc_c89" in
6892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6893 $as_echo "none needed" >&6; } ;;
6894 xno)
6895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6896 $as_echo "unsupported" >&6; } ;;
6898 CC="$CC $ac_cv_prog_cc_c89"
6899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6900 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6901 esac
6902 if test "x$ac_cv_prog_cc_c89" != xno; then :
6903 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6904 else
6905 ac_cv_prog_cc_stdc=no
6910 esac
6911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6912 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6913 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6914 $as_echo_n "(cached) " >&6
6917 case $ac_cv_prog_cc_stdc in #(
6918 no) :
6919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6920 $as_echo "unsupported" >&6; } ;; #(
6921 '') :
6922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6923 $as_echo "none needed" >&6; } ;; #(
6924 *) :
6925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6926 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6927 esac
6931 # Code from module alloca-opt:
6932 # Code from module allocator:
6933 # Code from module c-ctype:
6934 # Code from module c-strcase:
6935 # Code from module careadlinkat:
6936 # Code from module clock-time:
6937 # Code from module crypto/md5:
6938 # Code from module crypto/sha1:
6939 # Code from module crypto/sha256:
6940 # Code from module crypto/sha512:
6941 # Code from module dosname:
6942 # Code from module dtoastr:
6943 # Code from module dtotimespec:
6944 # Code from module dup2:
6945 # Code from module environ:
6946 # Code from module extensions:
6948 # Code from module filemode:
6949 # Code from module getloadavg:
6950 # Code from module getopt-gnu:
6951 # Code from module getopt-posix:
6952 # Code from module gettext-h:
6953 # Code from module gettime:
6954 # Code from module gettimeofday:
6955 # Code from module ignore-value:
6956 # Code from module include_next:
6957 # Code from module intprops:
6958 # Code from module inttypes-incomplete:
6959 # Code from module largefile:
6961 # Code from module lstat:
6962 # Code from module manywarnings:
6963 # Code from module mktime:
6964 # Code from module multiarch:
6965 # Code from module nocrash:
6966 # Code from module pathmax:
6967 # Code from module pselect:
6968 # Code from module pthread_sigmask:
6969 # Code from module readlink:
6970 # Code from module signal-h:
6971 # Code from module snippet/_Noreturn:
6972 # Code from module snippet/arg-nonnull:
6973 # Code from module snippet/c++defs:
6974 # Code from module snippet/warn-on-use:
6975 # Code from module socklen:
6976 # Code from module ssize_t:
6977 # Code from module stat:
6978 # Code from module stat-time:
6979 # Code from module stdalign:
6980 # Code from module stdarg:
6984 # Code from module stdbool:
6985 # Code from module stddef:
6986 # Code from module stdint:
6987 # Code from module stdio:
6988 # Code from module stdlib:
6989 # Code from module strftime:
6990 # Code from module strtoimax:
6991 # Code from module strtoll:
6992 # Code from module strtoull:
6993 # Code from module strtoumax:
6994 # Code from module symlink:
6995 # Code from module sys_select:
6996 # Code from module sys_stat:
6997 # Code from module sys_time:
6998 # Code from module time:
6999 # Code from module time_r:
7000 # Code from module timespec:
7001 # Code from module timespec-add:
7002 # Code from module timespec-sub:
7003 # Code from module u64:
7004 # Code from module unistd:
7005 # Code from module utimens:
7006 # Code from module verify:
7007 # Code from module warnings:
7010 # Check whether --enable-gcc-warnings was given.
7011 if test "${enable_gcc_warnings+set}" = set; then :
7012 enableval=$enable_gcc_warnings; case $enableval in
7013 yes|no) ;;
7014 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7015 esac
7016 gl_gcc_warnings=$enableval
7017 else
7018 gl_gcc_warnings=no
7023 # Check whether --enable-link-time-optimization was given.
7024 if test "${enable_link_time_optimization+set}" = set; then :
7025 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7027 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7028 ac_lto_supported=no
7029 if test x$GCC = xyes; then
7030 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7031 if test x$CPUS != x; then
7032 LTO="-flto=$CPUS"
7033 else
7034 LTO="-flto"
7036 old_CFLAGS=$CFLAGS
7037 CFLAGS="$CFLAGS $LTO"
7038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7039 /* end confdefs.h. */
7042 main ()
7046 return 0;
7048 _ACEOF
7049 if ac_fn_c_try_compile "$LINENO"; then :
7050 ac_lto_supported=yes
7051 else
7052 ac_lto_supported=no
7054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7055 CFLAGS="$old_CFLAGS"
7057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7058 $as_echo "$ac_lto_supported" >&6; }
7059 if test "$ac_lto_supported" = "yes"; then
7060 CFLAGS="$CFLAGS $LTO"
7066 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7067 # ------------------------------------------------
7068 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7069 # Otherwise, run RUN-IF-NOT-FOUND.
7072 # When compiling with GCC, prefer -isystem to -I when including system
7073 # include files, to avoid generating useless diagnostics for the files.
7074 if test "$gl_gcc_warnings" != yes; then
7075 isystem='-I'
7076 else
7077 isystem='-isystem '
7079 # This, $nw, is the list of warnings we disable.
7082 case $with_x_toolkit in
7083 lucid | athena | motif)
7084 # Old toolkits mishandle 'const'.
7085 nw="$nw -Wwrite-strings"
7088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7089 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7090 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7091 $as_echo_n "(cached) " >&6
7092 else
7094 gl_save_compiler_FLAGS="$CFLAGS"
7095 as_fn_append CFLAGS " -Werror"
7096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7097 /* end confdefs.h. */
7100 main ()
7104 return 0;
7106 _ACEOF
7107 if ac_fn_c_try_compile "$LINENO"; then :
7108 gl_cv_warn_c__Werror=yes
7109 else
7110 gl_cv_warn_c__Werror=no
7112 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7113 CFLAGS="$gl_save_compiler_FLAGS"
7116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7117 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7118 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7119 as_fn_append WERROR_CFLAGS " -Werror"
7124 esac
7127 nw="$nw -Waggregate-return" # anachronistic
7128 nw="$nw -Wlong-long" # C90 is anachronistic
7129 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7130 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7131 nw="$nw -Wtraditional" # Warns on #elif which we use often
7132 nw="$nw -Wcast-qual" # Too many warnings for now
7133 nw="$nw -Wconversion" # Too many warnings for now
7134 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7135 nw="$nw -Wsign-conversion" # Too many warnings for now
7136 nw="$nw -Woverlength-strings" # Not a problem these days
7137 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7138 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7139 nw="$nw -Wpadded" # Our structs are not padded
7140 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7141 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7142 nw="$nw -Wformat-nonliteral" # we do this a lot
7143 nw="$nw -Wvla" # warnings in gettext.h
7144 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7145 nw="$nw -Wswitch-enum" # Too many warnings for now
7146 nw="$nw -Wswitch-default" # Too many warnings for now
7147 nw="$nw -Wfloat-equal" # warns about high-quality code
7148 nw="$nw -Winline" # OK to ignore 'inline'
7149 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7150 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7152 # Emacs doesn't care about shadowing; see
7153 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7154 nw="$nw -Wshadow"
7156 # The following lines should be removable at some point.
7157 nw="$nw -Wstack-protector"
7158 nw="$nw -Wstrict-overflow"
7159 nw="$nw -Wsuggest-attribute=pure"
7163 if test -n "$GCC"; then
7165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7166 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7167 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7168 $as_echo_n "(cached) " >&6
7169 else
7171 gl_save_CFLAGS="$CFLAGS"
7172 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7174 /* end confdefs.h. */
7177 main ()
7181 return 0;
7183 _ACEOF
7184 if ac_fn_c_try_compile "$LINENO"; then :
7185 gl_cv_cc_nomfi_supported=yes
7186 else
7187 gl_cv_cc_nomfi_supported=no
7189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7190 CFLAGS="$gl_save_CFLAGS"
7193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7194 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7196 if test "$gl_cv_cc_nomfi_supported" = yes; then
7197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7198 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7199 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7200 $as_echo_n "(cached) " >&6
7201 else
7203 gl_save_CFLAGS="$CFLAGS"
7204 CFLAGS="$CFLAGS -W -Werror"
7205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7206 /* end confdefs.h. */
7207 void f (void)
7209 typedef struct { int a; int b; } s_t;
7210 s_t s1 = { 0, };
7214 main ()
7218 return 0;
7220 _ACEOF
7221 if ac_fn_c_try_compile "$LINENO"; then :
7222 gl_cv_cc_nomfi_needed=no
7223 else
7224 gl_cv_cc_nomfi_needed=yes
7226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7227 CFLAGS="$gl_save_CFLAGS"
7231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7232 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7236 gl_manywarn_set=
7237 for gl_manywarn_item in \
7238 -Wall \
7239 -W \
7240 -Wformat-y2k \
7241 -Wformat-nonliteral \
7242 -Wformat-security \
7243 -Winit-self \
7244 -Wmissing-include-dirs \
7245 -Wswitch-default \
7246 -Wswitch-enum \
7247 -Wunused \
7248 -Wunknown-pragmas \
7249 -Wstrict-aliasing \
7250 -Wstrict-overflow \
7251 -Wsystem-headers \
7252 -Wfloat-equal \
7253 -Wtraditional \
7254 -Wtraditional-conversion \
7255 -Wdeclaration-after-statement \
7256 -Wundef \
7257 -Wshadow \
7258 -Wunsafe-loop-optimizations \
7259 -Wpointer-arith \
7260 -Wbad-function-cast \
7261 -Wc++-compat \
7262 -Wcast-qual \
7263 -Wcast-align \
7264 -Wwrite-strings \
7265 -Wconversion \
7266 -Wsign-conversion \
7267 -Wlogical-op \
7268 -Waggregate-return \
7269 -Wstrict-prototypes \
7270 -Wold-style-definition \
7271 -Wmissing-prototypes \
7272 -Wmissing-declarations \
7273 -Wmissing-noreturn \
7274 -Wmissing-format-attribute \
7275 -Wpacked \
7276 -Wpadded \
7277 -Wredundant-decls \
7278 -Wnested-externs \
7279 -Wunreachable-code \
7280 -Winline \
7281 -Winvalid-pch \
7282 -Wlong-long \
7283 -Wvla \
7284 -Wvolatile-register-var \
7285 -Wdisabled-optimization \
7286 -Wstack-protector \
7287 -Woverlength-strings \
7288 -Wbuiltin-macro-redefined \
7289 -Wmudflap \
7290 -Wpacked-bitfield-compat \
7291 -Wsync-nand \
7292 ; do
7293 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7294 done
7295 # The following are not documented in the manual but are included in
7296 # output from gcc --help=warnings.
7297 for gl_manywarn_item in \
7298 -Wattributes \
7299 -Wcoverage-mismatch \
7300 -Wunused-macros \
7301 ; do
7302 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7303 done
7304 # More warnings from gcc 4.6.2 --help=warnings.
7305 for gl_manywarn_item in \
7306 -Wabi \
7307 -Wcpp \
7308 -Wdeprecated \
7309 -Wdeprecated-declarations \
7310 -Wdiv-by-zero \
7311 -Wdouble-promotion \
7312 -Wendif-labels \
7313 -Wextra \
7314 -Wformat-contains-nul \
7315 -Wformat-extra-args \
7316 -Wformat-zero-length \
7317 -Wformat=2 \
7318 -Wmultichar \
7319 -Wnormalized=nfc \
7320 -Woverflow \
7321 -Wpointer-to-int-cast \
7322 -Wpragmas \
7323 -Wsuggest-attribute=const \
7324 -Wsuggest-attribute=noreturn \
7325 -Wsuggest-attribute=pure \
7326 -Wtrampolines \
7327 ; do
7328 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7329 done
7331 # Disable the missing-field-initializers warning if needed
7332 if test "$gl_cv_cc_nomfi_needed" = yes; then
7333 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7336 ws=$gl_manywarn_set
7339 gl_warn_set=
7340 set x $ws; shift
7341 for gl_warn_item
7343 case " $nw " in
7344 *" $gl_warn_item "*)
7347 gl_warn_set="$gl_warn_set $gl_warn_item"
7349 esac
7350 done
7351 ws=$gl_warn_set
7353 for w in $ws; do
7354 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7356 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7357 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7358 $as_echo_n "(cached) " >&6
7359 else
7361 gl_save_compiler_FLAGS="$CFLAGS"
7362 as_fn_append CFLAGS " $w"
7363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7364 /* end confdefs.h. */
7367 main ()
7371 return 0;
7373 _ACEOF
7374 if ac_fn_c_try_compile "$LINENO"; then :
7375 eval "$as_gl_Warn=yes"
7376 else
7377 eval "$as_gl_Warn=no"
7379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7380 CFLAGS="$gl_save_compiler_FLAGS"
7383 eval ac_res=\$$as_gl_Warn
7384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7385 $as_echo "$ac_res" >&6; }
7386 eval as_val=\$$as_gl_Warn
7387 if test "x$as_val" = x""yes; then :
7388 as_fn_append WARN_CFLAGS " $w"
7392 done
7393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7394 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7395 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7396 $as_echo_n "(cached) " >&6
7397 else
7399 gl_save_compiler_FLAGS="$CFLAGS"
7400 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7402 /* end confdefs.h. */
7405 main ()
7409 return 0;
7411 _ACEOF
7412 if ac_fn_c_try_compile "$LINENO"; then :
7413 gl_cv_warn_c__Wno_missing_field_initializers=yes
7414 else
7415 gl_cv_warn_c__Wno_missing_field_initializers=no
7417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7418 CFLAGS="$gl_save_compiler_FLAGS"
7421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7422 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7423 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7424 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7427 # We need this one
7428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7429 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7430 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7431 $as_echo_n "(cached) " >&6
7432 else
7434 gl_save_compiler_FLAGS="$CFLAGS"
7435 as_fn_append CFLAGS " -Wno-sign-compare"
7436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7437 /* end confdefs.h. */
7440 main ()
7444 return 0;
7446 _ACEOF
7447 if ac_fn_c_try_compile "$LINENO"; then :
7448 gl_cv_warn_c__Wno_sign_compare=yes
7449 else
7450 gl_cv_warn_c__Wno_sign_compare=no
7452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7453 CFLAGS="$gl_save_compiler_FLAGS"
7456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7457 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7458 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7459 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7462 # Too many warnings for now
7463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7464 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7465 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7466 $as_echo_n "(cached) " >&6
7467 else
7469 gl_save_compiler_FLAGS="$CFLAGS"
7470 as_fn_append CFLAGS " -Wno-type-limits"
7471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7472 /* end confdefs.h. */
7475 main ()
7479 return 0;
7481 _ACEOF
7482 if ac_fn_c_try_compile "$LINENO"; then :
7483 gl_cv_warn_c__Wno_type_limits=yes
7484 else
7485 gl_cv_warn_c__Wno_type_limits=no
7487 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7488 CFLAGS="$gl_save_compiler_FLAGS"
7491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7492 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7493 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7494 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7497 # Too many warnings for now
7498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7499 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7500 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7501 $as_echo_n "(cached) " >&6
7502 else
7504 gl_save_compiler_FLAGS="$CFLAGS"
7505 as_fn_append CFLAGS " -Wno-switch"
7506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7507 /* end confdefs.h. */
7510 main ()
7514 return 0;
7516 _ACEOF
7517 if ac_fn_c_try_compile "$LINENO"; then :
7518 gl_cv_warn_c__Wno_switch=yes
7519 else
7520 gl_cv_warn_c__Wno_switch=no
7522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7523 CFLAGS="$gl_save_compiler_FLAGS"
7526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7527 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7528 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7529 as_fn_append WARN_CFLAGS " -Wno-switch"
7532 # Too many warnings for now
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7534 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7535 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7536 $as_echo_n "(cached) " >&6
7537 else
7539 gl_save_compiler_FLAGS="$CFLAGS"
7540 as_fn_append CFLAGS " -Wno-unused-parameter"
7541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7542 /* end confdefs.h. */
7545 main ()
7549 return 0;
7551 _ACEOF
7552 if ac_fn_c_try_compile "$LINENO"; then :
7553 gl_cv_warn_c__Wno_unused_parameter=yes
7554 else
7555 gl_cv_warn_c__Wno_unused_parameter=no
7557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7558 CFLAGS="$gl_save_compiler_FLAGS"
7561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7562 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7563 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7564 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7567 # Too many warnings for now
7568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7569 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7570 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7571 $as_echo_n "(cached) " >&6
7572 else
7574 gl_save_compiler_FLAGS="$CFLAGS"
7575 as_fn_append CFLAGS " -Wno-format-nonliteral"
7576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7577 /* end confdefs.h. */
7580 main ()
7584 return 0;
7586 _ACEOF
7587 if ac_fn_c_try_compile "$LINENO"; then :
7588 gl_cv_warn_c__Wno_format_nonliteral=yes
7589 else
7590 gl_cv_warn_c__Wno_format_nonliteral=no
7592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7593 CFLAGS="$gl_save_compiler_FLAGS"
7596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7597 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7598 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7599 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7604 # In spite of excluding -Wlogical-op above, it is enabled, as of
7605 # gcc 4.5.0 20090517.
7606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7607 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7608 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7609 $as_echo_n "(cached) " >&6
7610 else
7612 gl_save_compiler_FLAGS="$CFLAGS"
7613 as_fn_append CFLAGS " -Wno-logical-op"
7614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7615 /* end confdefs.h. */
7618 main ()
7622 return 0;
7624 _ACEOF
7625 if ac_fn_c_try_compile "$LINENO"; then :
7626 gl_cv_warn_c__Wno_logical_op=yes
7627 else
7628 gl_cv_warn_c__Wno_logical_op=no
7630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7631 CFLAGS="$gl_save_compiler_FLAGS"
7634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7635 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7636 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7637 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7643 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7644 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7645 $as_echo_n "(cached) " >&6
7646 else
7648 gl_save_compiler_FLAGS="$CFLAGS"
7649 as_fn_append CFLAGS " -fdiagnostics-show-option"
7650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7651 /* end confdefs.h. */
7654 main ()
7658 return 0;
7660 _ACEOF
7661 if ac_fn_c_try_compile "$LINENO"; then :
7662 gl_cv_warn_c__fdiagnostics_show_option=yes
7663 else
7664 gl_cv_warn_c__fdiagnostics_show_option=no
7666 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7667 CFLAGS="$gl_save_compiler_FLAGS"
7670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7671 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7672 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7673 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7678 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7679 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7680 $as_echo_n "(cached) " >&6
7681 else
7683 gl_save_compiler_FLAGS="$CFLAGS"
7684 as_fn_append CFLAGS " -funit-at-a-time"
7685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7686 /* end confdefs.h. */
7689 main ()
7693 return 0;
7695 _ACEOF
7696 if ac_fn_c_try_compile "$LINENO"; then :
7697 gl_cv_warn_c__funit_at_a_time=yes
7698 else
7699 gl_cv_warn_c__funit_at_a_time=no
7701 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7702 CFLAGS="$gl_save_compiler_FLAGS"
7705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7706 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7707 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7708 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7714 $as_echo "#define lint 1" >>confdefs.h
7717 $as_echo "#define _FORTIFY_SOURCE 2" >>confdefs.h
7720 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7723 # We use a slightly smaller set of warning options for lib/.
7724 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7726 nw="$nw -Wunused-macros"
7729 gl_warn_set=
7730 set x $WARN_CFLAGS; shift
7731 for gl_warn_item
7733 case " $nw " in
7734 *" $gl_warn_item "*)
7737 gl_warn_set="$gl_warn_set $gl_warn_item"
7739 esac
7740 done
7741 GNULIB_WARN_CFLAGS=$gl_warn_set
7749 # Extract the first word of "install-info", so it can be a program name with args.
7750 set dummy install-info; ac_word=$2
7751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7752 $as_echo_n "checking for $ac_word... " >&6; }
7753 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7754 $as_echo_n "(cached) " >&6
7755 else
7756 case $INSTALL_INFO in
7757 [\\/]* | ?:[\\/]*)
7758 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7762 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7764 IFS=$as_save_IFS
7765 test -z "$as_dir" && as_dir=.
7766 for ac_exec_ext in '' $ac_executable_extensions; do
7767 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7768 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7769 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7770 break 2
7772 done
7773 done
7774 IFS=$as_save_IFS
7776 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7778 esac
7780 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7781 if test -n "$INSTALL_INFO"; then
7782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7783 $as_echo "$INSTALL_INFO" >&6; }
7784 else
7785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7786 $as_echo "no" >&6; }
7790 # Extract the first word of "gzip", so it can be a program name with args.
7791 set dummy gzip; ac_word=$2
7792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7793 $as_echo_n "checking for $ac_word... " >&6; }
7794 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7795 $as_echo_n "(cached) " >&6
7796 else
7797 case $GZIP_PROG in
7798 [\\/]* | ?:[\\/]*)
7799 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7803 for as_dir in $PATH
7805 IFS=$as_save_IFS
7806 test -z "$as_dir" && as_dir=.
7807 for ac_exec_ext in '' $ac_executable_extensions; do
7808 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7809 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7811 break 2
7813 done
7814 done
7815 IFS=$as_save_IFS
7818 esac
7820 GZIP_PROG=$ac_cv_path_GZIP_PROG
7821 if test -n "$GZIP_PROG"; then
7822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7823 $as_echo "$GZIP_PROG" >&6; }
7824 else
7825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7826 $as_echo "no" >&6; }
7831 if test $opsys = gnu-linux; then
7832 # Extract the first word of "paxctl", so it can be a program name with args.
7833 set dummy paxctl; ac_word=$2
7834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7835 $as_echo_n "checking for $ac_word... " >&6; }
7836 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7837 $as_echo_n "(cached) " >&6
7838 else
7839 case $PAXCTL in
7840 [\\/]* | ?:[\\/]*)
7841 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7844 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7845 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7847 IFS=$as_save_IFS
7848 test -z "$as_dir" && as_dir=.
7849 for ac_exec_ext in '' $ac_executable_extensions; do
7850 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7851 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
7852 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7853 break 2
7855 done
7856 done
7857 IFS=$as_save_IFS
7860 esac
7862 PAXCTL=$ac_cv_path_PAXCTL
7863 if test -n "$PAXCTL"; then
7864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
7865 $as_echo "$PAXCTL" >&6; }
7866 else
7867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7868 $as_echo "no" >&6; }
7874 ## Need makeinfo >= 4.7 (?) to build the manuals.
7875 # Extract the first word of "makeinfo", so it can be a program name with args.
7876 set dummy makeinfo; ac_word=$2
7877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7878 $as_echo_n "checking for $ac_word... " >&6; }
7879 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
7880 $as_echo_n "(cached) " >&6
7881 else
7882 case $MAKEINFO in
7883 [\\/]* | ?:[\\/]*)
7884 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7887 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7888 for as_dir in $PATH
7890 IFS=$as_save_IFS
7891 test -z "$as_dir" && as_dir=.
7892 for ac_exec_ext in '' $ac_executable_extensions; do
7893 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7894 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
7895 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7896 break 2
7898 done
7899 done
7900 IFS=$as_save_IFS
7902 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
7904 esac
7906 MAKEINFO=$ac_cv_path_MAKEINFO
7907 if test -n "$MAKEINFO"; then
7908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
7909 $as_echo "$MAKEINFO" >&6; }
7910 else
7911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7912 $as_echo "no" >&6; }
7916 if test "$MAKEINFO" != "no" && \
7917 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
7918 MAKEINFO=no
7921 ## Makeinfo is unusual. For a released Emacs, the manuals are
7922 ## pre-built, and not deleted by the normal clean rules. makeinfo is
7923 ## therefore in the category of "special tools" not normally required, which
7924 ## configure does not have to check for (eg autoconf itself).
7925 ## In a Bazaar checkout on the other hand, the manuals are not included.
7926 ## So makeinfo is a requirement to build from Bazaar, and configure
7927 ## should test for it as it does for any other build requirement.
7928 ## We use the presence of $srcdir/info/emacs to distinguish a release,
7929 ## with pre-built manuals, from a Bazaar checkout.
7930 HAVE_MAKEINFO=yes
7932 if test "$MAKEINFO" = "no"; then
7933 MAKEINFO=makeinfo
7934 if test "x${with_makeinfo}" = "xno"; then
7935 HAVE_MAKEINFO=no
7936 elif test ! -e $srcdir/info/emacs; then
7937 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
7938 source tree does not seem to have pre-built manuals in the \`info' directory.
7939 Either install a suitable version of makeinfo, or re-run configure
7940 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
7945 INFO_EXT=.info
7946 INFO_OPTS=--no-split
7951 if test x$GCC = xyes; then
7952 test "x$GCC_LINK_TEST_OPTIONS" != x && \
7953 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
7954 else
7955 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
7956 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
7960 late_LDFLAGS=$LDFLAGS
7961 if test x$GCC = xyes; then
7962 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
7963 else
7964 LDFLAGS="$LDFLAGS -znocombreloc"
7967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
7968 $as_echo_n "checking for -znocombreloc... " >&6; }
7969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7970 /* end confdefs.h. */
7973 main ()
7977 return 0;
7979 _ACEOF
7980 if ac_fn_c_try_link "$LINENO"; then :
7981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7982 $as_echo "yes" >&6; }
7983 else
7984 LDFLAGS=$late_LDFLAGS
7985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7986 $as_echo "no" >&6; }
7988 rm -f core conftest.err conftest.$ac_objext \
7989 conftest$ac_exeext conftest.$ac_ext
7992 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
7993 case "$opsys" in
7994 your-opsys-here) CANNOT_DUMP=yes ;;
7995 esac
7997 test "$CANNOT_DUMP" = "yes" && \
7999 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8005 UNEXEC_OBJ=unexelf.o
8006 case "$opsys" in
8007 # MSDOS uses unexcoff.o
8008 # MSWindows uses unexw32.o
8009 aix4-2)
8010 UNEXEC_OBJ=unexaix.o
8012 cygwin)
8013 UNEXEC_OBJ=unexcw.o
8015 darwin)
8016 UNEXEC_OBJ=unexmacosx.o
8018 hpux10-20 | hpux11)
8019 UNEXEC_OBJ=unexhp9k800.o
8021 sol2-10)
8022 # Use the Solaris dldump() function, called from unexsol.c, to dump
8023 # emacs, instead of the generic ELF dump code found in unexelf.c.
8024 # The resulting binary has a complete symbol table, and is better
8025 # for debugging and other observability tools (debuggers, pstack, etc).
8027 # If you encounter a problem using dldump(), please consider sending
8028 # a message to the OpenSolaris tools-linking mailing list:
8029 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8031 # It is likely that dldump() works with older Solaris too, but this has
8032 # not been tested, so for now this change is for Solaris 10 or newer.
8033 UNEXEC_OBJ=unexsol.o
8035 esac
8037 LD_SWITCH_SYSTEM=
8038 case "$opsys" in
8039 freebsd)
8040 ## Let `ld' find image libs and similar things in /usr/local/lib.
8041 ## The system compiler, GCC, has apparently been modified to not
8042 ## look there, contrary to what a stock GCC would do.
8043 ### It's not our place to do this. See bug#10313#17.
8044 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8048 gnu-linux)
8049 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8050 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8053 netbsd)
8054 ### It's not our place to do this. See bug#10313#17.
8055 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8059 openbsd)
8060 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8061 ## otherwise Emacs dumps core on elf systems.
8062 LD_SWITCH_SYSTEM="-Z"
8064 esac
8067 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8069 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8070 ## which has not been defined yet. When this was handled with cpp,
8071 ## it was expanded to null when configure sourced the s/*.h file.
8072 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8073 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8074 ## (or somesuch), but because it is supposed to go at the _front_
8075 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8076 ## Compare with the gnu-linux case below, which added to the end
8077 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8078 ## LD_SWITCH_SYSTEM_TEMACS.
8079 case "$opsys" in
8080 netbsd|openbsd)
8081 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8082 esac
8085 C_SWITCH_MACHINE=
8086 case $canonical in
8087 alpha*)
8088 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8089 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8093 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8094 ## With ELF, make sure that all common symbols get allocated to in the
8095 ## data section. Otherwise, the dump of temacs may miss variables in
8096 ## the shared library that have been initialized. For example, with
8097 ## GNU libc, __malloc_initialized would normally be resolved to the
8098 ## shared library's .bss section, which is fatal.
8099 if test "x$GCC" = "xyes"; then
8100 C_SWITCH_MACHINE="-fno-common"
8101 else
8102 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8104 else
8105 UNEXEC_OBJ=unexalpha.o
8108 esac
8113 C_SWITCH_SYSTEM=
8114 ## Some programs in src produce warnings saying certain subprograms
8115 ## are too complex and need a MAXMEM value greater than 2000 for
8116 ## additional optimization. --nils@exp-math.uni-essen.de
8117 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8118 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8119 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8120 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8124 LIBS_SYSTEM=
8125 case "$opsys" in
8126 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8127 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8129 freebsd) LIBS_SYSTEM="-lutil" ;;
8131 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8133 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8135 ## Motif needs -lgen.
8136 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8137 esac
8141 ### Make sure subsequent tests use flags consistent with the build flags.
8143 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8144 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8145 else
8146 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8149 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8151 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8155 LIB_MATH=-lm
8156 LIB_STANDARD=
8157 START_FILES=
8158 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8160 case $opsys in
8161 cygwin )
8162 LIB_MATH=
8163 START_FILES='pre-crt0.o'
8165 darwin )
8166 ## Adding -lm confuses the dynamic linker, so omit it.
8167 LIB_MATH=
8168 START_FILES='pre-crt0.o'
8170 freebsd )
8171 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8172 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8173 SYSTEM_TYPE=berkeley-unix
8175 gnu-linux | gnu-kfreebsd )
8176 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8177 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8179 hpux10-20 | hpux11 )
8180 LIB_STANDARD=-lc
8181 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8183 netbsd | openbsd )
8184 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8185 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8186 SYSTEM_TYPE=berkeley-unix
8189 sol2* | unixware )
8190 SYSTEM_TYPE=usg-unix-v
8193 esac
8198 cat >>confdefs.h <<_ACEOF
8199 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8200 _ACEOF
8203 crt_files=
8205 for file in x $LIB_STANDARD $START_FILES; do
8206 case "$file" in
8207 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8208 esac
8209 done
8211 if test "x$crt_files" != x; then
8213 ## If user specified a crt-dir, use that unconditionally.
8214 crt_gcc=no
8216 if test "X$CRT_DIR" = "X"; then
8218 CRT_DIR=/usr/lib # default
8220 case "$canonical" in
8221 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8222 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8223 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8224 ## For anything else (eg /usr/lib32), it is up the user to specify
8225 ## the location (bug#5655).
8226 ## Test for crtn.o, not just the directory, because sometimes the
8227 ## directory exists but does not have the relevant files (bug#1287).
8228 ## FIXME better to test for binary compatibility somehow.
8229 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8232 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8233 esac
8235 case "$opsys" in
8236 hpux10-20) CRT_DIR=/lib ;;
8237 esac
8239 test "x${GCC}" = xyes && crt_gcc=yes
8241 fi # CRT_DIR = ""
8243 crt_missing=
8245 for file in $crt_files; do
8247 ## If we're using gcc, try to determine it automatically by asking
8248 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8249 ## system-dependent default from above.]
8250 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8252 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8253 case "$crt_file" in
8254 */*)
8255 CRT_DIR=`$as_dirname -- "$crt_file" ||
8256 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8257 X"$crt_file" : 'X\(//\)[^/]' \| \
8258 X"$crt_file" : 'X\(//\)$' \| \
8259 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8260 $as_echo X"$crt_file" |
8261 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8262 s//\1/
8265 /^X\(\/\/\)[^/].*/{
8266 s//\1/
8269 /^X\(\/\/\)$/{
8270 s//\1/
8273 /^X\(\/\).*/{
8274 s//\1/
8277 s/.*/./; q'`
8279 esac
8282 crt_gcc=no
8284 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8285 done # $crt_files
8287 test "x$crt_missing" = x || \
8288 as_fn_error "Required file(s) not found:$crt_missing
8289 Try using the --with-crt-dir option." "$LINENO" 5
8291 fi # crt_files != ""
8295 case $opsys in
8296 netbsd | openbsd )
8297 if test -f $CRT_DIR/crti.o; then
8299 test -f $CRT_DIR/crtn.o || \
8300 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8302 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8303 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8306 esac
8309 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8310 pre_PKG_CONFIG_LIBS=$LIBS
8312 # Extract the first word of "pkg-config", so it can be a program name with args.
8313 set dummy pkg-config; ac_word=$2
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8315 $as_echo_n "checking for $ac_word... " >&6; }
8316 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8317 $as_echo_n "(cached) " >&6
8318 else
8319 case $PKG_CONFIG in
8320 [\\/]* | ?:[\\/]*)
8321 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8324 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8325 for as_dir in $PATH
8327 IFS=$as_save_IFS
8328 test -z "$as_dir" && as_dir=.
8329 for ac_exec_ext in '' $ac_executable_extensions; do
8330 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8331 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8332 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8333 break 2
8335 done
8336 done
8337 IFS=$as_save_IFS
8339 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8341 esac
8343 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8344 if test -n "$PKG_CONFIG"; then
8345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8346 $as_echo "$PKG_CONFIG" >&6; }
8347 else
8348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8349 $as_echo "no" >&6; }
8357 if test "${with_sound}" != "no"; then
8358 # Sound support for GNU/Linux and the free BSDs.
8359 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8360 do :
8361 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8362 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8363 eval as_val=\$$as_ac_Header
8364 if test "x$as_val" = x""yes; then :
8365 cat >>confdefs.h <<_ACEOF
8366 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8367 _ACEOF
8368 have_sound_header=yes
8371 done
8373 # Emulation library used on NetBSD.
8374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8375 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8376 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8377 $as_echo_n "(cached) " >&6
8378 else
8379 ac_check_lib_save_LIBS=$LIBS
8380 LIBS="-lossaudio $LIBS"
8381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8382 /* end confdefs.h. */
8384 /* Override any GCC internal prototype to avoid an error.
8385 Use char because int might match the return type of a GCC
8386 builtin and then its argument prototype would still apply. */
8387 #ifdef __cplusplus
8388 extern "C"
8389 #endif
8390 char _oss_ioctl ();
8392 main ()
8394 return _oss_ioctl ();
8396 return 0;
8398 _ACEOF
8399 if ac_fn_c_try_link "$LINENO"; then :
8400 ac_cv_lib_ossaudio__oss_ioctl=yes
8401 else
8402 ac_cv_lib_ossaudio__oss_ioctl=no
8404 rm -f core conftest.err conftest.$ac_objext \
8405 conftest$ac_exeext conftest.$ac_ext
8406 LIBS=$ac_check_lib_save_LIBS
8408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8409 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8410 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8411 LIBSOUND=-lossaudio
8412 else
8413 LIBSOUND=
8418 ALSA_REQUIRED=1.0.0
8419 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8421 succeeded=no
8423 if test "$PKG_CONFIG" = "no" ; then
8424 HAVE_ALSA=no
8425 else
8426 PKG_CONFIG_MIN_VERSION=0.9.0
8427 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8429 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8431 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8432 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8433 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8434 edit_cflags="
8435 s,///*,/,g
8436 s/^/ /
8437 s/ -I/ $isystem/g
8438 s/^ //
8440 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8441 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8443 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8444 succeeded=yes
8445 else
8446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8447 $as_echo "no" >&6; }
8448 ALSA_CFLAGS=""
8449 ALSA_LIBS=""
8450 ## If we have a custom action on failure, don't print errors, but
8451 ## do set a variable so people can do so.
8452 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
8458 else
8459 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8460 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8464 if test $succeeded = yes; then
8465 HAVE_ALSA=yes
8466 else
8467 HAVE_ALSA=no
8470 if test $HAVE_ALSA = yes; then
8471 SAVE_CFLAGS="$CFLAGS"
8472 SAVE_LIBS="$LIBS"
8473 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8474 LIBS="$ALSA_LIBS $LIBS"
8475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8476 /* end confdefs.h. */
8477 #include <asoundlib.h>
8479 main ()
8481 snd_lib_error_set_handler (0);
8483 return 0;
8485 _ACEOF
8486 if ac_fn_c_try_compile "$LINENO"; then :
8487 emacs_alsa_normal=yes
8488 else
8489 emacs_alsa_normal=no
8491 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8492 if test "$emacs_alsa_normal" != yes; then
8493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8494 /* end confdefs.h. */
8495 #include <alsa/asoundlib.h>
8497 main ()
8499 snd_lib_error_set_handler (0);
8501 return 0;
8503 _ACEOF
8504 if ac_fn_c_try_compile "$LINENO"; then :
8505 emacs_alsa_subdir=yes
8506 else
8507 emacs_alsa_subdir=no
8509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8510 if test "$emacs_alsa_subdir" != yes; then
8511 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8513 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8516 CFLAGS="$SAVE_CFLAGS"
8517 LIBS="$SAVE_LIBS"
8518 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8519 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8521 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8525 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8526 case "$opsys" in
8527 gnu-linux|freebsd|netbsd)
8529 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8532 esac
8541 for ac_header in $ac_header_list
8542 do :
8543 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8544 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8546 eval as_val=\$$as_ac_Header
8547 if test "x$as_val" = x""yes; then :
8548 cat >>confdefs.h <<_ACEOF
8549 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8550 _ACEOF
8554 done
8584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8585 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8587 /* end confdefs.h. */
8588 #include <sys/personality.h>
8590 main ()
8592 personality (PER_LINUX32)
8594 return 0;
8596 _ACEOF
8597 if ac_fn_c_try_compile "$LINENO"; then :
8598 emacs_cv_personality_linux32=yes
8599 else
8600 emacs_cv_personality_linux32=no
8602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8604 $as_echo "$emacs_cv_personality_linux32" >&6; }
8606 if test $emacs_cv_personality_linux32 = yes; then
8608 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8612 for ac_header in term.h
8613 do :
8614 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8615 if test "x$ac_cv_header_term_h" = x""yes; then :
8616 cat >>confdefs.h <<_ACEOF
8617 #define HAVE_TERM_H 1
8618 _ACEOF
8622 done
8624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8625 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8626 if test "${ac_cv_header_time+set}" = set; then :
8627 $as_echo_n "(cached) " >&6
8628 else
8629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8630 /* end confdefs.h. */
8631 #include <sys/types.h>
8632 #include <sys/time.h>
8633 #include <time.h>
8636 main ()
8638 if ((struct tm *) 0)
8639 return 0;
8641 return 0;
8643 _ACEOF
8644 if ac_fn_c_try_compile "$LINENO"; then :
8645 ac_cv_header_time=yes
8646 else
8647 ac_cv_header_time=no
8649 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8652 $as_echo "$ac_cv_header_time" >&6; }
8653 if test $ac_cv_header_time = yes; then
8655 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8659 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8660 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8661 ac_have_decl=1
8662 else
8663 ac_have_decl=0
8666 cat >>confdefs.h <<_ACEOF
8667 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8668 _ACEOF
8670 if test $ac_cv_have_decl_sys_siglist != yes; then
8671 # For Tru64, at least:
8672 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8673 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8674 ac_have_decl=1
8675 else
8676 ac_have_decl=0
8679 cat >>confdefs.h <<_ACEOF
8680 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8681 _ACEOF
8683 if test $ac_cv_have_decl___sys_siglist = yes; then
8685 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8690 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8691 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8692 $as_echo_n "(cached) " >&6
8693 else
8694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8695 /* end confdefs.h. */
8696 #include <sys/types.h>
8697 #include <sys/wait.h>
8698 #ifndef WEXITSTATUS
8699 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8700 #endif
8701 #ifndef WIFEXITED
8702 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8703 #endif
8706 main ()
8708 int s;
8709 wait (&s);
8710 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8712 return 0;
8714 _ACEOF
8715 if ac_fn_c_try_compile "$LINENO"; then :
8716 ac_cv_header_sys_wait_h=yes
8717 else
8718 ac_cv_header_sys_wait_h=no
8720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8723 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8724 if test $ac_cv_header_sys_wait_h = yes; then
8726 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8732 $as_echo_n "checking for speed_t... " >&6; }
8733 if test "${emacs_cv_speed_t+set}" = set; then :
8734 $as_echo_n "(cached) " >&6
8735 else
8736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8737 /* end confdefs.h. */
8738 #include <termios.h>
8740 main ()
8742 speed_t x = 1;
8744 return 0;
8746 _ACEOF
8747 if ac_fn_c_try_compile "$LINENO"; then :
8748 emacs_cv_speed_t=yes
8749 else
8750 emacs_cv_speed_t=no
8752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8755 $as_echo "$emacs_cv_speed_t" >&6; }
8756 if test $emacs_cv_speed_t = yes; then
8758 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8763 $as_echo_n "checking for struct exception... " >&6; }
8764 if test "${emacs_cv_struct_exception+set}" = set; then :
8765 $as_echo_n "(cached) " >&6
8766 else
8767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8768 /* end confdefs.h. */
8769 #include <math.h>
8771 main ()
8773 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8775 return 0;
8777 _ACEOF
8778 if ac_fn_c_try_compile "$LINENO"; then :
8779 emacs_cv_struct_exception=yes
8780 else
8781 emacs_cv_struct_exception=no
8783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8786 $as_echo "$emacs_cv_struct_exception" >&6; }
8787 HAVE_EXCEPTION=$emacs_cv_struct_exception
8788 if test $emacs_cv_struct_exception != yes || test $opsys = darwin; then
8790 $as_echo "#define NO_MATHERR 1" >>confdefs.h
8797 for ac_header in net/if.h
8798 do :
8799 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8800 #if HAVE_SYS_SOCKET_H
8801 #include <sys/socket.h>
8802 #endif
8804 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8805 cat >>confdefs.h <<_ACEOF
8806 #define HAVE_NET_IF_H 1
8807 _ACEOF
8811 done
8813 for ac_header in ifaddrs.h
8814 do :
8815 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8816 #if HAVE_SYS_SOCKET_H
8817 #include <sys/socket.h>
8818 #endif
8820 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8821 cat >>confdefs.h <<_ACEOF
8822 #define HAVE_IFADDRS_H 1
8823 _ACEOF
8827 done
8829 for ac_header in net/if_dl.h
8830 do :
8831 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8832 #if HAVE_SYS_SOCKET_H
8833 #include <sys/socket.h>
8834 #endif
8836 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8837 cat >>confdefs.h <<_ACEOF
8838 #define HAVE_NET_IF_DL_H 1
8839 _ACEOF
8843 done
8846 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8847 #if HAVE_SYS_SOCKET_H
8848 #include <sys/socket.h>
8849 #endif
8850 #if HAVE_NET_IF_H
8851 #include <net/if.h>
8852 #endif
8854 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8856 cat >>confdefs.h <<_ACEOF
8857 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8858 _ACEOF
8862 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8863 #if HAVE_SYS_SOCKET_H
8864 #include <sys/socket.h>
8865 #endif
8866 #if HAVE_NET_IF_H
8867 #include <net/if.h>
8868 #endif
8870 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8872 cat >>confdefs.h <<_ACEOF
8873 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8874 _ACEOF
8878 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8879 #if HAVE_SYS_SOCKET_H
8880 #include <sys/socket.h>
8881 #endif
8882 #if HAVE_NET_IF_H
8883 #include <net/if.h>
8884 #endif
8886 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
8888 cat >>confdefs.h <<_ACEOF
8889 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8890 _ACEOF
8894 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8895 #if HAVE_SYS_SOCKET_H
8896 #include <sys/socket.h>
8897 #endif
8898 #if HAVE_NET_IF_H
8899 #include <net/if.h>
8900 #endif
8902 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
8904 cat >>confdefs.h <<_ACEOF
8905 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8906 _ACEOF
8910 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8911 #if HAVE_SYS_SOCKET_H
8912 #include <sys/socket.h>
8913 #endif
8914 #if HAVE_NET_IF_H
8915 #include <net/if.h>
8916 #endif
8918 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
8920 cat >>confdefs.h <<_ACEOF
8921 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8922 _ACEOF
8926 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
8927 #if HAVE_SYS_SOCKET_H
8928 #include <sys/socket.h>
8929 #endif
8930 #if HAVE_NET_IF_H
8931 #include <net/if.h>
8932 #endif
8934 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
8936 cat >>confdefs.h <<_ACEOF
8937 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
8938 _ACEOF
8946 DEPFLAGS=
8947 MKDEPDIR=":"
8948 deps_frag=deps.mk
8949 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
8950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
8951 $as_echo_n "checking whether we are using GNU Make... " >&6; }
8952 HAVE_GNU_MAKE=no
8953 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
8954 if test "x$testval" != x; then
8955 HAVE_GNU_MAKE=yes
8956 else
8957 ac_enable_autodepend=no
8959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
8960 $as_echo "$HAVE_GNU_MAKE" >&6; }
8961 if test $HAVE_GNU_MAKE = yes; then
8962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
8963 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
8964 SAVE_CFLAGS="$CFLAGS"
8965 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
8966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8967 /* end confdefs.h. */
8970 main ()
8974 return 0;
8976 _ACEOF
8977 if ac_fn_c_try_compile "$LINENO"; then :
8979 else
8980 ac_enable_autodepend=no
8982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8983 CFLAGS="$SAVE_CFLAGS"
8984 test -f deps.d || ac_enable_autodepend=no
8985 rm -rf deps.d
8986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
8987 $as_echo "$ac_enable_autodepend" >&6; }
8989 if test $ac_enable_autodepend = yes; then
8990 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
8991 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
8992 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
8993 deps_frag=autodeps.mk
8996 deps_frag=$srcdir/src/$deps_frag
9002 lisp_frag=$srcdir/src/lisp.mk
9006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9007 $as_echo_n "checking for long file names... " >&6; }
9008 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9009 $as_echo_n "(cached) " >&6
9010 else
9011 ac_cv_sys_long_file_names=yes
9012 # Test for long file names in all the places we know might matter:
9013 # . the current directory, where building will happen
9014 # $prefix/lib where we will be installing things
9015 # $exec_prefix/lib likewise
9016 # $TMPDIR if set, where it might want to write temporary files
9017 # /tmp where it might want to write temporary files
9018 # /var/tmp likewise
9019 # /usr/tmp likewise
9020 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9021 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9022 # in the usual case where exec_prefix is '${prefix}'.
9023 case $ac_dir in #(
9024 . | /* | ?:[\\/]*) ;; #(
9025 *) continue;;
9026 esac
9027 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9028 ac_xdir=$ac_dir/cf$$
9029 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9030 ac_tf1=$ac_xdir/conftest9012345
9031 ac_tf2=$ac_xdir/conftest9012346
9032 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9033 ac_cv_sys_long_file_names=no
9034 rm -f -r "$ac_xdir" 2>/dev/null
9035 test $ac_cv_sys_long_file_names = no && break
9036 done
9038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9039 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9040 if test $ac_cv_sys_long_file_names = yes; then
9042 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9047 #### Choose a window system.
9049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9050 $as_echo_n "checking for X... " >&6; }
9053 # Check whether --with-x was given.
9054 if test "${with_x+set}" = set; then :
9055 withval=$with_x;
9058 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9059 if test "x$with_x" = xno; then
9060 # The user explicitly disabled X.
9061 have_x=disabled
9062 else
9063 case $x_includes,$x_libraries in #(
9064 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9065 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9066 $as_echo_n "(cached) " >&6
9067 else
9068 # One or both of the vars are not set, and there is no cached value.
9069 ac_x_includes=no ac_x_libraries=no
9070 rm -f -r conftest.dir
9071 if mkdir conftest.dir; then
9072 cd conftest.dir
9073 cat >Imakefile <<'_ACEOF'
9074 incroot:
9075 @echo incroot='${INCROOT}'
9076 usrlibdir:
9077 @echo usrlibdir='${USRLIBDIR}'
9078 libdir:
9079 @echo libdir='${LIBDIR}'
9080 _ACEOF
9081 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9082 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9083 for ac_var in incroot usrlibdir libdir; do
9084 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9085 done
9086 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9087 for ac_extension in a so sl dylib la dll; do
9088 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9089 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9090 ac_im_usrlibdir=$ac_im_libdir; break
9092 done
9093 # Screen out bogus values from the imake configuration. They are
9094 # bogus both because they are the default anyway, and because
9095 # using them would break gcc on systems where it needs fixed includes.
9096 case $ac_im_incroot in
9097 /usr/include) ac_x_includes= ;;
9098 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9099 esac
9100 case $ac_im_usrlibdir in
9101 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9102 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9103 esac
9105 cd ..
9106 rm -f -r conftest.dir
9109 # Standard set of common directories for X headers.
9110 # Check X11 before X11Rn because it is often a symlink to the current release.
9111 ac_x_header_dirs='
9112 /usr/X11/include
9113 /usr/X11R7/include
9114 /usr/X11R6/include
9115 /usr/X11R5/include
9116 /usr/X11R4/include
9118 /usr/include/X11
9119 /usr/include/X11R7
9120 /usr/include/X11R6
9121 /usr/include/X11R5
9122 /usr/include/X11R4
9124 /usr/local/X11/include
9125 /usr/local/X11R7/include
9126 /usr/local/X11R6/include
9127 /usr/local/X11R5/include
9128 /usr/local/X11R4/include
9130 /usr/local/include/X11
9131 /usr/local/include/X11R7
9132 /usr/local/include/X11R6
9133 /usr/local/include/X11R5
9134 /usr/local/include/X11R4
9136 /usr/X386/include
9137 /usr/x386/include
9138 /usr/XFree86/include/X11
9140 /usr/include
9141 /usr/local/include
9142 /usr/unsupported/include
9143 /usr/athena/include
9144 /usr/local/x11r5/include
9145 /usr/lpp/Xamples/include
9147 /usr/openwin/include
9148 /usr/openwin/share/include'
9150 if test "$ac_x_includes" = no; then
9151 # Guess where to find include files, by looking for Xlib.h.
9152 # First, try using that file with no special directory specified.
9153 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9154 /* end confdefs.h. */
9155 #include <X11/Xlib.h>
9156 _ACEOF
9157 if ac_fn_c_try_cpp "$LINENO"; then :
9158 # We can compile using X headers with no special include directory.
9159 ac_x_includes=
9160 else
9161 for ac_dir in $ac_x_header_dirs; do
9162 if test -r "$ac_dir/X11/Xlib.h"; then
9163 ac_x_includes=$ac_dir
9164 break
9166 done
9168 rm -f conftest.err conftest.$ac_ext
9169 fi # $ac_x_includes = no
9171 if test "$ac_x_libraries" = no; then
9172 # Check for the libraries.
9173 # See if we find them without any special options.
9174 # Don't add to $LIBS permanently.
9175 ac_save_LIBS=$LIBS
9176 LIBS="-lX11 $LIBS"
9177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9178 /* end confdefs.h. */
9179 #include <X11/Xlib.h>
9181 main ()
9183 XrmInitialize ()
9185 return 0;
9187 _ACEOF
9188 if ac_fn_c_try_link "$LINENO"; then :
9189 LIBS=$ac_save_LIBS
9190 # We can link X programs with no special library path.
9191 ac_x_libraries=
9192 else
9193 LIBS=$ac_save_LIBS
9194 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9196 # Don't even attempt the hair of trying to link an X program!
9197 for ac_extension in a so sl dylib la dll; do
9198 if test -r "$ac_dir/libX11.$ac_extension"; then
9199 ac_x_libraries=$ac_dir
9200 break 2
9202 done
9203 done
9205 rm -f core conftest.err conftest.$ac_objext \
9206 conftest$ac_exeext conftest.$ac_ext
9207 fi # $ac_x_libraries = no
9209 case $ac_x_includes,$ac_x_libraries in #(
9210 no,* | *,no | *\'*)
9211 # Didn't find X, or a directory has "'" in its name.
9212 ac_cv_have_x="have_x=no";; #(
9214 # Record where we found X for the cache.
9215 ac_cv_have_x="have_x=yes\
9216 ac_x_includes='$ac_x_includes'\
9217 ac_x_libraries='$ac_x_libraries'"
9218 esac
9220 ;; #(
9221 *) have_x=yes;;
9222 esac
9223 eval "$ac_cv_have_x"
9224 fi # $with_x != no
9226 if test "$have_x" != yes; then
9227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9228 $as_echo "$have_x" >&6; }
9229 no_x=yes
9230 else
9231 # If each of the values was on the command line, it overrides each guess.
9232 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9233 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9234 # Update the cache value to reflect the command line values.
9235 ac_cv_have_x="have_x=yes\
9236 ac_x_includes='$x_includes'\
9237 ac_x_libraries='$x_libraries'"
9238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9239 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9242 if test "$no_x" = yes; then
9243 window_system=none
9244 else
9245 window_system=x11
9248 LD_SWITCH_X_SITE_RPATH=
9249 if test "${x_libraries}" != NONE; then
9250 if test -n "${x_libraries}"; then
9251 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9252 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9254 x_default_search_path=""
9255 x_search_path=${x_libraries}
9256 if test -z "${x_search_path}"; then
9257 x_search_path=/usr/lib
9259 for x_library in `echo ${x_search_path}: | \
9260 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9261 x_search_path="\
9262 ${x_library}/X11/%L/%T/%N%C%S:\
9263 ${x_library}/X11/%l/%T/%N%C%S:\
9264 ${x_library}/X11/%T/%N%C%S:\
9265 ${x_library}/X11/%L/%T/%N%S:\
9266 ${x_library}/X11/%l/%T/%N%S:\
9267 ${x_library}/X11/%T/%N%S"
9268 if test x"${x_default_search_path}" = x; then
9269 x_default_search_path=${x_search_path}
9270 else
9271 x_default_search_path="${x_search_path}:${x_default_search_path}"
9273 done
9277 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9278 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9281 if test x"${x_includes}" = x; then
9282 bitmapdir=/usr/include/X11/bitmaps
9283 else
9284 # accumulate include directories that have X11 bitmap subdirectories
9285 bmd_acc="dummyval"
9286 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9287 if test -d "${bmd}/X11/bitmaps"; then
9288 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9290 if test -d "${bmd}/bitmaps"; then
9291 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9293 done
9294 if test ${bmd_acc} != "dummyval"; then
9295 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9299 HAVE_NS=no
9300 NS_IMPL_COCOA=no
9301 NS_IMPL_GNUSTEP=no
9302 tmp_CPPFLAGS="$CPPFLAGS"
9303 tmp_CFLAGS="$CFLAGS"
9304 CPPFLAGS="$CPPFLAGS -x objective-c"
9305 CFLAGS="$CFLAGS -x objective-c"
9306 TEMACS_LDFLAGS2="\${LDFLAGS}"
9307 GNU_OBJC_CFLAGS=
9308 if test "${with_ns}" != no; then
9309 if test "${opsys}" = darwin; then
9310 NS_IMPL_COCOA=yes
9311 ns_appdir=`pwd`/nextstep/Emacs.app
9312 ns_appbindir=${ns_appdir}/Contents/MacOS
9313 ns_appresdir=${ns_appdir}/Contents/Resources
9314 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9315 elif test -f $GNUSTEP_CONFIG_FILE; then
9316 NS_IMPL_GNUSTEP=yes
9317 ns_appdir=`pwd`/nextstep/Emacs.app
9318 ns_appbindir=${ns_appdir}
9319 ns_appresdir=${ns_appdir}/Resources
9320 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9321 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9322 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9323 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9324 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9325 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9326 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9327 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9328 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9329 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9330 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9331 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9332 LIB_STANDARD=
9333 START_FILES=
9334 TEMACS_LDFLAGS2=
9335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9336 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9337 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9338 $as_echo_n "(cached) " >&6
9339 else
9340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9341 /* end confdefs.h. */
9342 #include <GNUstepBase/GSConfig.h>
9344 main ()
9346 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9348 #else
9349 fail;
9350 #endif
9352 return 0;
9354 _ACEOF
9355 if ac_fn_c_try_compile "$LINENO"; then :
9356 emacs_cv_objc_exceptions=yes
9357 else
9358 emacs_cv_objc_exceptions=no
9360 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9363 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9364 if test $emacs_cv_objc_exceptions = yes; then
9366 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9368 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9372 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9374 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9375 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9376 HAVE_NS=yes
9377 else
9378 as_fn_error "\`--with-ns' was specified, but the include
9379 files are missing or cannot be compiled." "$LINENO" 5
9383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9384 /* end confdefs.h. */
9385 #include <Foundation/NSObjCRuntime.h>
9387 main ()
9389 NSInteger i;
9391 return 0;
9393 _ACEOF
9394 if ac_fn_c_try_compile "$LINENO"; then :
9395 ns_have_nsinteger=yes
9396 else
9397 ns_have_nsinteger=no
9399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9400 if test $ns_have_nsinteger = yes; then
9402 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9408 INSTALL_ARCH_INDEP_EXTRA=install-etc
9409 ns_self_contained=no
9410 ns_frag=/dev/null
9411 NS_OBJ=
9412 NS_OBJC_OBJ=
9413 if test "${HAVE_NS}" = yes; then
9414 if test "$with_toolkit_scroll_bars" = "no"; then
9415 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9418 window_system=nextstep
9419 with_xft=no
9420 # set up packaging dirs
9421 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9422 ns_self_contained=yes
9423 prefix=${ns_appresdir}
9424 exec_prefix=${ns_appbindir}
9425 libexecdir="\${ns_appbindir}/libexec"
9426 archlibdir="\${ns_appbindir}/libexec"
9427 docdir="\${ns_appresdir}/etc"
9428 etcdir="\${ns_appresdir}/etc"
9429 infodir="\${ns_appresdir}/info"
9430 mandir="\${ns_appresdir}/man"
9431 lispdir="\${ns_appresdir}/lisp"
9432 leimdir="\${ns_appresdir}/leim"
9433 INSTALL_ARCH_INDEP_EXTRA=
9435 ns_frag=$srcdir/src/ns.mk
9436 NS_OBJ="fontset.o fringe.o image.o"
9437 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9439 CFLAGS="$tmp_CFLAGS"
9440 CPPFLAGS="$tmp_CPPFLAGS"
9448 case "${window_system}" in
9449 x11 )
9450 HAVE_X_WINDOWS=yes
9451 HAVE_X11=yes
9452 case "${with_x_toolkit}" in
9453 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9454 motif ) USE_X_TOOLKIT=MOTIF ;;
9455 gtk ) with_gtk=yes
9456 USE_X_TOOLKIT=none ;;
9457 gtk3 ) with_gtk3=yes
9458 USE_X_TOOLKIT=none ;;
9459 no ) USE_X_TOOLKIT=none ;;
9460 * ) USE_X_TOOLKIT=maybe ;;
9461 esac
9463 nextstep | none )
9464 HAVE_X_WINDOWS=no
9465 HAVE_X11=no
9466 USE_X_TOOLKIT=none
9468 esac
9470 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9471 # Extract the first word of "X", so it can be a program name with args.
9472 set dummy X; ac_word=$2
9473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9474 $as_echo_n "checking for $ac_word... " >&6; }
9475 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9476 $as_echo_n "(cached) " >&6
9477 else
9478 if test -n "$HAVE_XSERVER"; then
9479 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9480 else
9481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9482 for as_dir in $PATH
9484 IFS=$as_save_IFS
9485 test -z "$as_dir" && as_dir=.
9486 for ac_exec_ext in '' $ac_executable_extensions; do
9487 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9488 ac_cv_prog_HAVE_XSERVER="true"
9489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9490 break 2
9492 done
9493 done
9494 IFS=$as_save_IFS
9496 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9499 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9500 if test -n "$HAVE_XSERVER"; then
9501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9502 $as_echo "$HAVE_XSERVER" >&6; }
9503 else
9504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9505 $as_echo "no" >&6; }
9509 if test "$HAVE_XSERVER" = true ||
9510 test -n "$DISPLAY" ||
9511 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9512 as_fn_error "You seem to be running X, but no X development libraries
9513 were found. You should install the relevant development files for X
9514 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9515 sure you have development files for image handling, i.e.
9516 tiff, gif, jpeg, png and xpm.
9517 If you are sure you want Emacs compiled without X window support, pass
9518 --without-x
9519 to configure." "$LINENO" 5
9523 ### If we're using X11, we should use the X menu package.
9524 HAVE_MENUS=no
9525 case ${HAVE_X11} in
9526 yes ) HAVE_MENUS=yes ;;
9527 esac
9529 # Does the opsystem file prohibit the use of the GNU malloc?
9530 # Assume not, until told otherwise.
9531 GNU_MALLOC=yes
9533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9534 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9535 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9536 $as_echo_n "(cached) " >&6
9537 else
9538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9539 /* end confdefs.h. */
9540 #include <malloc.h>
9541 static void hook (void) {}
9543 main ()
9545 malloc_set_state (malloc_get_state ());
9546 __after_morecore_hook = hook;
9547 __malloc_initialize_hook = hook;
9549 return 0;
9551 _ACEOF
9552 if ac_fn_c_try_link "$LINENO"; then :
9553 emacs_cv_var_doug_lea_malloc=yes
9554 else
9555 emacs_cv_var_doug_lea_malloc=no
9557 rm -f core conftest.err conftest.$ac_objext \
9558 conftest$ac_exeext conftest.$ac_ext
9560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9561 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9562 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9565 system_malloc=no
9566 case "$opsys" in
9567 ## darwin ld insists on the use of malloc routines in the System framework.
9568 darwin|sol2-10) system_malloc=yes ;;
9569 esac
9571 if test "${system_malloc}" = "yes"; then
9573 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9575 GNU_MALLOC=no
9576 GNU_MALLOC_reason="
9577 (The GNU allocators don't work with this system configuration.)"
9578 GMALLOC_OBJ=
9579 VMLIMIT_OBJ=
9580 else
9581 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9582 VMLIMIT_OBJ=vm-limit.o
9587 if test "$doug_lea_malloc" = "yes" ; then
9588 if test "$GNU_MALLOC" = yes ; then
9589 GNU_MALLOC_reason="
9590 (Using Doug Lea's new malloc from the GNU C Library.)"
9593 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9596 ## Use mmap directly for allocating larger buffers.
9597 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9598 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9599 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9600 case "$opsys" in
9601 gnu*) REL_ALLOC=no ;;
9602 esac
9605 if test x"${REL_ALLOC}" = x; then
9606 REL_ALLOC=${GNU_MALLOC}
9609 use_mmap_for_buffers=no
9610 case "$opsys" in
9611 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9612 esac
9621 for ac_func in getpagesize
9622 do :
9623 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9624 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9625 cat >>confdefs.h <<_ACEOF
9626 #define HAVE_GETPAGESIZE 1
9627 _ACEOF
9630 done
9632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9633 $as_echo_n "checking for working mmap... " >&6; }
9634 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9635 $as_echo_n "(cached) " >&6
9636 else
9637 if test "$cross_compiling" = yes; then :
9638 ac_cv_func_mmap_fixed_mapped=no
9639 else
9640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9641 /* end confdefs.h. */
9642 $ac_includes_default
9643 /* malloc might have been renamed as rpl_malloc. */
9644 #undef malloc
9646 /* Thanks to Mike Haertel and Jim Avera for this test.
9647 Here is a matrix of mmap possibilities:
9648 mmap private not fixed
9649 mmap private fixed at somewhere currently unmapped
9650 mmap private fixed at somewhere already mapped
9651 mmap shared not fixed
9652 mmap shared fixed at somewhere currently unmapped
9653 mmap shared fixed at somewhere already mapped
9654 For private mappings, we should verify that changes cannot be read()
9655 back from the file, nor mmap's back from the file at a different
9656 address. (There have been systems where private was not correctly
9657 implemented like the infamous i386 svr4.0, and systems where the
9658 VM page cache was not coherent with the file system buffer cache
9659 like early versions of FreeBSD and possibly contemporary NetBSD.)
9660 For shared mappings, we should conversely verify that changes get
9661 propagated back to all the places they're supposed to be.
9663 Grep wants private fixed already mapped.
9664 The main things grep needs to know about mmap are:
9665 * does it exist and is it safe to write into the mmap'd area
9666 * how to use it (BSD variants) */
9668 #include <fcntl.h>
9669 #include <sys/mman.h>
9671 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9672 char *malloc ();
9673 #endif
9675 /* This mess was copied from the GNU getpagesize.h. */
9676 #ifndef HAVE_GETPAGESIZE
9677 # ifdef _SC_PAGESIZE
9678 # define getpagesize() sysconf(_SC_PAGESIZE)
9679 # else /* no _SC_PAGESIZE */
9680 # ifdef HAVE_SYS_PARAM_H
9681 # include <sys/param.h>
9682 # ifdef EXEC_PAGESIZE
9683 # define getpagesize() EXEC_PAGESIZE
9684 # else /* no EXEC_PAGESIZE */
9685 # ifdef NBPG
9686 # define getpagesize() NBPG * CLSIZE
9687 # ifndef CLSIZE
9688 # define CLSIZE 1
9689 # endif /* no CLSIZE */
9690 # else /* no NBPG */
9691 # ifdef NBPC
9692 # define getpagesize() NBPC
9693 # else /* no NBPC */
9694 # ifdef PAGESIZE
9695 # define getpagesize() PAGESIZE
9696 # endif /* PAGESIZE */
9697 # endif /* no NBPC */
9698 # endif /* no NBPG */
9699 # endif /* no EXEC_PAGESIZE */
9700 # else /* no HAVE_SYS_PARAM_H */
9701 # define getpagesize() 8192 /* punt totally */
9702 # endif /* no HAVE_SYS_PARAM_H */
9703 # endif /* no _SC_PAGESIZE */
9705 #endif /* no HAVE_GETPAGESIZE */
9708 main ()
9710 char *data, *data2, *data3;
9711 const char *cdata2;
9712 int i, pagesize;
9713 int fd, fd2;
9715 pagesize = getpagesize ();
9717 /* First, make a file with some known garbage in it. */
9718 data = (char *) malloc (pagesize);
9719 if (!data)
9720 return 1;
9721 for (i = 0; i < pagesize; ++i)
9722 *(data + i) = rand ();
9723 umask (0);
9724 fd = creat ("conftest.mmap", 0600);
9725 if (fd < 0)
9726 return 2;
9727 if (write (fd, data, pagesize) != pagesize)
9728 return 3;
9729 close (fd);
9731 /* Next, check that the tail of a page is zero-filled. File must have
9732 non-zero length, otherwise we risk SIGBUS for entire page. */
9733 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9734 if (fd2 < 0)
9735 return 4;
9736 cdata2 = "";
9737 if (write (fd2, cdata2, 1) != 1)
9738 return 5;
9739 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9740 if (data2 == MAP_FAILED)
9741 return 6;
9742 for (i = 0; i < pagesize; ++i)
9743 if (*(data2 + i))
9744 return 7;
9745 close (fd2);
9746 if (munmap (data2, pagesize))
9747 return 8;
9749 /* Next, try to mmap the file at a fixed address which already has
9750 something else allocated at it. If we can, also make sure that
9751 we see the same garbage. */
9752 fd = open ("conftest.mmap", O_RDWR);
9753 if (fd < 0)
9754 return 9;
9755 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9756 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9757 return 10;
9758 for (i = 0; i < pagesize; ++i)
9759 if (*(data + i) != *(data2 + i))
9760 return 11;
9762 /* Finally, make sure that changes to the mapped area do not
9763 percolate back to the file as seen by read(). (This is a bug on
9764 some variants of i386 svr4.0.) */
9765 for (i = 0; i < pagesize; ++i)
9766 *(data2 + i) = *(data2 + i) + 1;
9767 data3 = (char *) malloc (pagesize);
9768 if (!data3)
9769 return 12;
9770 if (read (fd, data3, pagesize) != pagesize)
9771 return 13;
9772 for (i = 0; i < pagesize; ++i)
9773 if (*(data + i) != *(data3 + i))
9774 return 14;
9775 close (fd);
9776 return 0;
9778 _ACEOF
9779 if ac_fn_c_try_run "$LINENO"; then :
9780 ac_cv_func_mmap_fixed_mapped=yes
9781 else
9782 ac_cv_func_mmap_fixed_mapped=no
9784 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9785 conftest.$ac_objext conftest.beam conftest.$ac_ext
9789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9790 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9791 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9793 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9796 rm -f conftest.mmap conftest.txt
9798 if test $use_mmap_for_buffers = yes; then
9800 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9802 REL_ALLOC=no
9805 LIBS="$LIBS_SYSTEM $LIBS"
9807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9808 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
9809 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
9810 $as_echo_n "(cached) " >&6
9811 else
9812 ac_check_lib_save_LIBS=$LIBS
9813 LIBS="-ldnet $LIBS"
9814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9815 /* end confdefs.h. */
9817 /* Override any GCC internal prototype to avoid an error.
9818 Use char because int might match the return type of a GCC
9819 builtin and then its argument prototype would still apply. */
9820 #ifdef __cplusplus
9821 extern "C"
9822 #endif
9823 char dnet_ntoa ();
9825 main ()
9827 return dnet_ntoa ();
9829 return 0;
9831 _ACEOF
9832 if ac_fn_c_try_link "$LINENO"; then :
9833 ac_cv_lib_dnet_dnet_ntoa=yes
9834 else
9835 ac_cv_lib_dnet_dnet_ntoa=no
9837 rm -f core conftest.err conftest.$ac_objext \
9838 conftest$ac_exeext conftest.$ac_ext
9839 LIBS=$ac_check_lib_save_LIBS
9841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9842 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
9843 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
9844 cat >>confdefs.h <<_ACEOF
9845 #define HAVE_LIBDNET 1
9846 _ACEOF
9848 LIBS="-ldnet $LIBS"
9853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
9854 $as_echo_n "checking for main in -lXbsd... " >&6; }
9855 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
9856 $as_echo_n "(cached) " >&6
9857 else
9858 ac_check_lib_save_LIBS=$LIBS
9859 LIBS="-lXbsd $LIBS"
9860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9861 /* end confdefs.h. */
9865 main ()
9867 return main ();
9869 return 0;
9871 _ACEOF
9872 if ac_fn_c_try_link "$LINENO"; then :
9873 ac_cv_lib_Xbsd_main=yes
9874 else
9875 ac_cv_lib_Xbsd_main=no
9877 rm -f core conftest.err conftest.$ac_objext \
9878 conftest$ac_exeext conftest.$ac_ext
9879 LIBS=$ac_check_lib_save_LIBS
9881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
9882 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
9883 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
9884 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9888 LIB_PTHREAD=
9892 if test "$ac_cv_header_pthread_h"; then
9893 if test "$GMALLOC_OBJ" = gmalloc.o; then
9894 emacs_pthread_function=pthread_atfork
9895 else
9896 emacs_pthread_function=pthread_self
9898 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
9899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
9900 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
9901 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
9902 $as_echo_n "(cached) " >&6
9903 else
9904 ac_check_lib_save_LIBS=$LIBS
9905 LIBS="-lpthread $LIBS"
9906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9907 /* end confdefs.h. */
9909 /* Override any GCC internal prototype to avoid an error.
9910 Use char because int might match the return type of a GCC
9911 builtin and then its argument prototype would still apply. */
9912 #ifdef __cplusplus
9913 extern "C"
9914 #endif
9915 char $emacs_pthread_function ();
9917 main ()
9919 return $emacs_pthread_function ();
9921 return 0;
9923 _ACEOF
9924 if ac_fn_c_try_link "$LINENO"; then :
9925 eval "$as_ac_Lib=yes"
9926 else
9927 eval "$as_ac_Lib=no"
9929 rm -f core conftest.err conftest.$ac_objext \
9930 conftest$ac_exeext conftest.$ac_ext
9931 LIBS=$ac_check_lib_save_LIBS
9933 eval ac_res=\$$as_ac_Lib
9934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9935 $as_echo "$ac_res" >&6; }
9936 eval as_val=\$$as_ac_Lib
9937 if test "x$as_val" = x""yes; then :
9938 HAVE_PTHREAD=yes
9942 if test "$HAVE_PTHREAD" = yes; then
9943 case "${canonical}" in
9944 *-hpux*) ;;
9945 *) LIB_PTHREAD="-lpthread"
9946 LIBS="$LIB_PTHREAD $LIBS" ;;
9947 esac
9949 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
9955 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
9956 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
9957 $as_echo_n "(cached) " >&6
9958 else
9959 ac_check_lib_save_LIBS=$LIBS
9960 LIBS="-lpthreads $LIBS"
9961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9962 /* end confdefs.h. */
9964 /* Override any GCC internal prototype to avoid an error.
9965 Use char because int might match the return type of a GCC
9966 builtin and then its argument prototype would still apply. */
9967 #ifdef __cplusplus
9968 extern "C"
9969 #endif
9970 char cma_open ();
9972 main ()
9974 return cma_open ();
9976 return 0;
9978 _ACEOF
9979 if ac_fn_c_try_link "$LINENO"; then :
9980 ac_cv_lib_pthreads_cma_open=yes
9981 else
9982 ac_cv_lib_pthreads_cma_open=no
9984 rm -f core conftest.err conftest.$ac_objext \
9985 conftest$ac_exeext conftest.$ac_ext
9986 LIBS=$ac_check_lib_save_LIBS
9988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
9989 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
9990 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
9991 cat >>confdefs.h <<_ACEOF
9992 #define HAVE_LIBPTHREADS 1
9993 _ACEOF
9995 LIBS="-lpthreads $LIBS"
10000 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10001 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10002 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10003 ## added to LIBS in configure would never contain the pthreads part,
10004 ## but the value used in Makefiles might. FIXME?
10006 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10007 ## be harmless on older versions of X where it happens to exist.
10008 test "$opsys" = "aix4-2" && \
10009 test $ac_cv_lib_pthreads_cma_open = yes && \
10010 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10013 case ${host_os} in
10014 aix*)
10015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10016 $as_echo_n "checking for -bbigtoc option... " >&6; }
10017 if test "${gdb_cv_bigtoc+set}" = set; then :
10018 $as_echo_n "(cached) " >&6
10019 else
10021 case $GCC in
10022 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10023 *) gdb_cv_bigtoc=-bbigtoc ;;
10024 esac
10026 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10028 /* end confdefs.h. */
10031 main ()
10033 int i;
10035 return 0;
10037 _ACEOF
10038 if ac_fn_c_try_link "$LINENO"; then :
10040 else
10041 gdb_cv_bigtoc=
10043 rm -f core conftest.err conftest.$ac_objext \
10044 conftest$ac_exeext conftest.$ac_ext
10047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10048 $as_echo "$gdb_cv_bigtoc" >&6; }
10050 esac
10052 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10053 # used for the tests that follow. We set them back to REAL_CFLAGS and
10054 # REAL_CPPFLAGS later on.
10056 REAL_CFLAGS="$CFLAGS"
10057 REAL_CPPFLAGS="$CPPFLAGS"
10059 if test "${HAVE_X11}" = "yes"; then
10060 DEFS="$C_SWITCH_X_SITE $DEFS"
10061 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10062 LIBS="-lX11 $LIBS"
10063 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10064 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10066 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10067 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10068 # but it's more convenient here to set LD_RUN_PATH since this
10069 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10070 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10071 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10072 export LD_RUN_PATH
10075 if test "${opsys}" = "gnu-linux"; then
10076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10077 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10079 /* end confdefs.h. */
10082 main ()
10084 XOpenDisplay ("foo");
10086 return 0;
10088 _ACEOF
10089 if ac_fn_c_try_link "$LINENO"; then :
10090 xgnu_linux_first_failure=no
10091 else
10092 xgnu_linux_first_failure=yes
10094 rm -f core conftest.err conftest.$ac_objext \
10095 conftest$ac_exeext conftest.$ac_ext
10096 if test "${xgnu_linux_first_failure}" = "yes"; then
10097 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10098 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10099 OLD_CPPFLAGS="$CPPFLAGS"
10100 OLD_LIBS="$LIBS"
10101 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10102 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10103 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10104 LIBS="$LIBS -b i486-linuxaout"
10105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10106 /* end confdefs.h. */
10109 main ()
10111 XOpenDisplay ("foo");
10113 return 0;
10115 _ACEOF
10116 if ac_fn_c_try_link "$LINENO"; then :
10117 xgnu_linux_second_failure=no
10118 else
10119 xgnu_linux_second_failure=yes
10121 rm -f core conftest.err conftest.$ac_objext \
10122 conftest$ac_exeext conftest.$ac_ext
10123 if test "${xgnu_linux_second_failure}" = "yes"; then
10124 # If we get the same failure with -b, there is no use adding -b.
10125 # So take it out. This plays safe.
10126 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10127 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10128 CPPFLAGS="$OLD_CPPFLAGS"
10129 LIBS="$OLD_LIBS"
10130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10131 $as_echo "no" >&6; }
10132 else
10133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10134 $as_echo "yes" >&6; }
10136 else
10137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10138 $as_echo "no" >&6; }
10142 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10143 # header files included from there.
10144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10145 $as_echo_n "checking for Xkb... " >&6; }
10146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10147 /* end confdefs.h. */
10148 #include <X11/Xlib.h>
10149 #include <X11/XKBlib.h>
10151 main ()
10153 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10155 return 0;
10157 _ACEOF
10158 if ac_fn_c_try_link "$LINENO"; then :
10159 emacs_xkb=yes
10160 else
10161 emacs_xkb=no
10163 rm -f core conftest.err conftest.$ac_objext \
10164 conftest$ac_exeext conftest.$ac_ext
10165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10166 $as_echo "$emacs_xkb" >&6; }
10167 if test $emacs_xkb = yes; then
10169 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10173 for ac_func in XrmSetDatabase XScreenResourceString \
10174 XScreenNumberOfScreen
10175 do :
10176 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10177 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10178 eval as_val=\$$as_ac_var
10179 if test "x$as_val" = x""yes; then :
10180 cat >>confdefs.h <<_ACEOF
10181 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10182 _ACEOF
10185 done
10189 if test "${window_system}" = "x11"; then
10190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10191 $as_echo_n "checking X11 version 6... " >&6; }
10192 if test "${emacs_cv_x11_version_6+set}" = set; then :
10193 $as_echo_n "(cached) " >&6
10194 else
10195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10196 /* end confdefs.h. */
10197 #include <X11/Xlib.h>
10199 main ()
10201 #if XlibSpecificationRelease < 6
10202 fail;
10203 #endif
10206 return 0;
10208 _ACEOF
10209 if ac_fn_c_try_link "$LINENO"; then :
10210 emacs_cv_x11_version_6=yes
10211 else
10212 emacs_cv_x11_version_6=no
10214 rm -f core conftest.err conftest.$ac_objext \
10215 conftest$ac_exeext conftest.$ac_ext
10218 if test $emacs_cv_x11_version_6 = yes; then
10219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10220 $as_echo "6 or newer" >&6; }
10222 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10225 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10227 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10228 ## XIM support.
10229 case "$opsys" in
10230 sol2-*) : ;;
10232 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10235 esac
10236 else
10237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10238 $as_echo "before 6" >&6; }
10243 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10244 HAVE_RSVG=no
10245 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10246 if test "${with_rsvg}" != "no"; then
10247 RSVG_REQUIRED=2.11.0
10248 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10251 succeeded=no
10253 if test "$PKG_CONFIG" = "no" ; then
10255 else
10256 PKG_CONFIG_MIN_VERSION=0.9.0
10257 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10259 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10261 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10262 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10263 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10264 edit_cflags="
10265 s,///*,/,g
10266 s/^/ /
10267 s/ -I/ $isystem/g
10268 s/^ //
10270 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10271 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10273 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10274 succeeded=yes
10275 else
10276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10277 $as_echo "no" >&6; }
10278 RSVG_CFLAGS=""
10279 RSVG_LIBS=""
10280 ## If we have a custom action on failure, don't print errors, but
10281 ## do set a variable so people can do so.
10282 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10288 else
10289 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10290 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10294 if test $succeeded = yes; then
10295 HAVE_RSVG=yes
10296 else
10303 if test $HAVE_RSVG = yes; then
10305 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10307 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10308 LIBS="$RSVG_LIBS $LIBS"
10313 HAVE_IMAGEMAGICK=no
10314 if test "${HAVE_X11}" = "yes"; then
10315 if test "${with_imagemagick}" != "no"; then
10316 ## 6.2.8 is the earliest version known to work, but earlier versions
10317 ## might work - let us know if you find one.
10318 ## 6.0.7 does not work. See bug#7955.
10319 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10321 succeeded=no
10323 if test "$PKG_CONFIG" = "no" ; then
10325 else
10326 PKG_CONFIG_MIN_VERSION=0.9.0
10327 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10329 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10331 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10332 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10333 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10334 edit_cflags="
10335 s,///*,/,g
10336 s/^/ /
10337 s/ -I/ $isystem/g
10338 s/^ //
10340 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10341 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10343 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10344 succeeded=yes
10345 else
10346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10347 $as_echo "no" >&6; }
10348 IMAGEMAGICK_CFLAGS=""
10349 IMAGEMAGICK_LIBS=""
10350 ## If we have a custom action on failure, don't print errors, but
10351 ## do set a variable so people can do so.
10352 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10358 else
10359 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10360 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10364 if test $succeeded = yes; then
10365 HAVE_IMAGEMAGICK=yes
10366 else
10373 if test $HAVE_IMAGEMAGICK = yes; then
10375 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10377 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10378 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10379 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10380 do :
10381 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10382 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10383 eval as_val=\$$as_ac_var
10384 if test "x$as_val" = x""yes; then :
10385 cat >>confdefs.h <<_ACEOF
10386 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10387 _ACEOF
10390 done
10397 HAVE_GTK=no
10398 GTK_OBJ=
10399 if test "${with_gtk3}" = "yes"; then
10400 GLIB_REQUIRED=2.28
10401 GTK_REQUIRED=3.0
10402 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10405 succeeded=no
10407 if test "$PKG_CONFIG" = "no" ; then
10408 pkg_check_gtk=no
10409 else
10410 PKG_CONFIG_MIN_VERSION=0.9.0
10411 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10413 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10415 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10416 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10417 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10418 edit_cflags="
10419 s,///*,/,g
10420 s/^/ /
10421 s/ -I/ $isystem/g
10422 s/^ //
10424 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10425 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10427 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10428 succeeded=yes
10429 else
10430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10431 $as_echo "no" >&6; }
10432 GTK_CFLAGS=""
10433 GTK_LIBS=""
10434 ## If we have a custom action on failure, don't print errors, but
10435 ## do set a variable so people can do so.
10436 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10442 else
10443 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10444 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10448 if test $succeeded = yes; then
10449 pkg_check_gtk=yes
10450 else
10451 pkg_check_gtk=no
10454 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10455 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10458 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10460 GTK_OBJ=emacsgtkfixed.o
10463 if test "$pkg_check_gtk" != "yes"; then
10464 HAVE_GTK=no
10465 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10466 GLIB_REQUIRED=2.10
10467 GTK_REQUIRED=2.10
10468 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10471 succeeded=no
10473 if test "$PKG_CONFIG" = "no" ; then
10474 pkg_check_gtk=no
10475 else
10476 PKG_CONFIG_MIN_VERSION=0.9.0
10477 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10479 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10481 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10482 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10483 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10484 edit_cflags="
10485 s,///*,/,g
10486 s/^/ /
10487 s/ -I/ $isystem/g
10488 s/^ //
10490 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10491 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10493 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10494 succeeded=yes
10495 else
10496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10497 $as_echo "no" >&6; }
10498 GTK_CFLAGS=""
10499 GTK_LIBS=""
10500 ## If we have a custom action on failure, don't print errors, but
10501 ## do set a variable so people can do so.
10502 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10508 else
10509 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10510 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10514 if test $succeeded = yes; then
10515 pkg_check_gtk=yes
10516 else
10517 pkg_check_gtk=no
10520 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10521 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10526 if test x"$pkg_check_gtk" = xyes; then
10530 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10531 CFLAGS="$CFLAGS $GTK_CFLAGS"
10532 LIBS="$GTK_LIBS $LIBS"
10533 GTK_COMPILES=no
10534 for ac_func in gtk_main
10535 do :
10536 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10537 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10538 cat >>confdefs.h <<_ACEOF
10539 #define HAVE_GTK_MAIN 1
10540 _ACEOF
10541 GTK_COMPILES=yes
10543 done
10545 if test "${GTK_COMPILES}" != "yes"; then
10546 if test "$USE_X_TOOLKIT" != "maybe"; then
10547 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10549 else
10550 HAVE_GTK=yes
10552 $as_echo "#define USE_GTK 1" >>confdefs.h
10554 GTK_OBJ="gtkutil.o $GTK_OBJ"
10555 USE_X_TOOLKIT=none
10556 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10558 else
10559 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10560 closing open displays. This is no problem if you just use
10561 one display, but if you use more than one and close one of them
10562 Emacs may crash." >&5
10563 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10564 closing open displays. This is no problem if you just use
10565 one display, but if you use more than one and close one of them
10566 Emacs may crash." >&2;}
10567 sleep 3
10575 if test "${HAVE_GTK}" = "yes"; then
10577 if test "$with_toolkit_scroll_bars" != no; then
10578 with_toolkit_scroll_bars=yes
10581 HAVE_GTK_FILE_SELECTION=no
10582 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10583 #include <gtk/gtk.h>
10585 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10586 HAVE_GTK_FILE_SELECTION=yes
10587 else
10588 HAVE_GTK_FILE_SELECTION=no
10591 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10592 for ac_func in gtk_file_selection_new
10593 do :
10594 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10595 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10596 cat >>confdefs.h <<_ACEOF
10597 #define HAVE_GTK_FILE_SELECTION_NEW 1
10598 _ACEOF
10601 done
10606 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10607 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10608 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10609 gtk_orientable_set_orientation \
10610 gtk_window_set_has_resize_grip
10611 do :
10612 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10613 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10614 eval as_val=\$$as_ac_var
10615 if test "x$as_val" = x""yes; then :
10616 cat >>confdefs.h <<_ACEOF
10617 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10618 _ACEOF
10621 done
10625 HAVE_DBUS=no
10626 DBUS_OBJ=
10627 if test "${with_dbus}" = "yes"; then
10629 succeeded=no
10631 if test "$PKG_CONFIG" = "no" ; then
10632 HAVE_DBUS=no
10633 else
10634 PKG_CONFIG_MIN_VERSION=0.9.0
10635 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10637 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10639 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10640 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10641 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10642 edit_cflags="
10643 s,///*,/,g
10644 s/^/ /
10645 s/ -I/ $isystem/g
10646 s/^ //
10648 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10649 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10651 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10652 succeeded=yes
10653 else
10654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10655 $as_echo "no" >&6; }
10656 DBUS_CFLAGS=""
10657 DBUS_LIBS=""
10658 ## If we have a custom action on failure, don't print errors, but
10659 ## do set a variable so people can do so.
10660 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
10666 else
10667 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10668 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10672 if test $succeeded = yes; then
10673 HAVE_DBUS=yes
10674 else
10675 HAVE_DBUS=no
10678 if test "$HAVE_DBUS" = yes; then
10679 LIBS="$LIBS $DBUS_LIBS"
10681 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10683 for ac_func in dbus_watch_get_unix_fd \
10684 dbus_type_is_valid \
10685 dbus_validate_bus_name \
10686 dbus_validate_path \
10687 dbus_validate_interface \
10688 dbus_validate_member
10689 do :
10690 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10691 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10692 eval as_val=\$$as_ac_var
10693 if test "x$as_val" = x""yes; then :
10694 cat >>confdefs.h <<_ACEOF
10695 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10696 _ACEOF
10699 done
10701 DBUS_OBJ=dbusbind.o
10706 HAVE_GSETTINGS=no
10707 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10709 succeeded=no
10711 if test "$PKG_CONFIG" = "no" ; then
10712 HAVE_GSETTINGS=no
10713 else
10714 PKG_CONFIG_MIN_VERSION=0.9.0
10715 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10717 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10719 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10720 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10721 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10722 edit_cflags="
10723 s,///*,/,g
10724 s/^/ /
10725 s/ -I/ $isystem/g
10726 s/^ //
10728 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10729 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10731 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10732 succeeded=yes
10733 else
10734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10735 $as_echo "no" >&6; }
10736 GSETTINGS_CFLAGS=""
10737 GSETTINGS_LIBS=""
10738 ## If we have a custom action on failure, don't print errors, but
10739 ## do set a variable so people can do so.
10740 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gio-2.0 >= 2.26"`
10746 else
10747 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10748 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10752 if test $succeeded = yes; then
10753 HAVE_GSETTINGS=yes
10754 else
10755 HAVE_GSETTINGS=no
10758 if test "$HAVE_GSETTINGS" = "yes"; then
10760 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
10762 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
10763 SETTINGS_LIBS="$GSETTINGS_LIBS"
10767 HAVE_GCONF=no
10768 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
10770 succeeded=no
10772 if test "$PKG_CONFIG" = "no" ; then
10773 HAVE_GCONF=no
10774 else
10775 PKG_CONFIG_MIN_VERSION=0.9.0
10776 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
10778 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
10780 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
10781 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
10782 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
10783 edit_cflags="
10784 s,///*,/,g
10785 s/^/ /
10786 s/ -I/ $isystem/g
10787 s/^ //
10789 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
10790 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
10791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
10792 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
10793 succeeded=yes
10794 else
10795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10796 $as_echo "no" >&6; }
10797 GCONF_CFLAGS=""
10798 GCONF_LIBS=""
10799 ## If we have a custom action on failure, don't print errors, but
10800 ## do set a variable so people can do so.
10801 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
10807 else
10808 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10809 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10813 if test $succeeded = yes; then
10814 HAVE_GCONF=yes
10815 else
10816 HAVE_GCONF=no
10819 if test "$HAVE_GCONF" = yes; then
10821 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
10823 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
10824 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
10828 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
10829 SAVE_CFLAGS="$CFLAGS"
10830 SAVE_LIBS="$LIBS"
10831 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
10832 LIBS="$SETTINGS_LIBS $LIBS"
10833 for ac_func in g_type_init
10834 do :
10835 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
10836 if test "x$ac_cv_func_g_type_init" = x""yes; then :
10837 cat >>confdefs.h <<_ACEOF
10838 #define HAVE_G_TYPE_INIT 1
10839 _ACEOF
10842 done
10844 CFLAGS="$SAVE_CFLAGS"
10845 LIBS="$SAVE_LIBS"
10851 HAVE_LIBSELINUX=no
10852 LIBSELINUX_LIBS=
10853 if test "${with_selinux}" = "yes"; then
10854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
10855 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
10856 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
10857 $as_echo_n "(cached) " >&6
10858 else
10859 ac_check_lib_save_LIBS=$LIBS
10860 LIBS="-lselinux $LIBS"
10861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10862 /* end confdefs.h. */
10864 /* Override any GCC internal prototype to avoid an error.
10865 Use char because int might match the return type of a GCC
10866 builtin and then its argument prototype would still apply. */
10867 #ifdef __cplusplus
10868 extern "C"
10869 #endif
10870 char lgetfilecon ();
10872 main ()
10874 return lgetfilecon ();
10876 return 0;
10878 _ACEOF
10879 if ac_fn_c_try_link "$LINENO"; then :
10880 ac_cv_lib_selinux_lgetfilecon=yes
10881 else
10882 ac_cv_lib_selinux_lgetfilecon=no
10884 rm -f core conftest.err conftest.$ac_objext \
10885 conftest$ac_exeext conftest.$ac_ext
10886 LIBS=$ac_check_lib_save_LIBS
10888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
10889 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
10890 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
10891 HAVE_LIBSELINUX=yes
10892 else
10893 HAVE_LIBSELINUX=no
10896 if test "$HAVE_LIBSELINUX" = yes; then
10898 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
10900 LIBSELINUX_LIBS=-lselinux
10905 HAVE_GNUTLS=no
10906 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
10907 if test "${with_gnutls}" = "yes" ; then
10909 succeeded=no
10911 if test "$PKG_CONFIG" = "no" ; then
10912 HAVE_GNUTLS=no
10913 else
10914 PKG_CONFIG_MIN_VERSION=0.9.0
10915 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
10917 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
10919 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
10920 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
10921 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
10922 edit_cflags="
10923 s,///*,/,g
10924 s/^/ /
10925 s/ -I/ $isystem/g
10926 s/^ //
10928 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
10929 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
10930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
10931 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
10932 succeeded=yes
10933 else
10934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10935 $as_echo "no" >&6; }
10936 LIBGNUTLS_CFLAGS=""
10937 LIBGNUTLS_LIBS=""
10938 ## If we have a custom action on failure, don't print errors, but
10939 ## do set a variable so people can do so.
10940 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.6"`
10946 else
10947 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10948 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10952 if test $succeeded = yes; then
10953 HAVE_GNUTLS=yes
10954 else
10955 HAVE_GNUTLS=no
10958 if test "${HAVE_GNUTLS}" = "yes"; then
10960 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
10964 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
10965 LIBS="$LIBGNUTLS_LIBS $LIBS"
10966 for ac_func in gnutls_certificate_set_verify_function
10967 do :
10968 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
10969 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
10970 cat >>confdefs.h <<_ACEOF
10971 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
10972 _ACEOF
10973 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
10975 done
10978 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
10980 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
10988 HAVE_XAW3D=no
10989 LUCID_LIBW=
10990 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
10991 if test "$with_xaw3d" != no; then
10992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
10993 $as_echo_n "checking for xaw3d... " >&6; }
10994 if test "${emacs_cv_xaw3d+set}" = set; then :
10995 $as_echo_n "(cached) " >&6
10996 else
10997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10998 /* end confdefs.h. */
11000 #include <X11/Intrinsic.h>
11001 #include <X11/Xaw3d/Simple.h>
11003 main ()
11007 return 0;
11009 _ACEOF
11010 if ac_fn_c_try_link "$LINENO"; then :
11011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11012 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11013 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11014 $as_echo_n "(cached) " >&6
11015 else
11016 ac_check_lib_save_LIBS=$LIBS
11017 LIBS="-lXaw3d $LIBS"
11018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11019 /* end confdefs.h. */
11021 /* Override any GCC internal prototype to avoid an error.
11022 Use char because int might match the return type of a GCC
11023 builtin and then its argument prototype would still apply. */
11024 #ifdef __cplusplus
11025 extern "C"
11026 #endif
11027 char XawScrollbarSetThumb ();
11029 main ()
11031 return XawScrollbarSetThumb ();
11033 return 0;
11035 _ACEOF
11036 if ac_fn_c_try_link "$LINENO"; then :
11037 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11038 else
11039 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11041 rm -f core conftest.err conftest.$ac_objext \
11042 conftest$ac_exeext conftest.$ac_ext
11043 LIBS=$ac_check_lib_save_LIBS
11045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11046 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11047 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11048 emacs_cv_xaw3d=yes
11049 else
11050 emacs_cv_xaw3d=no
11053 else
11054 emacs_cv_xaw3d=no
11056 rm -f core conftest.err conftest.$ac_objext \
11057 conftest$ac_exeext conftest.$ac_ext
11060 else
11061 emacs_cv_xaw3d=no
11063 if test $emacs_cv_xaw3d = yes; then
11064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11065 $as_echo "yes; using Lucid toolkit" >&6; }
11066 USE_X_TOOLKIT=LUCID
11067 HAVE_XAW3D=yes
11068 LUCID_LIBW=-lXaw3d
11070 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11072 else
11073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11074 $as_echo "no" >&6; }
11075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11076 $as_echo_n "checking for libXaw... " >&6; }
11077 if test "${emacs_cv_xaw+set}" = set; then :
11078 $as_echo_n "(cached) " >&6
11079 else
11080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11081 /* end confdefs.h. */
11083 #include <X11/Intrinsic.h>
11084 #include <X11/Xaw/Simple.h>
11086 main ()
11090 return 0;
11092 _ACEOF
11093 if ac_fn_c_try_link "$LINENO"; then :
11094 emacs_cv_xaw=yes
11095 else
11096 emacs_cv_xaw=no
11098 rm -f core conftest.err conftest.$ac_objext \
11099 conftest$ac_exeext conftest.$ac_ext
11102 if test $emacs_cv_xaw = yes; then
11103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11104 $as_echo "yes; using Lucid toolkit" >&6; }
11105 USE_X_TOOLKIT=LUCID
11106 LUCID_LIBW=-lXaw
11107 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11108 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11109 else
11110 as_fn_error "No X toolkit could be found.
11111 If you are sure you want Emacs compiled without an X toolkit, pass
11112 --with-x-toolkit=no
11113 to configure. Otherwise, install the development libraries for the toolkit
11114 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11119 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11121 LIBXTR6=
11122 if test "${USE_X_TOOLKIT}" != "none"; then
11123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11124 $as_echo_n "checking X11 toolkit version... " >&6; }
11125 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11126 $as_echo_n "(cached) " >&6
11127 else
11128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11129 /* end confdefs.h. */
11130 #include <X11/Intrinsic.h>
11132 main ()
11134 #if XtSpecificationRelease < 6
11135 fail;
11136 #endif
11139 return 0;
11141 _ACEOF
11142 if ac_fn_c_try_link "$LINENO"; then :
11143 emacs_cv_x11_toolkit_version_6=yes
11144 else
11145 emacs_cv_x11_toolkit_version_6=no
11147 rm -f core conftest.err conftest.$ac_objext \
11148 conftest$ac_exeext conftest.$ac_ext
11151 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11152 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11154 $as_echo "6 or newer" >&6; }
11156 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11158 LIBXTR6="-lSM -lICE"
11159 case "$opsys" in
11160 ## Use libw.a along with X11R6 Xt.
11161 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11162 esac
11163 else
11164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11165 $as_echo "before 6" >&6; }
11168 OLDLIBS="$LIBS"
11169 if test x$HAVE_X11XTR6 = xyes; then
11170 LIBS="-lXt -lSM -lICE $LIBS"
11171 else
11172 LIBS="-lXt $LIBS"
11174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11175 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11176 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11177 $as_echo_n "(cached) " >&6
11178 else
11179 ac_check_lib_save_LIBS=$LIBS
11180 LIBS="-lXmu $LIBS"
11181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11182 /* end confdefs.h. */
11184 /* Override any GCC internal prototype to avoid an error.
11185 Use char because int might match the return type of a GCC
11186 builtin and then its argument prototype would still apply. */
11187 #ifdef __cplusplus
11188 extern "C"
11189 #endif
11190 char XmuConvertStandardSelection ();
11192 main ()
11194 return XmuConvertStandardSelection ();
11196 return 0;
11198 _ACEOF
11199 if ac_fn_c_try_link "$LINENO"; then :
11200 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11201 else
11202 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11204 rm -f core conftest.err conftest.$ac_objext \
11205 conftest$ac_exeext conftest.$ac_ext
11206 LIBS=$ac_check_lib_save_LIBS
11208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11209 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11210 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11211 cat >>confdefs.h <<_ACEOF
11212 #define HAVE_LIBXMU 1
11213 _ACEOF
11215 LIBS="-lXmu $LIBS"
11219 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11223 LIBXMU=-lXmu
11224 case $opsys in
11225 ## These systems don't supply Xmu.
11226 hpux* | aix4-2 )
11227 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11229 esac
11232 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11233 if test "${HAVE_X11}" = "yes"; then
11234 if test "${USE_X_TOOLKIT}" != "none"; then
11235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11236 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11237 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11238 $as_echo_n "(cached) " >&6
11239 else
11240 ac_check_lib_save_LIBS=$LIBS
11241 LIBS="-lXext $LIBS"
11242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11243 /* end confdefs.h. */
11245 /* Override any GCC internal prototype to avoid an error.
11246 Use char because int might match the return type of a GCC
11247 builtin and then its argument prototype would still apply. */
11248 #ifdef __cplusplus
11249 extern "C"
11250 #endif
11251 char XShapeQueryExtension ();
11253 main ()
11255 return XShapeQueryExtension ();
11257 return 0;
11259 _ACEOF
11260 if ac_fn_c_try_link "$LINENO"; then :
11261 ac_cv_lib_Xext_XShapeQueryExtension=yes
11262 else
11263 ac_cv_lib_Xext_XShapeQueryExtension=no
11265 rm -f core conftest.err conftest.$ac_objext \
11266 conftest$ac_exeext conftest.$ac_ext
11267 LIBS=$ac_check_lib_save_LIBS
11269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11270 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11271 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11272 cat >>confdefs.h <<_ACEOF
11273 #define HAVE_LIBXEXT 1
11274 _ACEOF
11276 LIBS="-lXext $LIBS"
11283 LIBXP=
11284 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11285 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11286 if test -d /usr/include/openmotif; then
11287 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11288 emacs_cv_openmotif=yes
11289 case "$canonical" in
11290 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11291 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11294 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11295 esac
11296 else
11297 emacs_cv_openmotif=no
11299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11300 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11301 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11302 $as_echo_n "(cached) " >&6
11303 else
11304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11305 /* end confdefs.h. */
11306 #include <Xm/Xm.h>
11308 main ()
11310 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11311 int x = 5;
11312 #else
11313 Motif version prior to 2.1.
11314 #endif
11316 return 0;
11318 _ACEOF
11319 if ac_fn_c_try_compile "$LINENO"; then :
11320 emacs_cv_motif_version_2_1=yes
11321 else
11322 emacs_cv_motif_version_2_1=no
11324 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11327 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11328 if test $emacs_cv_motif_version_2_1 = yes; then
11329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11330 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11331 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11332 $as_echo_n "(cached) " >&6
11333 else
11334 ac_check_lib_save_LIBS=$LIBS
11335 LIBS="-lXp $LIBS"
11336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11337 /* end confdefs.h. */
11339 /* Override any GCC internal prototype to avoid an error.
11340 Use char because int might match the return type of a GCC
11341 builtin and then its argument prototype would still apply. */
11342 #ifdef __cplusplus
11343 extern "C"
11344 #endif
11345 char XpCreateContext ();
11347 main ()
11349 return XpCreateContext ();
11351 return 0;
11353 _ACEOF
11354 if ac_fn_c_try_link "$LINENO"; then :
11355 ac_cv_lib_Xp_XpCreateContext=yes
11356 else
11357 ac_cv_lib_Xp_XpCreateContext=no
11359 rm -f core conftest.err conftest.$ac_objext \
11360 conftest$ac_exeext conftest.$ac_ext
11361 LIBS=$ac_check_lib_save_LIBS
11363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11364 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11365 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11366 LIBXP=-lXp
11369 if test x$emacs_cv_openmotif = xyes; then
11370 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11372 else
11373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11374 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11375 if test "${emacs_cv_lesstif+set}" = set; then :
11376 $as_echo_n "(cached) " >&6
11377 else
11378 # We put this in CFLAGS temporarily to precede other -I options
11379 # that might be in CFLAGS temporarily.
11380 # We put this in CPPFLAGS where it precedes the other -I options.
11381 OLD_CPPFLAGS=$CPPFLAGS
11382 OLD_CFLAGS=$CFLAGS
11383 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11384 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11386 /* end confdefs.h. */
11387 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11389 main ()
11391 int x = 5;
11393 return 0;
11395 _ACEOF
11396 if ac_fn_c_try_compile "$LINENO"; then :
11397 emacs_cv_lesstif=yes
11398 else
11399 emacs_cv_lesstif=no
11401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11404 $as_echo "$emacs_cv_lesstif" >&6; }
11405 if test $emacs_cv_lesstif = yes; then
11406 # Make sure this -I option remains in CPPFLAGS after it is set
11407 # back to REAL_CPPFLAGS.
11408 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11409 # have those other -I options anyway. Ultimately, having this
11410 # directory ultimately in CPPFLAGS will be enough.
11411 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11412 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11413 else
11414 CFLAGS=$OLD_CFLAGS
11415 CPPFLAGS=$OLD_CPPFLAGS
11418 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11419 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11421 else
11422 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11429 USE_TOOLKIT_SCROLL_BARS=no
11430 if test "${with_toolkit_scroll_bars}" != "no"; then
11431 if test "${USE_X_TOOLKIT}" != "none"; then
11432 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11433 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11435 HAVE_XAW3D=no
11436 USE_TOOLKIT_SCROLL_BARS=yes
11437 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11438 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11440 USE_TOOLKIT_SCROLL_BARS=yes
11442 elif test "${HAVE_GTK}" = "yes"; then
11443 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11445 USE_TOOLKIT_SCROLL_BARS=yes
11446 elif test "${HAVE_NS}" = "yes"; then
11447 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11449 USE_TOOLKIT_SCROLL_BARS=yes
11453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11454 /* end confdefs.h. */
11456 #include <X11/Xlib.h>
11457 #include <X11/Xresource.h>
11459 main ()
11461 XIMProc callback;
11463 return 0;
11465 _ACEOF
11466 if ac_fn_c_try_compile "$LINENO"; then :
11467 HAVE_XIM=yes
11469 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11471 else
11472 HAVE_XIM=no
11474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11477 if test "${with_xim}" != "no"; then
11479 $as_echo "#define USE_XIM 1" >>confdefs.h
11484 if test "${HAVE_XIM}" != "no"; then
11485 late_CFLAGS=$CFLAGS
11486 if test "$GCC" = yes; then
11487 CFLAGS="$CFLAGS --pedantic-errors"
11489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11490 /* end confdefs.h. */
11492 #include <X11/Xlib.h>
11493 #include <X11/Xresource.h>
11495 main ()
11497 Display *display;
11498 XrmDatabase db;
11499 char *res_name;
11500 char *res_class;
11501 XIMProc callback;
11502 XPointer *client_data;
11503 #ifndef __GNUC__
11504 /* If we're not using GCC, it's probably not XFree86, and this is
11505 probably right, but we can't use something like --pedantic-errors. */
11506 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11507 char*, XIMProc, XPointer*);
11508 #endif
11509 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11510 client_data);
11512 return 0;
11514 _ACEOF
11515 if ac_fn_c_try_compile "$LINENO"; then :
11516 emacs_cv_arg6_star=yes
11518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11519 if test "$emacs_cv_arg6_star" = yes; then
11520 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11522 else
11523 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11526 CFLAGS=$late_CFLAGS
11529 ### Start of font-backend (under any platform) section.
11530 # (nothing here yet -- this is a placeholder)
11531 ### End of font-backend (under any platform) section.
11533 ### Start of font-backend (under X11) section.
11534 if test "${HAVE_X11}" = "yes"; then
11536 succeeded=no
11538 if test "$PKG_CONFIG" = "no" ; then
11539 HAVE_FC=no
11540 else
11541 PKG_CONFIG_MIN_VERSION=0.9.0
11542 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11544 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11546 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11547 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11548 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11549 edit_cflags="
11550 s,///*,/,g
11551 s/^/ /
11552 s/ -I/ $isystem/g
11553 s/^ //
11555 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11556 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11558 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11559 succeeded=yes
11560 else
11561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11562 $as_echo "no" >&6; }
11563 FONTCONFIG_CFLAGS=""
11564 FONTCONFIG_LIBS=""
11565 ## If we have a custom action on failure, don't print errors, but
11566 ## do set a variable so people can do so.
11567 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
11573 else
11574 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11575 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11579 if test $succeeded = yes; then
11580 HAVE_FC=yes
11581 else
11582 HAVE_FC=no
11586 ## Use -lXft if available, unless `--with-xft=no'.
11587 HAVE_XFT=maybe
11588 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11589 with_xft="no";
11591 if test "x${with_xft}" != "xno"; then
11594 succeeded=no
11596 if test "$PKG_CONFIG" = "no" ; then
11597 HAVE_XFT=no
11598 else
11599 PKG_CONFIG_MIN_VERSION=0.9.0
11600 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11602 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11604 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11605 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11606 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11607 edit_cflags="
11608 s,///*,/,g
11609 s/^/ /
11610 s/ -I/ $isystem/g
11611 s/^ //
11613 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11614 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11616 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11617 succeeded=yes
11618 else
11619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11620 $as_echo "no" >&6; }
11621 XFT_CFLAGS=""
11622 XFT_LIBS=""
11623 ## If we have a custom action on failure, don't print errors, but
11624 ## do set a variable so people can do so.
11625 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
11631 else
11632 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11633 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11637 if test $succeeded = yes; then
11639 else
11640 HAVE_XFT=no
11643 ## Because xftfont.c uses XRenderQueryExtension, we also
11644 ## need to link to -lXrender.
11645 HAVE_XRENDER=no
11646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11647 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11648 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11649 $as_echo_n "(cached) " >&6
11650 else
11651 ac_check_lib_save_LIBS=$LIBS
11652 LIBS="-lXrender $LIBS"
11653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11654 /* end confdefs.h. */
11656 /* Override any GCC internal prototype to avoid an error.
11657 Use char because int might match the return type of a GCC
11658 builtin and then its argument prototype would still apply. */
11659 #ifdef __cplusplus
11660 extern "C"
11661 #endif
11662 char XRenderQueryExtension ();
11664 main ()
11666 return XRenderQueryExtension ();
11668 return 0;
11670 _ACEOF
11671 if ac_fn_c_try_link "$LINENO"; then :
11672 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11673 else
11674 ac_cv_lib_Xrender_XRenderQueryExtension=no
11676 rm -f core conftest.err conftest.$ac_objext \
11677 conftest$ac_exeext conftest.$ac_ext
11678 LIBS=$ac_check_lib_save_LIBS
11680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11681 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11682 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11683 HAVE_XRENDER=yes
11686 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11687 OLD_CPPFLAGS="$CPPFLAGS"
11688 OLD_CFLAGS="$CFLAGS"
11689 OLD_LIBS="$LIBS"
11690 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11691 CFLAGS="$CFLAGS $XFT_CFLAGS"
11692 XFT_LIBS="-lXrender $XFT_LIBS"
11693 LIBS="$XFT_LIBS $LIBS"
11694 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
11695 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
11696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
11697 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
11698 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
11699 $as_echo_n "(cached) " >&6
11700 else
11701 ac_check_lib_save_LIBS=$LIBS
11702 LIBS="-lXft $XFT_LIBS $LIBS"
11703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11704 /* end confdefs.h. */
11706 /* Override any GCC internal prototype to avoid an error.
11707 Use char because int might match the return type of a GCC
11708 builtin and then its argument prototype would still apply. */
11709 #ifdef __cplusplus
11710 extern "C"
11711 #endif
11712 char XftFontOpen ();
11714 main ()
11716 return XftFontOpen ();
11718 return 0;
11720 _ACEOF
11721 if ac_fn_c_try_link "$LINENO"; then :
11722 ac_cv_lib_Xft_XftFontOpen=yes
11723 else
11724 ac_cv_lib_Xft_XftFontOpen=no
11726 rm -f core conftest.err conftest.$ac_objext \
11727 conftest$ac_exeext conftest.$ac_ext
11728 LIBS=$ac_check_lib_save_LIBS
11730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11731 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
11732 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
11733 HAVE_XFT=yes
11740 if test "${HAVE_XFT}" = "yes"; then
11742 $as_echo "#define HAVE_XFT 1" >>confdefs.h
11745 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
11746 else
11747 CPPFLAGS="$OLD_CPPFLAGS"
11748 CFLAGS="$OLD_CFLAGS"
11749 LIBS="$OLD_LIBS"
11750 fi # "${HAVE_XFT}" = "yes"
11751 fi # "$HAVE_XFT" != no
11752 fi # "x${with_xft}" != "xno"
11754 ## We used to allow building with FreeType and without Xft.
11755 ## However, the ftx font backend driver is not in good shape.
11756 if test "$HAVE_XFT" != "yes"; then
11757 HAVE_XFT=no
11758 HAVE_FREETYPE=no
11759 else
11761 succeeded=no
11763 if test "$PKG_CONFIG" = "no" ; then
11764 HAVE_FREETYPE=no
11765 else
11766 PKG_CONFIG_MIN_VERSION=0.9.0
11767 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
11769 $as_echo_n "checking for freetype2... " >&6; }
11771 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
11772 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
11773 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
11774 edit_cflags="
11775 s,///*,/,g
11776 s/^/ /
11777 s/ -I/ $isystem/g
11778 s/^ //
11780 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
11781 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
11782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
11783 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
11784 succeeded=yes
11785 else
11786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11787 $as_echo "no" >&6; }
11788 FREETYPE_CFLAGS=""
11789 FREETYPE_LIBS=""
11790 ## If we have a custom action on failure, don't print errors, but
11791 ## do set a variable so people can do so.
11792 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
11798 else
11799 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11800 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11804 if test $succeeded = yes; then
11805 HAVE_FREETYPE=yes
11806 else
11807 HAVE_FREETYPE=no
11811 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
11814 HAVE_LIBOTF=no
11815 if test "${HAVE_FREETYPE}" = "yes"; then
11817 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
11819 if test "${with_libotf}" != "no"; then
11821 succeeded=no
11823 if test "$PKG_CONFIG" = "no" ; then
11824 HAVE_LIBOTF=no
11825 else
11826 PKG_CONFIG_MIN_VERSION=0.9.0
11827 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
11829 $as_echo_n "checking for libotf... " >&6; }
11831 if $PKG_CONFIG --exists "libotf" 2>&5 &&
11832 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
11833 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
11834 edit_cflags="
11835 s,///*,/,g
11836 s/^/ /
11837 s/ -I/ $isystem/g
11838 s/^ //
11840 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
11841 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
11842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
11843 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
11844 succeeded=yes
11845 else
11846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11847 $as_echo "no" >&6; }
11848 LIBOTF_CFLAGS=""
11849 LIBOTF_LIBS=""
11850 ## If we have a custom action on failure, don't print errors, but
11851 ## do set a variable so people can do so.
11852 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
11858 else
11859 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11860 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11864 if test $succeeded = yes; then
11865 HAVE_LIBOTF=yes
11866 else
11867 HAVE_LIBOTF=no
11870 if test "$HAVE_LIBOTF" = "yes"; then
11872 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
11874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
11875 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
11876 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
11877 $as_echo_n "(cached) " >&6
11878 else
11879 ac_check_lib_save_LIBS=$LIBS
11880 LIBS="-lotf $LIBS"
11881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11882 /* end confdefs.h. */
11884 /* Override any GCC internal prototype to avoid an error.
11885 Use char because int might match the return type of a GCC
11886 builtin and then its argument prototype would still apply. */
11887 #ifdef __cplusplus
11888 extern "C"
11889 #endif
11890 char OTF_get_variation_glyphs ();
11892 main ()
11894 return OTF_get_variation_glyphs ();
11896 return 0;
11898 _ACEOF
11899 if ac_fn_c_try_link "$LINENO"; then :
11900 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
11901 else
11902 ac_cv_lib_otf_OTF_get_variation_glyphs=no
11904 rm -f core conftest.err conftest.$ac_objext \
11905 conftest$ac_exeext conftest.$ac_ext
11906 LIBS=$ac_check_lib_save_LIBS
11908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
11909 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
11910 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
11911 HAVE_OTF_GET_VARIATION_GLYPHS=yes
11912 else
11913 HAVE_OTF_GET_VARIATION_GLYPHS=no
11916 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
11918 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
11925 HAVE_M17N_FLT=no
11926 if test "${HAVE_LIBOTF}" = yes; then
11927 if test "${with_m17n_flt}" != "no"; then
11929 succeeded=no
11931 if test "$PKG_CONFIG" = "no" ; then
11932 HAVE_M17N_FLT=no
11933 else
11934 PKG_CONFIG_MIN_VERSION=0.9.0
11935 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
11937 $as_echo_n "checking for m17n-flt... " >&6; }
11939 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
11940 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
11941 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
11942 edit_cflags="
11943 s,///*,/,g
11944 s/^/ /
11945 s/ -I/ $isystem/g
11946 s/^ //
11948 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
11949 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
11950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
11951 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
11952 succeeded=yes
11953 else
11954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11955 $as_echo "no" >&6; }
11956 M17N_FLT_CFLAGS=""
11957 M17N_FLT_LIBS=""
11958 ## If we have a custom action on failure, don't print errors, but
11959 ## do set a variable so people can do so.
11960 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
11966 else
11967 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11968 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11972 if test $succeeded = yes; then
11973 HAVE_M17N_FLT=yes
11974 else
11975 HAVE_M17N_FLT=no
11978 if test "$HAVE_M17N_FLT" = "yes"; then
11980 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
11985 else
11986 HAVE_XFT=no
11987 HAVE_FREETYPE=no
11988 HAVE_LIBOTF=no
11989 HAVE_M17N_FLT=no
11992 ### End of font-backend (under X11) section.
12003 ### Use -lXpm if available, unless `--with-xpm=no'.
12004 HAVE_XPM=no
12005 LIBXPM=
12006 if test "${HAVE_X11}" = "yes"; then
12007 if test "${with_xpm}" != "no"; then
12008 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12009 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12011 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12012 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12013 $as_echo_n "(cached) " >&6
12014 else
12015 ac_check_lib_save_LIBS=$LIBS
12016 LIBS="-lXpm -lX11 $LIBS"
12017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12018 /* end confdefs.h. */
12020 /* Override any GCC internal prototype to avoid an error.
12021 Use char because int might match the return type of a GCC
12022 builtin and then its argument prototype would still apply. */
12023 #ifdef __cplusplus
12024 extern "C"
12025 #endif
12026 char XpmReadFileToPixmap ();
12028 main ()
12030 return XpmReadFileToPixmap ();
12032 return 0;
12034 _ACEOF
12035 if ac_fn_c_try_link "$LINENO"; then :
12036 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12037 else
12038 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12040 rm -f core conftest.err conftest.$ac_objext \
12041 conftest$ac_exeext conftest.$ac_ext
12042 LIBS=$ac_check_lib_save_LIBS
12044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12045 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12046 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12047 HAVE_XPM=yes
12053 if test "${HAVE_XPM}" = "yes"; then
12054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12055 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12057 /* end confdefs.h. */
12058 #include "X11/xpm.h"
12059 #ifndef XpmReturnAllocPixels
12060 no_return_alloc_pixels
12061 #endif
12063 _ACEOF
12064 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12065 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12066 HAVE_XPM=no
12067 else
12068 HAVE_XPM=yes
12070 rm -f conftest*
12073 if test "${HAVE_XPM}" = "yes"; then
12074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12075 $as_echo "yes" >&6; }
12076 else
12077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12078 $as_echo "no" >&6; }
12083 if test "${HAVE_XPM}" = "yes"; then
12085 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12087 LIBXPM=-lXpm
12092 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12093 HAVE_JPEG=no
12094 LIBJPEG=
12095 if test "${HAVE_X11}" = "yes"; then
12096 if test "${with_jpeg}" != "no"; then
12097 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12098 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12100 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12101 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12102 $as_echo_n "(cached) " >&6
12103 else
12104 ac_check_lib_save_LIBS=$LIBS
12105 LIBS="-ljpeg $LIBS"
12106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12107 /* end confdefs.h. */
12109 /* Override any GCC internal prototype to avoid an error.
12110 Use char because int might match the return type of a GCC
12111 builtin and then its argument prototype would still apply. */
12112 #ifdef __cplusplus
12113 extern "C"
12114 #endif
12115 char jpeg_destroy_compress ();
12117 main ()
12119 return jpeg_destroy_compress ();
12121 return 0;
12123 _ACEOF
12124 if ac_fn_c_try_link "$LINENO"; then :
12125 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12126 else
12127 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12129 rm -f core conftest.err conftest.$ac_objext \
12130 conftest$ac_exeext conftest.$ac_ext
12131 LIBS=$ac_check_lib_save_LIBS
12133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12134 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12135 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12136 HAVE_JPEG=yes
12144 if test "${HAVE_JPEG}" = "yes"; then
12145 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12147 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12148 /* end confdefs.h. */
12149 #include <jpeglib.h>
12150 version=JPEG_LIB_VERSION
12152 _ACEOF
12153 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12154 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12155 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12157 else
12158 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12159 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12160 HAVE_JPEG=no
12162 rm -f conftest*
12165 if test "${HAVE_JPEG}" = "yes"; then
12166 LIBJPEG=-ljpeg
12171 ### Use -lpng if available, unless `--with-png=no'.
12172 HAVE_PNG=no
12173 LIBPNG=
12174 if test "${HAVE_X11}" = "yes"; then
12175 if test "${with_png}" != "no"; then
12176 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12177 # in /usr/include/libpng.
12178 for ac_header in png.h libpng/png.h
12179 do :
12180 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12181 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12182 eval as_val=\$$as_ac_Header
12183 if test "x$as_val" = x""yes; then :
12184 cat >>confdefs.h <<_ACEOF
12185 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12186 _ACEOF
12187 break
12190 done
12192 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12194 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12195 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12196 $as_echo_n "(cached) " >&6
12197 else
12198 ac_check_lib_save_LIBS=$LIBS
12199 LIBS="-lpng -lz -lm $LIBS"
12200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12201 /* end confdefs.h. */
12203 /* Override any GCC internal prototype to avoid an error.
12204 Use char because int might match the return type of a GCC
12205 builtin and then its argument prototype would still apply. */
12206 #ifdef __cplusplus
12207 extern "C"
12208 #endif
12209 char png_get_channels ();
12211 main ()
12213 return png_get_channels ();
12215 return 0;
12217 _ACEOF
12218 if ac_fn_c_try_link "$LINENO"; then :
12219 ac_cv_lib_png_png_get_channels=yes
12220 else
12221 ac_cv_lib_png_png_get_channels=no
12223 rm -f core conftest.err conftest.$ac_objext \
12224 conftest$ac_exeext conftest.$ac_ext
12225 LIBS=$ac_check_lib_save_LIBS
12227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12228 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12229 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12230 HAVE_PNG=yes
12236 if test "${HAVE_PNG}" = "yes"; then
12238 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12240 LIBPNG="-lpng -lz -lm"
12242 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12243 # include <libpng/png.h>
12244 #else
12245 # include <png.h>
12246 #endif
12249 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12251 else
12253 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12261 ### Use -ltiff if available, unless `--with-tiff=no'.
12262 HAVE_TIFF=no
12263 LIBTIFF=
12264 if test "${HAVE_X11}" = "yes"; then
12265 if test "${with_tiff}" != "no"; then
12266 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12267 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12268 tifflibs="-lz -lm"
12269 # At least one tiff package requires the jpeg library.
12270 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12272 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12273 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12274 $as_echo_n "(cached) " >&6
12275 else
12276 ac_check_lib_save_LIBS=$LIBS
12277 LIBS="-ltiff $tifflibs $LIBS"
12278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12279 /* end confdefs.h. */
12281 /* Override any GCC internal prototype to avoid an error.
12282 Use char because int might match the return type of a GCC
12283 builtin and then its argument prototype would still apply. */
12284 #ifdef __cplusplus
12285 extern "C"
12286 #endif
12287 char TIFFGetVersion ();
12289 main ()
12291 return TIFFGetVersion ();
12293 return 0;
12295 _ACEOF
12296 if ac_fn_c_try_link "$LINENO"; then :
12297 ac_cv_lib_tiff_TIFFGetVersion=yes
12298 else
12299 ac_cv_lib_tiff_TIFFGetVersion=no
12301 rm -f core conftest.err conftest.$ac_objext \
12302 conftest$ac_exeext conftest.$ac_ext
12303 LIBS=$ac_check_lib_save_LIBS
12305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12306 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12307 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12308 HAVE_TIFF=yes
12316 if test "${HAVE_TIFF}" = "yes"; then
12318 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12320 LIBTIFF=-ltiff
12325 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12326 HAVE_GIF=no
12327 LIBGIF=
12328 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12329 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12330 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12331 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12332 # Earlier versions can crash Emacs.
12333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12334 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12335 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12336 $as_echo_n "(cached) " >&6
12337 else
12338 ac_check_lib_save_LIBS=$LIBS
12339 LIBS="-lgif $LIBS"
12340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12341 /* end confdefs.h. */
12343 /* Override any GCC internal prototype to avoid an error.
12344 Use char because int might match the return type of a GCC
12345 builtin and then its argument prototype would still apply. */
12346 #ifdef __cplusplus
12347 extern "C"
12348 #endif
12349 char EGifPutExtensionLast ();
12351 main ()
12353 return EGifPutExtensionLast ();
12355 return 0;
12357 _ACEOF
12358 if ac_fn_c_try_link "$LINENO"; then :
12359 ac_cv_lib_gif_EGifPutExtensionLast=yes
12360 else
12361 ac_cv_lib_gif_EGifPutExtensionLast=no
12363 rm -f core conftest.err conftest.$ac_objext \
12364 conftest$ac_exeext conftest.$ac_ext
12365 LIBS=$ac_check_lib_save_LIBS
12367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12368 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12369 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12370 HAVE_GIF=yes
12371 else
12372 HAVE_GIF=maybe
12379 if test "$HAVE_GIF" = yes; then
12380 LIBGIF=-lgif
12381 elif test "$HAVE_GIF" = maybe; then
12382 # If gif_lib.h but no libgif, try libungif.
12383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12384 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12385 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12386 $as_echo_n "(cached) " >&6
12387 else
12388 ac_check_lib_save_LIBS=$LIBS
12389 LIBS="-lungif $LIBS"
12390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12391 /* end confdefs.h. */
12393 /* Override any GCC internal prototype to avoid an error.
12394 Use char because int might match the return type of a GCC
12395 builtin and then its argument prototype would still apply. */
12396 #ifdef __cplusplus
12397 extern "C"
12398 #endif
12399 char EGifPutExtensionLast ();
12401 main ()
12403 return EGifPutExtensionLast ();
12405 return 0;
12407 _ACEOF
12408 if ac_fn_c_try_link "$LINENO"; then :
12409 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12410 else
12411 ac_cv_lib_ungif_EGifPutExtensionLast=no
12413 rm -f core conftest.err conftest.$ac_objext \
12414 conftest$ac_exeext conftest.$ac_ext
12415 LIBS=$ac_check_lib_save_LIBS
12417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12418 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12419 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12420 HAVE_GIF=yes
12421 else
12422 HAVE_GIF=no
12425 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12428 if test "${HAVE_GIF}" = "yes"; then
12430 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12436 if test "${HAVE_X11}" = "yes"; then
12437 MISSING=""
12438 WITH_NO=""
12439 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12440 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12441 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12442 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12443 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12444 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12445 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12446 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12447 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12448 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12450 if test "X${MISSING}" != X; then
12451 as_fn_error "The following required libraries were not found:
12452 $MISSING
12453 Maybe some development libraries/packages are missing?
12454 If you don't want to link with them give
12455 $WITH_NO
12456 as options to configure" "$LINENO" 5
12460 ### Use -lgpm if available, unless `--with-gpm=no'.
12461 HAVE_GPM=no
12462 LIBGPM=
12463 if test "${with_gpm}" != "no"; then
12464 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12465 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12467 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12468 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12469 $as_echo_n "(cached) " >&6
12470 else
12471 ac_check_lib_save_LIBS=$LIBS
12472 LIBS="-lgpm $LIBS"
12473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12474 /* end confdefs.h. */
12476 /* Override any GCC internal prototype to avoid an error.
12477 Use char because int might match the return type of a GCC
12478 builtin and then its argument prototype would still apply. */
12479 #ifdef __cplusplus
12480 extern "C"
12481 #endif
12482 char Gpm_Open ();
12484 main ()
12486 return Gpm_Open ();
12488 return 0;
12490 _ACEOF
12491 if ac_fn_c_try_link "$LINENO"; then :
12492 ac_cv_lib_gpm_Gpm_Open=yes
12493 else
12494 ac_cv_lib_gpm_Gpm_Open=no
12496 rm -f core conftest.err conftest.$ac_objext \
12497 conftest$ac_exeext conftest.$ac_ext
12498 LIBS=$ac_check_lib_save_LIBS
12500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12501 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12502 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12503 HAVE_GPM=yes
12510 if test "${HAVE_GPM}" = "yes"; then
12512 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12514 LIBGPM=-lgpm
12523 GNUSTEP_CFLAGS=
12524 ### Use NeXTstep API to implement GUI.
12525 if test "${HAVE_NS}" = "yes"; then
12527 $as_echo "#define HAVE_NS 1" >>confdefs.h
12529 if test "${NS_IMPL_COCOA}" = "yes"; then
12531 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12534 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12536 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12538 # See also .m.o rule in Makefile.in */
12539 # FIXME: are all these flags really needed? Document here why. */
12540 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12541 ## Extra CFLAGS applied to src/*.m files.
12542 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"
12544 # We also have mouse menus.
12545 HAVE_MENUS=yes
12546 OTHER_FILES=ns-app
12550 ### Use session management (-lSM -lICE) if available
12551 HAVE_X_SM=no
12552 LIBXSM=
12553 if test "${HAVE_X11}" = "yes"; then
12554 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12555 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12557 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12558 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12559 $as_echo_n "(cached) " >&6
12560 else
12561 ac_check_lib_save_LIBS=$LIBS
12562 LIBS="-lSM -lICE $LIBS"
12563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12564 /* end confdefs.h. */
12566 /* Override any GCC internal prototype to avoid an error.
12567 Use char because int might match the return type of a GCC
12568 builtin and then its argument prototype would still apply. */
12569 #ifdef __cplusplus
12570 extern "C"
12571 #endif
12572 char SmcOpenConnection ();
12574 main ()
12576 return SmcOpenConnection ();
12578 return 0;
12580 _ACEOF
12581 if ac_fn_c_try_link "$LINENO"; then :
12582 ac_cv_lib_SM_SmcOpenConnection=yes
12583 else
12584 ac_cv_lib_SM_SmcOpenConnection=no
12586 rm -f core conftest.err conftest.$ac_objext \
12587 conftest$ac_exeext conftest.$ac_ext
12588 LIBS=$ac_check_lib_save_LIBS
12590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
12591 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
12592 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
12593 HAVE_X_SM=yes
12600 if test "${HAVE_X_SM}" = "yes"; then
12602 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
12604 LIBXSM="-lSM -lICE"
12605 case "$LIBS" in
12606 *-lSM*) ;;
12607 *) LIBS="$LIBXSM $LIBS" ;;
12608 esac
12613 ### Use libxml (-lxml2) if available
12614 HAVE_LIBXML2=no
12615 if test "${with_xml2}" != "no"; then
12616 ### I'm not sure what the version number should be, so I just guessed.
12618 succeeded=no
12620 if test "$PKG_CONFIG" = "no" ; then
12621 HAVE_LIBXML2=no
12622 else
12623 PKG_CONFIG_MIN_VERSION=0.9.0
12624 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
12626 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
12628 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
12629 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
12630 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
12631 edit_cflags="
12632 s,///*,/,g
12633 s/^/ /
12634 s/ -I/ $isystem/g
12635 s/^ //
12637 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
12638 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
12639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
12640 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
12641 succeeded=yes
12642 else
12643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12644 $as_echo "no" >&6; }
12645 LIBXML2_CFLAGS=""
12646 LIBXML2_LIBS=""
12647 ## If we have a custom action on failure, don't print errors, but
12648 ## do set a variable so people can do so.
12649 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
12655 else
12656 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12657 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12661 if test $succeeded = yes; then
12662 HAVE_LIBXML2=yes
12663 else
12664 HAVE_LIBXML2=no
12667 if test "${HAVE_LIBXML2}" = "yes"; then
12668 LIBS="$LIBXML2_LIBS $LIBS"
12669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
12670 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
12671 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
12672 $as_echo_n "(cached) " >&6
12673 else
12674 ac_check_lib_save_LIBS=$LIBS
12675 LIBS="-lxml2 $LIBS"
12676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12677 /* end confdefs.h. */
12679 /* Override any GCC internal prototype to avoid an error.
12680 Use char because int might match the return type of a GCC
12681 builtin and then its argument prototype would still apply. */
12682 #ifdef __cplusplus
12683 extern "C"
12684 #endif
12685 char htmlReadMemory ();
12687 main ()
12689 return htmlReadMemory ();
12691 return 0;
12693 _ACEOF
12694 if ac_fn_c_try_link "$LINENO"; then :
12695 ac_cv_lib_xml2_htmlReadMemory=yes
12696 else
12697 ac_cv_lib_xml2_htmlReadMemory=no
12699 rm -f core conftest.err conftest.$ac_objext \
12700 conftest$ac_exeext conftest.$ac_ext
12701 LIBS=$ac_check_lib_save_LIBS
12703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
12704 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
12705 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
12706 HAVE_LIBXML2=yes
12707 else
12708 HAVE_LIBXML2=no
12711 if test "${HAVE_LIBXML2}" = "yes"; then
12713 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
12715 else
12716 LIBXML2_LIBS=""
12717 LIBXML2_CFLAGS=""
12724 # If netdb.h doesn't declare h_errno, we must declare it by hand.
12725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
12726 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
12727 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
12728 $as_echo_n "(cached) " >&6
12729 else
12730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12731 /* end confdefs.h. */
12732 #include <netdb.h>
12734 main ()
12736 return h_errno;
12738 return 0;
12740 _ACEOF
12741 if ac_fn_c_try_link "$LINENO"; then :
12742 emacs_cv_netdb_declares_h_errno=yes
12743 else
12744 emacs_cv_netdb_declares_h_errno=no
12746 rm -f core conftest.err conftest.$ac_objext \
12747 conftest$ac_exeext conftest.$ac_ext
12749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
12750 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
12751 if test $emacs_cv_netdb_declares_h_errno = yes; then
12753 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
12757 # fmod, logb, and frexp are found in -lm on most systems.
12758 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
12760 $as_echo_n "checking for sqrt in -lm... " >&6; }
12761 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
12762 $as_echo_n "(cached) " >&6
12763 else
12764 ac_check_lib_save_LIBS=$LIBS
12765 LIBS="-lm $LIBS"
12766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12767 /* end confdefs.h. */
12769 /* Override any GCC internal prototype to avoid an error.
12770 Use char because int might match the return type of a GCC
12771 builtin and then its argument prototype would still apply. */
12772 #ifdef __cplusplus
12773 extern "C"
12774 #endif
12775 char sqrt ();
12777 main ()
12779 return sqrt ();
12781 return 0;
12783 _ACEOF
12784 if ac_fn_c_try_link "$LINENO"; then :
12785 ac_cv_lib_m_sqrt=yes
12786 else
12787 ac_cv_lib_m_sqrt=no
12789 rm -f core conftest.err conftest.$ac_objext \
12790 conftest$ac_exeext conftest.$ac_ext
12791 LIBS=$ac_check_lib_save_LIBS
12793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
12794 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
12795 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
12796 cat >>confdefs.h <<_ACEOF
12797 #define HAVE_LIBM 1
12798 _ACEOF
12800 LIBS="-lm $LIBS"
12805 # Check for mail-locking functions in a "mail" library. Probably this should
12806 # have the same check as for liblockfile below.
12807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
12808 $as_echo_n "checking for maillock in -lmail... " >&6; }
12809 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
12810 $as_echo_n "(cached) " >&6
12811 else
12812 ac_check_lib_save_LIBS=$LIBS
12813 LIBS="-lmail $LIBS"
12814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12815 /* end confdefs.h. */
12817 /* Override any GCC internal prototype to avoid an error.
12818 Use char because int might match the return type of a GCC
12819 builtin and then its argument prototype would still apply. */
12820 #ifdef __cplusplus
12821 extern "C"
12822 #endif
12823 char maillock ();
12825 main ()
12827 return maillock ();
12829 return 0;
12831 _ACEOF
12832 if ac_fn_c_try_link "$LINENO"; then :
12833 ac_cv_lib_mail_maillock=yes
12834 else
12835 ac_cv_lib_mail_maillock=no
12837 rm -f core conftest.err conftest.$ac_objext \
12838 conftest$ac_exeext conftest.$ac_ext
12839 LIBS=$ac_check_lib_save_LIBS
12841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
12842 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
12843 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
12844 have_mail=yes
12845 else
12846 have_mail=no
12849 if test $have_mail = yes; then
12850 LIBS_MAIL=-lmail
12851 LIBS="$LIBS_MAIL $LIBS"
12853 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
12855 else
12856 LIBS_MAIL=
12858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
12859 $as_echo_n "checking for maillock in -llockfile... " >&6; }
12860 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
12861 $as_echo_n "(cached) " >&6
12862 else
12863 ac_check_lib_save_LIBS=$LIBS
12864 LIBS="-llockfile $LIBS"
12865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12866 /* end confdefs.h. */
12868 /* Override any GCC internal prototype to avoid an error.
12869 Use char because int might match the return type of a GCC
12870 builtin and then its argument prototype would still apply. */
12871 #ifdef __cplusplus
12872 extern "C"
12873 #endif
12874 char maillock ();
12876 main ()
12878 return maillock ();
12880 return 0;
12882 _ACEOF
12883 if ac_fn_c_try_link "$LINENO"; then :
12884 ac_cv_lib_lockfile_maillock=yes
12885 else
12886 ac_cv_lib_lockfile_maillock=no
12888 rm -f core conftest.err conftest.$ac_objext \
12889 conftest$ac_exeext conftest.$ac_ext
12890 LIBS=$ac_check_lib_save_LIBS
12892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
12893 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
12894 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
12895 have_lockfile=yes
12896 else
12897 have_lockfile=no
12900 if test $have_lockfile = yes; then
12901 LIBS_MAIL=-llockfile
12902 LIBS="$LIBS_MAIL $LIBS"
12904 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
12906 else
12907 # If we have the shared liblockfile, assume we must use it for mail
12908 # locking (e.g. Debian). If we couldn't link against liblockfile
12909 # (no liblockfile.a installed), ensure that we don't need to.
12910 # Extract the first word of "liblockfile.so", so it can be a program name with args.
12911 set dummy liblockfile.so; ac_word=$2
12912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12913 $as_echo_n "checking for $ac_word... " >&6; }
12914 if test "${ac_cv_prog_liblockfile+set}" = set; then :
12915 $as_echo_n "(cached) " >&6
12916 else
12917 if test -n "$liblockfile"; then
12918 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
12919 else
12920 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12921 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
12922 for as_dir in $as_dummy
12924 IFS=$as_save_IFS
12925 test -z "$as_dir" && as_dir=.
12926 for ac_exec_ext in '' $ac_executable_extensions; do
12927 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12928 ac_cv_prog_liblockfile="yes"
12929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12930 break 2
12932 done
12933 done
12934 IFS=$as_save_IFS
12936 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
12939 liblockfile=$ac_cv_prog_liblockfile
12940 if test -n "$liblockfile"; then
12941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
12942 $as_echo "$liblockfile" >&6; }
12943 else
12944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12945 $as_echo "no" >&6; }
12949 if test $ac_cv_prog_liblockfile = yes; then
12950 as_fn_error "Shared liblockfile found but can't link against it.
12951 This probably means that movemail could lose mail.
12952 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
12960 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
12961 ## interlock access to the mail spool. The alternative is a lock file named
12962 ## /usr/spool/mail/$USER.lock.
12963 mail_lock=no
12964 case "$opsys" in
12965 aix4-2) mail_lock="lockf" ;;
12967 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
12969 ## On GNU/Linux systems, both methods are used by various mail programs.
12970 ## I assume most people are using newer mailers that have heard of flock.
12971 ## Change this if you need to.
12972 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
12973 ## configure gets the right answers, and that means *NOT* using flock.
12974 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
12975 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
12976 ## Debian maintainer hasn't provided a clean fix for Emacs.
12977 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
12978 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
12979 ## correct logic. -- fx
12980 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
12981 ## liblockfile is a Free Software replacement for libmail, used on
12982 ## Debian systems and elsewhere. -rfr.
12983 gnu-*)
12984 mail_lock="flock"
12985 if test $have_mail = yes || test $have_lockfile = yes; then
12986 test $ac_cv_header_maillock_h = yes && mail_lock=no
12989 esac
12991 BLESSMAIL_TARGET=
12992 case "$mail_lock" in
12993 flock)
12994 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
12997 lockf)
12998 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13001 *) BLESSMAIL_TARGET="need-blessmail" ;;
13002 esac
13006 for ac_func in gethostname \
13007 closedir getrusage get_current_dir_name \
13008 lrand48 logb frexp fmod cbrt setsid \
13009 fpathconf select euidaccess getpagesize setlocale \
13010 utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
13011 __fpending strsignal setitimer \
13012 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13013 gai_strerror mkstemp getline getdelim fsync sync \
13014 difftime posix_memalign \
13015 getpwent endpwent getgrent endgrent \
13016 touchlock \
13017 cfmakeraw cfsetspeed copysign __executable_start
13018 do :
13019 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13020 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13021 eval as_val=\$$as_ac_var
13022 if test "x$as_val" = x""yes; then :
13023 cat >>confdefs.h <<_ACEOF
13024 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13025 _ACEOF
13028 done
13031 if test $opsys != unixware; then
13032 for ac_func in getwd
13033 do :
13034 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13035 if test "x$ac_cv_func_getwd" = x""yes; then :
13036 cat >>confdefs.h <<_ACEOF
13037 #define HAVE_GETWD 1
13038 _ACEOF
13041 done
13045 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13046 ## has a broken `rint' in some library versions including math library
13047 ## version number A.09.05.
13048 ## You can fix the math library by installing patch number PHSS_4630.
13049 ## But we can fix it more reliably for Emacs by just not using rint.
13050 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13051 case $opsys in
13052 hpux*) : ;;
13053 *) for ac_func in random rint
13054 do :
13055 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13056 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13057 eval as_val=\$$as_ac_var
13058 if test "x$as_val" = x""yes; then :
13059 cat >>confdefs.h <<_ACEOF
13060 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13061 _ACEOF
13064 done
13066 esac
13068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13069 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13070 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13071 $as_echo_n "(cached) " >&6
13072 else
13073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13074 /* end confdefs.h. */
13077 main ()
13079 __builtin_unwind_init ();
13081 return 0;
13083 _ACEOF
13084 if ac_fn_c_try_link "$LINENO"; then :
13085 emacs_cv_func___builtin_unwind_init=yes
13086 else
13087 emacs_cv_func___builtin_unwind_init=no
13089 rm -f core conftest.err conftest.$ac_objext \
13090 conftest$ac_exeext conftest.$ac_ext
13092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13093 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13094 if test $emacs_cv_func___builtin_unwind_init = yes; then
13096 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13105 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13106 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13107 $as_echo_n "(cached) " >&6
13108 else
13109 while :; do
13110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13111 /* end confdefs.h. */
13112 #include <sys/types.h> /* for off_t */
13113 #include <stdio.h>
13115 main ()
13117 int (*fp) (FILE *, off_t, int) = fseeko;
13118 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13120 return 0;
13122 _ACEOF
13123 if ac_fn_c_try_link "$LINENO"; then :
13124 ac_cv_sys_largefile_source=no; break
13126 rm -f core conftest.err conftest.$ac_objext \
13127 conftest$ac_exeext conftest.$ac_ext
13128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13129 /* end confdefs.h. */
13130 #define _LARGEFILE_SOURCE 1
13131 #include <sys/types.h> /* for off_t */
13132 #include <stdio.h>
13134 main ()
13136 int (*fp) (FILE *, off_t, int) = fseeko;
13137 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13139 return 0;
13141 _ACEOF
13142 if ac_fn_c_try_link "$LINENO"; then :
13143 ac_cv_sys_largefile_source=1; break
13145 rm -f core conftest.err conftest.$ac_objext \
13146 conftest$ac_exeext conftest.$ac_ext
13147 ac_cv_sys_largefile_source=unknown
13148 break
13149 done
13151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13152 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13153 case $ac_cv_sys_largefile_source in #(
13154 no | unknown) ;;
13156 cat >>confdefs.h <<_ACEOF
13157 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13158 _ACEOF
13160 esac
13161 rm -rf conftest*
13163 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13164 # in glibc 2.1.3, but that breaks too many other things.
13165 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13166 if test $ac_cv_sys_largefile_source != unknown; then
13168 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13174 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13175 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13176 $as_echo_n "(cached) " >&6
13177 else
13178 # Use it with a single arg.
13179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13180 /* end confdefs.h. */
13181 $ac_includes_default
13183 main ()
13185 getpgrp (0);
13187 return 0;
13189 _ACEOF
13190 if ac_fn_c_try_compile "$LINENO"; then :
13191 ac_cv_func_getpgrp_void=no
13192 else
13193 ac_cv_func_getpgrp_void=yes
13195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13199 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13200 if test $ac_cv_func_getpgrp_void = yes; then
13202 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13207 # UNIX98 PTYs.
13208 for ac_func in grantpt
13209 do :
13210 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13211 if test "x$ac_cv_func_grantpt" = x""yes; then :
13212 cat >>confdefs.h <<_ACEOF
13213 #define HAVE_GRANTPT 1
13214 _ACEOF
13217 done
13220 # PTY-related GNU extensions.
13221 for ac_func in getpt
13222 do :
13223 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
13224 if test "x$ac_cv_func_getpt" = x""yes; then :
13225 cat >>confdefs.h <<_ACEOF
13226 #define HAVE_GETPT 1
13227 _ACEOF
13230 done
13233 # Check this now, so that we will NOT find the above functions in ncurses.
13234 # That is because we have not set up to link ncurses in lib-src.
13235 # It's better to believe a function is not available
13236 # than to expect to find it in ncurses.
13237 # Also we need tputs and friends to be able to build at all.
13238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13239 $as_echo_n "checking for library containing tputs... " >&6; }
13240 # Run a test program that contains a call to tputs, a call that is
13241 # never executed. This tests whether a pre-'main' dynamic linker
13242 # works with the library. It's too much trouble to actually call
13243 # tputs in the test program, due to portability hassles. When
13244 # cross-compiling, assume the test program will run if it links.
13246 # Maybe curses should be tried earlier?
13247 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13248 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13249 OLIBS=$LIBS
13250 if test -z "$tputs_library"; then
13251 LIBS_TERMCAP=
13252 msg='none required'
13253 else
13254 LIBS_TERMCAP=-l$tputs_library
13255 msg=$LIBS_TERMCAP
13256 LIBS="$LIBS_TERMCAP $LIBS"
13258 if test "$cross_compiling" = yes; then :
13259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13260 /* end confdefs.h. */
13262 extern void tputs (const char *, int, int (*)(int));
13263 int main (int argc, char **argv)
13265 if (argc == 10000)
13266 tputs (argv[0], 0, 0);
13267 return 0;
13270 _ACEOF
13271 if ac_fn_c_try_link "$LINENO"; then :
13273 else
13274 msg=no
13276 rm -f core conftest.err conftest.$ac_objext \
13277 conftest$ac_exeext conftest.$ac_ext
13278 else
13279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13280 /* end confdefs.h. */
13282 extern void tputs (const char *, int, int (*)(int));
13283 int main (int argc, char **argv)
13285 if (argc == 10000)
13286 tputs (argv[0], 0, 0);
13287 return 0;
13290 _ACEOF
13291 if ac_fn_c_try_run "$LINENO"; then :
13293 else
13294 msg=no
13296 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13297 conftest.$ac_objext conftest.beam conftest.$ac_ext
13300 LIBS=$OLIBS
13301 if test "X$msg" != Xno; then
13302 break
13304 done
13305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13306 $as_echo "$msg" >&6; }
13307 if test "X$msg" = Xno; then
13308 as_fn_error "The required function \`tputs' was not found in any library.
13309 The following libraries were tried (in order):
13310 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13311 Please try installing whichever of these libraries is most appropriate
13312 for your system, together with its header files.
13313 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13316 ## Use termcap instead of terminfo?
13317 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13318 TERMINFO=yes
13319 ## FIXME? In the cases below where we unconditionally set
13320 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13321 ## if that was found above to have tputs.
13322 ## Should we use the gnu* logic everywhere?
13323 case "$opsys" in
13324 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13325 ## The ncurses library has been moved out of the System framework in
13326 ## Mac OS X 10.2. So if configure detects it, set the command-line
13327 ## option to use it.
13328 darwin) LIBS_TERMCAP="-lncurses" ;;
13330 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13332 freebsd)
13333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13334 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13335 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13336 $as_echo_n "(cached) " >&6
13337 else
13338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13339 /* end confdefs.h. */
13340 #include <osreldate.h>
13342 main ()
13344 #if __FreeBSD_version < 400000
13345 fail;
13346 #endif
13349 return 0;
13351 _ACEOF
13352 if ac_fn_c_try_link "$LINENO"; then :
13353 emacs_cv_freebsd_terminfo=yes
13354 else
13355 emacs_cv_freebsd_terminfo=no
13357 rm -f core conftest.err conftest.$ac_objext \
13358 conftest$ac_exeext conftest.$ac_ext
13362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13363 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13365 if test $emacs_cv_freebsd_terminfo = yes; then
13366 LIBS_TERMCAP="-lncurses"
13367 else
13368 TERMINFO=no
13369 LIBS_TERMCAP="-ltermcap"
13373 netbsd)
13374 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13375 TERMINFO=no
13376 LIBS_TERMCAP="-ltermcap"
13380 openbsd) LIBS_TERMCAP="-lncurses" ;;
13382 ## hpux: Make sure we get select from libc rather than from libcurses
13383 ## because libcurses on HPUX 10.10 has a broken version of select.
13384 ## We used to use -lc -lcurses, but this may be cleaner.
13385 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13386 # set that way, now it uses the default). Isn't this a contradiction?
13387 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13389 esac
13391 TERMCAP_OBJ=tparam.o
13392 if test $TERMINFO = yes; then
13394 $as_echo "#define TERMINFO 1" >>confdefs.h
13396 TERMCAP_OBJ=terminfo.o
13402 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13403 # On Darwin, res_init appears not to be useful: see bug#562 and
13404 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13405 resolv=no
13407 if test $opsys != darwin; then
13409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13410 /* end confdefs.h. */
13411 #include <netinet/in.h>
13412 #include <arpa/nameser.h>
13413 #include <resolv.h>
13415 main ()
13417 return res_init();
13419 return 0;
13421 _ACEOF
13422 if ac_fn_c_try_link "$LINENO"; then :
13423 have_res_init=yes
13424 else
13425 have_res_init=no
13427 rm -f core conftest.err conftest.$ac_objext \
13428 conftest$ac_exeext conftest.$ac_ext
13429 if test "$have_res_init" = no; then
13430 OLIBS="$LIBS"
13431 LIBS="$LIBS -lresolv"
13432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13433 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13435 /* end confdefs.h. */
13436 #include <netinet/in.h>
13437 #include <arpa/nameser.h>
13438 #include <resolv.h>
13440 main ()
13442 return res_init();
13444 return 0;
13446 _ACEOF
13447 if ac_fn_c_try_link "$LINENO"; then :
13448 have_res_init=yes
13449 else
13450 have_res_init=no
13452 rm -f core conftest.err conftest.$ac_objext \
13453 conftest$ac_exeext conftest.$ac_ext
13454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13455 $as_echo "$have_res_init" >&6; }
13456 if test "$have_res_init" = yes ; then
13457 resolv=yes
13459 LIBS="$OLIBS"
13462 if test "$have_res_init" = yes; then
13464 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13468 # Do we need the Hesiod library to provide the support routines?
13469 LIBHESIOD=
13470 if test "$with_hesiod" != no ; then
13471 # Don't set $LIBS here -- see comments above. FIXME which comments?
13472 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13473 if test "x$ac_cv_func_res_send" = x""yes; then :
13475 else
13476 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13477 if test "x$ac_cv_func___res_send" = x""yes; then :
13479 else
13480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13481 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13482 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13483 $as_echo_n "(cached) " >&6
13484 else
13485 ac_check_lib_save_LIBS=$LIBS
13486 LIBS="-lresolv $LIBS"
13487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13488 /* end confdefs.h. */
13490 /* Override any GCC internal prototype to avoid an error.
13491 Use char because int might match the return type of a GCC
13492 builtin and then its argument prototype would still apply. */
13493 #ifdef __cplusplus
13494 extern "C"
13495 #endif
13496 char res_send ();
13498 main ()
13500 return res_send ();
13502 return 0;
13504 _ACEOF
13505 if ac_fn_c_try_link "$LINENO"; then :
13506 ac_cv_lib_resolv_res_send=yes
13507 else
13508 ac_cv_lib_resolv_res_send=no
13510 rm -f core conftest.err conftest.$ac_objext \
13511 conftest$ac_exeext conftest.$ac_ext
13512 LIBS=$ac_check_lib_save_LIBS
13514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13515 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13516 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13517 resolv=yes
13518 else
13519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13520 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13521 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13522 $as_echo_n "(cached) " >&6
13523 else
13524 ac_check_lib_save_LIBS=$LIBS
13525 LIBS="-lresolv $LIBS"
13526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13527 /* end confdefs.h. */
13529 /* Override any GCC internal prototype to avoid an error.
13530 Use char because int might match the return type of a GCC
13531 builtin and then its argument prototype would still apply. */
13532 #ifdef __cplusplus
13533 extern "C"
13534 #endif
13535 char __res_send ();
13537 main ()
13539 return __res_send ();
13541 return 0;
13543 _ACEOF
13544 if ac_fn_c_try_link "$LINENO"; then :
13545 ac_cv_lib_resolv___res_send=yes
13546 else
13547 ac_cv_lib_resolv___res_send=no
13549 rm -f core conftest.err conftest.$ac_objext \
13550 conftest$ac_exeext conftest.$ac_ext
13551 LIBS=$ac_check_lib_save_LIBS
13553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13554 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13555 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13556 resolv=yes
13565 if test "$resolv" = yes ; then
13566 RESOLVLIB=-lresolv
13567 else
13568 RESOLVLIB=
13570 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13571 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13573 else
13574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13575 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13576 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13577 $as_echo_n "(cached) " >&6
13578 else
13579 ac_check_lib_save_LIBS=$LIBS
13580 LIBS="-lhesiod $RESOLVLIB $LIBS"
13581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13582 /* end confdefs.h. */
13584 /* Override any GCC internal prototype to avoid an error.
13585 Use char because int might match the return type of a GCC
13586 builtin and then its argument prototype would still apply. */
13587 #ifdef __cplusplus
13588 extern "C"
13589 #endif
13590 char hes_getmailhost ();
13592 main ()
13594 return hes_getmailhost ();
13596 return 0;
13598 _ACEOF
13599 if ac_fn_c_try_link "$LINENO"; then :
13600 ac_cv_lib_hesiod_hes_getmailhost=yes
13601 else
13602 ac_cv_lib_hesiod_hes_getmailhost=no
13604 rm -f core conftest.err conftest.$ac_objext \
13605 conftest$ac_exeext conftest.$ac_ext
13606 LIBS=$ac_check_lib_save_LIBS
13608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
13609 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
13610 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
13611 hesiod=yes
13612 else
13619 if test x"$hesiod" = xyes; then
13621 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
13623 LIBHESIOD=-lhesiod
13628 # Do we need libresolv (due to res_init or Hesiod)?
13629 if test "$resolv" = yes && test $opsys != darwin; then
13631 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
13633 LIBRESOLV=-lresolv
13634 else
13635 LIBRESOLV=
13639 # These tell us which Kerberos-related libraries to use.
13640 COM_ERRLIB=
13641 CRYPTOLIB=
13642 KRB5LIB=
13643 DESLIB=
13644 KRB4LIB=
13646 if test "${with_kerberos}" != no; then
13647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
13648 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
13649 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
13650 $as_echo_n "(cached) " >&6
13651 else
13652 ac_check_lib_save_LIBS=$LIBS
13653 LIBS="-lcom_err $LIBS"
13654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13655 /* end confdefs.h. */
13657 /* Override any GCC internal prototype to avoid an error.
13658 Use char because int might match the return type of a GCC
13659 builtin and then its argument prototype would still apply. */
13660 #ifdef __cplusplus
13661 extern "C"
13662 #endif
13663 char com_err ();
13665 main ()
13667 return com_err ();
13669 return 0;
13671 _ACEOF
13672 if ac_fn_c_try_link "$LINENO"; then :
13673 ac_cv_lib_com_err_com_err=yes
13674 else
13675 ac_cv_lib_com_err_com_err=no
13677 rm -f core conftest.err conftest.$ac_objext \
13678 conftest$ac_exeext conftest.$ac_ext
13679 LIBS=$ac_check_lib_save_LIBS
13681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
13682 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
13683 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
13684 have_com_err=yes
13685 else
13686 have_com_err=no
13689 if test $have_com_err = yes; then
13690 COM_ERRLIB=-lcom_err
13691 LIBS="$COM_ERRLIB $LIBS"
13693 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
13696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
13697 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
13698 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
13699 $as_echo_n "(cached) " >&6
13700 else
13701 ac_check_lib_save_LIBS=$LIBS
13702 LIBS="-lcrypto $LIBS"
13703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13704 /* end confdefs.h. */
13706 /* Override any GCC internal prototype to avoid an error.
13707 Use char because int might match the return type of a GCC
13708 builtin and then its argument prototype would still apply. */
13709 #ifdef __cplusplus
13710 extern "C"
13711 #endif
13712 char mit_des_cbc_encrypt ();
13714 main ()
13716 return mit_des_cbc_encrypt ();
13718 return 0;
13720 _ACEOF
13721 if ac_fn_c_try_link "$LINENO"; then :
13722 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
13723 else
13724 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
13726 rm -f core conftest.err conftest.$ac_objext \
13727 conftest$ac_exeext conftest.$ac_ext
13728 LIBS=$ac_check_lib_save_LIBS
13730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
13731 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
13732 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
13733 have_crypto=yes
13734 else
13735 have_crypto=no
13738 if test $have_crypto = yes; then
13739 CRYPTOLIB=-lcrypto
13740 LIBS="$CRYPTOLIB $LIBS"
13742 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
13745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
13746 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
13747 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
13748 $as_echo_n "(cached) " >&6
13749 else
13750 ac_check_lib_save_LIBS=$LIBS
13751 LIBS="-lk5crypto $LIBS"
13752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13753 /* end confdefs.h. */
13755 /* Override any GCC internal prototype to avoid an error.
13756 Use char because int might match the return type of a GCC
13757 builtin and then its argument prototype would still apply. */
13758 #ifdef __cplusplus
13759 extern "C"
13760 #endif
13761 char mit_des_cbc_encrypt ();
13763 main ()
13765 return mit_des_cbc_encrypt ();
13767 return 0;
13769 _ACEOF
13770 if ac_fn_c_try_link "$LINENO"; then :
13771 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
13772 else
13773 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
13775 rm -f core conftest.err conftest.$ac_objext \
13776 conftest$ac_exeext conftest.$ac_ext
13777 LIBS=$ac_check_lib_save_LIBS
13779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
13780 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
13781 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
13782 have_k5crypto=yes
13783 else
13784 have_k5crypto=no
13787 if test $have_k5crypto = yes; then
13788 CRYPTOLIB=-lk5crypto
13789 LIBS="$CRYPTOLIB $LIBS"
13791 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
13794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
13795 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
13796 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
13797 $as_echo_n "(cached) " >&6
13798 else
13799 ac_check_lib_save_LIBS=$LIBS
13800 LIBS="-lkrb5 $LIBS"
13801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13802 /* end confdefs.h. */
13804 /* Override any GCC internal prototype to avoid an error.
13805 Use char because int might match the return type of a GCC
13806 builtin and then its argument prototype would still apply. */
13807 #ifdef __cplusplus
13808 extern "C"
13809 #endif
13810 char krb5_init_context ();
13812 main ()
13814 return krb5_init_context ();
13816 return 0;
13818 _ACEOF
13819 if ac_fn_c_try_link "$LINENO"; then :
13820 ac_cv_lib_krb5_krb5_init_context=yes
13821 else
13822 ac_cv_lib_krb5_krb5_init_context=no
13824 rm -f core conftest.err conftest.$ac_objext \
13825 conftest$ac_exeext conftest.$ac_ext
13826 LIBS=$ac_check_lib_save_LIBS
13828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
13829 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
13830 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
13831 have_krb5=yes
13832 else
13833 have_krb5=no
13836 if test $have_krb5=yes; then
13837 KRB5LIB=-lkrb5
13838 LIBS="$KRB5LIB $LIBS"
13840 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
13843 if test "${with_kerberos5}" = no; then
13844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
13845 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
13846 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
13847 $as_echo_n "(cached) " >&6
13848 else
13849 ac_check_lib_save_LIBS=$LIBS
13850 LIBS="-ldes425 $LIBS"
13851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13852 /* end confdefs.h. */
13854 /* Override any GCC internal prototype to avoid an error.
13855 Use char because int might match the return type of a GCC
13856 builtin and then its argument prototype would still apply. */
13857 #ifdef __cplusplus
13858 extern "C"
13859 #endif
13860 char des_cbc_encrypt ();
13862 main ()
13864 return des_cbc_encrypt ();
13866 return 0;
13868 _ACEOF
13869 if ac_fn_c_try_link "$LINENO"; then :
13870 ac_cv_lib_des425_des_cbc_encrypt=yes
13871 else
13872 ac_cv_lib_des425_des_cbc_encrypt=no
13874 rm -f core conftest.err conftest.$ac_objext \
13875 conftest$ac_exeext conftest.$ac_ext
13876 LIBS=$ac_check_lib_save_LIBS
13878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
13879 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
13880 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
13881 have_des425=yes
13882 else
13883 have_des425=no
13886 if test $have_des425 = yes; then
13887 DESLIB=-ldes425
13888 LIBS="$DESLIB $LIBS"
13890 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
13892 else
13893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
13894 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
13895 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
13896 $as_echo_n "(cached) " >&6
13897 else
13898 ac_check_lib_save_LIBS=$LIBS
13899 LIBS="-ldes $LIBS"
13900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13901 /* end confdefs.h. */
13903 /* Override any GCC internal prototype to avoid an error.
13904 Use char because int might match the return type of a GCC
13905 builtin and then its argument prototype would still apply. */
13906 #ifdef __cplusplus
13907 extern "C"
13908 #endif
13909 char des_cbc_encrypt ();
13911 main ()
13913 return des_cbc_encrypt ();
13915 return 0;
13917 _ACEOF
13918 if ac_fn_c_try_link "$LINENO"; then :
13919 ac_cv_lib_des_des_cbc_encrypt=yes
13920 else
13921 ac_cv_lib_des_des_cbc_encrypt=no
13923 rm -f core conftest.err conftest.$ac_objext \
13924 conftest$ac_exeext conftest.$ac_ext
13925 LIBS=$ac_check_lib_save_LIBS
13927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
13928 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
13929 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
13930 have_des=yes
13931 else
13932 have_des=no
13935 if test $have_des = yes; then
13936 DESLIB=-ldes
13937 LIBS="$DESLIB $LIBS"
13939 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
13943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
13944 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
13945 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
13946 $as_echo_n "(cached) " >&6
13947 else
13948 ac_check_lib_save_LIBS=$LIBS
13949 LIBS="-lkrb4 $LIBS"
13950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13951 /* end confdefs.h. */
13953 /* Override any GCC internal prototype to avoid an error.
13954 Use char because int might match the return type of a GCC
13955 builtin and then its argument prototype would still apply. */
13956 #ifdef __cplusplus
13957 extern "C"
13958 #endif
13959 char krb_get_cred ();
13961 main ()
13963 return krb_get_cred ();
13965 return 0;
13967 _ACEOF
13968 if ac_fn_c_try_link "$LINENO"; then :
13969 ac_cv_lib_krb4_krb_get_cred=yes
13970 else
13971 ac_cv_lib_krb4_krb_get_cred=no
13973 rm -f core conftest.err conftest.$ac_objext \
13974 conftest$ac_exeext conftest.$ac_ext
13975 LIBS=$ac_check_lib_save_LIBS
13977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
13978 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
13979 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
13980 have_krb4=yes
13981 else
13982 have_krb4=no
13985 if test $have_krb4 = yes; then
13986 KRB4LIB=-lkrb4
13987 LIBS="$KRB4LIB $LIBS"
13989 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
13991 else
13992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
13993 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
13994 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
13995 $as_echo_n "(cached) " >&6
13996 else
13997 ac_check_lib_save_LIBS=$LIBS
13998 LIBS="-lkrb $LIBS"
13999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14000 /* end confdefs.h. */
14002 /* Override any GCC internal prototype to avoid an error.
14003 Use char because int might match the return type of a GCC
14004 builtin and then its argument prototype would still apply. */
14005 #ifdef __cplusplus
14006 extern "C"
14007 #endif
14008 char krb_get_cred ();
14010 main ()
14012 return krb_get_cred ();
14014 return 0;
14016 _ACEOF
14017 if ac_fn_c_try_link "$LINENO"; then :
14018 ac_cv_lib_krb_krb_get_cred=yes
14019 else
14020 ac_cv_lib_krb_krb_get_cred=no
14022 rm -f core conftest.err conftest.$ac_objext \
14023 conftest$ac_exeext conftest.$ac_ext
14024 LIBS=$ac_check_lib_save_LIBS
14026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14027 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14028 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14029 have_krb=yes
14030 else
14031 have_krb=no
14034 if test $have_krb = yes; then
14035 KRB4LIB=-lkrb
14036 LIBS="$KRB4LIB $LIBS"
14038 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14044 if test "${with_kerberos5}" != no; then
14045 for ac_header in krb5.h
14046 do :
14047 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14048 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14049 cat >>confdefs.h <<_ACEOF
14050 #define HAVE_KRB5_H 1
14051 _ACEOF
14052 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14054 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14056 cat >>confdefs.h <<_ACEOF
14057 #define HAVE_KRB5_ERROR_TEXT 1
14058 _ACEOF
14062 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14064 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14066 cat >>confdefs.h <<_ACEOF
14067 #define HAVE_KRB5_ERROR_E_TEXT 1
14068 _ACEOF
14075 done
14077 else
14078 for ac_header in des.h
14079 do :
14080 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14081 if test "x$ac_cv_header_des_h" = x""yes; then :
14082 cat >>confdefs.h <<_ACEOF
14083 #define HAVE_DES_H 1
14084 _ACEOF
14086 else
14087 for ac_header in kerberosIV/des.h
14088 do :
14089 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14090 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14091 cat >>confdefs.h <<_ACEOF
14092 #define HAVE_KERBEROSIV_DES_H 1
14093 _ACEOF
14095 else
14096 for ac_header in kerberos/des.h
14097 do :
14098 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14099 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14100 cat >>confdefs.h <<_ACEOF
14101 #define HAVE_KERBEROS_DES_H 1
14102 _ACEOF
14106 done
14110 done
14114 done
14116 for ac_header in krb.h
14117 do :
14118 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14119 if test "x$ac_cv_header_krb_h" = x""yes; then :
14120 cat >>confdefs.h <<_ACEOF
14121 #define HAVE_KRB_H 1
14122 _ACEOF
14124 else
14125 for ac_header in kerberosIV/krb.h
14126 do :
14127 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14128 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14129 cat >>confdefs.h <<_ACEOF
14130 #define HAVE_KERBEROSIV_KRB_H 1
14131 _ACEOF
14133 else
14134 for ac_header in kerberos/krb.h
14135 do :
14136 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14137 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14138 cat >>confdefs.h <<_ACEOF
14139 #define HAVE_KERBEROS_KRB_H 1
14140 _ACEOF
14144 done
14148 done
14152 done
14155 for ac_header in com_err.h
14156 do :
14157 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14158 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14159 cat >>confdefs.h <<_ACEOF
14160 #define HAVE_COM_ERR_H 1
14161 _ACEOF
14165 done
14178 for ac_func in $ac_func_list
14179 do :
14180 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14181 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14182 eval as_val=\$$as_ac_var
14183 if test "x$as_val" = x""yes; then :
14184 cat >>confdefs.h <<_ACEOF
14185 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14186 _ACEOF
14189 done
14194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14195 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14196 if test "${emacs_cv_localtime_cache+set}" = set; then :
14197 $as_echo_n "(cached) " >&6
14198 else
14199 if test x$ac_cv_func_tzset = xyes; then
14200 if test "$cross_compiling" = yes; then :
14201 # If we have tzset, assume the worst when cross-compiling.
14202 emacs_cv_localtime_cache=yes
14203 else
14204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14205 /* end confdefs.h. */
14206 #include <time.h>
14207 char TZ_GMT0[] = "TZ=GMT0";
14208 char TZ_PST8[] = "TZ=PST8";
14209 main()
14211 time_t now = time ((time_t *) 0);
14212 int hour_GMT0, hour_unset;
14213 if (putenv (TZ_GMT0) != 0)
14214 exit (1);
14215 hour_GMT0 = localtime (&now)->tm_hour;
14216 unsetenv("TZ");
14217 hour_unset = localtime (&now)->tm_hour;
14218 if (putenv (TZ_PST8) != 0)
14219 exit (1);
14220 if (localtime (&now)->tm_hour == hour_GMT0)
14221 exit (1);
14222 unsetenv("TZ");
14223 if (localtime (&now)->tm_hour != hour_unset)
14224 exit (1);
14225 exit (0);
14227 _ACEOF
14228 if ac_fn_c_try_run "$LINENO"; then :
14229 emacs_cv_localtime_cache=no
14230 else
14231 emacs_cv_localtime_cache=yes
14233 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14234 conftest.$ac_objext conftest.beam conftest.$ac_ext
14237 else
14238 # If we lack tzset, report that localtime does not cache TZ,
14239 # since we can't invalidate the cache if we don't have tzset.
14240 emacs_cv_localtime_cache=no
14243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14244 $as_echo "$emacs_cv_localtime_cache" >&6; }
14245 if test $emacs_cv_localtime_cache = yes; then
14247 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14251 ok_so_far=yes
14252 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14253 if test "x$ac_cv_func_socket" = x""yes; then :
14255 else
14256 ok_so_far=no
14259 if test $ok_so_far = yes; then
14260 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14261 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14263 else
14264 ok_so_far=no
14269 if test $ok_so_far = yes; then
14270 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14271 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14273 else
14274 ok_so_far=no
14279 if test $ok_so_far = yes; then
14281 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14285 if test -f /usr/lpp/X11/bin/smt.exp; then
14287 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14292 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14293 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14295 $as_echo "yes" >&6; }
14297 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14299 else
14300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14301 $as_echo "no" >&6; }
14304 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14305 if test "x$ac_cv_type_pid_t" = x""yes; then :
14307 else
14309 cat >>confdefs.h <<_ACEOF
14310 #define pid_t int
14311 _ACEOF
14315 for ac_header in vfork.h
14316 do :
14317 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14318 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14319 cat >>confdefs.h <<_ACEOF
14320 #define HAVE_VFORK_H 1
14321 _ACEOF
14325 done
14327 for ac_func in fork vfork
14328 do :
14329 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14330 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14331 eval as_val=\$$as_ac_var
14332 if test "x$as_val" = x""yes; then :
14333 cat >>confdefs.h <<_ACEOF
14334 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14335 _ACEOF
14338 done
14340 if test "x$ac_cv_func_fork" = xyes; then
14341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14342 $as_echo_n "checking for working fork... " >&6; }
14343 if test "${ac_cv_func_fork_works+set}" = set; then :
14344 $as_echo_n "(cached) " >&6
14345 else
14346 if test "$cross_compiling" = yes; then :
14347 ac_cv_func_fork_works=cross
14348 else
14349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14350 /* end confdefs.h. */
14351 $ac_includes_default
14353 main ()
14356 /* By Ruediger Kuhlmann. */
14357 return fork () < 0;
14360 return 0;
14362 _ACEOF
14363 if ac_fn_c_try_run "$LINENO"; then :
14364 ac_cv_func_fork_works=yes
14365 else
14366 ac_cv_func_fork_works=no
14368 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14369 conftest.$ac_objext conftest.beam conftest.$ac_ext
14373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14374 $as_echo "$ac_cv_func_fork_works" >&6; }
14376 else
14377 ac_cv_func_fork_works=$ac_cv_func_fork
14379 if test "x$ac_cv_func_fork_works" = xcross; then
14380 case $host in
14381 *-*-amigaos* | *-*-msdosdjgpp*)
14382 # Override, as these systems have only a dummy fork() stub
14383 ac_cv_func_fork_works=no
14386 ac_cv_func_fork_works=yes
14388 esac
14389 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14390 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14392 ac_cv_func_vfork_works=$ac_cv_func_vfork
14393 if test "x$ac_cv_func_vfork" = xyes; then
14394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14395 $as_echo_n "checking for working vfork... " >&6; }
14396 if test "${ac_cv_func_vfork_works+set}" = set; then :
14397 $as_echo_n "(cached) " >&6
14398 else
14399 if test "$cross_compiling" = yes; then :
14400 ac_cv_func_vfork_works=cross
14401 else
14402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14403 /* end confdefs.h. */
14404 /* Thanks to Paul Eggert for this test. */
14405 $ac_includes_default
14406 #include <sys/wait.h>
14407 #ifdef HAVE_VFORK_H
14408 # include <vfork.h>
14409 #endif
14410 /* On some sparc systems, changes by the child to local and incoming
14411 argument registers are propagated back to the parent. The compiler
14412 is told about this with #include <vfork.h>, but some compilers
14413 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14414 static variable whose address is put into a register that is
14415 clobbered by the vfork. */
14416 static void
14417 #ifdef __cplusplus
14418 sparc_address_test (int arg)
14419 # else
14420 sparc_address_test (arg) int arg;
14421 #endif
14423 static pid_t child;
14424 if (!child) {
14425 child = vfork ();
14426 if (child < 0) {
14427 perror ("vfork");
14428 _exit(2);
14430 if (!child) {
14431 arg = getpid();
14432 write(-1, "", 0);
14433 _exit (arg);
14439 main ()
14441 pid_t parent = getpid ();
14442 pid_t child;
14444 sparc_address_test (0);
14446 child = vfork ();
14448 if (child == 0) {
14449 /* Here is another test for sparc vfork register problems. This
14450 test uses lots of local variables, at least as many local
14451 variables as main has allocated so far including compiler
14452 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14453 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14454 reuse the register of parent for one of the local variables,
14455 since it will think that parent can't possibly be used any more
14456 in this routine. Assigning to the local variable will thus
14457 munge parent in the parent process. */
14458 pid_t
14459 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14460 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14461 /* Convince the compiler that p..p7 are live; otherwise, it might
14462 use the same hardware register for all 8 local variables. */
14463 if (p != p1 || p != p2 || p != p3 || p != p4
14464 || p != p5 || p != p6 || p != p7)
14465 _exit(1);
14467 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14468 from child file descriptors. If the child closes a descriptor
14469 before it execs or exits, this munges the parent's descriptor
14470 as well. Test for this by closing stdout in the child. */
14471 _exit(close(fileno(stdout)) != 0);
14472 } else {
14473 int status;
14474 struct stat st;
14476 while (wait(&status) != child)
14478 return (
14479 /* Was there some problem with vforking? */
14480 child < 0
14482 /* Did the child fail? (This shouldn't happen.) */
14483 || status
14485 /* Did the vfork/compiler bug occur? */
14486 || parent != getpid()
14488 /* Did the file descriptor bug occur? */
14489 || fstat(fileno(stdout), &st) != 0
14493 _ACEOF
14494 if ac_fn_c_try_run "$LINENO"; then :
14495 ac_cv_func_vfork_works=yes
14496 else
14497 ac_cv_func_vfork_works=no
14499 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14500 conftest.$ac_objext conftest.beam conftest.$ac_ext
14504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14505 $as_echo "$ac_cv_func_vfork_works" >&6; }
14508 if test "x$ac_cv_func_fork_works" = xcross; then
14509 ac_cv_func_vfork_works=$ac_cv_func_vfork
14510 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14511 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14514 if test "x$ac_cv_func_vfork_works" = xyes; then
14516 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14518 else
14520 $as_echo "#define vfork fork" >>confdefs.h
14523 if test "x$ac_cv_func_fork_works" = xyes; then
14525 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14530 for ac_func in snprintf
14531 do :
14532 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14533 if test "x$ac_cv_func_snprintf" = x""yes; then :
14534 cat >>confdefs.h <<_ACEOF
14535 #define HAVE_SNPRINTF 1
14536 _ACEOF
14539 done
14542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14543 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14544 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14545 $as_echo_n "(cached) " >&6
14546 else
14547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14548 /* end confdefs.h. */
14549 #include <langinfo.h>
14551 main ()
14553 char* cs = nl_langinfo(CODESET);
14555 return 0;
14557 _ACEOF
14558 if ac_fn_c_try_link "$LINENO"; then :
14559 emacs_cv_langinfo_codeset=yes
14560 else
14561 emacs_cv_langinfo_codeset=no
14563 rm -f core conftest.err conftest.$ac_objext \
14564 conftest$ac_exeext conftest.$ac_ext
14567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14568 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14569 if test $emacs_cv_langinfo_codeset = yes; then
14571 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14576 $as_echo_n "checking for mbstate_t... " >&6; }
14577 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14578 $as_echo_n "(cached) " >&6
14579 else
14580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14581 /* end confdefs.h. */
14582 $ac_includes_default
14583 # include <wchar.h>
14585 main ()
14587 mbstate_t x; return sizeof x;
14589 return 0;
14591 _ACEOF
14592 if ac_fn_c_try_compile "$LINENO"; then :
14593 ac_cv_type_mbstate_t=yes
14594 else
14595 ac_cv_type_mbstate_t=no
14597 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
14600 $as_echo "$ac_cv_type_mbstate_t" >&6; }
14601 if test $ac_cv_type_mbstate_t = yes; then
14603 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
14605 else
14607 $as_echo "#define mbstate_t int" >>confdefs.h
14611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
14612 $as_echo_n "checking for C restricted array declarations... " >&6; }
14613 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
14614 $as_echo_n "(cached) " >&6
14615 else
14616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14617 /* end confdefs.h. */
14618 void fred (int x[__restrict]);
14620 main ()
14624 return 0;
14626 _ACEOF
14627 if ac_fn_c_try_compile "$LINENO"; then :
14628 emacs_cv_c_restrict_arr=yes
14629 else
14630 emacs_cv_c_restrict_arr=no
14632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
14635 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
14636 if test "$emacs_cv_c_restrict_arr" = yes; then
14638 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
14644 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
14648 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
14655 ## Note: PTYs are broken on darwin <6. Use at your own risk.
14657 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
14661 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
14667 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
14671 $as_echo "#define SEPCHAR ':'" >>confdefs.h
14675 $as_echo "#define subprocesses 1" >>confdefs.h
14679 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
14686 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
14690 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
14694 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
14700 case $opsys in
14701 aix4-2)
14702 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
14703 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14708 hpux*)
14709 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14712 esac
14715 case $opsys in
14716 darwin | gnu | hpux* | *bsd )
14718 $as_echo "#define NO_TERMIO 1" >>confdefs.h
14722 irix6-5 | sol2* | unixware )
14724 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
14727 esac
14730 case $opsys in
14731 hpux* | irix6-5 | openbsd | sol2* | unixware )
14733 $as_echo "#define BROKEN_SIGIO 1" >>confdefs.h
14737 aix4-2)
14739 $as_echo "#define BROKEN_FIONREAD 1" >>confdefs.h
14742 $as_echo "#define BROKEN_SIGAIO 1" >>confdefs.h
14745 $as_echo "#define BROKEN_SIGPOLL 1" >>confdefs.h
14748 $as_echo "#define BROKEN_SIGPTY 1" >>confdefs.h
14752 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
14756 freebsd)
14758 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
14762 darwin)
14764 $as_echo "#define NO_ABORT 1" >>confdefs.h
14767 esac
14769 case $opsys in
14770 gnu-* | sol2-10 )
14772 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
14775 esac
14777 case $opsys in
14778 darwin | freebsd | netbsd | openbsd )
14780 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
14783 esac
14785 case $opsys in
14786 netbsd | openbsd) sound_device="/dev/audio" ;;
14787 *) sound_device="/dev/dsp" ;;
14788 esac
14791 cat >>confdefs.h <<_ACEOF
14792 #define DEFAULT_SOUND_DEVICE "$sound_device"
14793 _ACEOF
14797 case $opsys in
14798 darwin | gnu-linux | gnu-kfreebsd )
14800 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
14803 esac
14806 case $opsys in
14807 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
14809 $as_echo "#define NARROWPROTO 1" >>confdefs.h
14812 esac
14821 case $opsys in
14822 aix4-2 )
14823 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++) " >>confdefs.h
14825 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\"); " >>confdefs.h
14827 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd)); " >>confdefs.h
14831 cygwin )
14832 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++) " >>confdefs.h
14834 $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
14836 $as_echo "#define PTY_NAME_SPRINTF " >>confdefs.h
14838 $as_echo "#define PTY_TTY_NAME_SPRINTF " >>confdefs.h
14842 darwin )
14843 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++) " >>confdefs.h
14845 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14847 $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
14849 $as_echo "#define PTY_NAME_SPRINTF " >>confdefs.h
14851 $as_echo "#define PTY_TTY_NAME_SPRINTF " >>confdefs.h
14855 gnu | freebsd | netbsd | openbsd )
14856 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14860 gnu-linux | gnu-kfreebsd )
14861 if test "x$ac_cv_func_grantpt" = xyes; then
14863 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
14865 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++) " >>confdefs.h
14867 $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
14869 if test "x$ac_cv_func_getpt" = xyes; then
14870 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
14872 $as_echo "#define PTY_NAME_SPRINTF " >>confdefs.h
14874 else
14875 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\"); " >>confdefs.h
14878 else
14879 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14884 hpux*)
14885 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
14887 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i); " >>confdefs.h
14889 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i); " >>confdefs.h
14893 irix6-5 )
14894 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
14896 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
14898 $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
14900 $as_echo "#define PTY_NAME_SPRINTF " >>confdefs.h
14902 $as_echo "#define PTY_TTY_NAME_SPRINTF " >>confdefs.h
14906 sol2* )
14907 $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
14911 unixware )
14912 $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
14915 esac
14918 case $opsys in
14919 sol2* | unixware )
14920 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
14922 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\"); " >>confdefs.h
14925 $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
14928 esac
14933 case $opsys in
14934 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
14935 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
14939 gnu-linux | gnu-kfreebsd )
14941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
14942 $as_echo_n "checking for signals via characters... " >&6; }
14943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14944 /* end confdefs.h. */
14946 #include <linux/version.h>
14947 #if LINUX_VERSION_CODE < 0x20400
14948 # error "Linux version too old"
14949 #endif
14952 main ()
14956 return 0;
14958 _ACEOF
14959 if ac_fn_c_try_cpp "$LINENO"; then :
14960 emacs_signals_via_chars=yes
14961 else
14962 emacs_signals_via_chars=no
14964 rm -f conftest.err conftest.$ac_ext
14966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
14967 $as_echo "$emacs_signals_via_chars" >&6; }
14968 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
14971 esac
14978 case $opsys in
14979 cygwin | darwin | freebsd | netbsd | openbsd )
14980 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)" >>confdefs.h
14984 unixware)
14985 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__ptr - (FILE)->__base)" >>confdefs.h
14989 gnu | gnu-linux | gnu-kfreebsd )
14990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of pending output formalism" >&5
14991 $as_echo_n "checking for style of pending output formalism... " >&6; }
14992 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14993 /* end confdefs.h. */
14995 #include <stdio.h>
14996 #if !defined (_IO_STDIO_H) && !defined (_STDIO_USES_IOSTREAM)
14997 # error "stdio definitions not found"
14998 #endif
15001 main ()
15005 return 0;
15007 _ACEOF
15008 if ac_fn_c_try_cpp "$LINENO"; then :
15009 emacs_pending_output=new
15010 else
15011 emacs_pending_output=unknown
15013 rm -f conftest.err conftest.$ac_ext
15015 if test $emacs_pending_output = unknown; then
15016 case $opsys in
15017 gnu-linux | gnu-kfreebsd)
15018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15019 /* end confdefs.h. */
15021 #include <stdio.h>
15022 #ifndef __UCLIBC__
15023 # error "not using uclibc"
15024 #endif
15027 main ()
15031 return 0;
15033 _ACEOF
15034 if ac_fn_c_try_cpp "$LINENO"; then :
15035 emacs_pending_output=uclibc
15036 else
15037 emacs_pending_output=old
15039 rm -f conftest.err conftest.$ac_ext
15041 esac
15044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_pending_output" >&5
15045 $as_echo "$emacs_pending_output" >&6; }
15047 case $emacs_pending_output in
15048 new)
15049 $as_echo "#define GNU_LIBRARY_PENDING_OUTPUT_COUNT(FILE) ((FILE)->_IO_write_ptr - (FILE)->_IO_write_base)" >>confdefs.h
15052 uclibc)
15053 $as_echo "#define GNU_LIBRARY_PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufpos - (FILE)->__bufstart)" >>confdefs.h
15056 old)
15057 $as_echo "#define GNU_LIBRARY_PENDING_OUTPUT_COUNT(FILE) ((FILE)->_pptr - (FILE)->_pbase)" >>confdefs.h
15060 esac
15062 esac
15068 case $opsys in
15069 gnu)
15070 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15074 hpux*)
15075 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15077 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15080 irix6-5)
15081 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15083 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15086 esac
15092 case $opsys in
15093 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15096 gnu | freebsd | netbsd | openbsd )
15098 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15100 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15104 gnu-linux | gnu-kfreebsd )
15105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15106 /* end confdefs.h. */
15108 #ifndef __i386__
15109 # error "not i386"
15110 #endif
15113 main ()
15117 return 0;
15119 _ACEOF
15120 if ac_fn_c_try_cpp "$LINENO"; then :
15121 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15124 rm -f conftest.err conftest.$ac_ext
15126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15127 /* end confdefs.h. */
15129 #ifndef __ia64__
15130 # error "not ia64"
15131 #endif
15134 main ()
15138 return 0;
15140 _ACEOF
15141 if ac_fn_c_try_cpp "$LINENO"; then :
15143 $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
15146 rm -f conftest.err conftest.$ac_ext
15149 hpux*)
15151 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15155 irix6-5)
15156 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15159 esac
15167 case $opsys in
15168 aix4-2 | hpux* | unixware)
15169 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15173 gnu-linux | gnu-kfreebsd )
15174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15175 /* end confdefs.h. */
15177 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15178 || defined __alpha__ || defined __mips__ || defined __s390__ \
15179 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15180 || defined __ia64__ || defined __sh__
15181 /* ok */
15182 #else
15183 # error "setjmp not known to work on this arch"
15184 #endif
15187 main ()
15191 return 0;
15193 _ACEOF
15194 if ac_fn_c_try_cpp "$LINENO"; then :
15195 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15197 else
15198 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15201 rm -f conftest.err conftest.$ac_ext
15203 esac
15206 if test x$GCC = xyes; then
15207 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15209 else
15210 case $opsys in
15211 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15212 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15215 esac
15218 case $opsys in
15219 sol2* | unixware )
15221 $as_echo "#define _setjmp setjmp" >>confdefs.h
15224 $as_echo "#define _longjmp longjmp" >>confdefs.h
15227 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15230 esac
15232 case $opsys in
15233 irix6-5 | sol2* | unixware )
15235 $as_echo "#define wait3(status, options, rusage) waitpid ((pid_t) -1, (status), (options))" >>confdefs.h
15238 $as_echo "#define WRETCODE(w) (w >> 8)" >>confdefs.h
15241 esac
15244 case $opsys in
15245 hpux* | sol2* )
15247 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15251 netbsd | openbsd )
15253 $as_echo "#define SIGNAL_H_AHB 1" >>confdefs.h
15256 esac
15265 case $opsys in
15266 aix4-2)
15267 $as_echo "#define USG /**/" >>confdefs.h
15269 $as_echo "#define USG5 /**/" >>confdefs.h
15271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15272 /* end confdefs.h. */
15274 #ifndef _AIX
15275 # error "_AIX not defined"
15276 #endif
15279 main ()
15283 return 0;
15285 _ACEOF
15286 if ac_fn_c_try_cpp "$LINENO"; then :
15288 else
15290 $as_echo "#define _AIX /**/" >>confdefs.h
15293 rm -f conftest.err conftest.$ac_ext
15296 cygwin)
15298 $as_echo "#define CYGWIN 1" >>confdefs.h
15302 darwin)
15303 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15305 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15308 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15312 freebsd)
15313 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15316 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15320 gnu | netbsd | openbsd )
15321 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15324 /* end confdefs.h. */
15326 #ifndef BSD_SYSTEM
15327 # error "BSD_SYSTEM not defined"
15328 #endif
15331 main ()
15335 return 0;
15337 _ACEOF
15338 if ac_fn_c_try_cpp "$LINENO"; then :
15340 else
15341 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15344 rm -f conftest.err conftest.$ac_ext
15347 gnu-linux | gnu-kfreebsd )
15348 $as_echo "#define USG /**/" >>confdefs.h
15351 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15355 hpux*)
15356 $as_echo "#define USG /**/" >>confdefs.h
15358 $as_echo "#define USG5 /**/" >>confdefs.h
15361 $as_echo "#define HPUX /**/" >>confdefs.h
15365 irix6-5)
15366 $as_echo "#define USG /**/" >>confdefs.h
15368 $as_echo "#define USG5 /**/" >>confdefs.h
15370 $as_echo "#define USG5_4 /**/" >>confdefs.h
15373 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15377 sol2*)
15378 $as_echo "#define USG /**/" >>confdefs.h
15380 $as_echo "#define USG5 /**/" >>confdefs.h
15382 $as_echo "#define USG5_4 /**/" >>confdefs.h
15385 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15389 unixware)
15390 $as_echo "#define USG /**/" >>confdefs.h
15392 $as_echo "#define USG5 /**/" >>confdefs.h
15394 $as_echo "#define USG5_4 /**/" >>confdefs.h
15397 esac
15400 case $opsys in
15401 cygwin)
15403 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15407 hpux11)
15409 $as_echo "#define BROKEN_SA_RESTART 1" >>confdefs.h
15412 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15416 irix6-5)
15418 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15421 $as_echo "#define SETPGRP_RELEASES_CTTY 1" >>confdefs.h
15425 sol2-10)
15427 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15430 esac
15432 # Set up the CFLAGS for real compilation, so we can substitute it.
15433 CFLAGS="$REAL_CFLAGS"
15434 CPPFLAGS="$REAL_CPPFLAGS"
15436 ## Hack to detect a buggy GCC version.
15437 if test "x$GCC" = xyes \
15438 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15439 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15440 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15441 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15444 version=$PACKAGE_VERSION
15446 ### Specify what sort of things we'll be editing into Makefile and config.h.
15447 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15450 ## Unused?
15473 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15474 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15475 ## end of LIBX_BASE, but nothing ever set it.
15480 ## Used in lwlib/Makefile.in.
15490 cat >>confdefs.h <<_ACEOF
15491 #define EMACS_CONFIGURATION "${canonical}"
15492 _ACEOF
15495 cat >>confdefs.h <<_ACEOF
15496 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15497 _ACEOF
15501 XMENU_OBJ=
15502 XOBJ=
15503 FONT_OBJ=
15504 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15506 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15508 XMENU_OBJ=xmenu.o
15509 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
15510 FONT_OBJ=xfont.o
15511 if test "$HAVE_XFT" = "yes"; then
15512 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15513 elif test "$HAVE_FREETYPE" = "yes"; then
15514 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15522 WIDGET_OBJ=
15523 MOTIF_LIBW=
15524 if test "${USE_X_TOOLKIT}" != "none" ; then
15525 WIDGET_OBJ=widget.o
15527 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15529 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15531 $as_echo "#define USE_LUCID 1" >>confdefs.h
15533 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15535 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15537 MOTIF_LIBW=-lXm
15538 case "$opsys" in
15539 gnu-linux)
15540 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15541 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15544 unixware)
15545 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15546 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15547 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15550 aix4-2)
15551 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15552 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15554 esac
15555 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15560 TOOLKIT_LIBW=
15561 case "$USE_X_TOOLKIT" in
15562 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15563 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15564 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15565 esac
15568 if test "$USE_X_TOOLKIT" = "none"; then
15569 LIBXT_OTHER="\$(LIBXSM)"
15570 OLDXMENU_TARGET="really-oldXMenu"
15571 else
15572 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15573 OLDXMENU_TARGET="really-lwlib"
15577 ## The X Menu stuff is present in the X10 distribution, but missing
15578 ## from X11. If we have X10, just use the installed library;
15579 ## otherwise, use our own copy.
15580 if test "${HAVE_X11}" = "yes" ; then
15582 $as_echo "#define HAVE_X11 1" >>confdefs.h
15585 if test "$USE_X_TOOLKIT" = "none"; then
15586 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15587 else
15588 OLDXMENU="\${lwlibdir}/liblw.a"
15590 LIBXMENU="\$(OLDXMENU)"
15591 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15592 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
15593 else
15594 ## For a syntactically valid Makefile; not actually used for anything.
15595 ## See comments in src/Makefile.in.
15596 OLDXMENU=nothing
15597 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15598 if test "${HAVE_X_WINDOWS}" = "yes"; then
15599 LIBXMENU="-lXMenu"
15600 else
15601 LIBXMENU=
15603 LIBX_OTHER=
15604 OLDXMENU_DEPS=
15607 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15608 OLDXMENU_TARGET=
15609 OLDXMENU=nothing
15610 LIBXMENU=
15611 OLDXMENU_DEPS=
15620 if test "${HAVE_MENUS}" = "yes" ; then
15622 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
15626 if test "${GNU_MALLOC}" = "yes" ; then
15628 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
15632 RALLOC_OBJ=
15633 if test "${REL_ALLOC}" = "yes" ; then
15635 $as_echo "#define REL_ALLOC 1" >>confdefs.h
15638 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
15642 if test "$opsys" = "cygwin"; then
15643 CYGWIN_OBJ="sheap.o"
15644 ## Cygwin differs because of its unexec().
15645 PRE_ALLOC_OBJ=
15646 POST_ALLOC_OBJ=lastfile.o
15647 else
15648 CYGWIN_OBJ=
15649 PRE_ALLOC_OBJ=lastfile.o
15650 POST_ALLOC_OBJ=
15656 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
15657 # it temporarily reverts them to their pre-pkg-config values,
15658 # because gnulib needs to work with both src (which uses the
15659 # pkg-config stuff) and lib-src (which does not). For example, gnulib
15660 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
15661 # and it therefore needs to run in an environment where LIBS does not
15662 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
15663 # for some package unrelated to lib-src.
15664 SAVE_CFLAGS=$CFLAGS
15665 SAVE_LIBS=$LIBS
15666 CFLAGS=$pre_PKG_CONFIG_CFLAGS
15667 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
15679 LIBC_FATAL_STDERR_=1
15680 export LIBC_FATAL_STDERR_
15682 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15683 # for constant arguments. Useless!
15684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15685 $as_echo_n "checking for working alloca.h... " >&6; }
15686 if test "${ac_cv_working_alloca_h+set}" = set; then :
15687 $as_echo_n "(cached) " >&6
15688 else
15689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15690 /* end confdefs.h. */
15691 #include <alloca.h>
15693 main ()
15695 char *p = (char *) alloca (2 * sizeof (int));
15696 if (p) return 0;
15698 return 0;
15700 _ACEOF
15701 if ac_fn_c_try_link "$LINENO"; then :
15702 ac_cv_working_alloca_h=yes
15703 else
15704 ac_cv_working_alloca_h=no
15706 rm -f core conftest.err conftest.$ac_objext \
15707 conftest$ac_exeext conftest.$ac_ext
15709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
15710 $as_echo "$ac_cv_working_alloca_h" >&6; }
15711 if test $ac_cv_working_alloca_h = yes; then
15713 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
15717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
15718 $as_echo_n "checking for alloca... " >&6; }
15719 if test "${ac_cv_func_alloca_works+set}" = set; then :
15720 $as_echo_n "(cached) " >&6
15721 else
15722 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15723 /* end confdefs.h. */
15724 #ifdef __GNUC__
15725 # define alloca __builtin_alloca
15726 #else
15727 # ifdef _MSC_VER
15728 # include <malloc.h>
15729 # define alloca _alloca
15730 # else
15731 # ifdef HAVE_ALLOCA_H
15732 # include <alloca.h>
15733 # else
15734 # ifdef _AIX
15735 #pragma alloca
15736 # else
15737 # ifndef alloca /* predefined by HP cc +Olibcalls */
15738 char *alloca ();
15739 # endif
15740 # endif
15741 # endif
15742 # endif
15743 #endif
15746 main ()
15748 char *p = (char *) alloca (1);
15749 if (p) return 0;
15751 return 0;
15753 _ACEOF
15754 if ac_fn_c_try_link "$LINENO"; then :
15755 ac_cv_func_alloca_works=yes
15756 else
15757 ac_cv_func_alloca_works=no
15759 rm -f core conftest.err conftest.$ac_objext \
15760 conftest$ac_exeext conftest.$ac_ext
15762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
15763 $as_echo "$ac_cv_func_alloca_works" >&6; }
15765 if test $ac_cv_func_alloca_works = yes; then
15767 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
15769 else
15770 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
15771 # that cause trouble. Some versions do not even contain alloca or
15772 # contain a buggy version. If you still want to use their alloca,
15773 # use ar to extract alloca.o from them instead of compiling alloca.c.
15779 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
15781 $as_echo "#define C_ALLOCA 1" >>confdefs.h
15784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
15785 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
15786 if test "${ac_cv_os_cray+set}" = set; then :
15787 $as_echo_n "(cached) " >&6
15788 else
15789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15790 /* end confdefs.h. */
15791 #if defined CRAY && ! defined CRAY2
15792 webecray
15793 #else
15794 wenotbecray
15795 #endif
15797 _ACEOF
15798 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15799 $EGREP "webecray" >/dev/null 2>&1; then :
15800 ac_cv_os_cray=yes
15801 else
15802 ac_cv_os_cray=no
15804 rm -f conftest*
15807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
15808 $as_echo "$ac_cv_os_cray" >&6; }
15809 if test $ac_cv_os_cray = yes; then
15810 for ac_func in _getb67 GETB67 getb67; do
15811 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15812 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15813 eval as_val=\$$as_ac_var
15814 if test "x$as_val" = x""yes; then :
15816 cat >>confdefs.h <<_ACEOF
15817 #define CRAY_STACKSEG_END $ac_func
15818 _ACEOF
15820 break
15823 done
15826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
15827 $as_echo_n "checking stack direction for C alloca... " >&6; }
15828 if test "${ac_cv_c_stack_direction+set}" = set; then :
15829 $as_echo_n "(cached) " >&6
15830 else
15831 if test "$cross_compiling" = yes; then :
15832 ac_cv_c_stack_direction=0
15833 else
15834 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15835 /* end confdefs.h. */
15836 $ac_includes_default
15838 find_stack_direction (int *addr, int depth)
15840 int dir, dummy = 0;
15841 if (! addr)
15842 addr = &dummy;
15843 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
15844 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
15845 return dir + dummy;
15849 main (int argc, char **argv)
15851 return find_stack_direction (0, argc + !argv + 20) < 0;
15853 _ACEOF
15854 if ac_fn_c_try_run "$LINENO"; then :
15855 ac_cv_c_stack_direction=1
15856 else
15857 ac_cv_c_stack_direction=-1
15859 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15860 conftest.$ac_objext conftest.beam conftest.$ac_ext
15864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
15865 $as_echo "$ac_cv_c_stack_direction" >&6; }
15866 cat >>confdefs.h <<_ACEOF
15867 #define STACK_DIRECTION $ac_cv_c_stack_direction
15868 _ACEOF
15876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
15877 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
15878 if test "${ac_cv_c_bigendian+set}" = set; then :
15879 $as_echo_n "(cached) " >&6
15880 else
15881 ac_cv_c_bigendian=unknown
15882 # See if we're dealing with a universal compiler.
15883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15884 /* end confdefs.h. */
15885 #ifndef __APPLE_CC__
15886 not a universal capable compiler
15887 #endif
15888 typedef int dummy;
15890 _ACEOF
15891 if ac_fn_c_try_compile "$LINENO"; then :
15893 # Check for potential -arch flags. It is not universal unless
15894 # there are at least two -arch flags with different values.
15895 ac_arch=
15896 ac_prev=
15897 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
15898 if test -n "$ac_prev"; then
15899 case $ac_word in
15900 i?86 | x86_64 | ppc | ppc64)
15901 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
15902 ac_arch=$ac_word
15903 else
15904 ac_cv_c_bigendian=universal
15905 break
15908 esac
15909 ac_prev=
15910 elif test "x$ac_word" = "x-arch"; then
15911 ac_prev=arch
15913 done
15915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15916 if test $ac_cv_c_bigendian = unknown; then
15917 # See if sys/param.h defines the BYTE_ORDER macro.
15918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15919 /* end confdefs.h. */
15920 #include <sys/types.h>
15921 #include <sys/param.h>
15924 main ()
15926 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
15927 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
15928 && LITTLE_ENDIAN)
15929 bogus endian macros
15930 #endif
15933 return 0;
15935 _ACEOF
15936 if ac_fn_c_try_compile "$LINENO"; then :
15937 # It does; now see whether it defined to BIG_ENDIAN or not.
15938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15939 /* end confdefs.h. */
15940 #include <sys/types.h>
15941 #include <sys/param.h>
15944 main ()
15946 #if BYTE_ORDER != BIG_ENDIAN
15947 not big endian
15948 #endif
15951 return 0;
15953 _ACEOF
15954 if ac_fn_c_try_compile "$LINENO"; then :
15955 ac_cv_c_bigendian=yes
15956 else
15957 ac_cv_c_bigendian=no
15959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15961 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15963 if test $ac_cv_c_bigendian = unknown; then
15964 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
15965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15966 /* end confdefs.h. */
15967 #include <limits.h>
15970 main ()
15972 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
15973 bogus endian macros
15974 #endif
15977 return 0;
15979 _ACEOF
15980 if ac_fn_c_try_compile "$LINENO"; then :
15981 # It does; now see whether it defined to _BIG_ENDIAN or not.
15982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15983 /* end confdefs.h. */
15984 #include <limits.h>
15987 main ()
15989 #ifndef _BIG_ENDIAN
15990 not big endian
15991 #endif
15994 return 0;
15996 _ACEOF
15997 if ac_fn_c_try_compile "$LINENO"; then :
15998 ac_cv_c_bigendian=yes
15999 else
16000 ac_cv_c_bigendian=no
16002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16006 if test $ac_cv_c_bigendian = unknown; then
16007 # Compile a test program.
16008 if test "$cross_compiling" = yes; then :
16009 # Try to guess by grepping values from an object file.
16010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16011 /* end confdefs.h. */
16012 short int ascii_mm[] =
16013 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16014 short int ascii_ii[] =
16015 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16016 int use_ascii (int i) {
16017 return ascii_mm[i] + ascii_ii[i];
16019 short int ebcdic_ii[] =
16020 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16021 short int ebcdic_mm[] =
16022 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16023 int use_ebcdic (int i) {
16024 return ebcdic_mm[i] + ebcdic_ii[i];
16026 extern int foo;
16029 main ()
16031 return use_ascii (foo) == use_ebcdic (foo);
16033 return 0;
16035 _ACEOF
16036 if ac_fn_c_try_compile "$LINENO"; then :
16037 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16038 ac_cv_c_bigendian=yes
16040 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16041 if test "$ac_cv_c_bigendian" = unknown; then
16042 ac_cv_c_bigendian=no
16043 else
16044 # finding both strings is unlikely to happen, but who knows?
16045 ac_cv_c_bigendian=unknown
16049 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16050 else
16051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16052 /* end confdefs.h. */
16053 $ac_includes_default
16055 main ()
16058 /* Are we little or big endian? From Harbison&Steele. */
16059 union
16061 long int l;
16062 char c[sizeof (long int)];
16063 } u;
16064 u.l = 1;
16065 return u.c[sizeof (long int) - 1] == 1;
16068 return 0;
16070 _ACEOF
16071 if ac_fn_c_try_run "$LINENO"; then :
16072 ac_cv_c_bigendian=no
16073 else
16074 ac_cv_c_bigendian=yes
16076 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16077 conftest.$ac_objext conftest.beam conftest.$ac_ext
16082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16083 $as_echo "$ac_cv_c_bigendian" >&6; }
16084 case $ac_cv_c_bigendian in #(
16085 yes)
16086 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16087 ;; #(
16089 ;; #(
16090 universal)
16092 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16094 ;; #(
16096 as_fn_error "unknown endianness
16097 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16098 esac
16101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16102 $as_echo_n "checking for inline... " >&6; }
16103 if test "${ac_cv_c_inline+set}" = set; then :
16104 $as_echo_n "(cached) " >&6
16105 else
16106 ac_cv_c_inline=no
16107 for ac_kw in inline __inline__ __inline; do
16108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16109 /* end confdefs.h. */
16110 #ifndef __cplusplus
16111 typedef int foo_t;
16112 static $ac_kw foo_t static_foo () {return 0; }
16113 $ac_kw foo_t foo () {return 0; }
16114 #endif
16116 _ACEOF
16117 if ac_fn_c_try_compile "$LINENO"; then :
16118 ac_cv_c_inline=$ac_kw
16120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16121 test "$ac_cv_c_inline" != no && break
16122 done
16125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16126 $as_echo "$ac_cv_c_inline" >&6; }
16128 case $ac_cv_c_inline in
16129 inline | yes) ;;
16131 case $ac_cv_c_inline in
16132 no) ac_val=;;
16133 *) ac_val=$ac_cv_c_inline;;
16134 esac
16135 cat >>confdefs.h <<_ACEOF
16136 #ifndef __cplusplus
16137 #define inline $ac_val
16138 #endif
16139 _ACEOF
16141 esac
16144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16145 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16146 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16147 $as_echo_n "(cached) " >&6
16148 else
16149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16150 /* end confdefs.h. */
16151 /* On HP-UX before 11.23, strtold returns a struct instead of
16152 long double. Reject implementations like that, by requiring
16153 compatibility with the C99 prototype. */
16154 #include <stdlib.h>
16155 static long double (*p) (char const *, char **) = strtold;
16156 static long double
16157 test (char const *nptr, char **endptr)
16159 long double r;
16160 r = strtold (nptr, endptr);
16161 return r;
16164 main ()
16166 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16168 return 0;
16170 _ACEOF
16171 if ac_fn_c_try_link "$LINENO"; then :
16172 gl_cv_func_c99_strtold=yes
16173 else
16174 gl_cv_func_c99_strtold=no
16176 rm -f core conftest.err conftest.$ac_objext \
16177 conftest$ac_exeext conftest.$ac_ext
16179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16180 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16181 if test $gl_cv_func_c99_strtold = yes; then
16183 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16188 GNULIB_CHDIR=0;
16189 GNULIB_CHOWN=0;
16190 GNULIB_CLOSE=0;
16191 GNULIB_DUP=0;
16192 GNULIB_DUP2=0;
16193 GNULIB_DUP3=0;
16194 GNULIB_ENVIRON=0;
16195 GNULIB_EUIDACCESS=0;
16196 GNULIB_FACCESSAT=0;
16197 GNULIB_FCHDIR=0;
16198 GNULIB_FCHOWNAT=0;
16199 GNULIB_FDATASYNC=0;
16200 GNULIB_FSYNC=0;
16201 GNULIB_FTRUNCATE=0;
16202 GNULIB_GETCWD=0;
16203 GNULIB_GETDOMAINNAME=0;
16204 GNULIB_GETDTABLESIZE=0;
16205 GNULIB_GETGROUPS=0;
16206 GNULIB_GETHOSTNAME=0;
16207 GNULIB_GETLOGIN=0;
16208 GNULIB_GETLOGIN_R=0;
16209 GNULIB_GETPAGESIZE=0;
16210 GNULIB_GETUSERSHELL=0;
16211 GNULIB_GROUP_MEMBER=0;
16212 GNULIB_ISATTY=0;
16213 GNULIB_LCHOWN=0;
16214 GNULIB_LINK=0;
16215 GNULIB_LINKAT=0;
16216 GNULIB_LSEEK=0;
16217 GNULIB_PIPE=0;
16218 GNULIB_PIPE2=0;
16219 GNULIB_PREAD=0;
16220 GNULIB_PWRITE=0;
16221 GNULIB_READ=0;
16222 GNULIB_READLINK=0;
16223 GNULIB_READLINKAT=0;
16224 GNULIB_RMDIR=0;
16225 GNULIB_SETHOSTNAME=0;
16226 GNULIB_SLEEP=0;
16227 GNULIB_SYMLINK=0;
16228 GNULIB_SYMLINKAT=0;
16229 GNULIB_TTYNAME_R=0;
16230 GNULIB_UNISTD_H_NONBLOCKING=0;
16231 GNULIB_UNISTD_H_SIGPIPE=0;
16232 GNULIB_UNLINK=0;
16233 GNULIB_UNLINKAT=0;
16234 GNULIB_USLEEP=0;
16235 GNULIB_WRITE=0;
16236 HAVE_CHOWN=1;
16237 HAVE_DUP2=1;
16238 HAVE_DUP3=1;
16239 HAVE_EUIDACCESS=1;
16240 HAVE_FACCESSAT=1;
16241 HAVE_FCHDIR=1;
16242 HAVE_FCHOWNAT=1;
16243 HAVE_FDATASYNC=1;
16244 HAVE_FSYNC=1;
16245 HAVE_FTRUNCATE=1;
16246 HAVE_GETDTABLESIZE=1;
16247 HAVE_GETGROUPS=1;
16248 HAVE_GETHOSTNAME=1;
16249 HAVE_GETLOGIN=1;
16250 HAVE_GETPAGESIZE=1;
16251 HAVE_GROUP_MEMBER=1;
16252 HAVE_LCHOWN=1;
16253 HAVE_LINK=1;
16254 HAVE_LINKAT=1;
16255 HAVE_PIPE=1;
16256 HAVE_PIPE2=1;
16257 HAVE_PREAD=1;
16258 HAVE_PWRITE=1;
16259 HAVE_READLINK=1;
16260 HAVE_READLINKAT=1;
16261 HAVE_SETHOSTNAME=1;
16262 HAVE_SLEEP=1;
16263 HAVE_SYMLINK=1;
16264 HAVE_SYMLINKAT=1;
16265 HAVE_UNLINKAT=1;
16266 HAVE_USLEEP=1;
16267 HAVE_DECL_ENVIRON=1;
16268 HAVE_DECL_FCHDIR=1;
16269 HAVE_DECL_FDATASYNC=1;
16270 HAVE_DECL_GETDOMAINNAME=1;
16271 HAVE_DECL_GETLOGIN_R=1;
16272 HAVE_DECL_GETPAGESIZE=1;
16273 HAVE_DECL_GETUSERSHELL=1;
16274 HAVE_DECL_SETHOSTNAME=1;
16275 HAVE_DECL_TTYNAME_R=1;
16276 HAVE_OS_H=0;
16277 HAVE_SYS_PARAM_H=0;
16278 REPLACE_CHOWN=0;
16279 REPLACE_CLOSE=0;
16280 REPLACE_DUP=0;
16281 REPLACE_DUP2=0;
16282 REPLACE_FCHOWNAT=0;
16283 REPLACE_FTRUNCATE=0;
16284 REPLACE_GETCWD=0;
16285 REPLACE_GETDOMAINNAME=0;
16286 REPLACE_GETLOGIN_R=0;
16287 REPLACE_GETGROUPS=0;
16288 REPLACE_GETPAGESIZE=0;
16289 REPLACE_ISATTY=0;
16290 REPLACE_LCHOWN=0;
16291 REPLACE_LINK=0;
16292 REPLACE_LINKAT=0;
16293 REPLACE_LSEEK=0;
16294 REPLACE_PREAD=0;
16295 REPLACE_PWRITE=0;
16296 REPLACE_READ=0;
16297 REPLACE_READLINK=0;
16298 REPLACE_RMDIR=0;
16299 REPLACE_SLEEP=0;
16300 REPLACE_SYMLINK=0;
16301 REPLACE_TTYNAME_R=0;
16302 REPLACE_UNLINK=0;
16303 REPLACE_UNLINKAT=0;
16304 REPLACE_USLEEP=0;
16305 REPLACE_WRITE=0;
16306 UNISTD_H_HAVE_WINSOCK2_H=0;
16307 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16318 $as_echo_n "checking if environ is properly declared... " >&6; }
16319 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16320 $as_echo_n "(cached) " >&6
16321 else
16323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16324 /* end confdefs.h. */
16325 #if HAVE_UNISTD_H
16326 #include <unistd.h>
16327 #endif
16328 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16329 #include <stdlib.h>
16331 extern struct { int foo; } environ;
16333 main ()
16335 environ.foo = 1;
16337 return 0;
16339 _ACEOF
16340 if ac_fn_c_try_compile "$LINENO"; then :
16341 gt_cv_var_environ_declaration=no
16342 else
16343 gt_cv_var_environ_declaration=yes
16345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16349 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16350 if test $gt_cv_var_environ_declaration = yes; then
16352 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16357 if test $gt_cv_var_environ_declaration != yes; then
16358 HAVE_DECL_ENVIRON=0
16361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16362 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16363 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16364 $as_echo_n "(cached) " >&6
16365 else
16366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16367 /* end confdefs.h. */
16369 #include <sys/types.h>
16370 #include <sys/stat.h>
16372 main ()
16374 struct stat s; s.st_dm_mode;
16376 return 0;
16378 _ACEOF
16379 if ac_fn_c_try_compile "$LINENO"; then :
16380 ac_cv_struct_st_dm_mode=yes
16381 else
16382 ac_cv_struct_st_dm_mode=no
16384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16387 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16389 if test $ac_cv_struct_st_dm_mode = yes; then
16391 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16396 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16397 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16398 ac_have_decl=1
16399 else
16400 ac_have_decl=0
16403 cat >>confdefs.h <<_ACEOF
16404 #define HAVE_DECL_STRMODE $ac_have_decl
16405 _ACEOF
16408 GNULIB__EXIT=0;
16409 GNULIB_ATOLL=0;
16410 GNULIB_CALLOC_POSIX=0;
16411 GNULIB_CANONICALIZE_FILE_NAME=0;
16412 GNULIB_GETLOADAVG=0;
16413 GNULIB_GETSUBOPT=0;
16414 GNULIB_GRANTPT=0;
16415 GNULIB_MALLOC_POSIX=0;
16416 GNULIB_MBTOWC=0;
16417 GNULIB_MKDTEMP=0;
16418 GNULIB_MKOSTEMP=0;
16419 GNULIB_MKOSTEMPS=0;
16420 GNULIB_MKSTEMP=0;
16421 GNULIB_MKSTEMPS=0;
16422 GNULIB_POSIX_OPENPT=0;
16423 GNULIB_PTSNAME=0;
16424 GNULIB_PTSNAME_R=0;
16425 GNULIB_PUTENV=0;
16426 GNULIB_RANDOM=0;
16427 GNULIB_RANDOM_R=0;
16428 GNULIB_REALLOC_POSIX=0;
16429 GNULIB_REALPATH=0;
16430 GNULIB_RPMATCH=0;
16431 GNULIB_SETENV=0;
16432 GNULIB_STRTOD=0;
16433 GNULIB_STRTOLL=0;
16434 GNULIB_STRTOULL=0;
16435 GNULIB_SYSTEM_POSIX=0;
16436 GNULIB_UNLOCKPT=0;
16437 GNULIB_UNSETENV=0;
16438 GNULIB_WCTOMB=0;
16439 HAVE__EXIT=1;
16440 HAVE_ATOLL=1;
16441 HAVE_CANONICALIZE_FILE_NAME=1;
16442 HAVE_DECL_GETLOADAVG=1;
16443 HAVE_GETSUBOPT=1;
16444 HAVE_GRANTPT=1;
16445 HAVE_MKDTEMP=1;
16446 HAVE_MKOSTEMP=1;
16447 HAVE_MKOSTEMPS=1;
16448 HAVE_MKSTEMP=1;
16449 HAVE_MKSTEMPS=1;
16450 HAVE_POSIX_OPENPT=1;
16451 HAVE_PTSNAME=1;
16452 HAVE_PTSNAME_R=1;
16453 HAVE_RANDOM=1;
16454 HAVE_RANDOM_H=1;
16455 HAVE_RANDOM_R=1;
16456 HAVE_REALPATH=1;
16457 HAVE_RPMATCH=1;
16458 HAVE_SETENV=1;
16459 HAVE_DECL_SETENV=1;
16460 HAVE_STRTOD=1;
16461 HAVE_STRTOLL=1;
16462 HAVE_STRTOULL=1;
16463 HAVE_STRUCT_RANDOM_DATA=1;
16464 HAVE_SYS_LOADAVG_H=0;
16465 HAVE_UNLOCKPT=1;
16466 HAVE_DECL_UNSETENV=1;
16467 REPLACE_CALLOC=0;
16468 REPLACE_CANONICALIZE_FILE_NAME=0;
16469 REPLACE_MALLOC=0;
16470 REPLACE_MBTOWC=0;
16471 REPLACE_MKSTEMP=0;
16472 REPLACE_PTSNAME_R=0;
16473 REPLACE_PUTENV=0;
16474 REPLACE_RANDOM_R=0;
16475 REPLACE_REALLOC=0;
16476 REPLACE_REALPATH=0;
16477 REPLACE_SETENV=0;
16478 REPLACE_STRTOD=0;
16479 REPLACE_UNSETENV=0;
16480 REPLACE_WCTOMB=0;
16484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16485 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16486 if test "${gl_cv_have_include_next+set}" = set; then :
16487 $as_echo_n "(cached) " >&6
16488 else
16489 rm -rf conftestd1a conftestd1b conftestd2
16490 mkdir conftestd1a conftestd1b conftestd2
16491 cat <<EOF > conftestd1a/conftest.h
16492 #define DEFINED_IN_CONFTESTD1
16493 #include_next <conftest.h>
16494 #ifdef DEFINED_IN_CONFTESTD2
16495 int foo;
16496 #else
16497 #error "include_next doesn't work"
16498 #endif
16500 cat <<EOF > conftestd1b/conftest.h
16501 #define DEFINED_IN_CONFTESTD1
16502 #include <stdio.h>
16503 #include_next <conftest.h>
16504 #ifdef DEFINED_IN_CONFTESTD2
16505 int foo;
16506 #else
16507 #error "include_next doesn't work"
16508 #endif
16510 cat <<EOF > conftestd2/conftest.h
16511 #ifndef DEFINED_IN_CONFTESTD1
16512 #error "include_next test doesn't work"
16513 #endif
16514 #define DEFINED_IN_CONFTESTD2
16516 gl_save_CPPFLAGS="$CPPFLAGS"
16517 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16519 /* end confdefs.h. */
16520 #include <conftest.h>
16521 _ACEOF
16522 if ac_fn_c_try_compile "$LINENO"; then :
16523 gl_cv_have_include_next=yes
16524 else
16525 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16527 /* end confdefs.h. */
16528 #include <conftest.h>
16529 _ACEOF
16530 if ac_fn_c_try_compile "$LINENO"; then :
16531 gl_cv_have_include_next=buggy
16532 else
16533 gl_cv_have_include_next=no
16535 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16539 CPPFLAGS="$gl_save_CPPFLAGS"
16540 rm -rf conftestd1a conftestd1b conftestd2
16543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16544 $as_echo "$gl_cv_have_include_next" >&6; }
16545 PRAGMA_SYSTEM_HEADER=
16546 if test $gl_cv_have_include_next = yes; then
16547 INCLUDE_NEXT=include_next
16548 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16549 if test -n "$GCC"; then
16550 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16552 else
16553 if test $gl_cv_have_include_next = buggy; then
16554 INCLUDE_NEXT=include
16555 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16556 else
16557 INCLUDE_NEXT=include
16558 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16565 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16566 if test "${gl_cv_pragma_columns+set}" = set; then :
16567 $as_echo_n "(cached) " >&6
16568 else
16569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16570 /* end confdefs.h. */
16572 #ifdef __TANDEM
16573 choke me
16574 #endif
16576 _ACEOF
16577 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16578 $EGREP "choke me" >/dev/null 2>&1; then :
16579 gl_cv_pragma_columns=yes
16580 else
16581 gl_cv_pragma_columns=no
16583 rm -f conftest*
16587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16588 $as_echo "$gl_cv_pragma_columns" >&6; }
16589 if test $gl_cv_pragma_columns = yes; then
16590 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16591 else
16592 PRAGMA_COLUMNS=
16611 if test $gl_cv_have_include_next = yes; then
16612 gl_cv_next_getopt_h='<'getopt.h'>'
16613 else
16614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16615 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
16616 if test "${gl_cv_next_getopt_h+set}" = set; then :
16617 $as_echo_n "(cached) " >&6
16618 else
16620 if test $ac_cv_header_getopt_h = yes; then
16623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16624 /* end confdefs.h. */
16625 #include <getopt.h>
16627 _ACEOF
16628 case "$host_os" in
16629 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16630 *) gl_absname_cpp="$ac_cpp" ;;
16631 esac
16633 case "$host_os" in
16634 mingw*)
16635 gl_dirsep_regex='[/\\]'
16638 gl_dirsep_regex='\/'
16640 esac
16641 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16643 gl_header_literal_regex=`echo 'getopt.h' \
16644 | sed -e "$gl_make_literal_regex_sed"`
16645 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16646 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16647 s|^/[^/]|//&|
16651 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16652 sed -n "$gl_absolute_header_sed"`'"'
16653 else
16654 gl_cv_next_getopt_h='<'getopt.h'>'
16659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
16660 $as_echo "$gl_cv_next_getopt_h" >&6; }
16662 NEXT_GETOPT_H=$gl_cv_next_getopt_h
16664 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16665 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16666 gl_next_as_first_directive='<'getopt.h'>'
16667 else
16668 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16669 gl_next_as_first_directive=$gl_cv_next_getopt_h
16671 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
16676 if test $ac_cv_header_getopt_h = yes; then
16677 HAVE_GETOPT_H=1
16678 else
16679 HAVE_GETOPT_H=0
16683 gl_replace_getopt=
16685 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16686 for ac_header in getopt.h
16687 do :
16688 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
16689 if test "x$ac_cv_header_getopt_h" = x""yes; then :
16690 cat >>confdefs.h <<_ACEOF
16691 #define HAVE_GETOPT_H 1
16692 _ACEOF
16694 else
16695 gl_replace_getopt=yes
16698 done
16702 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16703 for ac_func in getopt_long_only
16704 do :
16705 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
16706 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
16707 cat >>confdefs.h <<_ACEOF
16708 #define HAVE_GETOPT_LONG_ONLY 1
16709 _ACEOF
16711 else
16712 gl_replace_getopt=yes
16714 done
16718 if test -z "$gl_replace_getopt"; then
16719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
16720 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
16721 if test "${gl_cv_func_getopt_posix+set}" = set; then :
16722 $as_echo_n "(cached) " >&6
16723 else
16725 if test $cross_compiling = no; then
16726 if test "$cross_compiling" = yes; then :
16727 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16728 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16729 as_fn_error "cannot run test program while cross compiling
16730 See \`config.log' for more details." "$LINENO" 5; }
16731 else
16732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16733 /* end confdefs.h. */
16735 #include <unistd.h>
16736 #include <stdlib.h>
16737 #include <string.h>
16740 main ()
16742 static char program[] = "program";
16743 static char a[] = "-a";
16744 static char foo[] = "foo";
16745 static char bar[] = "bar";
16746 char *argv[] = { program, a, foo, bar, NULL };
16747 int c;
16749 c = getopt (4, argv, "ab");
16750 if (!(c == 'a'))
16751 return 1;
16752 c = getopt (4, argv, "ab");
16753 if (!(c == -1))
16754 return 2;
16755 if (!(optind == 2))
16756 return 3;
16757 return 0;
16760 _ACEOF
16761 if ac_fn_c_try_run "$LINENO"; then :
16762 gl_cv_func_getopt_posix=maybe
16763 else
16764 gl_cv_func_getopt_posix=no
16766 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16767 conftest.$ac_objext conftest.beam conftest.$ac_ext
16770 if test $gl_cv_func_getopt_posix = maybe; then
16771 if test "$cross_compiling" = yes; then :
16772 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16773 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16774 as_fn_error "cannot run test program while cross compiling
16775 See \`config.log' for more details." "$LINENO" 5; }
16776 else
16777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16778 /* end confdefs.h. */
16780 #include <unistd.h>
16781 #include <stdlib.h>
16782 #include <string.h>
16785 main ()
16787 static char program[] = "program";
16788 static char donald[] = "donald";
16789 static char p[] = "-p";
16790 static char billy[] = "billy";
16791 static char duck[] = "duck";
16792 static char a[] = "-a";
16793 static char bar[] = "bar";
16794 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
16795 int c;
16797 c = getopt (7, argv, "+abp:q:");
16798 if (!(c == -1))
16799 return 4;
16800 if (!(strcmp (argv[0], "program") == 0))
16801 return 5;
16802 if (!(strcmp (argv[1], "donald") == 0))
16803 return 6;
16804 if (!(strcmp (argv[2], "-p") == 0))
16805 return 7;
16806 if (!(strcmp (argv[3], "billy") == 0))
16807 return 8;
16808 if (!(strcmp (argv[4], "duck") == 0))
16809 return 9;
16810 if (!(strcmp (argv[5], "-a") == 0))
16811 return 10;
16812 if (!(strcmp (argv[6], "bar") == 0))
16813 return 11;
16814 if (!(optind == 1))
16815 return 12;
16816 return 0;
16819 _ACEOF
16820 if ac_fn_c_try_run "$LINENO"; then :
16821 gl_cv_func_getopt_posix=maybe
16822 else
16823 gl_cv_func_getopt_posix=no
16825 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16826 conftest.$ac_objext conftest.beam conftest.$ac_ext
16830 if test $gl_cv_func_getopt_posix = maybe; then
16831 if test "$cross_compiling" = yes; then :
16832 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16833 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16834 as_fn_error "cannot run test program while cross compiling
16835 See \`config.log' for more details." "$LINENO" 5; }
16836 else
16837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16838 /* end confdefs.h. */
16840 #include <unistd.h>
16841 #include <stdlib.h>
16842 #include <string.h>
16845 main ()
16847 static char program[] = "program";
16848 static char ab[] = "-ab";
16849 char *argv[3] = { program, ab, NULL };
16850 if (getopt (2, argv, "ab:") != 'a')
16851 return 13;
16852 if (getopt (2, argv, "ab:") != '?')
16853 return 14;
16854 if (optopt != 'b')
16855 return 15;
16856 if (optind != 2)
16857 return 16;
16858 return 0;
16861 _ACEOF
16862 if ac_fn_c_try_run "$LINENO"; then :
16863 gl_cv_func_getopt_posix=yes
16864 else
16865 gl_cv_func_getopt_posix=no
16867 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16868 conftest.$ac_objext conftest.beam conftest.$ac_ext
16872 else
16873 case "$host_os" in
16874 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
16875 *) gl_cv_func_getopt_posix="guessing yes";;
16876 esac
16880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
16881 $as_echo "$gl_cv_func_getopt_posix" >&6; }
16882 case "$gl_cv_func_getopt_posix" in
16883 *no) gl_replace_getopt=yes ;;
16884 esac
16887 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
16889 $as_echo_n "checking for working GNU getopt function... " >&6; }
16890 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
16891 $as_echo_n "(cached) " >&6
16892 else
16893 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
16894 # optstring is necessary for programs like m4 that have POSIX-mandated
16895 # semantics for supporting options interspersed with files.
16896 # Also, since getopt_long is a GNU extension, we require optind=0.
16897 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
16898 # so take care to revert to the correct (non-)export state.
16899 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
16900 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
16901 xx) gl_had_POSIXLY_CORRECT=exported ;;
16902 x) gl_had_POSIXLY_CORRECT=yes ;;
16903 *) gl_had_POSIXLY_CORRECT= ;;
16904 esac
16905 POSIXLY_CORRECT=1
16906 export POSIXLY_CORRECT
16907 if test "$cross_compiling" = yes; then :
16908 gl_cv_func_getopt_gnu="guessing no"
16910 else
16911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16912 /* end confdefs.h. */
16913 #include <getopt.h>
16914 #include <stddef.h>
16915 #include <string.h>
16917 #include <stdlib.h>
16918 #if defined __MACH__ && defined __APPLE__
16919 /* Avoid a crash on Mac OS X. */
16920 #include <mach/mach.h>
16921 #include <mach/mach_error.h>
16922 #include <mach/thread_status.h>
16923 #include <mach/exception.h>
16924 #include <mach/task.h>
16925 #include <pthread.h>
16926 /* The exception port on which our thread listens. */
16927 static mach_port_t our_exception_port;
16928 /* The main function of the thread listening for exceptions of type
16929 EXC_BAD_ACCESS. */
16930 static void *
16931 mach_exception_thread (void *arg)
16933 /* Buffer for a message to be received. */
16934 struct {
16935 mach_msg_header_t head;
16936 mach_msg_body_t msgh_body;
16937 char data[1024];
16938 } msg;
16939 mach_msg_return_t retval;
16940 /* Wait for a message on the exception port. */
16941 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
16942 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
16943 if (retval != MACH_MSG_SUCCESS)
16944 abort ();
16945 exit (1);
16947 static void
16948 nocrash_init (void)
16950 mach_port_t self = mach_task_self ();
16951 /* Allocate a port on which the thread shall listen for exceptions. */
16952 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
16953 == KERN_SUCCESS) {
16954 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
16955 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
16956 MACH_MSG_TYPE_MAKE_SEND)
16957 == KERN_SUCCESS) {
16958 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
16959 for us. */
16960 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
16961 /* Create the thread listening on the exception port. */
16962 pthread_attr_t attr;
16963 pthread_t thread;
16964 if (pthread_attr_init (&attr) == 0
16965 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
16966 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
16967 pthread_attr_destroy (&attr);
16968 /* Replace the exception port info for these exceptions with our own.
16969 Note that we replace the exception port for the entire task, not only
16970 for a particular thread. This has the effect that when our exception
16971 port gets the message, the thread specific exception port has already
16972 been asked, and we don't need to bother about it.
16973 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
16974 task_set_exception_ports (self, mask, our_exception_port,
16975 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
16980 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
16981 /* Avoid a crash on native Windows. */
16982 #define WIN32_LEAN_AND_MEAN
16983 #include <windows.h>
16984 #include <winerror.h>
16985 static LONG WINAPI
16986 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
16988 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
16990 case EXCEPTION_ACCESS_VIOLATION:
16991 case EXCEPTION_IN_PAGE_ERROR:
16992 case EXCEPTION_STACK_OVERFLOW:
16993 case EXCEPTION_GUARD_PAGE:
16994 case EXCEPTION_PRIV_INSTRUCTION:
16995 case EXCEPTION_ILLEGAL_INSTRUCTION:
16996 case EXCEPTION_DATATYPE_MISALIGNMENT:
16997 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
16998 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
16999 exit (1);
17001 return EXCEPTION_CONTINUE_SEARCH;
17003 static void
17004 nocrash_init (void)
17006 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17008 #else
17009 /* Avoid a crash on POSIX systems. */
17010 #include <signal.h>
17011 /* A POSIX signal handler. */
17012 static void
17013 exception_handler (int sig)
17015 exit (1);
17017 static void
17018 nocrash_init (void)
17020 #ifdef SIGSEGV
17021 signal (SIGSEGV, exception_handler);
17022 #endif
17023 #ifdef SIGBUS
17024 signal (SIGBUS, exception_handler);
17025 #endif
17027 #endif
17031 main ()
17034 int result = 0;
17036 nocrash_init();
17038 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17039 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17040 OSF/1 5.1, Solaris 10. */
17042 static char conftest[] = "conftest";
17043 static char plus[] = "-+";
17044 char *argv[3] = { conftest, plus, NULL };
17045 opterr = 0;
17046 if (getopt (2, argv, "+a") != '?')
17047 result |= 1;
17049 /* This code succeeds on glibc 2.8, mingw,
17050 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17051 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17053 static char program[] = "program";
17054 static char p[] = "-p";
17055 static char foo[] = "foo";
17056 static char bar[] = "bar";
17057 char *argv[] = { program, p, foo, bar, NULL };
17059 optind = 1;
17060 if (getopt (4, argv, "p::") != 'p')
17061 result |= 2;
17062 else if (optarg != NULL)
17063 result |= 4;
17064 else if (getopt (4, argv, "p::") != -1)
17065 result |= 6;
17066 else if (optind != 2)
17067 result |= 8;
17069 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17071 static char program[] = "program";
17072 static char foo[] = "foo";
17073 static char p[] = "-p";
17074 char *argv[] = { program, foo, p, NULL };
17075 optind = 0;
17076 if (getopt (3, argv, "-p") != 1)
17077 result |= 16;
17078 else if (getopt (3, argv, "-p") != 'p')
17079 result |= 16;
17081 /* This code fails on glibc 2.11. */
17083 static char program[] = "program";
17084 static char b[] = "-b";
17085 static char a[] = "-a";
17086 char *argv[] = { program, b, a, NULL };
17087 optind = opterr = 0;
17088 if (getopt (3, argv, "+:a:b") != 'b')
17089 result |= 32;
17090 else if (getopt (3, argv, "+:a:b") != ':')
17091 result |= 32;
17093 /* This code dumps core on glibc 2.14. */
17095 static char program[] = "program";
17096 static char w[] = "-W";
17097 static char dummy[] = "dummy";
17098 char *argv[] = { program, w, dummy, NULL };
17099 optind = opterr = 1;
17100 if (getopt (3, argv, "W;") != 'W')
17101 result |= 64;
17103 return result;
17106 return 0;
17108 _ACEOF
17109 if ac_fn_c_try_run "$LINENO"; then :
17110 gl_cv_func_getopt_gnu=yes
17111 else
17112 gl_cv_func_getopt_gnu=no
17114 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17115 conftest.$ac_objext conftest.beam conftest.$ac_ext
17118 case $gl_had_POSIXLY_CORRECT in
17119 exported) ;;
17120 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17121 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17122 esac
17125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17126 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17127 if test "$gl_cv_func_getopt_gnu" != yes; then
17128 gl_replace_getopt=yes
17129 else
17130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17131 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17132 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17133 $as_echo_n "(cached) " >&6
17134 else
17135 if test "$cross_compiling" = yes; then :
17136 case "$host_os" in
17137 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17138 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17139 esac
17141 else
17142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17143 /* end confdefs.h. */
17144 #include <getopt.h>
17145 #include <stddef.h>
17146 #include <string.h>
17149 main ()
17151 static const struct option long_options[] =
17153 { "xtremely-",no_argument, NULL, 1003 },
17154 { "xtra", no_argument, NULL, 1001 },
17155 { "xtreme", no_argument, NULL, 1002 },
17156 { "xtremely", no_argument, NULL, 1003 },
17157 { NULL, 0, NULL, 0 }
17159 /* This code fails on OpenBSD 5.0. */
17161 static char program[] = "program";
17162 static char xtremel[] = "--xtremel";
17163 char *argv[] = { program, xtremel, NULL };
17164 int option_index;
17165 optind = 1; opterr = 0;
17166 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17167 return 1;
17169 return 0;
17172 return 0;
17174 _ACEOF
17175 if ac_fn_c_try_run "$LINENO"; then :
17176 gl_cv_func_getopt_long_gnu=yes
17177 else
17178 gl_cv_func_getopt_long_gnu=no
17180 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17181 conftest.$ac_objext conftest.beam conftest.$ac_ext
17186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17187 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17188 case "$gl_cv_func_getopt_long_gnu" in
17189 *yes) ;;
17190 *) gl_replace_getopt=yes ;;
17191 esac
17200 REPLACE_GETOPT=0
17201 if test -n "$gl_replace_getopt"; then
17202 REPLACE_GETOPT=1
17205 if test $REPLACE_GETOPT = 1; then
17207 GETOPT_H=getopt.h
17209 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17215 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17216 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17217 ac_have_decl=1
17218 else
17219 ac_have_decl=0
17222 cat >>confdefs.h <<_ACEOF
17223 #define HAVE_DECL_GETENV $ac_have_decl
17224 _ACEOF
17233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17234 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17235 if test "${ac_cv_c_restrict+set}" = set; then :
17236 $as_echo_n "(cached) " >&6
17237 else
17238 ac_cv_c_restrict=no
17239 # The order here caters to the fact that C++ does not require restrict.
17240 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17242 /* end confdefs.h. */
17243 typedef int * int_ptr;
17244 int foo (int_ptr $ac_kw ip) {
17245 return ip[0];
17248 main ()
17250 int s[1];
17251 int * $ac_kw t = s;
17252 t[0] = 0;
17253 return foo(t)
17255 return 0;
17257 _ACEOF
17258 if ac_fn_c_try_compile "$LINENO"; then :
17259 ac_cv_c_restrict=$ac_kw
17261 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17262 test "$ac_cv_c_restrict" != no && break
17263 done
17266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17267 $as_echo "$ac_cv_c_restrict" >&6; }
17269 case $ac_cv_c_restrict in
17270 restrict) ;;
17271 no) $as_echo "#define restrict /**/" >>confdefs.h
17273 *) cat >>confdefs.h <<_ACEOF
17274 #define restrict $ac_cv_c_restrict
17275 _ACEOF
17277 esac
17280 GNULIB_GETTIMEOFDAY=0;
17281 HAVE_GETTIMEOFDAY=1;
17282 HAVE_STRUCT_TIMEVAL=1;
17283 HAVE_SYS_TIME_H=1;
17284 REPLACE_GETTIMEOFDAY=0;
17285 REPLACE_STRUCT_TIMEVAL=0;
17302 if test $gl_cv_have_include_next = yes; then
17303 gl_cv_next_sys_time_h='<'sys/time.h'>'
17304 else
17305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17306 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17307 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17308 $as_echo_n "(cached) " >&6
17309 else
17311 if test $ac_cv_header_sys_time_h = yes; then
17314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17315 /* end confdefs.h. */
17316 #include <sys/time.h>
17318 _ACEOF
17319 case "$host_os" in
17320 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17321 *) gl_absname_cpp="$ac_cpp" ;;
17322 esac
17324 case "$host_os" in
17325 mingw*)
17326 gl_dirsep_regex='[/\\]'
17329 gl_dirsep_regex='\/'
17331 esac
17332 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17334 gl_header_literal_regex=`echo 'sys/time.h' \
17335 | sed -e "$gl_make_literal_regex_sed"`
17336 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17337 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17338 s|^/[^/]|//&|
17342 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17343 sed -n "$gl_absolute_header_sed"`'"'
17344 else
17345 gl_cv_next_sys_time_h='<'sys/time.h'>'
17350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17351 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17353 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17355 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17356 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17357 gl_next_as_first_directive='<'sys/time.h'>'
17358 else
17359 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17360 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17362 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17368 if test $ac_cv_header_sys_time_h != yes; then
17369 HAVE_SYS_TIME_H=0
17376 if test $ac_cv_header_sys_socket_h != yes; then
17377 for ac_header in winsock2.h
17378 do :
17379 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17380 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17381 cat >>confdefs.h <<_ACEOF
17382 #define HAVE_WINSOCK2_H 1
17383 _ACEOF
17387 done
17390 if test "$ac_cv_header_winsock2_h" = yes; then
17391 HAVE_WINSOCK2_H=1
17392 UNISTD_H_HAVE_WINSOCK2_H=1
17393 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17394 else
17395 HAVE_WINSOCK2_H=0
17399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17400 $as_echo_n "checking for struct timeval... " >&6; }
17401 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17402 $as_echo_n "(cached) " >&6
17403 else
17404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17405 /* end confdefs.h. */
17406 #if HAVE_SYS_TIME_H
17407 #include <sys/time.h>
17408 #endif
17409 #include <time.h>
17410 #if HAVE_WINSOCK2_H
17411 # include <winsock2.h>
17412 #endif
17415 main ()
17417 static struct timeval x; x.tv_sec = x.tv_usec;
17419 return 0;
17421 _ACEOF
17422 if ac_fn_c_try_compile "$LINENO"; then :
17423 gl_cv_sys_struct_timeval=yes
17424 else
17425 gl_cv_sys_struct_timeval=no
17427 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
17431 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
17432 if test $gl_cv_sys_struct_timeval != yes; then
17433 HAVE_STRUCT_TIMEVAL=0
17434 else
17435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
17436 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
17437 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
17438 $as_echo_n "(cached) " >&6
17439 else
17440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17441 /* end confdefs.h. */
17442 #if HAVE_SYS_TIME_H
17443 #include <sys/time.h>
17444 #endif
17445 #include <time.h>
17446 #if HAVE_WINSOCK2_H
17447 # include <winsock2.h>
17448 #endif
17451 main ()
17453 static struct timeval x;
17454 typedef int verify_tv_sec_type[
17455 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
17459 return 0;
17461 _ACEOF
17462 if ac_fn_c_try_compile "$LINENO"; then :
17463 gl_cv_sys_struct_timeval_tv_sec=yes
17464 else
17465 gl_cv_sys_struct_timeval_tv_sec=no
17467 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
17471 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
17472 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
17473 REPLACE_STRUCT_TIMEVAL=1
17483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17484 $as_echo_n "checking for unsigned long long int... " >&6; }
17485 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17486 $as_echo_n "(cached) " >&6
17487 else
17488 ac_cv_type_unsigned_long_long_int=yes
17489 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17491 /* end confdefs.h. */
17493 /* For now, do not test the preprocessor; as of 2007 there are too many
17494 implementations with broken preprocessors. Perhaps this can
17495 be revisited in 2012. In the meantime, code should not expect
17496 #if to work with literals wider than 32 bits. */
17497 /* Test literals. */
17498 long long int ll = 9223372036854775807ll;
17499 long long int nll = -9223372036854775807LL;
17500 unsigned long long int ull = 18446744073709551615ULL;
17501 /* Test constant expressions. */
17502 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17503 ? 1 : -1)];
17504 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17505 ? 1 : -1)];
17506 int i = 63;
17508 main ()
17510 /* Test availability of runtime routines for shift and division. */
17511 long long int llmax = 9223372036854775807ll;
17512 unsigned long long int ullmax = 18446744073709551615ull;
17513 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17514 | (llmax / ll) | (llmax % ll)
17515 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17516 | (ullmax / ull) | (ullmax % ull));
17518 return 0;
17521 _ACEOF
17522 if ac_fn_c_try_link "$LINENO"; then :
17524 else
17525 ac_cv_type_unsigned_long_long_int=no
17527 rm -f core conftest.err conftest.$ac_objext \
17528 conftest$ac_exeext conftest.$ac_ext
17531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17532 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17533 if test $ac_cv_type_unsigned_long_long_int = yes; then
17535 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17542 $as_echo_n "checking for long long int... " >&6; }
17543 if test "${ac_cv_type_long_long_int+set}" = set; then :
17544 $as_echo_n "(cached) " >&6
17545 else
17546 ac_cv_type_long_long_int=yes
17547 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17548 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17549 if test $ac_cv_type_long_long_int = yes; then
17550 if test "$cross_compiling" = yes; then :
17552 else
17553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17554 /* end confdefs.h. */
17555 #include <limits.h>
17556 #ifndef LLONG_MAX
17557 # define HALF \
17558 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17559 # define LLONG_MAX (HALF - 1 + HALF)
17560 #endif
17562 main ()
17564 long long int n = 1;
17565 int i;
17566 for (i = 0; ; i++)
17568 long long int m = n << i;
17569 if (m >> i != n)
17570 return 1;
17571 if (LLONG_MAX / 2 < m)
17572 break;
17574 return 0;
17576 return 0;
17578 _ACEOF
17579 if ac_fn_c_try_run "$LINENO"; then :
17581 else
17582 ac_cv_type_long_long_int=no
17584 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17585 conftest.$ac_objext conftest.beam conftest.$ac_ext
17591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17592 $as_echo "$ac_cv_type_long_long_int" >&6; }
17593 if test $ac_cv_type_long_long_int = yes; then
17595 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
17604 gl_cv_c_multiarch=no
17605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17606 /* end confdefs.h. */
17607 #ifndef __APPLE_CC__
17608 not a universal capable compiler
17609 #endif
17610 typedef int dummy;
17612 _ACEOF
17613 if ac_fn_c_try_compile "$LINENO"; then :
17615 arch=
17616 prev=
17617 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17618 if test -n "$prev"; then
17619 case $word in
17620 i?86 | x86_64 | ppc | ppc64)
17621 if test -z "$arch" || test "$arch" = "$word"; then
17622 arch="$word"
17623 else
17624 gl_cv_c_multiarch=yes
17627 esac
17628 prev=
17629 else
17630 if test "x$word" = "x-arch"; then
17631 prev=arch
17634 done
17637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17638 if test $gl_cv_c_multiarch = yes; then
17639 APPLE_UNIVERSAL_BUILD=1
17640 else
17641 APPLE_UNIVERSAL_BUILD=0
17648 if test $ac_cv_type_long_long_int = yes; then
17649 HAVE_LONG_LONG_INT=1
17650 else
17651 HAVE_LONG_LONG_INT=0
17655 if test $ac_cv_type_unsigned_long_long_int = yes; then
17656 HAVE_UNSIGNED_LONG_LONG_INT=1
17657 else
17658 HAVE_UNSIGNED_LONG_LONG_INT=0
17663 if test $ac_cv_header_wchar_h = yes; then
17664 HAVE_WCHAR_H=1
17665 else
17666 HAVE_WCHAR_H=0
17670 if test $ac_cv_header_inttypes_h = yes; then
17671 HAVE_INTTYPES_H=1
17672 else
17673 HAVE_INTTYPES_H=0
17677 if test $ac_cv_header_sys_types_h = yes; then
17678 HAVE_SYS_TYPES_H=1
17679 else
17680 HAVE_SYS_TYPES_H=0
17693 if test $gl_cv_have_include_next = yes; then
17694 gl_cv_next_stdint_h='<'stdint.h'>'
17695 else
17696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17697 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
17698 if test "${gl_cv_next_stdint_h+set}" = set; then :
17699 $as_echo_n "(cached) " >&6
17700 else
17702 if test $ac_cv_header_stdint_h = yes; then
17705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17706 /* end confdefs.h. */
17707 #include <stdint.h>
17709 _ACEOF
17710 case "$host_os" in
17711 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17712 *) gl_absname_cpp="$ac_cpp" ;;
17713 esac
17715 case "$host_os" in
17716 mingw*)
17717 gl_dirsep_regex='[/\\]'
17720 gl_dirsep_regex='\/'
17722 esac
17723 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17725 gl_header_literal_regex=`echo 'stdint.h' \
17726 | sed -e "$gl_make_literal_regex_sed"`
17727 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17728 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17729 s|^/[^/]|//&|
17733 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17734 sed -n "$gl_absolute_header_sed"`'"'
17735 else
17736 gl_cv_next_stdint_h='<'stdint.h'>'
17741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
17742 $as_echo "$gl_cv_next_stdint_h" >&6; }
17744 NEXT_STDINT_H=$gl_cv_next_stdint_h
17746 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17747 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17748 gl_next_as_first_directive='<'stdint.h'>'
17749 else
17750 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17751 gl_next_as_first_directive=$gl_cv_next_stdint_h
17753 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
17758 if test $ac_cv_header_stdint_h = yes; then
17759 HAVE_STDINT_H=1
17760 else
17761 HAVE_STDINT_H=0
17765 if test $ac_cv_header_stdint_h = yes; then
17766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
17767 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
17768 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
17769 $as_echo_n "(cached) " >&6
17770 else
17771 gl_cv_header_working_stdint_h=no
17772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17773 /* end confdefs.h. */
17776 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17777 #include <stdint.h>
17778 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
17779 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
17780 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
17781 #endif
17784 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17785 included before <wchar.h>. */
17786 #include <stddef.h>
17787 #include <signal.h>
17788 #if HAVE_WCHAR_H
17789 # include <stdio.h>
17790 # include <time.h>
17791 # include <wchar.h>
17792 #endif
17795 #ifdef INT8_MAX
17796 int8_t a1 = INT8_MAX;
17797 int8_t a1min = INT8_MIN;
17798 #endif
17799 #ifdef INT16_MAX
17800 int16_t a2 = INT16_MAX;
17801 int16_t a2min = INT16_MIN;
17802 #endif
17803 #ifdef INT32_MAX
17804 int32_t a3 = INT32_MAX;
17805 int32_t a3min = INT32_MIN;
17806 #endif
17807 #ifdef INT64_MAX
17808 int64_t a4 = INT64_MAX;
17809 int64_t a4min = INT64_MIN;
17810 #endif
17811 #ifdef UINT8_MAX
17812 uint8_t b1 = UINT8_MAX;
17813 #else
17814 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
17815 #endif
17816 #ifdef UINT16_MAX
17817 uint16_t b2 = UINT16_MAX;
17818 #endif
17819 #ifdef UINT32_MAX
17820 uint32_t b3 = UINT32_MAX;
17821 #endif
17822 #ifdef UINT64_MAX
17823 uint64_t b4 = UINT64_MAX;
17824 #endif
17825 int_least8_t c1 = INT8_C (0x7f);
17826 int_least8_t c1max = INT_LEAST8_MAX;
17827 int_least8_t c1min = INT_LEAST8_MIN;
17828 int_least16_t c2 = INT16_C (0x7fff);
17829 int_least16_t c2max = INT_LEAST16_MAX;
17830 int_least16_t c2min = INT_LEAST16_MIN;
17831 int_least32_t c3 = INT32_C (0x7fffffff);
17832 int_least32_t c3max = INT_LEAST32_MAX;
17833 int_least32_t c3min = INT_LEAST32_MIN;
17834 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
17835 int_least64_t c4max = INT_LEAST64_MAX;
17836 int_least64_t c4min = INT_LEAST64_MIN;
17837 uint_least8_t d1 = UINT8_C (0xff);
17838 uint_least8_t d1max = UINT_LEAST8_MAX;
17839 uint_least16_t d2 = UINT16_C (0xffff);
17840 uint_least16_t d2max = UINT_LEAST16_MAX;
17841 uint_least32_t d3 = UINT32_C (0xffffffff);
17842 uint_least32_t d3max = UINT_LEAST32_MAX;
17843 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
17844 uint_least64_t d4max = UINT_LEAST64_MAX;
17845 int_fast8_t e1 = INT_FAST8_MAX;
17846 int_fast8_t e1min = INT_FAST8_MIN;
17847 int_fast16_t e2 = INT_FAST16_MAX;
17848 int_fast16_t e2min = INT_FAST16_MIN;
17849 int_fast32_t e3 = INT_FAST32_MAX;
17850 int_fast32_t e3min = INT_FAST32_MIN;
17851 int_fast64_t e4 = INT_FAST64_MAX;
17852 int_fast64_t e4min = INT_FAST64_MIN;
17853 uint_fast8_t f1 = UINT_FAST8_MAX;
17854 uint_fast16_t f2 = UINT_FAST16_MAX;
17855 uint_fast32_t f3 = UINT_FAST32_MAX;
17856 uint_fast64_t f4 = UINT_FAST64_MAX;
17857 #ifdef INTPTR_MAX
17858 intptr_t g = INTPTR_MAX;
17859 intptr_t gmin = INTPTR_MIN;
17860 #endif
17861 #ifdef UINTPTR_MAX
17862 uintptr_t h = UINTPTR_MAX;
17863 #endif
17864 intmax_t i = INTMAX_MAX;
17865 uintmax_t j = UINTMAX_MAX;
17867 #include <limits.h> /* for CHAR_BIT */
17868 #define TYPE_MINIMUM(t) \
17869 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
17870 #define TYPE_MAXIMUM(t) \
17871 ((t) ((t) 0 < (t) -1 \
17872 ? (t) -1 \
17873 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
17874 struct s {
17875 int check_PTRDIFF:
17876 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
17877 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
17878 ? 1 : -1;
17879 /* Detect bug in FreeBSD 6.0 / ia64. */
17880 int check_SIG_ATOMIC:
17881 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
17882 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
17883 ? 1 : -1;
17884 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
17885 int check_WCHAR:
17886 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
17887 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
17888 ? 1 : -1;
17889 /* Detect bug in mingw. */
17890 int check_WINT:
17891 WINT_MIN == TYPE_MINIMUM (wint_t)
17892 && WINT_MAX == TYPE_MAXIMUM (wint_t)
17893 ? 1 : -1;
17895 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
17896 int check_UINT8_C:
17897 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
17898 int check_UINT16_C:
17899 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
17901 /* Detect bugs in OpenBSD 3.9 stdint.h. */
17902 #ifdef UINT8_MAX
17903 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
17904 #endif
17905 #ifdef UINT16_MAX
17906 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
17907 #endif
17908 #ifdef UINT32_MAX
17909 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
17910 #endif
17911 #ifdef UINT64_MAX
17912 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
17913 #endif
17914 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
17915 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
17916 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
17917 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
17918 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
17919 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
17920 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
17921 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
17922 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
17923 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
17924 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
17928 main ()
17932 return 0;
17934 _ACEOF
17935 if ac_fn_c_try_compile "$LINENO"; then :
17936 if test "$cross_compiling" = yes; then :
17937 gl_cv_header_working_stdint_h=yes
17939 else
17940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17941 /* end confdefs.h. */
17944 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17945 #include <stdint.h>
17948 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17949 included before <wchar.h>. */
17950 #include <stddef.h>
17951 #include <signal.h>
17952 #if HAVE_WCHAR_H
17953 # include <stdio.h>
17954 # include <time.h>
17955 # include <wchar.h>
17956 #endif
17959 #include <stdio.h>
17960 #include <string.h>
17961 #define MVAL(macro) MVAL1(macro)
17962 #define MVAL1(expression) #expression
17963 static const char *macro_values[] =
17965 #ifdef INT8_MAX
17966 MVAL (INT8_MAX),
17967 #endif
17968 #ifdef INT16_MAX
17969 MVAL (INT16_MAX),
17970 #endif
17971 #ifdef INT32_MAX
17972 MVAL (INT32_MAX),
17973 #endif
17974 #ifdef INT64_MAX
17975 MVAL (INT64_MAX),
17976 #endif
17977 #ifdef UINT8_MAX
17978 MVAL (UINT8_MAX),
17979 #endif
17980 #ifdef UINT16_MAX
17981 MVAL (UINT16_MAX),
17982 #endif
17983 #ifdef UINT32_MAX
17984 MVAL (UINT32_MAX),
17985 #endif
17986 #ifdef UINT64_MAX
17987 MVAL (UINT64_MAX),
17988 #endif
17989 NULL
17993 main ()
17996 const char **mv;
17997 for (mv = macro_values; *mv != NULL; mv++)
17999 const char *value = *mv;
18000 /* Test whether it looks like a cast expression. */
18001 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18002 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18003 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18004 || strncmp (value, "((int)"/*)*/, 6) == 0
18005 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18006 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18007 return mv - macro_values + 1;
18009 return 0;
18012 return 0;
18014 _ACEOF
18015 if ac_fn_c_try_run "$LINENO"; then :
18016 gl_cv_header_working_stdint_h=yes
18018 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18019 conftest.$ac_objext conftest.beam conftest.$ac_ext
18024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18028 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18030 if test "$gl_cv_header_working_stdint_h" = yes; then
18031 STDINT_H=
18032 else
18033 for ac_header in sys/inttypes.h sys/bitypes.h
18034 do :
18035 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18036 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18037 eval as_val=\$$as_ac_Header
18038 if test "x$as_val" = x""yes; then :
18039 cat >>confdefs.h <<_ACEOF
18040 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18041 _ACEOF
18045 done
18047 if test $ac_cv_header_sys_inttypes_h = yes; then
18048 HAVE_SYS_INTTYPES_H=1
18049 else
18050 HAVE_SYS_INTTYPES_H=0
18053 if test $ac_cv_header_sys_bitypes_h = yes; then
18054 HAVE_SYS_BITYPES_H=1
18055 else
18056 HAVE_SYS_BITYPES_H=0
18062 if test $APPLE_UNIVERSAL_BUILD = 0; then
18065 for gltype in ptrdiff_t size_t ; do
18066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18067 $as_echo_n "checking for bit size of $gltype... " >&6; }
18068 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18069 $as_echo_n "(cached) " >&6
18070 else
18071 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18072 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18073 included before <wchar.h>. */
18074 #include <stddef.h>
18075 #include <signal.h>
18076 #if HAVE_WCHAR_H
18077 # include <stdio.h>
18078 # include <time.h>
18079 # include <wchar.h>
18080 #endif
18082 #include <limits.h>"; then :
18084 else
18085 result=unknown
18088 eval gl_cv_bitsizeof_${gltype}=\$result
18091 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18093 $as_echo "$ac_res" >&6; }
18094 eval result=\$gl_cv_bitsizeof_${gltype}
18095 if test $result = unknown; then
18096 result=0
18098 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18099 cat >>confdefs.h <<_ACEOF
18100 #define BITSIZEOF_${GLTYPE} $result
18101 _ACEOF
18103 eval BITSIZEOF_${GLTYPE}=\$result
18104 done
18110 for gltype in sig_atomic_t wchar_t wint_t ; do
18111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18112 $as_echo_n "checking for bit size of $gltype... " >&6; }
18113 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18114 $as_echo_n "(cached) " >&6
18115 else
18116 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18117 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18118 included before <wchar.h>. */
18119 #include <stddef.h>
18120 #include <signal.h>
18121 #if HAVE_WCHAR_H
18122 # include <stdio.h>
18123 # include <time.h>
18124 # include <wchar.h>
18125 #endif
18127 #include <limits.h>"; then :
18129 else
18130 result=unknown
18133 eval gl_cv_bitsizeof_${gltype}=\$result
18136 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18138 $as_echo "$ac_res" >&6; }
18139 eval result=\$gl_cv_bitsizeof_${gltype}
18140 if test $result = unknown; then
18141 result=0
18143 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18144 cat >>confdefs.h <<_ACEOF
18145 #define BITSIZEOF_${GLTYPE} $result
18146 _ACEOF
18148 eval BITSIZEOF_${GLTYPE}=\$result
18149 done
18154 for gltype in sig_atomic_t wchar_t wint_t ; do
18155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18156 $as_echo_n "checking whether $gltype is signed... " >&6; }
18157 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18158 $as_echo_n "(cached) " >&6
18159 else
18160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18161 /* end confdefs.h. */
18163 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18164 included before <wchar.h>. */
18165 #include <stddef.h>
18166 #include <signal.h>
18167 #if HAVE_WCHAR_H
18168 # include <stdio.h>
18169 # include <time.h>
18170 # include <wchar.h>
18171 #endif
18173 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18175 main ()
18179 return 0;
18181 _ACEOF
18182 if ac_fn_c_try_compile "$LINENO"; then :
18183 result=yes
18184 else
18185 result=no
18187 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18188 eval gl_cv_type_${gltype}_signed=\$result
18191 eval ac_res=\$gl_cv_type_${gltype}_signed
18192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18193 $as_echo "$ac_res" >&6; }
18194 eval result=\$gl_cv_type_${gltype}_signed
18195 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18196 if test "$result" = yes; then
18197 cat >>confdefs.h <<_ACEOF
18198 #define HAVE_SIGNED_${GLTYPE} 1
18199 _ACEOF
18201 eval HAVE_SIGNED_${GLTYPE}=1
18202 else
18203 eval HAVE_SIGNED_${GLTYPE}=0
18205 done
18208 gl_cv_type_ptrdiff_t_signed=yes
18209 gl_cv_type_size_t_signed=no
18210 if test $APPLE_UNIVERSAL_BUILD = 0; then
18213 for gltype in ptrdiff_t size_t ; do
18214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18215 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18216 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18217 $as_echo_n "(cached) " >&6
18218 else
18219 eval gl_cv_type_${gltype}_suffix=no
18220 eval result=\$gl_cv_type_${gltype}_signed
18221 if test "$result" = yes; then
18222 glsufu=
18223 else
18224 glsufu=u
18226 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18227 case $glsuf in
18228 '') gltype1='int';;
18229 l) gltype1='long int';;
18230 ll) gltype1='long long int';;
18231 i64) gltype1='__int64';;
18232 u) gltype1='unsigned int';;
18233 ul) gltype1='unsigned long int';;
18234 ull) gltype1='unsigned long long int';;
18235 ui64)gltype1='unsigned __int64';;
18236 esac
18237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18238 /* end confdefs.h. */
18240 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18241 included before <wchar.h>. */
18242 #include <stddef.h>
18243 #include <signal.h>
18244 #if HAVE_WCHAR_H
18245 # include <stdio.h>
18246 # include <time.h>
18247 # include <wchar.h>
18248 #endif
18250 extern $gltype foo;
18251 extern $gltype1 foo;
18253 main ()
18257 return 0;
18259 _ACEOF
18260 if ac_fn_c_try_compile "$LINENO"; then :
18261 eval gl_cv_type_${gltype}_suffix=\$glsuf
18263 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18264 eval result=\$gl_cv_type_${gltype}_suffix
18265 test "$result" != no && break
18266 done
18268 eval ac_res=\$gl_cv_type_${gltype}_suffix
18269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18270 $as_echo "$ac_res" >&6; }
18271 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18272 eval result=\$gl_cv_type_${gltype}_suffix
18273 test "$result" = no && result=
18274 eval ${GLTYPE}_SUFFIX=\$result
18275 cat >>confdefs.h <<_ACEOF
18276 #define ${GLTYPE}_SUFFIX $result
18277 _ACEOF
18279 done
18285 for gltype in sig_atomic_t wchar_t wint_t ; do
18286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18287 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18288 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18289 $as_echo_n "(cached) " >&6
18290 else
18291 eval gl_cv_type_${gltype}_suffix=no
18292 eval result=\$gl_cv_type_${gltype}_signed
18293 if test "$result" = yes; then
18294 glsufu=
18295 else
18296 glsufu=u
18298 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18299 case $glsuf in
18300 '') gltype1='int';;
18301 l) gltype1='long int';;
18302 ll) gltype1='long long int';;
18303 i64) gltype1='__int64';;
18304 u) gltype1='unsigned int';;
18305 ul) gltype1='unsigned long int';;
18306 ull) gltype1='unsigned long long int';;
18307 ui64)gltype1='unsigned __int64';;
18308 esac
18309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18310 /* end confdefs.h. */
18312 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18313 included before <wchar.h>. */
18314 #include <stddef.h>
18315 #include <signal.h>
18316 #if HAVE_WCHAR_H
18317 # include <stdio.h>
18318 # include <time.h>
18319 # include <wchar.h>
18320 #endif
18322 extern $gltype foo;
18323 extern $gltype1 foo;
18325 main ()
18329 return 0;
18331 _ACEOF
18332 if ac_fn_c_try_compile "$LINENO"; then :
18333 eval gl_cv_type_${gltype}_suffix=\$glsuf
18335 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18336 eval result=\$gl_cv_type_${gltype}_suffix
18337 test "$result" != no && break
18338 done
18340 eval ac_res=\$gl_cv_type_${gltype}_suffix
18341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18342 $as_echo "$ac_res" >&6; }
18343 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18344 eval result=\$gl_cv_type_${gltype}_suffix
18345 test "$result" = no && result=
18346 eval ${GLTYPE}_SUFFIX=\$result
18347 cat >>confdefs.h <<_ACEOF
18348 #define ${GLTYPE}_SUFFIX $result
18349 _ACEOF
18351 done
18355 if test $BITSIZEOF_WINT_T -lt 32; then
18356 BITSIZEOF_WINT_T=32
18359 STDINT_H=stdint.h
18362 if test -n "$STDINT_H"; then
18363 GL_GENERATE_STDINT_H_TRUE=
18364 GL_GENERATE_STDINT_H_FALSE='#'
18365 else
18366 GL_GENERATE_STDINT_H_TRUE='#'
18367 GL_GENERATE_STDINT_H_FALSE=
18374 GNULIB_IMAXABS=0;
18375 GNULIB_IMAXDIV=0;
18376 GNULIB_STRTOIMAX=0;
18377 GNULIB_STRTOUMAX=0;
18378 HAVE_DECL_IMAXABS=1;
18379 HAVE_DECL_IMAXDIV=1;
18380 HAVE_DECL_STRTOIMAX=1;
18381 HAVE_DECL_STRTOUMAX=1;
18382 REPLACE_STRTOIMAX=0;
18383 INT32_MAX_LT_INTMAX_MAX=1;
18384 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18385 PRI_MACROS_BROKEN=0;
18386 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18387 UINT32_MAX_LT_UINTMAX_MAX=1;
18388 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18404 if test $gl_cv_have_include_next = yes; then
18405 gl_cv_next_inttypes_h='<'inttypes.h'>'
18406 else
18407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18408 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18409 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18410 $as_echo_n "(cached) " >&6
18411 else
18413 if test $ac_cv_header_inttypes_h = yes; then
18416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18417 /* end confdefs.h. */
18418 #include <inttypes.h>
18420 _ACEOF
18421 case "$host_os" in
18422 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18423 *) gl_absname_cpp="$ac_cpp" ;;
18424 esac
18426 case "$host_os" in
18427 mingw*)
18428 gl_dirsep_regex='[/\\]'
18431 gl_dirsep_regex='\/'
18433 esac
18434 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18436 gl_header_literal_regex=`echo 'inttypes.h' \
18437 | sed -e "$gl_make_literal_regex_sed"`
18438 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18439 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18440 s|^/[^/]|//&|
18444 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18445 sed -n "$gl_absolute_header_sed"`'"'
18446 else
18447 gl_cv_next_inttypes_h='<'inttypes.h'>'
18452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18453 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18455 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18457 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18458 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18459 gl_next_as_first_directive='<'inttypes.h'>'
18460 else
18461 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18462 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18464 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18476 case "$host_os" in
18477 mingw*)
18478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
18479 $as_echo_n "checking for 64-bit off_t... " >&6; }
18480 if test "${gl_cv_type_off_t_64+set}" = set; then :
18481 $as_echo_n "(cached) " >&6
18482 else
18483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18484 /* end confdefs.h. */
18485 #include <sys/types.h>
18486 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
18489 main ()
18493 return 0;
18495 _ACEOF
18496 if ac_fn_c_try_compile "$LINENO"; then :
18497 gl_cv_type_off_t_64=yes
18498 else
18499 gl_cv_type_off_t_64=no
18501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
18505 $as_echo "$gl_cv_type_off_t_64" >&6; }
18506 if test $gl_cv_type_off_t_64 = no; then
18507 WINDOWS_64_BIT_OFF_T=1
18508 else
18509 WINDOWS_64_BIT_OFF_T=0
18511 WINDOWS_64_BIT_ST_SIZE=1
18514 WINDOWS_64_BIT_OFF_T=0
18515 WINDOWS_64_BIT_ST_SIZE=0
18517 esac
18520 GNULIB_FCHMODAT=0;
18521 GNULIB_FSTAT=0;
18522 GNULIB_FSTATAT=0;
18523 GNULIB_FUTIMENS=0;
18524 GNULIB_LCHMOD=0;
18525 GNULIB_LSTAT=0;
18526 GNULIB_MKDIRAT=0;
18527 GNULIB_MKFIFO=0;
18528 GNULIB_MKFIFOAT=0;
18529 GNULIB_MKNOD=0;
18530 GNULIB_MKNODAT=0;
18531 GNULIB_STAT=0;
18532 GNULIB_UTIMENSAT=0;
18533 HAVE_FCHMODAT=1;
18534 HAVE_FSTATAT=1;
18535 HAVE_FUTIMENS=1;
18536 HAVE_LCHMOD=1;
18537 HAVE_LSTAT=1;
18538 HAVE_MKDIRAT=1;
18539 HAVE_MKFIFO=1;
18540 HAVE_MKFIFOAT=1;
18541 HAVE_MKNOD=1;
18542 HAVE_MKNODAT=1;
18543 HAVE_UTIMENSAT=1;
18544 REPLACE_FSTAT=0;
18545 REPLACE_FSTATAT=0;
18546 REPLACE_FUTIMENS=0;
18547 REPLACE_LSTAT=0;
18548 REPLACE_MKDIR=0;
18549 REPLACE_MKFIFO=0;
18550 REPLACE_MKNOD=0;
18551 REPLACE_STAT=0;
18552 REPLACE_UTIMENSAT=0;
18557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18558 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18559 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18560 $as_echo_n "(cached) " >&6
18561 else
18562 rm -f conftest.sym conftest.file
18563 echo >conftest.file
18564 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18565 if test "$cross_compiling" = yes; then :
18566 case "$host_os" in
18567 # Guess yes on glibc systems.
18568 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18569 # If we don't know, assume the worst.
18570 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18571 esac
18573 else
18574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18575 /* end confdefs.h. */
18576 $ac_includes_default
18578 main ()
18580 struct stat sbuf;
18581 /* Linux will dereference the symlink and fail, as required by
18582 POSIX. That is better in the sense that it means we will not
18583 have to compile and use the lstat wrapper. */
18584 return lstat ("conftest.sym/", &sbuf) == 0;
18587 return 0;
18589 _ACEOF
18590 if ac_fn_c_try_run "$LINENO"; then :
18591 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18592 else
18593 gl_cv_func_lstat_dereferences_slashed_symlink=no
18595 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18596 conftest.$ac_objext conftest.beam conftest.$ac_ext
18599 else
18600 # If the 'ln -s' command failed, then we probably don't even
18601 # have an lstat function.
18602 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18604 rm -f conftest.sym conftest.file
18607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18608 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18609 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18610 *yes)
18612 cat >>confdefs.h <<_ACEOF
18613 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18614 _ACEOF
18617 esac
18620 GNULIB_MKTIME=0;
18621 GNULIB_NANOSLEEP=0;
18622 GNULIB_STRPTIME=0;
18623 GNULIB_TIMEGM=0;
18624 GNULIB_TIME_R=0;
18625 HAVE_DECL_LOCALTIME_R=1;
18626 HAVE_NANOSLEEP=1;
18627 HAVE_STRPTIME=1;
18628 HAVE_TIMEGM=1;
18629 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18630 REPLACE_MKTIME=GNULIB_PORTCHECK;
18631 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18632 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18637 GNULIB_PSELECT=0;
18638 GNULIB_SELECT=0;
18639 HAVE_PSELECT=1;
18640 REPLACE_PSELECT=0;
18641 REPLACE_SELECT=0;
18648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
18649 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
18650 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
18651 $as_echo_n "(cached) " >&6
18652 else
18654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18655 /* end confdefs.h. */
18656 #include <sys/select.h>
18658 main ()
18660 struct timeval b;
18662 return 0;
18664 _ACEOF
18665 if ac_fn_c_try_compile "$LINENO"; then :
18666 gl_cv_header_sys_select_h_selfcontained=yes
18667 else
18668 gl_cv_header_sys_select_h_selfcontained=no
18670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18671 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
18672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18673 /* end confdefs.h. */
18674 #include <sys/select.h>
18676 main ()
18678 int memset; int bzero;
18680 return 0;
18683 _ACEOF
18684 if ac_fn_c_try_compile "$LINENO"; then :
18685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18686 /* end confdefs.h. */
18687 #include <sys/select.h>
18689 main ()
18692 #undef memset
18693 #define memset nonexistent_memset
18694 extern
18695 #ifdef __cplusplus
18697 #endif
18698 void *memset (void *, int, unsigned long);
18699 #undef bzero
18700 #define bzero nonexistent_bzero
18701 extern
18702 #ifdef __cplusplus
18704 #endif
18705 void bzero (void *, unsigned long);
18706 fd_set fds;
18707 FD_ZERO (&fds);
18710 return 0;
18713 _ACEOF
18714 if ac_fn_c_try_link "$LINENO"; then :
18716 else
18717 gl_cv_header_sys_select_h_selfcontained=no
18719 rm -f core conftest.err conftest.$ac_objext \
18720 conftest$ac_exeext conftest.$ac_ext
18723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
18728 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
18738 if test $gl_cv_have_include_next = yes; then
18739 gl_cv_next_sys_select_h='<'sys/select.h'>'
18740 else
18741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
18742 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
18743 if test "${gl_cv_next_sys_select_h+set}" = set; then :
18744 $as_echo_n "(cached) " >&6
18745 else
18747 if test $ac_cv_header_sys_select_h = yes; then
18750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18751 /* end confdefs.h. */
18752 #include <sys/select.h>
18754 _ACEOF
18755 case "$host_os" in
18756 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18757 *) gl_absname_cpp="$ac_cpp" ;;
18758 esac
18760 case "$host_os" in
18761 mingw*)
18762 gl_dirsep_regex='[/\\]'
18765 gl_dirsep_regex='\/'
18767 esac
18768 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18770 gl_header_literal_regex=`echo 'sys/select.h' \
18771 | sed -e "$gl_make_literal_regex_sed"`
18772 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18773 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18774 s|^/[^/]|//&|
18778 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18779 sed -n "$gl_absolute_header_sed"`'"'
18780 else
18781 gl_cv_next_sys_select_h='<'sys/select.h'>'
18786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
18787 $as_echo "$gl_cv_next_sys_select_h" >&6; }
18789 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
18791 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18792 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18793 gl_next_as_first_directive='<'sys/select.h'>'
18794 else
18795 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18796 gl_next_as_first_directive=$gl_cv_next_sys_select_h
18798 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
18803 if test $ac_cv_header_sys_select_h = yes; then
18804 HAVE_SYS_SELECT_H=1
18805 else
18806 HAVE_SYS_SELECT_H=0
18813 if test $ac_cv_header_sys_socket_h != yes; then
18814 for ac_header in winsock2.h
18815 do :
18816 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
18817 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
18818 cat >>confdefs.h <<_ACEOF
18819 #define HAVE_WINSOCK2_H 1
18820 _ACEOF
18824 done
18827 if test "$ac_cv_header_winsock2_h" = yes; then
18828 HAVE_WINSOCK2_H=1
18829 UNISTD_H_HAVE_WINSOCK2_H=1
18830 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
18831 else
18832 HAVE_WINSOCK2_H=0
18842 GNULIB_PTHREAD_SIGMASK=0;
18843 GNULIB_RAISE=0;
18844 GNULIB_SIGNAL_H_SIGPIPE=0;
18845 GNULIB_SIGPROCMASK=0;
18846 GNULIB_SIGACTION=0;
18847 HAVE_POSIX_SIGNALBLOCKING=1;
18848 HAVE_PTHREAD_SIGMASK=1;
18849 HAVE_RAISE=1;
18850 HAVE_SIGSET_T=1;
18851 HAVE_SIGINFO_T=1;
18852 HAVE_SIGACTION=1;
18853 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
18855 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
18857 HAVE_SIGHANDLER_T=1;
18858 REPLACE_PTHREAD_SIGMASK=0;
18859 REPLACE_RAISE=0;
18866 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
18867 #include <signal.h>
18868 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
18869 #include <sys/types.h>
18872 if test "x$ac_cv_type_sigset_t" = x""yes; then :
18874 cat >>confdefs.h <<_ACEOF
18875 #define HAVE_SIGSET_T 1
18876 _ACEOF
18878 gl_cv_type_sigset_t=yes
18879 else
18880 gl_cv_type_sigset_t=no
18883 if test $gl_cv_type_sigset_t != yes; then
18884 HAVE_SIGSET_T=0
18889 if test $ac_cv_header_sys_socket_h = no; then
18890 for ac_header in ws2tcpip.h
18891 do :
18892 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
18893 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
18894 cat >>confdefs.h <<_ACEOF
18895 #define HAVE_WS2TCPIP_H 1
18896 _ACEOF
18900 done
18904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
18905 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
18906 if test "${ac_cv_header_stdbool_h+set}" = set; then :
18907 $as_echo_n "(cached) " >&6
18908 else
18909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18910 /* end confdefs.h. */
18912 #include <stdbool.h>
18913 #ifndef bool
18914 "error: bool is not defined"
18915 #endif
18916 #ifndef false
18917 "error: false is not defined"
18918 #endif
18919 #if false
18920 "error: false is not 0"
18921 #endif
18922 #ifndef true
18923 "error: true is not defined"
18924 #endif
18925 #if true != 1
18926 "error: true is not 1"
18927 #endif
18928 #ifndef __bool_true_false_are_defined
18929 "error: __bool_true_false_are_defined is not defined"
18930 #endif
18932 struct s { _Bool s: 1; _Bool t; } s;
18934 char a[true == 1 ? 1 : -1];
18935 char b[false == 0 ? 1 : -1];
18936 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
18937 char d[(bool) 0.5 == true ? 1 : -1];
18938 /* See body of main program for 'e'. */
18939 char f[(_Bool) 0.0 == false ? 1 : -1];
18940 char g[true];
18941 char h[sizeof (_Bool)];
18942 char i[sizeof s.t];
18943 enum { j = false, k = true, l = false * true, m = true * 256 };
18944 /* The following fails for
18945 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
18946 _Bool n[m];
18947 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
18948 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
18949 /* Catch a bug in an HP-UX C compiler. See
18950 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
18951 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
18953 _Bool q = true;
18954 _Bool *pq = &q;
18957 main ()
18960 bool e = &s;
18961 *pq |= q;
18962 *pq |= ! q;
18963 /* Refer to every declared value, to avoid compiler optimizations. */
18964 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
18965 + !m + !n + !o + !p + !q + !pq);
18968 return 0;
18970 _ACEOF
18971 if ac_fn_c_try_compile "$LINENO"; then :
18972 ac_cv_header_stdbool_h=yes
18973 else
18974 ac_cv_header_stdbool_h=no
18976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
18979 $as_echo "$ac_cv_header_stdbool_h" >&6; }
18980 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
18981 if test "x$ac_cv_type__Bool" = x""yes; then :
18983 cat >>confdefs.h <<_ACEOF
18984 #define HAVE__BOOL 1
18985 _ACEOF
18992 REPLACE_NULL=0;
18993 HAVE_WCHAR_T=1;
18996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
18997 $as_echo_n "checking for wchar_t... " >&6; }
18998 if test "${gt_cv_c_wchar_t+set}" = set; then :
18999 $as_echo_n "(cached) " >&6
19000 else
19001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19002 /* end confdefs.h. */
19003 #include <stddef.h>
19004 wchar_t foo = (wchar_t)'\0';
19006 main ()
19010 return 0;
19012 _ACEOF
19013 if ac_fn_c_try_compile "$LINENO"; then :
19014 gt_cv_c_wchar_t=yes
19015 else
19016 gt_cv_c_wchar_t=no
19018 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19021 $as_echo "$gt_cv_c_wchar_t" >&6; }
19022 if test $gt_cv_c_wchar_t = yes; then
19024 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19029 GNULIB_DPRINTF=0;
19030 GNULIB_FCLOSE=0;
19031 GNULIB_FDOPEN=0;
19032 GNULIB_FFLUSH=0;
19033 GNULIB_FGETC=0;
19034 GNULIB_FGETS=0;
19035 GNULIB_FOPEN=0;
19036 GNULIB_FPRINTF=0;
19037 GNULIB_FPRINTF_POSIX=0;
19038 GNULIB_FPURGE=0;
19039 GNULIB_FPUTC=0;
19040 GNULIB_FPUTS=0;
19041 GNULIB_FREAD=0;
19042 GNULIB_FREOPEN=0;
19043 GNULIB_FSCANF=0;
19044 GNULIB_FSEEK=0;
19045 GNULIB_FSEEKO=0;
19046 GNULIB_FTELL=0;
19047 GNULIB_FTELLO=0;
19048 GNULIB_FWRITE=0;
19049 GNULIB_GETC=0;
19050 GNULIB_GETCHAR=0;
19051 GNULIB_GETDELIM=0;
19052 GNULIB_GETLINE=0;
19053 GNULIB_OBSTACK_PRINTF=0;
19054 GNULIB_OBSTACK_PRINTF_POSIX=0;
19055 GNULIB_PCLOSE=0;
19056 GNULIB_PERROR=0;
19057 GNULIB_POPEN=0;
19058 GNULIB_PRINTF=0;
19059 GNULIB_PRINTF_POSIX=0;
19060 GNULIB_PUTC=0;
19061 GNULIB_PUTCHAR=0;
19062 GNULIB_PUTS=0;
19063 GNULIB_REMOVE=0;
19064 GNULIB_RENAME=0;
19065 GNULIB_RENAMEAT=0;
19066 GNULIB_SCANF=0;
19067 GNULIB_SNPRINTF=0;
19068 GNULIB_SPRINTF_POSIX=0;
19069 GNULIB_STDIO_H_NONBLOCKING=0;
19070 GNULIB_STDIO_H_SIGPIPE=0;
19071 GNULIB_TMPFILE=0;
19072 GNULIB_VASPRINTF=0;
19073 GNULIB_VFSCANF=0;
19074 GNULIB_VSCANF=0;
19075 GNULIB_VDPRINTF=0;
19076 GNULIB_VFPRINTF=0;
19077 GNULIB_VFPRINTF_POSIX=0;
19078 GNULIB_VPRINTF=0;
19079 GNULIB_VPRINTF_POSIX=0;
19080 GNULIB_VSNPRINTF=0;
19081 GNULIB_VSPRINTF_POSIX=0;
19082 HAVE_DECL_FPURGE=1;
19083 HAVE_DECL_FSEEKO=1;
19084 HAVE_DECL_FTELLO=1;
19085 HAVE_DECL_GETDELIM=1;
19086 HAVE_DECL_GETLINE=1;
19087 HAVE_DECL_OBSTACK_PRINTF=1;
19088 HAVE_DECL_SNPRINTF=1;
19089 HAVE_DECL_VSNPRINTF=1;
19090 HAVE_DPRINTF=1;
19091 HAVE_FSEEKO=1;
19092 HAVE_FTELLO=1;
19093 HAVE_PCLOSE=1;
19094 HAVE_POPEN=1;
19095 HAVE_RENAMEAT=1;
19096 HAVE_VASPRINTF=1;
19097 HAVE_VDPRINTF=1;
19098 REPLACE_DPRINTF=0;
19099 REPLACE_FCLOSE=0;
19100 REPLACE_FDOPEN=0;
19101 REPLACE_FFLUSH=0;
19102 REPLACE_FOPEN=0;
19103 REPLACE_FPRINTF=0;
19104 REPLACE_FPURGE=0;
19105 REPLACE_FREOPEN=0;
19106 REPLACE_FSEEK=0;
19107 REPLACE_FSEEKO=0;
19108 REPLACE_FTELL=0;
19109 REPLACE_FTELLO=0;
19110 REPLACE_GETDELIM=0;
19111 REPLACE_GETLINE=0;
19112 REPLACE_OBSTACK_PRINTF=0;
19113 REPLACE_PERROR=0;
19114 REPLACE_POPEN=0;
19115 REPLACE_PRINTF=0;
19116 REPLACE_REMOVE=0;
19117 REPLACE_RENAME=0;
19118 REPLACE_RENAMEAT=0;
19119 REPLACE_SNPRINTF=0;
19120 REPLACE_SPRINTF=0;
19121 REPLACE_STDIO_READ_FUNCS=0;
19122 REPLACE_STDIO_WRITE_FUNCS=0;
19123 REPLACE_TMPFILE=0;
19124 REPLACE_VASPRINTF=0;
19125 REPLACE_VDPRINTF=0;
19126 REPLACE_VFPRINTF=0;
19127 REPLACE_VPRINTF=0;
19128 REPLACE_VSNPRINTF=0;
19129 REPLACE_VSPRINTF=0;
19131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19132 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19133 if test "${ac_cv_struct_tm+set}" = set; then :
19134 $as_echo_n "(cached) " >&6
19135 else
19136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19137 /* end confdefs.h. */
19138 #include <sys/types.h>
19139 #include <time.h>
19142 main ()
19144 struct tm tm;
19145 int *p = &tm.tm_sec;
19146 return !p;
19148 return 0;
19150 _ACEOF
19151 if ac_fn_c_try_compile "$LINENO"; then :
19152 ac_cv_struct_tm=time.h
19153 else
19154 ac_cv_struct_tm=sys/time.h
19156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19159 $as_echo "$ac_cv_struct_tm" >&6; }
19160 if test $ac_cv_struct_tm = sys/time.h; then
19162 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19166 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19167 #include <$ac_cv_struct_tm>
19170 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19172 cat >>confdefs.h <<_ACEOF
19173 #define HAVE_STRUCT_TM_TM_ZONE 1
19174 _ACEOF
19179 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19181 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19183 else
19184 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19186 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19187 ac_have_decl=1
19188 else
19189 ac_have_decl=0
19192 cat >>confdefs.h <<_ACEOF
19193 #define HAVE_DECL_TZNAME $ac_have_decl
19194 _ACEOF
19196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19197 $as_echo_n "checking for tzname... " >&6; }
19198 if test "${ac_cv_var_tzname+set}" = set; then :
19199 $as_echo_n "(cached) " >&6
19200 else
19201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19202 /* end confdefs.h. */
19203 #include <time.h>
19204 #if !HAVE_DECL_TZNAME
19205 extern char *tzname[];
19206 #endif
19209 main ()
19211 return tzname[0][0];
19213 return 0;
19215 _ACEOF
19216 if ac_fn_c_try_link "$LINENO"; then :
19217 ac_cv_var_tzname=yes
19218 else
19219 ac_cv_var_tzname=no
19221 rm -f core conftest.err conftest.$ac_objext \
19222 conftest$ac_exeext conftest.$ac_ext
19224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19225 $as_echo "$ac_cv_var_tzname" >&6; }
19226 if test $ac_cv_var_tzname = yes; then
19228 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19234 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19236 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19238 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19245 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19246 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19247 ac_have_decl=1
19248 else
19249 ac_have_decl=0
19252 cat >>confdefs.h <<_ACEOF
19253 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19254 _ACEOF
19258 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19259 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19260 ac_have_decl=1
19261 else
19262 ac_have_decl=0
19265 cat >>confdefs.h <<_ACEOF
19266 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19267 _ACEOF
19271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19272 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19273 if test "${ac_cv_header_stat_broken+set}" = set; then :
19274 $as_echo_n "(cached) " >&6
19275 else
19276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19277 /* end confdefs.h. */
19278 #include <sys/types.h>
19279 #include <sys/stat.h>
19281 #if defined S_ISBLK && defined S_IFDIR
19282 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19283 #endif
19285 #if defined S_ISBLK && defined S_IFCHR
19286 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19287 #endif
19289 #if defined S_ISLNK && defined S_IFREG
19290 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19291 #endif
19293 #if defined S_ISSOCK && defined S_IFREG
19294 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19295 #endif
19297 _ACEOF
19298 if ac_fn_c_try_compile "$LINENO"; then :
19299 ac_cv_header_stat_broken=no
19300 else
19301 ac_cv_header_stat_broken=yes
19303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19306 $as_echo "$ac_cv_header_stat_broken" >&6; }
19307 if test $ac_cv_header_stat_broken = yes; then
19309 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19315 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19316 if test "x$ac_cv_type_mode_t" = x""yes; then :
19318 else
19320 cat >>confdefs.h <<_ACEOF
19321 #define mode_t int
19322 _ACEOF
19328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19329 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19330 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19331 $as_echo_n "(cached) " >&6
19332 else
19333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19334 /* end confdefs.h. */
19335 #include <time.h>
19338 main ()
19340 static struct timespec x; x.tv_sec = x.tv_nsec;
19342 return 0;
19344 _ACEOF
19345 if ac_fn_c_try_compile "$LINENO"; then :
19346 gl_cv_sys_struct_timespec_in_time_h=yes
19347 else
19348 gl_cv_sys_struct_timespec_in_time_h=no
19350 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19353 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19355 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19356 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19357 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19358 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19359 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19360 else
19361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19362 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19363 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19364 $as_echo_n "(cached) " >&6
19365 else
19366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19367 /* end confdefs.h. */
19368 #include <sys/time.h>
19371 main ()
19373 static struct timespec x; x.tv_sec = x.tv_nsec;
19375 return 0;
19377 _ACEOF
19378 if ac_fn_c_try_compile "$LINENO"; then :
19379 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19380 else
19381 gl_cv_sys_struct_timespec_in_sys_time_h=no
19383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19386 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19387 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19388 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19389 else
19390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19391 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19392 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19393 $as_echo_n "(cached) " >&6
19394 else
19395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19396 /* end confdefs.h. */
19397 #include <pthread.h>
19400 main ()
19402 static struct timespec x; x.tv_sec = x.tv_nsec;
19404 return 0;
19406 _ACEOF
19407 if ac_fn_c_try_compile "$LINENO"; then :
19408 gl_cv_sys_struct_timespec_in_pthread_h=yes
19409 else
19410 gl_cv_sys_struct_timespec_in_pthread_h=no
19412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19415 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19416 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19417 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19436 if test $gl_cv_have_include_next = yes; then
19437 gl_cv_next_time_h='<'time.h'>'
19438 else
19439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19440 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19441 if test "${gl_cv_next_time_h+set}" = set; then :
19442 $as_echo_n "(cached) " >&6
19443 else
19445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19446 /* end confdefs.h. */
19447 #include <time.h>
19449 _ACEOF
19450 case "$host_os" in
19451 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19452 *) gl_absname_cpp="$ac_cpp" ;;
19453 esac
19455 case "$host_os" in
19456 mingw*)
19457 gl_dirsep_regex='[/\\]'
19460 gl_dirsep_regex='\/'
19462 esac
19463 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19465 gl_header_literal_regex=`echo 'time.h' \
19466 | sed -e "$gl_make_literal_regex_sed"`
19467 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19468 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19469 s|^/[^/]|//&|
19473 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19474 sed -n "$gl_absolute_header_sed"`'"'
19478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19479 $as_echo "$gl_cv_next_time_h" >&6; }
19481 NEXT_TIME_H=$gl_cv_next_time_h
19483 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19484 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19485 gl_next_as_first_directive='<'time.h'>'
19486 else
19487 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19488 gl_next_as_first_directive=$gl_cv_next_time_h
19490 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
19507 $as_echo_n "checking whether the utimes function works... " >&6; }
19508 if test "${gl_cv_func_working_utimes+set}" = set; then :
19509 $as_echo_n "(cached) " >&6
19510 else
19512 if test "$cross_compiling" = yes; then :
19513 gl_cv_func_working_utimes=no
19514 else
19515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19516 /* end confdefs.h. */
19518 #include <sys/types.h>
19519 #include <sys/stat.h>
19520 #include <fcntl.h>
19521 #include <sys/time.h>
19522 #include <time.h>
19523 #include <unistd.h>
19524 #include <stdlib.h>
19525 #include <stdio.h>
19526 #include <utime.h>
19528 static int
19529 inorder (time_t a, time_t b, time_t c)
19531 return a <= b && b <= c;
19535 main ()
19537 int result = 0;
19538 char const *file = "conftest.utimes";
19539 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
19541 /* Test whether utimes() essentially works. */
19543 struct stat sbuf;
19544 FILE *f = fopen (file, "w");
19545 if (f == NULL)
19546 result |= 1;
19547 else if (fclose (f) != 0)
19548 result |= 1;
19549 else if (utimes (file, timeval) != 0)
19550 result |= 2;
19551 else if (lstat (file, &sbuf) != 0)
19552 result |= 1;
19553 else if (!(sbuf.st_atime == timeval[0].tv_sec
19554 && sbuf.st_mtime == timeval[1].tv_sec))
19555 result |= 4;
19556 if (unlink (file) != 0)
19557 result |= 1;
19560 /* Test whether utimes() with a NULL argument sets the file's timestamp
19561 to the current time. Use 'fstat' as well as 'time' to
19562 determine the "current" time, to accommodate NFS file systems
19563 if there is a time skew between the host and the NFS server. */
19565 int fd = open (file, O_WRONLY|O_CREAT, 0644);
19566 if (fd < 0)
19567 result |= 1;
19568 else
19570 time_t t0, t2;
19571 struct stat st0, st1, st2;
19572 if (time (&t0) == (time_t) -1)
19573 result |= 1;
19574 else if (fstat (fd, &st0) != 0)
19575 result |= 1;
19576 else if (utimes (file, timeval) != 0)
19577 result |= 2;
19578 else if (utimes (file, NULL) != 0)
19579 result |= 8;
19580 else if (fstat (fd, &st1) != 0)
19581 result |= 1;
19582 else if (write (fd, "\n", 1) != 1)
19583 result |= 1;
19584 else if (fstat (fd, &st2) != 0)
19585 result |= 1;
19586 else if (time (&t2) == (time_t) -1)
19587 result |= 1;
19588 else
19590 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
19591 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
19592 if (! (st1.st_atime == st1.st_mtime))
19593 result |= 16;
19594 if (! (m_ok_POSIX || m_ok_NFS))
19595 result |= 32;
19597 if (close (fd) != 0)
19598 result |= 1;
19600 if (unlink (file) != 0)
19601 result |= 1;
19604 /* Test whether utimes() with a NULL argument works on read-only files. */
19606 int fd = open (file, O_WRONLY|O_CREAT, 0444);
19607 if (fd < 0)
19608 result |= 1;
19609 else if (close (fd) != 0)
19610 result |= 1;
19611 else if (utimes (file, NULL) != 0)
19612 result |= 64;
19613 if (unlink (file) != 0)
19614 result |= 1;
19617 return result;
19620 _ACEOF
19621 if ac_fn_c_try_run "$LINENO"; then :
19622 gl_cv_func_working_utimes=yes
19623 else
19624 gl_cv_func_working_utimes=no
19626 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19627 conftest.$ac_objext conftest.beam conftest.$ac_ext
19631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
19632 $as_echo "$gl_cv_func_working_utimes" >&6; }
19634 if test $gl_cv_func_working_utimes = yes; then
19636 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
19644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
19645 $as_echo_n "checking for struct utimbuf... " >&6; }
19646 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
19647 $as_echo_n "(cached) " >&6
19648 else
19649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19650 /* end confdefs.h. */
19651 #if HAVE_SYS_TIME_H
19652 #include <sys/time.h>
19653 #endif
19654 #include <time.h>
19655 #ifdef HAVE_UTIME_H
19656 #include <utime.h>
19657 #endif
19660 main ()
19662 static struct utimbuf x; x.actime = x.modtime;
19664 return 0;
19666 _ACEOF
19667 if ac_fn_c_try_compile "$LINENO"; then :
19668 gl_cv_sys_struct_utimbuf=yes
19669 else
19670 gl_cv_sys_struct_utimbuf=no
19672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
19675 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
19677 if test $gl_cv_sys_struct_utimbuf = yes; then
19679 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
19694 if false; then
19695 GL_COND_LIBTOOL_TRUE=
19696 GL_COND_LIBTOOL_FALSE='#'
19697 else
19698 GL_COND_LIBTOOL_TRUE='#'
19699 GL_COND_LIBTOOL_FALSE=
19702 gl_cond_libtool=false
19703 gl_libdeps=
19704 gl_ltlibdeps=
19705 gl_m4_base='m4'
19715 gl_source_base='lib'
19718 if test $ac_cv_func_alloca_works = no; then
19722 # Define an additional variable used in the Makefile substitution.
19723 if test $ac_cv_working_alloca_h = yes; then
19724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
19725 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
19726 if test "${gl_cv_rpl_alloca+set}" = set; then :
19727 $as_echo_n "(cached) " >&6
19728 else
19730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19731 /* end confdefs.h. */
19733 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
19734 Need own alloca
19735 #endif
19737 _ACEOF
19738 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19739 $EGREP "Need own alloca" >/dev/null 2>&1; then :
19740 gl_cv_rpl_alloca=yes
19741 else
19742 gl_cv_rpl_alloca=no
19744 rm -f conftest*
19748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
19749 $as_echo "$gl_cv_rpl_alloca" >&6; }
19750 if test $gl_cv_rpl_alloca = yes; then
19752 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
19754 ALLOCA_H=alloca.h
19755 else
19756 ALLOCA_H=
19758 else
19759 ALLOCA_H=alloca.h
19762 if test -n "$ALLOCA_H"; then
19763 GL_GENERATE_ALLOCA_H_TRUE=
19764 GL_GENERATE_ALLOCA_H_FALSE='#'
19765 else
19766 GL_GENERATE_ALLOCA_H_TRUE='#'
19767 GL_GENERATE_ALLOCA_H_FALSE=
19775 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
19776 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
19778 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
19779 # programs in the package would end up linked with that potentially-shared
19780 # library, inducing unnecessary run-time overhead.
19781 LIB_CLOCK_GETTIME=
19783 gl_saved_libs=$LIBS
19784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
19785 $as_echo_n "checking for library containing clock_gettime... " >&6; }
19786 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19787 $as_echo_n "(cached) " >&6
19788 else
19789 ac_func_search_save_LIBS=$LIBS
19790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19791 /* end confdefs.h. */
19793 /* Override any GCC internal prototype to avoid an error.
19794 Use char because int might match the return type of a GCC
19795 builtin and then its argument prototype would still apply. */
19796 #ifdef __cplusplus
19797 extern "C"
19798 #endif
19799 char clock_gettime ();
19801 main ()
19803 return clock_gettime ();
19805 return 0;
19807 _ACEOF
19808 for ac_lib in '' rt posix4; do
19809 if test -z "$ac_lib"; then
19810 ac_res="none required"
19811 else
19812 ac_res=-l$ac_lib
19813 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19815 if ac_fn_c_try_link "$LINENO"; then :
19816 ac_cv_search_clock_gettime=$ac_res
19818 rm -f core conftest.err conftest.$ac_objext \
19819 conftest$ac_exeext
19820 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19821 break
19823 done
19824 if test "${ac_cv_search_clock_gettime+set}" = set; then :
19826 else
19827 ac_cv_search_clock_gettime=no
19829 rm conftest.$ac_ext
19830 LIBS=$ac_func_search_save_LIBS
19832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
19833 $as_echo "$ac_cv_search_clock_gettime" >&6; }
19834 ac_res=$ac_cv_search_clock_gettime
19835 if test "$ac_res" != no; then :
19836 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19837 test "$ac_cv_search_clock_gettime" = "none required" ||
19838 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
19841 for ac_func in clock_gettime clock_settime
19842 do :
19843 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19844 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
19845 eval as_val=\$$as_ac_var
19846 if test "x$as_val" = x""yes; then :
19847 cat >>confdefs.h <<_ACEOF
19848 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19849 _ACEOF
19852 done
19854 LIBS=$gl_saved_libs
19880 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
19883 if test $HAVE_DUP2 = 1; then
19884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
19885 $as_echo_n "checking whether dup2 works... " >&6; }
19886 if test "${gl_cv_func_dup2_works+set}" = set; then :
19887 $as_echo_n "(cached) " >&6
19888 else
19889 if test "$cross_compiling" = yes; then :
19890 case "$host_os" in
19891 mingw*) # on this platform, dup2 always returns 0 for success
19892 gl_cv_func_dup2_works="guessing no" ;;
19893 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
19894 gl_cv_func_dup2_works="guessing no" ;;
19895 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
19896 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
19897 gl_cv_func_dup2_works="guessing no" ;;
19898 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
19899 gl_cv_func_dup2_works="guessing no" ;;
19900 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
19901 gl_cv_func_dup2_works="guessing no" ;;
19902 *) gl_cv_func_dup2_works="guessing yes" ;;
19903 esac
19904 else
19905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19906 /* end confdefs.h. */
19908 #include <unistd.h>
19909 #include <fcntl.h>
19910 #include <errno.h>
19912 main ()
19914 int result = 0;
19915 #ifdef FD_CLOEXEC
19916 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
19917 result |= 1;
19918 #endif
19919 if (dup2 (1, 1) == 0)
19920 result |= 2;
19921 #ifdef FD_CLOEXEC
19922 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
19923 result |= 4;
19924 #endif
19925 close (0);
19926 if (dup2 (0, 0) != -1)
19927 result |= 8;
19928 /* Many gnulib modules require POSIX conformance of EBADF. */
19929 if (dup2 (2, 1000000) == -1 && errno != EBADF)
19930 result |= 16;
19931 return result;
19934 return 0;
19937 _ACEOF
19938 if ac_fn_c_try_run "$LINENO"; then :
19939 gl_cv_func_dup2_works=yes
19940 else
19941 gl_cv_func_dup2_works=no
19943 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19944 conftest.$ac_objext conftest.beam conftest.$ac_ext
19949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
19950 $as_echo "$gl_cv_func_dup2_works" >&6; }
19951 case "$gl_cv_func_dup2_works" in
19952 *yes) ;;
19954 REPLACE_DUP2=1
19956 esac
19960 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
19969 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
19978 GNULIB_DUP2=1
19990 GNULIB_ENVIRON=1
20002 # Persuade glibc <stdlib.h> to declare getloadavg().
20005 gl_save_LIBS=$LIBS
20007 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20008 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20009 HAVE_GETLOADAVG=1
20010 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20011 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20013 else
20014 gl_func_getloadavg_done=no
20016 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20017 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20018 # to get the right answer into the cache.
20019 # For kstat on solaris, we need to test for libelf and libkvm to force the
20020 # definition of SVR4 below.
20021 if test $gl_func_getloadavg_done = no; then
20022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20023 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20024 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20025 $as_echo_n "(cached) " >&6
20026 else
20027 ac_check_lib_save_LIBS=$LIBS
20028 LIBS="-lelf $LIBS"
20029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20030 /* end confdefs.h. */
20032 /* Override any GCC internal prototype to avoid an error.
20033 Use char because int might match the return type of a GCC
20034 builtin and then its argument prototype would still apply. */
20035 #ifdef __cplusplus
20036 extern "C"
20037 #endif
20038 char elf_begin ();
20040 main ()
20042 return elf_begin ();
20044 return 0;
20046 _ACEOF
20047 if ac_fn_c_try_link "$LINENO"; then :
20048 ac_cv_lib_elf_elf_begin=yes
20049 else
20050 ac_cv_lib_elf_elf_begin=no
20052 rm -f core conftest.err conftest.$ac_objext \
20053 conftest$ac_exeext conftest.$ac_ext
20054 LIBS=$ac_check_lib_save_LIBS
20056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20057 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20058 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20059 LIBS="-lelf $LIBS"
20062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20063 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20064 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20065 $as_echo_n "(cached) " >&6
20066 else
20067 ac_check_lib_save_LIBS=$LIBS
20068 LIBS="-lkvm $LIBS"
20069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20070 /* end confdefs.h. */
20072 /* Override any GCC internal prototype to avoid an error.
20073 Use char because int might match the return type of a GCC
20074 builtin and then its argument prototype would still apply. */
20075 #ifdef __cplusplus
20076 extern "C"
20077 #endif
20078 char kvm_open ();
20080 main ()
20082 return kvm_open ();
20084 return 0;
20086 _ACEOF
20087 if ac_fn_c_try_link "$LINENO"; then :
20088 ac_cv_lib_kvm_kvm_open=yes
20089 else
20090 ac_cv_lib_kvm_kvm_open=no
20092 rm -f core conftest.err conftest.$ac_objext \
20093 conftest$ac_exeext conftest.$ac_ext
20094 LIBS=$ac_check_lib_save_LIBS
20096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20097 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20098 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20099 LIBS="-lkvm $LIBS"
20102 # Check for the 4.4BSD definition of getloadavg.
20103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20104 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20105 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20106 $as_echo_n "(cached) " >&6
20107 else
20108 ac_check_lib_save_LIBS=$LIBS
20109 LIBS="-lutil $LIBS"
20110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20111 /* end confdefs.h. */
20113 /* Override any GCC internal prototype to avoid an error.
20114 Use char because int might match the return type of a GCC
20115 builtin and then its argument prototype would still apply. */
20116 #ifdef __cplusplus
20117 extern "C"
20118 #endif
20119 char getloadavg ();
20121 main ()
20123 return getloadavg ();
20125 return 0;
20127 _ACEOF
20128 if ac_fn_c_try_link "$LINENO"; then :
20129 ac_cv_lib_util_getloadavg=yes
20130 else
20131 ac_cv_lib_util_getloadavg=no
20133 rm -f core conftest.err conftest.$ac_objext \
20134 conftest$ac_exeext conftest.$ac_ext
20135 LIBS=$ac_check_lib_save_LIBS
20137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20138 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20139 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20140 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20145 if test $gl_func_getloadavg_done = no; then
20146 # There is a commonly available library for RS/6000 AIX.
20147 # Since it is not a standard part of AIX, it might be installed locally.
20148 gl_getloadavg_LIBS=$LIBS
20149 LIBS="-L/usr/local/lib $LIBS"
20150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20151 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20152 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20153 $as_echo_n "(cached) " >&6
20154 else
20155 ac_check_lib_save_LIBS=$LIBS
20156 LIBS="-lgetloadavg $LIBS"
20157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20158 /* end confdefs.h. */
20160 /* Override any GCC internal prototype to avoid an error.
20161 Use char because int might match the return type of a GCC
20162 builtin and then its argument prototype would still apply. */
20163 #ifdef __cplusplus
20164 extern "C"
20165 #endif
20166 char getloadavg ();
20168 main ()
20170 return getloadavg ();
20172 return 0;
20174 _ACEOF
20175 if ac_fn_c_try_link "$LINENO"; then :
20176 ac_cv_lib_getloadavg_getloadavg=yes
20177 else
20178 ac_cv_lib_getloadavg_getloadavg=no
20180 rm -f core conftest.err conftest.$ac_objext \
20181 conftest$ac_exeext conftest.$ac_ext
20182 LIBS=$ac_check_lib_save_LIBS
20184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
20185 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20186 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20187 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20188 else
20189 LIBS=$gl_getloadavg_LIBS
20194 # Set up the replacement function if necessary.
20195 if test $gl_func_getloadavg_done = no; then
20196 HAVE_GETLOADAVG=0
20198 # Solaris has libkstat which does not require root.
20199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20200 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20201 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20202 $as_echo_n "(cached) " >&6
20203 else
20204 ac_check_lib_save_LIBS=$LIBS
20205 LIBS="-lkstat $LIBS"
20206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20207 /* end confdefs.h. */
20209 /* Override any GCC internal prototype to avoid an error.
20210 Use char because int might match the return type of a GCC
20211 builtin and then its argument prototype would still apply. */
20212 #ifdef __cplusplus
20213 extern "C"
20214 #endif
20215 char kstat_open ();
20217 main ()
20219 return kstat_open ();
20221 return 0;
20223 _ACEOF
20224 if ac_fn_c_try_link "$LINENO"; then :
20225 ac_cv_lib_kstat_kstat_open=yes
20226 else
20227 ac_cv_lib_kstat_kstat_open=no
20229 rm -f core conftest.err conftest.$ac_objext \
20230 conftest$ac_exeext conftest.$ac_ext
20231 LIBS=$ac_check_lib_save_LIBS
20233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20234 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20235 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20236 cat >>confdefs.h <<_ACEOF
20237 #define HAVE_LIBKSTAT 1
20238 _ACEOF
20240 LIBS="-lkstat $LIBS"
20244 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20246 # AIX has libperfstat which does not require root
20247 if test $gl_func_getloadavg_done = no; then
20248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20249 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20250 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20251 $as_echo_n "(cached) " >&6
20252 else
20253 ac_check_lib_save_LIBS=$LIBS
20254 LIBS="-lperfstat $LIBS"
20255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20256 /* end confdefs.h. */
20258 /* Override any GCC internal prototype to avoid an error.
20259 Use char because int might match the return type of a GCC
20260 builtin and then its argument prototype would still apply. */
20261 #ifdef __cplusplus
20262 extern "C"
20263 #endif
20264 char perfstat_cpu_total ();
20266 main ()
20268 return perfstat_cpu_total ();
20270 return 0;
20272 _ACEOF
20273 if ac_fn_c_try_link "$LINENO"; then :
20274 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20275 else
20276 ac_cv_lib_perfstat_perfstat_cpu_total=no
20278 rm -f core conftest.err conftest.$ac_objext \
20279 conftest$ac_exeext conftest.$ac_ext
20280 LIBS=$ac_check_lib_save_LIBS
20282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20283 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20284 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20285 cat >>confdefs.h <<_ACEOF
20286 #define HAVE_LIBPERFSTAT 1
20287 _ACEOF
20289 LIBS="-lperfstat $LIBS"
20293 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20296 if test $gl_func_getloadavg_done = no; then
20297 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20298 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20299 gl_func_getloadavg_done=yes
20301 $as_echo "#define DGUX 1" >>confdefs.h
20303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20304 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20305 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20306 $as_echo_n "(cached) " >&6
20307 else
20308 ac_check_lib_save_LIBS=$LIBS
20309 LIBS="-ldgc $LIBS"
20310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20311 /* end confdefs.h. */
20313 /* Override any GCC internal prototype to avoid an error.
20314 Use char because int might match the return type of a GCC
20315 builtin and then its argument prototype would still apply. */
20316 #ifdef __cplusplus
20317 extern "C"
20318 #endif
20319 char dg_sys_info ();
20321 main ()
20323 return dg_sys_info ();
20325 return 0;
20327 _ACEOF
20328 if ac_fn_c_try_link "$LINENO"; then :
20329 ac_cv_lib_dgc_dg_sys_info=yes
20330 else
20331 ac_cv_lib_dgc_dg_sys_info=no
20333 rm -f core conftest.err conftest.$ac_objext \
20334 conftest$ac_exeext conftest.$ac_ext
20335 LIBS=$ac_check_lib_save_LIBS
20337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
20338 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
20339 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
20340 cat >>confdefs.h <<_ACEOF
20341 #define HAVE_LIBDGC 1
20342 _ACEOF
20344 LIBS="-ldgc $LIBS"
20356 if test "x$gl_save_LIBS" = x; then
20357 GETLOADAVG_LIBS=$LIBS
20358 else
20359 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
20361 LIBS=$gl_save_LIBS
20364 # Test whether the system declares getloadavg. Solaris has the function
20365 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
20366 for ac_header in sys/loadavg.h
20367 do :
20368 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
20369 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
20370 cat >>confdefs.h <<_ACEOF
20371 #define HAVE_SYS_LOADAVG_H 1
20372 _ACEOF
20376 done
20378 if test $ac_cv_header_sys_loadavg_h = yes; then
20379 HAVE_SYS_LOADAVG_H=1
20380 else
20381 HAVE_SYS_LOADAVG_H=0
20383 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
20384 # include <sys/loadavg.h>
20385 #endif
20386 #include <stdlib.h>
20388 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
20390 else
20391 HAVE_DECL_GETLOADAVG=0
20395 if test $HAVE_GETLOADAVG = 0; then
20404 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
20407 # Figure out what our getloadavg.c needs.
20411 # On HPUX9, an unprivileged user can get load averages this way.
20412 if test $gl_func_getloadavg_done = no; then
20413 for ac_func in pstat_getdynamic
20414 do :
20415 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
20416 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
20417 cat >>confdefs.h <<_ACEOF
20418 #define HAVE_PSTAT_GETDYNAMIC 1
20419 _ACEOF
20420 gl_func_getloadavg_done=yes
20422 done
20426 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
20427 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
20428 # Irix 4.0.5F has the header but not the library.
20429 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
20430 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
20431 gl_func_getloadavg_done=yes
20433 $as_echo "#define SVR4 1" >>confdefs.h
20437 if test $gl_func_getloadavg_done = no; then
20438 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
20439 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
20440 gl_func_getloadavg_done=yes
20442 $as_echo "#define UMAX 1" >>confdefs.h
20445 $as_echo "#define UMAX4_3 1" >>confdefs.h
20452 if test $gl_func_getloadavg_done = no; then
20453 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
20454 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
20455 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
20462 if test $gl_func_getloadavg_done = no; then
20463 for ac_header in mach/mach.h
20464 do :
20465 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
20466 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
20467 cat >>confdefs.h <<_ACEOF
20468 #define HAVE_MACH_MACH_H 1
20469 _ACEOF
20473 done
20477 for ac_header in nlist.h
20478 do :
20479 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
20480 if test "x$ac_cv_header_nlist_h" = x""yes; then :
20481 cat >>confdefs.h <<_ACEOF
20482 #define HAVE_NLIST_H 1
20483 _ACEOF
20484 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
20486 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
20488 cat >>confdefs.h <<_ACEOF
20489 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
20490 _ACEOF
20495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20496 /* end confdefs.h. */
20497 #include <nlist.h>
20499 main ()
20501 struct nlist x;
20502 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
20503 x.n_un.n_name = "";
20504 #else
20505 x.n_name = "";
20506 #endif
20508 return 0;
20510 _ACEOF
20511 if ac_fn_c_try_link "$LINENO"; then :
20513 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
20516 rm -f core conftest.err conftest.$ac_objext \
20517 conftest$ac_exeext conftest.$ac_ext
20521 done
20529 GNULIB_GETLOADAVG=1
20540 if test $REPLACE_GETOPT = 1; then
20549 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20559 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20564 GNULIB_GL_UNISTD_H_GETOPT=1
20573 REPLACE_GETOPT=0
20574 if test -n "$gl_replace_getopt"; then
20575 REPLACE_GETOPT=1
20578 if test $REPLACE_GETOPT = 1; then
20580 GETOPT_H=getopt.h
20582 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
20588 if test $REPLACE_GETOPT = 1; then
20597 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20607 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20612 GNULIB_GL_UNISTD_H_GETOPT=1
20626 gl_gettimeofday_timezone=void
20627 if test $ac_cv_func_gettimeofday != yes; then
20628 HAVE_GETTIMEOFDAY=0
20629 else
20633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
20634 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
20635 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
20636 $as_echo_n "(cached) " >&6
20637 else
20638 if test "$cross_compiling" = yes; then :
20639 # When cross-compiling:
20640 case "$host_os" in
20641 # Guess all is fine on glibc systems.
20642 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
20643 # If we don't know, assume the worst.
20644 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
20645 esac
20647 else
20648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20649 /* end confdefs.h. */
20650 #include <string.h>
20651 #include <sys/time.h>
20652 #include <time.h>
20653 #include <stdlib.h>
20656 main ()
20659 time_t t = 0;
20660 struct tm *lt;
20661 struct tm saved_lt;
20662 struct timeval tv;
20663 lt = localtime (&t);
20664 saved_lt = *lt;
20665 gettimeofday (&tv, NULL);
20666 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
20669 return 0;
20671 _ACEOF
20672 if ac_fn_c_try_run "$LINENO"; then :
20673 gl_cv_func_gettimeofday_clobber=no
20674 else
20675 gl_cv_func_gettimeofday_clobber=yes
20677 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20678 conftest.$ac_objext conftest.beam conftest.$ac_ext
20682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
20683 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
20685 case "$gl_cv_func_gettimeofday_clobber" in
20686 *yes)
20687 REPLACE_GETTIMEOFDAY=1
20690 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
20693 $as_echo "#define localtime rpl_localtime" >>confdefs.h
20697 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
20700 esac
20702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
20703 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
20704 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
20705 $as_echo_n "(cached) " >&6
20706 else
20707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20708 /* end confdefs.h. */
20709 #include <sys/time.h>
20710 struct timeval c;
20711 int gettimeofday (struct timeval *restrict, void *restrict);
20714 main ()
20716 /* glibc uses struct timezone * rather than the POSIX void *
20717 if _GNU_SOURCE is defined. However, since the only portable
20718 use of gettimeofday uses NULL as the second parameter, and
20719 since the glibc definition is actually more typesafe, it is
20720 not worth wrapping this to get a compliant signature. */
20721 int (*f) (struct timeval *restrict, void *restrict)
20722 = gettimeofday;
20723 int x = f (&c, 0);
20724 return !(x | c.tv_sec | c.tv_usec);
20727 return 0;
20729 _ACEOF
20730 if ac_fn_c_try_compile "$LINENO"; then :
20731 gl_cv_func_gettimeofday_posix_signature=yes
20732 else
20733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20734 /* end confdefs.h. */
20735 #include <sys/time.h>
20736 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
20739 main ()
20743 return 0;
20745 _ACEOF
20746 if ac_fn_c_try_compile "$LINENO"; then :
20747 gl_cv_func_gettimeofday_posix_signature=almost
20748 else
20749 gl_cv_func_gettimeofday_posix_signature=no
20751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
20756 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
20757 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
20758 gl_gettimeofday_timezone='struct timezone'
20759 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
20760 REPLACE_GETTIMEOFDAY=1
20762 if test $REPLACE_STRUCT_TIMEVAL = 1; then
20763 REPLACE_GETTIMEOFDAY=1
20768 cat >>confdefs.h <<_ACEOF
20769 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
20770 _ACEOF
20773 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
20782 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
20785 for ac_header in sys/timeb.h
20786 do :
20787 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
20788 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
20789 cat >>confdefs.h <<_ACEOF
20790 #define HAVE_SYS_TIMEB_H 1
20791 _ACEOF
20795 done
20797 for ac_func in _ftime
20798 do :
20799 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
20800 if test "x$ac_cv_func__ftime" = x""yes; then :
20801 cat >>confdefs.h <<_ACEOF
20802 #define HAVE__FTIME 1
20803 _ACEOF
20806 done
20815 GNULIB_GETTIMEOFDAY=1
20827 if test $ac_cv_func_lstat = yes; then
20829 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
20830 *no)
20831 REPLACE_LSTAT=1
20833 esac
20834 else
20835 HAVE_LSTAT=0
20838 if test $REPLACE_LSTAT = 1; then
20847 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
20859 GNULIB_LSTAT=1
20871 if test $APPLE_UNIVERSAL_BUILD = 1; then
20872 # A universal build on Apple Mac OS X platforms.
20873 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
20874 # But we need a configuration result that is valid in both modes.
20875 gl_cv_func_working_mktime=no
20877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
20878 $as_echo_n "checking for working mktime... " >&6; }
20879 if test "${gl_cv_func_working_mktime+set}" = set; then :
20880 $as_echo_n "(cached) " >&6
20881 else
20882 if test "$cross_compiling" = yes; then :
20883 gl_cv_func_working_mktime=no
20884 else
20885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20886 /* end confdefs.h. */
20887 /* Test program from Paul Eggert and Tony Leneis. */
20888 #include <limits.h>
20889 #include <stdlib.h>
20890 #include <time.h>
20892 #ifdef HAVE_UNISTD_H
20893 # include <unistd.h>
20894 #endif
20896 #ifndef HAVE_ALARM
20897 # define alarm(X) /* empty */
20898 #endif
20900 /* Work around redefinition to rpl_putenv by other config tests. */
20901 #undef putenv
20903 static time_t time_t_max;
20904 static time_t time_t_min;
20906 /* Values we'll use to set the TZ environment variable. */
20907 static char *tz_strings[] = {
20908 (char *) 0, "TZ=GMT0", "TZ=JST-9",
20909 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
20911 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
20913 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
20914 Based on a problem report from Andreas Jaeger. */
20915 static int
20916 spring_forward_gap ()
20918 /* glibc (up to about 1998-10-07) failed this test. */
20919 struct tm tm;
20921 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
20922 instead of "TZ=America/Vancouver" in order to detect the bug even
20923 on systems that don't support the Olson extension, or don't have the
20924 full zoneinfo tables installed. */
20925 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
20927 tm.tm_year = 98;
20928 tm.tm_mon = 3;
20929 tm.tm_mday = 5;
20930 tm.tm_hour = 2;
20931 tm.tm_min = 0;
20932 tm.tm_sec = 0;
20933 tm.tm_isdst = -1;
20934 return mktime (&tm) != (time_t) -1;
20937 static int
20938 mktime_test1 (time_t now)
20940 struct tm *lt;
20941 return ! (lt = localtime (&now)) || mktime (lt) == now;
20944 static int
20945 mktime_test (time_t now)
20947 return (mktime_test1 (now)
20948 && mktime_test1 ((time_t) (time_t_max - now))
20949 && mktime_test1 ((time_t) (time_t_min + now)));
20952 static int
20953 irix_6_4_bug ()
20955 /* Based on code from Ariel Faigon. */
20956 struct tm tm;
20957 tm.tm_year = 96;
20958 tm.tm_mon = 3;
20959 tm.tm_mday = 0;
20960 tm.tm_hour = 0;
20961 tm.tm_min = 0;
20962 tm.tm_sec = 0;
20963 tm.tm_isdst = -1;
20964 mktime (&tm);
20965 return tm.tm_mon == 2 && tm.tm_mday == 31;
20968 static int
20969 bigtime_test (int j)
20971 struct tm tm;
20972 time_t now;
20973 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
20974 now = mktime (&tm);
20975 if (now != (time_t) -1)
20977 struct tm *lt = localtime (&now);
20978 if (! (lt
20979 && lt->tm_year == tm.tm_year
20980 && lt->tm_mon == tm.tm_mon
20981 && lt->tm_mday == tm.tm_mday
20982 && lt->tm_hour == tm.tm_hour
20983 && lt->tm_min == tm.tm_min
20984 && lt->tm_sec == tm.tm_sec
20985 && lt->tm_yday == tm.tm_yday
20986 && lt->tm_wday == tm.tm_wday
20987 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
20988 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
20989 return 0;
20991 return 1;
20994 static int
20995 year_2050_test ()
20997 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
20998 ignoring leap seconds. */
20999 unsigned long int answer = 2527315200UL;
21001 struct tm tm;
21002 time_t t;
21003 tm.tm_year = 2050 - 1900;
21004 tm.tm_mon = 2 - 1;
21005 tm.tm_mday = 1;
21006 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21007 tm.tm_isdst = -1;
21009 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21010 instead of "TZ=America/Vancouver" in order to detect the bug even
21011 on systems that don't support the Olson extension, or don't have the
21012 full zoneinfo tables installed. */
21013 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21015 t = mktime (&tm);
21017 /* Check that the result is either a failure, or close enough
21018 to the correct answer that we can assume the discrepancy is
21019 due to leap seconds. */
21020 return (t == (time_t) -1
21021 || (0 < t && answer - 120 <= t && t <= answer + 120));
21025 main ()
21027 int result = 0;
21028 time_t t, delta;
21029 int i, j;
21030 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21031 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21033 /* This test makes some buggy mktime implementations loop.
21034 Give up after 60 seconds; a mktime slower than that
21035 isn't worth using anyway. */
21036 alarm (60);
21038 time_t_max = (! time_t_signed
21039 ? (time_t) -1
21040 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21041 * 2 + 1));
21042 time_t_min = (! time_t_signed
21043 ? (time_t) 0
21044 : time_t_signed_magnitude
21045 ? ~ (time_t) 0
21046 : ~ time_t_max);
21048 delta = time_t_max / 997; /* a suitable prime number */
21049 for (i = 0; i < N_STRINGS; i++)
21051 if (tz_strings[i])
21052 putenv (tz_strings[i]);
21054 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21055 if (! mktime_test (t))
21056 result |= 1;
21057 if ((result & 2) == 0
21058 && ! (mktime_test ((time_t) 1)
21059 && mktime_test ((time_t) (60 * 60))
21060 && mktime_test ((time_t) (60 * 60 * 24))))
21061 result |= 2;
21063 for (j = 1; (result & 4) == 0; j <<= 1)
21065 if (! bigtime_test (j))
21066 result |= 4;
21067 if (INT_MAX / 2 < j)
21068 break;
21070 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21071 result |= 8;
21073 if (! irix_6_4_bug ())
21074 result |= 16;
21075 if (! spring_forward_gap ())
21076 result |= 32;
21077 if (! year_2050_test ())
21078 result |= 64;
21079 return result;
21081 _ACEOF
21082 if ac_fn_c_try_run "$LINENO"; then :
21083 gl_cv_func_working_mktime=yes
21084 else
21085 gl_cv_func_working_mktime=no
21087 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21088 conftest.$ac_objext conftest.beam conftest.$ac_ext
21093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21094 $as_echo "$gl_cv_func_working_mktime" >&6; }
21096 if test $gl_cv_func_working_mktime = no; then
21097 REPLACE_MKTIME=1
21098 else
21099 REPLACE_MKTIME=0
21102 if test $REPLACE_MKTIME = 1; then
21111 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21122 GNULIB_MKTIME=1
21134 if test $ac_cv_func_pselect = yes; then
21135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21136 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21137 if test "${gl_cv_sig_pselect+set}" = set; then :
21138 $as_echo_n "(cached) " >&6
21139 else
21140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21141 /* end confdefs.h. */
21142 #include <sys/select.h>
21145 main ()
21147 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21148 struct timespec const *restrict,
21149 sigset_t const *restrict) = pselect;
21150 return !p;
21152 return 0;
21154 _ACEOF
21155 if ac_fn_c_try_link "$LINENO"; then :
21156 gl_cv_sig_pselect=yes
21157 else
21158 gl_cv_sig_pselect=no
21160 rm -f core conftest.err conftest.$ac_objext \
21161 conftest$ac_exeext conftest.$ac_ext
21163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21164 $as_echo "$gl_cv_sig_pselect" >&6; }
21167 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21168 REPLACE_PSELECT=1
21171 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21180 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21188 GNULIB_PSELECT=1
21198 LIB_PTHREAD_SIGMASK=
21201 if test $ac_cv_func_pthread_sigmask = yes; then
21203 else
21204 HAVE_PTHREAD_SIGMASK=0
21205 REPLACE_PTHREAD_SIGMASK=1
21211 if test $HAVE_PTHREAD_SIGMASK = 1; then
21214 if test -z "$LIB_PTHREAD_SIGMASK"; then
21215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
21216 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
21217 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
21218 $as_echo_n "(cached) " >&6
21219 else
21221 if test "$cross_compiling" = yes; then :
21223 case "$host_os" in
21224 freebsd* | hpux* | solaris | solaris2.[2-9]*)
21225 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
21227 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
21228 esac
21230 else
21231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21232 /* end confdefs.h. */
21234 #include <pthread.h>
21235 #include <signal.h>
21236 #include <stddef.h>
21237 int main ()
21239 sigset_t set;
21240 sigemptyset (&set);
21241 return pthread_sigmask (1729, &set, NULL) != 0;
21243 _ACEOF
21244 if ac_fn_c_try_run "$LINENO"; then :
21245 gl_cv_func_pthread_sigmask_in_libc_works=no
21246 else
21247 gl_cv_func_pthread_sigmask_in_libc_works=yes
21249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21250 conftest.$ac_objext conftest.beam conftest.$ac_ext
21255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
21256 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
21257 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
21258 *no)
21259 REPLACE_PTHREAD_SIGMASK=1
21261 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
21264 esac
21267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
21268 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
21269 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
21270 $as_echo_n "(cached) " >&6
21271 else
21273 gl_save_LIBS="$LIBS"
21274 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
21275 if test "$cross_compiling" = yes; then :
21276 case "$host_os" in
21277 cygwin*)
21278 gl_cv_func_pthread_sigmask_return_works="guessing no";;
21280 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
21281 esac
21283 else
21284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21285 /* end confdefs.h. */
21287 #include <pthread.h>
21288 #include <signal.h>
21289 #include <stddef.h>
21290 int main ()
21292 sigset_t set;
21293 sigemptyset (&set);
21294 if (pthread_sigmask (1729, &set, NULL) == -1)
21295 return 1;
21296 return 0;
21298 _ACEOF
21299 if ac_fn_c_try_run "$LINENO"; then :
21300 gl_cv_func_pthread_sigmask_return_works=yes
21301 else
21302 gl_cv_func_pthread_sigmask_return_works=no
21304 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21305 conftest.$ac_objext conftest.beam conftest.$ac_ext
21308 LIBS="$gl_save_LIBS"
21311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
21312 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
21313 case "$gl_cv_func_pthread_sigmask_return_works" in
21314 *no)
21315 REPLACE_PTHREAD_SIGMASK=1
21317 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
21320 esac
21322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
21323 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
21324 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
21325 $as_echo_n "(cached) " >&6
21326 else
21328 case "$host_os" in
21329 irix*)
21330 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
21332 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
21333 esac
21334 gl_save_LIBS="$LIBS"
21335 LIBS="$LIBS $LIBMULTITHREAD"
21336 if test "$cross_compiling" = yes; then :
21338 else
21339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21340 /* end confdefs.h. */
21342 #include <pthread.h>
21343 #include <signal.h>
21344 #include <stdio.h>
21345 #include <stdlib.h>
21346 #include <unistd.h>
21347 static volatile int sigint_occurred;
21348 static void
21349 sigint_handler (int sig)
21351 sigint_occurred++;
21353 int main ()
21355 sigset_t set;
21356 int pid = getpid ();
21357 char command[80];
21358 signal (SIGINT, sigint_handler);
21359 sigemptyset (&set);
21360 sigaddset (&set, SIGINT);
21361 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
21362 return 1;
21363 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
21364 if (!(system (command) == 0))
21365 return 2;
21366 sleep (2);
21367 if (!(sigint_occurred == 0))
21368 return 3;
21369 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
21370 return 4;
21371 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
21372 return 5;
21373 return 0;
21375 _ACEOF
21376 if ac_fn_c_try_run "$LINENO"; then :
21378 else
21379 gl_cv_func_pthread_sigmask_unblock_works=no
21381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21382 conftest.$ac_objext conftest.beam conftest.$ac_ext
21385 LIBS="$gl_save_LIBS"
21388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
21389 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
21390 case "$gl_cv_func_pthread_sigmask_unblock_works" in
21391 *no)
21392 REPLACE_PTHREAD_SIGMASK=1
21394 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
21397 esac
21400 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
21409 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
21412 if test $HAVE_PTHREAD_SIGMASK = 1; then
21414 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
21424 GNULIB_PTHREAD_SIGMASK=1
21433 if test $ac_cv_func_readlink = no; then
21434 HAVE_READLINK=0
21435 else
21436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
21437 $as_echo_n "checking whether readlink signature is correct... " >&6; }
21438 if test "${gl_cv_decl_readlink_works+set}" = set; then :
21439 $as_echo_n "(cached) " >&6
21440 else
21441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21442 /* end confdefs.h. */
21443 #include <unistd.h>
21444 /* Cause compilation failure if original declaration has wrong type. */
21445 ssize_t readlink (const char *, char *, size_t);
21447 main ()
21451 return 0;
21453 _ACEOF
21454 if ac_fn_c_try_compile "$LINENO"; then :
21455 gl_cv_decl_readlink_works=yes
21456 else
21457 gl_cv_decl_readlink_works=no
21459 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
21462 $as_echo "$gl_cv_decl_readlink_works" >&6; }
21463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
21464 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
21465 if test "${gl_cv_func_readlink_works+set}" = set; then :
21466 $as_echo_n "(cached) " >&6
21467 else
21468 # We have readlink, so assume ln -s works.
21469 ln -s conftest.no-such conftest.link
21470 ln -s conftest.link conftest.lnk2
21471 if test "$cross_compiling" = yes; then :
21472 case "$host_os" in
21473 # Guess yes on glibc systems.
21474 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
21475 # If we don't know, assume the worst.
21476 *) gl_cv_func_readlink_works="guessing no" ;;
21477 esac
21479 else
21480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21481 /* end confdefs.h. */
21482 #include <unistd.h>
21485 main ()
21487 char buf[20];
21488 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
21490 return 0;
21492 _ACEOF
21493 if ac_fn_c_try_run "$LINENO"; then :
21494 gl_cv_func_readlink_works=yes
21495 else
21496 gl_cv_func_readlink_works=no
21498 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21499 conftest.$ac_objext conftest.beam conftest.$ac_ext
21502 rm -f conftest.link conftest.lnk2
21504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
21505 $as_echo "$gl_cv_func_readlink_works" >&6; }
21506 case "$gl_cv_func_readlink_works" in
21507 *yes)
21508 if test "$gl_cv_decl_readlink_works" != yes; then
21509 REPLACE_READLINK=1
21514 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
21516 REPLACE_READLINK=1
21518 esac
21521 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
21530 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
21541 GNULIB_READLINK=1
21558 if test $gl_cv_have_include_next = yes; then
21559 gl_cv_next_signal_h='<'signal.h'>'
21560 else
21561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
21562 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
21563 if test "${gl_cv_next_signal_h+set}" = set; then :
21564 $as_echo_n "(cached) " >&6
21565 else
21567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21568 /* end confdefs.h. */
21569 #include <signal.h>
21571 _ACEOF
21572 case "$host_os" in
21573 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21574 *) gl_absname_cpp="$ac_cpp" ;;
21575 esac
21577 case "$host_os" in
21578 mingw*)
21579 gl_dirsep_regex='[/\\]'
21582 gl_dirsep_regex='\/'
21584 esac
21585 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21587 gl_header_literal_regex=`echo 'signal.h' \
21588 | sed -e "$gl_make_literal_regex_sed"`
21589 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21590 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21591 s|^/[^/]|//&|
21595 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21596 sed -n "$gl_absolute_header_sed"`'"'
21600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
21601 $as_echo "$gl_cv_next_signal_h" >&6; }
21603 NEXT_SIGNAL_H=$gl_cv_next_signal_h
21605 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21606 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21607 gl_next_as_first_directive='<'signal.h'>'
21608 else
21609 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21610 gl_next_as_first_directive=$gl_cv_next_signal_h
21612 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
21618 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
21619 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
21620 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
21621 #include <signal.h>
21624 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
21626 else
21627 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
21636 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
21637 #include <signal.h>
21640 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
21642 else
21643 HAVE_SIGHANDLER_T=0
21649 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
21650 /* <sys/types.h> is not needed according to POSIX, but the
21651 <sys/socket.h> in i386-unknown-freebsd4.10 and
21652 powerpc-apple-darwin5.5 required it. */
21653 #include <sys/types.h>
21654 #if HAVE_SYS_SOCKET_H
21655 # include <sys/socket.h>
21656 #elif HAVE_WS2TCPIP_H
21657 # include <ws2tcpip.h>
21658 #endif
21661 if test "x$ac_cv_type_socklen_t" = x""yes; then :
21663 else
21664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
21665 $as_echo_n "checking for socklen_t equivalent... " >&6; }
21666 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
21667 $as_echo_n "(cached) " >&6
21668 else
21669 # Systems have either "struct sockaddr *" or
21670 # "void *" as the second argument to getpeername
21671 gl_cv_socklen_t_equiv=
21672 for arg2 in "struct sockaddr" void; do
21673 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
21674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21675 /* end confdefs.h. */
21676 #include <sys/types.h>
21677 #include <sys/socket.h>
21679 int getpeername (int, $arg2 *, $t *);
21681 main ()
21683 $t len;
21684 getpeername (0, 0, &len);
21686 return 0;
21688 _ACEOF
21689 if ac_fn_c_try_compile "$LINENO"; then :
21690 gl_cv_socklen_t_equiv="$t"
21692 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21693 test "$gl_cv_socklen_t_equiv" != "" && break
21694 done
21695 test "$gl_cv_socklen_t_equiv" != "" && break
21696 done
21700 if test "$gl_cv_socklen_t_equiv" = ""; then
21701 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
21703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
21704 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
21706 cat >>confdefs.h <<_ACEOF
21707 #define socklen_t $gl_cv_socklen_t_equiv
21708 _ACEOF
21713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
21714 $as_echo_n "checking for ssize_t... " >&6; }
21715 if test "${gt_cv_ssize_t+set}" = set; then :
21716 $as_echo_n "(cached) " >&6
21717 else
21718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21719 /* end confdefs.h. */
21720 #include <sys/types.h>
21722 main ()
21724 int x = sizeof (ssize_t *) + sizeof (ssize_t);
21725 return !x;
21727 return 0;
21729 _ACEOF
21730 if ac_fn_c_try_compile "$LINENO"; then :
21731 gt_cv_ssize_t=yes
21732 else
21733 gt_cv_ssize_t=no
21735 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
21738 $as_echo "$gt_cv_ssize_t" >&6; }
21739 if test $gt_cv_ssize_t = no; then
21741 $as_echo "#define ssize_t int" >>confdefs.h
21750 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>
21751 #include <sys/stat.h>
21753 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
21755 cat >>confdefs.h <<_ACEOF
21756 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
21757 _ACEOF
21759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
21760 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
21761 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
21762 $as_echo_n "(cached) " >&6
21763 else
21764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21765 /* end confdefs.h. */
21767 #include <sys/types.h>
21768 #include <sys/stat.h>
21769 #if HAVE_SYS_TIME_H
21770 # include <sys/time.h>
21771 #endif
21772 #include <time.h>
21773 struct timespec ts;
21774 struct stat st;
21777 main ()
21780 st.st_atim = ts;
21783 return 0;
21785 _ACEOF
21786 if ac_fn_c_try_compile "$LINENO"; then :
21787 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
21788 else
21789 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
21791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
21794 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
21795 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
21797 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
21800 else
21801 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>
21802 #include <sys/stat.h>
21804 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
21806 cat >>confdefs.h <<_ACEOF
21807 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
21808 _ACEOF
21811 else
21812 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
21813 #include <sys/stat.h>
21815 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
21817 cat >>confdefs.h <<_ACEOF
21818 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
21819 _ACEOF
21822 else
21823 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>
21824 #include <sys/stat.h>
21826 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
21828 cat >>confdefs.h <<_ACEOF
21829 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
21830 _ACEOF
21846 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>
21847 #include <sys/stat.h>
21849 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
21851 cat >>confdefs.h <<_ACEOF
21852 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
21853 _ACEOF
21856 else
21857 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
21858 #include <sys/stat.h>
21860 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
21862 cat >>confdefs.h <<_ACEOF
21863 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
21864 _ACEOF
21867 else
21868 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>
21869 #include <sys/stat.h>
21871 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
21873 cat >>confdefs.h <<_ACEOF
21874 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
21875 _ACEOF
21886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
21887 $as_echo_n "checking for working stdalign.h... " >&6; }
21888 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
21889 $as_echo_n "(cached) " >&6
21890 else
21891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21892 /* end confdefs.h. */
21893 #include <stdalign.h>
21894 #include <stddef.h>
21896 /* Test that alignof yields a result consistent with offsetof.
21897 This catches GCC bug 52023
21898 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
21899 #ifdef __cplusplus
21900 template <class t> struct alignof_helper { char a; t b; };
21901 # define ao(type) offsetof (alignof_helper<type>, b)
21902 #else
21903 # define ao(type) offsetof (struct { char a; type b; }, b)
21904 #endif
21905 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
21906 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
21907 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
21909 /* Test _Alignas only on platforms where gnulib can help. */
21910 #if \
21911 (__GNUC__ || __IBMC__ || __IBMCPP__ \
21912 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
21913 int alignas (8) alignas_int = 1;
21914 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
21915 #endif
21918 main ()
21922 return 0;
21924 _ACEOF
21925 if ac_fn_c_try_compile "$LINENO"; then :
21926 gl_cv_header_working_stdalign_h=yes
21927 else
21928 gl_cv_header_working_stdalign_h=no
21930 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
21933 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
21935 if test $gl_cv_header_working_stdalign_h = yes; then
21936 STDALIGN_H=''
21937 else
21938 STDALIGN_H='stdalign.h'
21942 if test -n "$STDALIGN_H"; then
21943 GL_GENERATE_STDALIGN_H_TRUE=
21944 GL_GENERATE_STDALIGN_H_FALSE='#'
21945 else
21946 GL_GENERATE_STDALIGN_H_TRUE='#'
21947 GL_GENERATE_STDALIGN_H_FALSE=
21952 STDARG_H=''
21953 NEXT_STDARG_H='<stdarg.h>'
21954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
21955 $as_echo_n "checking for va_copy... " >&6; }
21956 if test "${gl_cv_func_va_copy+set}" = set; then :
21957 $as_echo_n "(cached) " >&6
21958 else
21960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21961 /* end confdefs.h. */
21962 #include <stdarg.h>
21964 main ()
21967 #ifndef va_copy
21968 void (*func) (va_list, va_list) = va_copy;
21969 #endif
21972 return 0;
21974 _ACEOF
21975 if ac_fn_c_try_compile "$LINENO"; then :
21976 gl_cv_func_va_copy=yes
21977 else
21978 gl_cv_func_va_copy=no
21980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
21984 $as_echo "$gl_cv_func_va_copy" >&6; }
21985 if test $gl_cv_func_va_copy = no; then
21986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21987 /* end confdefs.h. */
21988 #if defined _AIX && !defined __GNUC__
21989 AIX vaccine
21990 #endif
21992 _ACEOF
21993 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21994 $EGREP "vaccine" >/dev/null 2>&1; then :
21995 gl_aixcc=yes
21996 else
21997 gl_aixcc=no
21999 rm -f conftest*
22001 if test $gl_aixcc = yes; then
22002 STDARG_H=stdarg.h
22011 if test $gl_cv_have_include_next = yes; then
22012 gl_cv_next_stdarg_h='<'stdarg.h'>'
22013 else
22014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22015 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22016 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22017 $as_echo_n "(cached) " >&6
22018 else
22020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22021 /* end confdefs.h. */
22022 #include <stdarg.h>
22024 _ACEOF
22025 case "$host_os" in
22026 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22027 *) gl_absname_cpp="$ac_cpp" ;;
22028 esac
22030 case "$host_os" in
22031 mingw*)
22032 gl_dirsep_regex='[/\\]'
22035 gl_dirsep_regex='\/'
22037 esac
22038 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22040 gl_header_literal_regex=`echo 'stdarg.h' \
22041 | sed -e "$gl_make_literal_regex_sed"`
22042 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22043 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22044 s|^/[^/]|//&|
22048 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22049 sed -n "$gl_absolute_header_sed"`'"'
22053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22054 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22056 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22058 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22059 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22060 gl_next_as_first_directive='<'stdarg.h'>'
22061 else
22062 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22063 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22065 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22070 if test "$gl_cv_next_stdarg_h" = '""'; then
22071 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22072 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22074 else
22076 saved_as_echo_n="$as_echo_n"
22077 as_echo_n=':'
22078 if test "${gl_cv_func___va_copy+set}" = set; then :
22079 $as_echo_n "(cached) " >&6
22080 else
22082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22083 /* end confdefs.h. */
22084 #include <stdarg.h>
22086 main ()
22089 #ifndef __va_copy
22090 error, bail out
22091 #endif
22094 return 0;
22096 _ACEOF
22097 if ac_fn_c_try_compile "$LINENO"; then :
22098 gl_cv_func___va_copy=yes
22099 else
22100 gl_cv_func___va_copy=no
22102 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22105 as_echo_n="$saved_as_echo_n"
22107 if test $gl_cv_func___va_copy = yes; then
22109 $as_echo "#define va_copy __va_copy" >>confdefs.h
22111 else
22114 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22120 if test -n "$STDARG_H"; then
22121 GL_GENERATE_STDARG_H_TRUE=
22122 GL_GENERATE_STDARG_H_FALSE='#'
22123 else
22124 GL_GENERATE_STDARG_H_TRUE='#'
22125 GL_GENERATE_STDARG_H_FALSE=
22133 # Define two additional variables used in the Makefile substitution.
22135 if test "$ac_cv_header_stdbool_h" = yes; then
22136 STDBOOL_H=''
22137 else
22138 STDBOOL_H='stdbool.h'
22141 if test -n "$STDBOOL_H"; then
22142 GL_GENERATE_STDBOOL_H_TRUE=
22143 GL_GENERATE_STDBOOL_H_FALSE='#'
22144 else
22145 GL_GENERATE_STDBOOL_H_TRUE='#'
22146 GL_GENERATE_STDBOOL_H_FALSE=
22150 if test "$ac_cv_type__Bool" = yes; then
22151 HAVE__BOOL=1
22152 else
22153 HAVE__BOOL=0
22160 STDDEF_H=
22161 if test $gt_cv_c_wchar_t = no; then
22162 HAVE_WCHAR_T=0
22163 STDDEF_H=stddef.h
22165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22166 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22167 if test "${gl_cv_decl_null_works+set}" = set; then :
22168 $as_echo_n "(cached) " >&6
22169 else
22170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22171 /* end confdefs.h. */
22172 #include <stddef.h>
22173 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22176 main ()
22180 return 0;
22182 _ACEOF
22183 if ac_fn_c_try_compile "$LINENO"; then :
22184 gl_cv_decl_null_works=yes
22185 else
22186 gl_cv_decl_null_works=no
22188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22191 $as_echo "$gl_cv_decl_null_works" >&6; }
22192 if test $gl_cv_decl_null_works = no; then
22193 REPLACE_NULL=1
22194 STDDEF_H=stddef.h
22197 if test -n "$STDDEF_H"; then
22198 GL_GENERATE_STDDEF_H_TRUE=
22199 GL_GENERATE_STDDEF_H_FALSE='#'
22200 else
22201 GL_GENERATE_STDDEF_H_TRUE='#'
22202 GL_GENERATE_STDDEF_H_FALSE=
22205 if test -n "$STDDEF_H"; then
22214 if test $gl_cv_have_include_next = yes; then
22215 gl_cv_next_stddef_h='<'stddef.h'>'
22216 else
22217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22218 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22219 if test "${gl_cv_next_stddef_h+set}" = set; then :
22220 $as_echo_n "(cached) " >&6
22221 else
22223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22224 /* end confdefs.h. */
22225 #include <stddef.h>
22227 _ACEOF
22228 case "$host_os" in
22229 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22230 *) gl_absname_cpp="$ac_cpp" ;;
22231 esac
22233 case "$host_os" in
22234 mingw*)
22235 gl_dirsep_regex='[/\\]'
22238 gl_dirsep_regex='\/'
22240 esac
22241 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22243 gl_header_literal_regex=`echo 'stddef.h' \
22244 | sed -e "$gl_make_literal_regex_sed"`
22245 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22246 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22247 s|^/[^/]|//&|
22251 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22252 sed -n "$gl_absolute_header_sed"`'"'
22256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
22257 $as_echo "$gl_cv_next_stddef_h" >&6; }
22259 NEXT_STDDEF_H=$gl_cv_next_stddef_h
22261 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22262 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22263 gl_next_as_first_directive='<'stddef.h'>'
22264 else
22265 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22266 gl_next_as_first_directive=$gl_cv_next_stddef_h
22268 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
22287 if test $gl_cv_have_include_next = yes; then
22288 gl_cv_next_stdio_h='<'stdio.h'>'
22289 else
22290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
22291 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
22292 if test "${gl_cv_next_stdio_h+set}" = set; then :
22293 $as_echo_n "(cached) " >&6
22294 else
22296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22297 /* end confdefs.h. */
22298 #include <stdio.h>
22300 _ACEOF
22301 case "$host_os" in
22302 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22303 *) gl_absname_cpp="$ac_cpp" ;;
22304 esac
22306 case "$host_os" in
22307 mingw*)
22308 gl_dirsep_regex='[/\\]'
22311 gl_dirsep_regex='\/'
22313 esac
22314 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22316 gl_header_literal_regex=`echo 'stdio.h' \
22317 | sed -e "$gl_make_literal_regex_sed"`
22318 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22319 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22320 s|^/[^/]|//&|
22324 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22325 sed -n "$gl_absolute_header_sed"`'"'
22329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
22330 $as_echo "$gl_cv_next_stdio_h" >&6; }
22332 NEXT_STDIO_H=$gl_cv_next_stdio_h
22334 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22335 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22336 gl_next_as_first_directive='<'stdio.h'>'
22337 else
22338 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22339 gl_next_as_first_directive=$gl_cv_next_stdio_h
22341 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
22347 GNULIB_FSCANF=1
22350 cat >>confdefs.h <<_ACEOF
22351 #define GNULIB_FSCANF 1
22352 _ACEOF
22355 GNULIB_SCANF=1
22358 cat >>confdefs.h <<_ACEOF
22359 #define GNULIB_SCANF 1
22360 _ACEOF
22363 GNULIB_FGETC=1
22364 GNULIB_GETC=1
22365 GNULIB_GETCHAR=1
22366 GNULIB_FGETS=1
22367 GNULIB_FREAD=1
22370 GNULIB_FPRINTF=1
22371 GNULIB_PRINTF=1
22372 GNULIB_VFPRINTF=1
22373 GNULIB_VPRINTF=1
22374 GNULIB_FPUTC=1
22375 GNULIB_PUTC=1
22376 GNULIB_PUTCHAR=1
22377 GNULIB_FPUTS=1
22378 GNULIB_PUTS=1
22379 GNULIB_FWRITE=1
22395 if test $gl_cv_have_include_next = yes; then
22396 gl_cv_next_stdlib_h='<'stdlib.h'>'
22397 else
22398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
22399 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
22400 if test "${gl_cv_next_stdlib_h+set}" = set; then :
22401 $as_echo_n "(cached) " >&6
22402 else
22404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22405 /* end confdefs.h. */
22406 #include <stdlib.h>
22408 _ACEOF
22409 case "$host_os" in
22410 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22411 *) gl_absname_cpp="$ac_cpp" ;;
22412 esac
22414 case "$host_os" in
22415 mingw*)
22416 gl_dirsep_regex='[/\\]'
22419 gl_dirsep_regex='\/'
22421 esac
22422 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22424 gl_header_literal_regex=`echo 'stdlib.h' \
22425 | sed -e "$gl_make_literal_regex_sed"`
22426 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22427 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22428 s|^/[^/]|//&|
22432 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22433 sed -n "$gl_absolute_header_sed"`'"'
22437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
22438 $as_echo "$gl_cv_next_stdlib_h" >&6; }
22440 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
22442 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22443 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22444 gl_next_as_first_directive='<'stdlib.h'>'
22445 else
22446 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22447 gl_next_as_first_directive=$gl_cv_next_stdlib_h
22449 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
22459 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
22467 $as_echo "#define my_strftime nstrftime" >>confdefs.h
22476 if test "$ac_cv_have_decl_strtoimax" != yes; then
22477 HAVE_DECL_STRTOIMAX=0
22480 if test $ac_cv_func_strtoimax = yes; then
22481 HAVE_STRTOIMAX=1
22482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
22483 $as_echo_n "checking whether strtoimax works... " >&6; }
22484 if test "${gl_cv_func_strtoimax+set}" = set; then :
22485 $as_echo_n "(cached) " >&6
22486 else
22487 if test "$cross_compiling" = yes; then :
22488 case "$host_os" in
22489 # Guess no on AIX 5.
22490 aix5*) gl_cv_func_strtoimax="guessing no" ;;
22491 # Guess yes otherwise.
22492 *) gl_cv_func_strtoimax="guessing yes" ;;
22493 esac
22495 else
22496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22497 /* end confdefs.h. */
22499 #include <errno.h>
22500 #include <string.h>
22501 #include <inttypes.h>
22502 int main ()
22504 if (sizeof (intmax_t) > sizeof (int))
22506 const char *s = "4294967295";
22507 char *p;
22508 intmax_t res;
22509 errno = 0;
22510 res = strtoimax (s, &p, 10);
22511 if (p != s + strlen (s))
22512 return 1;
22513 if (errno != 0)
22514 return 2;
22515 if (res != (intmax_t) 65535 * (intmax_t) 65537)
22516 return 3;
22518 else
22520 const char *s = "2147483647";
22521 char *p;
22522 intmax_t res;
22523 errno = 0;
22524 res = strtoimax (s, &p, 10);
22525 if (p != s + strlen (s))
22526 return 1;
22527 if (errno != 0)
22528 return 2;
22529 if (res != 2147483647)
22530 return 3;
22532 return 0;
22535 _ACEOF
22536 if ac_fn_c_try_run "$LINENO"; then :
22537 gl_cv_func_strtoimax=yes
22538 else
22539 gl_cv_func_strtoimax=no
22541 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22542 conftest.$ac_objext conftest.beam conftest.$ac_ext
22547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
22548 $as_echo "$gl_cv_func_strtoimax" >&6; }
22549 case "$gl_cv_func_strtoimax" in
22550 *no) REPLACE_STRTOIMAX=1 ;;
22551 esac
22552 else
22553 HAVE_STRTOIMAX=0
22556 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
22565 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
22568 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
22569 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
22570 ac_have_decl=1
22571 else
22572 ac_have_decl=0
22575 cat >>confdefs.h <<_ACEOF
22576 #define HAVE_DECL_STRTOLL $ac_have_decl
22577 _ACEOF
22587 GNULIB_STRTOIMAX=1
22597 if test "$ac_cv_have_decl_strtoumax" != yes; then
22598 HAVE_DECL_STRTOUMAX=0
22601 if test $ac_cv_func_strtoumax = no; then
22610 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
22613 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
22614 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
22615 ac_have_decl=1
22616 else
22617 ac_have_decl=0
22620 cat >>confdefs.h <<_ACEOF
22621 #define HAVE_DECL_STRTOULL $ac_have_decl
22622 _ACEOF
22632 GNULIB_STRTOUMAX=1
22640 if test $ac_cv_func_symlink = no; then
22641 HAVE_SYMLINK=0
22642 else
22643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
22644 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
22645 if test "${gl_cv_func_symlink_works+set}" = set; then :
22646 $as_echo_n "(cached) " >&6
22647 else
22648 if test "$cross_compiling" = yes; then :
22649 case "$host_os" in
22650 # Guess yes on glibc systems.
22651 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
22652 # If we don't know, assume the worst.
22653 *) gl_cv_func_symlink_works="guessing no" ;;
22654 esac
22656 else
22657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22658 /* end confdefs.h. */
22659 #include <unistd.h>
22662 main ()
22664 int result = 0;
22665 if (!symlink ("a", "conftest.link/"))
22666 result |= 1;
22667 if (symlink ("conftest.f", "conftest.lnk2"))
22668 result |= 2;
22669 else if (!symlink ("a", "conftest.lnk2/"))
22670 result |= 4;
22671 return result;
22674 return 0;
22676 _ACEOF
22677 if ac_fn_c_try_run "$LINENO"; then :
22678 gl_cv_func_symlink_works=yes
22679 else
22680 gl_cv_func_symlink_works=no
22682 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22683 conftest.$ac_objext conftest.beam conftest.$ac_ext
22686 rm -f conftest.f conftest.link conftest.lnk2
22688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
22689 $as_echo "$gl_cv_func_symlink_works" >&6; }
22690 case "$gl_cv_func_symlink_works" in
22691 *yes) ;;
22693 REPLACE_SYMLINK=1
22695 esac
22698 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
22707 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
22715 GNULIB_SYMLINK=1
22724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
22725 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
22726 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
22727 $as_echo_n "(cached) " >&6
22728 else
22730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22731 /* end confdefs.h. */
22732 #include <sys/select.h>
22734 main ()
22736 struct timeval b;
22738 return 0;
22740 _ACEOF
22741 if ac_fn_c_try_compile "$LINENO"; then :
22742 gl_cv_header_sys_select_h_selfcontained=yes
22743 else
22744 gl_cv_header_sys_select_h_selfcontained=no
22746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22747 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
22748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22749 /* end confdefs.h. */
22750 #include <sys/select.h>
22752 main ()
22754 int memset; int bzero;
22756 return 0;
22759 _ACEOF
22760 if ac_fn_c_try_compile "$LINENO"; then :
22761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22762 /* end confdefs.h. */
22763 #include <sys/select.h>
22765 main ()
22768 #undef memset
22769 #define memset nonexistent_memset
22770 extern
22771 #ifdef __cplusplus
22773 #endif
22774 void *memset (void *, int, unsigned long);
22775 #undef bzero
22776 #define bzero nonexistent_bzero
22777 extern
22778 #ifdef __cplusplus
22780 #endif
22781 void bzero (void *, unsigned long);
22782 fd_set fds;
22783 FD_ZERO (&fds);
22786 return 0;
22789 _ACEOF
22790 if ac_fn_c_try_link "$LINENO"; then :
22792 else
22793 gl_cv_header_sys_select_h_selfcontained=no
22795 rm -f core conftest.err conftest.$ac_objext \
22796 conftest$ac_exeext conftest.$ac_ext
22799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
22804 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
22814 if test $gl_cv_have_include_next = yes; then
22815 gl_cv_next_sys_select_h='<'sys/select.h'>'
22816 else
22817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
22818 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
22819 if test "${gl_cv_next_sys_select_h+set}" = set; then :
22820 $as_echo_n "(cached) " >&6
22821 else
22823 if test $ac_cv_header_sys_select_h = yes; then
22826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22827 /* end confdefs.h. */
22828 #include <sys/select.h>
22830 _ACEOF
22831 case "$host_os" in
22832 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22833 *) gl_absname_cpp="$ac_cpp" ;;
22834 esac
22836 case "$host_os" in
22837 mingw*)
22838 gl_dirsep_regex='[/\\]'
22841 gl_dirsep_regex='\/'
22843 esac
22844 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22846 gl_header_literal_regex=`echo 'sys/select.h' \
22847 | sed -e "$gl_make_literal_regex_sed"`
22848 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22849 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22850 s|^/[^/]|//&|
22854 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22855 sed -n "$gl_absolute_header_sed"`'"'
22856 else
22857 gl_cv_next_sys_select_h='<'sys/select.h'>'
22862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
22863 $as_echo "$gl_cv_next_sys_select_h" >&6; }
22865 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
22867 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22868 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22869 gl_next_as_first_directive='<'sys/select.h'>'
22870 else
22871 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22872 gl_next_as_first_directive=$gl_cv_next_sys_select_h
22874 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
22879 if test $ac_cv_header_sys_select_h = yes; then
22880 HAVE_SYS_SELECT_H=1
22881 else
22882 HAVE_SYS_SELECT_H=0
22889 if test $ac_cv_header_sys_socket_h != yes; then
22890 for ac_header in winsock2.h
22891 do :
22892 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
22893 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
22894 cat >>confdefs.h <<_ACEOF
22895 #define HAVE_WINSOCK2_H 1
22896 _ACEOF
22900 done
22903 if test "$ac_cv_header_winsock2_h" = yes; then
22904 HAVE_WINSOCK2_H=1
22905 UNISTD_H_HAVE_WINSOCK2_H=1
22906 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
22907 else
22908 HAVE_WINSOCK2_H=0
22932 if test $gl_cv_have_include_next = yes; then
22933 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
22934 else
22935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
22936 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
22937 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
22938 $as_echo_n "(cached) " >&6
22939 else
22941 if test $ac_cv_header_sys_stat_h = yes; then
22944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22945 /* end confdefs.h. */
22946 #include <sys/stat.h>
22948 _ACEOF
22949 case "$host_os" in
22950 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22951 *) gl_absname_cpp="$ac_cpp" ;;
22952 esac
22954 case "$host_os" in
22955 mingw*)
22956 gl_dirsep_regex='[/\\]'
22959 gl_dirsep_regex='\/'
22961 esac
22962 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22964 gl_header_literal_regex=`echo 'sys/stat.h' \
22965 | sed -e "$gl_make_literal_regex_sed"`
22966 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22967 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22968 s|^/[^/]|//&|
22972 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22973 sed -n "$gl_absolute_header_sed"`'"'
22974 else
22975 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
22980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
22981 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
22983 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
22985 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22986 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22987 gl_next_as_first_directive='<'sys/stat.h'>'
22988 else
22989 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22990 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
22992 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23004 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23006 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23010 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23011 #include <sys/stat.h>
23013 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23015 else
23017 $as_echo "#define nlink_t int" >>confdefs.h
23038 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23040 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23041 ac_have_decl=1
23042 else
23043 ac_have_decl=0
23046 cat >>confdefs.h <<_ACEOF
23047 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23048 _ACEOF
23050 if test $ac_cv_have_decl_localtime_r = no; then
23051 HAVE_DECL_LOCALTIME_R=0
23055 if test $ac_cv_func_localtime_r = yes; then
23056 HAVE_LOCALTIME_R=1
23057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23058 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23059 if test "${gl_cv_time_r_posix+set}" = set; then :
23060 $as_echo_n "(cached) " >&6
23061 else
23062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23063 /* end confdefs.h. */
23064 #include <time.h>
23066 main ()
23068 /* We don't need to append 'restrict's to the argument types,
23069 even though the POSIX signature has the 'restrict's,
23070 since C99 says they can't affect type compatibility. */
23071 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23072 if (ptr) return 0;
23073 /* Check the return type is a pointer.
23074 On HP-UX 10 it is 'int'. */
23075 *localtime_r (0, 0);
23077 return 0;
23080 _ACEOF
23081 if ac_fn_c_try_compile "$LINENO"; then :
23082 gl_cv_time_r_posix=yes
23083 else
23084 gl_cv_time_r_posix=no
23086 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23090 $as_echo "$gl_cv_time_r_posix" >&6; }
23091 if test $gl_cv_time_r_posix = yes; then
23092 REPLACE_LOCALTIME_R=0
23093 else
23094 REPLACE_LOCALTIME_R=1
23096 else
23097 HAVE_LOCALTIME_R=0
23100 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23109 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23120 GNULIB_TIME_R=1
23143 if test $gl_cv_have_include_next = yes; then
23144 gl_cv_next_unistd_h='<'unistd.h'>'
23145 else
23146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23147 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23148 if test "${gl_cv_next_unistd_h+set}" = set; then :
23149 $as_echo_n "(cached) " >&6
23150 else
23152 if test $ac_cv_header_unistd_h = yes; then
23155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23156 /* end confdefs.h. */
23157 #include <unistd.h>
23159 _ACEOF
23160 case "$host_os" in
23161 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23162 *) gl_absname_cpp="$ac_cpp" ;;
23163 esac
23165 case "$host_os" in
23166 mingw*)
23167 gl_dirsep_regex='[/\\]'
23170 gl_dirsep_regex='\/'
23172 esac
23173 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23175 gl_header_literal_regex=`echo 'unistd.h' \
23176 | sed -e "$gl_make_literal_regex_sed"`
23177 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23178 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23179 s|^/[^/]|//&|
23183 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23184 sed -n "$gl_absolute_header_sed"`'"'
23185 else
23186 gl_cv_next_unistd_h='<'unistd.h'>'
23191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
23192 $as_echo "$gl_cv_next_unistd_h" >&6; }
23194 NEXT_UNISTD_H=$gl_cv_next_unistd_h
23196 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23197 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23198 gl_next_as_first_directive='<'unistd.h'>'
23199 else
23200 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23201 gl_next_as_first_directive=$gl_cv_next_unistd_h
23203 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
23208 if test $ac_cv_header_unistd_h = yes; then
23209 HAVE_UNISTD_H=1
23210 else
23211 HAVE_UNISTD_H=0
23227 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
23228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
23229 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
23230 if test "${gl_cv_func_futimesat_works+set}" = set; then :
23231 $as_echo_n "(cached) " >&6
23232 else
23233 touch conftest.file
23234 if test "$cross_compiling" = yes; then :
23235 case "$host_os" in
23236 # Guess yes on glibc systems.
23237 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
23238 # If we don't know, assume the worst.
23239 *) gl_cv_func_futimesat_works="guessing no" ;;
23240 esac
23242 else
23243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23244 /* end confdefs.h. */
23246 #include <stddef.h>
23247 #include <sys/times.h>
23248 #include <fcntl.h>
23251 main ()
23253 int fd = open ("conftest.file", O_RDWR);
23254 if (fd < 0) return 1;
23255 if (futimesat (fd, NULL, NULL)) return 2;
23258 return 0;
23260 _ACEOF
23261 if ac_fn_c_try_run "$LINENO"; then :
23262 gl_cv_func_futimesat_works=yes
23263 else
23264 gl_cv_func_futimesat_works=no
23266 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23267 conftest.$ac_objext conftest.beam conftest.$ac_ext
23270 rm -f conftest.file
23272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
23273 $as_echo "$gl_cv_func_futimesat_works" >&6; }
23274 case "$gl_cv_func_futimesat_works" in
23275 *yes) ;;
23278 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
23281 esac
23284 gl_gnulib_enabled_dosname=false
23285 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
23286 gl_gnulib_enabled_pathmax=false
23287 gl_gnulib_enabled_stat=false
23288 gl_gnulib_enabled_strtoll=false
23289 gl_gnulib_enabled_strtoull=false
23290 gl_gnulib_enabled_verify=false
23291 func_gl_gnulib_m4code_dosname ()
23293 if ! $gl_gnulib_enabled_dosname; then
23294 gl_gnulib_enabled_dosname=true
23297 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
23299 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23302 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
23305 func_gl_gnulib_m4code_pathmax ()
23307 if ! $gl_gnulib_enabled_pathmax; then
23311 gl_gnulib_enabled_pathmax=true
23314 func_gl_gnulib_m4code_stat ()
23316 if ! $gl_gnulib_enabled_stat; then
23320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
23321 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
23322 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
23323 $as_echo_n "(cached) " >&6
23324 else
23325 if test "$cross_compiling" = yes; then :
23326 case $host_os in
23327 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
23328 *) gl_cv_func_stat_dir_slash="guessing yes";;
23329 esac
23330 else
23331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23332 /* end confdefs.h. */
23333 #include <sys/stat.h>
23336 main ()
23338 struct stat st; return stat (".", &st) != stat ("./", &st);
23340 return 0;
23342 _ACEOF
23343 if ac_fn_c_try_run "$LINENO"; then :
23344 gl_cv_func_stat_dir_slash=yes
23345 else
23346 gl_cv_func_stat_dir_slash=no
23348 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23349 conftest.$ac_objext conftest.beam conftest.$ac_ext
23353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
23354 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
23355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
23356 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
23357 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
23358 $as_echo_n "(cached) " >&6
23359 else
23360 touch conftest.tmp
23361 # Assume that if we have lstat, we can also check symlinks.
23362 if test $ac_cv_func_lstat = yes; then
23363 ln -s conftest.tmp conftest.lnk
23365 if test "$cross_compiling" = yes; then :
23366 case "$host_os" in
23367 # Guess yes on glibc systems.
23368 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
23369 # If we don't know, assume the worst.
23370 *) gl_cv_func_stat_file_slash="guessing no" ;;
23371 esac
23373 else
23374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23375 /* end confdefs.h. */
23376 #include <sys/stat.h>
23379 main ()
23381 int result = 0;
23382 struct stat st;
23383 if (!stat ("conftest.tmp/", &st))
23384 result |= 1;
23385 #if HAVE_LSTAT
23386 if (!stat ("conftest.lnk/", &st))
23387 result |= 2;
23388 #endif
23389 return result;
23392 return 0;
23394 _ACEOF
23395 if ac_fn_c_try_run "$LINENO"; then :
23396 gl_cv_func_stat_file_slash=yes
23397 else
23398 gl_cv_func_stat_file_slash=no
23400 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23401 conftest.$ac_objext conftest.beam conftest.$ac_ext
23404 rm -f conftest.tmp conftest.lnk
23406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
23407 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
23408 case $gl_cv_func_stat_dir_slash in
23409 *no) REPLACE_STAT=1
23411 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
23413 esac
23414 case $gl_cv_func_stat_file_slash in
23415 *no) REPLACE_STAT=1
23417 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
23419 esac
23421 if test $REPLACE_STAT = 1; then
23430 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
23442 GNULIB_STAT=1
23448 gl_gnulib_enabled_stat=true
23449 if test $REPLACE_STAT = 1; then
23450 func_gl_gnulib_m4code_dosname
23452 if test $REPLACE_STAT = 1; then
23453 func_gl_gnulib_m4code_pathmax
23455 if test $REPLACE_STAT = 1; then
23456 func_gl_gnulib_m4code_verify
23460 func_gl_gnulib_m4code_strtoll ()
23462 if ! $gl_gnulib_enabled_strtoll; then
23466 if test "$ac_cv_type_long_long_int" = yes; then
23467 for ac_func in strtoll
23468 do :
23469 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
23470 if test "x$ac_cv_func_strtoll" = x""yes; then :
23471 cat >>confdefs.h <<_ACEOF
23472 #define HAVE_STRTOLL 1
23473 _ACEOF
23476 done
23478 if test $ac_cv_func_strtoll = no; then
23479 HAVE_STRTOLL=0
23483 if test $HAVE_STRTOLL = 0; then
23492 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
23503 GNULIB_STRTOLL=1
23509 gl_gnulib_enabled_strtoll=true
23512 func_gl_gnulib_m4code_strtoull ()
23514 if ! $gl_gnulib_enabled_strtoull; then
23518 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
23519 for ac_func in strtoull
23520 do :
23521 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
23522 if test "x$ac_cv_func_strtoull" = x""yes; then :
23523 cat >>confdefs.h <<_ACEOF
23524 #define HAVE_STRTOULL 1
23525 _ACEOF
23528 done
23530 if test $ac_cv_func_strtoull = no; then
23531 HAVE_STRTOULL=0
23535 if test $HAVE_STRTOULL = 0; then
23544 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
23555 GNULIB_STRTOULL=1
23561 gl_gnulib_enabled_strtoull=true
23564 func_gl_gnulib_m4code_verify ()
23566 if ! $gl_gnulib_enabled_verify; then
23567 gl_gnulib_enabled_verify=true
23570 if test $REPLACE_GETOPT = 1; then
23571 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
23573 if test $REPLACE_LSTAT = 1; then
23574 func_gl_gnulib_m4code_dosname
23576 if test $REPLACE_LSTAT = 1; then
23577 func_gl_gnulib_m4code_stat
23579 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
23580 func_gl_gnulib_m4code_stat
23582 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
23583 func_gl_gnulib_m4code_strtoll
23585 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23586 func_gl_gnulib_m4code_verify
23588 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
23589 func_gl_gnulib_m4code_strtoull
23591 if test $ac_cv_func_strtoumax = no; then
23592 func_gl_gnulib_m4code_verify
23595 if $gl_gnulib_enabled_dosname; then
23596 gl_GNULIB_ENABLED_dosname_TRUE=
23597 gl_GNULIB_ENABLED_dosname_FALSE='#'
23598 else
23599 gl_GNULIB_ENABLED_dosname_TRUE='#'
23600 gl_GNULIB_ENABLED_dosname_FALSE=
23603 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23604 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
23605 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
23606 else
23607 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
23608 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
23611 if $gl_gnulib_enabled_pathmax; then
23612 gl_GNULIB_ENABLED_pathmax_TRUE=
23613 gl_GNULIB_ENABLED_pathmax_FALSE='#'
23614 else
23615 gl_GNULIB_ENABLED_pathmax_TRUE='#'
23616 gl_GNULIB_ENABLED_pathmax_FALSE=
23619 if $gl_gnulib_enabled_stat; then
23620 gl_GNULIB_ENABLED_stat_TRUE=
23621 gl_GNULIB_ENABLED_stat_FALSE='#'
23622 else
23623 gl_GNULIB_ENABLED_stat_TRUE='#'
23624 gl_GNULIB_ENABLED_stat_FALSE=
23627 if $gl_gnulib_enabled_strtoll; then
23628 gl_GNULIB_ENABLED_strtoll_TRUE=
23629 gl_GNULIB_ENABLED_strtoll_FALSE='#'
23630 else
23631 gl_GNULIB_ENABLED_strtoll_TRUE='#'
23632 gl_GNULIB_ENABLED_strtoll_FALSE=
23635 if $gl_gnulib_enabled_strtoull; then
23636 gl_GNULIB_ENABLED_strtoull_TRUE=
23637 gl_GNULIB_ENABLED_strtoull_FALSE='#'
23638 else
23639 gl_GNULIB_ENABLED_strtoull_TRUE='#'
23640 gl_GNULIB_ENABLED_strtoull_FALSE=
23643 if $gl_gnulib_enabled_verify; then
23644 gl_GNULIB_ENABLED_verify_TRUE=
23645 gl_GNULIB_ENABLED_verify_FALSE='#'
23646 else
23647 gl_GNULIB_ENABLED_verify_TRUE='#'
23648 gl_GNULIB_ENABLED_verify_FALSE=
23651 # End of code from modules
23661 gltests_libdeps=
23662 gltests_ltlibdeps=
23672 gl_source_base='tests'
23673 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
23675 gl_module_indicator_condition=$gltests_WITNESS
23686 LIBGNU_LIBDEPS="$gl_libdeps"
23688 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
23691 CFLAGS=$SAVE_CFLAGS
23692 LIBS=$SAVE_LIBS
23694 case "$opsys" in
23695 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
23697 darwin)
23698 ## The -headerpad option tells ld (see man page) to leave room at the
23699 ## end of the header for adding load commands. Needed for dumping.
23700 ## 0x690 is the total size of 30 segment load commands (at 56
23701 ## each); under Cocoa 31 commands are required.
23702 if test "$HAVE_NS" = "yes"; then
23703 libs_nsgui="-framework AppKit"
23704 headerpad_extra=6C8
23705 else
23706 libs_nsgui=
23707 headerpad_extra=690
23709 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
23711 ## This is here because src/Makefile.in did some extra fiddling around
23712 ## with LD_SWITCH_SYSTEM. The cpp logic was:
23713 ## #ifndef LD_SWITCH_SYSTEM
23714 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
23715 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
23716 ## not using gcc, darwin.
23717 ## Because this was done in src/Makefile.in, the resulting part of
23718 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
23719 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
23720 ## rather than LD_SWITCH_SYSTEM.
23721 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
23722 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
23725 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
23726 ## find X at run-time.
23727 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
23728 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
23729 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
23730 ## had different values in configure (in ac_link) and src/Makefile.in.
23731 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
23732 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
23734 *) LD_SWITCH_SYSTEM_TEMACS= ;;
23735 esac
23737 if test "$NS_IMPL_GNUSTEP" = "yes"; then
23738 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
23744 LD_FIRSTFLAG=
23745 ORDINARY_LINK=
23746 case "$opsys" in
23747 ## gnu: GNU needs its own crt0.
23748 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
23750 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
23751 ## library search parth, i.e. it won't search /usr/lib for libc and
23752 ## friends. Using -nostartfiles instead avoids this problem, and
23753 ## will also work on earlier NetBSD releases.
23754 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
23756 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
23757 ## MkLinux/LinuxPPC needs this.
23758 ## s390x-* only supports opsys = gnu-linux so it can be added here.
23759 gnu-*)
23760 case "$canonical" in
23761 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
23762 esac
23764 esac
23767 if test "x$ORDINARY_LINK" = "xyes"; then
23769 LD_FIRSTFLAG=""
23771 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
23774 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
23775 ## freebsd, gnu-* not on powerpc*|s390x*.
23776 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
23778 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
23779 ## places that are difficult to figure out at make time. Fortunately,
23780 ## these same versions allow you to pass arbitrary flags on to the
23781 ## linker, so there is no reason not to use it as a linker.
23783 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
23784 ## searching for libraries in its internal directories, so we have to
23785 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
23786 LD_FIRSTFLAG="-nostdlib"
23789 ## FIXME? What setting of EDIT_LDFLAGS should this have?
23790 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
23795 ## FIXME? The logic here is not precisely the same as that above.
23796 ## There is no check here for a pre-defined LD_FIRSTFLAG.
23797 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
23798 LIB_GCC=
23799 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
23801 case "$opsys" in
23802 freebsd|netbsd|openbsd) LIB_GCC= ;;
23804 gnu-*)
23805 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
23806 ## build on ARM EABI under GNU/Linux. (Bug#5518)
23807 case $host_cpu in
23808 arm*)
23809 LIB_GCC="-lgcc_s"
23812 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
23813 ## immediately undefine it again and redefine it to empty.
23814 ## Was the C_SWITCH_X_SITE part really necessary?
23815 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
23816 LIB_GCC=
23818 esac
23821 ## Ask GCC where to find libgcc.a.
23822 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
23823 esac
23827 ## If we're using X11/GNUstep, define some consequences.
23828 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
23830 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
23833 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
23840 #### Report on what we decided to do.
23841 #### Report GTK as a toolkit, even if it doesn't use Xt.
23842 #### It makes printing result more understandable as using GTK sets
23843 #### toolkit_scroll_bars to yes by default.
23844 if test "${HAVE_GTK}" = "yes"; then
23845 if test "${with_gtk3}" = "yes"; then
23846 USE_X_TOOLKIT=GTK3
23847 else
23848 USE_X_TOOLKIT=GTK
23852 echo "
23853 Configured for \`${canonical}'.
23855 Where should the build process find the source code? ${srcdir}
23856 What compiler should emacs be built with? ${CC} ${CFLAGS}
23857 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
23858 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
23859 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
23860 What window system should Emacs use? ${window_system}
23861 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
23863 if test -n "${x_includes}"; then
23864 echo " Where do we find X Windows header files? ${x_includes}"
23865 else
23866 echo " Where do we find X Windows header files? Standard dirs"
23868 if test -n "${x_libraries}"; then
23869 echo " Where do we find X Windows libraries? ${x_libraries}"
23870 else
23871 echo " Where do we find X Windows libraries? Standard dirs"
23874 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
23875 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
23876 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
23877 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
23878 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
23879 echo " Does Emacs use -lpng? ${HAVE_PNG}"
23880 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
23881 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
23883 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
23884 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
23885 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
23886 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
23887 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
23888 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
23889 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
23891 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
23892 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
23893 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
23894 echo " Does Emacs use -lxft? ${HAVE_XFT}"
23896 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
23897 echo
23899 if test -n "${EMACSDATA}"; then
23900 echo " Environment variable EMACSDATA set to: $EMACSDATA"
23902 if test -n "${EMACSDOC}"; then
23903 echo " Environment variable EMACSDOC set to: $EMACSDOC"
23906 echo
23908 if test "$HAVE_NS" = "yes"; then
23909 echo
23910 echo "You must run \"${MAKE-make} install\" in order to test the built application.
23911 The installed application will go to nextstep/Emacs.app and can be
23912 run or moved from there."
23913 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
23914 echo "The application will be fully self-contained."
23915 else
23916 echo "The lisp resources for the application will be installed under ${prefix}.
23917 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
23918 to run if these resources are not installed."
23920 echo
23923 if test "${opsys}" = "cygwin"; then
23924 case `uname -r` in
23925 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
23926 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
23927 echo
23929 esac
23932 # Remove any trailing slashes in these variables.
23933 test "${prefix}" != NONE &&
23934 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
23935 test "${exec_prefix}" != NONE &&
23936 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
23938 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"
23940 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"
23943 opt_makefile=test/automated/Makefile
23945 if test -f $srcdir/${opt_makefile}.in; then
23946 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
23947 ac_config_files="$ac_config_files test/automated/Makefile"
23952 opt_makefile=admin/unidata/Makefile
23954 if test -f $srcdir/${opt_makefile}.in; then
23955 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
23956 ac_config_files="$ac_config_files admin/unidata/Makefile"
23961 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
23965 ac_config_commands="$ac_config_commands mkdirs"
23968 ac_config_commands="$ac_config_commands epaths"
23971 ac_config_commands="$ac_config_commands gdbinit"
23974 cat >confcache <<\_ACEOF
23975 # This file is a shell script that caches the results of configure
23976 # tests run on this system so they can be shared between configure
23977 # scripts and configure runs, see configure's option --config-cache.
23978 # It is not useful on other systems. If it contains results you don't
23979 # want to keep, you may remove or edit it.
23981 # config.status only pays attention to the cache file if you give it
23982 # the --recheck option to rerun configure.
23984 # `ac_cv_env_foo' variables (set or unset) will be overridden when
23985 # loading this file, other *unset* `ac_cv_foo' will be assigned the
23986 # following values.
23988 _ACEOF
23990 # The following way of writing the cache mishandles newlines in values,
23991 # but we know of no workaround that is simple, portable, and efficient.
23992 # So, we kill variables containing newlines.
23993 # Ultrix sh set writes to stderr and can't be redirected directly,
23994 # and sets the high bit in the cache file unless we assign to the vars.
23996 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
23997 eval ac_val=\$$ac_var
23998 case $ac_val in #(
23999 *${as_nl}*)
24000 case $ac_var in #(
24001 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24002 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24003 esac
24004 case $ac_var in #(
24005 _ | IFS | as_nl) ;; #(
24006 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24007 *) { eval $ac_var=; unset $ac_var;} ;;
24008 esac ;;
24009 esac
24010 done
24012 (set) 2>&1 |
24013 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24014 *${as_nl}ac_space=\ *)
24015 # `set' does not quote correctly, so add quotes: double-quote
24016 # substitution turns \\\\ into \\, and sed turns \\ into \.
24017 sed -n \
24018 "s/'/'\\\\''/g;
24019 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24020 ;; #(
24022 # `set' quotes correctly as required by POSIX, so do not add quotes.
24023 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24025 esac |
24026 sort
24028 sed '
24029 /^ac_cv_env_/b end
24030 t clear
24031 :clear
24032 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24033 t end
24034 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24035 :end' >>confcache
24036 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24037 if test -w "$cache_file"; then
24038 test "x$cache_file" != "x/dev/null" &&
24039 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24040 $as_echo "$as_me: updating cache $cache_file" >&6;}
24041 cat confcache >$cache_file
24042 else
24043 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24044 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24047 rm -f confcache
24049 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24050 # Let make expand exec_prefix.
24051 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24053 DEFS=-DHAVE_CONFIG_H
24055 ac_libobjs=
24056 ac_ltlibobjs=
24057 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24058 # 1. Remove the extension, and $U if already installed.
24059 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24060 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24061 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24062 # will be set to the directory where LIBOBJS objects are built.
24063 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24064 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24065 done
24066 LIBOBJS=$ac_libobjs
24068 LTLIBOBJS=$ac_ltlibobjs
24071 if test -n "$EXEEXT"; then
24072 am__EXEEXT_TRUE=
24073 am__EXEEXT_FALSE='#'
24074 else
24075 am__EXEEXT_TRUE='#'
24076 am__EXEEXT_FALSE=
24079 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24080 as_fn_error "conditional \"AMDEP\" was never defined.
24081 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24083 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24084 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24085 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24087 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24088 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24089 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24091 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24092 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24093 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24096 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24097 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24098 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24100 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
24101 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
24102 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24104 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
24105 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
24106 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24108 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24109 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24110 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24112 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24113 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24114 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24116 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
24117 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
24118 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24120 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
24121 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
24122 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24124 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
24125 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
24126 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24128 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
24129 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
24130 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24132 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
24133 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
24134 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24136 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
24137 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
24138 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24140 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
24141 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
24142 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24145 gl_libobjs=
24146 gl_ltlibobjs=
24147 if test -n "$gl_LIBOBJS"; then
24148 # Remove the extension.
24149 sed_drop_objext='s/\.o$//;s/\.obj$//'
24150 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24151 gl_libobjs="$gl_libobjs $i.$ac_objext"
24152 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
24153 done
24155 gl_LIBOBJS=$gl_libobjs
24157 gl_LTLIBOBJS=$gl_ltlibobjs
24161 gltests_libobjs=
24162 gltests_ltlibobjs=
24163 if test -n "$gltests_LIBOBJS"; then
24164 # Remove the extension.
24165 sed_drop_objext='s/\.o$//;s/\.obj$//'
24166 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24167 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
24168 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
24169 done
24171 gltests_LIBOBJS=$gltests_libobjs
24173 gltests_LTLIBOBJS=$gltests_ltlibobjs
24177 : ${CONFIG_STATUS=./config.status}
24178 ac_write_fail=0
24179 ac_clean_files_save=$ac_clean_files
24180 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24181 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
24182 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
24183 as_write_fail=0
24184 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
24185 #! $SHELL
24186 # Generated by $as_me.
24187 # Run this file to recreate the current configuration.
24188 # Compiler output produced by configure, useful for debugging
24189 # configure, is in config.log if it exists.
24191 debug=false
24192 ac_cs_recheck=false
24193 ac_cs_silent=false
24195 SHELL=\${CONFIG_SHELL-$SHELL}
24196 export SHELL
24197 _ASEOF
24198 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
24199 ## -------------------- ##
24200 ## M4sh Initialization. ##
24201 ## -------------------- ##
24203 # Be more Bourne compatible
24204 DUALCASE=1; export DUALCASE # for MKS sh
24205 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24206 emulate sh
24207 NULLCMD=:
24208 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
24209 # is contrary to our usage. Disable this feature.
24210 alias -g '${1+"$@"}'='"$@"'
24211 setopt NO_GLOB_SUBST
24212 else
24213 case `(set -o) 2>/dev/null` in #(
24214 *posix*) :
24215 set -o posix ;; #(
24216 *) :
24218 esac
24222 as_nl='
24224 export as_nl
24225 # Printing a long string crashes Solaris 7 /usr/bin/printf.
24226 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
24227 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
24228 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
24229 # Prefer a ksh shell builtin over an external printf program on Solaris,
24230 # but without wasting forks for bash or zsh.
24231 if test -z "$BASH_VERSION$ZSH_VERSION" \
24232 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
24233 as_echo='print -r --'
24234 as_echo_n='print -rn --'
24235 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
24236 as_echo='printf %s\n'
24237 as_echo_n='printf %s'
24238 else
24239 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
24240 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
24241 as_echo_n='/usr/ucb/echo -n'
24242 else
24243 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
24244 as_echo_n_body='eval
24245 arg=$1;
24246 case $arg in #(
24247 *"$as_nl"*)
24248 expr "X$arg" : "X\\(.*\\)$as_nl";
24249 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
24250 esac;
24251 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
24253 export as_echo_n_body
24254 as_echo_n='sh -c $as_echo_n_body as_echo'
24256 export as_echo_body
24257 as_echo='sh -c $as_echo_body as_echo'
24260 # The user is always right.
24261 if test "${PATH_SEPARATOR+set}" != set; then
24262 PATH_SEPARATOR=:
24263 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
24264 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
24265 PATH_SEPARATOR=';'
24270 # IFS
24271 # We need space, tab and new line, in precisely that order. Quoting is
24272 # there to prevent editors from complaining about space-tab.
24273 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
24274 # splitting by setting IFS to empty value.)
24275 IFS=" "" $as_nl"
24277 # Find who we are. Look in the path if we contain no directory separator.
24278 case $0 in #((
24279 *[\\/]* ) as_myself=$0 ;;
24280 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24281 for as_dir in $PATH
24283 IFS=$as_save_IFS
24284 test -z "$as_dir" && as_dir=.
24285 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
24286 done
24287 IFS=$as_save_IFS
24290 esac
24291 # We did not find ourselves, most probably we were run as `sh COMMAND'
24292 # in which case we are not to be found in the path.
24293 if test "x$as_myself" = x; then
24294 as_myself=$0
24296 if test ! -f "$as_myself"; then
24297 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
24298 exit 1
24301 # Unset variables that we do not need and which cause bugs (e.g. in
24302 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
24303 # suppresses any "Segmentation fault" message there. '((' could
24304 # trigger a bug in pdksh 5.2.14.
24305 for as_var in BASH_ENV ENV MAIL MAILPATH
24306 do eval test x\${$as_var+set} = xset \
24307 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
24308 done
24309 PS1='$ '
24310 PS2='> '
24311 PS4='+ '
24313 # NLS nuisances.
24314 LC_ALL=C
24315 export LC_ALL
24316 LANGUAGE=C
24317 export LANGUAGE
24319 # CDPATH.
24320 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
24323 # as_fn_error ERROR [LINENO LOG_FD]
24324 # ---------------------------------
24325 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
24326 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
24327 # script with status $?, using 1 if that was 0.
24328 as_fn_error ()
24330 as_status=$?; test $as_status -eq 0 && as_status=1
24331 if test "$3"; then
24332 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
24333 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
24335 $as_echo "$as_me: error: $1" >&2
24336 as_fn_exit $as_status
24337 } # as_fn_error
24340 # as_fn_set_status STATUS
24341 # -----------------------
24342 # Set $? to STATUS, without forking.
24343 as_fn_set_status ()
24345 return $1
24346 } # as_fn_set_status
24348 # as_fn_exit STATUS
24349 # -----------------
24350 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
24351 as_fn_exit ()
24353 set +e
24354 as_fn_set_status $1
24355 exit $1
24356 } # as_fn_exit
24358 # as_fn_unset VAR
24359 # ---------------
24360 # Portably unset VAR.
24361 as_fn_unset ()
24363 { eval $1=; unset $1;}
24365 as_unset=as_fn_unset
24366 # as_fn_append VAR VALUE
24367 # ----------------------
24368 # Append the text in VALUE to the end of the definition contained in VAR. Take
24369 # advantage of any shell optimizations that allow amortized linear growth over
24370 # repeated appends, instead of the typical quadratic growth present in naive
24371 # implementations.
24372 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
24373 eval 'as_fn_append ()
24375 eval $1+=\$2
24377 else
24378 as_fn_append ()
24380 eval $1=\$$1\$2
24382 fi # as_fn_append
24384 # as_fn_arith ARG...
24385 # ------------------
24386 # Perform arithmetic evaluation on the ARGs, and store the result in the
24387 # global $as_val. Take advantage of shells that can avoid forks. The arguments
24388 # must be portable across $(()) and expr.
24389 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
24390 eval 'as_fn_arith ()
24392 as_val=$(( $* ))
24394 else
24395 as_fn_arith ()
24397 as_val=`expr "$@" || test $? -eq 1`
24399 fi # as_fn_arith
24402 if expr a : '\(a\)' >/dev/null 2>&1 &&
24403 test "X`expr 00001 : '.*\(...\)'`" = X001; then
24404 as_expr=expr
24405 else
24406 as_expr=false
24409 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
24410 as_basename=basename
24411 else
24412 as_basename=false
24415 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
24416 as_dirname=dirname
24417 else
24418 as_dirname=false
24421 as_me=`$as_basename -- "$0" ||
24422 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
24423 X"$0" : 'X\(//\)$' \| \
24424 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
24425 $as_echo X/"$0" |
24426 sed '/^.*\/\([^/][^/]*\)\/*$/{
24427 s//\1/
24430 /^X\/\(\/\/\)$/{
24431 s//\1/
24434 /^X\/\(\/\).*/{
24435 s//\1/
24438 s/.*/./; q'`
24440 # Avoid depending upon Character Ranges.
24441 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
24442 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
24443 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
24444 as_cr_digits='0123456789'
24445 as_cr_alnum=$as_cr_Letters$as_cr_digits
24447 ECHO_C= ECHO_N= ECHO_T=
24448 case `echo -n x` in #(((((
24449 -n*)
24450 case `echo 'xy\c'` in
24451 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
24452 xy) ECHO_C='\c';;
24453 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
24454 ECHO_T=' ';;
24455 esac;;
24457 ECHO_N='-n';;
24458 esac
24460 rm -f conf$$ conf$$.exe conf$$.file
24461 if test -d conf$$.dir; then
24462 rm -f conf$$.dir/conf$$.file
24463 else
24464 rm -f conf$$.dir
24465 mkdir conf$$.dir 2>/dev/null
24467 if (echo >conf$$.file) 2>/dev/null; then
24468 if ln -s conf$$.file conf$$ 2>/dev/null; then
24469 as_ln_s='ln -s'
24470 # ... but there are two gotchas:
24471 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
24472 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
24473 # In both cases, we have to default to `cp -p'.
24474 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
24475 as_ln_s='cp -p'
24476 elif ln conf$$.file conf$$ 2>/dev/null; then
24477 as_ln_s=ln
24478 else
24479 as_ln_s='cp -p'
24481 else
24482 as_ln_s='cp -p'
24484 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
24485 rmdir conf$$.dir 2>/dev/null
24488 # as_fn_mkdir_p
24489 # -------------
24490 # Create "$as_dir" as a directory, including parents if necessary.
24491 as_fn_mkdir_p ()
24494 case $as_dir in #(
24495 -*) as_dir=./$as_dir;;
24496 esac
24497 test -d "$as_dir" || eval $as_mkdir_p || {
24498 as_dirs=
24499 while :; do
24500 case $as_dir in #(
24501 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
24502 *) as_qdir=$as_dir;;
24503 esac
24504 as_dirs="'$as_qdir' $as_dirs"
24505 as_dir=`$as_dirname -- "$as_dir" ||
24506 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24507 X"$as_dir" : 'X\(//\)[^/]' \| \
24508 X"$as_dir" : 'X\(//\)$' \| \
24509 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24510 $as_echo X"$as_dir" |
24511 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24512 s//\1/
24515 /^X\(\/\/\)[^/].*/{
24516 s//\1/
24519 /^X\(\/\/\)$/{
24520 s//\1/
24523 /^X\(\/\).*/{
24524 s//\1/
24527 s/.*/./; q'`
24528 test -d "$as_dir" && break
24529 done
24530 test -z "$as_dirs" || eval "mkdir $as_dirs"
24531 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
24534 } # as_fn_mkdir_p
24535 if mkdir -p . 2>/dev/null; then
24536 as_mkdir_p='mkdir -p "$as_dir"'
24537 else
24538 test -d ./-p && rmdir ./-p
24539 as_mkdir_p=false
24542 if test -x / >/dev/null 2>&1; then
24543 as_test_x='test -x'
24544 else
24545 if ls -dL / >/dev/null 2>&1; then
24546 as_ls_L_option=L
24547 else
24548 as_ls_L_option=
24550 as_test_x='
24551 eval sh -c '\''
24552 if test -d "$1"; then
24553 test -d "$1/.";
24554 else
24555 case $1 in #(
24556 -*)set "./$1";;
24557 esac;
24558 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
24559 ???[sx]*):;;*)false;;esac;fi
24560 '\'' sh
24563 as_executable_p=$as_test_x
24565 # Sed expression to map a string onto a valid CPP name.
24566 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
24568 # Sed expression to map a string onto a valid variable name.
24569 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
24572 exec 6>&1
24573 ## ----------------------------------- ##
24574 ## Main body of $CONFIG_STATUS script. ##
24575 ## ----------------------------------- ##
24576 _ASEOF
24577 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
24579 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24580 # Save the log message, to keep $0 and so on meaningful, and to
24581 # report actual input values of CONFIG_FILES etc. instead of their
24582 # values after options handling.
24583 ac_log="
24584 This file was extended by emacs $as_me 24.1.50, which was
24585 generated by GNU Autoconf 2.65. Invocation command line was
24587 CONFIG_FILES = $CONFIG_FILES
24588 CONFIG_HEADERS = $CONFIG_HEADERS
24589 CONFIG_LINKS = $CONFIG_LINKS
24590 CONFIG_COMMANDS = $CONFIG_COMMANDS
24591 $ $0 $@
24593 on `(hostname || uname -n) 2>/dev/null | sed 1q`
24596 _ACEOF
24598 case $ac_config_files in *"
24599 "*) set x $ac_config_files; shift; ac_config_files=$*;;
24600 esac
24602 case $ac_config_headers in *"
24603 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
24604 esac
24607 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24608 # Files that config.status was made for.
24609 config_files="$ac_config_files"
24610 config_headers="$ac_config_headers"
24611 config_commands="$ac_config_commands"
24613 _ACEOF
24615 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24616 ac_cs_usage="\
24617 \`$as_me' instantiates files and other configuration actions
24618 from templates according to the current configuration. Unless the files
24619 and actions are specified as TAGs, all are instantiated by default.
24621 Usage: $0 [OPTION]... [TAG]...
24623 -h, --help print this help, then exit
24624 -V, --version print version number and configuration settings, then exit
24625 --config print configuration, then exit
24626 -q, --quiet, --silent
24627 do not print progress messages
24628 -d, --debug don't remove temporary files
24629 --recheck update $as_me by reconfiguring in the same conditions
24630 --file=FILE[:TEMPLATE]
24631 instantiate the configuration file FILE
24632 --header=FILE[:TEMPLATE]
24633 instantiate the configuration header FILE
24635 Configuration files:
24636 $config_files
24638 Configuration headers:
24639 $config_headers
24641 Configuration commands:
24642 $config_commands
24644 Report bugs to the package provider."
24646 _ACEOF
24647 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24648 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
24649 ac_cs_version="\\
24650 emacs config.status 24.1.50
24651 configured by $0, generated by GNU Autoconf 2.65,
24652 with options \\"\$ac_cs_config\\"
24654 Copyright (C) 2009 Free Software Foundation, Inc.
24655 This config.status script is free software; the Free Software Foundation
24656 gives unlimited permission to copy, distribute and modify it."
24658 ac_pwd='$ac_pwd'
24659 srcdir='$srcdir'
24660 INSTALL='$INSTALL'
24661 MKDIR_P='$MKDIR_P'
24662 AWK='$AWK'
24663 test -n "\$AWK" || AWK=awk
24664 _ACEOF
24666 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24667 # The default lists apply if the user does not specify any file.
24668 ac_need_defaults=:
24669 while test $# != 0
24671 case $1 in
24672 --*=*)
24673 ac_option=`expr "X$1" : 'X\([^=]*\)='`
24674 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
24675 ac_shift=:
24678 ac_option=$1
24679 ac_optarg=$2
24680 ac_shift=shift
24682 esac
24684 case $ac_option in
24685 # Handling of the options.
24686 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
24687 ac_cs_recheck=: ;;
24688 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
24689 $as_echo "$ac_cs_version"; exit ;;
24690 --config | --confi | --conf | --con | --co | --c )
24691 $as_echo "$ac_cs_config"; exit ;;
24692 --debug | --debu | --deb | --de | --d | -d )
24693 debug=: ;;
24694 --file | --fil | --fi | --f )
24695 $ac_shift
24696 case $ac_optarg in
24697 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24698 esac
24699 as_fn_append CONFIG_FILES " '$ac_optarg'"
24700 ac_need_defaults=false;;
24701 --header | --heade | --head | --hea )
24702 $ac_shift
24703 case $ac_optarg in
24704 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
24705 esac
24706 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
24707 ac_need_defaults=false;;
24708 --he | --h)
24709 # Conflict between --help and --header
24710 as_fn_error "ambiguous option: \`$1'
24711 Try \`$0 --help' for more information.";;
24712 --help | --hel | -h )
24713 $as_echo "$ac_cs_usage"; exit ;;
24714 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
24715 | -silent | --silent | --silen | --sile | --sil | --si | --s)
24716 ac_cs_silent=: ;;
24718 # This is an error.
24719 -*) as_fn_error "unrecognized option: \`$1'
24720 Try \`$0 --help' for more information." ;;
24722 *) as_fn_append ac_config_targets " $1"
24723 ac_need_defaults=false ;;
24725 esac
24726 shift
24727 done
24729 ac_configure_extra_args=
24731 if $ac_cs_silent; then
24732 exec 6>/dev/null
24733 ac_configure_extra_args="$ac_configure_extra_args --silent"
24736 _ACEOF
24737 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24738 if \$ac_cs_recheck; then
24739 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
24740 shift
24741 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
24742 CONFIG_SHELL='$SHELL'
24743 export CONFIG_SHELL
24744 exec "\$@"
24747 _ACEOF
24748 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24749 exec 5>>config.log
24751 echo
24752 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
24753 ## Running $as_me. ##
24754 _ASBOX
24755 $as_echo "$ac_log"
24756 } >&5
24758 _ACEOF
24759 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24761 # INIT-COMMANDS
24763 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
24764 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
24766 _ACEOF
24768 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24770 # Handling of arguments.
24771 for ac_config_target in $ac_config_targets
24773 case $ac_config_target in
24774 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
24775 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
24776 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
24777 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
24778 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
24779 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
24780 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
24781 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
24782 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
24783 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
24784 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
24785 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
24786 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
24787 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
24788 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
24789 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
24790 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
24791 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
24792 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
24794 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
24795 esac
24796 done
24799 # If the user did not use the arguments to specify the items to instantiate,
24800 # then the envvar interface is used. Set only those that are not.
24801 # We use the long form for the default assignment because of an extremely
24802 # bizarre bug on SunOS 4.1.3.
24803 if $ac_need_defaults; then
24804 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
24805 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
24806 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
24809 # Have a temporary directory for convenience. Make it in the build tree
24810 # simply because there is no reason against having it here, and in addition,
24811 # creating and moving files from /tmp can sometimes cause problems.
24812 # Hook for its removal unless debugging.
24813 # Note that there is a small window in which the directory will not be cleaned:
24814 # after its creation but before its name has been assigned to `$tmp'.
24815 $debug ||
24817 tmp=
24818 trap 'exit_status=$?
24819 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
24821 trap 'as_fn_exit 1' 1 2 13 15
24823 # Create a (secure) tmp directory for tmp files.
24826 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
24827 test -n "$tmp" && test -d "$tmp"
24828 } ||
24830 tmp=./conf$$-$RANDOM
24831 (umask 077 && mkdir "$tmp")
24832 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
24834 # Set up the scripts for CONFIG_FILES section.
24835 # No need to generate them if there are no CONFIG_FILES.
24836 # This happens for instance with `./config.status config.h'.
24837 if test -n "$CONFIG_FILES"; then
24839 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
24840 ac_cs_awk_getline=:
24841 ac_cs_awk_pipe_init=
24842 ac_cs_awk_read_file='
24843 while ((getline aline < (F[key])) > 0)
24844 print(aline)
24845 close(F[key])'
24846 ac_cs_awk_pipe_fini=
24847 else
24848 ac_cs_awk_getline=false
24849 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
24850 ac_cs_awk_read_file='
24851 print "|#_!!_#|"
24852 print "cat " F[key] " &&"
24853 '$ac_cs_awk_pipe_init
24854 # The final `:' finishes the AND list.
24855 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
24857 ac_cr=`echo X | tr X '\015'`
24858 # On cygwin, bash can eat \r inside `` if the user requested igncr.
24859 # But we know of no other shell where ac_cr would be empty at this
24860 # point, so we can use a bashism as a fallback.
24861 if test "x$ac_cr" = x; then
24862 eval ac_cr=\$\'\\r\'
24864 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
24865 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
24866 ac_cs_awk_cr='\r'
24867 else
24868 ac_cs_awk_cr=$ac_cr
24871 echo 'BEGIN {' >"$tmp/subs1.awk" &&
24872 _ACEOF
24874 # Create commands to substitute file output variables.
24876 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
24877 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
24878 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
24879 echo "_ACAWK" &&
24880 echo "_ACEOF"
24881 } >conf$$files.sh &&
24882 . ./conf$$files.sh ||
24883 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
24884 rm -f conf$$files.sh
24887 echo "cat >conf$$subs.awk <<_ACEOF" &&
24888 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
24889 echo "_ACEOF"
24890 } >conf$$subs.sh ||
24891 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
24892 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
24893 ac_delim='%!_!# '
24894 for ac_last_try in false false false false false :; do
24895 . ./conf$$subs.sh ||
24896 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
24898 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
24899 if test $ac_delim_n = $ac_delim_num; then
24900 break
24901 elif $ac_last_try; then
24902 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
24903 else
24904 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
24906 done
24907 rm -f conf$$subs.sh
24909 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24910 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
24911 _ACEOF
24912 sed -n '
24914 s/^/S["/; s/!.*/"]=/
24917 s/^[^!]*!//
24918 :repl
24919 t repl
24920 s/'"$ac_delim"'$//
24921 t delim
24924 s/\(.\{148\}\)..*/\1/
24925 t more1
24926 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
24929 b repl
24930 :more1
24931 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24934 s/.\{148\}//
24935 t nl
24936 :delim
24938 s/\(.\{148\}\)..*/\1/
24939 t more2
24940 s/["\\]/\\&/g; s/^/"/; s/$/"/
24943 :more2
24944 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24947 s/.\{148\}//
24948 t delim
24949 ' <conf$$subs.awk | sed '
24950 /^[^""]/{
24952 s/\n//
24954 ' >>$CONFIG_STATUS || ac_write_fail=1
24955 rm -f conf$$subs.awk
24956 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24957 _ACAWK
24958 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
24959 for (key in S) S_is_set[key] = 1
24960 FS = "\a"
24961 \$ac_cs_awk_pipe_init
24964 line = $ 0
24965 nfields = split(line, field, "@")
24966 substed = 0
24967 len = length(field[1])
24968 for (i = 2; i < nfields; i++) {
24969 key = field[i]
24970 keylen = length(key)
24971 if (S_is_set[key]) {
24972 value = S[key]
24973 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
24974 len += length(value) + length(field[++i])
24975 substed = 1
24976 } else
24977 len += 1 + keylen
24979 if (nfields == 3 && !substed) {
24980 key = field[2]
24981 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
24982 \$ac_cs_awk_read_file
24983 next
24986 print line
24988 \$ac_cs_awk_pipe_fini
24989 _ACAWK
24990 _ACEOF
24991 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24992 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
24993 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
24994 else
24996 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
24997 || as_fn_error "could not setup config files machinery" "$LINENO" 5
24998 _ACEOF
25000 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25001 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25002 # trailing colons and then remove the whole line if VPATH becomes empty
25003 # (actually we leave an empty line to preserve line numbers).
25004 if test "x$srcdir" = x.; then
25005 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25006 s/:*\$(srcdir):*/:/
25007 s/:*\${srcdir}:*/:/
25008 s/:*@srcdir@:*/:/
25009 s/^\([^=]*=[ ]*\):*/\1/
25010 s/:*$//
25011 s/^[^=]*=[ ]*$//
25015 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25016 fi # test -n "$CONFIG_FILES"
25018 # Set up the scripts for CONFIG_HEADERS section.
25019 # No need to generate them if there are no CONFIG_HEADERS.
25020 # This happens for instance with `./config.status Makefile'.
25021 if test -n "$CONFIG_HEADERS"; then
25022 cat >"$tmp/defines.awk" <<\_ACAWK ||
25023 BEGIN {
25024 _ACEOF
25026 # Transform confdefs.h into an awk script `defines.awk', embedded as
25027 # here-document in config.status, that substitutes the proper values into
25028 # config.h.in to produce config.h.
25030 # Create a delimiter string that does not exist in confdefs.h, to ease
25031 # handling of long lines.
25032 ac_delim='%!_!# '
25033 for ac_last_try in false false :; do
25034 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25035 if test -z "$ac_t"; then
25036 break
25037 elif $ac_last_try; then
25038 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25039 else
25040 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25042 done
25044 # For the awk script, D is an array of macro values keyed by name,
25045 # likewise P contains macro parameters if any. Preserve backslash
25046 # newline sequences.
25048 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25049 sed -n '
25050 s/.\{148\}/&'"$ac_delim"'/g
25051 t rset
25052 :rset
25053 s/^[ ]*#[ ]*define[ ][ ]*/ /
25054 t def
25056 :def
25057 s/\\$//
25058 t bsnl
25059 s/["\\]/\\&/g
25060 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25061 D["\1"]=" \3"/p
25062 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25064 :bsnl
25065 s/["\\]/\\&/g
25066 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25067 D["\1"]=" \3\\\\\\n"\\/p
25068 t cont
25069 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25070 t cont
25072 :cont
25074 s/.\{148\}/&'"$ac_delim"'/g
25075 t clear
25076 :clear
25077 s/\\$//
25078 t bsnlc
25079 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25081 :bsnlc
25082 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25083 b cont
25084 ' <confdefs.h | sed '
25085 s/'"$ac_delim"'/"\\\
25086 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25088 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25089 for (key in D) D_is_set[key] = 1
25090 FS = "\a"
25092 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25093 line = \$ 0
25094 split(line, arg, " ")
25095 if (arg[1] == "#") {
25096 defundef = arg[2]
25097 mac1 = arg[3]
25098 } else {
25099 defundef = substr(arg[1], 2)
25100 mac1 = arg[2]
25102 split(mac1, mac2, "(") #)
25103 macro = mac2[1]
25104 prefix = substr(line, 1, index(line, defundef) - 1)
25105 if (D_is_set[macro]) {
25106 # Preserve the white space surrounding the "#".
25107 print prefix "define", macro P[macro] D[macro]
25108 next
25109 } else {
25110 # Replace #undef with comments. This is necessary, for example,
25111 # in the case of _POSIX_SOURCE, which is predefined and required
25112 # on some systems where configure will not decide to define it.
25113 if (defundef == "undef") {
25114 print "/*", prefix defundef, macro, "*/"
25115 next
25119 { print }
25120 _ACAWK
25121 _ACEOF
25122 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25123 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25124 fi # test -n "$CONFIG_HEADERS"
25127 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25128 shift
25129 for ac_tag
25131 case $ac_tag in
25132 :[FHLC]) ac_mode=$ac_tag; continue;;
25133 esac
25134 case $ac_mode$ac_tag in
25135 :[FHL]*:*);;
25136 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25137 :[FH]-) ac_tag=-:-;;
25138 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25139 esac
25140 ac_save_IFS=$IFS
25141 IFS=:
25142 set x $ac_tag
25143 IFS=$ac_save_IFS
25144 shift
25145 ac_file=$1
25146 shift
25148 case $ac_mode in
25149 :L) ac_source=$1;;
25150 :[FH])
25151 ac_file_inputs=
25152 for ac_f
25154 case $ac_f in
25155 -) ac_f="$tmp/stdin";;
25156 *) # Look for the file first in the build tree, then in the source tree
25157 # (if the path is not absolute). The absolute path cannot be DOS-style,
25158 # because $ac_f cannot contain `:'.
25159 test -f "$ac_f" ||
25160 case $ac_f in
25161 [\\/$]*) false;;
25162 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
25163 esac ||
25164 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
25165 esac
25166 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
25167 as_fn_append ac_file_inputs " '$ac_f'"
25168 done
25170 # Let's still pretend it is `configure' which instantiates (i.e., don't
25171 # use $as_me), people would be surprised to read:
25172 # /* config.h. Generated by config.status. */
25173 configure_input='Generated from '`
25174 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
25175 `' by configure.'
25176 if test x"$ac_file" != x-; then
25177 configure_input="$ac_file. $configure_input"
25178 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
25179 $as_echo "$as_me: creating $ac_file" >&6;}
25181 # Neutralize special characters interpreted by sed in replacement strings.
25182 case $configure_input in #(
25183 *\&* | *\|* | *\\* )
25184 ac_sed_conf_input=`$as_echo "$configure_input" |
25185 sed 's/[\\\\&|]/\\\\&/g'`;; #(
25186 *) ac_sed_conf_input=$configure_input;;
25187 esac
25189 case $ac_tag in
25190 *:-:* | *:-) cat >"$tmp/stdin" \
25191 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
25192 esac
25194 esac
25196 ac_dir=`$as_dirname -- "$ac_file" ||
25197 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25198 X"$ac_file" : 'X\(//\)[^/]' \| \
25199 X"$ac_file" : 'X\(//\)$' \| \
25200 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
25201 $as_echo X"$ac_file" |
25202 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25203 s//\1/
25206 /^X\(\/\/\)[^/].*/{
25207 s//\1/
25210 /^X\(\/\/\)$/{
25211 s//\1/
25214 /^X\(\/\).*/{
25215 s//\1/
25218 s/.*/./; q'`
25219 as_dir="$ac_dir"; as_fn_mkdir_p
25220 ac_builddir=.
25222 case "$ac_dir" in
25223 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
25225 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
25226 # A ".." for each directory in $ac_dir_suffix.
25227 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
25228 case $ac_top_builddir_sub in
25229 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
25230 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
25231 esac ;;
25232 esac
25233 ac_abs_top_builddir=$ac_pwd
25234 ac_abs_builddir=$ac_pwd$ac_dir_suffix
25235 # for backward compatibility:
25236 ac_top_builddir=$ac_top_build_prefix
25238 case $srcdir in
25239 .) # We are building in place.
25240 ac_srcdir=.
25241 ac_top_srcdir=$ac_top_builddir_sub
25242 ac_abs_top_srcdir=$ac_pwd ;;
25243 [\\/]* | ?:[\\/]* ) # Absolute name.
25244 ac_srcdir=$srcdir$ac_dir_suffix;
25245 ac_top_srcdir=$srcdir
25246 ac_abs_top_srcdir=$srcdir ;;
25247 *) # Relative name.
25248 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
25249 ac_top_srcdir=$ac_top_build_prefix$srcdir
25250 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
25251 esac
25252 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
25255 case $ac_mode in
25258 # CONFIG_FILE
25261 case $INSTALL in
25262 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
25263 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
25264 esac
25265 ac_MKDIR_P=$MKDIR_P
25266 case $MKDIR_P in
25267 [\\/$]* | ?:[\\/]* ) ;;
25268 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
25269 esac
25270 _ACEOF
25272 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25273 # If the template does not know about datarootdir, expand it.
25274 # FIXME: This hack should be removed a few years after 2.60.
25275 ac_datarootdir_hack=; ac_datarootdir_seen=
25276 ac_sed_dataroot='
25277 /datarootdir/ {
25281 /@datadir@/p
25282 /@docdir@/p
25283 /@infodir@/p
25284 /@localedir@/p
25285 /@mandir@/p'
25286 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
25287 *datarootdir*) ac_datarootdir_seen=yes;;
25288 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
25289 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
25290 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
25291 _ACEOF
25292 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25293 ac_datarootdir_hack='
25294 s&@datadir@&$datadir&g
25295 s&@docdir@&$docdir&g
25296 s&@infodir@&$infodir&g
25297 s&@localedir@&$localedir&g
25298 s&@mandir@&$mandir&g
25299 s&\\\${datarootdir}&$datarootdir&g' ;;
25300 esac
25301 _ACEOF
25303 # Neutralize VPATH when `$srcdir' = `.'.
25304 # Shell code in configure.ac might set extrasub.
25305 # FIXME: do we really want to maintain this feature?
25306 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25307 ac_sed_extra="$ac_vpsub
25308 $extrasub
25309 _ACEOF
25310 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25312 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
25313 s|@configure_input@|$ac_sed_conf_input|;t t
25314 s&@top_builddir@&$ac_top_builddir_sub&;t t
25315 s&@top_build_prefix@&$ac_top_build_prefix&;t t
25316 s&@srcdir@&$ac_srcdir&;t t
25317 s&@abs_srcdir@&$ac_abs_srcdir&;t t
25318 s&@top_srcdir@&$ac_top_srcdir&;t t
25319 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
25320 s&@builddir@&$ac_builddir&;t t
25321 s&@abs_builddir@&$ac_abs_builddir&;t t
25322 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
25323 s&@INSTALL@&$ac_INSTALL&;t t
25324 s&@MKDIR_P@&$ac_MKDIR_P&;t t
25325 $ac_datarootdir_hack
25327 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
25328 if $ac_cs_awk_getline; then
25329 $AWK -f "$tmp/subs.awk"
25330 else
25331 $AWK -f "$tmp/subs.awk" | $SHELL
25332 fi >$tmp/out \
25333 || as_fn_error "could not create $ac_file" "$LINENO" 5
25335 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
25336 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
25337 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
25338 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25339 which seems to be undefined. Please make sure it is defined." >&5
25340 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25341 which seems to be undefined. Please make sure it is defined." >&2;}
25343 rm -f "$tmp/stdin"
25344 case $ac_file in
25345 -) cat "$tmp/out" && rm -f "$tmp/out";;
25346 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
25347 esac \
25348 || as_fn_error "could not create $ac_file" "$LINENO" 5
25352 # CONFIG_HEADER
25354 if test x"$ac_file" != x-; then
25356 $as_echo "/* $configure_input */" \
25357 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
25358 } >"$tmp/config.h" \
25359 || as_fn_error "could not create $ac_file" "$LINENO" 5
25360 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
25361 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
25362 $as_echo "$as_me: $ac_file is unchanged" >&6;}
25363 else
25364 rm -f "$ac_file"
25365 mv "$tmp/config.h" "$ac_file" \
25366 || as_fn_error "could not create $ac_file" "$LINENO" 5
25368 else
25369 $as_echo "/* $configure_input */" \
25370 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
25371 || as_fn_error "could not create -" "$LINENO" 5
25373 # Compute "$ac_file"'s index in $config_headers.
25374 _am_arg="$ac_file"
25375 _am_stamp_count=1
25376 for _am_header in $config_headers :; do
25377 case $_am_header in
25378 $_am_arg | $_am_arg:* )
25379 break ;;
25381 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
25382 esac
25383 done
25384 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
25385 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25386 X"$_am_arg" : 'X\(//\)[^/]' \| \
25387 X"$_am_arg" : 'X\(//\)$' \| \
25388 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
25389 $as_echo X"$_am_arg" |
25390 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25391 s//\1/
25394 /^X\(\/\/\)[^/].*/{
25395 s//\1/
25398 /^X\(\/\/\)$/{
25399 s//\1/
25402 /^X\(\/\).*/{
25403 s//\1/
25406 s/.*/./; q'`/stamp-h$_am_stamp_count
25409 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
25410 $as_echo "$as_me: executing $ac_file commands" >&6;}
25412 esac
25415 case $ac_file$ac_mode in
25416 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
25417 # Autoconf 2.62 quotes --file arguments for eval, but not when files
25418 # are listed without --file. Let's play safe and only enable the eval
25419 # if we detect the quoting.
25420 case $CONFIG_FILES in
25421 *\'*) eval set x "$CONFIG_FILES" ;;
25422 *) set x $CONFIG_FILES ;;
25423 esac
25424 shift
25425 for mf
25427 # Strip MF so we end up with the name of the file.
25428 mf=`echo "$mf" | sed -e 's/:.*$//'`
25429 # Check whether this is an Automake generated Makefile or not.
25430 # We used to match only the files named `Makefile.in', but
25431 # some people rename them; so instead we look at the file content.
25432 # Grep'ing the first line is not enough: some people post-process
25433 # each Makefile.in and add a new line on top of each file to say so.
25434 # Grep'ing the whole file is not good either: AIX grep has a line
25435 # limit of 2048, but all sed's we know have understand at least 4000.
25436 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
25437 dirpart=`$as_dirname -- "$mf" ||
25438 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25439 X"$mf" : 'X\(//\)[^/]' \| \
25440 X"$mf" : 'X\(//\)$' \| \
25441 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
25442 $as_echo X"$mf" |
25443 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25444 s//\1/
25447 /^X\(\/\/\)[^/].*/{
25448 s//\1/
25451 /^X\(\/\/\)$/{
25452 s//\1/
25455 /^X\(\/\).*/{
25456 s//\1/
25459 s/.*/./; q'`
25460 else
25461 continue
25463 # Extract the definition of DEPDIR, am__include, and am__quote
25464 # from the Makefile without running `make'.
25465 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
25466 test -z "$DEPDIR" && continue
25467 am__include=`sed -n 's/^am__include = //p' < "$mf"`
25468 test -z "am__include" && continue
25469 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
25470 # When using ansi2knr, U may be empty or an underscore; expand it
25471 U=`sed -n 's/^U = //p' < "$mf"`
25472 # Find all dependency output files, they are included files with
25473 # $(DEPDIR) in their names. We invoke sed twice because it is the
25474 # simplest approach to changing $(DEPDIR) to its actual value in the
25475 # expansion.
25476 for file in `sed -n "
25477 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
25478 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
25479 # Make sure the directory exists.
25480 test -f "$dirpart/$file" && continue
25481 fdir=`$as_dirname -- "$file" ||
25482 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25483 X"$file" : 'X\(//\)[^/]' \| \
25484 X"$file" : 'X\(//\)$' \| \
25485 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
25486 $as_echo X"$file" |
25487 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25488 s//\1/
25491 /^X\(\/\/\)[^/].*/{
25492 s//\1/
25495 /^X\(\/\/\)$/{
25496 s//\1/
25499 /^X\(\/\).*/{
25500 s//\1/
25503 s/.*/./; q'`
25504 as_dir=$dirpart/$fdir; as_fn_mkdir_p
25505 # echo "creating $dirpart/$file"
25506 echo '# dummy' > "$dirpart/$file"
25507 done
25508 done
25511 "mkdirs":C)
25512 for dir in etc lisp ; do
25513 test -d ${dir} || mkdir ${dir}
25514 done
25516 "epaths":C)
25517 echo creating src/epaths.h
25518 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
25520 "gdbinit":C)
25521 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
25522 echo creating src/.gdbinit
25523 echo source $srcdir/src/.gdbinit > src/.gdbinit
25527 esac
25528 done # for ac_tag
25531 as_fn_exit 0
25532 _ACEOF
25533 ac_clean_files=$ac_clean_files_save
25535 test $ac_write_fail = 0 ||
25536 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
25539 # configure is writing to config.log, and then calls config.status.
25540 # config.status does its own redirection, appending to config.log.
25541 # Unfortunately, on DOS this fails, as config.log is still kept open
25542 # by configure, so config.status won't be able to write to it; its
25543 # output is simply discarded. So we exec the FD to /dev/null,
25544 # effectively closing config.log, so it can be properly (re)opened and
25545 # appended to by config.status. When coming back to configure, we
25546 # need to make the FD available again.
25547 if test "$no_create" != yes; then
25548 ac_cs_success=:
25549 ac_config_status_args=
25550 test "$silent" = yes &&
25551 ac_config_status_args="$ac_config_status_args --quiet"
25552 exec 5>/dev/null
25553 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
25554 exec 5>>config.log
25555 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
25556 # would make configure fail if this is the last instruction.
25557 $ac_cs_success || as_fn_exit $?
25559 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
25560 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
25561 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}