]> code.delx.au - gnu-emacs/blob - autogen/configure
Auto-commit of generated files.
[gnu-emacs] / autogen / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.2.50.
4 #
5 #
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.
9 #
10 #
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 ## -------------------- ##
16
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 *) :
31 ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
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"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72 fi
73
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=';'
80 }
81 fi
82
83
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"
90
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
96 do
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
102
103 ;;
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
109 fi
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
113 fi
114
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='+ '
126
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
132
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
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 *) :
149 ;;
150 esac
151 fi
152 "
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; }
158
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 :
165
166 else
167 exitcode=1; echo positional parameters were not saved.
168 fi
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
179 fi
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
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
186 do
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
191 /*)
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
200 fi
201 fi
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
211
212
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+"$@"}
222 fi
223
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."
235 fi
236 exit 1
237 fi
238 fi
239 fi
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
245
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
253 {
254 { eval $1=; unset $1;}
255 }
256 as_unset=as_fn_unset
257
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
262 {
263 return $1
264 } # as_fn_set_status
265
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 ()
270 {
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
275
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
280 {
281
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/
301 q
302 }
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
305 q
306 }
307 /^X\(\/\/\)$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\).*/{
312 s//\1/
313 q
314 }
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"
320
321
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 ()
331 {
332 eval $1+=\$2
333 }'
334 else
335 as_fn_append ()
336 {
337 eval $1=\$$1\$2
338 }
339 fi # as_fn_append
340
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 ()
348 {
349 as_val=$(( $* ))
350 }'
351 else
352 as_fn_arith ()
353 {
354 as_val=`expr "$@" || test $? -eq 1`
355 }
356 fi # as_fn_arith
357
358
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 ()
365 {
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
370 fi
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
374
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
380 fi
381
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
386 fi
387
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
392 fi
393
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/
401 q
402 }
403 /^X\/\(\/\/\)$/{
404 s//\1/
405 q
406 }
407 /^X\/\(\/\).*/{
408 s//\1/
409 q
410 }
411 s/.*/./; q'`
412
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
419
420
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 '
427 p
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
433 b
434 :lineno
435 N
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; }
443
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
450 }
451
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;;
461 *)
462 ECHO_N='-n';;
463 esac
464
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
471 fi
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'
485 fi
486 else
487 as_ln_s='cp -p'
488 fi
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
491
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
497 fi
498
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=
506 fi
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
518 '
519 fi
520 as_executable_p=$as_test_x
521
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'"
524
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'"
527
528
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
531
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`
536
537 #
538 # Initializations.
539 #
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=
548
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.2.50'
553 PACKAGE_STRING='emacs 24.2.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
556
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"
593
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 WINDOW_SYSTEM_OBJ
608 LIB_GCC
609 LD_FIRSTFLAG
610 LD_SWITCH_SYSTEM_TEMACS
611 LIBGNU_LTLIBDEPS
612 LIBGNU_LIBDEPS
613 gltests_WITNESS
614 gl_GNULIB_ENABLED_verify_FALSE
615 gl_GNULIB_ENABLED_verify_TRUE
616 gl_GNULIB_ENABLED_strtoull_FALSE
617 gl_GNULIB_ENABLED_strtoull_TRUE
618 gl_GNULIB_ENABLED_strtoll_FALSE
619 gl_GNULIB_ENABLED_strtoll_TRUE
620 gl_GNULIB_ENABLED_stat_FALSE
621 gl_GNULIB_ENABLED_stat_TRUE
622 gl_GNULIB_ENABLED_pathmax_FALSE
623 gl_GNULIB_ENABLED_pathmax_TRUE
624 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
625 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
626 gl_GNULIB_ENABLED_dosname_FALSE
627 gl_GNULIB_ENABLED_dosname_TRUE
628 LTLIBINTL
629 LIBINTL
630 WINDOWS_64_BIT_OFF_T
631 HAVE_UNISTD_H
632 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
633 NEXT_UNISTD_H
634 LIB_TIMER_TIME
635 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
636 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
637 TIME_H_DEFINES_STRUCT_TIMESPEC
638 NEXT_AS_FIRST_DIRECTIVE_TIME_H
639 NEXT_TIME_H
640 WINDOWS_64_BIT_ST_SIZE
641 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
642 NEXT_SYS_STAT_H
643 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
644 NEXT_STDLIB_H
645 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
646 NEXT_STDIO_H
647 REPLACE_VSPRINTF
648 REPLACE_VSNPRINTF
649 REPLACE_VPRINTF
650 REPLACE_VFPRINTF
651 REPLACE_VDPRINTF
652 REPLACE_VASPRINTF
653 REPLACE_TMPFILE
654 REPLACE_STDIO_WRITE_FUNCS
655 REPLACE_STDIO_READ_FUNCS
656 REPLACE_SPRINTF
657 REPLACE_SNPRINTF
658 REPLACE_RENAMEAT
659 REPLACE_RENAME
660 REPLACE_REMOVE
661 REPLACE_PRINTF
662 REPLACE_POPEN
663 REPLACE_PERROR
664 REPLACE_OBSTACK_PRINTF
665 REPLACE_GETLINE
666 REPLACE_GETDELIM
667 REPLACE_FTELLO
668 REPLACE_FTELL
669 REPLACE_FSEEKO
670 REPLACE_FSEEK
671 REPLACE_FREOPEN
672 REPLACE_FPURGE
673 REPLACE_FPRINTF
674 REPLACE_FOPEN
675 REPLACE_FFLUSH
676 REPLACE_FDOPEN
677 REPLACE_FCLOSE
678 REPLACE_DPRINTF
679 HAVE_VDPRINTF
680 HAVE_VASPRINTF
681 HAVE_RENAMEAT
682 HAVE_POPEN
683 HAVE_PCLOSE
684 HAVE_FTELLO
685 HAVE_FSEEKO
686 HAVE_DPRINTF
687 HAVE_DECL_VSNPRINTF
688 HAVE_DECL_SNPRINTF
689 HAVE_DECL_OBSTACK_PRINTF
690 HAVE_DECL_GETLINE
691 HAVE_DECL_GETDELIM
692 HAVE_DECL_FTELLO
693 HAVE_DECL_FSEEKO
694 HAVE_DECL_FPURGE
695 GNULIB_VSPRINTF_POSIX
696 GNULIB_VSNPRINTF
697 GNULIB_VPRINTF_POSIX
698 GNULIB_VPRINTF
699 GNULIB_VFPRINTF_POSIX
700 GNULIB_VFPRINTF
701 GNULIB_VDPRINTF
702 GNULIB_VSCANF
703 GNULIB_VFSCANF
704 GNULIB_VASPRINTF
705 GNULIB_TMPFILE
706 GNULIB_STDIO_H_SIGPIPE
707 GNULIB_STDIO_H_NONBLOCKING
708 GNULIB_SPRINTF_POSIX
709 GNULIB_SNPRINTF
710 GNULIB_SCANF
711 GNULIB_RENAMEAT
712 GNULIB_RENAME
713 GNULIB_REMOVE
714 GNULIB_PUTS
715 GNULIB_PUTCHAR
716 GNULIB_PUTC
717 GNULIB_PRINTF_POSIX
718 GNULIB_PRINTF
719 GNULIB_POPEN
720 GNULIB_PERROR
721 GNULIB_PCLOSE
722 GNULIB_OBSTACK_PRINTF_POSIX
723 GNULIB_OBSTACK_PRINTF
724 GNULIB_GETLINE
725 GNULIB_GETDELIM
726 GNULIB_GETCHAR
727 GNULIB_GETC
728 GNULIB_FWRITE
729 GNULIB_FTELLO
730 GNULIB_FTELL
731 GNULIB_FSEEKO
732 GNULIB_FSEEK
733 GNULIB_FSCANF
734 GNULIB_FREOPEN
735 GNULIB_FREAD
736 GNULIB_FPUTS
737 GNULIB_FPUTC
738 GNULIB_FPURGE
739 GNULIB_FPRINTF_POSIX
740 GNULIB_FPRINTF
741 GNULIB_FOPEN
742 GNULIB_FGETS
743 GNULIB_FGETC
744 GNULIB_FFLUSH
745 GNULIB_FDOPEN
746 GNULIB_FCLOSE
747 GNULIB_DPRINTF
748 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
749 NEXT_STDDEF_H
750 GL_GENERATE_STDDEF_H_FALSE
751 GL_GENERATE_STDDEF_H_TRUE
752 STDDEF_H
753 HAVE_WCHAR_T
754 REPLACE_NULL
755 HAVE__BOOL
756 GL_GENERATE_STDBOOL_H_FALSE
757 GL_GENERATE_STDBOOL_H_TRUE
758 STDBOOL_H
759 GL_GENERATE_STDARG_H_FALSE
760 GL_GENERATE_STDARG_H_TRUE
761 STDARG_H
762 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
763 NEXT_STDARG_H
764 GL_GENERATE_STDALIGN_H_FALSE
765 GL_GENERATE_STDALIGN_H_TRUE
766 STDALIGN_H
767 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
768 NEXT_SIGNAL_H
769 LIB_PTHREAD_SIGMASK
770 REPLACE_RAISE
771 REPLACE_PTHREAD_SIGMASK
772 HAVE_SIGHANDLER_T
773 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
774 HAVE_STRUCT_SIGACTION_SA_SIGACTION
775 HAVE_SIGACTION
776 HAVE_SIGINFO_T
777 HAVE_SIGSET_T
778 HAVE_RAISE
779 HAVE_PTHREAD_SIGMASK
780 HAVE_POSIX_SIGNALBLOCKING
781 GNULIB_SIGACTION
782 GNULIB_SIGPROCMASK
783 GNULIB_SIGNAL_H_SIGPIPE
784 GNULIB_RAISE
785 GNULIB_PTHREAD_SIGMASK
786 HAVE_SYS_SELECT_H
787 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
788 NEXT_SYS_SELECT_H
789 REPLACE_SELECT
790 REPLACE_PSELECT
791 HAVE_PSELECT
792 GNULIB_SELECT
793 GNULIB_PSELECT
794 REPLACE_TIMEGM
795 REPLACE_NANOSLEEP
796 REPLACE_MKTIME
797 REPLACE_LOCALTIME_R
798 HAVE_TIMEGM
799 HAVE_STRPTIME
800 HAVE_NANOSLEEP
801 HAVE_DECL_LOCALTIME_R
802 GNULIB_TIME_R
803 GNULIB_TIMEGM
804 GNULIB_STRPTIME
805 GNULIB_NANOSLEEP
806 GNULIB_MKTIME
807 REPLACE_UTIMENSAT
808 REPLACE_STAT
809 REPLACE_MKNOD
810 REPLACE_MKFIFO
811 REPLACE_MKDIR
812 REPLACE_LSTAT
813 REPLACE_FUTIMENS
814 REPLACE_FSTATAT
815 REPLACE_FSTAT
816 HAVE_UTIMENSAT
817 HAVE_MKNODAT
818 HAVE_MKNOD
819 HAVE_MKFIFOAT
820 HAVE_MKFIFO
821 HAVE_MKDIRAT
822 HAVE_LSTAT
823 HAVE_LCHMOD
824 HAVE_FUTIMENS
825 HAVE_FSTATAT
826 HAVE_FCHMODAT
827 GNULIB_UTIMENSAT
828 GNULIB_STAT
829 GNULIB_MKNODAT
830 GNULIB_MKNOD
831 GNULIB_MKFIFOAT
832 GNULIB_MKFIFO
833 GNULIB_MKDIRAT
834 GNULIB_LSTAT
835 GNULIB_LCHMOD
836 GNULIB_FUTIMENS
837 GNULIB_FSTATAT
838 GNULIB_FSTAT
839 GNULIB_FCHMODAT
840 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
841 NEXT_INTTYPES_H
842 UINT64_MAX_EQ_ULONG_MAX
843 UINT32_MAX_LT_UINTMAX_MAX
844 PRIPTR_PREFIX
845 PRI_MACROS_BROKEN
846 INT64_MAX_EQ_LONG_MAX
847 INT32_MAX_LT_INTMAX_MAX
848 REPLACE_STRTOIMAX
849 HAVE_DECL_STRTOUMAX
850 HAVE_DECL_STRTOIMAX
851 HAVE_DECL_IMAXDIV
852 HAVE_DECL_IMAXABS
853 GNULIB_STRTOUMAX
854 GNULIB_STRTOIMAX
855 GNULIB_IMAXDIV
856 GNULIB_IMAXABS
857 GL_GENERATE_STDINT_H_FALSE
858 GL_GENERATE_STDINT_H_TRUE
859 STDINT_H
860 WINT_T_SUFFIX
861 WCHAR_T_SUFFIX
862 SIG_ATOMIC_T_SUFFIX
863 SIZE_T_SUFFIX
864 PTRDIFF_T_SUFFIX
865 HAVE_SIGNED_WINT_T
866 HAVE_SIGNED_WCHAR_T
867 HAVE_SIGNED_SIG_ATOMIC_T
868 BITSIZEOF_WINT_T
869 BITSIZEOF_WCHAR_T
870 BITSIZEOF_SIG_ATOMIC_T
871 BITSIZEOF_SIZE_T
872 BITSIZEOF_PTRDIFF_T
873 APPLE_UNIVERSAL_BUILD
874 HAVE_SYS_BITYPES_H
875 HAVE_SYS_INTTYPES_H
876 HAVE_STDINT_H
877 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
878 NEXT_STDINT_H
879 HAVE_SYS_TYPES_H
880 HAVE_INTTYPES_H
881 HAVE_WCHAR_H
882 HAVE_UNSIGNED_LONG_LONG_INT
883 HAVE_LONG_LONG_INT
884 HAVE_WINSOCK2_H
885 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
886 NEXT_SYS_TIME_H
887 REPLACE_STRUCT_TIMEVAL
888 REPLACE_GETTIMEOFDAY
889 HAVE_SYS_TIME_H
890 HAVE_STRUCT_TIMEVAL
891 HAVE_GETTIMEOFDAY
892 GNULIB_GETTIMEOFDAY
893 GNULIB_GL_UNISTD_H_GETOPT
894 GETOPT_H
895 HAVE_GETOPT_H
896 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
897 NEXT_GETOPT_H
898 PRAGMA_COLUMNS
899 PRAGMA_SYSTEM_HEADER
900 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
901 INCLUDE_NEXT
902 GETLOADAVG_LIBS
903 REPLACE_WCTOMB
904 REPLACE_UNSETENV
905 REPLACE_STRTOD
906 REPLACE_SETENV
907 REPLACE_REALPATH
908 REPLACE_REALLOC
909 REPLACE_RANDOM_R
910 REPLACE_PUTENV
911 REPLACE_PTSNAME_R
912 REPLACE_PTSNAME
913 REPLACE_MKSTEMP
914 REPLACE_MBTOWC
915 REPLACE_MALLOC
916 REPLACE_CANONICALIZE_FILE_NAME
917 REPLACE_CALLOC
918 HAVE_DECL_UNSETENV
919 HAVE_UNLOCKPT
920 HAVE_SYS_LOADAVG_H
921 HAVE_STRUCT_RANDOM_DATA
922 HAVE_STRTOULL
923 HAVE_STRTOLL
924 HAVE_STRTOD
925 HAVE_DECL_SETENV
926 HAVE_SETENV
927 HAVE_RPMATCH
928 HAVE_REALPATH
929 HAVE_RANDOM_R
930 HAVE_RANDOM_H
931 HAVE_RANDOM
932 HAVE_PTSNAME_R
933 HAVE_PTSNAME
934 HAVE_POSIX_OPENPT
935 HAVE_MKSTEMPS
936 HAVE_MKSTEMP
937 HAVE_MKOSTEMPS
938 HAVE_MKOSTEMP
939 HAVE_MKDTEMP
940 HAVE_GRANTPT
941 HAVE_GETSUBOPT
942 HAVE_DECL_GETLOADAVG
943 HAVE_CANONICALIZE_FILE_NAME
944 HAVE_ATOLL
945 HAVE__EXIT
946 GNULIB_WCTOMB
947 GNULIB_UNSETENV
948 GNULIB_UNLOCKPT
949 GNULIB_SYSTEM_POSIX
950 GNULIB_STRTOULL
951 GNULIB_STRTOLL
952 GNULIB_STRTOD
953 GNULIB_SETENV
954 GNULIB_RPMATCH
955 GNULIB_REALPATH
956 GNULIB_REALLOC_POSIX
957 GNULIB_RANDOM_R
958 GNULIB_RANDOM
959 GNULIB_PUTENV
960 GNULIB_PTSNAME_R
961 GNULIB_PTSNAME
962 GNULIB_POSIX_OPENPT
963 GNULIB_MKSTEMPS
964 GNULIB_MKSTEMP
965 GNULIB_MKOSTEMPS
966 GNULIB_MKOSTEMP
967 GNULIB_MKDTEMP
968 GNULIB_MBTOWC
969 GNULIB_MALLOC_POSIX
970 GNULIB_GRANTPT
971 GNULIB_GETSUBOPT
972 GNULIB_GETLOADAVG
973 GNULIB_CANONICALIZE_FILE_NAME
974 GNULIB_CALLOC_POSIX
975 GNULIB_ATOLL
976 GNULIB__EXIT
977 GL_GENERATE_EXECINFO_H_FALSE
978 GL_GENERATE_EXECINFO_H_TRUE
979 LIB_EXECINFO
980 EXECINFO_H
981 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
982 UNISTD_H_HAVE_WINSOCK2_H
983 REPLACE_WRITE
984 REPLACE_USLEEP
985 REPLACE_UNLINKAT
986 REPLACE_UNLINK
987 REPLACE_TTYNAME_R
988 REPLACE_SYMLINK
989 REPLACE_SLEEP
990 REPLACE_RMDIR
991 REPLACE_READLINK
992 REPLACE_READ
993 REPLACE_PWRITE
994 REPLACE_PREAD
995 REPLACE_LSEEK
996 REPLACE_LINKAT
997 REPLACE_LINK
998 REPLACE_LCHOWN
999 REPLACE_ISATTY
1000 REPLACE_GETPAGESIZE
1001 REPLACE_GETGROUPS
1002 REPLACE_GETLOGIN_R
1003 REPLACE_GETDOMAINNAME
1004 REPLACE_GETCWD
1005 REPLACE_FTRUNCATE
1006 REPLACE_FCHOWNAT
1007 REPLACE_DUP2
1008 REPLACE_DUP
1009 REPLACE_CLOSE
1010 REPLACE_CHOWN
1011 HAVE_SYS_PARAM_H
1012 HAVE_OS_H
1013 HAVE_DECL_TTYNAME_R
1014 HAVE_DECL_SETHOSTNAME
1015 HAVE_DECL_GETUSERSHELL
1016 HAVE_DECL_GETPAGESIZE
1017 HAVE_DECL_GETLOGIN_R
1018 HAVE_DECL_GETDOMAINNAME
1019 HAVE_DECL_FDATASYNC
1020 HAVE_DECL_FCHDIR
1021 HAVE_DECL_ENVIRON
1022 HAVE_USLEEP
1023 HAVE_UNLINKAT
1024 HAVE_SYMLINKAT
1025 HAVE_SYMLINK
1026 HAVE_SLEEP
1027 HAVE_SETHOSTNAME
1028 HAVE_READLINKAT
1029 HAVE_READLINK
1030 HAVE_PWRITE
1031 HAVE_PREAD
1032 HAVE_PIPE2
1033 HAVE_PIPE
1034 HAVE_LINKAT
1035 HAVE_LINK
1036 HAVE_LCHOWN
1037 HAVE_GROUP_MEMBER
1038 HAVE_GETPAGESIZE
1039 HAVE_GETLOGIN
1040 HAVE_GETHOSTNAME
1041 HAVE_GETGROUPS
1042 HAVE_GETDTABLESIZE
1043 HAVE_FTRUNCATE
1044 HAVE_FSYNC
1045 HAVE_FDATASYNC
1046 HAVE_FCHOWNAT
1047 HAVE_FCHDIR
1048 HAVE_FACCESSAT
1049 HAVE_EUIDACCESS
1050 HAVE_DUP3
1051 HAVE_DUP2
1052 HAVE_CHOWN
1053 GNULIB_WRITE
1054 GNULIB_USLEEP
1055 GNULIB_UNLINKAT
1056 GNULIB_UNLINK
1057 GNULIB_UNISTD_H_SIGPIPE
1058 GNULIB_UNISTD_H_NONBLOCKING
1059 GNULIB_TTYNAME_R
1060 GNULIB_SYMLINKAT
1061 GNULIB_SYMLINK
1062 GNULIB_SLEEP
1063 GNULIB_SETHOSTNAME
1064 GNULIB_RMDIR
1065 GNULIB_READLINKAT
1066 GNULIB_READLINK
1067 GNULIB_READ
1068 GNULIB_PWRITE
1069 GNULIB_PREAD
1070 GNULIB_PIPE2
1071 GNULIB_PIPE
1072 GNULIB_LSEEK
1073 GNULIB_LINKAT
1074 GNULIB_LINK
1075 GNULIB_LCHOWN
1076 GNULIB_ISATTY
1077 GNULIB_GROUP_MEMBER
1078 GNULIB_GETUSERSHELL
1079 GNULIB_GETPAGESIZE
1080 GNULIB_GETLOGIN_R
1081 GNULIB_GETLOGIN
1082 GNULIB_GETHOSTNAME
1083 GNULIB_GETGROUPS
1084 GNULIB_GETDTABLESIZE
1085 GNULIB_GETDOMAINNAME
1086 GNULIB_GETCWD
1087 GNULIB_FTRUNCATE
1088 GNULIB_FSYNC
1089 GNULIB_FDATASYNC
1090 GNULIB_FCHOWNAT
1091 GNULIB_FCHDIR
1092 GNULIB_FACCESSAT
1093 GNULIB_EUIDACCESS
1094 GNULIB_ENVIRON
1095 GNULIB_DUP3
1096 GNULIB_DUP2
1097 GNULIB_DUP
1098 GNULIB_CLOSE
1099 GNULIB_CHOWN
1100 GNULIB_CHDIR
1101 LIB_CLOCK_GETTIME
1102 GL_GENERATE_ALLOCA_H_FALSE
1103 GL_GENERATE_ALLOCA_H_TRUE
1104 ALLOCA_H
1105 ALLOCA
1106 GL_COND_LIBTOOL_FALSE
1107 GL_COND_LIBTOOL_TRUE
1108 POST_ALLOC_OBJ
1109 PRE_ALLOC_OBJ
1110 CYGWIN_OBJ
1111 RALLOC_OBJ
1112 OLDXMENU_DEPS
1113 LIBX_OTHER
1114 LIBXMENU
1115 OLDXMENU
1116 OLDXMENU_TARGET
1117 LIBXT_OTHER
1118 TOOLKIT_LIBW
1119 WIDGET_OBJ
1120 XOBJ
1121 XMENU_OBJ
1122 FONT_OBJ
1123 OTHER_FILES
1124 GNU_OBJC_CFLAGS
1125 ns_appsrc
1126 ns_appresdir
1127 ns_appbindir
1128 ns_appdir
1129 X_TOOLKIT_TYPE
1130 GNUSTEP_CFLAGS
1131 C_SWITCH_X_SITE
1132 LD_SWITCH_X_SITE
1133 gameuser
1134 gamedir
1135 bitmapdir
1136 archlibdir
1137 etcdir
1138 x_default_search_path
1139 lisppath
1140 locallisppath
1141 standardlisppath
1142 leimdir
1143 lispdir
1144 srcdir
1145 canonical
1146 configuration
1147 version
1148 copyright
1149 KRB4LIB
1150 DESLIB
1151 KRB5LIB
1152 CRYPTOLIB
1153 COM_ERRLIB
1154 LIBRESOLV
1155 LIBHESIOD
1156 TERMCAP_OBJ
1157 LIBS_TERMCAP
1158 BLESSMAIL_TARGET
1159 LIBS_MAIL
1160 liblockfile
1161 LIBXML2_LIBS
1162 LIBXML2_CFLAGS
1163 LIBXSM
1164 LIBGPM
1165 LIBGIF
1166 LIBTIFF
1167 LIBPNG
1168 LIBJPEG
1169 LIBXPM
1170 M17N_FLT_LIBS
1171 M17N_FLT_CFLAGS
1172 LIBOTF_LIBS
1173 LIBOTF_CFLAGS
1174 FREETYPE_LIBS
1175 FREETYPE_CFLAGS
1176 XFT_LIBS
1177 XFT_CFLAGS
1178 FONTCONFIG_LIBS
1179 FONTCONFIG_CFLAGS
1180 LIBXMU
1181 LIBXTR6
1182 LIBGNUTLS_LIBS
1183 LIBGNUTLS_CFLAGS
1184 LIBSELINUX_LIBS
1185 SETTINGS_LIBS
1186 SETTINGS_CFLAGS
1187 GOBJECT_LIBS
1188 GOBJECT_CFLAGS
1189 GCONF_LIBS
1190 GCONF_CFLAGS
1191 GSETTINGS_LIBS
1192 GSETTINGS_CFLAGS
1193 DBUS_OBJ
1194 DBUS_LIBS
1195 DBUS_CFLAGS
1196 GTK_OBJ
1197 GTK_LIBS
1198 GTK_CFLAGS
1199 IMAGEMAGICK_LIBS
1200 IMAGEMAGICK_CFLAGS
1201 RSVG_LIBS
1202 RSVG_CFLAGS
1203 LIB_PTHREAD
1204 VMLIMIT_OBJ
1205 GMALLOC_OBJ
1206 HAVE_XSERVER
1207 W32_LIBS
1208 W32_OBJ
1209 LIB_STANDARD
1210 NS_OBJC_OBJ
1211 NS_OBJ
1212 ns_self_contained
1213 INSTALL_ARCH_INDEP_EXTRA
1214 TEMACS_LDFLAGS2
1215 LD_SWITCH_X_SITE_RPATH
1216 XMKMF
1217 DEPFLAGS
1218 MKDEPDIR
1219 CFLAGS_SOUND
1220 ALSA_LIBS
1221 ALSA_CFLAGS
1222 LIBSOUND
1223 PKG_CONFIG
1224 CRT_DIR
1225 START_FILES
1226 LIB_MATH
1227 LIBS_SYSTEM
1228 C_SWITCH_SYSTEM
1229 UNEXEC_OBJ
1230 C_SWITCH_MACHINE
1231 LD_SWITCH_SYSTEM
1232 CANNOT_DUMP
1233 INFO_OPTS
1234 INFO_EXT
1235 HAVE_MAKEINFO
1236 PAXCTL
1237 GZIP_PROG
1238 INSTALL_INFO
1239 LN_S
1240 GNULIB_WARN_CFLAGS
1241 WARN_CFLAGS
1242 WERROR_CFLAGS
1243 RANLIB
1244 ARFLAGS
1245 AR
1246 EGREP
1247 GREP
1248 CPP
1249 am__fastdepCC_FALSE
1250 am__fastdepCC_TRUE
1251 CCDEPMODE
1252 AMDEPBACKSLASH
1253 AMDEP_FALSE
1254 AMDEP_TRUE
1255 am__quote
1256 am__include
1257 DEPDIR
1258 OBJEXT
1259 EXEEXT
1260 ac_ct_CC
1261 CPPFLAGS
1262 LDFLAGS
1263 CFLAGS
1264 CC
1265 host_os
1266 host_vendor
1267 host_cpu
1268 host
1269 build_os
1270 build_vendor
1271 build_cpu
1272 build
1273 PROFILING_CFLAGS
1274 GZIP_INFO
1275 cache_file
1276 am__untar
1277 am__tar
1278 AMTAR
1279 am__leading_dot
1280 SET_MAKE
1281 AWK
1282 mkdir_p
1283 MKDIR_P
1284 INSTALL_STRIP_PROGRAM
1285 STRIP
1286 install_sh
1287 MAKEINFO
1288 AUTOHEADER
1289 AUTOMAKE
1290 AUTOCONF
1291 ACLOCAL
1292 VERSION
1293 PACKAGE
1294 CYGPATH_W
1295 am__isrc
1296 INSTALL_DATA
1297 INSTALL_SCRIPT
1298 INSTALL_PROGRAM
1299 target_alias
1300 host_alias
1301 build_alias
1302 LIBS
1303 ECHO_T
1304 ECHO_N
1305 ECHO_C
1306 DEFS
1307 mandir
1308 localedir
1309 libdir
1310 psdir
1311 pdfdir
1312 dvidir
1313 htmldir
1314 infodir
1315 docdir
1316 oldincludedir
1317 includedir
1318 localstatedir
1319 sharedstatedir
1320 sysconfdir
1321 datadir
1322 datarootdir
1323 libexecdir
1324 sbindir
1325 bindir
1326 program_transform_name
1327 prefix
1328 exec_prefix
1329 PACKAGE_URL
1330 PACKAGE_BUGREPORT
1331 PACKAGE_STRING
1332 PACKAGE_VERSION
1333 PACKAGE_TARNAME
1334 PACKAGE_NAME
1335 PATH_SEPARATOR
1336 SHELL'
1337 ac_subst_files='deps_frag
1338 lisp_frag'
1339 ac_user_opts='
1340 enable_option_checking
1341 with_all
1342 with_pop
1343 with_kerberos
1344 with_kerberos5
1345 with_hesiod
1346 with_mmdf
1347 with_mail_unlink
1348 with_mailhost
1349 with_sound
1350 with_x_toolkit
1351 with_wide_int
1352 with_xpm
1353 with_jpeg
1354 with_tiff
1355 with_gif
1356 with_png
1357 with_rsvg
1358 with_xml2
1359 with_imagemagick
1360 with_xft
1361 with_libotf
1362 with_m17n_flt
1363 with_toolkit_scroll_bars
1364 with_xaw3d
1365 with_xim
1366 with_ns
1367 with_w32
1368 with_gpm
1369 with_dbus
1370 with_gconf
1371 with_gsettings
1372 with_selinux
1373 with_gnutls
1374 with_makeinfo
1375 with_compress_info
1376 with_pkg_config_prog
1377 with_crt_dir
1378 with_gameuser
1379 with_gnustep_conf
1380 enable_ns_self_contained
1381 enable_locallisppath
1382 enable_checking
1383 enable_check_lisp_object_type
1384 enable_profiling
1385 enable_autodepend
1386 enable_dependency_tracking
1387 enable_largefile
1388 enable_gcc_warnings
1389 enable_link_time_optimization
1390 with_x
1391 '
1392 ac_precious_vars='build_alias
1393 host_alias
1394 target_alias
1395 CC
1396 CFLAGS
1397 LDFLAGS
1398 LIBS
1399 CPPFLAGS
1400 CPP
1401 XMKMF'
1402
1403
1404 # Initialize some variables set by options.
1405 ac_init_help=
1406 ac_init_version=false
1407 ac_unrecognized_opts=
1408 ac_unrecognized_sep=
1409 # The variables have the same names as the options, with
1410 # dashes changed to underlines.
1411 cache_file=/dev/null
1412 exec_prefix=NONE
1413 no_create=
1414 no_recursion=
1415 prefix=NONE
1416 program_prefix=NONE
1417 program_suffix=NONE
1418 program_transform_name=s,x,x,
1419 silent=
1420 site=
1421 srcdir=
1422 verbose=
1423 x_includes=NONE
1424 x_libraries=NONE
1425
1426 # Installation directory options.
1427 # These are left unexpanded so users can "make install exec_prefix=/foo"
1428 # and all the variables that are supposed to be based on exec_prefix
1429 # by default will actually change.
1430 # Use braces instead of parens because sh, perl, etc. also accept them.
1431 # (The list follows the same order as the GNU Coding Standards.)
1432 bindir='${exec_prefix}/bin'
1433 sbindir='${exec_prefix}/sbin'
1434 libexecdir='${exec_prefix}/libexec'
1435 datarootdir='${prefix}/share'
1436 datadir='${datarootdir}'
1437 sysconfdir='${prefix}/etc'
1438 sharedstatedir='${prefix}/com'
1439 localstatedir='${prefix}/var'
1440 includedir='${prefix}/include'
1441 oldincludedir='/usr/include'
1442 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1443 infodir='${datarootdir}/info'
1444 htmldir='${docdir}'
1445 dvidir='${docdir}'
1446 pdfdir='${docdir}'
1447 psdir='${docdir}'
1448 libdir='${exec_prefix}/lib'
1449 localedir='${datarootdir}/locale'
1450 mandir='${datarootdir}/man'
1451
1452 ac_prev=
1453 ac_dashdash=
1454 for ac_option
1455 do
1456 # If the previous option needs an argument, assign it.
1457 if test -n "$ac_prev"; then
1458 eval $ac_prev=\$ac_option
1459 ac_prev=
1460 continue
1461 fi
1462
1463 case $ac_option in
1464 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1465 *) ac_optarg=yes ;;
1466 esac
1467
1468 # Accept the important Cygnus configure options, so we can diagnose typos.
1469
1470 case $ac_dashdash$ac_option in
1471 --)
1472 ac_dashdash=yes ;;
1473
1474 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1475 ac_prev=bindir ;;
1476 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1477 bindir=$ac_optarg ;;
1478
1479 -build | --build | --buil | --bui | --bu)
1480 ac_prev=build_alias ;;
1481 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1482 build_alias=$ac_optarg ;;
1483
1484 -cache-file | --cache-file | --cache-fil | --cache-fi \
1485 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1486 ac_prev=cache_file ;;
1487 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1488 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1489 cache_file=$ac_optarg ;;
1490
1491 --config-cache | -C)
1492 cache_file=config.cache ;;
1493
1494 -datadir | --datadir | --datadi | --datad)
1495 ac_prev=datadir ;;
1496 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1497 datadir=$ac_optarg ;;
1498
1499 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1500 | --dataroo | --dataro | --datar)
1501 ac_prev=datarootdir ;;
1502 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1503 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1504 datarootdir=$ac_optarg ;;
1505
1506 -disable-* | --disable-*)
1507 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1508 # Reject names that are not valid shell variable names.
1509 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1510 as_fn_error "invalid feature name: $ac_useropt"
1511 ac_useropt_orig=$ac_useropt
1512 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1513 case $ac_user_opts in
1514 *"
1515 "enable_$ac_useropt"
1516 "*) ;;
1517 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1518 ac_unrecognized_sep=', ';;
1519 esac
1520 eval enable_$ac_useropt=no ;;
1521
1522 -docdir | --docdir | --docdi | --doc | --do)
1523 ac_prev=docdir ;;
1524 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1525 docdir=$ac_optarg ;;
1526
1527 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1528 ac_prev=dvidir ;;
1529 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1530 dvidir=$ac_optarg ;;
1531
1532 -enable-* | --enable-*)
1533 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1534 # Reject names that are not valid shell variable names.
1535 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1536 as_fn_error "invalid feature name: $ac_useropt"
1537 ac_useropt_orig=$ac_useropt
1538 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1539 case $ac_user_opts in
1540 *"
1541 "enable_$ac_useropt"
1542 "*) ;;
1543 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1544 ac_unrecognized_sep=', ';;
1545 esac
1546 eval enable_$ac_useropt=\$ac_optarg ;;
1547
1548 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1549 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1550 | --exec | --exe | --ex)
1551 ac_prev=exec_prefix ;;
1552 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1553 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1554 | --exec=* | --exe=* | --ex=*)
1555 exec_prefix=$ac_optarg ;;
1556
1557 -gas | --gas | --ga | --g)
1558 # Obsolete; use --with-gas.
1559 with_gas=yes ;;
1560
1561 -help | --help | --hel | --he | -h)
1562 ac_init_help=long ;;
1563 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1564 ac_init_help=recursive ;;
1565 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1566 ac_init_help=short ;;
1567
1568 -host | --host | --hos | --ho)
1569 ac_prev=host_alias ;;
1570 -host=* | --host=* | --hos=* | --ho=*)
1571 host_alias=$ac_optarg ;;
1572
1573 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1574 ac_prev=htmldir ;;
1575 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1576 | --ht=*)
1577 htmldir=$ac_optarg ;;
1578
1579 -includedir | --includedir | --includedi | --included | --include \
1580 | --includ | --inclu | --incl | --inc)
1581 ac_prev=includedir ;;
1582 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1583 | --includ=* | --inclu=* | --incl=* | --inc=*)
1584 includedir=$ac_optarg ;;
1585
1586 -infodir | --infodir | --infodi | --infod | --info | --inf)
1587 ac_prev=infodir ;;
1588 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1589 infodir=$ac_optarg ;;
1590
1591 -libdir | --libdir | --libdi | --libd)
1592 ac_prev=libdir ;;
1593 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1594 libdir=$ac_optarg ;;
1595
1596 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1597 | --libexe | --libex | --libe)
1598 ac_prev=libexecdir ;;
1599 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1600 | --libexe=* | --libex=* | --libe=*)
1601 libexecdir=$ac_optarg ;;
1602
1603 -localedir | --localedir | --localedi | --localed | --locale)
1604 ac_prev=localedir ;;
1605 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1606 localedir=$ac_optarg ;;
1607
1608 -localstatedir | --localstatedir | --localstatedi | --localstated \
1609 | --localstate | --localstat | --localsta | --localst | --locals)
1610 ac_prev=localstatedir ;;
1611 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1612 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1613 localstatedir=$ac_optarg ;;
1614
1615 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1616 ac_prev=mandir ;;
1617 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1618 mandir=$ac_optarg ;;
1619
1620 -nfp | --nfp | --nf)
1621 # Obsolete; use --without-fp.
1622 with_fp=no ;;
1623
1624 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1625 | --no-cr | --no-c | -n)
1626 no_create=yes ;;
1627
1628 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1629 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1630 no_recursion=yes ;;
1631
1632 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1633 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1634 | --oldin | --oldi | --old | --ol | --o)
1635 ac_prev=oldincludedir ;;
1636 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1637 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1638 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1639 oldincludedir=$ac_optarg ;;
1640
1641 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1642 ac_prev=prefix ;;
1643 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1644 prefix=$ac_optarg ;;
1645
1646 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1647 | --program-pre | --program-pr | --program-p)
1648 ac_prev=program_prefix ;;
1649 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1650 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1651 program_prefix=$ac_optarg ;;
1652
1653 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1654 | --program-suf | --program-su | --program-s)
1655 ac_prev=program_suffix ;;
1656 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1657 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1658 program_suffix=$ac_optarg ;;
1659
1660 -program-transform-name | --program-transform-name \
1661 | --program-transform-nam | --program-transform-na \
1662 | --program-transform-n | --program-transform- \
1663 | --program-transform | --program-transfor \
1664 | --program-transfo | --program-transf \
1665 | --program-trans | --program-tran \
1666 | --progr-tra | --program-tr | --program-t)
1667 ac_prev=program_transform_name ;;
1668 -program-transform-name=* | --program-transform-name=* \
1669 | --program-transform-nam=* | --program-transform-na=* \
1670 | --program-transform-n=* | --program-transform-=* \
1671 | --program-transform=* | --program-transfor=* \
1672 | --program-transfo=* | --program-transf=* \
1673 | --program-trans=* | --program-tran=* \
1674 | --progr-tra=* | --program-tr=* | --program-t=*)
1675 program_transform_name=$ac_optarg ;;
1676
1677 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1678 ac_prev=pdfdir ;;
1679 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1680 pdfdir=$ac_optarg ;;
1681
1682 -psdir | --psdir | --psdi | --psd | --ps)
1683 ac_prev=psdir ;;
1684 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1685 psdir=$ac_optarg ;;
1686
1687 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1688 | -silent | --silent | --silen | --sile | --sil)
1689 silent=yes ;;
1690
1691 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1692 ac_prev=sbindir ;;
1693 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1694 | --sbi=* | --sb=*)
1695 sbindir=$ac_optarg ;;
1696
1697 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1698 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1699 | --sharedst | --shareds | --shared | --share | --shar \
1700 | --sha | --sh)
1701 ac_prev=sharedstatedir ;;
1702 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1703 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1704 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1705 | --sha=* | --sh=*)
1706 sharedstatedir=$ac_optarg ;;
1707
1708 -site | --site | --sit)
1709 ac_prev=site ;;
1710 -site=* | --site=* | --sit=*)
1711 site=$ac_optarg ;;
1712
1713 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1714 ac_prev=srcdir ;;
1715 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1716 srcdir=$ac_optarg ;;
1717
1718 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1719 | --syscon | --sysco | --sysc | --sys | --sy)
1720 ac_prev=sysconfdir ;;
1721 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1722 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1723 sysconfdir=$ac_optarg ;;
1724
1725 -target | --target | --targe | --targ | --tar | --ta | --t)
1726 ac_prev=target_alias ;;
1727 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1728 target_alias=$ac_optarg ;;
1729
1730 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1731 verbose=yes ;;
1732
1733 -version | --version | --versio | --versi | --vers | -V)
1734 ac_init_version=: ;;
1735
1736 -with-* | --with-*)
1737 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1738 # Reject names that are not valid shell variable names.
1739 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1740 as_fn_error "invalid package name: $ac_useropt"
1741 ac_useropt_orig=$ac_useropt
1742 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1743 case $ac_user_opts in
1744 *"
1745 "with_$ac_useropt"
1746 "*) ;;
1747 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1748 ac_unrecognized_sep=', ';;
1749 esac
1750 eval with_$ac_useropt=\$ac_optarg ;;
1751
1752 -without-* | --without-*)
1753 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1754 # Reject names that are not valid shell variable names.
1755 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1756 as_fn_error "invalid package name: $ac_useropt"
1757 ac_useropt_orig=$ac_useropt
1758 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1759 case $ac_user_opts in
1760 *"
1761 "with_$ac_useropt"
1762 "*) ;;
1763 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1764 ac_unrecognized_sep=', ';;
1765 esac
1766 eval with_$ac_useropt=no ;;
1767
1768 --x)
1769 # Obsolete; use --with-x.
1770 with_x=yes ;;
1771
1772 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1773 | --x-incl | --x-inc | --x-in | --x-i)
1774 ac_prev=x_includes ;;
1775 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1776 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1777 x_includes=$ac_optarg ;;
1778
1779 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1780 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1781 ac_prev=x_libraries ;;
1782 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1783 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1784 x_libraries=$ac_optarg ;;
1785
1786 -*) as_fn_error "unrecognized option: \`$ac_option'
1787 Try \`$0 --help' for more information."
1788 ;;
1789
1790 *=*)
1791 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1792 # Reject names that are not valid shell variable names.
1793 case $ac_envvar in #(
1794 '' | [0-9]* | *[!_$as_cr_alnum]* )
1795 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1796 esac
1797 eval $ac_envvar=\$ac_optarg
1798 export $ac_envvar ;;
1799
1800 *)
1801 # FIXME: should be removed in autoconf 3.0.
1802 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1803 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1804 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1805 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1806 ;;
1807
1808 esac
1809 done
1810
1811 if test -n "$ac_prev"; then
1812 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1813 as_fn_error "missing argument to $ac_option"
1814 fi
1815
1816 if test -n "$ac_unrecognized_opts"; then
1817 case $enable_option_checking in
1818 no) ;;
1819 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1820 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1821 esac
1822 fi
1823
1824 # Check all directory arguments for consistency.
1825 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1826 datadir sysconfdir sharedstatedir localstatedir includedir \
1827 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1828 libdir localedir mandir
1829 do
1830 eval ac_val=\$$ac_var
1831 # Remove trailing slashes.
1832 case $ac_val in
1833 */ )
1834 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1835 eval $ac_var=\$ac_val;;
1836 esac
1837 # Be sure to have absolute directory names.
1838 case $ac_val in
1839 [\\/$]* | ?:[\\/]* ) continue;;
1840 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1841 esac
1842 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1843 done
1844
1845 # There might be people who depend on the old broken behavior: `$host'
1846 # used to hold the argument of --host etc.
1847 # FIXME: To remove some day.
1848 build=$build_alias
1849 host=$host_alias
1850 target=$target_alias
1851
1852 # FIXME: To remove some day.
1853 if test "x$host_alias" != x; then
1854 if test "x$build_alias" = x; then
1855 cross_compiling=maybe
1856 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1857 If a cross compiler is detected then cross compile mode will be used." >&2
1858 elif test "x$build_alias" != "x$host_alias"; then
1859 cross_compiling=yes
1860 fi
1861 fi
1862
1863 ac_tool_prefix=
1864 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1865
1866 test "$silent" = yes && exec 6>/dev/null
1867
1868
1869 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1870 ac_ls_di=`ls -di .` &&
1871 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1872 as_fn_error "working directory cannot be determined"
1873 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1874 as_fn_error "pwd does not report name of working directory"
1875
1876
1877 # Find the source files, if location was not specified.
1878 if test -z "$srcdir"; then
1879 ac_srcdir_defaulted=yes
1880 # Try the directory containing this script, then the parent directory.
1881 ac_confdir=`$as_dirname -- "$as_myself" ||
1882 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1883 X"$as_myself" : 'X\(//\)[^/]' \| \
1884 X"$as_myself" : 'X\(//\)$' \| \
1885 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1886 $as_echo X"$as_myself" |
1887 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1888 s//\1/
1889 q
1890 }
1891 /^X\(\/\/\)[^/].*/{
1892 s//\1/
1893 q
1894 }
1895 /^X\(\/\/\)$/{
1896 s//\1/
1897 q
1898 }
1899 /^X\(\/\).*/{
1900 s//\1/
1901 q
1902 }
1903 s/.*/./; q'`
1904 srcdir=$ac_confdir
1905 if test ! -r "$srcdir/$ac_unique_file"; then
1906 srcdir=..
1907 fi
1908 else
1909 ac_srcdir_defaulted=no
1910 fi
1911 if test ! -r "$srcdir/$ac_unique_file"; then
1912 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1913 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1914 fi
1915 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1916 ac_abs_confdir=`(
1917 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1918 pwd)`
1919 # When building in place, set srcdir=.
1920 if test "$ac_abs_confdir" = "$ac_pwd"; then
1921 srcdir=.
1922 fi
1923 # Remove unnecessary trailing slashes from srcdir.
1924 # Double slashes in file names in object file debugging info
1925 # mess up M-x gdb in Emacs.
1926 case $srcdir in
1927 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1928 esac
1929 for ac_var in $ac_precious_vars; do
1930 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1931 eval ac_env_${ac_var}_value=\$${ac_var}
1932 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1933 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1934 done
1935
1936 #
1937 # Report the --help message.
1938 #
1939 if test "$ac_init_help" = "long"; then
1940 # Omit some internal or obsolete options to make the list less imposing.
1941 # This message is too long to be a string in the A/UX 3.1 sh.
1942 cat <<_ACEOF
1943 \`configure' configures emacs 24.2.50 to adapt to many kinds of systems.
1944
1945 Usage: $0 [OPTION]... [VAR=VALUE]...
1946
1947 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1948 VAR=VALUE. See below for descriptions of some of the useful variables.
1949
1950 Defaults for the options are specified in brackets.
1951
1952 Configuration:
1953 -h, --help display this help and exit
1954 --help=short display options specific to this package
1955 --help=recursive display the short help of all the included packages
1956 -V, --version display version information and exit
1957 -q, --quiet, --silent do not print \`checking...' messages
1958 --cache-file=FILE cache test results in FILE [disabled]
1959 -C, --config-cache alias for \`--cache-file=config.cache'
1960 -n, --no-create do not create output files
1961 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1962
1963 Installation directories:
1964 --prefix=PREFIX install architecture-independent files in PREFIX
1965 [$ac_default_prefix]
1966 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1967 [PREFIX]
1968
1969 By default, \`make install' will install all the files in
1970 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1971 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1972 for instance \`--prefix=\$HOME'.
1973
1974 For better control, use the options below.
1975
1976 Fine tuning of the installation directories:
1977 --bindir=DIR user executables [EPREFIX/bin]
1978 --sbindir=DIR system admin executables [EPREFIX/sbin]
1979 --libexecdir=DIR program executables [EPREFIX/libexec]
1980 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1981 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1982 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1983 --libdir=DIR object code libraries [EPREFIX/lib]
1984 --includedir=DIR C header files [PREFIX/include]
1985 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1986 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1987 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1988 --infodir=DIR info documentation [DATAROOTDIR/info]
1989 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1990 --mandir=DIR man documentation [DATAROOTDIR/man]
1991 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1992 --htmldir=DIR html documentation [DOCDIR]
1993 --dvidir=DIR dvi documentation [DOCDIR]
1994 --pdfdir=DIR pdf documentation [DOCDIR]
1995 --psdir=DIR ps documentation [DOCDIR]
1996 _ACEOF
1997
1998 cat <<\_ACEOF
1999
2000 Program names:
2001 --program-prefix=PREFIX prepend PREFIX to installed program names
2002 --program-suffix=SUFFIX append SUFFIX to installed program names
2003 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2004
2005 X features:
2006 --x-includes=DIR X include files are in DIR
2007 --x-libraries=DIR X library files are in DIR
2008
2009 System types:
2010 --build=BUILD configure for building on BUILD [guessed]
2011 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2012 _ACEOF
2013 fi
2014
2015 if test -n "$ac_init_help"; then
2016 case $ac_init_help in
2017 short | recursive ) echo "Configuration of emacs 24.2.50:";;
2018 esac
2019 cat <<\_ACEOF
2020
2021 Optional Features:
2022 --disable-option-checking ignore unrecognized --enable/--with options
2023 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2024 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2025 --disable-ns-self-contained
2026 disable self contained build under NeXTstep
2027 --enable-locallisppath=PATH
2028 directories Emacs should search for lisp files
2029 specific to this site
2030 --enable-checking[=LIST]
2031 enable expensive run-time checks. With LIST, enable
2032 only specific categories of checks. Categories are:
2033 all,yes,no. Flags are: stringbytes, stringoverrun,
2034 stringfreelist, xmallocoverrun, conslist, glyphs
2035 --enable-check-lisp-object-type
2036 enable compile time checks for the Lisp_Object data
2037 type. This is useful for development for catching
2038 certain types of bugs.
2039 --enable-profiling build emacs with profiling support. This might not
2040 work on all platforms
2041 --enable-autodepend automatically generate dependencies to .h-files.
2042 Requires GNU Make and Gcc. Enabled if GNU Make and
2043 Gcc is found
2044 --disable-dependency-tracking speeds up one-time build
2045 --enable-dependency-tracking do not reject slow dependency extractors
2046 --disable-largefile omit support for large files
2047 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2048 developers, and may generate false alarms when used
2049 with older or non-GNU development tools.
2050 --enable-link-time-optimization
2051 build emacs with link-time optimization. This is
2052 supported only for GCC since 4.5.0.
2053
2054 Optional Packages:
2055 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2056 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2057 --without-all omit almost all features and build small executable
2058 with minimal dependencies
2059 --without-pop don't support POP mail retrieval with movemail
2060 --with-kerberos support Kerberos-authenticated POP
2061 --with-kerberos5 support Kerberos version 5 authenticated POP
2062 --with-hesiod support Hesiod to get the POP server host
2063 --with-mmdf support MMDF mailboxes
2064 --with-mail-unlink unlink, rather than empty, mail spool after reading
2065 --with-mailhost=HOSTNAME
2066 string giving default POP mail host
2067 --without-sound don't compile with sound support
2068 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2069 gtk3, lucid or athena, motif, no)
2070 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2071 --without-xpm don't compile with XPM image support
2072 --without-jpeg don't compile with JPEG image support
2073 --without-tiff don't compile with TIFF image support
2074 --without-gif don't compile with GIF image support
2075 --without-png don't compile with PNG image support
2076 --without-rsvg don't compile with SVG image support
2077 --without-xml2 don't compile with XML parsing support
2078 --without-imagemagick don't compile with ImageMagick image support
2079 --without-xft don't use XFT for anti aliased fonts
2080 --without-libotf don't use libotf for OpenType font support
2081 --without-m17n-flt don't use m17n-flt for text shaping
2082 --without-toolkit-scroll-bars
2083 don't use Motif or Xaw3d scroll bars
2084 --without-xaw3d don't use Xaw3d
2085 --without-xim don't use X11 XIM
2086 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2087 --with-w32 use native Windows GUI
2088 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2089 console
2090 --without-dbus don't compile with D-Bus support
2091 --without-gconf don't compile with GConf support
2092 --without-gsettings don't compile with GSettings support
2093 --without-selinux don't compile with SELinux support
2094 --without-gnutls don't use -lgnutls for SSL/TLS support
2095 --without-makeinfo don't require makeinfo for building manuals
2096 --without-compress-info don't compress the installed Info pages
2097 --with-pkg-config-prog=PATH
2098 path to pkg-config for finding GTK and librsvg
2099 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2100 /usr/lib, or /usr/lib64 on some platforms.
2101 --with-gameuser=USER user for shared game score files
2102 --with-gnustep-conf=PATH
2103 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2104 or /etc/GNUstep/GNUstep.conf
2105 --with-x use the X Window System
2106
2107 Some influential environment variables:
2108 CC C compiler command
2109 CFLAGS C compiler flags
2110 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2111 nonstandard directory <lib dir>
2112 LIBS libraries to pass to the linker, e.g. -l<library>
2113 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2114 you have headers in a nonstandard directory <include dir>
2115 CPP C preprocessor
2116 XMKMF Path to xmkmf, Makefile generator for X Window System
2117
2118 Use these variables to override the choices made by `configure' or to help
2119 it to find libraries and programs with nonstandard names/locations.
2120
2121 Report bugs to the package provider.
2122 _ACEOF
2123 ac_status=$?
2124 fi
2125
2126 if test "$ac_init_help" = "recursive"; then
2127 # If there are subdirs, report their specific --help.
2128 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2129 test -d "$ac_dir" ||
2130 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2131 continue
2132 ac_builddir=.
2133
2134 case "$ac_dir" in
2135 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2136 *)
2137 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2138 # A ".." for each directory in $ac_dir_suffix.
2139 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2140 case $ac_top_builddir_sub in
2141 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2142 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2143 esac ;;
2144 esac
2145 ac_abs_top_builddir=$ac_pwd
2146 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2147 # for backward compatibility:
2148 ac_top_builddir=$ac_top_build_prefix
2149
2150 case $srcdir in
2151 .) # We are building in place.
2152 ac_srcdir=.
2153 ac_top_srcdir=$ac_top_builddir_sub
2154 ac_abs_top_srcdir=$ac_pwd ;;
2155 [\\/]* | ?:[\\/]* ) # Absolute name.
2156 ac_srcdir=$srcdir$ac_dir_suffix;
2157 ac_top_srcdir=$srcdir
2158 ac_abs_top_srcdir=$srcdir ;;
2159 *) # Relative name.
2160 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2161 ac_top_srcdir=$ac_top_build_prefix$srcdir
2162 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2163 esac
2164 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2165
2166 cd "$ac_dir" || { ac_status=$?; continue; }
2167 # Check for guested configure.
2168 if test -f "$ac_srcdir/configure.gnu"; then
2169 echo &&
2170 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2171 elif test -f "$ac_srcdir/configure"; then
2172 echo &&
2173 $SHELL "$ac_srcdir/configure" --help=recursive
2174 else
2175 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2176 fi || ac_status=$?
2177 cd "$ac_pwd" || { ac_status=$?; break; }
2178 done
2179 fi
2180
2181 test -n "$ac_init_help" && exit $ac_status
2182 if $ac_init_version; then
2183 cat <<\_ACEOF
2184 emacs configure 24.2.50
2185 generated by GNU Autoconf 2.65
2186
2187 Copyright (C) 2009 Free Software Foundation, Inc.
2188 This configure script is free software; the Free Software Foundation
2189 gives unlimited permission to copy, distribute and modify it.
2190 _ACEOF
2191 exit
2192 fi
2193
2194 ## ------------------------ ##
2195 ## Autoconf initialization. ##
2196 ## ------------------------ ##
2197
2198 # ac_fn_c_try_compile LINENO
2199 # --------------------------
2200 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2201 ac_fn_c_try_compile ()
2202 {
2203 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2204 rm -f conftest.$ac_objext
2205 if { { ac_try="$ac_compile"
2206 case "(($ac_try" in
2207 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2208 *) ac_try_echo=$ac_try;;
2209 esac
2210 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2211 $as_echo "$ac_try_echo"; } >&5
2212 (eval "$ac_compile") 2>conftest.err
2213 ac_status=$?
2214 if test -s conftest.err; then
2215 grep -v '^ *+' conftest.err >conftest.er1
2216 cat conftest.er1 >&5
2217 mv -f conftest.er1 conftest.err
2218 fi
2219 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2220 test $ac_status = 0; } && {
2221 test -z "$ac_c_werror_flag" ||
2222 test ! -s conftest.err
2223 } && test -s conftest.$ac_objext; then :
2224 ac_retval=0
2225 else
2226 $as_echo "$as_me: failed program was:" >&5
2227 sed 's/^/| /' conftest.$ac_ext >&5
2228
2229 ac_retval=1
2230 fi
2231 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2232 as_fn_set_status $ac_retval
2233
2234 } # ac_fn_c_try_compile
2235
2236 # ac_fn_c_try_cpp LINENO
2237 # ----------------------
2238 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2239 ac_fn_c_try_cpp ()
2240 {
2241 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2242 if { { ac_try="$ac_cpp conftest.$ac_ext"
2243 case "(($ac_try" in
2244 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2245 *) ac_try_echo=$ac_try;;
2246 esac
2247 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2248 $as_echo "$ac_try_echo"; } >&5
2249 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2250 ac_status=$?
2251 if test -s conftest.err; then
2252 grep -v '^ *+' conftest.err >conftest.er1
2253 cat conftest.er1 >&5
2254 mv -f conftest.er1 conftest.err
2255 fi
2256 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2257 test $ac_status = 0; } >/dev/null && {
2258 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2259 test ! -s conftest.err
2260 }; then :
2261 ac_retval=0
2262 else
2263 $as_echo "$as_me: failed program was:" >&5
2264 sed 's/^/| /' conftest.$ac_ext >&5
2265
2266 ac_retval=1
2267 fi
2268 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2269 as_fn_set_status $ac_retval
2270
2271 } # ac_fn_c_try_cpp
2272
2273 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2274 # -------------------------------------------------------
2275 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2276 # the include files in INCLUDES and setting the cache variable VAR
2277 # accordingly.
2278 ac_fn_c_check_header_mongrel ()
2279 {
2280 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2281 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2283 $as_echo_n "checking for $2... " >&6; }
2284 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2285 $as_echo_n "(cached) " >&6
2286 fi
2287 eval ac_res=\$$3
2288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2289 $as_echo "$ac_res" >&6; }
2290 else
2291 # Is the header compilable?
2292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2293 $as_echo_n "checking $2 usability... " >&6; }
2294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2295 /* end confdefs.h. */
2296 $4
2297 #include <$2>
2298 _ACEOF
2299 if ac_fn_c_try_compile "$LINENO"; then :
2300 ac_header_compiler=yes
2301 else
2302 ac_header_compiler=no
2303 fi
2304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2306 $as_echo "$ac_header_compiler" >&6; }
2307
2308 # Is the header present?
2309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2310 $as_echo_n "checking $2 presence... " >&6; }
2311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2312 /* end confdefs.h. */
2313 #include <$2>
2314 _ACEOF
2315 if ac_fn_c_try_cpp "$LINENO"; then :
2316 ac_header_preproc=yes
2317 else
2318 ac_header_preproc=no
2319 fi
2320 rm -f conftest.err conftest.$ac_ext
2321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2322 $as_echo "$ac_header_preproc" >&6; }
2323
2324 # So? What about this header?
2325 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2326 yes:no: )
2327 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2328 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2330 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2331 ;;
2332 no:yes:* )
2333 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2334 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2335 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2336 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2337 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2338 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2339 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2340 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2341 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2342 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2343 ;;
2344 esac
2345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2346 $as_echo_n "checking for $2... " >&6; }
2347 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2348 $as_echo_n "(cached) " >&6
2349 else
2350 eval "$3=\$ac_header_compiler"
2351 fi
2352 eval ac_res=\$$3
2353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2354 $as_echo "$ac_res" >&6; }
2355 fi
2356 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2357
2358 } # ac_fn_c_check_header_mongrel
2359
2360 # ac_fn_c_try_run LINENO
2361 # ----------------------
2362 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2363 # that executables *can* be run.
2364 ac_fn_c_try_run ()
2365 {
2366 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2367 if { { ac_try="$ac_link"
2368 case "(($ac_try" in
2369 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2370 *) ac_try_echo=$ac_try;;
2371 esac
2372 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2373 $as_echo "$ac_try_echo"; } >&5
2374 (eval "$ac_link") 2>&5
2375 ac_status=$?
2376 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2377 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2378 { { case "(($ac_try" in
2379 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2380 *) ac_try_echo=$ac_try;;
2381 esac
2382 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2383 $as_echo "$ac_try_echo"; } >&5
2384 (eval "$ac_try") 2>&5
2385 ac_status=$?
2386 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2387 test $ac_status = 0; }; }; then :
2388 ac_retval=0
2389 else
2390 $as_echo "$as_me: program exited with status $ac_status" >&5
2391 $as_echo "$as_me: failed program was:" >&5
2392 sed 's/^/| /' conftest.$ac_ext >&5
2393
2394 ac_retval=$ac_status
2395 fi
2396 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2397 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2398 as_fn_set_status $ac_retval
2399
2400 } # ac_fn_c_try_run
2401
2402 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2403 # -------------------------------------------------------
2404 # Tests whether HEADER exists and can be compiled using the include files in
2405 # INCLUDES, setting the cache variable VAR accordingly.
2406 ac_fn_c_check_header_compile ()
2407 {
2408 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2410 $as_echo_n "checking for $2... " >&6; }
2411 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2412 $as_echo_n "(cached) " >&6
2413 else
2414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2415 /* end confdefs.h. */
2416 $4
2417 #include <$2>
2418 _ACEOF
2419 if ac_fn_c_try_compile "$LINENO"; then :
2420 eval "$3=yes"
2421 else
2422 eval "$3=no"
2423 fi
2424 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2425 fi
2426 eval ac_res=\$$3
2427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2428 $as_echo "$ac_res" >&6; }
2429 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2430
2431 } # ac_fn_c_check_header_compile
2432
2433 # ac_fn_c_try_link LINENO
2434 # -----------------------
2435 # Try to link conftest.$ac_ext, and return whether this succeeded.
2436 ac_fn_c_try_link ()
2437 {
2438 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2439 rm -f conftest.$ac_objext conftest$ac_exeext
2440 if { { ac_try="$ac_link"
2441 case "(($ac_try" in
2442 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2443 *) ac_try_echo=$ac_try;;
2444 esac
2445 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2446 $as_echo "$ac_try_echo"; } >&5
2447 (eval "$ac_link") 2>conftest.err
2448 ac_status=$?
2449 if test -s conftest.err; then
2450 grep -v '^ *+' conftest.err >conftest.er1
2451 cat conftest.er1 >&5
2452 mv -f conftest.er1 conftest.err
2453 fi
2454 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2455 test $ac_status = 0; } && {
2456 test -z "$ac_c_werror_flag" ||
2457 test ! -s conftest.err
2458 } && test -s conftest$ac_exeext && {
2459 test "$cross_compiling" = yes ||
2460 $as_test_x conftest$ac_exeext
2461 }; then :
2462 ac_retval=0
2463 else
2464 $as_echo "$as_me: failed program was:" >&5
2465 sed 's/^/| /' conftest.$ac_ext >&5
2466
2467 ac_retval=1
2468 fi
2469 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2470 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2471 # interfere with the next link command; also delete a directory that is
2472 # left behind by Apple's compiler. We do this before executing the actions.
2473 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2474 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2475 as_fn_set_status $ac_retval
2476
2477 } # ac_fn_c_try_link
2478
2479 # ac_fn_c_check_decl LINENO SYMBOL VAR
2480 # ------------------------------------
2481 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2482 ac_fn_c_check_decl ()
2483 {
2484 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2486 $as_echo_n "checking whether $2 is declared... " >&6; }
2487 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2488 $as_echo_n "(cached) " >&6
2489 else
2490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2491 /* end confdefs.h. */
2492 $4
2493 int
2494 main ()
2495 {
2496 #ifndef $2
2497 (void) $2;
2498 #endif
2499
2500 ;
2501 return 0;
2502 }
2503 _ACEOF
2504 if ac_fn_c_try_compile "$LINENO"; then :
2505 eval "$3=yes"
2506 else
2507 eval "$3=no"
2508 fi
2509 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2510 fi
2511 eval ac_res=\$$3
2512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2513 $as_echo "$ac_res" >&6; }
2514 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2515
2516 } # ac_fn_c_check_decl
2517
2518 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2519 # ----------------------------------------------
2520 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2521 ac_fn_c_check_header_preproc ()
2522 {
2523 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2525 $as_echo_n "checking for $2... " >&6; }
2526 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2527 $as_echo_n "(cached) " >&6
2528 else
2529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2530 /* end confdefs.h. */
2531 #include <$2>
2532 _ACEOF
2533 if ac_fn_c_try_cpp "$LINENO"; then :
2534 eval "$3=yes"
2535 else
2536 eval "$3=no"
2537 fi
2538 rm -f conftest.err conftest.$ac_ext
2539 fi
2540 eval ac_res=\$$3
2541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2542 $as_echo "$ac_res" >&6; }
2543 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2544
2545 } # ac_fn_c_check_header_preproc
2546
2547 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2548 # ----------------------------------------------------
2549 # Tries to find if the field MEMBER exists in type AGGR, after including
2550 # INCLUDES, setting cache variable VAR accordingly.
2551 ac_fn_c_check_member ()
2552 {
2553 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2555 $as_echo_n "checking for $2.$3... " >&6; }
2556 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2557 $as_echo_n "(cached) " >&6
2558 else
2559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2560 /* end confdefs.h. */
2561 $5
2562 int
2563 main ()
2564 {
2565 static $2 ac_aggr;
2566 if (ac_aggr.$3)
2567 return 0;
2568 ;
2569 return 0;
2570 }
2571 _ACEOF
2572 if ac_fn_c_try_compile "$LINENO"; then :
2573 eval "$4=yes"
2574 else
2575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2576 /* end confdefs.h. */
2577 $5
2578 int
2579 main ()
2580 {
2581 static $2 ac_aggr;
2582 if (sizeof ac_aggr.$3)
2583 return 0;
2584 ;
2585 return 0;
2586 }
2587 _ACEOF
2588 if ac_fn_c_try_compile "$LINENO"; then :
2589 eval "$4=yes"
2590 else
2591 eval "$4=no"
2592 fi
2593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2594 fi
2595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2596 fi
2597 eval ac_res=\$$4
2598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2599 $as_echo "$ac_res" >&6; }
2600 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2601
2602 } # ac_fn_c_check_member
2603
2604 # ac_fn_c_check_func LINENO FUNC VAR
2605 # ----------------------------------
2606 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2607 ac_fn_c_check_func ()
2608 {
2609 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2611 $as_echo_n "checking for $2... " >&6; }
2612 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2613 $as_echo_n "(cached) " >&6
2614 else
2615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2616 /* end confdefs.h. */
2617 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2618 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2619 #define $2 innocuous_$2
2620
2621 /* System header to define __stub macros and hopefully few prototypes,
2622 which can conflict with char $2 (); below.
2623 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2624 <limits.h> exists even on freestanding compilers. */
2625
2626 #ifdef __STDC__
2627 # include <limits.h>
2628 #else
2629 # include <assert.h>
2630 #endif
2631
2632 #undef $2
2633
2634 /* Override any GCC internal prototype to avoid an error.
2635 Use char because int might match the return type of a GCC
2636 builtin and then its argument prototype would still apply. */
2637 #ifdef __cplusplus
2638 extern "C"
2639 #endif
2640 char $2 ();
2641 /* The GNU C library defines this for functions which it implements
2642 to always fail with ENOSYS. Some functions are actually named
2643 something starting with __ and the normal name is an alias. */
2644 #if defined __stub_$2 || defined __stub___$2
2645 choke me
2646 #endif
2647
2648 int
2649 main ()
2650 {
2651 return $2 ();
2652 ;
2653 return 0;
2654 }
2655 _ACEOF
2656 if ac_fn_c_try_link "$LINENO"; then :
2657 eval "$3=yes"
2658 else
2659 eval "$3=no"
2660 fi
2661 rm -f core conftest.err conftest.$ac_objext \
2662 conftest$ac_exeext conftest.$ac_ext
2663 fi
2664 eval ac_res=\$$3
2665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2666 $as_echo "$ac_res" >&6; }
2667 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2668
2669 } # ac_fn_c_check_func
2670
2671 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2672 # -------------------------------------------
2673 # Tests whether TYPE exists after having included INCLUDES, setting cache
2674 # variable VAR accordingly.
2675 ac_fn_c_check_type ()
2676 {
2677 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2679 $as_echo_n "checking for $2... " >&6; }
2680 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2681 $as_echo_n "(cached) " >&6
2682 else
2683 eval "$3=no"
2684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2685 /* end confdefs.h. */
2686 $4
2687 int
2688 main ()
2689 {
2690 if (sizeof ($2))
2691 return 0;
2692 ;
2693 return 0;
2694 }
2695 _ACEOF
2696 if ac_fn_c_try_compile "$LINENO"; then :
2697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2698 /* end confdefs.h. */
2699 $4
2700 int
2701 main ()
2702 {
2703 if (sizeof (($2)))
2704 return 0;
2705 ;
2706 return 0;
2707 }
2708 _ACEOF
2709 if ac_fn_c_try_compile "$LINENO"; then :
2710
2711 else
2712 eval "$3=yes"
2713 fi
2714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2715 fi
2716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2717 fi
2718 eval ac_res=\$$3
2719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2720 $as_echo "$ac_res" >&6; }
2721 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2722
2723 } # ac_fn_c_check_type
2724
2725 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2726 # --------------------------------------------
2727 # Tries to find the compile-time value of EXPR in a program that includes
2728 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2729 # computed
2730 ac_fn_c_compute_int ()
2731 {
2732 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2733 if test "$cross_compiling" = yes; then
2734 # Depending upon the size, compute the lo and hi bounds.
2735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2736 /* end confdefs.h. */
2737 $4
2738 int
2739 main ()
2740 {
2741 static int test_array [1 - 2 * !(($2) >= 0)];
2742 test_array [0] = 0
2743
2744 ;
2745 return 0;
2746 }
2747 _ACEOF
2748 if ac_fn_c_try_compile "$LINENO"; then :
2749 ac_lo=0 ac_mid=0
2750 while :; do
2751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2752 /* end confdefs.h. */
2753 $4
2754 int
2755 main ()
2756 {
2757 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2758 test_array [0] = 0
2759
2760 ;
2761 return 0;
2762 }
2763 _ACEOF
2764 if ac_fn_c_try_compile "$LINENO"; then :
2765 ac_hi=$ac_mid; break
2766 else
2767 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2768 if test $ac_lo -le $ac_mid; then
2769 ac_lo= ac_hi=
2770 break
2771 fi
2772 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2773 fi
2774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2775 done
2776 else
2777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2778 /* end confdefs.h. */
2779 $4
2780 int
2781 main ()
2782 {
2783 static int test_array [1 - 2 * !(($2) < 0)];
2784 test_array [0] = 0
2785
2786 ;
2787 return 0;
2788 }
2789 _ACEOF
2790 if ac_fn_c_try_compile "$LINENO"; then :
2791 ac_hi=-1 ac_mid=-1
2792 while :; do
2793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2794 /* end confdefs.h. */
2795 $4
2796 int
2797 main ()
2798 {
2799 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2800 test_array [0] = 0
2801
2802 ;
2803 return 0;
2804 }
2805 _ACEOF
2806 if ac_fn_c_try_compile "$LINENO"; then :
2807 ac_lo=$ac_mid; break
2808 else
2809 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2810 if test $ac_mid -le $ac_hi; then
2811 ac_lo= ac_hi=
2812 break
2813 fi
2814 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2815 fi
2816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2817 done
2818 else
2819 ac_lo= ac_hi=
2820 fi
2821 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2822 fi
2823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2824 # Binary search between lo and hi bounds.
2825 while test "x$ac_lo" != "x$ac_hi"; do
2826 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2828 /* end confdefs.h. */
2829 $4
2830 int
2831 main ()
2832 {
2833 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2834 test_array [0] = 0
2835
2836 ;
2837 return 0;
2838 }
2839 _ACEOF
2840 if ac_fn_c_try_compile "$LINENO"; then :
2841 ac_hi=$ac_mid
2842 else
2843 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2844 fi
2845 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2846 done
2847 case $ac_lo in #((
2848 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2849 '') ac_retval=1 ;;
2850 esac
2851 else
2852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2853 /* end confdefs.h. */
2854 $4
2855 static long int longval () { return $2; }
2856 static unsigned long int ulongval () { return $2; }
2857 #include <stdio.h>
2858 #include <stdlib.h>
2859 int
2860 main ()
2861 {
2862
2863 FILE *f = fopen ("conftest.val", "w");
2864 if (! f)
2865 return 1;
2866 if (($2) < 0)
2867 {
2868 long int i = longval ();
2869 if (i != ($2))
2870 return 1;
2871 fprintf (f, "%ld", i);
2872 }
2873 else
2874 {
2875 unsigned long int i = ulongval ();
2876 if (i != ($2))
2877 return 1;
2878 fprintf (f, "%lu", i);
2879 }
2880 /* Do not output a trailing newline, as this causes \r\n confusion
2881 on some platforms. */
2882 return ferror (f) || fclose (f) != 0;
2883
2884 ;
2885 return 0;
2886 }
2887 _ACEOF
2888 if ac_fn_c_try_run "$LINENO"; then :
2889 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2890 else
2891 ac_retval=1
2892 fi
2893 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2894 conftest.$ac_objext conftest.beam conftest.$ac_ext
2895 rm -f conftest.val
2896
2897 fi
2898 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2899 as_fn_set_status $ac_retval
2900
2901 } # ac_fn_c_compute_int
2902 cat >config.log <<_ACEOF
2903 This file contains any messages produced by compilers while
2904 running configure, to aid debugging if configure makes a mistake.
2905
2906 It was created by emacs $as_me 24.2.50, which was
2907 generated by GNU Autoconf 2.65. Invocation command line was
2908
2909 $ $0 $@
2910
2911 _ACEOF
2912 exec 5>>config.log
2913 {
2914 cat <<_ASUNAME
2915 ## --------- ##
2916 ## Platform. ##
2917 ## --------- ##
2918
2919 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2920 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2921 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2922 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2923 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2924
2925 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2926 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2927
2928 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2929 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2930 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2931 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2932 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2933 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2934 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2935
2936 _ASUNAME
2937
2938 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2939 for as_dir in $PATH
2940 do
2941 IFS=$as_save_IFS
2942 test -z "$as_dir" && as_dir=.
2943 $as_echo "PATH: $as_dir"
2944 done
2945 IFS=$as_save_IFS
2946
2947 } >&5
2948
2949 cat >&5 <<_ACEOF
2950
2951
2952 ## ----------- ##
2953 ## Core tests. ##
2954 ## ----------- ##
2955
2956 _ACEOF
2957
2958
2959 # Keep a trace of the command line.
2960 # Strip out --no-create and --no-recursion so they do not pile up.
2961 # Strip out --silent because we don't want to record it for future runs.
2962 # Also quote any args containing shell meta-characters.
2963 # Make two passes to allow for proper duplicate-argument suppression.
2964 ac_configure_args=
2965 ac_configure_args0=
2966 ac_configure_args1=
2967 ac_must_keep_next=false
2968 for ac_pass in 1 2
2969 do
2970 for ac_arg
2971 do
2972 case $ac_arg in
2973 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2974 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2975 | -silent | --silent | --silen | --sile | --sil)
2976 continue ;;
2977 *\'*)
2978 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2979 esac
2980 case $ac_pass in
2981 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2982 2)
2983 as_fn_append ac_configure_args1 " '$ac_arg'"
2984 if test $ac_must_keep_next = true; then
2985 ac_must_keep_next=false # Got value, back to normal.
2986 else
2987 case $ac_arg in
2988 *=* | --config-cache | -C | -disable-* | --disable-* \
2989 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2990 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2991 | -with-* | --with-* | -without-* | --without-* | --x)
2992 case "$ac_configure_args0 " in
2993 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2994 esac
2995 ;;
2996 -* ) ac_must_keep_next=true ;;
2997 esac
2998 fi
2999 as_fn_append ac_configure_args " '$ac_arg'"
3000 ;;
3001 esac
3002 done
3003 done
3004 { ac_configure_args0=; unset ac_configure_args0;}
3005 { ac_configure_args1=; unset ac_configure_args1;}
3006
3007 # When interrupted or exit'd, cleanup temporary files, and complete
3008 # config.log. We remove comments because anyway the quotes in there
3009 # would cause problems or look ugly.
3010 # WARNING: Use '\'' to represent an apostrophe within the trap.
3011 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3012 trap 'exit_status=$?
3013 # Save into config.log some information that might help in debugging.
3014 {
3015 echo
3016
3017 cat <<\_ASBOX
3018 ## ---------------- ##
3019 ## Cache variables. ##
3020 ## ---------------- ##
3021 _ASBOX
3022 echo
3023 # The following way of writing the cache mishandles newlines in values,
3024 (
3025 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3026 eval ac_val=\$$ac_var
3027 case $ac_val in #(
3028 *${as_nl}*)
3029 case $ac_var in #(
3030 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3031 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3032 esac
3033 case $ac_var in #(
3034 _ | IFS | as_nl) ;; #(
3035 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3036 *) { eval $ac_var=; unset $ac_var;} ;;
3037 esac ;;
3038 esac
3039 done
3040 (set) 2>&1 |
3041 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3042 *${as_nl}ac_space=\ *)
3043 sed -n \
3044 "s/'\''/'\''\\\\'\'''\''/g;
3045 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3046 ;; #(
3047 *)
3048 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3049 ;;
3050 esac |
3051 sort
3052 )
3053 echo
3054
3055 cat <<\_ASBOX
3056 ## ----------------- ##
3057 ## Output variables. ##
3058 ## ----------------- ##
3059 _ASBOX
3060 echo
3061 for ac_var in $ac_subst_vars
3062 do
3063 eval ac_val=\$$ac_var
3064 case $ac_val in
3065 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3066 esac
3067 $as_echo "$ac_var='\''$ac_val'\''"
3068 done | sort
3069 echo
3070
3071 if test -n "$ac_subst_files"; then
3072 cat <<\_ASBOX
3073 ## ------------------- ##
3074 ## File substitutions. ##
3075 ## ------------------- ##
3076 _ASBOX
3077 echo
3078 for ac_var in $ac_subst_files
3079 do
3080 eval ac_val=\$$ac_var
3081 case $ac_val in
3082 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3083 esac
3084 $as_echo "$ac_var='\''$ac_val'\''"
3085 done | sort
3086 echo
3087 fi
3088
3089 if test -s confdefs.h; then
3090 cat <<\_ASBOX
3091 ## ----------- ##
3092 ## confdefs.h. ##
3093 ## ----------- ##
3094 _ASBOX
3095 echo
3096 cat confdefs.h
3097 echo
3098 fi
3099 test "$ac_signal" != 0 &&
3100 $as_echo "$as_me: caught signal $ac_signal"
3101 $as_echo "$as_me: exit $exit_status"
3102 } >&5
3103 rm -f core *.core core.conftest.* &&
3104 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3105 exit $exit_status
3106 ' 0
3107 for ac_signal in 1 2 13 15; do
3108 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3109 done
3110 ac_signal=0
3111
3112 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3113 rm -f -r conftest* confdefs.h
3114
3115 $as_echo "/* confdefs.h */" > confdefs.h
3116
3117 # Predefined preprocessor variables.
3118
3119 cat >>confdefs.h <<_ACEOF
3120 #define PACKAGE_NAME "$PACKAGE_NAME"
3121 _ACEOF
3122
3123 cat >>confdefs.h <<_ACEOF
3124 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3125 _ACEOF
3126
3127 cat >>confdefs.h <<_ACEOF
3128 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3129 _ACEOF
3130
3131 cat >>confdefs.h <<_ACEOF
3132 #define PACKAGE_STRING "$PACKAGE_STRING"
3133 _ACEOF
3134
3135 cat >>confdefs.h <<_ACEOF
3136 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3137 _ACEOF
3138
3139 cat >>confdefs.h <<_ACEOF
3140 #define PACKAGE_URL "$PACKAGE_URL"
3141 _ACEOF
3142
3143
3144 # Let the site file select an alternate cache file if it wants to.
3145 # Prefer an explicitly selected file to automatically selected ones.
3146 ac_site_file1=NONE
3147 ac_site_file2=NONE
3148 if test -n "$CONFIG_SITE"; then
3149 ac_site_file1=$CONFIG_SITE
3150 elif test "x$prefix" != xNONE; then
3151 ac_site_file1=$prefix/share/config.site
3152 ac_site_file2=$prefix/etc/config.site
3153 else
3154 ac_site_file1=$ac_default_prefix/share/config.site
3155 ac_site_file2=$ac_default_prefix/etc/config.site
3156 fi
3157 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3158 do
3159 test "x$ac_site_file" = xNONE && continue
3160 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3161 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3162 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3163 sed 's/^/| /' "$ac_site_file" >&5
3164 . "$ac_site_file"
3165 fi
3166 done
3167
3168 if test -r "$cache_file"; then
3169 # Some versions of bash will fail to source /dev/null (special files
3170 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3171 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3172 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3173 $as_echo "$as_me: loading cache $cache_file" >&6;}
3174 case $cache_file in
3175 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3176 *) . "./$cache_file";;
3177 esac
3178 fi
3179 else
3180 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3181 $as_echo "$as_me: creating cache $cache_file" >&6;}
3182 >$cache_file
3183 fi
3184
3185 as_fn_append ac_header_list " linux/version.h"
3186 as_fn_append ac_header_list " sys/systeminfo.h"
3187 as_fn_append ac_header_list " stdio_ext.h"
3188 as_fn_append ac_header_list " fcntl.h"
3189 as_fn_append ac_header_list " coff.h"
3190 as_fn_append ac_header_list " pty.h"
3191 as_fn_append ac_header_list " sys/vlimit.h"
3192 as_fn_append ac_header_list " sys/resource.h"
3193 as_fn_append ac_header_list " sys/utsname.h"
3194 as_fn_append ac_header_list " pwd.h"
3195 as_fn_append ac_header_list " utmp.h"
3196 as_fn_append ac_header_list " dirent.h"
3197 as_fn_append ac_header_list " util.h"
3198 as_fn_append ac_header_list " sys/socket.h"
3199 as_fn_append ac_header_list " stdlib.h"
3200 as_fn_append ac_header_list " unistd.h"
3201 as_fn_append ac_header_list " sys/param.h"
3202 as_fn_append ac_header_list " pthread.h"
3203 as_fn_append ac_header_list " malloc/malloc.h"
3204 as_fn_append ac_header_list " maillock.h"
3205 as_fn_append ac_header_list " sys/un.h"
3206 as_fn_append ac_func_list " tzset"
3207 as_fn_append ac_func_list " readlinkat"
3208 as_fn_append ac_header_list " execinfo.h"
3209 gl_getopt_required=GNU
3210 as_fn_append ac_header_list " getopt.h"
3211 as_fn_append ac_func_list " gettimeofday"
3212 as_fn_append ac_func_list " nanotime"
3213 as_fn_append ac_header_list " sys/time.h"
3214 as_fn_append ac_header_list " wchar.h"
3215 as_fn_append ac_header_list " stdint.h"
3216 as_fn_append ac_header_list " inttypes.h"
3217 as_fn_append ac_func_list " lstat"
3218 as_fn_append ac_func_list " alarm"
3219 as_fn_append ac_header_list " sys/select.h"
3220 as_fn_append ac_func_list " pselect"
3221 as_fn_append ac_func_list " pthread_sigmask"
3222 as_fn_append ac_func_list " readlink"
3223 as_fn_append ac_func_list " strtoimax"
3224 as_fn_append ac_func_list " strtoumax"
3225 as_fn_append ac_func_list " symlink"
3226 as_fn_append ac_header_list " sys/stat.h"
3227 as_fn_append ac_func_list " localtime_r"
3228 as_fn_append ac_header_list " utime.h"
3229 as_fn_append ac_func_list " futimes"
3230 as_fn_append ac_func_list " futimesat"
3231 as_fn_append ac_func_list " futimens"
3232 as_fn_append ac_func_list " utimensat"
3233 as_fn_append ac_func_list " lutimes"
3234 # Check that the precious variables saved in the cache have kept the same
3235 # value.
3236 ac_cache_corrupted=false
3237 for ac_var in $ac_precious_vars; do
3238 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3239 eval ac_new_set=\$ac_env_${ac_var}_set
3240 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3241 eval ac_new_val=\$ac_env_${ac_var}_value
3242 case $ac_old_set,$ac_new_set in
3243 set,)
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3245 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3246 ac_cache_corrupted=: ;;
3247 ,set)
3248 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3249 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3250 ac_cache_corrupted=: ;;
3251 ,);;
3252 *)
3253 if test "x$ac_old_val" != "x$ac_new_val"; then
3254 # differences in whitespace do not lead to failure.
3255 ac_old_val_w=`echo x $ac_old_val`
3256 ac_new_val_w=`echo x $ac_new_val`
3257 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3258 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3259 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3260 ac_cache_corrupted=:
3261 else
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3263 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3264 eval $ac_var=\$ac_old_val
3265 fi
3266 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3267 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3268 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3269 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3270 fi;;
3271 esac
3272 # Pass precious variables to config.status.
3273 if test "$ac_new_set" = set; then
3274 case $ac_new_val in
3275 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3276 *) ac_arg=$ac_var=$ac_new_val ;;
3277 esac
3278 case " $ac_configure_args " in
3279 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3280 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3281 esac
3282 fi
3283 done
3284 if $ac_cache_corrupted; then
3285 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3286 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3287 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3288 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3289 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3290 fi
3291 ## -------------------- ##
3292 ## Main body of script. ##
3293 ## -------------------- ##
3294
3295 ac_ext=c
3296 ac_cpp='$CPP $CPPFLAGS'
3297 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3298 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3299 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3300
3301
3302 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3303
3304
3305 ac_aux_dir=
3306 for ac_dir in build-aux "$srcdir"/build-aux; do
3307 for ac_t in install-sh install.sh shtool; do
3308 if test -f "$ac_dir/$ac_t"; then
3309 ac_aux_dir=$ac_dir
3310 ac_install_sh="$ac_aux_dir/$ac_t -c"
3311 break 2
3312 fi
3313 done
3314 done
3315 if test -z "$ac_aux_dir"; then
3316 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3317 fi
3318
3319 # These three variables are undocumented and unsupported,
3320 # and are intended to be withdrawn in a future Autoconf release.
3321 # They can cause serious problems if a builder's source tree is in a directory
3322 # whose full name contains unusual characters.
3323 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3324 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3325 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3326
3327
3328 am__api_version='1.11'
3329
3330 # Find a good install program. We prefer a C program (faster),
3331 # so one script is as good as another. But avoid the broken or
3332 # incompatible versions:
3333 # SysV /etc/install, /usr/sbin/install
3334 # SunOS /usr/etc/install
3335 # IRIX /sbin/install
3336 # AIX /bin/install
3337 # AmigaOS /C/install, which installs bootblocks on floppy discs
3338 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3339 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3340 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3341 # OS/2's system install, which has a completely different semantic
3342 # ./install, which can be erroneously created by make from ./install.sh.
3343 # Reject install programs that cannot install multiple files.
3344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3345 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3346 if test -z "$INSTALL"; then
3347 if test "${ac_cv_path_install+set}" = set; then :
3348 $as_echo_n "(cached) " >&6
3349 else
3350 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3351 for as_dir in $PATH
3352 do
3353 IFS=$as_save_IFS
3354 test -z "$as_dir" && as_dir=.
3355 # Account for people who put trailing slashes in PATH elements.
3356 case $as_dir/ in #((
3357 ./ | .// | /[cC]/* | \
3358 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3359 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3360 /usr/ucb/* ) ;;
3361 *)
3362 # OSF1 and SCO ODT 3.0 have their own names for install.
3363 # Don't use installbsd from OSF since it installs stuff as root
3364 # by default.
3365 for ac_prog in ginstall scoinst install; do
3366 for ac_exec_ext in '' $ac_executable_extensions; do
3367 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3368 if test $ac_prog = install &&
3369 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3370 # AIX install. It has an incompatible calling convention.
3371 :
3372 elif test $ac_prog = install &&
3373 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3374 # program-specific install script used by HP pwplus--don't use.
3375 :
3376 else
3377 rm -rf conftest.one conftest.two conftest.dir
3378 echo one > conftest.one
3379 echo two > conftest.two
3380 mkdir conftest.dir
3381 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3382 test -s conftest.one && test -s conftest.two &&
3383 test -s conftest.dir/conftest.one &&
3384 test -s conftest.dir/conftest.two
3385 then
3386 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3387 break 3
3388 fi
3389 fi
3390 fi
3391 done
3392 done
3393 ;;
3394 esac
3395
3396 done
3397 IFS=$as_save_IFS
3398
3399 rm -rf conftest.one conftest.two conftest.dir
3400
3401 fi
3402 if test "${ac_cv_path_install+set}" = set; then
3403 INSTALL=$ac_cv_path_install
3404 else
3405 # As a last resort, use the slow shell script. Don't cache a
3406 # value for INSTALL within a source directory, because that will
3407 # break other packages using the cache if that directory is
3408 # removed, or if the value is a relative name.
3409 INSTALL=$ac_install_sh
3410 fi
3411 fi
3412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3413 $as_echo "$INSTALL" >&6; }
3414
3415 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3416 # It thinks the first close brace ends the variable substitution.
3417 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3418
3419 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3420
3421 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3422
3423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3424 $as_echo_n "checking whether build environment is sane... " >&6; }
3425 # Just in case
3426 sleep 1
3427 echo timestamp > conftest.file
3428 # Reject unsafe characters in $srcdir or the absolute working directory
3429 # name. Accept space and tab only in the latter.
3430 am_lf='
3431 '
3432 case `pwd` in
3433 *[\\\"\#\$\&\'\`$am_lf]*)
3434 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3435 esac
3436 case $srcdir in
3437 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3438 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3439 esac
3440
3441 # Do `set' in a subshell so we don't clobber the current shell's
3442 # arguments. Must try -L first in case configure is actually a
3443 # symlink; some systems play weird games with the mod time of symlinks
3444 # (eg FreeBSD returns the mod time of the symlink's containing
3445 # directory).
3446 if (
3447 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3448 if test "$*" = "X"; then
3449 # -L didn't work.
3450 set X `ls -t "$srcdir/configure" conftest.file`
3451 fi
3452 rm -f conftest.file
3453 if test "$*" != "X $srcdir/configure conftest.file" \
3454 && test "$*" != "X conftest.file $srcdir/configure"; then
3455
3456 # If neither matched, then we have a broken ls. This can happen
3457 # if, for instance, CONFIG_SHELL is bash and it inherits a
3458 # broken ls alias from the environment. This has actually
3459 # happened. Such a system could not be considered "sane".
3460 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3461 alias in your environment" "$LINENO" 5
3462 fi
3463
3464 test "$2" = conftest.file
3465 )
3466 then
3467 # Ok.
3468 :
3469 else
3470 as_fn_error "newly created file is older than distributed files!
3471 Check your system clock" "$LINENO" 5
3472 fi
3473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3474 $as_echo "yes" >&6; }
3475 test "$program_prefix" != NONE &&
3476 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3477 # Use a double $ so make ignores it.
3478 test "$program_suffix" != NONE &&
3479 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3480 # Double any \ or $.
3481 # By default was `s,x,x', remove it if useless.
3482 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3483 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3484
3485 # expand $ac_aux_dir to an absolute path
3486 am_aux_dir=`cd $ac_aux_dir && pwd`
3487
3488 if test x"${MISSING+set}" != xset; then
3489 case $am_aux_dir in
3490 *\ * | *\ *)
3491 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3492 *)
3493 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3494 esac
3495 fi
3496 # Use eval to expand $SHELL
3497 if eval "$MISSING --run true"; then
3498 am_missing_run="$MISSING --run "
3499 else
3500 am_missing_run=
3501 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3502 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3503 fi
3504
3505 if test x"${install_sh}" != xset; then
3506 case $am_aux_dir in
3507 *\ * | *\ *)
3508 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3509 *)
3510 install_sh="\${SHELL} $am_aux_dir/install-sh"
3511 esac
3512 fi
3513
3514 # Installed binaries are usually stripped using `strip' when the user
3515 # run `make install-strip'. However `strip' might not be the right
3516 # tool to use in cross-compilation environments, therefore Automake
3517 # will honor the `STRIP' environment variable to overrule this program.
3518 if test "$cross_compiling" != no; then
3519 if test -n "$ac_tool_prefix"; then
3520 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3521 set dummy ${ac_tool_prefix}strip; ac_word=$2
3522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3523 $as_echo_n "checking for $ac_word... " >&6; }
3524 if test "${ac_cv_prog_STRIP+set}" = set; then :
3525 $as_echo_n "(cached) " >&6
3526 else
3527 if test -n "$STRIP"; then
3528 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3529 else
3530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3531 for as_dir in $PATH
3532 do
3533 IFS=$as_save_IFS
3534 test -z "$as_dir" && as_dir=.
3535 for ac_exec_ext in '' $ac_executable_extensions; do
3536 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3537 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3539 break 2
3540 fi
3541 done
3542 done
3543 IFS=$as_save_IFS
3544
3545 fi
3546 fi
3547 STRIP=$ac_cv_prog_STRIP
3548 if test -n "$STRIP"; then
3549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3550 $as_echo "$STRIP" >&6; }
3551 else
3552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3553 $as_echo "no" >&6; }
3554 fi
3555
3556
3557 fi
3558 if test -z "$ac_cv_prog_STRIP"; then
3559 ac_ct_STRIP=$STRIP
3560 # Extract the first word of "strip", so it can be a program name with args.
3561 set dummy strip; ac_word=$2
3562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3563 $as_echo_n "checking for $ac_word... " >&6; }
3564 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3565 $as_echo_n "(cached) " >&6
3566 else
3567 if test -n "$ac_ct_STRIP"; then
3568 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3569 else
3570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3571 for as_dir in $PATH
3572 do
3573 IFS=$as_save_IFS
3574 test -z "$as_dir" && as_dir=.
3575 for ac_exec_ext in '' $ac_executable_extensions; do
3576 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3577 ac_cv_prog_ac_ct_STRIP="strip"
3578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3579 break 2
3580 fi
3581 done
3582 done
3583 IFS=$as_save_IFS
3584
3585 fi
3586 fi
3587 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3588 if test -n "$ac_ct_STRIP"; then
3589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3590 $as_echo "$ac_ct_STRIP" >&6; }
3591 else
3592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3593 $as_echo "no" >&6; }
3594 fi
3595
3596 if test "x$ac_ct_STRIP" = x; then
3597 STRIP=":"
3598 else
3599 case $cross_compiling:$ac_tool_warned in
3600 yes:)
3601 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3602 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3603 ac_tool_warned=yes ;;
3604 esac
3605 STRIP=$ac_ct_STRIP
3606 fi
3607 else
3608 STRIP="$ac_cv_prog_STRIP"
3609 fi
3610
3611 fi
3612 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3613
3614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3615 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3616 if test -z "$MKDIR_P"; then
3617 if test "${ac_cv_path_mkdir+set}" = set; then :
3618 $as_echo_n "(cached) " >&6
3619 else
3620 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3621 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3622 do
3623 IFS=$as_save_IFS
3624 test -z "$as_dir" && as_dir=.
3625 for ac_prog in mkdir gmkdir; do
3626 for ac_exec_ext in '' $ac_executable_extensions; do
3627 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3628 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3629 'mkdir (GNU coreutils) '* | \
3630 'mkdir (coreutils) '* | \
3631 'mkdir (fileutils) '4.1*)
3632 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3633 break 3;;
3634 esac
3635 done
3636 done
3637 done
3638 IFS=$as_save_IFS
3639
3640 fi
3641
3642 test -d ./--version && rmdir ./--version
3643 if test "${ac_cv_path_mkdir+set}" = set; then
3644 MKDIR_P="$ac_cv_path_mkdir -p"
3645 else
3646 # As a last resort, use the slow shell script. Don't cache a
3647 # value for MKDIR_P within a source directory, because that will
3648 # break other packages using the cache if that directory is
3649 # removed, or if the value is a relative name.
3650 MKDIR_P="$ac_install_sh -d"
3651 fi
3652 fi
3653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3654 $as_echo "$MKDIR_P" >&6; }
3655
3656
3657 mkdir_p="$MKDIR_P"
3658 case $mkdir_p in
3659 [\\/$]* | ?:[\\/]*) ;;
3660 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3661 esac
3662
3663 for ac_prog in gawk mawk nawk awk
3664 do
3665 # Extract the first word of "$ac_prog", so it can be a program name with args.
3666 set dummy $ac_prog; ac_word=$2
3667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3668 $as_echo_n "checking for $ac_word... " >&6; }
3669 if test "${ac_cv_prog_AWK+set}" = set; then :
3670 $as_echo_n "(cached) " >&6
3671 else
3672 if test -n "$AWK"; then
3673 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3674 else
3675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3676 for as_dir in $PATH
3677 do
3678 IFS=$as_save_IFS
3679 test -z "$as_dir" && as_dir=.
3680 for ac_exec_ext in '' $ac_executable_extensions; do
3681 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3682 ac_cv_prog_AWK="$ac_prog"
3683 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3684 break 2
3685 fi
3686 done
3687 done
3688 IFS=$as_save_IFS
3689
3690 fi
3691 fi
3692 AWK=$ac_cv_prog_AWK
3693 if test -n "$AWK"; then
3694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3695 $as_echo "$AWK" >&6; }
3696 else
3697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3698 $as_echo "no" >&6; }
3699 fi
3700
3701
3702 test -n "$AWK" && break
3703 done
3704
3705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3706 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3707 set x ${MAKE-make}
3708 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3709 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3710 $as_echo_n "(cached) " >&6
3711 else
3712 cat >conftest.make <<\_ACEOF
3713 SHELL = /bin/sh
3714 all:
3715 @echo '@@@%%%=$(MAKE)=@@@%%%'
3716 _ACEOF
3717 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3718 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3719 *@@@%%%=?*=@@@%%%*)
3720 eval ac_cv_prog_make_${ac_make}_set=yes;;
3721 *)
3722 eval ac_cv_prog_make_${ac_make}_set=no;;
3723 esac
3724 rm -f conftest.make
3725 fi
3726 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3728 $as_echo "yes" >&6; }
3729 SET_MAKE=
3730 else
3731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3732 $as_echo "no" >&6; }
3733 SET_MAKE="MAKE=${MAKE-make}"
3734 fi
3735
3736 rm -rf .tst 2>/dev/null
3737 mkdir .tst 2>/dev/null
3738 if test -d .tst; then
3739 am__leading_dot=.
3740 else
3741 am__leading_dot=_
3742 fi
3743 rmdir .tst 2>/dev/null
3744
3745 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3746 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3747 # is not polluted with repeated "-I."
3748 am__isrc=' -I$(srcdir)'
3749 # test to see if srcdir already configured
3750 if test -f $srcdir/config.status; then
3751 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3752 fi
3753 fi
3754
3755 # test whether we have cygpath
3756 if test -z "$CYGPATH_W"; then
3757 if (cygpath --version) >/dev/null 2>/dev/null; then
3758 CYGPATH_W='cygpath -w'
3759 else
3760 CYGPATH_W=echo
3761 fi
3762 fi
3763
3764
3765 # Define the identity of the package.
3766 PACKAGE='emacs'
3767 VERSION='24.2.50'
3768
3769
3770 cat >>confdefs.h <<_ACEOF
3771 #define PACKAGE "$PACKAGE"
3772 _ACEOF
3773
3774
3775 cat >>confdefs.h <<_ACEOF
3776 #define VERSION "$VERSION"
3777 _ACEOF
3778
3779 # Some tools Automake needs.
3780
3781 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3782
3783
3784 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3785
3786
3787 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3788
3789
3790 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3791
3792
3793 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3794
3795 # We need awk for the "check" target. The system "awk" is bad on
3796 # some platforms.
3797 # Always define AMTAR for backward compatibility.
3798
3799 AMTAR=${AMTAR-"${am_missing_run}tar"}
3800
3801 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3802
3803
3804
3805
3806
3807
3808
3809
3810 lispdir='${datadir}/emacs/${version}/lisp'
3811 leimdir='${datadir}/emacs/${version}/leim'
3812 standardlisppath='${lispdir}:${leimdir}'
3813 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3814 '${datadir}/emacs/site-lisp'
3815 lisppath='${locallisppath}:${standardlisppath}'
3816 etcdir='${datadir}/emacs/${version}/etc'
3817 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3818 docdir='${datadir}/emacs/${version}/etc'
3819 gamedir='${localstatedir}/games/emacs'
3820
3821
3822 # Check whether --with-all was given.
3823 if test "${with_all+set}" = set; then :
3824 withval=$with_all; with_features=$withval
3825 else
3826 with_features=yes
3827 fi
3828
3829
3830
3831
3832
3833 # Check whether --with-pop was given.
3834 if test "${with_pop+set}" = set; then :
3835 withval=$with_pop;
3836 else
3837 with_pop=$with_features
3838 fi
3839
3840 if test "$with_pop" = yes; then
3841 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3842
3843 fi
3844
3845
3846 # Check whether --with-kerberos was given.
3847 if test "${with_kerberos+set}" = set; then :
3848 withval=$with_kerberos;
3849 else
3850 with_kerberos=no
3851 fi
3852
3853 if test "$with_kerberos" != no; then
3854 $as_echo "#define KERBEROS 1" >>confdefs.h
3855
3856 fi
3857
3858
3859 # Check whether --with-kerberos5 was given.
3860 if test "${with_kerberos5+set}" = set; then :
3861 withval=$with_kerberos5;
3862 else
3863 with_kerberos5=no
3864 fi
3865
3866 if test "${with_kerberos5}" != no; then
3867 if test "${with_kerberos}" = no; then
3868 with_kerberos=yes
3869 $as_echo "#define KERBEROS 1" >>confdefs.h
3870
3871 fi
3872
3873 $as_echo "#define KERBEROS5 1" >>confdefs.h
3874
3875 fi
3876
3877
3878 # Check whether --with-hesiod was given.
3879 if test "${with_hesiod+set}" = set; then :
3880 withval=$with_hesiod;
3881 else
3882 with_hesiod=no
3883 fi
3884
3885 if test "$with_hesiod" != no; then
3886
3887 $as_echo "#define HESIOD 1" >>confdefs.h
3888
3889 fi
3890
3891
3892 # Check whether --with-mmdf was given.
3893 if test "${with_mmdf+set}" = set; then :
3894 withval=$with_mmdf;
3895 else
3896 with_mmdf=no
3897 fi
3898
3899 if test "$with_mmdf" != no; then
3900
3901 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3902
3903 fi
3904
3905
3906 # Check whether --with-mail-unlink was given.
3907 if test "${with_mail_unlink+set}" = set; then :
3908 withval=$with_mail_unlink;
3909 else
3910 with_mail_unlink=no
3911 fi
3912
3913 if test "$with_mail_unlink" != no; then
3914
3915 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3916
3917 fi
3918
3919
3920 # Check whether --with-mailhost was given.
3921 if test "${with_mailhost+set}" = set; then :
3922 withval=$with_mailhost;
3923 cat >>confdefs.h <<_ACEOF
3924 #define MAILHOST "$withval"
3925 _ACEOF
3926
3927 fi
3928
3929
3930
3931 # Check whether --with-sound was given.
3932 if test "${with_sound+set}" = set; then :
3933 withval=$with_sound;
3934 else
3935 with_sound=$with_features
3936 fi
3937
3938
3939
3940 # Check whether --with-x-toolkit was given.
3941 if test "${with_x_toolkit+set}" = set; then :
3942 withval=$with_x_toolkit; case "${withval}" in
3943 y | ye | yes ) val=gtk ;;
3944 n | no ) val=no ;;
3945 l | lu | luc | luci | lucid ) val=lucid ;;
3946 a | at | ath | athe | athen | athena ) val=athena ;;
3947 m | mo | mot | moti | motif ) val=motif ;;
3948 g | gt | gtk ) val=gtk ;;
3949 gtk2 ) val=gtk2 ;;
3950 gtk3 ) val=gtk3 ;;
3951 * )
3952 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3953 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
3954 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
3955 \`athena' and \`lucid' are synonyms." "$LINENO" 5
3956 ;;
3957 esac
3958 with_x_toolkit=$val
3959
3960 fi
3961
3962
3963
3964 # Check whether --with-wide-int was given.
3965 if test "${with_wide_int+set}" = set; then :
3966 withval=$with_wide_int;
3967 else
3968 with_wide_int=no
3969 fi
3970
3971 if test "$with_wide_int" = yes; then
3972
3973 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3974
3975 fi
3976
3977
3978 # Check whether --with-xpm was given.
3979 if test "${with_xpm+set}" = set; then :
3980 withval=$with_xpm;
3981 else
3982 with_xpm=$with_features
3983 fi
3984
3985
3986 # Check whether --with-jpeg was given.
3987 if test "${with_jpeg+set}" = set; then :
3988 withval=$with_jpeg;
3989 else
3990 with_jpeg=$with_features
3991 fi
3992
3993
3994 # Check whether --with-tiff was given.
3995 if test "${with_tiff+set}" = set; then :
3996 withval=$with_tiff;
3997 else
3998 with_tiff=$with_features
3999 fi
4000
4001
4002 # Check whether --with-gif was given.
4003 if test "${with_gif+set}" = set; then :
4004 withval=$with_gif;
4005 else
4006 with_gif=$with_features
4007 fi
4008
4009
4010 # Check whether --with-png was given.
4011 if test "${with_png+set}" = set; then :
4012 withval=$with_png;
4013 else
4014 with_png=$with_features
4015 fi
4016
4017
4018 # Check whether --with-rsvg was given.
4019 if test "${with_rsvg+set}" = set; then :
4020 withval=$with_rsvg;
4021 else
4022 with_rsvg=$with_features
4023 fi
4024
4025
4026 # Check whether --with-xml2 was given.
4027 if test "${with_xml2+set}" = set; then :
4028 withval=$with_xml2;
4029 else
4030 with_xml2=$with_features
4031 fi
4032
4033
4034 # Check whether --with-imagemagick was given.
4035 if test "${with_imagemagick+set}" = set; then :
4036 withval=$with_imagemagick;
4037 else
4038 with_imagemagick=$with_features
4039 fi
4040
4041
4042
4043 # Check whether --with-xft was given.
4044 if test "${with_xft+set}" = set; then :
4045 withval=$with_xft;
4046 else
4047 with_xft=$with_features
4048 fi
4049
4050
4051 # Check whether --with-libotf was given.
4052 if test "${with_libotf+set}" = set; then :
4053 withval=$with_libotf;
4054 else
4055 with_libotf=$with_features
4056 fi
4057
4058
4059 # Check whether --with-m17n-flt was given.
4060 if test "${with_m17n_flt+set}" = set; then :
4061 withval=$with_m17n_flt;
4062 else
4063 with_m17n_flt=$with_features
4064 fi
4065
4066
4067
4068 # Check whether --with-toolkit-scroll-bars was given.
4069 if test "${with_toolkit_scroll_bars+set}" = set; then :
4070 withval=$with_toolkit_scroll_bars;
4071 else
4072 with_toolkit_scroll_bars=$with_features
4073 fi
4074
4075
4076 # Check whether --with-xaw3d was given.
4077 if test "${with_xaw3d+set}" = set; then :
4078 withval=$with_xaw3d;
4079 else
4080 with_xaw3d=$with_features
4081 fi
4082
4083
4084 # Check whether --with-xim was given.
4085 if test "${with_xim+set}" = set; then :
4086 withval=$with_xim;
4087 else
4088 with_xim=$with_features
4089 fi
4090
4091
4092 # Check whether --with-ns was given.
4093 if test "${with_ns+set}" = set; then :
4094 withval=$with_ns;
4095 else
4096 with_ns=no
4097 fi
4098
4099
4100 # Check whether --with-w32 was given.
4101 if test "${with_w32+set}" = set; then :
4102 withval=$with_w32;
4103 else
4104 with_w32=no
4105 fi
4106
4107
4108
4109 # Check whether --with-gpm was given.
4110 if test "${with_gpm+set}" = set; then :
4111 withval=$with_gpm;
4112 else
4113 with_gpm=$with_features
4114 fi
4115
4116
4117 # Check whether --with-dbus was given.
4118 if test "${with_dbus+set}" = set; then :
4119 withval=$with_dbus;
4120 else
4121 with_dbus=$with_features
4122 fi
4123
4124
4125 # Check whether --with-gconf was given.
4126 if test "${with_gconf+set}" = set; then :
4127 withval=$with_gconf;
4128 else
4129 with_gconf=$with_features
4130 fi
4131
4132
4133 # Check whether --with-gsettings was given.
4134 if test "${with_gsettings+set}" = set; then :
4135 withval=$with_gsettings;
4136 else
4137 with_gsettings=$with_features
4138 fi
4139
4140
4141 # Check whether --with-selinux was given.
4142 if test "${with_selinux+set}" = set; then :
4143 withval=$with_selinux;
4144 else
4145 with_selinux=$with_features
4146 fi
4147
4148
4149 # Check whether --with-gnutls was given.
4150 if test "${with_gnutls+set}" = set; then :
4151 withval=$with_gnutls;
4152 else
4153 with_gnutls=$with_features
4154 fi
4155
4156
4157 ## For the times when you want to build Emacs but don't have
4158 ## a suitable makeinfo, and can live without the manuals.
4159
4160 # Check whether --with-makeinfo was given.
4161 if test "${with_makeinfo+set}" = set; then :
4162 withval=$with_makeinfo;
4163 else
4164 with_makeinfo=$with_features
4165 fi
4166
4167
4168 ## Makefile.in needs the cache file name.
4169
4170
4171 ## This is an option because I do not know if all info/man support
4172 ## compressed files, nor how to test if they do so.
4173
4174 # Check whether --with-compress-info was given.
4175 if test "${with_compress_info+set}" = set; then :
4176 withval=$with_compress_info;
4177 else
4178 with_compress_info=$with_features
4179 fi
4180
4181 if test $with_compress_info = yes; then
4182 GZIP_INFO=yes
4183 else
4184 GZIP_INFO=
4185 fi
4186
4187
4188
4189 # Check whether --with-pkg-config-prog was given.
4190 if test "${with_pkg_config_prog+set}" = set; then :
4191 withval=$with_pkg_config_prog;
4192 fi
4193
4194 if test "X${with_pkg_config_prog}" != X; then
4195 if test "${with_pkg_config_prog}" != yes; then
4196 PKG_CONFIG="${with_pkg_config_prog}"
4197 fi
4198 fi
4199
4200 CRT_DIR=
4201
4202 # Check whether --with-crt-dir was given.
4203 if test "${with_crt_dir+set}" = set; then :
4204 withval=$with_crt_dir;
4205 fi
4206
4207 CRT_DIR="${with_crt_dir}"
4208
4209
4210 # Check whether --with-gameuser was given.
4211 if test "${with_gameuser+set}" = set; then :
4212 withval=$with_gameuser;
4213 fi
4214
4215 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4216 && gameuser="${with_gameuser}"
4217 test "X$gameuser" = X && gameuser=games
4218
4219
4220 # Check whether --with-gnustep-conf was given.
4221 if test "${with_gnustep_conf+set}" = set; then :
4222 withval=$with_gnustep_conf;
4223 fi
4224
4225 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4226 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4227 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4228 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4229
4230 # Check whether --enable-ns-self-contained was given.
4231 if test "${enable_ns_self_contained+set}" = set; then :
4232 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4233 else
4234 EN_NS_SELF_CONTAINED=yes
4235 fi
4236
4237
4238 # Check whether --enable-locallisppath was given.
4239 if test "${enable_locallisppath+set}" = set; then :
4240 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4241 locallisppath=
4242 elif test "${enableval}" != "yes"; then
4243 locallisppath=${enableval}
4244 fi
4245 fi
4246
4247
4248 # Check whether --enable-checking was given.
4249 if test "${enable_checking+set}" = set; then :
4250 enableval=$enable_checking; ac_checking_flags="${enableval}"
4251 fi
4252
4253 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4254 for check in $ac_checking_flags
4255 do
4256 case $check in
4257 # these set all the flags to specific states
4258 yes) ac_enable_checking=1 ;;
4259 no) ac_enable_checking= ;
4260 ac_gc_check_stringbytes= ;
4261 ac_gc_check_string_overrun= ;
4262 ac_gc_check_string_free_list= ;
4263 ac_xmalloc_overrun= ;
4264 ac_gc_check_cons_list= ;
4265 ac_glyphs_debug= ;;
4266 all) ac_enable_checking=1 ;
4267 ac_gc_check_stringbytes=1 ;
4268 ac_gc_check_string_overrun=1 ;
4269 ac_gc_check_string_free_list=1 ;
4270 ac_xmalloc_overrun=1 ;
4271 ac_gc_check_cons_list=1 ;
4272 ac_glyphs_debug=1 ;;
4273 # these enable particular checks
4274 stringbytes) ac_gc_check_stringbytes=1 ;;
4275 stringoverrun) ac_gc_check_string_overrun=1 ;;
4276 stringfreelist) ac_gc_check_string_free_list=1 ;;
4277 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4278 conslist) ac_gc_check_cons_list=1 ;;
4279 glyphs) ac_glyphs_debug=1 ;;
4280 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4281 esac
4282 done
4283 IFS="$ac_save_IFS"
4284
4285 if test x$ac_enable_checking != x ; then
4286
4287 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4288
4289 fi
4290 if test x$ac_gc_check_stringbytes != x ; then
4291
4292 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4293
4294 fi
4295 if test x$ac_gc_check_string_overrun != x ; then
4296
4297 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4298
4299 fi
4300 if test x$ac_gc_check_string_free_list != x ; then
4301
4302 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4303
4304 fi
4305 if test x$ac_xmalloc_overrun != x ; then
4306
4307 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4308
4309 fi
4310 if test x$ac_gc_check_cons_list != x ; then
4311
4312 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4313
4314 fi
4315 if test x$ac_glyphs_debug != x ; then
4316
4317 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4318
4319 fi
4320
4321 # Check whether --enable-check-lisp-object-type was given.
4322 if test "${enable_check_lisp_object_type+set}" = set; then :
4323 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4324
4325 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4326
4327 fi
4328 fi
4329
4330
4331
4332 # Check whether --enable-profiling was given.
4333 if test "${enable_profiling+set}" = set; then :
4334 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4335 fi
4336
4337 if test x$ac_enable_profiling != x ; then
4338 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4339 else
4340 PROFILING_CFLAGS=
4341 fi
4342
4343
4344 # Check whether --enable-autodepend was given.
4345 if test "${enable_autodepend+set}" = set; then :
4346 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4347 else
4348 ac_enable_autodepend=yes
4349 fi
4350
4351
4352 #### Make srcdir absolute, if it isn't already. It's important to
4353 #### avoid running the path through pwd unnecessarily, since pwd can
4354 #### give you automounter prefixes, which can go away. We do all this
4355 #### so Emacs can find its files when run uninstalled.
4356 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4357 unset CDPATH
4358 case "${srcdir}" in
4359 /* ) ;;
4360 . )
4361 ## We may be able to use the $PWD environment variable to make this
4362 ## absolute. But sometimes PWD is inaccurate.
4363 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4364 ## but that tested only for a well-formed and valid PWD,
4365 ## it did not object when PWD was well-formed and valid but just wrong.
4366 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4367 then
4368 srcdir="$PWD"
4369 else
4370 srcdir="`(cd ${srcdir}; pwd)`"
4371 fi
4372 ;;
4373 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4374 esac
4375
4376 ### Canonicalize the configuration name.
4377
4378 # Make sure we can run config.sub.
4379 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4380 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4381
4382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4383 $as_echo_n "checking build system type... " >&6; }
4384 if test "${ac_cv_build+set}" = set; then :
4385 $as_echo_n "(cached) " >&6
4386 else
4387 ac_build_alias=$build_alias
4388 test "x$ac_build_alias" = x &&
4389 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4390 test "x$ac_build_alias" = x &&
4391 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4392 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4393 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4394
4395 fi
4396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4397 $as_echo "$ac_cv_build" >&6; }
4398 case $ac_cv_build in
4399 *-*-*) ;;
4400 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4401 esac
4402 build=$ac_cv_build
4403 ac_save_IFS=$IFS; IFS='-'
4404 set x $ac_cv_build
4405 shift
4406 build_cpu=$1
4407 build_vendor=$2
4408 shift; shift
4409 # Remember, the first character of IFS is used to create $*,
4410 # except with old shells:
4411 build_os=$*
4412 IFS=$ac_save_IFS
4413 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4414
4415
4416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4417 $as_echo_n "checking host system type... " >&6; }
4418 if test "${ac_cv_host+set}" = set; then :
4419 $as_echo_n "(cached) " >&6
4420 else
4421 if test "x$host_alias" = x; then
4422 ac_cv_host=$ac_cv_build
4423 else
4424 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4425 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4426 fi
4427
4428 fi
4429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4430 $as_echo "$ac_cv_host" >&6; }
4431 case $ac_cv_host in
4432 *-*-*) ;;
4433 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4434 esac
4435 host=$ac_cv_host
4436 ac_save_IFS=$IFS; IFS='-'
4437 set x $ac_cv_host
4438 shift
4439 host_cpu=$1
4440 host_vendor=$2
4441 shift; shift
4442 # Remember, the first character of IFS is used to create $*,
4443 # except with old shells:
4444 host_os=$*
4445 IFS=$ac_save_IFS
4446 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4447
4448
4449 canonical=$host
4450 configuration=${host_alias-${build_alias-$host}}
4451
4452
4453
4454 ### If you add support for a new configuration, add code to this
4455 ### switch statement to recognize your configuration name and select
4456 ### the appropriate operating system file.
4457
4458 ### You would hope that you could choose an s/*.h
4459 ### file based on the operating system portion. However, it turns out
4460 ### that each s/*.h file is pretty manufacturer-specific.
4461 ### So we basically have to have a special case for each
4462 ### configuration name.
4463 ###
4464 ### As far as handling version numbers on operating systems is
4465 ### concerned, make sure things will fail in a fixable way. If
4466 ### /etc/MACHINES doesn't say anything about version numbers, be
4467 ### prepared to handle anything reasonably. If version numbers
4468 ### matter, be sure /etc/MACHINES says something about it.
4469
4470 opsys='' unported=no
4471 case "${canonical}" in
4472
4473 ## GNU/Linux and similar ports
4474 *-*-linux* )
4475 opsys=gnu-linux
4476 ;;
4477
4478 ## FreeBSD ports
4479 *-*-freebsd* )
4480 opsys=freebsd
4481 ;;
4482
4483 ## FreeBSD kernel + glibc based userland
4484 *-*-kfreebsd*gnu* )
4485 opsys=gnu-kfreebsd
4486 ;;
4487
4488 ## NetBSD ports
4489 *-*-netbsd* )
4490 opsys=netbsd
4491 ;;
4492
4493 ## OpenBSD ports
4494 *-*-openbsd* )
4495 opsys=openbsd
4496 ;;
4497
4498 ## Apple Darwin / Mac OS X
4499 *-apple-darwin* )
4500 case "${canonical}" in
4501 i[3456]86-* ) ;;
4502 powerpc-* ) ;;
4503 x86_64-* ) ;;
4504 * ) unported=yes ;;
4505 esac
4506 opsys=darwin
4507 ## Use fink packages if available.
4508 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4509 ## if test -d /sw/include && test -d /sw/lib; then
4510 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4511 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4512 ## fi
4513 ;;
4514
4515 ## HP 9000 series 700 and 800, running HP/UX
4516 hppa*-hp-hpux10.2* )
4517 opsys=hpux10-20
4518 ;;
4519 hppa*-hp-hpux1[1-9]* )
4520 opsys=hpux11
4521 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4522 ;;
4523
4524 ## IBM machines
4525 rs6000-ibm-aix4.[23]* )
4526 opsys=aix4-2
4527 ;;
4528 powerpc-ibm-aix4.[23]* )
4529 opsys=aix4-2
4530 ;;
4531 rs6000-ibm-aix[56]* )
4532 opsys=aix4-2
4533 ;;
4534 powerpc-ibm-aix[56]* )
4535 opsys=aix4-2
4536 ;;
4537
4538 ## Silicon Graphics machines
4539 ## Iris 4D
4540 mips-sgi-irix6.5 )
4541 opsys=irix6-5
4542 # Without defining _LANGUAGE_C, things get masked out in the headers
4543 # so that, for instance, grepping for `free' in stdlib.h fails and
4544 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4545 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4546 ;;
4547
4548 ## Suns
4549 *-sun-solaris* \
4550 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4551 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4552 case "${canonical}" in
4553 i[3456]86-*-* ) ;;
4554 amd64-*-*|x86_64-*-*) ;;
4555 sparc* ) ;;
4556 * ) unported=yes ;;
4557 esac
4558 case "${canonical}" in
4559 *-sunos5.6* | *-solaris2.6* )
4560 opsys=sol2-6
4561 RANLIB="ar -ts"
4562 ;;
4563 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4564 opsys=sol2-6
4565 emacs_check_sunpro_c=yes
4566 ;;
4567 *-sunos5* | *-solaris* )
4568 opsys=sol2-10
4569 emacs_check_sunpro_c=yes
4570 ;;
4571 esac
4572 ## Watch out for a compiler that we know will not work.
4573 case "${canonical}" in
4574 *-solaris* | *-sunos5* )
4575 if [ "x$CC" = x/usr/ucb/cc ]; then
4576 ## /usr/ucb/cc doesn't work;
4577 ## we should find some other compiler that does work.
4578 unset CC
4579 fi
4580 ;;
4581 *) ;;
4582 esac
4583 ;;
4584
4585 ## Intel 386 machines where we don't care about the manufacturer.
4586 i[3456]86-*-* )
4587 case "${canonical}" in
4588 *-cygwin ) opsys=cygwin ;;
4589 *-darwin* ) opsys=darwin ;;
4590 *-sysv4.2uw* ) opsys=unixware ;;
4591 *-sysv5uw* ) opsys=unixware ;;
4592 *-sysv5OpenUNIX* ) opsys=unixware ;;
4593 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4594 esac
4595 ;;
4596
4597 * )
4598 unported=yes
4599 ;;
4600 esac
4601
4602 ### If the code above didn't choose an operating system, just choose
4603 ### an operating system based on the configuration name. You really
4604 ### only want to use this when you have no idea what the right
4605 ### operating system is; if you know what operating systems a machine
4606 ### runs, it's cleaner to make it explicit in the case statement
4607 ### above.
4608 if test x"${opsys}" = x; then
4609 case "${canonical}" in
4610 *-gnu* ) opsys=gnu ;;
4611 * )
4612 unported=yes
4613 ;;
4614 esac
4615 fi
4616
4617
4618
4619 if test $unported = yes; then
4620 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4621 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4622 fi
4623
4624
4625 #### Choose a compiler.
4626
4627 ac_ext=c
4628 ac_cpp='$CPP $CPPFLAGS'
4629 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4630 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4631 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4632 if test -n "$ac_tool_prefix"; then
4633 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4634 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4636 $as_echo_n "checking for $ac_word... " >&6; }
4637 if test "${ac_cv_prog_CC+set}" = set; then :
4638 $as_echo_n "(cached) " >&6
4639 else
4640 if test -n "$CC"; then
4641 ac_cv_prog_CC="$CC" # Let the user override the test.
4642 else
4643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4644 for as_dir in $PATH
4645 do
4646 IFS=$as_save_IFS
4647 test -z "$as_dir" && as_dir=.
4648 for ac_exec_ext in '' $ac_executable_extensions; do
4649 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4650 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4652 break 2
4653 fi
4654 done
4655 done
4656 IFS=$as_save_IFS
4657
4658 fi
4659 fi
4660 CC=$ac_cv_prog_CC
4661 if test -n "$CC"; then
4662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4663 $as_echo "$CC" >&6; }
4664 else
4665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4666 $as_echo "no" >&6; }
4667 fi
4668
4669
4670 fi
4671 if test -z "$ac_cv_prog_CC"; then
4672 ac_ct_CC=$CC
4673 # Extract the first word of "gcc", so it can be a program name with args.
4674 set dummy gcc; ac_word=$2
4675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4676 $as_echo_n "checking for $ac_word... " >&6; }
4677 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4678 $as_echo_n "(cached) " >&6
4679 else
4680 if test -n "$ac_ct_CC"; then
4681 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4682 else
4683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4684 for as_dir in $PATH
4685 do
4686 IFS=$as_save_IFS
4687 test -z "$as_dir" && as_dir=.
4688 for ac_exec_ext in '' $ac_executable_extensions; do
4689 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4690 ac_cv_prog_ac_ct_CC="gcc"
4691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4692 break 2
4693 fi
4694 done
4695 done
4696 IFS=$as_save_IFS
4697
4698 fi
4699 fi
4700 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4701 if test -n "$ac_ct_CC"; then
4702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4703 $as_echo "$ac_ct_CC" >&6; }
4704 else
4705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4706 $as_echo "no" >&6; }
4707 fi
4708
4709 if test "x$ac_ct_CC" = x; then
4710 CC=""
4711 else
4712 case $cross_compiling:$ac_tool_warned in
4713 yes:)
4714 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4715 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4716 ac_tool_warned=yes ;;
4717 esac
4718 CC=$ac_ct_CC
4719 fi
4720 else
4721 CC="$ac_cv_prog_CC"
4722 fi
4723
4724 if test -z "$CC"; then
4725 if test -n "$ac_tool_prefix"; then
4726 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4727 set dummy ${ac_tool_prefix}cc; ac_word=$2
4728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4729 $as_echo_n "checking for $ac_word... " >&6; }
4730 if test "${ac_cv_prog_CC+set}" = set; then :
4731 $as_echo_n "(cached) " >&6
4732 else
4733 if test -n "$CC"; then
4734 ac_cv_prog_CC="$CC" # Let the user override the test.
4735 else
4736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4737 for as_dir in $PATH
4738 do
4739 IFS=$as_save_IFS
4740 test -z "$as_dir" && as_dir=.
4741 for ac_exec_ext in '' $ac_executable_extensions; do
4742 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4743 ac_cv_prog_CC="${ac_tool_prefix}cc"
4744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4745 break 2
4746 fi
4747 done
4748 done
4749 IFS=$as_save_IFS
4750
4751 fi
4752 fi
4753 CC=$ac_cv_prog_CC
4754 if test -n "$CC"; then
4755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4756 $as_echo "$CC" >&6; }
4757 else
4758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4759 $as_echo "no" >&6; }
4760 fi
4761
4762
4763 fi
4764 fi
4765 if test -z "$CC"; then
4766 # Extract the first word of "cc", so it can be a program name with args.
4767 set dummy cc; ac_word=$2
4768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4769 $as_echo_n "checking for $ac_word... " >&6; }
4770 if test "${ac_cv_prog_CC+set}" = set; then :
4771 $as_echo_n "(cached) " >&6
4772 else
4773 if test -n "$CC"; then
4774 ac_cv_prog_CC="$CC" # Let the user override the test.
4775 else
4776 ac_prog_rejected=no
4777 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4778 for as_dir in $PATH
4779 do
4780 IFS=$as_save_IFS
4781 test -z "$as_dir" && as_dir=.
4782 for ac_exec_ext in '' $ac_executable_extensions; do
4783 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4784 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4785 ac_prog_rejected=yes
4786 continue
4787 fi
4788 ac_cv_prog_CC="cc"
4789 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4790 break 2
4791 fi
4792 done
4793 done
4794 IFS=$as_save_IFS
4795
4796 if test $ac_prog_rejected = yes; then
4797 # We found a bogon in the path, so make sure we never use it.
4798 set dummy $ac_cv_prog_CC
4799 shift
4800 if test $# != 0; then
4801 # We chose a different compiler from the bogus one.
4802 # However, it has the same basename, so the bogon will be chosen
4803 # first if we set CC to just the basename; use the full file name.
4804 shift
4805 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4806 fi
4807 fi
4808 fi
4809 fi
4810 CC=$ac_cv_prog_CC
4811 if test -n "$CC"; then
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4813 $as_echo "$CC" >&6; }
4814 else
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4816 $as_echo "no" >&6; }
4817 fi
4818
4819
4820 fi
4821 if test -z "$CC"; then
4822 if test -n "$ac_tool_prefix"; then
4823 for ac_prog in cl.exe
4824 do
4825 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4826 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4828 $as_echo_n "checking for $ac_word... " >&6; }
4829 if test "${ac_cv_prog_CC+set}" = set; then :
4830 $as_echo_n "(cached) " >&6
4831 else
4832 if test -n "$CC"; then
4833 ac_cv_prog_CC="$CC" # Let the user override the test.
4834 else
4835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4836 for as_dir in $PATH
4837 do
4838 IFS=$as_save_IFS
4839 test -z "$as_dir" && as_dir=.
4840 for ac_exec_ext in '' $ac_executable_extensions; do
4841 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4842 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4844 break 2
4845 fi
4846 done
4847 done
4848 IFS=$as_save_IFS
4849
4850 fi
4851 fi
4852 CC=$ac_cv_prog_CC
4853 if test -n "$CC"; then
4854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4855 $as_echo "$CC" >&6; }
4856 else
4857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4858 $as_echo "no" >&6; }
4859 fi
4860
4861
4862 test -n "$CC" && break
4863 done
4864 fi
4865 if test -z "$CC"; then
4866 ac_ct_CC=$CC
4867 for ac_prog in cl.exe
4868 do
4869 # Extract the first word of "$ac_prog", so it can be a program name with args.
4870 set dummy $ac_prog; ac_word=$2
4871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4872 $as_echo_n "checking for $ac_word... " >&6; }
4873 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4874 $as_echo_n "(cached) " >&6
4875 else
4876 if test -n "$ac_ct_CC"; then
4877 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4878 else
4879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4880 for as_dir in $PATH
4881 do
4882 IFS=$as_save_IFS
4883 test -z "$as_dir" && as_dir=.
4884 for ac_exec_ext in '' $ac_executable_extensions; do
4885 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4886 ac_cv_prog_ac_ct_CC="$ac_prog"
4887 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4888 break 2
4889 fi
4890 done
4891 done
4892 IFS=$as_save_IFS
4893
4894 fi
4895 fi
4896 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4897 if test -n "$ac_ct_CC"; then
4898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4899 $as_echo "$ac_ct_CC" >&6; }
4900 else
4901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4902 $as_echo "no" >&6; }
4903 fi
4904
4905
4906 test -n "$ac_ct_CC" && break
4907 done
4908
4909 if test "x$ac_ct_CC" = x; then
4910 CC=""
4911 else
4912 case $cross_compiling:$ac_tool_warned in
4913 yes:)
4914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4915 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4916 ac_tool_warned=yes ;;
4917 esac
4918 CC=$ac_ct_CC
4919 fi
4920 fi
4921
4922 fi
4923
4924
4925 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4926 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4927 as_fn_error "no acceptable C compiler found in \$PATH
4928 See \`config.log' for more details." "$LINENO" 5; }
4929
4930 # Provide some information about the compiler.
4931 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4932 set X $ac_compile
4933 ac_compiler=$2
4934 for ac_option in --version -v -V -qversion; do
4935 { { ac_try="$ac_compiler $ac_option >&5"
4936 case "(($ac_try" in
4937 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4938 *) ac_try_echo=$ac_try;;
4939 esac
4940 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4941 $as_echo "$ac_try_echo"; } >&5
4942 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4943 ac_status=$?
4944 if test -s conftest.err; then
4945 sed '10a\
4946 ... rest of stderr output deleted ...
4947 10q' conftest.err >conftest.er1
4948 cat conftest.er1 >&5
4949 fi
4950 rm -f conftest.er1 conftest.err
4951 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4952 test $ac_status = 0; }
4953 done
4954
4955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4956 /* end confdefs.h. */
4957
4958 int
4959 main ()
4960 {
4961
4962 ;
4963 return 0;
4964 }
4965 _ACEOF
4966 ac_clean_files_save=$ac_clean_files
4967 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4968 # Try to create an executable without -o first, disregard a.out.
4969 # It will help us diagnose broken compilers, and finding out an intuition
4970 # of exeext.
4971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4972 $as_echo_n "checking whether the C compiler works... " >&6; }
4973 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4974
4975 # The possible output files:
4976 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4977
4978 ac_rmfiles=
4979 for ac_file in $ac_files
4980 do
4981 case $ac_file in
4982 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4983 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4984 esac
4985 done
4986 rm -f $ac_rmfiles
4987
4988 if { { ac_try="$ac_link_default"
4989 case "(($ac_try" in
4990 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4991 *) ac_try_echo=$ac_try;;
4992 esac
4993 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4994 $as_echo "$ac_try_echo"; } >&5
4995 (eval "$ac_link_default") 2>&5
4996 ac_status=$?
4997 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4998 test $ac_status = 0; }; then :
4999 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5000 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5001 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5002 # so that the user can short-circuit this test for compilers unknown to
5003 # Autoconf.
5004 for ac_file in $ac_files ''
5005 do
5006 test -f "$ac_file" || continue
5007 case $ac_file in
5008 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5009 ;;
5010 [ab].out )
5011 # We found the default executable, but exeext='' is most
5012 # certainly right.
5013 break;;
5014 *.* )
5015 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5016 then :; else
5017 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5018 fi
5019 # We set ac_cv_exeext here because the later test for it is not
5020 # safe: cross compilers may not add the suffix if given an `-o'
5021 # argument, so we may need to know it at that point already.
5022 # Even if this section looks crufty: it has the advantage of
5023 # actually working.
5024 break;;
5025 * )
5026 break;;
5027 esac
5028 done
5029 test "$ac_cv_exeext" = no && ac_cv_exeext=
5030
5031 else
5032 ac_file=''
5033 fi
5034 if test -z "$ac_file"; then :
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5036 $as_echo "no" >&6; }
5037 $as_echo "$as_me: failed program was:" >&5
5038 sed 's/^/| /' conftest.$ac_ext >&5
5039
5040 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5041 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5042 { as_fn_set_status 77
5043 as_fn_error "C compiler cannot create executables
5044 See \`config.log' for more details." "$LINENO" 5; }; }
5045 else
5046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5047 $as_echo "yes" >&6; }
5048 fi
5049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5050 $as_echo_n "checking for C compiler default output file name... " >&6; }
5051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5052 $as_echo "$ac_file" >&6; }
5053 ac_exeext=$ac_cv_exeext
5054
5055 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5056 ac_clean_files=$ac_clean_files_save
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5058 $as_echo_n "checking for suffix of executables... " >&6; }
5059 if { { ac_try="$ac_link"
5060 case "(($ac_try" in
5061 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5062 *) ac_try_echo=$ac_try;;
5063 esac
5064 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5065 $as_echo "$ac_try_echo"; } >&5
5066 (eval "$ac_link") 2>&5
5067 ac_status=$?
5068 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5069 test $ac_status = 0; }; then :
5070 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5071 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5072 # work properly (i.e., refer to `conftest.exe'), while it won't with
5073 # `rm'.
5074 for ac_file in conftest.exe conftest conftest.*; do
5075 test -f "$ac_file" || continue
5076 case $ac_file in
5077 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5078 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5079 break;;
5080 * ) break;;
5081 esac
5082 done
5083 else
5084 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5085 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5086 as_fn_error "cannot compute suffix of executables: cannot compile and link
5087 See \`config.log' for more details." "$LINENO" 5; }
5088 fi
5089 rm -f conftest conftest$ac_cv_exeext
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5091 $as_echo "$ac_cv_exeext" >&6; }
5092
5093 rm -f conftest.$ac_ext
5094 EXEEXT=$ac_cv_exeext
5095 ac_exeext=$EXEEXT
5096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5097 /* end confdefs.h. */
5098 #include <stdio.h>
5099 int
5100 main ()
5101 {
5102 FILE *f = fopen ("conftest.out", "w");
5103 return ferror (f) || fclose (f) != 0;
5104
5105 ;
5106 return 0;
5107 }
5108 _ACEOF
5109 ac_clean_files="$ac_clean_files conftest.out"
5110 # Check that the compiler produces executables we can run. If not, either
5111 # the compiler is broken, or we cross compile.
5112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5113 $as_echo_n "checking whether we are cross compiling... " >&6; }
5114 if test "$cross_compiling" != yes; then
5115 { { ac_try="$ac_link"
5116 case "(($ac_try" in
5117 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5118 *) ac_try_echo=$ac_try;;
5119 esac
5120 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5121 $as_echo "$ac_try_echo"; } >&5
5122 (eval "$ac_link") 2>&5
5123 ac_status=$?
5124 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5125 test $ac_status = 0; }
5126 if { ac_try='./conftest$ac_cv_exeext'
5127 { { case "(($ac_try" in
5128 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5129 *) ac_try_echo=$ac_try;;
5130 esac
5131 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5132 $as_echo "$ac_try_echo"; } >&5
5133 (eval "$ac_try") 2>&5
5134 ac_status=$?
5135 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5136 test $ac_status = 0; }; }; then
5137 cross_compiling=no
5138 else
5139 if test "$cross_compiling" = maybe; then
5140 cross_compiling=yes
5141 else
5142 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5143 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5144 as_fn_error "cannot run C compiled programs.
5145 If you meant to cross compile, use \`--host'.
5146 See \`config.log' for more details." "$LINENO" 5; }
5147 fi
5148 fi
5149 fi
5150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5151 $as_echo "$cross_compiling" >&6; }
5152
5153 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5154 ac_clean_files=$ac_clean_files_save
5155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5156 $as_echo_n "checking for suffix of object files... " >&6; }
5157 if test "${ac_cv_objext+set}" = set; then :
5158 $as_echo_n "(cached) " >&6
5159 else
5160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5161 /* end confdefs.h. */
5162
5163 int
5164 main ()
5165 {
5166
5167 ;
5168 return 0;
5169 }
5170 _ACEOF
5171 rm -f conftest.o conftest.obj
5172 if { { ac_try="$ac_compile"
5173 case "(($ac_try" in
5174 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5175 *) ac_try_echo=$ac_try;;
5176 esac
5177 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5178 $as_echo "$ac_try_echo"; } >&5
5179 (eval "$ac_compile") 2>&5
5180 ac_status=$?
5181 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5182 test $ac_status = 0; }; then :
5183 for ac_file in conftest.o conftest.obj conftest.*; do
5184 test -f "$ac_file" || continue;
5185 case $ac_file in
5186 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5187 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5188 break;;
5189 esac
5190 done
5191 else
5192 $as_echo "$as_me: failed program was:" >&5
5193 sed 's/^/| /' conftest.$ac_ext >&5
5194
5195 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5196 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5197 as_fn_error "cannot compute suffix of object files: cannot compile
5198 See \`config.log' for more details." "$LINENO" 5; }
5199 fi
5200 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5201 fi
5202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5203 $as_echo "$ac_cv_objext" >&6; }
5204 OBJEXT=$ac_cv_objext
5205 ac_objext=$OBJEXT
5206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5207 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5208 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5209 $as_echo_n "(cached) " >&6
5210 else
5211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5212 /* end confdefs.h. */
5213
5214 int
5215 main ()
5216 {
5217 #ifndef __GNUC__
5218 choke me
5219 #endif
5220
5221 ;
5222 return 0;
5223 }
5224 _ACEOF
5225 if ac_fn_c_try_compile "$LINENO"; then :
5226 ac_compiler_gnu=yes
5227 else
5228 ac_compiler_gnu=no
5229 fi
5230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5231 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5232
5233 fi
5234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5235 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5236 if test $ac_compiler_gnu = yes; then
5237 GCC=yes
5238 else
5239 GCC=
5240 fi
5241 ac_test_CFLAGS=${CFLAGS+set}
5242 ac_save_CFLAGS=$CFLAGS
5243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5244 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5245 if test "${ac_cv_prog_cc_g+set}" = set; then :
5246 $as_echo_n "(cached) " >&6
5247 else
5248 ac_save_c_werror_flag=$ac_c_werror_flag
5249 ac_c_werror_flag=yes
5250 ac_cv_prog_cc_g=no
5251 CFLAGS="-g"
5252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5253 /* end confdefs.h. */
5254
5255 int
5256 main ()
5257 {
5258
5259 ;
5260 return 0;
5261 }
5262 _ACEOF
5263 if ac_fn_c_try_compile "$LINENO"; then :
5264 ac_cv_prog_cc_g=yes
5265 else
5266 CFLAGS=""
5267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5268 /* end confdefs.h. */
5269
5270 int
5271 main ()
5272 {
5273
5274 ;
5275 return 0;
5276 }
5277 _ACEOF
5278 if ac_fn_c_try_compile "$LINENO"; then :
5279
5280 else
5281 ac_c_werror_flag=$ac_save_c_werror_flag
5282 CFLAGS="-g"
5283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5284 /* end confdefs.h. */
5285
5286 int
5287 main ()
5288 {
5289
5290 ;
5291 return 0;
5292 }
5293 _ACEOF
5294 if ac_fn_c_try_compile "$LINENO"; then :
5295 ac_cv_prog_cc_g=yes
5296 fi
5297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5298 fi
5299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5300 fi
5301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5302 ac_c_werror_flag=$ac_save_c_werror_flag
5303 fi
5304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5305 $as_echo "$ac_cv_prog_cc_g" >&6; }
5306 if test "$ac_test_CFLAGS" = set; then
5307 CFLAGS=$ac_save_CFLAGS
5308 elif test $ac_cv_prog_cc_g = yes; then
5309 if test "$GCC" = yes; then
5310 CFLAGS="-g -O2"
5311 else
5312 CFLAGS="-g"
5313 fi
5314 else
5315 if test "$GCC" = yes; then
5316 CFLAGS="-O2"
5317 else
5318 CFLAGS=
5319 fi
5320 fi
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5322 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5323 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5324 $as_echo_n "(cached) " >&6
5325 else
5326 ac_cv_prog_cc_c89=no
5327 ac_save_CC=$CC
5328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5329 /* end confdefs.h. */
5330 #include <stdarg.h>
5331 #include <stdio.h>
5332 #include <sys/types.h>
5333 #include <sys/stat.h>
5334 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5335 struct buf { int x; };
5336 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5337 static char *e (p, i)
5338 char **p;
5339 int i;
5340 {
5341 return p[i];
5342 }
5343 static char *f (char * (*g) (char **, int), char **p, ...)
5344 {
5345 char *s;
5346 va_list v;
5347 va_start (v,p);
5348 s = g (p, va_arg (v,int));
5349 va_end (v);
5350 return s;
5351 }
5352
5353 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5354 function prototypes and stuff, but not '\xHH' hex character constants.
5355 These don't provoke an error unfortunately, instead are silently treated
5356 as 'x'. The following induces an error, until -std is added to get
5357 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5358 array size at least. It's necessary to write '\x00'==0 to get something
5359 that's true only with -std. */
5360 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5361
5362 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5363 inside strings and character constants. */
5364 #define FOO(x) 'x'
5365 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5366
5367 int test (int i, double x);
5368 struct s1 {int (*f) (int a);};
5369 struct s2 {int (*f) (double a);};
5370 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5371 int argc;
5372 char **argv;
5373 int
5374 main ()
5375 {
5376 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5377 ;
5378 return 0;
5379 }
5380 _ACEOF
5381 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5382 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5383 do
5384 CC="$ac_save_CC $ac_arg"
5385 if ac_fn_c_try_compile "$LINENO"; then :
5386 ac_cv_prog_cc_c89=$ac_arg
5387 fi
5388 rm -f core conftest.err conftest.$ac_objext
5389 test "x$ac_cv_prog_cc_c89" != "xno" && break
5390 done
5391 rm -f conftest.$ac_ext
5392 CC=$ac_save_CC
5393
5394 fi
5395 # AC_CACHE_VAL
5396 case "x$ac_cv_prog_cc_c89" in
5397 x)
5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5399 $as_echo "none needed" >&6; } ;;
5400 xno)
5401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5402 $as_echo "unsupported" >&6; } ;;
5403 *)
5404 CC="$CC $ac_cv_prog_cc_c89"
5405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5406 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5407 esac
5408 if test "x$ac_cv_prog_cc_c89" != xno; then :
5409
5410 fi
5411
5412 ac_ext=c
5413 ac_cpp='$CPP $CPPFLAGS'
5414 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5415 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5416 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5417 DEPDIR="${am__leading_dot}deps"
5418
5419 ac_config_commands="$ac_config_commands depfiles"
5420
5421
5422 am_make=${MAKE-make}
5423 cat > confinc << 'END'
5424 am__doit:
5425 @echo this is the am__doit target
5426 .PHONY: am__doit
5427 END
5428 # If we don't find an include directive, just comment out the code.
5429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5430 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5431 am__include="#"
5432 am__quote=
5433 _am_result=none
5434 # First try GNU make style include.
5435 echo "include confinc" > confmf
5436 # Ignore all kinds of additional output from `make'.
5437 case `$am_make -s -f confmf 2> /dev/null` in #(
5438 *the\ am__doit\ target*)
5439 am__include=include
5440 am__quote=
5441 _am_result=GNU
5442 ;;
5443 esac
5444 # Now try BSD make style include.
5445 if test "$am__include" = "#"; then
5446 echo '.include "confinc"' > confmf
5447 case `$am_make -s -f confmf 2> /dev/null` in #(
5448 *the\ am__doit\ target*)
5449 am__include=.include
5450 am__quote="\""
5451 _am_result=BSD
5452 ;;
5453 esac
5454 fi
5455
5456
5457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5458 $as_echo "$_am_result" >&6; }
5459 rm -f confinc confmf
5460
5461 # Check whether --enable-dependency-tracking was given.
5462 if test "${enable_dependency_tracking+set}" = set; then :
5463 enableval=$enable_dependency_tracking;
5464 fi
5465
5466 if test "x$enable_dependency_tracking" != xno; then
5467 am_depcomp="$ac_aux_dir/depcomp"
5468 AMDEPBACKSLASH='\'
5469 fi
5470 if test "x$enable_dependency_tracking" != xno; then
5471 AMDEP_TRUE=
5472 AMDEP_FALSE='#'
5473 else
5474 AMDEP_TRUE='#'
5475 AMDEP_FALSE=
5476 fi
5477
5478
5479
5480 depcc="$CC" am_compiler_list=
5481
5482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5483 $as_echo_n "checking dependency style of $depcc... " >&6; }
5484 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5485 $as_echo_n "(cached) " >&6
5486 else
5487 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5488 # We make a subdir and do the tests there. Otherwise we can end up
5489 # making bogus files that we don't know about and never remove. For
5490 # instance it was reported that on HP-UX the gcc test will end up
5491 # making a dummy file named `D' -- because `-MD' means `put the output
5492 # in D'.
5493 mkdir conftest.dir
5494 # Copy depcomp to subdir because otherwise we won't find it if we're
5495 # using a relative directory.
5496 cp "$am_depcomp" conftest.dir
5497 cd conftest.dir
5498 # We will build objects and dependencies in a subdirectory because
5499 # it helps to detect inapplicable dependency modes. For instance
5500 # both Tru64's cc and ICC support -MD to output dependencies as a
5501 # side effect of compilation, but ICC will put the dependencies in
5502 # the current directory while Tru64 will put them in the object
5503 # directory.
5504 mkdir sub
5505
5506 am_cv_CC_dependencies_compiler_type=none
5507 if test "$am_compiler_list" = ""; then
5508 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5509 fi
5510 am__universal=false
5511 case " $depcc " in #(
5512 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5513 esac
5514
5515 for depmode in $am_compiler_list; do
5516 # Setup a source with many dependencies, because some compilers
5517 # like to wrap large dependency lists on column 80 (with \), and
5518 # we should not choose a depcomp mode which is confused by this.
5519 #
5520 # We need to recreate these files for each test, as the compiler may
5521 # overwrite some of them when testing with obscure command lines.
5522 # This happens at least with the AIX C compiler.
5523 : > sub/conftest.c
5524 for i in 1 2 3 4 5 6; do
5525 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5526 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5527 # Solaris 8's {/usr,}/bin/sh.
5528 touch sub/conftst$i.h
5529 done
5530 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5531
5532 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5533 # mode. It turns out that the SunPro C++ compiler does not properly
5534 # handle `-M -o', and we need to detect this. Also, some Intel
5535 # versions had trouble with output in subdirs
5536 am__obj=sub/conftest.${OBJEXT-o}
5537 am__minus_obj="-o $am__obj"
5538 case $depmode in
5539 gcc)
5540 # This depmode causes a compiler race in universal mode.
5541 test "$am__universal" = false || continue
5542 ;;
5543 nosideeffect)
5544 # after this tag, mechanisms are not by side-effect, so they'll
5545 # only be used when explicitly requested
5546 if test "x$enable_dependency_tracking" = xyes; then
5547 continue
5548 else
5549 break
5550 fi
5551 ;;
5552 msvisualcpp | msvcmsys)
5553 # This compiler won't grok `-c -o', but also, the minuso test has
5554 # not run yet. These depmodes are late enough in the game, and
5555 # so weak that their functioning should not be impacted.
5556 am__obj=conftest.${OBJEXT-o}
5557 am__minus_obj=
5558 ;;
5559 none) break ;;
5560 esac
5561 if depmode=$depmode \
5562 source=sub/conftest.c object=$am__obj \
5563 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5564 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5565 >/dev/null 2>conftest.err &&
5566 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5567 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5568 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5569 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5570 # icc doesn't choke on unknown options, it will just issue warnings
5571 # or remarks (even with -Werror). So we grep stderr for any message
5572 # that says an option was ignored or not supported.
5573 # When given -MP, icc 7.0 and 7.1 complain thusly:
5574 # icc: Command line warning: ignoring option '-M'; no argument required
5575 # The diagnosis changed in icc 8.0:
5576 # icc: Command line remark: option '-MP' not supported
5577 if (grep 'ignoring option' conftest.err ||
5578 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5579 am_cv_CC_dependencies_compiler_type=$depmode
5580 break
5581 fi
5582 fi
5583 done
5584
5585 cd ..
5586 rm -rf conftest.dir
5587 else
5588 am_cv_CC_dependencies_compiler_type=none
5589 fi
5590
5591 fi
5592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5593 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5594 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5595
5596 if
5597 test "x$enable_dependency_tracking" != xno \
5598 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5599 am__fastdepCC_TRUE=
5600 am__fastdepCC_FALSE='#'
5601 else
5602 am__fastdepCC_TRUE='#'
5603 am__fastdepCC_FALSE=
5604 fi
5605
5606
5607 if test "x$CC" != xcc; then
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5609 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5610 else
5611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5612 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5613 fi
5614 set dummy $CC; ac_cc=`$as_echo "$2" |
5615 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5616 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5617 $as_echo_n "(cached) " >&6
5618 else
5619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5620 /* end confdefs.h. */
5621
5622 int
5623 main ()
5624 {
5625
5626 ;
5627 return 0;
5628 }
5629 _ACEOF
5630 # Make sure it works both with $CC and with simple cc.
5631 # We do the test twice because some compilers refuse to overwrite an
5632 # existing .o file with -o, though they will create one.
5633 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5634 rm -f conftest2.*
5635 if { { case "(($ac_try" in
5636 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5637 *) ac_try_echo=$ac_try;;
5638 esac
5639 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5640 $as_echo "$ac_try_echo"; } >&5
5641 (eval "$ac_try") 2>&5
5642 ac_status=$?
5643 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5644 test $ac_status = 0; } &&
5645 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5646 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5647 *) ac_try_echo=$ac_try;;
5648 esac
5649 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5650 $as_echo "$ac_try_echo"; } >&5
5651 (eval "$ac_try") 2>&5
5652 ac_status=$?
5653 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5654 test $ac_status = 0; };
5655 then
5656 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5657 if test "x$CC" != xcc; then
5658 # Test first that cc exists at all.
5659 if { ac_try='cc -c conftest.$ac_ext >&5'
5660 { { case "(($ac_try" in
5661 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5662 *) ac_try_echo=$ac_try;;
5663 esac
5664 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5665 $as_echo "$ac_try_echo"; } >&5
5666 (eval "$ac_try") 2>&5
5667 ac_status=$?
5668 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5669 test $ac_status = 0; }; }; then
5670 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5671 rm -f conftest2.*
5672 if { { case "(($ac_try" in
5673 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5674 *) ac_try_echo=$ac_try;;
5675 esac
5676 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5677 $as_echo "$ac_try_echo"; } >&5
5678 (eval "$ac_try") 2>&5
5679 ac_status=$?
5680 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5681 test $ac_status = 0; } &&
5682 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5683 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5684 *) ac_try_echo=$ac_try;;
5685 esac
5686 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5687 $as_echo "$ac_try_echo"; } >&5
5688 (eval "$ac_try") 2>&5
5689 ac_status=$?
5690 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5691 test $ac_status = 0; };
5692 then
5693 # cc works too.
5694 :
5695 else
5696 # cc exists but doesn't like -o.
5697 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5698 fi
5699 fi
5700 fi
5701 else
5702 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5703 fi
5704 rm -f core conftest*
5705
5706 fi
5707 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5709 $as_echo "yes" >&6; }
5710 else
5711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5712 $as_echo "no" >&6; }
5713
5714 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5715
5716 fi
5717
5718 # FIXME: we rely on the cache variable name because
5719 # there is no other way.
5720 set dummy $CC
5721 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5722 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5723 if test "$am_t" != yes; then
5724 # Losing compiler, so override with the script.
5725 # FIXME: It is wrong to rewrite CC.
5726 # But if we don't then we get into trouble of one sort or another.
5727 # A longer-term fix would be to have automake use am__CC in this case,
5728 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5729 CC="$am_aux_dir/compile $CC"
5730 fi
5731
5732
5733
5734 if test x$GCC = xyes; then
5735 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5736 else
5737 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5738 fi
5739
5740 # Avoid gnulib's threadlib module, as we do threads our own way.
5741
5742
5743 # Initialize gnulib right after choosing the compiler.
5744
5745 ac_ext=c
5746 ac_cpp='$CPP $CPPFLAGS'
5747 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5748 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5749 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5751 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5752 # On Suns, sometimes $CPP names a directory.
5753 if test -n "$CPP" && test -d "$CPP"; then
5754 CPP=
5755 fi
5756 if test -z "$CPP"; then
5757 if test "${ac_cv_prog_CPP+set}" = set; then :
5758 $as_echo_n "(cached) " >&6
5759 else
5760 # Double quotes because CPP needs to be expanded
5761 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5762 do
5763 ac_preproc_ok=false
5764 for ac_c_preproc_warn_flag in '' yes
5765 do
5766 # Use a header file that comes with gcc, so configuring glibc
5767 # with a fresh cross-compiler works.
5768 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5769 # <limits.h> exists even on freestanding compilers.
5770 # On the NeXT, cc -E runs the code through the compiler's parser,
5771 # not just through cpp. "Syntax error" is here to catch this case.
5772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5773 /* end confdefs.h. */
5774 #ifdef __STDC__
5775 # include <limits.h>
5776 #else
5777 # include <assert.h>
5778 #endif
5779 Syntax error
5780 _ACEOF
5781 if ac_fn_c_try_cpp "$LINENO"; then :
5782
5783 else
5784 # Broken: fails on valid input.
5785 continue
5786 fi
5787 rm -f conftest.err conftest.$ac_ext
5788
5789 # OK, works on sane cases. Now check whether nonexistent headers
5790 # can be detected and how.
5791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5792 /* end confdefs.h. */
5793 #include <ac_nonexistent.h>
5794 _ACEOF
5795 if ac_fn_c_try_cpp "$LINENO"; then :
5796 # Broken: success on invalid input.
5797 continue
5798 else
5799 # Passes both tests.
5800 ac_preproc_ok=:
5801 break
5802 fi
5803 rm -f conftest.err conftest.$ac_ext
5804
5805 done
5806 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5807 rm -f conftest.err conftest.$ac_ext
5808 if $ac_preproc_ok; then :
5809 break
5810 fi
5811
5812 done
5813 ac_cv_prog_CPP=$CPP
5814
5815 fi
5816 CPP=$ac_cv_prog_CPP
5817 else
5818 ac_cv_prog_CPP=$CPP
5819 fi
5820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5821 $as_echo "$CPP" >&6; }
5822 ac_preproc_ok=false
5823 for ac_c_preproc_warn_flag in '' yes
5824 do
5825 # Use a header file that comes with gcc, so configuring glibc
5826 # with a fresh cross-compiler works.
5827 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5828 # <limits.h> exists even on freestanding compilers.
5829 # On the NeXT, cc -E runs the code through the compiler's parser,
5830 # not just through cpp. "Syntax error" is here to catch this case.
5831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5832 /* end confdefs.h. */
5833 #ifdef __STDC__
5834 # include <limits.h>
5835 #else
5836 # include <assert.h>
5837 #endif
5838 Syntax error
5839 _ACEOF
5840 if ac_fn_c_try_cpp "$LINENO"; then :
5841
5842 else
5843 # Broken: fails on valid input.
5844 continue
5845 fi
5846 rm -f conftest.err conftest.$ac_ext
5847
5848 # OK, works on sane cases. Now check whether nonexistent headers
5849 # can be detected and how.
5850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5851 /* end confdefs.h. */
5852 #include <ac_nonexistent.h>
5853 _ACEOF
5854 if ac_fn_c_try_cpp "$LINENO"; then :
5855 # Broken: success on invalid input.
5856 continue
5857 else
5858 # Passes both tests.
5859 ac_preproc_ok=:
5860 break
5861 fi
5862 rm -f conftest.err conftest.$ac_ext
5863
5864 done
5865 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5866 rm -f conftest.err conftest.$ac_ext
5867 if $ac_preproc_ok; then :
5868
5869 else
5870 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5871 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5872 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5873 See \`config.log' for more details." "$LINENO" 5; }
5874 fi
5875
5876 ac_ext=c
5877 ac_cpp='$CPP $CPPFLAGS'
5878 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5879 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5880 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5881
5882
5883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5884 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5885 if test "${ac_cv_path_GREP+set}" = set; then :
5886 $as_echo_n "(cached) " >&6
5887 else
5888 if test -z "$GREP"; then
5889 ac_path_GREP_found=false
5890 # Loop through the user's path and test for each of PROGNAME-LIST
5891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5892 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5893 do
5894 IFS=$as_save_IFS
5895 test -z "$as_dir" && as_dir=.
5896 for ac_prog in grep ggrep; do
5897 for ac_exec_ext in '' $ac_executable_extensions; do
5898 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5899 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5900 # Check for GNU ac_path_GREP and select it if it is found.
5901 # Check for GNU $ac_path_GREP
5902 case `"$ac_path_GREP" --version 2>&1` in
5903 *GNU*)
5904 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5905 *)
5906 ac_count=0
5907 $as_echo_n 0123456789 >"conftest.in"
5908 while :
5909 do
5910 cat "conftest.in" "conftest.in" >"conftest.tmp"
5911 mv "conftest.tmp" "conftest.in"
5912 cp "conftest.in" "conftest.nl"
5913 $as_echo 'GREP' >> "conftest.nl"
5914 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5915 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5916 as_fn_arith $ac_count + 1 && ac_count=$as_val
5917 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5918 # Best one so far, save it but keep looking for a better one
5919 ac_cv_path_GREP="$ac_path_GREP"
5920 ac_path_GREP_max=$ac_count
5921 fi
5922 # 10*(2^10) chars as input seems more than enough
5923 test $ac_count -gt 10 && break
5924 done
5925 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5926 esac
5927
5928 $ac_path_GREP_found && break 3
5929 done
5930 done
5931 done
5932 IFS=$as_save_IFS
5933 if test -z "$ac_cv_path_GREP"; then
5934 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5935 fi
5936 else
5937 ac_cv_path_GREP=$GREP
5938 fi
5939
5940 fi
5941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5942 $as_echo "$ac_cv_path_GREP" >&6; }
5943 GREP="$ac_cv_path_GREP"
5944
5945
5946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5947 $as_echo_n "checking for egrep... " >&6; }
5948 if test "${ac_cv_path_EGREP+set}" = set; then :
5949 $as_echo_n "(cached) " >&6
5950 else
5951 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5952 then ac_cv_path_EGREP="$GREP -E"
5953 else
5954 if test -z "$EGREP"; then
5955 ac_path_EGREP_found=false
5956 # Loop through the user's path and test for each of PROGNAME-LIST
5957 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5958 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5959 do
5960 IFS=$as_save_IFS
5961 test -z "$as_dir" && as_dir=.
5962 for ac_prog in egrep; do
5963 for ac_exec_ext in '' $ac_executable_extensions; do
5964 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5965 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5966 # Check for GNU ac_path_EGREP and select it if it is found.
5967 # Check for GNU $ac_path_EGREP
5968 case `"$ac_path_EGREP" --version 2>&1` in
5969 *GNU*)
5970 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5971 *)
5972 ac_count=0
5973 $as_echo_n 0123456789 >"conftest.in"
5974 while :
5975 do
5976 cat "conftest.in" "conftest.in" >"conftest.tmp"
5977 mv "conftest.tmp" "conftest.in"
5978 cp "conftest.in" "conftest.nl"
5979 $as_echo 'EGREP' >> "conftest.nl"
5980 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5981 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5982 as_fn_arith $ac_count + 1 && ac_count=$as_val
5983 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5984 # Best one so far, save it but keep looking for a better one
5985 ac_cv_path_EGREP="$ac_path_EGREP"
5986 ac_path_EGREP_max=$ac_count
5987 fi
5988 # 10*(2^10) chars as input seems more than enough
5989 test $ac_count -gt 10 && break
5990 done
5991 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5992 esac
5993
5994 $ac_path_EGREP_found && break 3
5995 done
5996 done
5997 done
5998 IFS=$as_save_IFS
5999 if test -z "$ac_cv_path_EGREP"; then
6000 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6001 fi
6002 else
6003 ac_cv_path_EGREP=$EGREP
6004 fi
6005
6006 fi
6007 fi
6008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6009 $as_echo "$ac_cv_path_EGREP" >&6; }
6010 EGREP="$ac_cv_path_EGREP"
6011
6012
6013
6014
6015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6016 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6017 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6018 $as_echo_n "(cached) " >&6
6019 else
6020
6021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6022 /* end confdefs.h. */
6023
6024 #ifdef __ACK__
6025 Amsterdam
6026 #endif
6027
6028 _ACEOF
6029 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6030 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6031 gl_cv_c_amsterdam_compiler=yes
6032 else
6033 gl_cv_c_amsterdam_compiler=no
6034 fi
6035 rm -f conftest*
6036
6037
6038 fi
6039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6040 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6041 if test -z "$AR"; then
6042 if test $gl_cv_c_amsterdam_compiler = yes; then
6043 AR='cc -c.a'
6044 if test -z "$ARFLAGS"; then
6045 ARFLAGS='-o'
6046 fi
6047 else
6048 if test -n "$ac_tool_prefix"; then
6049 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6050 set dummy ${ac_tool_prefix}ar; ac_word=$2
6051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6052 $as_echo_n "checking for $ac_word... " >&6; }
6053 if test "${ac_cv_prog_AR+set}" = set; then :
6054 $as_echo_n "(cached) " >&6
6055 else
6056 if test -n "$AR"; then
6057 ac_cv_prog_AR="$AR" # Let the user override the test.
6058 else
6059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6060 for as_dir in $PATH
6061 do
6062 IFS=$as_save_IFS
6063 test -z "$as_dir" && as_dir=.
6064 for ac_exec_ext in '' $ac_executable_extensions; do
6065 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6066 ac_cv_prog_AR="${ac_tool_prefix}ar"
6067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6068 break 2
6069 fi
6070 done
6071 done
6072 IFS=$as_save_IFS
6073
6074 fi
6075 fi
6076 AR=$ac_cv_prog_AR
6077 if test -n "$AR"; then
6078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6079 $as_echo "$AR" >&6; }
6080 else
6081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6082 $as_echo "no" >&6; }
6083 fi
6084
6085
6086 fi
6087 if test -z "$ac_cv_prog_AR"; then
6088 ac_ct_AR=$AR
6089 # Extract the first word of "ar", so it can be a program name with args.
6090 set dummy ar; ac_word=$2
6091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6092 $as_echo_n "checking for $ac_word... " >&6; }
6093 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6094 $as_echo_n "(cached) " >&6
6095 else
6096 if test -n "$ac_ct_AR"; then
6097 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6098 else
6099 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6100 for as_dir in $PATH
6101 do
6102 IFS=$as_save_IFS
6103 test -z "$as_dir" && as_dir=.
6104 for ac_exec_ext in '' $ac_executable_extensions; do
6105 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6106 ac_cv_prog_ac_ct_AR="ar"
6107 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6108 break 2
6109 fi
6110 done
6111 done
6112 IFS=$as_save_IFS
6113
6114 fi
6115 fi
6116 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6117 if test -n "$ac_ct_AR"; then
6118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6119 $as_echo "$ac_ct_AR" >&6; }
6120 else
6121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6122 $as_echo "no" >&6; }
6123 fi
6124
6125 if test "x$ac_ct_AR" = x; then
6126 AR="ar"
6127 else
6128 case $cross_compiling:$ac_tool_warned in
6129 yes:)
6130 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6131 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6132 ac_tool_warned=yes ;;
6133 esac
6134 AR=$ac_ct_AR
6135 fi
6136 else
6137 AR="$ac_cv_prog_AR"
6138 fi
6139
6140 if test -z "$ARFLAGS"; then
6141 ARFLAGS='cru'
6142 fi
6143 fi
6144 else
6145 if test -z "$ARFLAGS"; then
6146 ARFLAGS='cru'
6147 fi
6148 fi
6149
6150
6151 if test -z "$RANLIB"; then
6152 if test $gl_cv_c_amsterdam_compiler = yes; then
6153 RANLIB=':'
6154 else
6155 if test -n "$ac_tool_prefix"; then
6156 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6157 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6159 $as_echo_n "checking for $ac_word... " >&6; }
6160 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6161 $as_echo_n "(cached) " >&6
6162 else
6163 if test -n "$RANLIB"; then
6164 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6165 else
6166 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6167 for as_dir in $PATH
6168 do
6169 IFS=$as_save_IFS
6170 test -z "$as_dir" && as_dir=.
6171 for ac_exec_ext in '' $ac_executable_extensions; do
6172 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6173 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6174 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6175 break 2
6176 fi
6177 done
6178 done
6179 IFS=$as_save_IFS
6180
6181 fi
6182 fi
6183 RANLIB=$ac_cv_prog_RANLIB
6184 if test -n "$RANLIB"; then
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6186 $as_echo "$RANLIB" >&6; }
6187 else
6188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6189 $as_echo "no" >&6; }
6190 fi
6191
6192
6193 fi
6194 if test -z "$ac_cv_prog_RANLIB"; then
6195 ac_ct_RANLIB=$RANLIB
6196 # Extract the first word of "ranlib", so it can be a program name with args.
6197 set dummy ranlib; ac_word=$2
6198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6199 $as_echo_n "checking for $ac_word... " >&6; }
6200 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6201 $as_echo_n "(cached) " >&6
6202 else
6203 if test -n "$ac_ct_RANLIB"; then
6204 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6205 else
6206 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6207 for as_dir in $PATH
6208 do
6209 IFS=$as_save_IFS
6210 test -z "$as_dir" && as_dir=.
6211 for ac_exec_ext in '' $ac_executable_extensions; do
6212 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6213 ac_cv_prog_ac_ct_RANLIB="ranlib"
6214 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6215 break 2
6216 fi
6217 done
6218 done
6219 IFS=$as_save_IFS
6220
6221 fi
6222 fi
6223 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6224 if test -n "$ac_ct_RANLIB"; then
6225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6226 $as_echo "$ac_ct_RANLIB" >&6; }
6227 else
6228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6229 $as_echo "no" >&6; }
6230 fi
6231
6232 if test "x$ac_ct_RANLIB" = x; then
6233 RANLIB=":"
6234 else
6235 case $cross_compiling:$ac_tool_warned in
6236 yes:)
6237 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6238 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6239 ac_tool_warned=yes ;;
6240 esac
6241 RANLIB=$ac_ct_RANLIB
6242 fi
6243 else
6244 RANLIB="$ac_cv_prog_RANLIB"
6245 fi
6246
6247 fi
6248 fi
6249
6250
6251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6252 $as_echo_n "checking for ANSI C header files... " >&6; }
6253 if test "${ac_cv_header_stdc+set}" = set; then :
6254 $as_echo_n "(cached) " >&6
6255 else
6256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6257 /* end confdefs.h. */
6258 #include <stdlib.h>
6259 #include <stdarg.h>
6260 #include <string.h>
6261 #include <float.h>
6262
6263 int
6264 main ()
6265 {
6266
6267 ;
6268 return 0;
6269 }
6270 _ACEOF
6271 if ac_fn_c_try_compile "$LINENO"; then :
6272 ac_cv_header_stdc=yes
6273 else
6274 ac_cv_header_stdc=no
6275 fi
6276 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6277
6278 if test $ac_cv_header_stdc = yes; then
6279 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6281 /* end confdefs.h. */
6282 #include <string.h>
6283
6284 _ACEOF
6285 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6286 $EGREP "memchr" >/dev/null 2>&1; then :
6287
6288 else
6289 ac_cv_header_stdc=no
6290 fi
6291 rm -f conftest*
6292
6293 fi
6294
6295 if test $ac_cv_header_stdc = yes; then
6296 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6298 /* end confdefs.h. */
6299 #include <stdlib.h>
6300
6301 _ACEOF
6302 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6303 $EGREP "free" >/dev/null 2>&1; then :
6304
6305 else
6306 ac_cv_header_stdc=no
6307 fi
6308 rm -f conftest*
6309
6310 fi
6311
6312 if test $ac_cv_header_stdc = yes; then
6313 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6314 if test "$cross_compiling" = yes; then :
6315 :
6316 else
6317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6318 /* end confdefs.h. */
6319 #include <ctype.h>
6320 #include <stdlib.h>
6321 #if ((' ' & 0x0FF) == 0x020)
6322 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6323 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6324 #else
6325 # define ISLOWER(c) \
6326 (('a' <= (c) && (c) <= 'i') \
6327 || ('j' <= (c) && (c) <= 'r') \
6328 || ('s' <= (c) && (c) <= 'z'))
6329 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6330 #endif
6331
6332 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6333 int
6334 main ()
6335 {
6336 int i;
6337 for (i = 0; i < 256; i++)
6338 if (XOR (islower (i), ISLOWER (i))
6339 || toupper (i) != TOUPPER (i))
6340 return 2;
6341 return 0;
6342 }
6343 _ACEOF
6344 if ac_fn_c_try_run "$LINENO"; then :
6345
6346 else
6347 ac_cv_header_stdc=no
6348 fi
6349 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6350 conftest.$ac_objext conftest.beam conftest.$ac_ext
6351 fi
6352
6353 fi
6354 fi
6355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6356 $as_echo "$ac_cv_header_stdc" >&6; }
6357 if test $ac_cv_header_stdc = yes; then
6358
6359 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6360
6361 fi
6362
6363 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6364 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6365 inttypes.h stdint.h unistd.h
6366 do :
6367 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6368 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6369 "
6370 eval as_val=\$$as_ac_Header
6371 if test "x$as_val" = x""yes; then :
6372 cat >>confdefs.h <<_ACEOF
6373 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6374 _ACEOF
6375
6376 fi
6377
6378 done
6379
6380
6381
6382
6383
6384 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6385 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6386 MINIX=yes
6387 else
6388 MINIX=
6389 fi
6390
6391
6392 if test "$MINIX" = yes; then
6393
6394 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6395
6396
6397 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6398
6399
6400 $as_echo "#define _MINIX 1" >>confdefs.h
6401
6402 fi
6403
6404 case "$host_os" in
6405 hpux*)
6406
6407 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6408
6409 ;;
6410 esac
6411
6412
6413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6414 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6415 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6416 $as_echo_n "(cached) " >&6
6417 else
6418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6419 /* end confdefs.h. */
6420
6421 # define __EXTENSIONS__ 1
6422 $ac_includes_default
6423 int
6424 main ()
6425 {
6426
6427 ;
6428 return 0;
6429 }
6430 _ACEOF
6431 if ac_fn_c_try_compile "$LINENO"; then :
6432 ac_cv_safe_to_define___extensions__=yes
6433 else
6434 ac_cv_safe_to_define___extensions__=no
6435 fi
6436 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6437 fi
6438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6439 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6440 test $ac_cv_safe_to_define___extensions__ = yes &&
6441 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6442
6443 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6444
6445 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6446
6447 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6448
6449 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6450
6451 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6452
6453
6454
6455
6456
6457
6458
6459
6460 # Check whether --enable-largefile was given.
6461 if test "${enable_largefile+set}" = set; then :
6462 enableval=$enable_largefile;
6463 fi
6464
6465 if test "$enable_largefile" != no; then
6466
6467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6468 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6469 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6470 $as_echo_n "(cached) " >&6
6471 else
6472 ac_cv_sys_largefile_CC=no
6473 if test "$GCC" != yes; then
6474 ac_save_CC=$CC
6475 while :; do
6476 # IRIX 6.2 and later do not support large files by default,
6477 # so use the C compiler's -n32 option if that helps.
6478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6479 /* end confdefs.h. */
6480 #include <sys/types.h>
6481 /* Check that off_t can represent 2**63 - 1 correctly.
6482 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6483 since some C++ compilers masquerading as C compilers
6484 incorrectly reject 9223372036854775807. */
6485 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6486 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6487 && LARGE_OFF_T % 2147483647 == 1)
6488 ? 1 : -1];
6489 int
6490 main ()
6491 {
6492
6493 ;
6494 return 0;
6495 }
6496 _ACEOF
6497 if ac_fn_c_try_compile "$LINENO"; then :
6498 break
6499 fi
6500 rm -f core conftest.err conftest.$ac_objext
6501 CC="$CC -n32"
6502 if ac_fn_c_try_compile "$LINENO"; then :
6503 ac_cv_sys_largefile_CC=' -n32'; break
6504 fi
6505 rm -f core conftest.err conftest.$ac_objext
6506 break
6507 done
6508 CC=$ac_save_CC
6509 rm -f conftest.$ac_ext
6510 fi
6511 fi
6512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6513 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6514 if test "$ac_cv_sys_largefile_CC" != no; then
6515 CC=$CC$ac_cv_sys_largefile_CC
6516 fi
6517
6518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6519 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6520 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6521 $as_echo_n "(cached) " >&6
6522 else
6523 while :; do
6524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6525 /* end confdefs.h. */
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];
6535 int
6536 main ()
6537 {
6538
6539 ;
6540 return 0;
6541 }
6542 _ACEOF
6543 if ac_fn_c_try_compile "$LINENO"; then :
6544 ac_cv_sys_file_offset_bits=no; break
6545 fi
6546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6548 /* end confdefs.h. */
6549 #define _FILE_OFFSET_BITS 64
6550 #include <sys/types.h>
6551 /* Check that off_t can represent 2**63 - 1 correctly.
6552 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6553 since some C++ compilers masquerading as C compilers
6554 incorrectly reject 9223372036854775807. */
6555 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6556 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6557 && LARGE_OFF_T % 2147483647 == 1)
6558 ? 1 : -1];
6559 int
6560 main ()
6561 {
6562
6563 ;
6564 return 0;
6565 }
6566 _ACEOF
6567 if ac_fn_c_try_compile "$LINENO"; then :
6568 ac_cv_sys_file_offset_bits=64; break
6569 fi
6570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6571 ac_cv_sys_file_offset_bits=unknown
6572 break
6573 done
6574 fi
6575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6576 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6577 case $ac_cv_sys_file_offset_bits in #(
6578 no | unknown) ;;
6579 *)
6580 cat >>confdefs.h <<_ACEOF
6581 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6582 _ACEOF
6583 ;;
6584 esac
6585 rm -rf conftest*
6586 if test $ac_cv_sys_file_offset_bits = unknown; then
6587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6588 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6589 if test "${ac_cv_sys_large_files+set}" = set; then :
6590 $as_echo_n "(cached) " >&6
6591 else
6592 while :; do
6593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6594 /* end confdefs.h. */
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];
6604 int
6605 main ()
6606 {
6607
6608 ;
6609 return 0;
6610 }
6611 _ACEOF
6612 if ac_fn_c_try_compile "$LINENO"; then :
6613 ac_cv_sys_large_files=no; break
6614 fi
6615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6617 /* end confdefs.h. */
6618 #define _LARGE_FILES 1
6619 #include <sys/types.h>
6620 /* Check that off_t can represent 2**63 - 1 correctly.
6621 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6622 since some C++ compilers masquerading as C compilers
6623 incorrectly reject 9223372036854775807. */
6624 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6625 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6626 && LARGE_OFF_T % 2147483647 == 1)
6627 ? 1 : -1];
6628 int
6629 main ()
6630 {
6631
6632 ;
6633 return 0;
6634 }
6635 _ACEOF
6636 if ac_fn_c_try_compile "$LINENO"; then :
6637 ac_cv_sys_large_files=1; break
6638 fi
6639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6640 ac_cv_sys_large_files=unknown
6641 break
6642 done
6643 fi
6644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6645 $as_echo "$ac_cv_sys_large_files" >&6; }
6646 case $ac_cv_sys_large_files in #(
6647 no | unknown) ;;
6648 *)
6649 cat >>confdefs.h <<_ACEOF
6650 #define _LARGE_FILES $ac_cv_sys_large_files
6651 _ACEOF
6652 ;;
6653 esac
6654 rm -rf conftest*
6655 fi
6656
6657
6658 fi
6659
6660 case $ac_cv_prog_cc_stdc in #(
6661 no) :
6662 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6663 *) :
6664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6665 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6666 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6667 $as_echo_n "(cached) " >&6
6668 else
6669 ac_cv_prog_cc_c99=no
6670 ac_save_CC=$CC
6671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6672 /* end confdefs.h. */
6673 #include <stdarg.h>
6674 #include <stdbool.h>
6675 #include <stdlib.h>
6676 #include <wchar.h>
6677 #include <stdio.h>
6678
6679 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6680 #define debug(...) fprintf (stderr, __VA_ARGS__)
6681 #define showlist(...) puts (#__VA_ARGS__)
6682 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6683 static void
6684 test_varargs_macros (void)
6685 {
6686 int x = 1234;
6687 int y = 5678;
6688 debug ("Flag");
6689 debug ("X = %d\n", x);
6690 showlist (The first, second, and third items.);
6691 report (x>y, "x is %d but y is %d", x, y);
6692 }
6693
6694 // Check long long types.
6695 #define BIG64 18446744073709551615ull
6696 #define BIG32 4294967295ul
6697 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6698 #if !BIG_OK
6699 your preprocessor is broken;
6700 #endif
6701 #if BIG_OK
6702 #else
6703 your preprocessor is broken;
6704 #endif
6705 static long long int bignum = -9223372036854775807LL;
6706 static unsigned long long int ubignum = BIG64;
6707
6708 struct incomplete_array
6709 {
6710 int datasize;
6711 double data[];
6712 };
6713
6714 struct named_init {
6715 int number;
6716 const wchar_t *name;
6717 double average;
6718 };
6719
6720 typedef const char *ccp;
6721
6722 static inline int
6723 test_restrict (ccp restrict text)
6724 {
6725 // See if C++-style comments work.
6726 // Iterate through items via the restricted pointer.
6727 // Also check for declarations in for loops.
6728 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6729 continue;
6730 return 0;
6731 }
6732
6733 // Check varargs and va_copy.
6734 static void
6735 test_varargs (const char *format, ...)
6736 {
6737 va_list args;
6738 va_start (args, format);
6739 va_list args_copy;
6740 va_copy (args_copy, args);
6741
6742 const char *str;
6743 int number;
6744 float fnumber;
6745
6746 while (*format)
6747 {
6748 switch (*format++)
6749 {
6750 case 's': // string
6751 str = va_arg (args_copy, const char *);
6752 break;
6753 case 'd': // int
6754 number = va_arg (args_copy, int);
6755 break;
6756 case 'f': // float
6757 fnumber = va_arg (args_copy, double);
6758 break;
6759 default:
6760 break;
6761 }
6762 }
6763 va_end (args_copy);
6764 va_end (args);
6765 }
6766
6767 int
6768 main ()
6769 {
6770
6771 // Check bool.
6772 _Bool success = false;
6773
6774 // Check restrict.
6775 if (test_restrict ("String literal") == 0)
6776 success = true;
6777 char *restrict newvar = "Another string";
6778
6779 // Check varargs.
6780 test_varargs ("s, d' f .", "string", 65, 34.234);
6781 test_varargs_macros ();
6782
6783 // Check flexible array members.
6784 struct incomplete_array *ia =
6785 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6786 ia->datasize = 10;
6787 for (int i = 0; i < ia->datasize; ++i)
6788 ia->data[i] = i * 1.234;
6789
6790 // Check named initializers.
6791 struct named_init ni = {
6792 .number = 34,
6793 .name = L"Test wide string",
6794 .average = 543.34343,
6795 };
6796
6797 ni.number = 58;
6798
6799 int dynamic_array[ni.number];
6800 dynamic_array[ni.number - 1] = 543;
6801
6802 // work around unused variable warnings
6803 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6804 || dynamic_array[ni.number - 1] != 543);
6805
6806 ;
6807 return 0;
6808 }
6809 _ACEOF
6810 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6811 do
6812 CC="$ac_save_CC $ac_arg"
6813 if ac_fn_c_try_compile "$LINENO"; then :
6814 ac_cv_prog_cc_c99=$ac_arg
6815 fi
6816 rm -f core conftest.err conftest.$ac_objext
6817 test "x$ac_cv_prog_cc_c99" != "xno" && break
6818 done
6819 rm -f conftest.$ac_ext
6820 CC=$ac_save_CC
6821
6822 fi
6823 # AC_CACHE_VAL
6824 case "x$ac_cv_prog_cc_c99" in
6825 x)
6826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6827 $as_echo "none needed" >&6; } ;;
6828 xno)
6829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6830 $as_echo "unsupported" >&6; } ;;
6831 *)
6832 CC="$CC $ac_cv_prog_cc_c99"
6833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6834 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6835 esac
6836 if test "x$ac_cv_prog_cc_c99" != xno; then :
6837 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6838 else
6839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6840 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6841 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6842 $as_echo_n "(cached) " >&6
6843 else
6844 ac_cv_prog_cc_c89=no
6845 ac_save_CC=$CC
6846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6847 /* end confdefs.h. */
6848 #include <stdarg.h>
6849 #include <stdio.h>
6850 #include <sys/types.h>
6851 #include <sys/stat.h>
6852 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6853 struct buf { int x; };
6854 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6855 static char *e (p, i)
6856 char **p;
6857 int i;
6858 {
6859 return p[i];
6860 }
6861 static char *f (char * (*g) (char **, int), char **p, ...)
6862 {
6863 char *s;
6864 va_list v;
6865 va_start (v,p);
6866 s = g (p, va_arg (v,int));
6867 va_end (v);
6868 return s;
6869 }
6870
6871 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6872 function prototypes and stuff, but not '\xHH' hex character constants.
6873 These don't provoke an error unfortunately, instead are silently treated
6874 as 'x'. The following induces an error, until -std is added to get
6875 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6876 array size at least. It's necessary to write '\x00'==0 to get something
6877 that's true only with -std. */
6878 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6879
6880 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6881 inside strings and character constants. */
6882 #define FOO(x) 'x'
6883 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6884
6885 int test (int i, double x);
6886 struct s1 {int (*f) (int a);};
6887 struct s2 {int (*f) (double a);};
6888 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6889 int argc;
6890 char **argv;
6891 int
6892 main ()
6893 {
6894 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6895 ;
6896 return 0;
6897 }
6898 _ACEOF
6899 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6900 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6901 do
6902 CC="$ac_save_CC $ac_arg"
6903 if ac_fn_c_try_compile "$LINENO"; then :
6904 ac_cv_prog_cc_c89=$ac_arg
6905 fi
6906 rm -f core conftest.err conftest.$ac_objext
6907 test "x$ac_cv_prog_cc_c89" != "xno" && break
6908 done
6909 rm -f conftest.$ac_ext
6910 CC=$ac_save_CC
6911
6912 fi
6913 # AC_CACHE_VAL
6914 case "x$ac_cv_prog_cc_c89" in
6915 x)
6916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6917 $as_echo "none needed" >&6; } ;;
6918 xno)
6919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6920 $as_echo "unsupported" >&6; } ;;
6921 *)
6922 CC="$CC $ac_cv_prog_cc_c89"
6923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6924 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6925 esac
6926 if test "x$ac_cv_prog_cc_c89" != xno; then :
6927 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6928 else
6929 ac_cv_prog_cc_stdc=no
6930 fi
6931
6932 fi
6933 ;;
6934 esac
6935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6936 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6937 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6938 $as_echo_n "(cached) " >&6
6939 fi
6940
6941 case $ac_cv_prog_cc_stdc in #(
6942 no) :
6943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6944 $as_echo "unsupported" >&6; } ;; #(
6945 '') :
6946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6947 $as_echo "none needed" >&6; } ;; #(
6948 *) :
6949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6950 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6951 esac
6952
6953
6954
6955 # Code from module alloca-opt:
6956 # Code from module allocator:
6957 # Code from module c-ctype:
6958 # Code from module c-strcase:
6959 # Code from module careadlinkat:
6960 # Code from module clock-time:
6961 # Code from module crypto/md5:
6962 # Code from module crypto/sha1:
6963 # Code from module crypto/sha256:
6964 # Code from module crypto/sha512:
6965 # Code from module dosname:
6966 # Code from module dtoastr:
6967 # Code from module dtotimespec:
6968 # Code from module dup2:
6969 # Code from module environ:
6970 # Code from module execinfo:
6971 # Code from module extensions:
6972
6973 # Code from module extern-inline:
6974 # Code from module filemode:
6975 # Code from module getloadavg:
6976 # Code from module getopt-gnu:
6977 # Code from module getopt-posix:
6978 # Code from module gettext-h:
6979 # Code from module gettime:
6980 # Code from module gettimeofday:
6981 # Code from module ignore-value:
6982 # Code from module include_next:
6983 # Code from module intprops:
6984 # Code from module inttypes-incomplete:
6985 # Code from module largefile:
6986
6987 # Code from module lstat:
6988 # Code from module manywarnings:
6989 # Code from module mktime:
6990 # Code from module multiarch:
6991 # Code from module nocrash:
6992 # Code from module pathmax:
6993 # Code from module pselect:
6994 # Code from module pthread_sigmask:
6995 # Code from module readlink:
6996 # Code from module signal-h:
6997 # Code from module snippet/_Noreturn:
6998 # Code from module snippet/arg-nonnull:
6999 # Code from module snippet/c++defs:
7000 # Code from module snippet/warn-on-use:
7001 # Code from module socklen:
7002 # Code from module ssize_t:
7003 # Code from module stat:
7004 # Code from module stat-time:
7005 # Code from module stdalign:
7006 # Code from module stdarg:
7007
7008
7009
7010 # Code from module stdbool:
7011 # Code from module stddef:
7012 # Code from module stdint:
7013 # Code from module stdio:
7014 # Code from module stdlib:
7015 # Code from module strftime:
7016 # Code from module strtoimax:
7017 # Code from module strtoll:
7018 # Code from module strtoull:
7019 # Code from module strtoumax:
7020 # Code from module symlink:
7021 # Code from module sys_select:
7022 # Code from module sys_stat:
7023 # Code from module sys_time:
7024 # Code from module time:
7025 # Code from module time_r:
7026 # Code from module timer-time:
7027 # Code from module timespec:
7028 # Code from module timespec-add:
7029 # Code from module timespec-sub:
7030 # Code from module u64:
7031 # Code from module unistd:
7032 # Code from module utimens:
7033 # Code from module verify:
7034 # Code from module warnings:
7035
7036
7037 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7038 # if -g3 works and the user does not specify CFLAGS.
7039 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7040 if test "$ac_test_CFLAGS" != set; then
7041 case $CFLAGS in
7042 '-g')
7043 emacs_g3_CFLAGS='-g3';;
7044 '-g -O2')
7045 emacs_g3_CFLAGS='-g3 -O2';;
7046 *)
7047 emacs_g3_CFLAGS='';;
7048 esac
7049 if test -n "$emacs_g3_CFLAGS"; then
7050 emacs_save_CFLAGS=$CFLAGS
7051 CFLAGS=$emacs_g3_CFLAGS
7052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7053 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7054 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7055 $as_echo_n "(cached) " >&6
7056 else
7057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7058 /* end confdefs.h. */
7059
7060 int
7061 main ()
7062 {
7063
7064 ;
7065 return 0;
7066 }
7067 _ACEOF
7068 if ac_fn_c_try_link "$LINENO"; then :
7069 emacs_cv_prog_cc_g3=yes
7070 else
7071 emacs_cv_prog_cc_g3=no
7072 fi
7073 rm -f core conftest.err conftest.$ac_objext \
7074 conftest$ac_exeext conftest.$ac_ext
7075 fi
7076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7077 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7078 if test $emacs_cv_prog_cc_g3 = yes; then
7079 CFLAGS=$emacs_g3_CFLAGS
7080 else
7081 CFLAGS=$emacs_save_CFLAGS
7082 fi
7083 fi
7084 fi
7085
7086 # Check whether --enable-gcc-warnings was given.
7087 if test "${enable_gcc_warnings+set}" = set; then :
7088 enableval=$enable_gcc_warnings; case $enableval in
7089 yes|no) ;;
7090 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7091 esac
7092 gl_gcc_warnings=$enableval
7093 else
7094 gl_gcc_warnings=no
7095
7096 fi
7097
7098
7099 # Check whether --enable-link-time-optimization was given.
7100 if test "${enable_link_time_optimization+set}" = set; then :
7101 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7103 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7104 ac_lto_supported=no
7105 if test x$GCC = xyes; then
7106 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7107 if test x$CPUS != x; then
7108 LTO="-flto=$CPUS"
7109 else
7110 LTO="-flto"
7111 fi
7112 old_CFLAGS=$CFLAGS
7113 CFLAGS="$CFLAGS $LTO"
7114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7115 /* end confdefs.h. */
7116
7117 int
7118 main ()
7119 {
7120
7121 ;
7122 return 0;
7123 }
7124 _ACEOF
7125 if ac_fn_c_try_compile "$LINENO"; then :
7126 ac_lto_supported=yes
7127 else
7128 ac_lto_supported=no
7129 fi
7130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7131 CFLAGS="$old_CFLAGS"
7132 fi
7133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7134 $as_echo "$ac_lto_supported" >&6; }
7135 if test "$ac_lto_supported" = "yes"; then
7136 CFLAGS="$CFLAGS $LTO"
7137 fi
7138 fi
7139 fi
7140
7141
7142 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7143 # ------------------------------------------------
7144 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7145 # Otherwise, run RUN-IF-NOT-FOUND.
7146
7147
7148 # When compiling with GCC, prefer -isystem to -I when including system
7149 # include files, to avoid generating useless diagnostics for the files.
7150 if test "$gl_gcc_warnings" != yes; then
7151 isystem='-I'
7152 else
7153 isystem='-isystem '
7154
7155 # This, $nw, is the list of warnings we disable.
7156 nw=
7157
7158 case $with_x_toolkit in
7159 lucid | athena | motif)
7160 # Old toolkits mishandle 'const'.
7161 nw="$nw -Wwrite-strings"
7162 ;;
7163 *)
7164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7165 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7166 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7167 $as_echo_n "(cached) " >&6
7168 else
7169
7170 gl_save_compiler_FLAGS="$CFLAGS"
7171 as_fn_append CFLAGS " -Werror"
7172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7173 /* end confdefs.h. */
7174
7175 int
7176 main ()
7177 {
7178
7179 ;
7180 return 0;
7181 }
7182 _ACEOF
7183 if ac_fn_c_try_compile "$LINENO"; then :
7184 gl_cv_warn_c__Werror=yes
7185 else
7186 gl_cv_warn_c__Werror=no
7187 fi
7188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7189 CFLAGS="$gl_save_compiler_FLAGS"
7190
7191 fi
7192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7193 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7194 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7195 as_fn_append WERROR_CFLAGS " -Werror"
7196 fi
7197
7198
7199 ;;
7200 esac
7201
7202
7203 nw="$nw -Waggregate-return" # anachronistic
7204 nw="$nw -Wlong-long" # C90 is anachronistic
7205 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7206 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7207 nw="$nw -Wtraditional" # Warns on #elif which we use often
7208 nw="$nw -Wcast-qual" # Too many warnings for now
7209 nw="$nw -Wconversion" # Too many warnings for now
7210 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7211 nw="$nw -Wsign-conversion" # Too many warnings for now
7212 nw="$nw -Woverlength-strings" # Not a problem these days
7213 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7214 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7215 nw="$nw -Wpadded" # Our structs are not padded
7216 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7217 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7218 nw="$nw -Wformat-nonliteral" # we do this a lot
7219 nw="$nw -Wvla" # warnings in gettext.h
7220 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7221 nw="$nw -Wswitch-enum" # Too many warnings for now
7222 nw="$nw -Wswitch-default" # Too many warnings for now
7223 nw="$nw -Wfloat-equal" # warns about high-quality code
7224 nw="$nw -Winline" # OK to ignore 'inline'
7225 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7226 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7227 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7228
7229 # Emacs doesn't care about shadowing; see
7230 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7231 nw="$nw -Wshadow"
7232
7233 # The following lines should be removable at some point.
7234 nw="$nw -Wstack-protector"
7235 nw="$nw -Wstrict-overflow"
7236 nw="$nw -Wsuggest-attribute=pure"
7237
7238
7239
7240 if test -n "$GCC"; then
7241
7242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7243 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7244 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7245 $as_echo_n "(cached) " >&6
7246 else
7247
7248 gl_save_CFLAGS="$CFLAGS"
7249 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7251 /* end confdefs.h. */
7252
7253 int
7254 main ()
7255 {
7256
7257 ;
7258 return 0;
7259 }
7260 _ACEOF
7261 if ac_fn_c_try_compile "$LINENO"; then :
7262 gl_cv_cc_nomfi_supported=yes
7263 else
7264 gl_cv_cc_nomfi_supported=no
7265 fi
7266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7267 CFLAGS="$gl_save_CFLAGS"
7268 fi
7269
7270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7271 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7272
7273 if test "$gl_cv_cc_nomfi_supported" = yes; then
7274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7275 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7276 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7277 $as_echo_n "(cached) " >&6
7278 else
7279
7280 gl_save_CFLAGS="$CFLAGS"
7281 CFLAGS="$CFLAGS -W -Werror"
7282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7283 /* end confdefs.h. */
7284 void f (void)
7285 {
7286 typedef struct { int a; int b; } s_t;
7287 s_t s1 = { 0, };
7288 }
7289
7290 int
7291 main ()
7292 {
7293
7294 ;
7295 return 0;
7296 }
7297 _ACEOF
7298 if ac_fn_c_try_compile "$LINENO"; then :
7299 gl_cv_cc_nomfi_needed=no
7300 else
7301 gl_cv_cc_nomfi_needed=yes
7302 fi
7303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7304 CFLAGS="$gl_save_CFLAGS"
7305
7306 fi
7307
7308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7309 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7310 fi
7311
7312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7313 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7314 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7315 $as_echo_n "(cached) " >&6
7316 else
7317
7318 gl_save_CFLAGS="$CFLAGS"
7319 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7321 /* end confdefs.h. */
7322
7323 int
7324 main ()
7325 {
7326
7327 ;
7328 return 0;
7329 }
7330 _ACEOF
7331 if ac_fn_c_try_compile "$LINENO"; then :
7332 gl_cv_cc_uninitialized_supported=yes
7333 else
7334 gl_cv_cc_uninitialized_supported=no
7335 fi
7336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7337 CFLAGS="$gl_save_CFLAGS"
7338 fi
7339
7340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7341 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7342
7343 fi
7344
7345 # List all gcc warning categories.
7346 gl_manywarn_set=
7347 for gl_manywarn_item in \
7348 -W \
7349 -Wabi \
7350 -Waddress \
7351 -Wall \
7352 -Warray-bounds \
7353 -Wattributes \
7354 -Wbad-function-cast \
7355 -Wbuiltin-macro-redefined \
7356 -Wcast-align \
7357 -Wchar-subscripts \
7358 -Wclobbered \
7359 -Wcomment \
7360 -Wcomments \
7361 -Wcoverage-mismatch \
7362 -Wcpp \
7363 -Wdeprecated \
7364 -Wdeprecated-declarations \
7365 -Wdisabled-optimization \
7366 -Wdiv-by-zero \
7367 -Wdouble-promotion \
7368 -Wempty-body \
7369 -Wendif-labels \
7370 -Wenum-compare \
7371 -Wextra \
7372 -Wformat-contains-nul \
7373 -Wformat-extra-args \
7374 -Wformat-nonliteral \
7375 -Wformat-security \
7376 -Wformat-y2k \
7377 -Wformat-zero-length \
7378 -Wformat=2 \
7379 -Wfree-nonheap-object \
7380 -Wignored-qualifiers \
7381 -Wimplicit \
7382 -Wimplicit-function-declaration \
7383 -Wimplicit-int \
7384 -Winit-self \
7385 -Winline \
7386 -Wint-to-pointer-cast \
7387 -Winvalid-memory-model \
7388 -Winvalid-pch \
7389 -Wjump-misses-init \
7390 -Wlogical-op \
7391 -Wmain \
7392 -Wmaybe-uninitialized \
7393 -Wmissing-braces \
7394 -Wmissing-declarations \
7395 -Wmissing-field-initializers \
7396 -Wmissing-format-attribute \
7397 -Wmissing-include-dirs \
7398 -Wmissing-noreturn \
7399 -Wmissing-parameter-type \
7400 -Wmissing-prototypes \
7401 -Wmudflap \
7402 -Wmultichar \
7403 -Wnarrowing \
7404 -Wnested-externs \
7405 -Wnonnull \
7406 -Wnormalized=nfc \
7407 -Wold-style-declaration \
7408 -Wold-style-definition \
7409 -Woverflow \
7410 -Woverlength-strings \
7411 -Woverride-init \
7412 -Wpacked \
7413 -Wpacked-bitfield-compat \
7414 -Wparentheses \
7415 -Wpointer-arith \
7416 -Wpointer-sign \
7417 -Wpointer-to-int-cast \
7418 -Wpragmas \
7419 -Wreturn-type \
7420 -Wsequence-point \
7421 -Wshadow \
7422 -Wsizeof-pointer-memaccess \
7423 -Wstack-protector \
7424 -Wstrict-aliasing \
7425 -Wstrict-overflow \
7426 -Wstrict-prototypes \
7427 -Wsuggest-attribute=const \
7428 -Wsuggest-attribute=format \
7429 -Wsuggest-attribute=noreturn \
7430 -Wsuggest-attribute=pure \
7431 -Wswitch \
7432 -Wswitch-default \
7433 -Wsync-nand \
7434 -Wsystem-headers \
7435 -Wtrampolines \
7436 -Wtrigraphs \
7437 -Wtype-limits \
7438 -Wuninitialized \
7439 -Wunknown-pragmas \
7440 -Wunreachable-code \
7441 -Wunsafe-loop-optimizations \
7442 -Wunused \
7443 -Wunused-but-set-parameter \
7444 -Wunused-but-set-variable \
7445 -Wunused-function \
7446 -Wunused-label \
7447 -Wunused-local-typedefs \
7448 -Wunused-macros \
7449 -Wunused-parameter \
7450 -Wunused-result \
7451 -Wunused-value \
7452 -Wunused-variable \
7453 -Wvarargs \
7454 -Wvariadic-macros \
7455 -Wvector-operation-performance \
7456 -Wvla \
7457 -Wvolatile-register-var \
7458 -Wwrite-strings \
7459 \
7460 ; do
7461 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7462 done
7463
7464 # Disable specific options as needed.
7465 if test "$gl_cv_cc_nomfi_needed" = yes; then
7466 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7467 fi
7468
7469 if test "$gl_cv_cc_uninitialized_supported" = no; then
7470 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7471 fi
7472
7473 ws=$gl_manywarn_set
7474
7475
7476 gl_warn_set=
7477 set x $ws; shift
7478 for gl_warn_item
7479 do
7480 case " $nw " in
7481 *" $gl_warn_item "*)
7482 ;;
7483 *)
7484 gl_warn_set="$gl_warn_set $gl_warn_item"
7485 ;;
7486 esac
7487 done
7488 ws=$gl_warn_set
7489
7490 for w in $ws; do
7491 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7493 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7494 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7495 $as_echo_n "(cached) " >&6
7496 else
7497
7498 gl_save_compiler_FLAGS="$CFLAGS"
7499 as_fn_append CFLAGS " $w"
7500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7501 /* end confdefs.h. */
7502
7503 int
7504 main ()
7505 {
7506
7507 ;
7508 return 0;
7509 }
7510 _ACEOF
7511 if ac_fn_c_try_compile "$LINENO"; then :
7512 eval "$as_gl_Warn=yes"
7513 else
7514 eval "$as_gl_Warn=no"
7515 fi
7516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7517 CFLAGS="$gl_save_compiler_FLAGS"
7518
7519 fi
7520 eval ac_res=\$$as_gl_Warn
7521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7522 $as_echo "$ac_res" >&6; }
7523 eval as_val=\$$as_gl_Warn
7524 if test "x$as_val" = x""yes; then :
7525 as_fn_append WARN_CFLAGS " $w"
7526 fi
7527
7528
7529 done
7530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7531 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7532 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7533 $as_echo_n "(cached) " >&6
7534 else
7535
7536 gl_save_compiler_FLAGS="$CFLAGS"
7537 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7539 /* end confdefs.h. */
7540
7541 int
7542 main ()
7543 {
7544
7545 ;
7546 return 0;
7547 }
7548 _ACEOF
7549 if ac_fn_c_try_compile "$LINENO"; then :
7550 gl_cv_warn_c__Wno_missing_field_initializers=yes
7551 else
7552 gl_cv_warn_c__Wno_missing_field_initializers=no
7553 fi
7554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7555 CFLAGS="$gl_save_compiler_FLAGS"
7556
7557 fi
7558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7559 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7560 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7561 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7562 fi
7563
7564 # We need this one
7565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7566 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7567 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7568 $as_echo_n "(cached) " >&6
7569 else
7570
7571 gl_save_compiler_FLAGS="$CFLAGS"
7572 as_fn_append CFLAGS " -Wno-sign-compare"
7573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7574 /* end confdefs.h. */
7575
7576 int
7577 main ()
7578 {
7579
7580 ;
7581 return 0;
7582 }
7583 _ACEOF
7584 if ac_fn_c_try_compile "$LINENO"; then :
7585 gl_cv_warn_c__Wno_sign_compare=yes
7586 else
7587 gl_cv_warn_c__Wno_sign_compare=no
7588 fi
7589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7590 CFLAGS="$gl_save_compiler_FLAGS"
7591
7592 fi
7593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7594 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7595 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7596 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7597 fi
7598
7599 # Too many warnings for now
7600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7601 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7602 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7603 $as_echo_n "(cached) " >&6
7604 else
7605
7606 gl_save_compiler_FLAGS="$CFLAGS"
7607 as_fn_append CFLAGS " -Wno-type-limits"
7608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7609 /* end confdefs.h. */
7610
7611 int
7612 main ()
7613 {
7614
7615 ;
7616 return 0;
7617 }
7618 _ACEOF
7619 if ac_fn_c_try_compile "$LINENO"; then :
7620 gl_cv_warn_c__Wno_type_limits=yes
7621 else
7622 gl_cv_warn_c__Wno_type_limits=no
7623 fi
7624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7625 CFLAGS="$gl_save_compiler_FLAGS"
7626
7627 fi
7628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7629 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7630 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7631 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7632 fi
7633
7634 # Too many warnings for now
7635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7636 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7637 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7638 $as_echo_n "(cached) " >&6
7639 else
7640
7641 gl_save_compiler_FLAGS="$CFLAGS"
7642 as_fn_append CFLAGS " -Wno-switch"
7643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7644 /* end confdefs.h. */
7645
7646 int
7647 main ()
7648 {
7649
7650 ;
7651 return 0;
7652 }
7653 _ACEOF
7654 if ac_fn_c_try_compile "$LINENO"; then :
7655 gl_cv_warn_c__Wno_switch=yes
7656 else
7657 gl_cv_warn_c__Wno_switch=no
7658 fi
7659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7660 CFLAGS="$gl_save_compiler_FLAGS"
7661
7662 fi
7663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7664 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7665 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7666 as_fn_append WARN_CFLAGS " -Wno-switch"
7667 fi
7668
7669 # Too many warnings for now
7670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7671 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7672 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7673 $as_echo_n "(cached) " >&6
7674 else
7675
7676 gl_save_compiler_FLAGS="$CFLAGS"
7677 as_fn_append CFLAGS " -Wno-unused-parameter"
7678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7679 /* end confdefs.h. */
7680
7681 int
7682 main ()
7683 {
7684
7685 ;
7686 return 0;
7687 }
7688 _ACEOF
7689 if ac_fn_c_try_compile "$LINENO"; then :
7690 gl_cv_warn_c__Wno_unused_parameter=yes
7691 else
7692 gl_cv_warn_c__Wno_unused_parameter=no
7693 fi
7694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7695 CFLAGS="$gl_save_compiler_FLAGS"
7696
7697 fi
7698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7699 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7700 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7701 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7702 fi
7703
7704 # Too many warnings for now
7705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7706 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7707 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7708 $as_echo_n "(cached) " >&6
7709 else
7710
7711 gl_save_compiler_FLAGS="$CFLAGS"
7712 as_fn_append CFLAGS " -Wno-format-nonliteral"
7713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7714 /* end confdefs.h. */
7715
7716 int
7717 main ()
7718 {
7719
7720 ;
7721 return 0;
7722 }
7723 _ACEOF
7724 if ac_fn_c_try_compile "$LINENO"; then :
7725 gl_cv_warn_c__Wno_format_nonliteral=yes
7726 else
7727 gl_cv_warn_c__Wno_format_nonliteral=no
7728 fi
7729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7730 CFLAGS="$gl_save_compiler_FLAGS"
7731
7732 fi
7733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7734 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7735 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7736 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7737 fi
7738
7739
7740
7741 # In spite of excluding -Wlogical-op above, it is enabled, as of
7742 # gcc 4.5.0 20090517.
7743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7744 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7745 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7746 $as_echo_n "(cached) " >&6
7747 else
7748
7749 gl_save_compiler_FLAGS="$CFLAGS"
7750 as_fn_append CFLAGS " -Wno-logical-op"
7751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7752 /* end confdefs.h. */
7753
7754 int
7755 main ()
7756 {
7757
7758 ;
7759 return 0;
7760 }
7761 _ACEOF
7762 if ac_fn_c_try_compile "$LINENO"; then :
7763 gl_cv_warn_c__Wno_logical_op=yes
7764 else
7765 gl_cv_warn_c__Wno_logical_op=no
7766 fi
7767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7768 CFLAGS="$gl_save_compiler_FLAGS"
7769
7770 fi
7771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7772 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7773 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7774 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7775 fi
7776
7777
7778
7779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7780 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7781 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7782 $as_echo_n "(cached) " >&6
7783 else
7784
7785 gl_save_compiler_FLAGS="$CFLAGS"
7786 as_fn_append CFLAGS " -fdiagnostics-show-option"
7787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7788 /* end confdefs.h. */
7789
7790 int
7791 main ()
7792 {
7793
7794 ;
7795 return 0;
7796 }
7797 _ACEOF
7798 if ac_fn_c_try_compile "$LINENO"; then :
7799 gl_cv_warn_c__fdiagnostics_show_option=yes
7800 else
7801 gl_cv_warn_c__fdiagnostics_show_option=no
7802 fi
7803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7804 CFLAGS="$gl_save_compiler_FLAGS"
7805
7806 fi
7807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7808 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7809 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7810 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7811 fi
7812
7813
7814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7815 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7816 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7817 $as_echo_n "(cached) " >&6
7818 else
7819
7820 gl_save_compiler_FLAGS="$CFLAGS"
7821 as_fn_append CFLAGS " -funit-at-a-time"
7822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7823 /* end confdefs.h. */
7824
7825 int
7826 main ()
7827 {
7828
7829 ;
7830 return 0;
7831 }
7832 _ACEOF
7833 if ac_fn_c_try_compile "$LINENO"; then :
7834 gl_cv_warn_c__funit_at_a_time=yes
7835 else
7836 gl_cv_warn_c__funit_at_a_time=no
7837 fi
7838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7839 CFLAGS="$gl_save_compiler_FLAGS"
7840
7841 fi
7842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7843 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7844 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7845 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7846 fi
7847
7848
7849
7850
7851 $as_echo "#define lint 1" >>confdefs.h
7852
7853
7854
7855 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7856
7857
7858 # We use a slightly smaller set of warning options for lib/.
7859 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7860 nw=
7861 nw="$nw -Wunused-macros"
7862
7863
7864 gl_warn_set=
7865 set x $WARN_CFLAGS; shift
7866 for gl_warn_item
7867 do
7868 case " $nw " in
7869 *" $gl_warn_item "*)
7870 ;;
7871 *)
7872 gl_warn_set="$gl_warn_set $gl_warn_item"
7873 ;;
7874 esac
7875 done
7876 GNULIB_WARN_CFLAGS=$gl_warn_set
7877
7878
7879 fi
7880
7881
7882
7883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7884 $as_echo_n "checking whether ln -s works... " >&6; }
7885 LN_S=$as_ln_s
7886 if test "$LN_S" = "ln -s"; then
7887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7888 $as_echo "yes" >&6; }
7889 else
7890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7891 $as_echo "no, using $LN_S" >&6; }
7892 fi
7893
7894
7895 # Extract the first word of "install-info", so it can be a program name with args.
7896 set dummy install-info; ac_word=$2
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7898 $as_echo_n "checking for $ac_word... " >&6; }
7899 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7900 $as_echo_n "(cached) " >&6
7901 else
7902 case $INSTALL_INFO in
7903 [\\/]* | ?:[\\/]*)
7904 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7905 ;;
7906 *)
7907 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7908 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7909 do
7910 IFS=$as_save_IFS
7911 test -z "$as_dir" && as_dir=.
7912 for ac_exec_ext in '' $ac_executable_extensions; do
7913 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7914 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7915 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7916 break 2
7917 fi
7918 done
7919 done
7920 IFS=$as_save_IFS
7921
7922 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7923 ;;
7924 esac
7925 fi
7926 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7927 if test -n "$INSTALL_INFO"; then
7928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7929 $as_echo "$INSTALL_INFO" >&6; }
7930 else
7931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7932 $as_echo "no" >&6; }
7933 fi
7934
7935
7936 # Extract the first word of "gzip", so it can be a program name with args.
7937 set dummy gzip; ac_word=$2
7938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7939 $as_echo_n "checking for $ac_word... " >&6; }
7940 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7941 $as_echo_n "(cached) " >&6
7942 else
7943 case $GZIP_PROG in
7944 [\\/]* | ?:[\\/]*)
7945 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7946 ;;
7947 *)
7948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7949 for as_dir in $PATH
7950 do
7951 IFS=$as_save_IFS
7952 test -z "$as_dir" && as_dir=.
7953 for ac_exec_ext in '' $ac_executable_extensions; do
7954 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7955 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7956 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7957 break 2
7958 fi
7959 done
7960 done
7961 IFS=$as_save_IFS
7962
7963 ;;
7964 esac
7965 fi
7966 GZIP_PROG=$ac_cv_path_GZIP_PROG
7967 if test -n "$GZIP_PROG"; then
7968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7969 $as_echo "$GZIP_PROG" >&6; }
7970 else
7971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7972 $as_echo "no" >&6; }
7973 fi
7974
7975
7976
7977 if test $opsys = gnu-linux; then
7978 # Extract the first word of "paxctl", so it can be a program name with args.
7979 set dummy paxctl; ac_word=$2
7980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7981 $as_echo_n "checking for $ac_word... " >&6; }
7982 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7983 $as_echo_n "(cached) " >&6
7984 else
7985 case $PAXCTL in
7986 [\\/]* | ?:[\\/]*)
7987 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7988 ;;
7989 *)
7990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7991 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7992 do
7993 IFS=$as_save_IFS
7994 test -z "$as_dir" && as_dir=.
7995 for ac_exec_ext in '' $ac_executable_extensions; do
7996 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7997 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
7998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7999 break 2
8000 fi
8001 done
8002 done
8003 IFS=$as_save_IFS
8004
8005 ;;
8006 esac
8007 fi
8008 PAXCTL=$ac_cv_path_PAXCTL
8009 if test -n "$PAXCTL"; then
8010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8011 $as_echo "$PAXCTL" >&6; }
8012 else
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8014 $as_echo "no" >&6; }
8015 fi
8016
8017
8018 if test "X$PAXCTL" != X; then
8019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8020 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8022 /* end confdefs.h. */
8023
8024 int
8025 main ()
8026 {
8027
8028 ;
8029 return 0;
8030 }
8031 _ACEOF
8032 if ac_fn_c_try_link "$LINENO"; then :
8033 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8034 $as_echo "yes" >&6; }
8035 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8036 $as_echo "no" >&6; }; PAXCTL=""; fi
8037 fi
8038 rm -f core conftest.err conftest.$ac_objext \
8039 conftest$ac_exeext conftest.$ac_ext
8040 fi
8041 fi
8042
8043 ## Need makeinfo >= 4.7 (?) to build the manuals.
8044 # Extract the first word of "makeinfo", so it can be a program name with args.
8045 set dummy makeinfo; ac_word=$2
8046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8047 $as_echo_n "checking for $ac_word... " >&6; }
8048 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8049 $as_echo_n "(cached) " >&6
8050 else
8051 case $MAKEINFO in
8052 [\\/]* | ?:[\\/]*)
8053 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8054 ;;
8055 *)
8056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8057 for as_dir in $PATH
8058 do
8059 IFS=$as_save_IFS
8060 test -z "$as_dir" && as_dir=.
8061 for ac_exec_ext in '' $ac_executable_extensions; do
8062 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8063 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8065 break 2
8066 fi
8067 done
8068 done
8069 IFS=$as_save_IFS
8070
8071 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8072 ;;
8073 esac
8074 fi
8075 MAKEINFO=$ac_cv_path_MAKEINFO
8076 if test -n "$MAKEINFO"; then
8077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8078 $as_echo "$MAKEINFO" >&6; }
8079 else
8080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8081 $as_echo "no" >&6; }
8082 fi
8083
8084
8085 if test "$MAKEINFO" != "no" && \
8086 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
8087 MAKEINFO=no
8088 fi
8089
8090 ## Makeinfo is unusual. For a released Emacs, the manuals are
8091 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8092 ## therefore in the category of "special tools" not normally required, which
8093 ## configure does not have to check for (eg autoconf itself).
8094 ## In a Bazaar checkout on the other hand, the manuals are not included.
8095 ## So makeinfo is a requirement to build from Bazaar, and configure
8096 ## should test for it as it does for any other build requirement.
8097 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8098 ## with pre-built manuals, from a Bazaar checkout.
8099 HAVE_MAKEINFO=yes
8100
8101 if test "$MAKEINFO" = "no"; then
8102 MAKEINFO=makeinfo
8103 if test "x${with_makeinfo}" = "xno"; then
8104 HAVE_MAKEINFO=no
8105 elif test ! -e $srcdir/info/emacs; then
8106 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8107 source tree does not seem to have pre-built manuals in the \`info' directory.
8108 Either install a suitable version of makeinfo, or re-run configure
8109 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8110 fi
8111 fi
8112
8113
8114 INFO_EXT=.info
8115 INFO_OPTS=--no-split
8116
8117
8118
8119
8120 if test x$GCC = xyes; then
8121 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8122 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8123 else
8124 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8125 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8126 fi
8127
8128
8129 late_LDFLAGS=$LDFLAGS
8130 if test x$GCC = xyes; then
8131 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8132 else
8133 LDFLAGS="$LDFLAGS -znocombreloc"
8134 fi
8135
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8137 $as_echo_n "checking for -znocombreloc... " >&6; }
8138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8139 /* end confdefs.h. */
8140
8141 int
8142 main ()
8143 {
8144
8145 ;
8146 return 0;
8147 }
8148 _ACEOF
8149 if ac_fn_c_try_link "$LINENO"; then :
8150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8151 $as_echo "yes" >&6; }
8152 else
8153 LDFLAGS=$late_LDFLAGS
8154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8155 $as_echo "no" >&6; }
8156 fi
8157 rm -f core conftest.err conftest.$ac_objext \
8158 conftest$ac_exeext conftest.$ac_ext
8159
8160
8161 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8162 case "$opsys" in
8163 your-opsys-here) CANNOT_DUMP=yes ;;
8164 esac
8165
8166 test "$CANNOT_DUMP" = "yes" && \
8167
8168 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8169
8170
8171
8172
8173
8174 UNEXEC_OBJ=unexelf.o
8175 case "$opsys" in
8176 # MSDOS uses unexcoff.o
8177 # MSWindows uses unexw32.o
8178 aix4-2)
8179 UNEXEC_OBJ=unexaix.o
8180 ;;
8181 cygwin)
8182 UNEXEC_OBJ=unexcw.o
8183 ;;
8184 darwin)
8185 UNEXEC_OBJ=unexmacosx.o
8186 ;;
8187 hpux10-20 | hpux11)
8188 UNEXEC_OBJ=unexhp9k800.o
8189 ;;
8190 sol2-10)
8191 # Use the Solaris dldump() function, called from unexsol.c, to dump
8192 # emacs, instead of the generic ELF dump code found in unexelf.c.
8193 # The resulting binary has a complete symbol table, and is better
8194 # for debugging and other observability tools (debuggers, pstack, etc).
8195 #
8196 # If you encounter a problem using dldump(), please consider sending
8197 # a message to the OpenSolaris tools-linking mailing list:
8198 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8199 #
8200 # It is likely that dldump() works with older Solaris too, but this has
8201 # not been tested, so for now this change is for Solaris 10 or newer.
8202 UNEXEC_OBJ=unexsol.o
8203 ;;
8204 esac
8205
8206 LD_SWITCH_SYSTEM=
8207 case "$opsys" in
8208 freebsd)
8209 ## Let `ld' find image libs and similar things in /usr/local/lib.
8210 ## The system compiler, GCC, has apparently been modified to not
8211 ## look there, contrary to what a stock GCC would do.
8212 ### It's not our place to do this. See bug#10313#17.
8213 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8214 :
8215 ;;
8216
8217 gnu-linux)
8218 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8219 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8220 ;;
8221
8222 netbsd)
8223 ### It's not our place to do this. See bug#10313#17.
8224 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8225 :
8226 ;;
8227
8228 openbsd)
8229 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8230 ## otherwise Emacs dumps core on elf systems.
8231 LD_SWITCH_SYSTEM="-Z"
8232 ;;
8233 esac
8234
8235
8236 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8237
8238 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8239 ## which has not been defined yet. When this was handled with cpp,
8240 ## it was expanded to null when configure sourced the s/*.h file.
8241 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8242 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8243 ## (or somesuch), but because it is supposed to go at the _front_
8244 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8245 ## Compare with the gnu-linux case below, which added to the end
8246 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8247 ## LD_SWITCH_SYSTEM_TEMACS.
8248 case "$opsys" in
8249 netbsd|openbsd)
8250 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8251 esac
8252
8253
8254 C_SWITCH_MACHINE=
8255 case $canonical in
8256 alpha*)
8257 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8258 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8259
8260 fi
8261
8262 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8263 ## With ELF, make sure that all common symbols get allocated to in the
8264 ## data section. Otherwise, the dump of temacs may miss variables in
8265 ## the shared library that have been initialized. For example, with
8266 ## GNU libc, __malloc_initialized would normally be resolved to the
8267 ## shared library's .bss section, which is fatal.
8268 if test "x$GCC" = "xyes"; then
8269 C_SWITCH_MACHINE="-fno-common"
8270 else
8271 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8272 fi
8273 else
8274 UNEXEC_OBJ=unexalpha.o
8275 fi
8276 ;;
8277 esac
8278
8279
8280
8281
8282 C_SWITCH_SYSTEM=
8283 ## Some programs in src produce warnings saying certain subprograms
8284 ## are too complex and need a MAXMEM value greater than 2000 for
8285 ## additional optimization. --nils@exp-math.uni-essen.de
8286 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8287 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8288 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8289 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8290
8291
8292
8293 LIBS_SYSTEM=
8294 case "$opsys" in
8295 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8296 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8297
8298 freebsd) LIBS_SYSTEM="-lutil" ;;
8299
8300 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8301
8302 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8303
8304 ## Motif needs -lgen.
8305 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8306 esac
8307
8308
8309
8310 ### Make sure subsequent tests use flags consistent with the build flags.
8311
8312 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8313 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8314 else
8315 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8316 fi
8317
8318 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8319
8320 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8321
8322
8323
8324 LIB_MATH=-lm
8325 LIB_STANDARD=
8326 START_FILES=
8327 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8328
8329 case $opsys in
8330 cygwin )
8331 LIB_MATH=
8332 START_FILES='pre-crt0.o'
8333 ;;
8334 darwin )
8335 ## Adding -lm confuses the dynamic linker, so omit it.
8336 LIB_MATH=
8337 START_FILES='pre-crt0.o'
8338 ;;
8339 freebsd )
8340 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8341 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8342 SYSTEM_TYPE=berkeley-unix
8343 ;;
8344 gnu-linux | gnu-kfreebsd )
8345 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8346 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8347 ;;
8348 hpux10-20 | hpux11 )
8349 LIB_STANDARD=-lc
8350 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8351 ;;
8352 netbsd | openbsd )
8353 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8354 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8355 SYSTEM_TYPE=berkeley-unix
8356 ;;
8357
8358 sol2* | unixware )
8359 SYSTEM_TYPE=usg-unix-v
8360 ;;
8361
8362 esac
8363
8364
8365
8366
8367 cat >>confdefs.h <<_ACEOF
8368 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8369 _ACEOF
8370
8371
8372 crt_files=
8373
8374 for file in x $LIB_STANDARD $START_FILES; do
8375 case "$file" in
8376 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8377 esac
8378 done
8379
8380 if test "x$crt_files" != x; then
8381
8382 ## If user specified a crt-dir, use that unconditionally.
8383 crt_gcc=no
8384
8385 if test "X$CRT_DIR" = "X"; then
8386
8387 CRT_DIR=/usr/lib # default
8388
8389 case "$canonical" in
8390 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8391 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8392 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8393 ## For anything else (eg /usr/lib32), it is up the user to specify
8394 ## the location (bug#5655).
8395 ## Test for crtn.o, not just the directory, because sometimes the
8396 ## directory exists but does not have the relevant files (bug#1287).
8397 ## FIXME better to test for binary compatibility somehow.
8398 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8399 ;;
8400
8401 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8402 esac
8403
8404 case "$opsys" in
8405 hpux10-20) CRT_DIR=/lib ;;
8406 esac
8407
8408 test "x${GCC}" = xyes && crt_gcc=yes
8409
8410 fi # CRT_DIR = ""
8411
8412 crt_missing=
8413
8414 for file in $crt_files; do
8415
8416 ## If we're using gcc, try to determine it automatically by asking
8417 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8418 ## system-dependent default from above.]
8419 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8420
8421 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8422 case "$crt_file" in
8423 */*)
8424 CRT_DIR=`$as_dirname -- "$crt_file" ||
8425 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8426 X"$crt_file" : 'X\(//\)[^/]' \| \
8427 X"$crt_file" : 'X\(//\)$' \| \
8428 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8429 $as_echo X"$crt_file" |
8430 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8431 s//\1/
8432 q
8433 }
8434 /^X\(\/\/\)[^/].*/{
8435 s//\1/
8436 q
8437 }
8438 /^X\(\/\/\)$/{
8439 s//\1/
8440 q
8441 }
8442 /^X\(\/\).*/{
8443 s//\1/
8444 q
8445 }
8446 s/.*/./; q'`
8447 ;;
8448 esac
8449 fi
8450
8451 crt_gcc=no
8452
8453 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8454 done # $crt_files
8455
8456 test "x$crt_missing" = x || \
8457 as_fn_error "Required file(s) not found:$crt_missing
8458 Try using the --with-crt-dir option." "$LINENO" 5
8459
8460 fi # crt_files != ""
8461
8462
8463
8464 case $opsys in
8465 netbsd | openbsd )
8466 if test -f $CRT_DIR/crti.o; then
8467
8468 test -f $CRT_DIR/crtn.o || \
8469 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8470
8471 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8472 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8473 fi
8474 ;;
8475 esac
8476
8477
8478 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8479 pre_PKG_CONFIG_LIBS=$LIBS
8480
8481 # Extract the first word of "pkg-config", so it can be a program name with args.
8482 set dummy pkg-config; ac_word=$2
8483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8484 $as_echo_n "checking for $ac_word... " >&6; }
8485 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8486 $as_echo_n "(cached) " >&6
8487 else
8488 case $PKG_CONFIG in
8489 [\\/]* | ?:[\\/]*)
8490 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8491 ;;
8492 *)
8493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8494 for as_dir in $PATH
8495 do
8496 IFS=$as_save_IFS
8497 test -z "$as_dir" && as_dir=.
8498 for ac_exec_ext in '' $ac_executable_extensions; do
8499 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8500 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8502 break 2
8503 fi
8504 done
8505 done
8506 IFS=$as_save_IFS
8507
8508 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8509 ;;
8510 esac
8511 fi
8512 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8513 if test -n "$PKG_CONFIG"; then
8514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8515 $as_echo "$PKG_CONFIG" >&6; }
8516 else
8517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8518 $as_echo "no" >&6; }
8519 fi
8520
8521
8522
8523
8524
8525
8526 if test "${with_sound}" != "no"; then
8527 # Sound support for GNU/Linux and the free BSDs.
8528 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8529 do :
8530 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8531 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8532 eval as_val=\$$as_ac_Header
8533 if test "x$as_val" = x""yes; then :
8534 cat >>confdefs.h <<_ACEOF
8535 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8536 _ACEOF
8537 have_sound_header=yes
8538 fi
8539
8540 done
8541
8542 # Emulation library used on NetBSD.
8543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8544 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8545 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8546 $as_echo_n "(cached) " >&6
8547 else
8548 ac_check_lib_save_LIBS=$LIBS
8549 LIBS="-lossaudio $LIBS"
8550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8551 /* end confdefs.h. */
8552
8553 /* Override any GCC internal prototype to avoid an error.
8554 Use char because int might match the return type of a GCC
8555 builtin and then its argument prototype would still apply. */
8556 #ifdef __cplusplus
8557 extern "C"
8558 #endif
8559 char _oss_ioctl ();
8560 int
8561 main ()
8562 {
8563 return _oss_ioctl ();
8564 ;
8565 return 0;
8566 }
8567 _ACEOF
8568 if ac_fn_c_try_link "$LINENO"; then :
8569 ac_cv_lib_ossaudio__oss_ioctl=yes
8570 else
8571 ac_cv_lib_ossaudio__oss_ioctl=no
8572 fi
8573 rm -f core conftest.err conftest.$ac_objext \
8574 conftest$ac_exeext conftest.$ac_ext
8575 LIBS=$ac_check_lib_save_LIBS
8576 fi
8577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8578 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8579 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8580 LIBSOUND=-lossaudio
8581 else
8582 LIBSOUND=
8583 fi
8584
8585
8586
8587 ALSA_REQUIRED=1.0.0
8588 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8589
8590 succeeded=no
8591
8592 if test "$PKG_CONFIG" = "no" ; then
8593 HAVE_ALSA=no
8594 else
8595 PKG_CONFIG_MIN_VERSION=0.9.0
8596 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8598 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8599
8600 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8601 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8602 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8603 edit_cflags="
8604 s,///*,/,g
8605 s/^/ /
8606 s/ -I/ $isystem/g
8607 s/^ //
8608 "
8609 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8610 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8612 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8613 succeeded=yes
8614 else
8615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8616 $as_echo "no" >&6; }
8617 ALSA_CFLAGS=""
8618 ALSA_LIBS=""
8619 ## If we have a custom action on failure, don't print errors, but
8620 ## do set a variable so people can do so. Do it in a subshell
8621 ## to capture any diagnostics in invoking pkg-config.
8622 ALSA_PKG_ERRORS=`($PKG_CONFIG --print-errors "$ALSA_MODULES") 2>&1`
8623
8624 fi
8625
8626
8627
8628 else
8629 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8630 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8631 fi
8632 fi
8633
8634 if test $succeeded = yes; then
8635 HAVE_ALSA=yes
8636 else
8637 HAVE_ALSA=no
8638 fi
8639
8640 if test $HAVE_ALSA = yes; then
8641 SAVE_CFLAGS="$CFLAGS"
8642 SAVE_LIBS="$LIBS"
8643 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8644 LIBS="$ALSA_LIBS $LIBS"
8645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8646 /* end confdefs.h. */
8647 #include <asoundlib.h>
8648 int
8649 main ()
8650 {
8651 snd_lib_error_set_handler (0);
8652 ;
8653 return 0;
8654 }
8655 _ACEOF
8656 if ac_fn_c_try_compile "$LINENO"; then :
8657 emacs_alsa_normal=yes
8658 else
8659 emacs_alsa_normal=no
8660 fi
8661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8662 if test "$emacs_alsa_normal" != yes; then
8663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8664 /* end confdefs.h. */
8665 #include <alsa/asoundlib.h>
8666 int
8667 main ()
8668 {
8669 snd_lib_error_set_handler (0);
8670 ;
8671 return 0;
8672 }
8673 _ACEOF
8674 if ac_fn_c_try_compile "$LINENO"; then :
8675 emacs_alsa_subdir=yes
8676 else
8677 emacs_alsa_subdir=no
8678 fi
8679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8680 if test "$emacs_alsa_subdir" != yes; then
8681 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8682 fi
8683 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8684 fi
8685
8686 CFLAGS="$SAVE_CFLAGS"
8687 LIBS="$SAVE_LIBS"
8688 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8689 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8690
8691 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8692
8693 fi
8694
8695 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8696 case "$opsys" in
8697 gnu-linux|freebsd|netbsd)
8698
8699 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8700
8701 ;;
8702 esac
8703 fi
8704
8705
8706 fi
8707
8708
8709
8710
8711 for ac_header in $ac_header_list
8712 do :
8713 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8714 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8715 "
8716 eval as_val=\$$as_ac_Header
8717 if test "x$as_val" = x""yes; then :
8718 cat >>confdefs.h <<_ACEOF
8719 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8720 _ACEOF
8721
8722 fi
8723
8724 done
8725
8726
8727
8728
8729
8730
8731
8732
8733
8734
8735
8736
8737
8738
8739
8740
8741
8742
8743
8744
8745
8746
8747
8748
8749
8750
8751
8752
8753
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8755 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8757 /* end confdefs.h. */
8758 #include <sys/personality.h>
8759 int
8760 main ()
8761 {
8762 personality (PER_LINUX32)
8763 ;
8764 return 0;
8765 }
8766 _ACEOF
8767 if ac_fn_c_try_compile "$LINENO"; then :
8768 emacs_cv_personality_linux32=yes
8769 else
8770 emacs_cv_personality_linux32=no
8771 fi
8772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8774 $as_echo "$emacs_cv_personality_linux32" >&6; }
8775
8776 if test $emacs_cv_personality_linux32 = yes; then
8777
8778 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8779
8780 fi
8781
8782 for ac_header in term.h
8783 do :
8784 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8785 if test "x$ac_cv_header_term_h" = x""yes; then :
8786 cat >>confdefs.h <<_ACEOF
8787 #define HAVE_TERM_H 1
8788 _ACEOF
8789
8790 fi
8791
8792 done
8793
8794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8795 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8796 if test "${ac_cv_header_time+set}" = set; then :
8797 $as_echo_n "(cached) " >&6
8798 else
8799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8800 /* end confdefs.h. */
8801 #include <sys/types.h>
8802 #include <sys/time.h>
8803 #include <time.h>
8804
8805 int
8806 main ()
8807 {
8808 if ((struct tm *) 0)
8809 return 0;
8810 ;
8811 return 0;
8812 }
8813 _ACEOF
8814 if ac_fn_c_try_compile "$LINENO"; then :
8815 ac_cv_header_time=yes
8816 else
8817 ac_cv_header_time=no
8818 fi
8819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8820 fi
8821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8822 $as_echo "$ac_cv_header_time" >&6; }
8823 if test $ac_cv_header_time = yes; then
8824
8825 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8826
8827 fi
8828
8829 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
8830
8831 "
8832 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8833 ac_have_decl=1
8834 else
8835 ac_have_decl=0
8836 fi
8837
8838 cat >>confdefs.h <<_ACEOF
8839 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8840 _ACEOF
8841
8842 if test $ac_cv_have_decl_sys_siglist != yes; then
8843 # For Tru64, at least:
8844 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
8845
8846 "
8847 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8848 ac_have_decl=1
8849 else
8850 ac_have_decl=0
8851 fi
8852
8853 cat >>confdefs.h <<_ACEOF
8854 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8855 _ACEOF
8856
8857 if test $ac_cv_have_decl___sys_siglist = yes; then
8858
8859 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8860
8861 fi
8862 fi
8863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8864 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8865 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8866 $as_echo_n "(cached) " >&6
8867 else
8868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8869 /* end confdefs.h. */
8870 #include <sys/types.h>
8871 #include <sys/wait.h>
8872 #ifndef WEXITSTATUS
8873 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8874 #endif
8875 #ifndef WIFEXITED
8876 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8877 #endif
8878
8879 int
8880 main ()
8881 {
8882 int s;
8883 wait (&s);
8884 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8885 ;
8886 return 0;
8887 }
8888 _ACEOF
8889 if ac_fn_c_try_compile "$LINENO"; then :
8890 ac_cv_header_sys_wait_h=yes
8891 else
8892 ac_cv_header_sys_wait_h=no
8893 fi
8894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8895 fi
8896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8897 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8898 if test $ac_cv_header_sys_wait_h = yes; then
8899
8900 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8901
8902 fi
8903
8904
8905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8906 $as_echo_n "checking for speed_t... " >&6; }
8907 if test "${emacs_cv_speed_t+set}" = set; then :
8908 $as_echo_n "(cached) " >&6
8909 else
8910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8911 /* end confdefs.h. */
8912 #include <termios.h>
8913 int
8914 main ()
8915 {
8916 speed_t x = 1;
8917 ;
8918 return 0;
8919 }
8920 _ACEOF
8921 if ac_fn_c_try_compile "$LINENO"; then :
8922 emacs_cv_speed_t=yes
8923 else
8924 emacs_cv_speed_t=no
8925 fi
8926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8927 fi
8928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8929 $as_echo "$emacs_cv_speed_t" >&6; }
8930 if test $emacs_cv_speed_t = yes; then
8931
8932 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8933
8934 fi
8935
8936
8937
8938
8939 for ac_header in net/if.h
8940 do :
8941 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8942 #if HAVE_SYS_SOCKET_H
8943 #include <sys/socket.h>
8944 #endif
8945 "
8946 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8947 cat >>confdefs.h <<_ACEOF
8948 #define HAVE_NET_IF_H 1
8949 _ACEOF
8950
8951 fi
8952
8953 done
8954
8955 for ac_header in ifaddrs.h
8956 do :
8957 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8958 #if HAVE_SYS_SOCKET_H
8959 #include <sys/socket.h>
8960 #endif
8961 "
8962 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8963 cat >>confdefs.h <<_ACEOF
8964 #define HAVE_IFADDRS_H 1
8965 _ACEOF
8966
8967 fi
8968
8969 done
8970
8971 for ac_header in net/if_dl.h
8972 do :
8973 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8974 #if HAVE_SYS_SOCKET_H
8975 #include <sys/socket.h>
8976 #endif
8977 "
8978 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8979 cat >>confdefs.h <<_ACEOF
8980 #define HAVE_NET_IF_DL_H 1
8981 _ACEOF
8982
8983 fi
8984
8985 done
8986
8987
8988 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8989 #if HAVE_SYS_SOCKET_H
8990 #include <sys/socket.h>
8991 #endif
8992 #if HAVE_NET_IF_H
8993 #include <net/if.h>
8994 #endif
8995 "
8996 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8997
8998 cat >>confdefs.h <<_ACEOF
8999 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9000 _ACEOF
9001
9002
9003 fi
9004 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9005 #if HAVE_SYS_SOCKET_H
9006 #include <sys/socket.h>
9007 #endif
9008 #if HAVE_NET_IF_H
9009 #include <net/if.h>
9010 #endif
9011 "
9012 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9013
9014 cat >>confdefs.h <<_ACEOF
9015 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9016 _ACEOF
9017
9018
9019 fi
9020 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9021 #if HAVE_SYS_SOCKET_H
9022 #include <sys/socket.h>
9023 #endif
9024 #if HAVE_NET_IF_H
9025 #include <net/if.h>
9026 #endif
9027 "
9028 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9029
9030 cat >>confdefs.h <<_ACEOF
9031 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9032 _ACEOF
9033
9034
9035 fi
9036 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9037 #if HAVE_SYS_SOCKET_H
9038 #include <sys/socket.h>
9039 #endif
9040 #if HAVE_NET_IF_H
9041 #include <net/if.h>
9042 #endif
9043 "
9044 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9045
9046 cat >>confdefs.h <<_ACEOF
9047 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9048 _ACEOF
9049
9050
9051 fi
9052 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9053 #if HAVE_SYS_SOCKET_H
9054 #include <sys/socket.h>
9055 #endif
9056 #if HAVE_NET_IF_H
9057 #include <net/if.h>
9058 #endif
9059 "
9060 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9061
9062 cat >>confdefs.h <<_ACEOF
9063 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9064 _ACEOF
9065
9066
9067 fi
9068 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9069 #if HAVE_SYS_SOCKET_H
9070 #include <sys/socket.h>
9071 #endif
9072 #if HAVE_NET_IF_H
9073 #include <net/if.h>
9074 #endif
9075 "
9076 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9077
9078 cat >>confdefs.h <<_ACEOF
9079 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9080 _ACEOF
9081
9082
9083 fi
9084
9085
9086
9087
9088 DEPFLAGS=
9089 MKDEPDIR=":"
9090 deps_frag=deps.mk
9091 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9093 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9094 HAVE_GNU_MAKE=no
9095 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9096 if test "x$testval" != x; then
9097 HAVE_GNU_MAKE=yes
9098 else
9099 ac_enable_autodepend=no
9100 fi
9101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9102 $as_echo "$HAVE_GNU_MAKE" >&6; }
9103 if test $HAVE_GNU_MAKE = yes; then
9104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9105 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9106 SAVE_CFLAGS="$CFLAGS"
9107 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9109 /* end confdefs.h. */
9110
9111 int
9112 main ()
9113 {
9114
9115 ;
9116 return 0;
9117 }
9118 _ACEOF
9119 if ac_fn_c_try_compile "$LINENO"; then :
9120
9121 else
9122 ac_enable_autodepend=no
9123 fi
9124 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9125 CFLAGS="$SAVE_CFLAGS"
9126 test -f deps.d || ac_enable_autodepend=no
9127 rm -rf deps.d
9128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9129 $as_echo "$ac_enable_autodepend" >&6; }
9130 fi
9131 if test $ac_enable_autodepend = yes; then
9132 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9133 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9134 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9135 deps_frag=autodeps.mk
9136 fi
9137 fi
9138 deps_frag=$srcdir/src/$deps_frag
9139
9140
9141
9142
9143
9144 lisp_frag=$srcdir/src/lisp.mk
9145
9146
9147
9148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9149 $as_echo_n "checking for long file names... " >&6; }
9150 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9151 $as_echo_n "(cached) " >&6
9152 else
9153 ac_cv_sys_long_file_names=yes
9154 # Test for long file names in all the places we know might matter:
9155 # . the current directory, where building will happen
9156 # $prefix/lib where we will be installing things
9157 # $exec_prefix/lib likewise
9158 # $TMPDIR if set, where it might want to write temporary files
9159 # /tmp where it might want to write temporary files
9160 # /var/tmp likewise
9161 # /usr/tmp likewise
9162 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9163 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9164 # in the usual case where exec_prefix is '${prefix}'.
9165 case $ac_dir in #(
9166 . | /* | ?:[\\/]*) ;; #(
9167 *) continue;;
9168 esac
9169 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9170 ac_xdir=$ac_dir/cf$$
9171 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9172 ac_tf1=$ac_xdir/conftest9012345
9173 ac_tf2=$ac_xdir/conftest9012346
9174 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9175 ac_cv_sys_long_file_names=no
9176 rm -f -r "$ac_xdir" 2>/dev/null
9177 test $ac_cv_sys_long_file_names = no && break
9178 done
9179 fi
9180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9181 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9182 if test $ac_cv_sys_long_file_names = yes; then
9183
9184 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9185
9186 fi
9187
9188
9189 #### Choose a window system.
9190
9191 ## We leave window_system equal to none if
9192 ## we end up building without one. Any new window system should
9193 ## set window_system to an appropriate value and add objects to
9194 ## window-system-specific substs.
9195
9196 window_system=none
9197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9198 $as_echo_n "checking for X... " >&6; }
9199
9200
9201 # Check whether --with-x was given.
9202 if test "${with_x+set}" = set; then :
9203 withval=$with_x;
9204 fi
9205
9206 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9207 if test "x$with_x" = xno; then
9208 # The user explicitly disabled X.
9209 have_x=disabled
9210 else
9211 case $x_includes,$x_libraries in #(
9212 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9213 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9214 $as_echo_n "(cached) " >&6
9215 else
9216 # One or both of the vars are not set, and there is no cached value.
9217 ac_x_includes=no ac_x_libraries=no
9218 rm -f -r conftest.dir
9219 if mkdir conftest.dir; then
9220 cd conftest.dir
9221 cat >Imakefile <<'_ACEOF'
9222 incroot:
9223 @echo incroot='${INCROOT}'
9224 usrlibdir:
9225 @echo usrlibdir='${USRLIBDIR}'
9226 libdir:
9227 @echo libdir='${LIBDIR}'
9228 _ACEOF
9229 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9230 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9231 for ac_var in incroot usrlibdir libdir; do
9232 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9233 done
9234 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9235 for ac_extension in a so sl dylib la dll; do
9236 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9237 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9238 ac_im_usrlibdir=$ac_im_libdir; break
9239 fi
9240 done
9241 # Screen out bogus values from the imake configuration. They are
9242 # bogus both because they are the default anyway, and because
9243 # using them would break gcc on systems where it needs fixed includes.
9244 case $ac_im_incroot in
9245 /usr/include) ac_x_includes= ;;
9246 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9247 esac
9248 case $ac_im_usrlibdir in
9249 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9250 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9251 esac
9252 fi
9253 cd ..
9254 rm -f -r conftest.dir
9255 fi
9256
9257 # Standard set of common directories for X headers.
9258 # Check X11 before X11Rn because it is often a symlink to the current release.
9259 ac_x_header_dirs='
9260 /usr/X11/include
9261 /usr/X11R7/include
9262 /usr/X11R6/include
9263 /usr/X11R5/include
9264 /usr/X11R4/include
9265
9266 /usr/include/X11
9267 /usr/include/X11R7
9268 /usr/include/X11R6
9269 /usr/include/X11R5
9270 /usr/include/X11R4
9271
9272 /usr/local/X11/include
9273 /usr/local/X11R7/include
9274 /usr/local/X11R6/include
9275 /usr/local/X11R5/include
9276 /usr/local/X11R4/include
9277
9278 /usr/local/include/X11
9279 /usr/local/include/X11R7
9280 /usr/local/include/X11R6
9281 /usr/local/include/X11R5
9282 /usr/local/include/X11R4
9283
9284 /usr/X386/include
9285 /usr/x386/include
9286 /usr/XFree86/include/X11
9287
9288 /usr/include
9289 /usr/local/include
9290 /usr/unsupported/include
9291 /usr/athena/include
9292 /usr/local/x11r5/include
9293 /usr/lpp/Xamples/include
9294
9295 /usr/openwin/include
9296 /usr/openwin/share/include'
9297
9298 if test "$ac_x_includes" = no; then
9299 # Guess where to find include files, by looking for Xlib.h.
9300 # First, try using that file with no special directory specified.
9301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9302 /* end confdefs.h. */
9303 #include <X11/Xlib.h>
9304 _ACEOF
9305 if ac_fn_c_try_cpp "$LINENO"; then :
9306 # We can compile using X headers with no special include directory.
9307 ac_x_includes=
9308 else
9309 for ac_dir in $ac_x_header_dirs; do
9310 if test -r "$ac_dir/X11/Xlib.h"; then
9311 ac_x_includes=$ac_dir
9312 break
9313 fi
9314 done
9315 fi
9316 rm -f conftest.err conftest.$ac_ext
9317 fi # $ac_x_includes = no
9318
9319 if test "$ac_x_libraries" = no; then
9320 # Check for the libraries.
9321 # See if we find them without any special options.
9322 # Don't add to $LIBS permanently.
9323 ac_save_LIBS=$LIBS
9324 LIBS="-lX11 $LIBS"
9325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9326 /* end confdefs.h. */
9327 #include <X11/Xlib.h>
9328 int
9329 main ()
9330 {
9331 XrmInitialize ()
9332 ;
9333 return 0;
9334 }
9335 _ACEOF
9336 if ac_fn_c_try_link "$LINENO"; then :
9337 LIBS=$ac_save_LIBS
9338 # We can link X programs with no special library path.
9339 ac_x_libraries=
9340 else
9341 LIBS=$ac_save_LIBS
9342 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9343 do
9344 # Don't even attempt the hair of trying to link an X program!
9345 for ac_extension in a so sl dylib la dll; do
9346 if test -r "$ac_dir/libX11.$ac_extension"; then
9347 ac_x_libraries=$ac_dir
9348 break 2
9349 fi
9350 done
9351 done
9352 fi
9353 rm -f core conftest.err conftest.$ac_objext \
9354 conftest$ac_exeext conftest.$ac_ext
9355 fi # $ac_x_libraries = no
9356
9357 case $ac_x_includes,$ac_x_libraries in #(
9358 no,* | *,no | *\'*)
9359 # Didn't find X, or a directory has "'" in its name.
9360 ac_cv_have_x="have_x=no";; #(
9361 *)
9362 # Record where we found X for the cache.
9363 ac_cv_have_x="have_x=yes\
9364 ac_x_includes='$ac_x_includes'\
9365 ac_x_libraries='$ac_x_libraries'"
9366 esac
9367 fi
9368 ;; #(
9369 *) have_x=yes;;
9370 esac
9371 eval "$ac_cv_have_x"
9372 fi # $with_x != no
9373
9374 if test "$have_x" != yes; then
9375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9376 $as_echo "$have_x" >&6; }
9377 no_x=yes
9378 else
9379 # If each of the values was on the command line, it overrides each guess.
9380 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9381 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9382 # Update the cache value to reflect the command line values.
9383 ac_cv_have_x="have_x=yes\
9384 ac_x_includes='$x_includes'\
9385 ac_x_libraries='$x_libraries'"
9386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9387 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9388 fi
9389
9390 if test "$no_x" != yes; then
9391 window_system=x11
9392 fi
9393
9394 LD_SWITCH_X_SITE_RPATH=
9395 if test "${x_libraries}" != NONE; then
9396 if test -n "${x_libraries}"; then
9397 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9398 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9399 fi
9400 x_default_search_path=""
9401 x_search_path=${x_libraries}
9402 if test -z "${x_search_path}"; then
9403 x_search_path=/usr/lib
9404 fi
9405 for x_library in `echo ${x_search_path}: | \
9406 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9407 x_search_path="\
9408 ${x_library}/X11/%L/%T/%N%C%S:\
9409 ${x_library}/X11/%l/%T/%N%C%S:\
9410 ${x_library}/X11/%T/%N%C%S:\
9411 ${x_library}/X11/%L/%T/%N%S:\
9412 ${x_library}/X11/%l/%T/%N%S:\
9413 ${x_library}/X11/%T/%N%S"
9414 if test x"${x_default_search_path}" = x; then
9415 x_default_search_path=${x_search_path}
9416 else
9417 x_default_search_path="${x_search_path}:${x_default_search_path}"
9418 fi
9419 done
9420 fi
9421
9422
9423 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9424 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9425 fi
9426
9427 if test x"${x_includes}" = x; then
9428 bitmapdir=/usr/include/X11/bitmaps
9429 else
9430 # accumulate include directories that have X11 bitmap subdirectories
9431 bmd_acc="dummyval"
9432 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9433 if test -d "${bmd}/X11/bitmaps"; then
9434 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9435 fi
9436 if test -d "${bmd}/bitmaps"; then
9437 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9438 fi
9439 done
9440 if test ${bmd_acc} != "dummyval"; then
9441 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9442 fi
9443 fi
9444
9445 HAVE_NS=no
9446 NS_IMPL_COCOA=no
9447 NS_IMPL_GNUSTEP=no
9448 tmp_CPPFLAGS="$CPPFLAGS"
9449 tmp_CFLAGS="$CFLAGS"
9450 CPPFLAGS="$CPPFLAGS -x objective-c"
9451 CFLAGS="$CFLAGS -x objective-c"
9452 TEMACS_LDFLAGS2="\${LDFLAGS}"
9453 GNU_OBJC_CFLAGS=
9454 if test "${with_ns}" != no; then
9455 if test "${opsys}" = darwin; then
9456 NS_IMPL_COCOA=yes
9457 ns_appdir=`pwd`/nextstep/Emacs.app
9458 ns_appbindir=${ns_appdir}/Contents/MacOS
9459 ns_appresdir=${ns_appdir}/Contents/Resources
9460 ns_appsrc=Cocoa/Emacs.base
9461 elif test -f $GNUSTEP_CONFIG_FILE; then
9462 NS_IMPL_GNUSTEP=yes
9463 ns_appdir=`pwd`/nextstep/Emacs.app
9464 ns_appbindir=${ns_appdir}
9465 ns_appresdir=${ns_appdir}/Resources
9466 ns_appsrc=GNUstep/Emacs.base
9467 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9468 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9469 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9470 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9471 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9472 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9473 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9474 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9475 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9476 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9477 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9478 LIB_STANDARD=
9479 START_FILES=
9480 TEMACS_LDFLAGS2=
9481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9482 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9483 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9484 $as_echo_n "(cached) " >&6
9485 else
9486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9487 /* end confdefs.h. */
9488 #include <GNUstepBase/GSConfig.h>
9489 int
9490 main ()
9491 {
9492 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9493 1;
9494 #else
9495 fail;
9496 #endif
9497 ;
9498 return 0;
9499 }
9500 _ACEOF
9501 if ac_fn_c_try_compile "$LINENO"; then :
9502 emacs_cv_objc_exceptions=yes
9503 else
9504 emacs_cv_objc_exceptions=no
9505 fi
9506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9507 fi
9508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9509 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9510 if test $emacs_cv_objc_exceptions = yes; then
9511
9512 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9513
9514 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9515 fi
9516 fi
9517
9518 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9519
9520 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9521 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9522 HAVE_NS=yes
9523 else
9524 as_fn_error "\`--with-ns' was specified, but the include
9525 files are missing or cannot be compiled." "$LINENO" 5
9526 fi
9527
9528
9529
9530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9531 /* end confdefs.h. */
9532 #include <AppKit/AppKit.h>
9533 int
9534 main ()
9535 {
9536
9537 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9538 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
9539 ; /* OK */
9540 #else
9541 #error "OSX 10.4 or newer required"
9542 #endif
9543 #endif
9544
9545 ;
9546 return 0;
9547 }
9548 _ACEOF
9549 if ac_fn_c_try_compile "$LINENO"; then :
9550 ns_osx_have_104=yes
9551 else
9552 ns_osx_have_104=no
9553 fi
9554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9556 /* end confdefs.h. */
9557 #include <Foundation/NSObjCRuntime.h>
9558 int
9559 main ()
9560 {
9561 NSInteger i;
9562 ;
9563 return 0;
9564 }
9565 _ACEOF
9566 if ac_fn_c_try_compile "$LINENO"; then :
9567 ns_have_nsinteger=yes
9568 else
9569 ns_have_nsinteger=no
9570 fi
9571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9572 if test $ns_osx_have_104 = no; then
9573 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
9574 fi
9575 if test $ns_have_nsinteger = yes; then
9576
9577 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9578
9579 fi
9580 fi
9581
9582
9583
9584 INSTALL_ARCH_INDEP_EXTRA=install-etc
9585 ns_self_contained=no
9586 NS_OBJ=
9587 NS_OBJC_OBJ=
9588 if test "${HAVE_NS}" = yes; then
9589 if test "$with_toolkit_scroll_bars" = "no"; then
9590 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9591 fi
9592
9593 window_system=nextstep
9594 # set up packaging dirs
9595 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9596 ns_self_contained=yes
9597 prefix=${ns_appresdir}
9598 exec_prefix=${ns_appbindir}
9599 libexecdir="\${ns_appbindir}/libexec"
9600 archlibdir="\${ns_appbindir}/libexec"
9601 docdir="\${ns_appresdir}/etc"
9602 etcdir="\${ns_appresdir}/etc"
9603 infodir="\${ns_appresdir}/info"
9604 mandir="\${ns_appresdir}/man"
9605 lispdir="\${ns_appresdir}/lisp"
9606 leimdir="\${ns_appresdir}/leim"
9607 INSTALL_ARCH_INDEP_EXTRA=
9608 fi
9609 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9610 fi
9611 CFLAGS="$tmp_CFLAGS"
9612 CPPFLAGS="$tmp_CPPFLAGS"
9613
9614
9615
9616
9617
9618
9619 HAVE_W32=no
9620 W32_OBJ=
9621 W32_LIBS=
9622 if test "${with_w32}" != no; then
9623 if test "${opsys}" != "cygwin"; then
9624 as_fn_error "Using w32 with an autotools build is only supported for Cygwin." "$LINENO" 5
9625 fi
9626 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
9627 if test "x$ac_cv_header_windows_h" = x""yes; then :
9628 HAVE_W32=yes
9629 else
9630 as_fn_error "\`--with-w32' was specified, but windows.h
9631 cannot be found." "$LINENO" 5
9632 fi
9633
9634
9635
9636 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
9637
9638 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
9639 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
9640 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
9641 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
9642 fi
9643
9644
9645
9646 if test "${HAVE_W32}" = "yes"; then
9647 window_system=w32
9648 with_xft=no
9649 fi
9650
9651 ## $window_system is now set to the window system we will
9652 ## ultimately use.
9653
9654 term_header=
9655 HAVE_X_WINDOWS=no
9656 HAVE_X11=no
9657 USE_X_TOOLKIT=none
9658
9659 case "${window_system}" in
9660 x11 )
9661 HAVE_X_WINDOWS=yes
9662 HAVE_X11=yes
9663 term_header=xterm.h
9664 case "${with_x_toolkit}" in
9665 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9666 motif ) USE_X_TOOLKIT=MOTIF ;;
9667 gtk ) with_gtk=yes
9668 term_header=gtkutil.h
9669 USE_X_TOOLKIT=none ;;
9670 gtk2 ) with_gtk2=yes
9671 term_header=gtkutil.h
9672 USE_X_TOOLKIT=none ;;
9673 gtk3 ) with_gtk3=yes
9674 term_header=gtkutil.h
9675 USE_X_TOOLKIT=none ;;
9676 no ) USE_X_TOOLKIT=none ;;
9677 * ) USE_X_TOOLKIT=maybe ;;
9678 esac
9679 ;;
9680 nextstep )
9681 term_header=nsterm.h
9682 ;;
9683 w32 )
9684 term_header=w32term.h
9685 ;;
9686 esac
9687
9688 if test -n "${term_header}"; then
9689
9690 cat >>confdefs.h <<_ACEOF
9691 #define TERM_HEADER "${term_header}"
9692 _ACEOF
9693
9694 fi
9695
9696 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9697 # Extract the first word of "X", so it can be a program name with args.
9698 set dummy X; ac_word=$2
9699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9700 $as_echo_n "checking for $ac_word... " >&6; }
9701 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9702 $as_echo_n "(cached) " >&6
9703 else
9704 if test -n "$HAVE_XSERVER"; then
9705 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9706 else
9707 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9708 for as_dir in $PATH
9709 do
9710 IFS=$as_save_IFS
9711 test -z "$as_dir" && as_dir=.
9712 for ac_exec_ext in '' $ac_executable_extensions; do
9713 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9714 ac_cv_prog_HAVE_XSERVER="true"
9715 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9716 break 2
9717 fi
9718 done
9719 done
9720 IFS=$as_save_IFS
9721
9722 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9723 fi
9724 fi
9725 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9726 if test -n "$HAVE_XSERVER"; then
9727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9728 $as_echo "$HAVE_XSERVER" >&6; }
9729 else
9730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9731 $as_echo "no" >&6; }
9732 fi
9733
9734
9735 if test "$HAVE_XSERVER" = true ||
9736 test -n "$DISPLAY" ||
9737 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9738 as_fn_error "You seem to be running X, but no X development libraries
9739 were found. You should install the relevant development files for X
9740 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9741 sure you have development files for image handling, i.e.
9742 tiff, gif, jpeg, png and xpm.
9743 If you are sure you want Emacs compiled without X window support, pass
9744 --without-x
9745 to configure." "$LINENO" 5
9746 fi
9747 fi
9748
9749 ### If we're using X11, we should use the X menu package.
9750 HAVE_MENUS=no
9751 case ${HAVE_X11} in
9752 yes ) HAVE_MENUS=yes ;;
9753 esac
9754
9755 # Does the opsystem file prohibit the use of the GNU malloc?
9756 # Assume not, until told otherwise.
9757 GNU_MALLOC=yes
9758
9759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9760 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9761 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9762 $as_echo_n "(cached) " >&6
9763 else
9764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9765 /* end confdefs.h. */
9766 #include <malloc.h>
9767 static void hook (void) {}
9768 int
9769 main ()
9770 {
9771 malloc_set_state (malloc_get_state ());
9772 __after_morecore_hook = hook;
9773 __malloc_initialize_hook = hook;
9774 ;
9775 return 0;
9776 }
9777 _ACEOF
9778 if ac_fn_c_try_link "$LINENO"; then :
9779 emacs_cv_var_doug_lea_malloc=yes
9780 else
9781 emacs_cv_var_doug_lea_malloc=no
9782 fi
9783 rm -f core conftest.err conftest.$ac_objext \
9784 conftest$ac_exeext conftest.$ac_ext
9785 fi
9786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9787 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9788 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9789
9790
9791 system_malloc=no
9792 case "$opsys" in
9793 ## darwin ld insists on the use of malloc routines in the System framework.
9794 darwin|sol2-10) system_malloc=yes ;;
9795 esac
9796
9797 if test "${system_malloc}" = "yes"; then
9798
9799 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9800
9801 GNU_MALLOC=no
9802 GNU_MALLOC_reason="
9803 (The GNU allocators don't work with this system configuration.)"
9804 GMALLOC_OBJ=
9805 VMLIMIT_OBJ=
9806 else
9807 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9808 VMLIMIT_OBJ=vm-limit.o
9809 fi
9810
9811
9812
9813 if test "$doug_lea_malloc" = "yes" ; then
9814 if test "$GNU_MALLOC" = yes ; then
9815 GNU_MALLOC_reason="
9816 (Using Doug Lea's new malloc from the GNU C Library.)"
9817 fi
9818
9819 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9820
9821
9822 ## Use mmap directly for allocating larger buffers.
9823 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9824 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9825 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9826 case "$opsys" in
9827 gnu*) REL_ALLOC=no ;;
9828 esac
9829 fi
9830
9831 if test x"${REL_ALLOC}" = x; then
9832 REL_ALLOC=${GNU_MALLOC}
9833 fi
9834
9835 use_mmap_for_buffers=no
9836 case "$opsys" in
9837 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9838 esac
9839
9840
9841
9842
9843
9844
9845
9846
9847 for ac_func in getpagesize
9848 do :
9849 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9850 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9851 cat >>confdefs.h <<_ACEOF
9852 #define HAVE_GETPAGESIZE 1
9853 _ACEOF
9854
9855 fi
9856 done
9857
9858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9859 $as_echo_n "checking for working mmap... " >&6; }
9860 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9861 $as_echo_n "(cached) " >&6
9862 else
9863 if test "$cross_compiling" = yes; then :
9864 ac_cv_func_mmap_fixed_mapped=no
9865 else
9866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9867 /* end confdefs.h. */
9868 $ac_includes_default
9869 /* malloc might have been renamed as rpl_malloc. */
9870 #undef malloc
9871
9872 /* Thanks to Mike Haertel and Jim Avera for this test.
9873 Here is a matrix of mmap possibilities:
9874 mmap private not fixed
9875 mmap private fixed at somewhere currently unmapped
9876 mmap private fixed at somewhere already mapped
9877 mmap shared not fixed
9878 mmap shared fixed at somewhere currently unmapped
9879 mmap shared fixed at somewhere already mapped
9880 For private mappings, we should verify that changes cannot be read()
9881 back from the file, nor mmap's back from the file at a different
9882 address. (There have been systems where private was not correctly
9883 implemented like the infamous i386 svr4.0, and systems where the
9884 VM page cache was not coherent with the file system buffer cache
9885 like early versions of FreeBSD and possibly contemporary NetBSD.)
9886 For shared mappings, we should conversely verify that changes get
9887 propagated back to all the places they're supposed to be.
9888
9889 Grep wants private fixed already mapped.
9890 The main things grep needs to know about mmap are:
9891 * does it exist and is it safe to write into the mmap'd area
9892 * how to use it (BSD variants) */
9893
9894 #include <fcntl.h>
9895 #include <sys/mman.h>
9896
9897 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9898 char *malloc ();
9899 #endif
9900
9901 /* This mess was copied from the GNU getpagesize.h. */
9902 #ifndef HAVE_GETPAGESIZE
9903 # ifdef _SC_PAGESIZE
9904 # define getpagesize() sysconf(_SC_PAGESIZE)
9905 # else /* no _SC_PAGESIZE */
9906 # ifdef HAVE_SYS_PARAM_H
9907 # include <sys/param.h>
9908 # ifdef EXEC_PAGESIZE
9909 # define getpagesize() EXEC_PAGESIZE
9910 # else /* no EXEC_PAGESIZE */
9911 # ifdef NBPG
9912 # define getpagesize() NBPG * CLSIZE
9913 # ifndef CLSIZE
9914 # define CLSIZE 1
9915 # endif /* no CLSIZE */
9916 # else /* no NBPG */
9917 # ifdef NBPC
9918 # define getpagesize() NBPC
9919 # else /* no NBPC */
9920 # ifdef PAGESIZE
9921 # define getpagesize() PAGESIZE
9922 # endif /* PAGESIZE */
9923 # endif /* no NBPC */
9924 # endif /* no NBPG */
9925 # endif /* no EXEC_PAGESIZE */
9926 # else /* no HAVE_SYS_PARAM_H */
9927 # define getpagesize() 8192 /* punt totally */
9928 # endif /* no HAVE_SYS_PARAM_H */
9929 # endif /* no _SC_PAGESIZE */
9930
9931 #endif /* no HAVE_GETPAGESIZE */
9932
9933 int
9934 main ()
9935 {
9936 char *data, *data2, *data3;
9937 const char *cdata2;
9938 int i, pagesize;
9939 int fd, fd2;
9940
9941 pagesize = getpagesize ();
9942
9943 /* First, make a file with some known garbage in it. */
9944 data = (char *) malloc (pagesize);
9945 if (!data)
9946 return 1;
9947 for (i = 0; i < pagesize; ++i)
9948 *(data + i) = rand ();
9949 umask (0);
9950 fd = creat ("conftest.mmap", 0600);
9951 if (fd < 0)
9952 return 2;
9953 if (write (fd, data, pagesize) != pagesize)
9954 return 3;
9955 close (fd);
9956
9957 /* Next, check that the tail of a page is zero-filled. File must have
9958 non-zero length, otherwise we risk SIGBUS for entire page. */
9959 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9960 if (fd2 < 0)
9961 return 4;
9962 cdata2 = "";
9963 if (write (fd2, cdata2, 1) != 1)
9964 return 5;
9965 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9966 if (data2 == MAP_FAILED)
9967 return 6;
9968 for (i = 0; i < pagesize; ++i)
9969 if (*(data2 + i))
9970 return 7;
9971 close (fd2);
9972 if (munmap (data2, pagesize))
9973 return 8;
9974
9975 /* Next, try to mmap the file at a fixed address which already has
9976 something else allocated at it. If we can, also make sure that
9977 we see the same garbage. */
9978 fd = open ("conftest.mmap", O_RDWR);
9979 if (fd < 0)
9980 return 9;
9981 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9982 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9983 return 10;
9984 for (i = 0; i < pagesize; ++i)
9985 if (*(data + i) != *(data2 + i))
9986 return 11;
9987
9988 /* Finally, make sure that changes to the mapped area do not
9989 percolate back to the file as seen by read(). (This is a bug on
9990 some variants of i386 svr4.0.) */
9991 for (i = 0; i < pagesize; ++i)
9992 *(data2 + i) = *(data2 + i) + 1;
9993 data3 = (char *) malloc (pagesize);
9994 if (!data3)
9995 return 12;
9996 if (read (fd, data3, pagesize) != pagesize)
9997 return 13;
9998 for (i = 0; i < pagesize; ++i)
9999 if (*(data + i) != *(data3 + i))
10000 return 14;
10001 close (fd);
10002 return 0;
10003 }
10004 _ACEOF
10005 if ac_fn_c_try_run "$LINENO"; then :
10006 ac_cv_func_mmap_fixed_mapped=yes
10007 else
10008 ac_cv_func_mmap_fixed_mapped=no
10009 fi
10010 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10011 conftest.$ac_objext conftest.beam conftest.$ac_ext
10012 fi
10013
10014 fi
10015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10016 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10017 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10018
10019 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10020
10021 fi
10022 rm -f conftest.mmap conftest.txt
10023
10024 if test $use_mmap_for_buffers = yes; then
10025
10026 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10027
10028 REL_ALLOC=no
10029 fi
10030
10031 LIBS="$LIBS_SYSTEM $LIBS"
10032
10033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10034 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10035 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10036 $as_echo_n "(cached) " >&6
10037 else
10038 ac_check_lib_save_LIBS=$LIBS
10039 LIBS="-ldnet $LIBS"
10040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10041 /* end confdefs.h. */
10042
10043 /* Override any GCC internal prototype to avoid an error.
10044 Use char because int might match the return type of a GCC
10045 builtin and then its argument prototype would still apply. */
10046 #ifdef __cplusplus
10047 extern "C"
10048 #endif
10049 char dnet_ntoa ();
10050 int
10051 main ()
10052 {
10053 return dnet_ntoa ();
10054 ;
10055 return 0;
10056 }
10057 _ACEOF
10058 if ac_fn_c_try_link "$LINENO"; then :
10059 ac_cv_lib_dnet_dnet_ntoa=yes
10060 else
10061 ac_cv_lib_dnet_dnet_ntoa=no
10062 fi
10063 rm -f core conftest.err conftest.$ac_objext \
10064 conftest$ac_exeext conftest.$ac_ext
10065 LIBS=$ac_check_lib_save_LIBS
10066 fi
10067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10068 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10069 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10070 cat >>confdefs.h <<_ACEOF
10071 #define HAVE_LIBDNET 1
10072 _ACEOF
10073
10074 LIBS="-ldnet $LIBS"
10075
10076 fi
10077
10078
10079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10080 $as_echo_n "checking for main in -lXbsd... " >&6; }
10081 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10082 $as_echo_n "(cached) " >&6
10083 else
10084 ac_check_lib_save_LIBS=$LIBS
10085 LIBS="-lXbsd $LIBS"
10086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10087 /* end confdefs.h. */
10088
10089
10090 int
10091 main ()
10092 {
10093 return main ();
10094 ;
10095 return 0;
10096 }
10097 _ACEOF
10098 if ac_fn_c_try_link "$LINENO"; then :
10099 ac_cv_lib_Xbsd_main=yes
10100 else
10101 ac_cv_lib_Xbsd_main=no
10102 fi
10103 rm -f core conftest.err conftest.$ac_objext \
10104 conftest$ac_exeext conftest.$ac_ext
10105 LIBS=$ac_check_lib_save_LIBS
10106 fi
10107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10108 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10109 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10110 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10111 fi
10112
10113
10114 LIB_PTHREAD=
10115
10116
10117
10118 if test "$ac_cv_header_pthread_h"; then
10119 if test "$GMALLOC_OBJ" = gmalloc.o; then
10120 emacs_pthread_function=pthread_atfork
10121 else
10122 emacs_pthread_function=pthread_self
10123 fi
10124 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10126 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10127 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10128 $as_echo_n "(cached) " >&6
10129 else
10130 ac_check_lib_save_LIBS=$LIBS
10131 LIBS="-lpthread $LIBS"
10132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10133 /* end confdefs.h. */
10134
10135 /* Override any GCC internal prototype to avoid an error.
10136 Use char because int might match the return type of a GCC
10137 builtin and then its argument prototype would still apply. */
10138 #ifdef __cplusplus
10139 extern "C"
10140 #endif
10141 char $emacs_pthread_function ();
10142 int
10143 main ()
10144 {
10145 return $emacs_pthread_function ();
10146 ;
10147 return 0;
10148 }
10149 _ACEOF
10150 if ac_fn_c_try_link "$LINENO"; then :
10151 eval "$as_ac_Lib=yes"
10152 else
10153 eval "$as_ac_Lib=no"
10154 fi
10155 rm -f core conftest.err conftest.$ac_objext \
10156 conftest$ac_exeext conftest.$ac_ext
10157 LIBS=$ac_check_lib_save_LIBS
10158 fi
10159 eval ac_res=\$$as_ac_Lib
10160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10161 $as_echo "$ac_res" >&6; }
10162 eval as_val=\$$as_ac_Lib
10163 if test "x$as_val" = x""yes; then :
10164 HAVE_PTHREAD=yes
10165 fi
10166
10167 fi
10168 if test "$HAVE_PTHREAD" = yes; then
10169 case "${canonical}" in
10170 *-hpux*) ;;
10171 *) LIB_PTHREAD="-lpthread"
10172 LIBS="$LIB_PTHREAD $LIBS" ;;
10173 esac
10174
10175 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10176
10177 fi
10178
10179
10180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10181 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10182 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10183 $as_echo_n "(cached) " >&6
10184 else
10185 ac_check_lib_save_LIBS=$LIBS
10186 LIBS="-lpthreads $LIBS"
10187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10188 /* end confdefs.h. */
10189
10190 /* Override any GCC internal prototype to avoid an error.
10191 Use char because int might match the return type of a GCC
10192 builtin and then its argument prototype would still apply. */
10193 #ifdef __cplusplus
10194 extern "C"
10195 #endif
10196 char cma_open ();
10197 int
10198 main ()
10199 {
10200 return cma_open ();
10201 ;
10202 return 0;
10203 }
10204 _ACEOF
10205 if ac_fn_c_try_link "$LINENO"; then :
10206 ac_cv_lib_pthreads_cma_open=yes
10207 else
10208 ac_cv_lib_pthreads_cma_open=no
10209 fi
10210 rm -f core conftest.err conftest.$ac_objext \
10211 conftest$ac_exeext conftest.$ac_ext
10212 LIBS=$ac_check_lib_save_LIBS
10213 fi
10214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10215 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10216 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10217 cat >>confdefs.h <<_ACEOF
10218 #define HAVE_LIBPTHREADS 1
10219 _ACEOF
10220
10221 LIBS="-lpthreads $LIBS"
10222
10223 fi
10224
10225
10226 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10227 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10228 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10229 ## added to LIBS in configure would never contain the pthreads part,
10230 ## but the value used in Makefiles might. FIXME?
10231 ##
10232 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10233 ## be harmless on older versions of X where it happens to exist.
10234 test "$opsys" = "aix4-2" && \
10235 test $ac_cv_lib_pthreads_cma_open = yes && \
10236 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10237
10238
10239 case ${host_os} in
10240 aix*)
10241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10242 $as_echo_n "checking for -bbigtoc option... " >&6; }
10243 if test "${gdb_cv_bigtoc+set}" = set; then :
10244 $as_echo_n "(cached) " >&6
10245 else
10246
10247 case $GCC in
10248 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10249 *) gdb_cv_bigtoc=-bbigtoc ;;
10250 esac
10251
10252 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10254 /* end confdefs.h. */
10255
10256 int
10257 main ()
10258 {
10259 int i;
10260 ;
10261 return 0;
10262 }
10263 _ACEOF
10264 if ac_fn_c_try_link "$LINENO"; then :
10265
10266 else
10267 gdb_cv_bigtoc=
10268 fi
10269 rm -f core conftest.err conftest.$ac_objext \
10270 conftest$ac_exeext conftest.$ac_ext
10271
10272 fi
10273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10274 $as_echo "$gdb_cv_bigtoc" >&6; }
10275 ;;
10276 esac
10277
10278 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10279 # used for the tests that follow. We set them back to REAL_CFLAGS and
10280 # REAL_CPPFLAGS later on.
10281
10282 REAL_CFLAGS="$CFLAGS"
10283 REAL_CPPFLAGS="$CPPFLAGS"
10284
10285 if test "${HAVE_X11}" = "yes"; then
10286 DEFS="$C_SWITCH_X_SITE $DEFS"
10287 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10288 LIBS="-lX11 $LIBS"
10289 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10290 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10291
10292 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10293 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10294 # but it's more convenient here to set LD_RUN_PATH since this
10295 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10296 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10297 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10298 export LD_RUN_PATH
10299 fi
10300
10301 if test "${opsys}" = "gnu-linux"; then
10302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10303 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10305 /* end confdefs.h. */
10306
10307 int
10308 main ()
10309 {
10310 XOpenDisplay ("foo");
10311 ;
10312 return 0;
10313 }
10314 _ACEOF
10315 if ac_fn_c_try_link "$LINENO"; then :
10316 xgnu_linux_first_failure=no
10317 else
10318 xgnu_linux_first_failure=yes
10319 fi
10320 rm -f core conftest.err conftest.$ac_objext \
10321 conftest$ac_exeext conftest.$ac_ext
10322 if test "${xgnu_linux_first_failure}" = "yes"; then
10323 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10324 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10325 OLD_CPPFLAGS="$CPPFLAGS"
10326 OLD_LIBS="$LIBS"
10327 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10328 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10329 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10330 LIBS="$LIBS -b i486-linuxaout"
10331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10332 /* end confdefs.h. */
10333
10334 int
10335 main ()
10336 {
10337 XOpenDisplay ("foo");
10338 ;
10339 return 0;
10340 }
10341 _ACEOF
10342 if ac_fn_c_try_link "$LINENO"; then :
10343 xgnu_linux_second_failure=no
10344 else
10345 xgnu_linux_second_failure=yes
10346 fi
10347 rm -f core conftest.err conftest.$ac_objext \
10348 conftest$ac_exeext conftest.$ac_ext
10349 if test "${xgnu_linux_second_failure}" = "yes"; then
10350 # If we get the same failure with -b, there is no use adding -b.
10351 # So take it out. This plays safe.
10352 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10353 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10354 CPPFLAGS="$OLD_CPPFLAGS"
10355 LIBS="$OLD_LIBS"
10356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10357 $as_echo "no" >&6; }
10358 else
10359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10360 $as_echo "yes" >&6; }
10361 fi
10362 else
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10364 $as_echo "no" >&6; }
10365 fi
10366 fi
10367
10368 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10369 # header files included from there.
10370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10371 $as_echo_n "checking for Xkb... " >&6; }
10372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10373 /* end confdefs.h. */
10374 #include <X11/Xlib.h>
10375 #include <X11/XKBlib.h>
10376 int
10377 main ()
10378 {
10379 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10380 ;
10381 return 0;
10382 }
10383 _ACEOF
10384 if ac_fn_c_try_link "$LINENO"; then :
10385 emacs_xkb=yes
10386 else
10387 emacs_xkb=no
10388 fi
10389 rm -f core conftest.err conftest.$ac_objext \
10390 conftest$ac_exeext conftest.$ac_ext
10391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10392 $as_echo "$emacs_xkb" >&6; }
10393 if test $emacs_xkb = yes; then
10394
10395 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10396
10397 fi
10398
10399 for ac_func in XrmSetDatabase XScreenResourceString \
10400 XScreenNumberOfScreen
10401 do :
10402 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10403 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10404 eval as_val=\$$as_ac_var
10405 if test "x$as_val" = x""yes; then :
10406 cat >>confdefs.h <<_ACEOF
10407 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10408 _ACEOF
10409
10410 fi
10411 done
10412
10413 fi
10414
10415 if test "${window_system}" = "x11"; then
10416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10417 $as_echo_n "checking X11 version 6... " >&6; }
10418 if test "${emacs_cv_x11_version_6+set}" = set; then :
10419 $as_echo_n "(cached) " >&6
10420 else
10421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10422 /* end confdefs.h. */
10423 #include <X11/Xlib.h>
10424 int
10425 main ()
10426 {
10427 #if XlibSpecificationRelease < 6
10428 fail;
10429 #endif
10430
10431 ;
10432 return 0;
10433 }
10434 _ACEOF
10435 if ac_fn_c_try_link "$LINENO"; then :
10436 emacs_cv_x11_version_6=yes
10437 else
10438 emacs_cv_x11_version_6=no
10439 fi
10440 rm -f core conftest.err conftest.$ac_objext \
10441 conftest$ac_exeext conftest.$ac_ext
10442 fi
10443
10444 if test $emacs_cv_x11_version_6 = yes; then
10445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10446 $as_echo "6 or newer" >&6; }
10447
10448 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10449
10450
10451 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10452
10453 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10454 ## XIM support.
10455 case "$opsys" in
10456 sol2-*) : ;;
10457 *)
10458 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10459
10460 ;;
10461 esac
10462 else
10463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10464 $as_echo "before 6" >&6; }
10465 fi
10466 fi
10467
10468
10469 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10470 HAVE_RSVG=no
10471 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10472 if test "${with_rsvg}" != "no"; then
10473 RSVG_REQUIRED=2.11.0
10474 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10475
10476
10477 succeeded=no
10478
10479 if test "$PKG_CONFIG" = "no" ; then
10480 :
10481 else
10482 PKG_CONFIG_MIN_VERSION=0.9.0
10483 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10485 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10486
10487 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10488 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10489 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10490 edit_cflags="
10491 s,///*,/,g
10492 s/^/ /
10493 s/ -I/ $isystem/g
10494 s/^ //
10495 "
10496 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10497 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10499 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10500 succeeded=yes
10501 else
10502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10503 $as_echo "no" >&6; }
10504 RSVG_CFLAGS=""
10505 RSVG_LIBS=""
10506 ## If we have a custom action on failure, don't print errors, but
10507 ## do set a variable so people can do so. Do it in a subshell
10508 ## to capture any diagnostics in invoking pkg-config.
10509 RSVG_PKG_ERRORS=`($PKG_CONFIG --print-errors "$RSVG_MODULE") 2>&1`
10510
10511 fi
10512
10513
10514
10515 else
10516 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10517 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10518 fi
10519 fi
10520
10521 if test $succeeded = yes; then
10522 HAVE_RSVG=yes
10523 else
10524 :
10525 fi
10526
10527
10528
10529
10530 if test $HAVE_RSVG = yes; then
10531
10532 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10533
10534 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10535 LIBS="$RSVG_LIBS $LIBS"
10536 fi
10537 fi
10538 fi
10539
10540 HAVE_IMAGEMAGICK=no
10541 if test "${HAVE_X11}" = "yes"; then
10542 if test "${with_imagemagick}" != "no"; then
10543 ## 6.2.8 is the earliest version known to work, but earlier versions
10544 ## might work - let us know if you find one.
10545 ## 6.0.7 does not work. See bug#7955.
10546 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10547
10548 succeeded=no
10549
10550 if test "$PKG_CONFIG" = "no" ; then
10551 :
10552 else
10553 PKG_CONFIG_MIN_VERSION=0.9.0
10554 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10556 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10557
10558 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10559 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10560 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10561 edit_cflags="
10562 s,///*,/,g
10563 s/^/ /
10564 s/ -I/ $isystem/g
10565 s/^ //
10566 "
10567 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10568 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10570 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10571 succeeded=yes
10572 else
10573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10574 $as_echo "no" >&6; }
10575 IMAGEMAGICK_CFLAGS=""
10576 IMAGEMAGICK_LIBS=""
10577 ## If we have a custom action on failure, don't print errors, but
10578 ## do set a variable so people can do so. Do it in a subshell
10579 ## to capture any diagnostics in invoking pkg-config.
10580 IMAGEMAGICK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
10581
10582 fi
10583
10584
10585
10586 else
10587 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10588 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10589 fi
10590 fi
10591
10592 if test $succeeded = yes; then
10593 HAVE_IMAGEMAGICK=yes
10594 else
10595 :
10596 fi
10597
10598
10599
10600
10601 if test $HAVE_IMAGEMAGICK = yes; then
10602
10603 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10604
10605 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10606 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10607 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10608 do :
10609 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10610 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10611 eval as_val=\$$as_ac_var
10612 if test "x$as_val" = x""yes; then :
10613 cat >>confdefs.h <<_ACEOF
10614 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10615 _ACEOF
10616
10617 fi
10618 done
10619
10620 fi
10621 fi
10622 fi
10623
10624
10625 HAVE_GTK=no
10626 GTK_OBJ=
10627 check_gtk2=no
10628 gtk3_pkg_errors=
10629 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10630 GLIB_REQUIRED=2.28
10631 GTK_REQUIRED=3.0
10632 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10633
10634
10635 succeeded=no
10636
10637 if test "$PKG_CONFIG" = "no" ; then
10638 pkg_check_gtk=no
10639 else
10640 PKG_CONFIG_MIN_VERSION=0.9.0
10641 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10643 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10644
10645 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10646 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10647 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10648 edit_cflags="
10649 s,///*,/,g
10650 s/^/ /
10651 s/ -I/ $isystem/g
10652 s/^ //
10653 "
10654 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10655 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10657 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10658 succeeded=yes
10659 else
10660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10661 $as_echo "no" >&6; }
10662 GTK_CFLAGS=""
10663 GTK_LIBS=""
10664 ## If we have a custom action on failure, don't print errors, but
10665 ## do set a variable so people can do so. Do it in a subshell
10666 ## to capture any diagnostics in invoking pkg-config.
10667 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10668
10669 fi
10670
10671
10672
10673 else
10674 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10675 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10676 fi
10677 fi
10678
10679 if test $succeeded = yes; then
10680 pkg_check_gtk=yes
10681 else
10682 pkg_check_gtk=no
10683 fi
10684
10685 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
10686 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10687 fi
10688 if test "$pkg_check_gtk" = "yes"; then
10689
10690 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10691
10692 GTK_OBJ=emacsgtkfixed.o
10693 term_header=gtkutil.h
10694 USE_GTK_TOOLKIT="GTK3"
10695 else
10696 check_gtk2=yes
10697 gtk3_pkg_errors="$GTK_PKG_ERRORS "
10698 fi
10699 fi
10700
10701 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
10702 GLIB_REQUIRED=2.10
10703 GTK_REQUIRED=2.10
10704 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10705
10706
10707 succeeded=no
10708
10709 if test "$PKG_CONFIG" = "no" ; then
10710 pkg_check_gtk=no
10711 else
10712 PKG_CONFIG_MIN_VERSION=0.9.0
10713 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10715 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10716
10717 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10718 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10719 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10720 edit_cflags="
10721 s,///*,/,g
10722 s/^/ /
10723 s/ -I/ $isystem/g
10724 s/^ //
10725 "
10726 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10727 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10729 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10730 succeeded=yes
10731 else
10732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10733 $as_echo "no" >&6; }
10734 GTK_CFLAGS=""
10735 GTK_LIBS=""
10736 ## If we have a custom action on failure, don't print errors, but
10737 ## do set a variable so people can do so. Do it in a subshell
10738 ## to capture any diagnostics in invoking pkg-config.
10739 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10740
10741 fi
10742
10743
10744
10745 else
10746 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10747 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10748 fi
10749 fi
10750
10751 if test $succeeded = yes; then
10752 pkg_check_gtk=yes
10753 else
10754 pkg_check_gtk=no
10755 fi
10756
10757 if test "$pkg_check_gtk" = "no" &&
10758 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
10759 then
10760 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
10761 fi
10762 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
10763 fi
10764
10765 if test x"$pkg_check_gtk" = xyes; then
10766
10767
10768
10769 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10770 CFLAGS="$CFLAGS $GTK_CFLAGS"
10771 LIBS="$GTK_LIBS $LIBS"
10772 GTK_COMPILES=no
10773 for ac_func in gtk_main
10774 do :
10775 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10776 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10777 cat >>confdefs.h <<_ACEOF
10778 #define HAVE_GTK_MAIN 1
10779 _ACEOF
10780 GTK_COMPILES=yes
10781 fi
10782 done
10783
10784 if test "${GTK_COMPILES}" != "yes"; then
10785 if test "$USE_X_TOOLKIT" != "maybe"; then
10786 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10787 fi
10788 else
10789 HAVE_GTK=yes
10790
10791 $as_echo "#define USE_GTK 1" >>confdefs.h
10792
10793 GTK_OBJ="gtkutil.o $GTK_OBJ"
10794 USE_X_TOOLKIT=none
10795 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10796 :
10797 else
10798 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10799 closing open displays. This is no problem if you just use
10800 one display, but if you use more than one and close one of them
10801 Emacs may crash." >&5
10802 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10803 closing open displays. This is no problem if you just use
10804 one display, but if you use more than one and close one of them
10805 Emacs may crash." >&2;}
10806 sleep 3
10807 fi
10808 fi
10809
10810 fi
10811
10812
10813
10814 if test "${HAVE_GTK}" = "yes"; then
10815
10816 if test "$with_toolkit_scroll_bars" != no; then
10817 with_toolkit_scroll_bars=yes
10818 fi
10819
10820 HAVE_GTK_FILE_SELECTION=no
10821 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10822 #include <gtk/gtk.h>
10823 "
10824 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10825 HAVE_GTK_FILE_SELECTION=yes
10826 else
10827 HAVE_GTK_FILE_SELECTION=no
10828 fi
10829
10830 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10831 for ac_func in gtk_file_selection_new
10832 do :
10833 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10834 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10835 cat >>confdefs.h <<_ACEOF
10836 #define HAVE_GTK_FILE_SELECTION_NEW 1
10837 _ACEOF
10838
10839 fi
10840 done
10841
10842 fi
10843
10844
10845 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10846 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10847 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10848 gtk_orientable_set_orientation \
10849 gtk_window_set_has_resize_grip
10850 do :
10851 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10852 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10853 eval as_val=\$$as_ac_var
10854 if test "x$as_val" = x""yes; then :
10855 cat >>confdefs.h <<_ACEOF
10856 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10857 _ACEOF
10858
10859 fi
10860 done
10861
10862
10863 term_header=gtkutil.h
10864 fi
10865
10866 HAVE_DBUS=no
10867 DBUS_OBJ=
10868 if test "${with_dbus}" = "yes"; then
10869
10870 succeeded=no
10871
10872 if test "$PKG_CONFIG" = "no" ; then
10873 HAVE_DBUS=no
10874 else
10875 PKG_CONFIG_MIN_VERSION=0.9.0
10876 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10878 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10879
10880 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10881 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10882 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10883 edit_cflags="
10884 s,///*,/,g
10885 s/^/ /
10886 s/ -I/ $isystem/g
10887 s/^ //
10888 "
10889 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10890 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10892 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10893 succeeded=yes
10894 else
10895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10896 $as_echo "no" >&6; }
10897 DBUS_CFLAGS=""
10898 DBUS_LIBS=""
10899 ## If we have a custom action on failure, don't print errors, but
10900 ## do set a variable so people can do so. Do it in a subshell
10901 ## to capture any diagnostics in invoking pkg-config.
10902 DBUS_PKG_ERRORS=`($PKG_CONFIG --print-errors "dbus-1 >= 1.0") 2>&1`
10903
10904 fi
10905
10906
10907
10908 else
10909 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10910 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10911 fi
10912 fi
10913
10914 if test $succeeded = yes; then
10915 HAVE_DBUS=yes
10916 else
10917 HAVE_DBUS=no
10918 fi
10919
10920 if test "$HAVE_DBUS" = yes; then
10921 LIBS="$LIBS $DBUS_LIBS"
10922
10923 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10924
10925 for ac_func in dbus_watch_get_unix_fd \
10926 dbus_type_is_valid \
10927 dbus_validate_bus_name \
10928 dbus_validate_path \
10929 dbus_validate_interface \
10930 dbus_validate_member
10931 do :
10932 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10933 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10934 eval as_val=\$$as_ac_var
10935 if test "x$as_val" = x""yes; then :
10936 cat >>confdefs.h <<_ACEOF
10937 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10938 _ACEOF
10939
10940 fi
10941 done
10942
10943 DBUS_OBJ=dbusbind.o
10944 fi
10945 fi
10946
10947
10948 HAVE_GSETTINGS=no
10949 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10950
10951 succeeded=no
10952
10953 if test "$PKG_CONFIG" = "no" ; then
10954 HAVE_GSETTINGS=no
10955 else
10956 PKG_CONFIG_MIN_VERSION=0.9.0
10957 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10959 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10960
10961 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10962 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10963 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10964 edit_cflags="
10965 s,///*,/,g
10966 s/^/ /
10967 s/ -I/ $isystem/g
10968 s/^ //
10969 "
10970 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10971 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10973 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10974 succeeded=yes
10975 else
10976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10977 $as_echo "no" >&6; }
10978 GSETTINGS_CFLAGS=""
10979 GSETTINGS_LIBS=""
10980 ## If we have a custom action on failure, don't print errors, but
10981 ## do set a variable so people can do so. Do it in a subshell
10982 ## to capture any diagnostics in invoking pkg-config.
10983 GSETTINGS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gio-2.0 >= 2.26") 2>&1`
10984
10985 fi
10986
10987
10988
10989 else
10990 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10991 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10992 fi
10993 fi
10994
10995 if test $succeeded = yes; then
10996 HAVE_GSETTINGS=yes
10997 else
10998 HAVE_GSETTINGS=no
10999 fi
11000
11001 if test "$HAVE_GSETTINGS" = "yes"; then
11002
11003 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11004
11005 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11006 SETTINGS_LIBS="$GSETTINGS_LIBS"
11007 fi
11008 fi
11009
11010 HAVE_GCONF=no
11011 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11012
11013 succeeded=no
11014
11015 if test "$PKG_CONFIG" = "no" ; then
11016 HAVE_GCONF=no
11017 else
11018 PKG_CONFIG_MIN_VERSION=0.9.0
11019 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11021 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11022
11023 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
11024 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11025 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
11026 edit_cflags="
11027 s,///*,/,g
11028 s/^/ /
11029 s/ -I/ $isystem/g
11030 s/^ //
11031 "
11032 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11033 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11035 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11036 succeeded=yes
11037 else
11038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11039 $as_echo "no" >&6; }
11040 GCONF_CFLAGS=""
11041 GCONF_LIBS=""
11042 ## If we have a custom action on failure, don't print errors, but
11043 ## do set a variable so people can do so. Do it in a subshell
11044 ## to capture any diagnostics in invoking pkg-config.
11045 GCONF_PKG_ERRORS=`($PKG_CONFIG --print-errors "gconf-2.0 >= 2.13") 2>&1`
11046
11047 fi
11048
11049
11050
11051 else
11052 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11053 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11054 fi
11055 fi
11056
11057 if test $succeeded = yes; then
11058 HAVE_GCONF=yes
11059 else
11060 HAVE_GCONF=no
11061 fi
11062
11063 if test "$HAVE_GCONF" = yes; then
11064
11065 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11066
11067 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11068 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11069 fi
11070 fi
11071
11072 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11073
11074 succeeded=no
11075
11076 if test "$PKG_CONFIG" = "no" ; then
11077 HAVE_GOBJECT=no
11078 else
11079 PKG_CONFIG_MIN_VERSION=0.9.0
11080 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11082 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11083
11084 if $PKG_CONFIG --exists "gobject-2.0 >= 2.0" 2>&5 &&
11085 GOBJECT_CFLAGS=`$PKG_CONFIG --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11086 GOBJECT_LIBS=`$PKG_CONFIG --libs "gobject-2.0 >= 2.0" 2>&5`; then
11087 edit_cflags="
11088 s,///*,/,g
11089 s/^/ /
11090 s/ -I/ $isystem/g
11091 s/^ //
11092 "
11093 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11094 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11096 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11097 succeeded=yes
11098 else
11099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11100 $as_echo "no" >&6; }
11101 GOBJECT_CFLAGS=""
11102 GOBJECT_LIBS=""
11103 ## If we have a custom action on failure, don't print errors, but
11104 ## do set a variable so people can do so. Do it in a subshell
11105 ## to capture any diagnostics in invoking pkg-config.
11106 GOBJECT_PKG_ERRORS=`($PKG_CONFIG --print-errors "gobject-2.0 >= 2.0") 2>&1`
11107
11108 fi
11109
11110
11111
11112 else
11113 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11114 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11115 fi
11116 fi
11117
11118 if test $succeeded = yes; then
11119 HAVE_GOBJECT=yes
11120 else
11121 HAVE_GOBJECT=no
11122 fi
11123
11124 if test "$HAVE_GOBJECT" = "yes"; then
11125 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11126 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11127 fi
11128 SAVE_CFLAGS="$CFLAGS"
11129 SAVE_LIBS="$LIBS"
11130 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11131 LIBS="$SETTINGS_LIBS $LIBS"
11132 for ac_func in g_type_init
11133 do :
11134 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11135 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11136 cat >>confdefs.h <<_ACEOF
11137 #define HAVE_G_TYPE_INIT 1
11138 _ACEOF
11139
11140 fi
11141 done
11142
11143 CFLAGS="$SAVE_CFLAGS"
11144 LIBS="$SAVE_LIBS"
11145 fi
11146
11147
11148
11149
11150 HAVE_LIBSELINUX=no
11151 LIBSELINUX_LIBS=
11152 if test "${with_selinux}" = "yes"; then
11153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11154 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11155 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11156 $as_echo_n "(cached) " >&6
11157 else
11158 ac_check_lib_save_LIBS=$LIBS
11159 LIBS="-lselinux $LIBS"
11160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11161 /* end confdefs.h. */
11162
11163 /* Override any GCC internal prototype to avoid an error.
11164 Use char because int might match the return type of a GCC
11165 builtin and then its argument prototype would still apply. */
11166 #ifdef __cplusplus
11167 extern "C"
11168 #endif
11169 char lgetfilecon ();
11170 int
11171 main ()
11172 {
11173 return lgetfilecon ();
11174 ;
11175 return 0;
11176 }
11177 _ACEOF
11178 if ac_fn_c_try_link "$LINENO"; then :
11179 ac_cv_lib_selinux_lgetfilecon=yes
11180 else
11181 ac_cv_lib_selinux_lgetfilecon=no
11182 fi
11183 rm -f core conftest.err conftest.$ac_objext \
11184 conftest$ac_exeext conftest.$ac_ext
11185 LIBS=$ac_check_lib_save_LIBS
11186 fi
11187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11188 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11189 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11190 HAVE_LIBSELINUX=yes
11191 else
11192 HAVE_LIBSELINUX=no
11193 fi
11194
11195 if test "$HAVE_LIBSELINUX" = yes; then
11196
11197 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11198
11199 LIBSELINUX_LIBS=-lselinux
11200 fi
11201 fi
11202
11203
11204 HAVE_GNUTLS=no
11205 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11206 if test "${with_gnutls}" = "yes" ; then
11207
11208 succeeded=no
11209
11210 if test "$PKG_CONFIG" = "no" ; then
11211 HAVE_GNUTLS=no
11212 else
11213 PKG_CONFIG_MIN_VERSION=0.9.0
11214 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11216 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11217
11218 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11219 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11220 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11221 edit_cflags="
11222 s,///*,/,g
11223 s/^/ /
11224 s/ -I/ $isystem/g
11225 s/^ //
11226 "
11227 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11228 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11230 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11231 succeeded=yes
11232 else
11233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11234 $as_echo "no" >&6; }
11235 LIBGNUTLS_CFLAGS=""
11236 LIBGNUTLS_LIBS=""
11237 ## If we have a custom action on failure, don't print errors, but
11238 ## do set a variable so people can do so. Do it in a subshell
11239 ## to capture any diagnostics in invoking pkg-config.
11240 LIBGNUTLS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gnutls >= 2.6.6") 2>&1`
11241
11242 fi
11243
11244
11245
11246 else
11247 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11248 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11249 fi
11250 fi
11251
11252 if test $succeeded = yes; then
11253 HAVE_GNUTLS=yes
11254 else
11255 HAVE_GNUTLS=no
11256 fi
11257
11258 if test "${HAVE_GNUTLS}" = "yes"; then
11259
11260 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11261
11262 fi
11263
11264 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11265 LIBS="$LIBGNUTLS_LIBS $LIBS"
11266 for ac_func in gnutls_certificate_set_verify_function
11267 do :
11268 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11269 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11270 cat >>confdefs.h <<_ACEOF
11271 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11272 _ACEOF
11273 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11274 fi
11275 done
11276
11277
11278 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11279
11280 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11281
11282 fi
11283 fi
11284
11285
11286
11287
11288 HAVE_XAW3D=no
11289 LUCID_LIBW=
11290 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11291 if test "$with_xaw3d" != no; then
11292 if test "${emacs_cv_xaw3d+set}" = set; then :
11293 $as_echo_n "(cached) " >&6
11294 else
11295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11296 /* end confdefs.h. */
11297
11298 #include <X11/Intrinsic.h>
11299 #include <X11/Xaw3d/Simple.h>
11300 int
11301 main ()
11302 {
11303
11304 ;
11305 return 0;
11306 }
11307 _ACEOF
11308 if ac_fn_c_try_link "$LINENO"; then :
11309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11310 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11311 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11312 $as_echo_n "(cached) " >&6
11313 else
11314 ac_check_lib_save_LIBS=$LIBS
11315 LIBS="-lXaw3d $LIBS"
11316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11317 /* end confdefs.h. */
11318
11319 /* Override any GCC internal prototype to avoid an error.
11320 Use char because int might match the return type of a GCC
11321 builtin and then its argument prototype would still apply. */
11322 #ifdef __cplusplus
11323 extern "C"
11324 #endif
11325 char XawScrollbarSetThumb ();
11326 int
11327 main ()
11328 {
11329 return XawScrollbarSetThumb ();
11330 ;
11331 return 0;
11332 }
11333 _ACEOF
11334 if ac_fn_c_try_link "$LINENO"; then :
11335 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11336 else
11337 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11338 fi
11339 rm -f core conftest.err conftest.$ac_objext \
11340 conftest$ac_exeext conftest.$ac_ext
11341 LIBS=$ac_check_lib_save_LIBS
11342 fi
11343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11344 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11345 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11346 emacs_cv_xaw3d=yes
11347 else
11348 emacs_cv_xaw3d=no
11349 fi
11350
11351 else
11352 emacs_cv_xaw3d=no
11353 fi
11354 rm -f core conftest.err conftest.$ac_objext \
11355 conftest$ac_exeext conftest.$ac_ext
11356 fi
11357
11358 else
11359 emacs_cv_xaw3d=no
11360 fi
11361 if test $emacs_cv_xaw3d = yes; then
11362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11363 $as_echo_n "checking for xaw3d... " >&6; }
11364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11365 $as_echo "yes; using Lucid toolkit" >&6; }
11366 USE_X_TOOLKIT=LUCID
11367 HAVE_XAW3D=yes
11368 LUCID_LIBW=-lXaw3d
11369
11370 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11371
11372 else
11373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11374 $as_echo_n "checking for xaw3d... " >&6; }
11375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11376 $as_echo "no" >&6; }
11377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11378 $as_echo_n "checking for libXaw... " >&6; }
11379 if test "${emacs_cv_xaw+set}" = set; then :
11380 $as_echo_n "(cached) " >&6
11381 else
11382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11383 /* end confdefs.h. */
11384
11385 #include <X11/Intrinsic.h>
11386 #include <X11/Xaw/Simple.h>
11387 int
11388 main ()
11389 {
11390
11391 ;
11392 return 0;
11393 }
11394 _ACEOF
11395 if ac_fn_c_try_link "$LINENO"; then :
11396 emacs_cv_xaw=yes
11397 else
11398 emacs_cv_xaw=no
11399 fi
11400 rm -f core conftest.err conftest.$ac_objext \
11401 conftest$ac_exeext conftest.$ac_ext
11402 fi
11403
11404 if test $emacs_cv_xaw = yes; then
11405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11406 $as_echo "yes; using Lucid toolkit" >&6; }
11407 USE_X_TOOLKIT=LUCID
11408 LUCID_LIBW=-lXaw
11409 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11410 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11411 else
11412 as_fn_error "No X toolkit could be found.
11413 If you are sure you want Emacs compiled without an X toolkit, pass
11414 --with-x-toolkit=no
11415 to configure. Otherwise, install the development libraries for the toolkit
11416 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11417 fi
11418 fi
11419 fi
11420
11421 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11422
11423 LIBXTR6=
11424 if test "${USE_X_TOOLKIT}" != "none"; then
11425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11426 $as_echo_n "checking X11 toolkit version... " >&6; }
11427 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11428 $as_echo_n "(cached) " >&6
11429 else
11430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11431 /* end confdefs.h. */
11432 #include <X11/Intrinsic.h>
11433 int
11434 main ()
11435 {
11436 #if XtSpecificationRelease < 6
11437 fail;
11438 #endif
11439
11440 ;
11441 return 0;
11442 }
11443 _ACEOF
11444 if ac_fn_c_try_link "$LINENO"; then :
11445 emacs_cv_x11_toolkit_version_6=yes
11446 else
11447 emacs_cv_x11_toolkit_version_6=no
11448 fi
11449 rm -f core conftest.err conftest.$ac_objext \
11450 conftest$ac_exeext conftest.$ac_ext
11451 fi
11452
11453 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11454 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11456 $as_echo "6 or newer" >&6; }
11457
11458 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11459
11460 LIBXTR6="-lSM -lICE"
11461 case "$opsys" in
11462 ## Use libw.a along with X11R6 Xt.
11463 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11464 esac
11465 else
11466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11467 $as_echo "before 6" >&6; }
11468 fi
11469
11470 OLDLIBS="$LIBS"
11471 if test x$HAVE_X11XTR6 = xyes; then
11472 LIBS="-lXt -lSM -lICE $LIBS"
11473 else
11474 LIBS="-lXt $LIBS"
11475 fi
11476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11477 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11478 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11479 $as_echo_n "(cached) " >&6
11480 else
11481 ac_check_lib_save_LIBS=$LIBS
11482 LIBS="-lXmu $LIBS"
11483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11484 /* end confdefs.h. */
11485
11486 /* Override any GCC internal prototype to avoid an error.
11487 Use char because int might match the return type of a GCC
11488 builtin and then its argument prototype would still apply. */
11489 #ifdef __cplusplus
11490 extern "C"
11491 #endif
11492 char XmuConvertStandardSelection ();
11493 int
11494 main ()
11495 {
11496 return XmuConvertStandardSelection ();
11497 ;
11498 return 0;
11499 }
11500 _ACEOF
11501 if ac_fn_c_try_link "$LINENO"; then :
11502 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11503 else
11504 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11505 fi
11506 rm -f core conftest.err conftest.$ac_objext \
11507 conftest$ac_exeext conftest.$ac_ext
11508 LIBS=$ac_check_lib_save_LIBS
11509 fi
11510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11511 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11512 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11513 cat >>confdefs.h <<_ACEOF
11514 #define HAVE_LIBXMU 1
11515 _ACEOF
11516
11517 LIBS="-lXmu $LIBS"
11518
11519 fi
11520
11521 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11522 fi
11523
11524
11525 LIBXMU=-lXmu
11526 case $opsys in
11527 ## These systems don't supply Xmu.
11528 hpux* | aix4-2 )
11529 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11530 ;;
11531 esac
11532
11533
11534 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11535 if test "${HAVE_X11}" = "yes"; then
11536 if test "${USE_X_TOOLKIT}" != "none"; then
11537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11538 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11539 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11540 $as_echo_n "(cached) " >&6
11541 else
11542 ac_check_lib_save_LIBS=$LIBS
11543 LIBS="-lXext $LIBS"
11544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11545 /* end confdefs.h. */
11546
11547 /* Override any GCC internal prototype to avoid an error.
11548 Use char because int might match the return type of a GCC
11549 builtin and then its argument prototype would still apply. */
11550 #ifdef __cplusplus
11551 extern "C"
11552 #endif
11553 char XShapeQueryExtension ();
11554 int
11555 main ()
11556 {
11557 return XShapeQueryExtension ();
11558 ;
11559 return 0;
11560 }
11561 _ACEOF
11562 if ac_fn_c_try_link "$LINENO"; then :
11563 ac_cv_lib_Xext_XShapeQueryExtension=yes
11564 else
11565 ac_cv_lib_Xext_XShapeQueryExtension=no
11566 fi
11567 rm -f core conftest.err conftest.$ac_objext \
11568 conftest$ac_exeext conftest.$ac_ext
11569 LIBS=$ac_check_lib_save_LIBS
11570 fi
11571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11572 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11573 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11574 cat >>confdefs.h <<_ACEOF
11575 #define HAVE_LIBXEXT 1
11576 _ACEOF
11577
11578 LIBS="-lXext $LIBS"
11579
11580 fi
11581
11582 fi
11583 fi
11584
11585 LIBXP=
11586 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11587 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11588 if test -d /usr/include/openmotif; then
11589 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11590 emacs_cv_openmotif=yes
11591 case "$canonical" in
11592 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11593 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11594 ;;
11595 *)
11596 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11597 esac
11598 else
11599 emacs_cv_openmotif=no
11600 fi
11601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11602 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11603 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11604 $as_echo_n "(cached) " >&6
11605 else
11606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11607 /* end confdefs.h. */
11608 #include <Xm/Xm.h>
11609 int
11610 main ()
11611 {
11612 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11613 int x = 5;
11614 #else
11615 Motif version prior to 2.1.
11616 #endif
11617 ;
11618 return 0;
11619 }
11620 _ACEOF
11621 if ac_fn_c_try_compile "$LINENO"; then :
11622 emacs_cv_motif_version_2_1=yes
11623 else
11624 emacs_cv_motif_version_2_1=no
11625 fi
11626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11627 fi
11628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11629 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11630 if test $emacs_cv_motif_version_2_1 = yes; then
11631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11632 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11633 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11634 $as_echo_n "(cached) " >&6
11635 else
11636 ac_check_lib_save_LIBS=$LIBS
11637 LIBS="-lXp $LIBS"
11638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11639 /* end confdefs.h. */
11640
11641 /* Override any GCC internal prototype to avoid an error.
11642 Use char because int might match the return type of a GCC
11643 builtin and then its argument prototype would still apply. */
11644 #ifdef __cplusplus
11645 extern "C"
11646 #endif
11647 char XpCreateContext ();
11648 int
11649 main ()
11650 {
11651 return XpCreateContext ();
11652 ;
11653 return 0;
11654 }
11655 _ACEOF
11656 if ac_fn_c_try_link "$LINENO"; then :
11657 ac_cv_lib_Xp_XpCreateContext=yes
11658 else
11659 ac_cv_lib_Xp_XpCreateContext=no
11660 fi
11661 rm -f core conftest.err conftest.$ac_objext \
11662 conftest$ac_exeext conftest.$ac_ext
11663 LIBS=$ac_check_lib_save_LIBS
11664 fi
11665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11666 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11667 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11668 LIBXP=-lXp
11669 fi
11670
11671 if test x$emacs_cv_openmotif = xyes; then
11672 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11673 fi
11674 else
11675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11676 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11677 if test "${emacs_cv_lesstif+set}" = set; then :
11678 $as_echo_n "(cached) " >&6
11679 else
11680 # We put this in CFLAGS temporarily to precede other -I options
11681 # that might be in CFLAGS temporarily.
11682 # We put this in CPPFLAGS where it precedes the other -I options.
11683 OLD_CPPFLAGS=$CPPFLAGS
11684 OLD_CFLAGS=$CFLAGS
11685 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11686 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11688 /* end confdefs.h. */
11689 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11690 int
11691 main ()
11692 {
11693 int x = 5;
11694 ;
11695 return 0;
11696 }
11697 _ACEOF
11698 if ac_fn_c_try_compile "$LINENO"; then :
11699 emacs_cv_lesstif=yes
11700 else
11701 emacs_cv_lesstif=no
11702 fi
11703 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11704 fi
11705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11706 $as_echo "$emacs_cv_lesstif" >&6; }
11707 if test $emacs_cv_lesstif = yes; then
11708 # Make sure this -I option remains in CPPFLAGS after it is set
11709 # back to REAL_CPPFLAGS.
11710 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11711 # have those other -I options anyway. Ultimately, having this
11712 # directory ultimately in CPPFLAGS will be enough.
11713 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11714 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11715 else
11716 CFLAGS=$OLD_CFLAGS
11717 CPPFLAGS=$OLD_CPPFLAGS
11718 fi
11719 fi
11720 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11721 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11722
11723 else
11724 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11725 fi
11726
11727
11728 fi
11729
11730
11731 USE_TOOLKIT_SCROLL_BARS=no
11732 if test "${with_toolkit_scroll_bars}" != "no"; then
11733 if test "${USE_X_TOOLKIT}" != "none"; then
11734 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11735 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11736
11737 HAVE_XAW3D=no
11738 USE_TOOLKIT_SCROLL_BARS=yes
11739 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11740 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11741
11742 USE_TOOLKIT_SCROLL_BARS=yes
11743 fi
11744 elif test "${HAVE_GTK}" = "yes"; then
11745 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11746
11747 USE_TOOLKIT_SCROLL_BARS=yes
11748 elif test "${HAVE_NS}" = "yes"; then
11749 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11750
11751 USE_TOOLKIT_SCROLL_BARS=yes
11752 elif test "${HAVE_W32}" = "yes"; then
11753 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11754
11755 USE_TOOLKIT_SCROLL_BARS=yes
11756 fi
11757 fi
11758
11759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11760 /* end confdefs.h. */
11761
11762 #include <X11/Xlib.h>
11763 #include <X11/Xresource.h>
11764 int
11765 main ()
11766 {
11767 XIMProc callback;
11768 ;
11769 return 0;
11770 }
11771 _ACEOF
11772 if ac_fn_c_try_compile "$LINENO"; then :
11773 HAVE_XIM=yes
11774
11775 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11776
11777 else
11778 HAVE_XIM=no
11779 fi
11780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11781
11782
11783 if test "${with_xim}" != "no"; then
11784
11785 $as_echo "#define USE_XIM 1" >>confdefs.h
11786
11787 fi
11788
11789
11790 if test "${HAVE_XIM}" != "no"; then
11791 late_CFLAGS=$CFLAGS
11792 if test "$GCC" = yes; then
11793 CFLAGS="$CFLAGS --pedantic-errors"
11794 fi
11795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11796 /* end confdefs.h. */
11797
11798 #include <X11/Xlib.h>
11799 #include <X11/Xresource.h>
11800 int
11801 main ()
11802 {
11803 Display *display;
11804 XrmDatabase db;
11805 char *res_name;
11806 char *res_class;
11807 XIMProc callback;
11808 XPointer *client_data;
11809 #ifndef __GNUC__
11810 /* If we're not using GCC, it's probably not XFree86, and this is
11811 probably right, but we can't use something like --pedantic-errors. */
11812 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11813 char*, XIMProc, XPointer*);
11814 #endif
11815 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11816 client_data);
11817 ;
11818 return 0;
11819 }
11820 _ACEOF
11821 if ac_fn_c_try_compile "$LINENO"; then :
11822 emacs_cv_arg6_star=yes
11823 fi
11824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11825 if test "$emacs_cv_arg6_star" = yes; then
11826 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11827
11828 else
11829 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11830
11831 fi
11832 CFLAGS=$late_CFLAGS
11833 fi
11834
11835 ### Start of font-backend (under any platform) section.
11836 # (nothing here yet -- this is a placeholder)
11837 ### End of font-backend (under any platform) section.
11838
11839 ### Start of font-backend (under X11) section.
11840 if test "${HAVE_X11}" = "yes"; then
11841
11842 succeeded=no
11843
11844 if test "$PKG_CONFIG" = "no" ; then
11845 HAVE_FC=no
11846 else
11847 PKG_CONFIG_MIN_VERSION=0.9.0
11848 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11850 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11851
11852 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11853 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11854 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11855 edit_cflags="
11856 s,///*,/,g
11857 s/^/ /
11858 s/ -I/ $isystem/g
11859 s/^ //
11860 "
11861 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11862 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11864 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11865 succeeded=yes
11866 else
11867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11868 $as_echo "no" >&6; }
11869 FONTCONFIG_CFLAGS=""
11870 FONTCONFIG_LIBS=""
11871 ## If we have a custom action on failure, don't print errors, but
11872 ## do set a variable so people can do so. Do it in a subshell
11873 ## to capture any diagnostics in invoking pkg-config.
11874 FONTCONFIG_PKG_ERRORS=`($PKG_CONFIG --print-errors "fontconfig >= 2.2.0") 2>&1`
11875
11876 fi
11877
11878
11879
11880 else
11881 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11882 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11883 fi
11884 fi
11885
11886 if test $succeeded = yes; then
11887 HAVE_FC=yes
11888 else
11889 HAVE_FC=no
11890 fi
11891
11892
11893 ## Use -lXft if available, unless `--with-xft=no'.
11894 HAVE_XFT=maybe
11895 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11896 with_xft="no";
11897 fi
11898 if test "x${with_xft}" != "xno"; then
11899
11900
11901 succeeded=no
11902
11903 if test "$PKG_CONFIG" = "no" ; then
11904 HAVE_XFT=no
11905 else
11906 PKG_CONFIG_MIN_VERSION=0.9.0
11907 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11909 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11910
11911 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11912 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11913 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11914 edit_cflags="
11915 s,///*,/,g
11916 s/^/ /
11917 s/ -I/ $isystem/g
11918 s/^ //
11919 "
11920 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11921 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11923 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11924 succeeded=yes
11925 else
11926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11927 $as_echo "no" >&6; }
11928 XFT_CFLAGS=""
11929 XFT_LIBS=""
11930 ## If we have a custom action on failure, don't print errors, but
11931 ## do set a variable so people can do so. Do it in a subshell
11932 ## to capture any diagnostics in invoking pkg-config.
11933 XFT_PKG_ERRORS=`($PKG_CONFIG --print-errors "xft >= 0.13.0") 2>&1`
11934
11935 fi
11936
11937
11938
11939 else
11940 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11941 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11942 fi
11943 fi
11944
11945 if test $succeeded = yes; then
11946 :
11947 else
11948 HAVE_XFT=no
11949 fi
11950
11951 ## Because xftfont.c uses XRenderQueryExtension, we also
11952 ## need to link to -lXrender.
11953 HAVE_XRENDER=no
11954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11955 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11956 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11957 $as_echo_n "(cached) " >&6
11958 else
11959 ac_check_lib_save_LIBS=$LIBS
11960 LIBS="-lXrender $LIBS"
11961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11962 /* end confdefs.h. */
11963
11964 /* Override any GCC internal prototype to avoid an error.
11965 Use char because int might match the return type of a GCC
11966 builtin and then its argument prototype would still apply. */
11967 #ifdef __cplusplus
11968 extern "C"
11969 #endif
11970 char XRenderQueryExtension ();
11971 int
11972 main ()
11973 {
11974 return XRenderQueryExtension ();
11975 ;
11976 return 0;
11977 }
11978 _ACEOF
11979 if ac_fn_c_try_link "$LINENO"; then :
11980 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11981 else
11982 ac_cv_lib_Xrender_XRenderQueryExtension=no
11983 fi
11984 rm -f core conftest.err conftest.$ac_objext \
11985 conftest$ac_exeext conftest.$ac_ext
11986 LIBS=$ac_check_lib_save_LIBS
11987 fi
11988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11989 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11990 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11991 HAVE_XRENDER=yes
11992 fi
11993
11994 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11995 OLD_CPPFLAGS="$CPPFLAGS"
11996 OLD_CFLAGS="$CFLAGS"
11997 OLD_LIBS="$LIBS"
11998 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11999 CFLAGS="$CFLAGS $XFT_CFLAGS"
12000 XFT_LIBS="-lXrender $XFT_LIBS"
12001 LIBS="$XFT_LIBS $LIBS"
12002 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12003 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12005 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12006 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12007 $as_echo_n "(cached) " >&6
12008 else
12009 ac_check_lib_save_LIBS=$LIBS
12010 LIBS="-lXft $XFT_LIBS $LIBS"
12011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12012 /* end confdefs.h. */
12013
12014 /* Override any GCC internal prototype to avoid an error.
12015 Use char because int might match the return type of a GCC
12016 builtin and then its argument prototype would still apply. */
12017 #ifdef __cplusplus
12018 extern "C"
12019 #endif
12020 char XftFontOpen ();
12021 int
12022 main ()
12023 {
12024 return XftFontOpen ();
12025 ;
12026 return 0;
12027 }
12028 _ACEOF
12029 if ac_fn_c_try_link "$LINENO"; then :
12030 ac_cv_lib_Xft_XftFontOpen=yes
12031 else
12032 ac_cv_lib_Xft_XftFontOpen=no
12033 fi
12034 rm -f core conftest.err conftest.$ac_objext \
12035 conftest$ac_exeext conftest.$ac_ext
12036 LIBS=$ac_check_lib_save_LIBS
12037 fi
12038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12039 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12040 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12041 HAVE_XFT=yes
12042 fi
12043
12044 fi
12045
12046
12047
12048 if test "${HAVE_XFT}" = "yes"; then
12049
12050 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12051
12052
12053 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12054 else
12055 CPPFLAGS="$OLD_CPPFLAGS"
12056 CFLAGS="$OLD_CFLAGS"
12057 LIBS="$OLD_LIBS"
12058 fi # "${HAVE_XFT}" = "yes"
12059 fi # "$HAVE_XFT" != no
12060 fi # "x${with_xft}" != "xno"
12061
12062 ## We used to allow building with FreeType and without Xft.
12063 ## However, the ftx font backend driver is not in good shape.
12064 if test "$HAVE_XFT" != "yes"; then
12065 HAVE_XFT=no
12066 HAVE_FREETYPE=no
12067 else
12068
12069 succeeded=no
12070
12071 if test "$PKG_CONFIG" = "no" ; then
12072 HAVE_FREETYPE=no
12073 else
12074 PKG_CONFIG_MIN_VERSION=0.9.0
12075 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12077 $as_echo_n "checking for freetype2... " >&6; }
12078
12079 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
12080 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
12081 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
12082 edit_cflags="
12083 s,///*,/,g
12084 s/^/ /
12085 s/ -I/ $isystem/g
12086 s/^ //
12087 "
12088 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12089 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12091 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12092 succeeded=yes
12093 else
12094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12095 $as_echo "no" >&6; }
12096 FREETYPE_CFLAGS=""
12097 FREETYPE_LIBS=""
12098 ## If we have a custom action on failure, don't print errors, but
12099 ## do set a variable so people can do so. Do it in a subshell
12100 ## to capture any diagnostics in invoking pkg-config.
12101 FREETYPE_PKG_ERRORS=`($PKG_CONFIG --print-errors "freetype2") 2>&1`
12102
12103 fi
12104
12105
12106
12107 else
12108 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12109 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12110 fi
12111 fi
12112
12113 if test $succeeded = yes; then
12114 HAVE_FREETYPE=yes
12115 else
12116 HAVE_FREETYPE=no
12117 fi
12118
12119
12120 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12121 fi
12122
12123 HAVE_LIBOTF=no
12124 if test "${HAVE_FREETYPE}" = "yes"; then
12125
12126 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12127
12128 if test "${with_libotf}" != "no"; then
12129
12130 succeeded=no
12131
12132 if test "$PKG_CONFIG" = "no" ; then
12133 HAVE_LIBOTF=no
12134 else
12135 PKG_CONFIG_MIN_VERSION=0.9.0
12136 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12138 $as_echo_n "checking for libotf... " >&6; }
12139
12140 if $PKG_CONFIG --exists "libotf" 2>&5 &&
12141 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
12142 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
12143 edit_cflags="
12144 s,///*,/,g
12145 s/^/ /
12146 s/ -I/ $isystem/g
12147 s/^ //
12148 "
12149 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12150 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12152 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12153 succeeded=yes
12154 else
12155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12156 $as_echo "no" >&6; }
12157 LIBOTF_CFLAGS=""
12158 LIBOTF_LIBS=""
12159 ## If we have a custom action on failure, don't print errors, but
12160 ## do set a variable so people can do so. Do it in a subshell
12161 ## to capture any diagnostics in invoking pkg-config.
12162 LIBOTF_PKG_ERRORS=`($PKG_CONFIG --print-errors "libotf") 2>&1`
12163
12164 fi
12165
12166
12167
12168 else
12169 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12170 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12171 fi
12172 fi
12173
12174 if test $succeeded = yes; then
12175 HAVE_LIBOTF=yes
12176 else
12177 HAVE_LIBOTF=no
12178 fi
12179
12180 if test "$HAVE_LIBOTF" = "yes"; then
12181
12182 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12183
12184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12185 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12186 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12187 $as_echo_n "(cached) " >&6
12188 else
12189 ac_check_lib_save_LIBS=$LIBS
12190 LIBS="-lotf $LIBS"
12191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12192 /* end confdefs.h. */
12193
12194 /* Override any GCC internal prototype to avoid an error.
12195 Use char because int might match the return type of a GCC
12196 builtin and then its argument prototype would still apply. */
12197 #ifdef __cplusplus
12198 extern "C"
12199 #endif
12200 char OTF_get_variation_glyphs ();
12201 int
12202 main ()
12203 {
12204 return OTF_get_variation_glyphs ();
12205 ;
12206 return 0;
12207 }
12208 _ACEOF
12209 if ac_fn_c_try_link "$LINENO"; then :
12210 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12211 else
12212 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12213 fi
12214 rm -f core conftest.err conftest.$ac_objext \
12215 conftest$ac_exeext conftest.$ac_ext
12216 LIBS=$ac_check_lib_save_LIBS
12217 fi
12218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12219 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12220 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12221 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12222 else
12223 HAVE_OTF_GET_VARIATION_GLYPHS=no
12224 fi
12225
12226 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12227
12228 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12229
12230 fi
12231 fi
12232 fi
12233 fi
12234
12235 HAVE_M17N_FLT=no
12236 if test "${HAVE_LIBOTF}" = yes; then
12237 if test "${with_m17n_flt}" != "no"; then
12238
12239 succeeded=no
12240
12241 if test "$PKG_CONFIG" = "no" ; then
12242 HAVE_M17N_FLT=no
12243 else
12244 PKG_CONFIG_MIN_VERSION=0.9.0
12245 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12247 $as_echo_n "checking for m17n-flt... " >&6; }
12248
12249 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12250 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12251 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12252 edit_cflags="
12253 s,///*,/,g
12254 s/^/ /
12255 s/ -I/ $isystem/g
12256 s/^ //
12257 "
12258 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12259 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12261 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12262 succeeded=yes
12263 else
12264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12265 $as_echo "no" >&6; }
12266 M17N_FLT_CFLAGS=""
12267 M17N_FLT_LIBS=""
12268 ## If we have a custom action on failure, don't print errors, but
12269 ## do set a variable so people can do so. Do it in a subshell
12270 ## to capture any diagnostics in invoking pkg-config.
12271 M17N_FLT_PKG_ERRORS=`($PKG_CONFIG --print-errors "m17n-flt") 2>&1`
12272
12273 fi
12274
12275
12276
12277 else
12278 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12279 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12280 fi
12281 fi
12282
12283 if test $succeeded = yes; then
12284 HAVE_M17N_FLT=yes
12285 else
12286 HAVE_M17N_FLT=no
12287 fi
12288
12289 if test "$HAVE_M17N_FLT" = "yes"; then
12290
12291 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12292
12293 fi
12294 fi
12295 fi
12296 else
12297 HAVE_XFT=no
12298 HAVE_FREETYPE=no
12299 HAVE_LIBOTF=no
12300 HAVE_M17N_FLT=no
12301 fi
12302
12303 ### End of font-backend (under X11) section.
12304
12305
12306
12307
12308
12309
12310
12311
12312
12313
12314 ### Use -lXpm if available, unless `--with-xpm=no'.
12315 HAVE_XPM=no
12316 LIBXPM=
12317
12318 if test "${HAVE_W32}" = "yes"; then
12319 if test "${with_xpm}" != "no"; then
12320 SAVE_CPPFLAGS="$CPPFLAGS"
12321 SAVE_LDFLAGS="$LDFLAGS"
12322 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
12323 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
12324 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12325 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
12327 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
12328 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
12329 $as_echo_n "(cached) " >&6
12330 else
12331 ac_check_lib_save_LIBS=$LIBS
12332 LIBS="-lXpm $LIBS"
12333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12334 /* end confdefs.h. */
12335
12336 /* Override any GCC internal prototype to avoid an error.
12337 Use char because int might match the return type of a GCC
12338 builtin and then its argument prototype would still apply. */
12339 #ifdef __cplusplus
12340 extern "C"
12341 #endif
12342 char XpmReadFileToImage ();
12343 int
12344 main ()
12345 {
12346 return XpmReadFileToImage ();
12347 ;
12348 return 0;
12349 }
12350 _ACEOF
12351 if ac_fn_c_try_link "$LINENO"; then :
12352 ac_cv_lib_Xpm_XpmReadFileToImage=yes
12353 else
12354 ac_cv_lib_Xpm_XpmReadFileToImage=no
12355 fi
12356 rm -f core conftest.err conftest.$ac_objext \
12357 conftest$ac_exeext conftest.$ac_ext
12358 LIBS=$ac_check_lib_save_LIBS
12359 fi
12360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
12361 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
12362 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
12363 HAVE_XPM=yes
12364 fi
12365
12366 fi
12367
12368
12369 if test "${HAVE_XPM}" = "yes"; then
12370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12371 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12373 /* end confdefs.h. */
12374 #include "X11/xpm.h"
12375 #ifndef XpmReturnAllocPixels
12376 no_return_alloc_pixels
12377 #endif
12378
12379 _ACEOF
12380 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12381 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12382 HAVE_XPM=no
12383 else
12384 HAVE_XPM=yes
12385 fi
12386 rm -f conftest*
12387
12388
12389 if test "${HAVE_XPM}" = "yes"; then
12390 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
12391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12392 $as_echo "yes" >&6; }
12393 else
12394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12395 $as_echo "no" >&6; }
12396 CPPFLAGS="$SAVE_CPPFLAGS"
12397 LDFLAGS="$SAVE_LDFLAGS"
12398 fi
12399 fi
12400 fi
12401
12402 if test "${HAVE_XPM}" = "yes"; then
12403
12404 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12405
12406 LIBXPM=-lXpm
12407 fi
12408 fi
12409
12410 if test "${HAVE_X11}" = "yes"; then
12411 if test "${with_xpm}" != "no"; then
12412 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12413 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12415 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12416 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12417 $as_echo_n "(cached) " >&6
12418 else
12419 ac_check_lib_save_LIBS=$LIBS
12420 LIBS="-lXpm -lX11 $LIBS"
12421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12422 /* end confdefs.h. */
12423
12424 /* Override any GCC internal prototype to avoid an error.
12425 Use char because int might match the return type of a GCC
12426 builtin and then its argument prototype would still apply. */
12427 #ifdef __cplusplus
12428 extern "C"
12429 #endif
12430 char XpmReadFileToPixmap ();
12431 int
12432 main ()
12433 {
12434 return XpmReadFileToPixmap ();
12435 ;
12436 return 0;
12437 }
12438 _ACEOF
12439 if ac_fn_c_try_link "$LINENO"; then :
12440 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12441 else
12442 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12443 fi
12444 rm -f core conftest.err conftest.$ac_objext \
12445 conftest$ac_exeext conftest.$ac_ext
12446 LIBS=$ac_check_lib_save_LIBS
12447 fi
12448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12449 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12450 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12451 HAVE_XPM=yes
12452 fi
12453
12454 fi
12455
12456
12457 if test "${HAVE_XPM}" = "yes"; then
12458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12459 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12461 /* end confdefs.h. */
12462 #include "X11/xpm.h"
12463 #ifndef XpmReturnAllocPixels
12464 no_return_alloc_pixels
12465 #endif
12466
12467 _ACEOF
12468 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12469 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12470 HAVE_XPM=no
12471 else
12472 HAVE_XPM=yes
12473 fi
12474 rm -f conftest*
12475
12476
12477 if test "${HAVE_XPM}" = "yes"; then
12478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12479 $as_echo "yes" >&6; }
12480 else
12481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12482 $as_echo "no" >&6; }
12483 fi
12484 fi
12485 fi
12486
12487 if test "${HAVE_XPM}" = "yes"; then
12488
12489 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12490
12491 LIBXPM=-lXpm
12492 fi
12493 fi
12494
12495
12496
12497 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12498 HAVE_JPEG=no
12499 LIBJPEG=
12500 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12501 if test "${with_jpeg}" != "no"; then
12502 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12503 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12505 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12506 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12507 $as_echo_n "(cached) " >&6
12508 else
12509 ac_check_lib_save_LIBS=$LIBS
12510 LIBS="-ljpeg $LIBS"
12511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12512 /* end confdefs.h. */
12513
12514 /* Override any GCC internal prototype to avoid an error.
12515 Use char because int might match the return type of a GCC
12516 builtin and then its argument prototype would still apply. */
12517 #ifdef __cplusplus
12518 extern "C"
12519 #endif
12520 char jpeg_destroy_compress ();
12521 int
12522 main ()
12523 {
12524 return jpeg_destroy_compress ();
12525 ;
12526 return 0;
12527 }
12528 _ACEOF
12529 if ac_fn_c_try_link "$LINENO"; then :
12530 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12531 else
12532 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12533 fi
12534 rm -f core conftest.err conftest.$ac_objext \
12535 conftest$ac_exeext conftest.$ac_ext
12536 LIBS=$ac_check_lib_save_LIBS
12537 fi
12538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12539 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12540 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12541 HAVE_JPEG=yes
12542 fi
12543
12544 fi
12545
12546
12547 fi
12548
12549 if test "${HAVE_JPEG}" = "yes"; then
12550 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12551
12552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12553 /* end confdefs.h. */
12554 #include <jpeglib.h>
12555 version=JPEG_LIB_VERSION
12556
12557 _ACEOF
12558 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12559 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12560 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12561
12562 else
12563 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12564 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12565 HAVE_JPEG=no
12566 fi
12567 rm -f conftest*
12568
12569 fi
12570 if test "${HAVE_JPEG}" = "yes"; then
12571 LIBJPEG=-ljpeg
12572 fi
12573 fi
12574
12575
12576 ### Use -lpng if available, unless `--with-png=no'.
12577 HAVE_PNG=no
12578 LIBPNG=
12579 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12580 if test "${with_png}" != "no"; then
12581 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12582 # in /usr/include/libpng.
12583 for ac_header in png.h libpng/png.h
12584 do :
12585 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12586 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12587 eval as_val=\$$as_ac_Header
12588 if test "x$as_val" = x""yes; then :
12589 cat >>confdefs.h <<_ACEOF
12590 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12591 _ACEOF
12592 break
12593 fi
12594
12595 done
12596
12597 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12599 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12600 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12601 $as_echo_n "(cached) " >&6
12602 else
12603 ac_check_lib_save_LIBS=$LIBS
12604 LIBS="-lpng -lz -lm $LIBS"
12605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12606 /* end confdefs.h. */
12607
12608 /* Override any GCC internal prototype to avoid an error.
12609 Use char because int might match the return type of a GCC
12610 builtin and then its argument prototype would still apply. */
12611 #ifdef __cplusplus
12612 extern "C"
12613 #endif
12614 char png_get_channels ();
12615 int
12616 main ()
12617 {
12618 return png_get_channels ();
12619 ;
12620 return 0;
12621 }
12622 _ACEOF
12623 if ac_fn_c_try_link "$LINENO"; then :
12624 ac_cv_lib_png_png_get_channels=yes
12625 else
12626 ac_cv_lib_png_png_get_channels=no
12627 fi
12628 rm -f core conftest.err conftest.$ac_objext \
12629 conftest$ac_exeext conftest.$ac_ext
12630 LIBS=$ac_check_lib_save_LIBS
12631 fi
12632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12633 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12634 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12635 HAVE_PNG=yes
12636 fi
12637
12638 fi
12639 fi
12640
12641 if test "${HAVE_PNG}" = "yes"; then
12642
12643 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12644
12645 LIBPNG="-lpng -lz -lm"
12646
12647 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12648 # include <libpng/png.h>
12649 #else
12650 # include <png.h>
12651 #endif
12652
12653 "
12654 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12655
12656 else
12657
12658 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12659
12660 fi
12661
12662 fi
12663 fi
12664
12665
12666 ### Use -ltiff if available, unless `--with-tiff=no'.
12667 HAVE_TIFF=no
12668 LIBTIFF=
12669 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12670 if test "${with_tiff}" != "no"; then
12671 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12672 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12673 tifflibs="-lz -lm"
12674 # At least one tiff package requires the jpeg library.
12675 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12677 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12678 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12679 $as_echo_n "(cached) " >&6
12680 else
12681 ac_check_lib_save_LIBS=$LIBS
12682 LIBS="-ltiff $tifflibs $LIBS"
12683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12684 /* end confdefs.h. */
12685
12686 /* Override any GCC internal prototype to avoid an error.
12687 Use char because int might match the return type of a GCC
12688 builtin and then its argument prototype would still apply. */
12689 #ifdef __cplusplus
12690 extern "C"
12691 #endif
12692 char TIFFGetVersion ();
12693 int
12694 main ()
12695 {
12696 return TIFFGetVersion ();
12697 ;
12698 return 0;
12699 }
12700 _ACEOF
12701 if ac_fn_c_try_link "$LINENO"; then :
12702 ac_cv_lib_tiff_TIFFGetVersion=yes
12703 else
12704 ac_cv_lib_tiff_TIFFGetVersion=no
12705 fi
12706 rm -f core conftest.err conftest.$ac_objext \
12707 conftest$ac_exeext conftest.$ac_ext
12708 LIBS=$ac_check_lib_save_LIBS
12709 fi
12710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12711 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12712 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12713 HAVE_TIFF=yes
12714 fi
12715
12716 fi
12717
12718
12719 fi
12720
12721 if test "${HAVE_TIFF}" = "yes"; then
12722
12723 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12724
12725 LIBTIFF=-ltiff
12726 fi
12727 fi
12728
12729
12730 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12731 HAVE_GIF=no
12732 LIBGIF=
12733 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
12734 || test "${HAVE_W32}" = "yes"; then
12735 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12736 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12737 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12738 # Earlier versions can crash Emacs.
12739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12740 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12741 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12742 $as_echo_n "(cached) " >&6
12743 else
12744 ac_check_lib_save_LIBS=$LIBS
12745 LIBS="-lgif $LIBS"
12746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12747 /* end confdefs.h. */
12748
12749 /* Override any GCC internal prototype to avoid an error.
12750 Use char because int might match the return type of a GCC
12751 builtin and then its argument prototype would still apply. */
12752 #ifdef __cplusplus
12753 extern "C"
12754 #endif
12755 char EGifPutExtensionLast ();
12756 int
12757 main ()
12758 {
12759 return EGifPutExtensionLast ();
12760 ;
12761 return 0;
12762 }
12763 _ACEOF
12764 if ac_fn_c_try_link "$LINENO"; then :
12765 ac_cv_lib_gif_EGifPutExtensionLast=yes
12766 else
12767 ac_cv_lib_gif_EGifPutExtensionLast=no
12768 fi
12769 rm -f core conftest.err conftest.$ac_objext \
12770 conftest$ac_exeext conftest.$ac_ext
12771 LIBS=$ac_check_lib_save_LIBS
12772 fi
12773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12774 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12775 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12776 HAVE_GIF=yes
12777 else
12778 HAVE_GIF=maybe
12779 fi
12780
12781 fi
12782
12783
12784
12785 if test "$HAVE_GIF" = yes; then
12786 LIBGIF=-lgif
12787 elif test "$HAVE_GIF" = maybe; then
12788 # If gif_lib.h but no libgif, try libungif.
12789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12790 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12791 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12792 $as_echo_n "(cached) " >&6
12793 else
12794 ac_check_lib_save_LIBS=$LIBS
12795 LIBS="-lungif $LIBS"
12796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12797 /* end confdefs.h. */
12798
12799 /* Override any GCC internal prototype to avoid an error.
12800 Use char because int might match the return type of a GCC
12801 builtin and then its argument prototype would still apply. */
12802 #ifdef __cplusplus
12803 extern "C"
12804 #endif
12805 char EGifPutExtensionLast ();
12806 int
12807 main ()
12808 {
12809 return EGifPutExtensionLast ();
12810 ;
12811 return 0;
12812 }
12813 _ACEOF
12814 if ac_fn_c_try_link "$LINENO"; then :
12815 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12816 else
12817 ac_cv_lib_ungif_EGifPutExtensionLast=no
12818 fi
12819 rm -f core conftest.err conftest.$ac_objext \
12820 conftest$ac_exeext conftest.$ac_ext
12821 LIBS=$ac_check_lib_save_LIBS
12822 fi
12823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12824 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12825 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12826 HAVE_GIF=yes
12827 else
12828 HAVE_GIF=no
12829 fi
12830
12831 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12832 fi
12833
12834 if test "${HAVE_GIF}" = "yes"; then
12835
12836 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12837
12838 fi
12839 fi
12840
12841
12842 if test "${HAVE_X11}" = "yes"; then
12843 MISSING=""
12844 WITH_NO=""
12845 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12846 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12847 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12848 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12849 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12850 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12851 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12852 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12853 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12854 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12855
12856 if test "X${MISSING}" != X; then
12857 as_fn_error "The following required libraries were not found:
12858 $MISSING
12859 Maybe some development libraries/packages are missing?
12860 If you don't want to link with them give
12861 $WITH_NO
12862 as options to configure" "$LINENO" 5
12863 fi
12864 fi
12865
12866 ### Use -lgpm if available, unless `--with-gpm=no'.
12867 HAVE_GPM=no
12868 LIBGPM=
12869 if test "${with_gpm}" != "no"; then
12870 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12871 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12873 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12874 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12875 $as_echo_n "(cached) " >&6
12876 else
12877 ac_check_lib_save_LIBS=$LIBS
12878 LIBS="-lgpm $LIBS"
12879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12880 /* end confdefs.h. */
12881
12882 /* Override any GCC internal prototype to avoid an error.
12883 Use char because int might match the return type of a GCC
12884 builtin and then its argument prototype would still apply. */
12885 #ifdef __cplusplus
12886 extern "C"
12887 #endif
12888 char Gpm_Open ();
12889 int
12890 main ()
12891 {
12892 return Gpm_Open ();
12893 ;
12894 return 0;
12895 }
12896 _ACEOF
12897 if ac_fn_c_try_link "$LINENO"; then :
12898 ac_cv_lib_gpm_Gpm_Open=yes
12899 else
12900 ac_cv_lib_gpm_Gpm_Open=no
12901 fi
12902 rm -f core conftest.err conftest.$ac_objext \
12903 conftest$ac_exeext conftest.$ac_ext
12904 LIBS=$ac_check_lib_save_LIBS
12905 fi
12906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12907 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12908 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12909 HAVE_GPM=yes
12910 fi
12911
12912 fi
12913
12914
12915
12916 if test "${HAVE_GPM}" = "yes"; then
12917
12918 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12919
12920 LIBGPM=-lgpm
12921 fi
12922 fi
12923
12924
12925
12926
12927
12928
12929 GNUSTEP_CFLAGS=
12930 ### Use NeXTstep API to implement GUI.
12931 if test "${HAVE_NS}" = "yes"; then
12932
12933 $as_echo "#define HAVE_NS 1" >>confdefs.h
12934
12935 if test "${NS_IMPL_COCOA}" = "yes"; then
12936
12937 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12938
12939 fi
12940 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12941
12942 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12943
12944 # See also .m.o rule in Makefile.in */
12945 # FIXME: are all these flags really needed? Document here why. */
12946 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12947 ## Extra CFLAGS applied to src/*.m files.
12948 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"
12949 fi
12950 # We also have mouse menus.
12951 HAVE_MENUS=yes
12952 OTHER_FILES=ns-app
12953 fi
12954
12955 if test "${HAVE_W32}" = "yes"; then
12956 HAVE_MENUS=yes
12957 fi
12958
12959 ### Use session management (-lSM -lICE) if available
12960 HAVE_X_SM=no
12961 LIBXSM=
12962 if test "${HAVE_X11}" = "yes"; then
12963 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12964 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12966 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12967 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12968 $as_echo_n "(cached) " >&6
12969 else
12970 ac_check_lib_save_LIBS=$LIBS
12971 LIBS="-lSM -lICE $LIBS"
12972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12973 /* end confdefs.h. */
12974
12975 /* Override any GCC internal prototype to avoid an error.
12976 Use char because int might match the return type of a GCC
12977 builtin and then its argument prototype would still apply. */
12978 #ifdef __cplusplus
12979 extern "C"
12980 #endif
12981 char SmcOpenConnection ();
12982 int
12983 main ()
12984 {
12985 return SmcOpenConnection ();
12986 ;
12987 return 0;
12988 }
12989 _ACEOF
12990 if ac_fn_c_try_link "$LINENO"; then :
12991 ac_cv_lib_SM_SmcOpenConnection=yes
12992 else
12993 ac_cv_lib_SM_SmcOpenConnection=no
12994 fi
12995 rm -f core conftest.err conftest.$ac_objext \
12996 conftest$ac_exeext conftest.$ac_ext
12997 LIBS=$ac_check_lib_save_LIBS
12998 fi
12999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13000 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13001 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13002 HAVE_X_SM=yes
13003 fi
13004
13005 fi
13006
13007
13008
13009 if test "${HAVE_X_SM}" = "yes"; then
13010
13011 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13012
13013 LIBXSM="-lSM -lICE"
13014 case "$LIBS" in
13015 *-lSM*) ;;
13016 *) LIBS="$LIBXSM $LIBS" ;;
13017 esac
13018 fi
13019 fi
13020
13021
13022 ### Use libxml (-lxml2) if available
13023 HAVE_LIBXML2=no
13024 if test "${with_xml2}" != "no"; then
13025 ### I'm not sure what the version number should be, so I just guessed.
13026
13027 succeeded=no
13028
13029 if test "$PKG_CONFIG" = "no" ; then
13030 HAVE_LIBXML2=no
13031 else
13032 PKG_CONFIG_MIN_VERSION=0.9.0
13033 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13035 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13036
13037 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
13038 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
13039 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
13040 edit_cflags="
13041 s,///*,/,g
13042 s/^/ /
13043 s/ -I/ $isystem/g
13044 s/^ //
13045 "
13046 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
13047 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
13048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
13049 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
13050 succeeded=yes
13051 else
13052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13053 $as_echo "no" >&6; }
13054 LIBXML2_CFLAGS=""
13055 LIBXML2_LIBS=""
13056 ## If we have a custom action on failure, don't print errors, but
13057 ## do set a variable so people can do so. Do it in a subshell
13058 ## to capture any diagnostics in invoking pkg-config.
13059 LIBXML2_PKG_ERRORS=`($PKG_CONFIG --print-errors "libxml-2.0 > 2.6.17") 2>&1`
13060
13061 fi
13062
13063
13064
13065 else
13066 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13067 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13068 fi
13069 fi
13070
13071 if test $succeeded = yes; then
13072 HAVE_LIBXML2=yes
13073 else
13074 HAVE_LIBXML2=no
13075 fi
13076
13077 if test "${HAVE_LIBXML2}" = "yes"; then
13078 LIBS="$LIBXML2_LIBS $LIBS"
13079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13080 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13081 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13082 $as_echo_n "(cached) " >&6
13083 else
13084 ac_check_lib_save_LIBS=$LIBS
13085 LIBS="-lxml2 $LIBS"
13086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13087 /* end confdefs.h. */
13088
13089 /* Override any GCC internal prototype to avoid an error.
13090 Use char because int might match the return type of a GCC
13091 builtin and then its argument prototype would still apply. */
13092 #ifdef __cplusplus
13093 extern "C"
13094 #endif
13095 char htmlReadMemory ();
13096 int
13097 main ()
13098 {
13099 return htmlReadMemory ();
13100 ;
13101 return 0;
13102 }
13103 _ACEOF
13104 if ac_fn_c_try_link "$LINENO"; then :
13105 ac_cv_lib_xml2_htmlReadMemory=yes
13106 else
13107 ac_cv_lib_xml2_htmlReadMemory=no
13108 fi
13109 rm -f core conftest.err conftest.$ac_objext \
13110 conftest$ac_exeext conftest.$ac_ext
13111 LIBS=$ac_check_lib_save_LIBS
13112 fi
13113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13114 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13115 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13116 HAVE_LIBXML2=yes
13117 else
13118 HAVE_LIBXML2=no
13119 fi
13120
13121 if test "${HAVE_LIBXML2}" = "yes"; then
13122
13123 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13124
13125 else
13126 LIBXML2_LIBS=""
13127 LIBXML2_CFLAGS=""
13128 fi
13129 fi
13130 fi
13131
13132
13133
13134 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13136 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13137 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13138 $as_echo_n "(cached) " >&6
13139 else
13140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13141 /* end confdefs.h. */
13142 #include <netdb.h>
13143 int
13144 main ()
13145 {
13146 return h_errno;
13147 ;
13148 return 0;
13149 }
13150 _ACEOF
13151 if ac_fn_c_try_link "$LINENO"; then :
13152 emacs_cv_netdb_declares_h_errno=yes
13153 else
13154 emacs_cv_netdb_declares_h_errno=no
13155 fi
13156 rm -f core conftest.err conftest.$ac_objext \
13157 conftest$ac_exeext conftest.$ac_ext
13158 fi
13159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13160 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13161 if test $emacs_cv_netdb_declares_h_errno = yes; then
13162
13163 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13164
13165 fi
13166
13167 # sqrt and other floating-point functions such as fmod and frexp
13168 # are found in -lm on most systems.
13169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13170 $as_echo_n "checking for sqrt in -lm... " >&6; }
13171 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13172 $as_echo_n "(cached) " >&6
13173 else
13174 ac_check_lib_save_LIBS=$LIBS
13175 LIBS="-lm $LIBS"
13176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13177 /* end confdefs.h. */
13178
13179 /* Override any GCC internal prototype to avoid an error.
13180 Use char because int might match the return type of a GCC
13181 builtin and then its argument prototype would still apply. */
13182 #ifdef __cplusplus
13183 extern "C"
13184 #endif
13185 char sqrt ();
13186 int
13187 main ()
13188 {
13189 return sqrt ();
13190 ;
13191 return 0;
13192 }
13193 _ACEOF
13194 if ac_fn_c_try_link "$LINENO"; then :
13195 ac_cv_lib_m_sqrt=yes
13196 else
13197 ac_cv_lib_m_sqrt=no
13198 fi
13199 rm -f core conftest.err conftest.$ac_objext \
13200 conftest$ac_exeext conftest.$ac_ext
13201 LIBS=$ac_check_lib_save_LIBS
13202 fi
13203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13204 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13205 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13206 cat >>confdefs.h <<_ACEOF
13207 #define HAVE_LIBM 1
13208 _ACEOF
13209
13210 LIBS="-lm $LIBS"
13211
13212 fi
13213
13214
13215 # Check for mail-locking functions in a "mail" library. Probably this should
13216 # have the same check as for liblockfile below.
13217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13218 $as_echo_n "checking for maillock in -lmail... " >&6; }
13219 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13220 $as_echo_n "(cached) " >&6
13221 else
13222 ac_check_lib_save_LIBS=$LIBS
13223 LIBS="-lmail $LIBS"
13224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13225 /* end confdefs.h. */
13226
13227 /* Override any GCC internal prototype to avoid an error.
13228 Use char because int might match the return type of a GCC
13229 builtin and then its argument prototype would still apply. */
13230 #ifdef __cplusplus
13231 extern "C"
13232 #endif
13233 char maillock ();
13234 int
13235 main ()
13236 {
13237 return maillock ();
13238 ;
13239 return 0;
13240 }
13241 _ACEOF
13242 if ac_fn_c_try_link "$LINENO"; then :
13243 ac_cv_lib_mail_maillock=yes
13244 else
13245 ac_cv_lib_mail_maillock=no
13246 fi
13247 rm -f core conftest.err conftest.$ac_objext \
13248 conftest$ac_exeext conftest.$ac_ext
13249 LIBS=$ac_check_lib_save_LIBS
13250 fi
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13252 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13253 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13254 have_mail=yes
13255 else
13256 have_mail=no
13257 fi
13258
13259 if test $have_mail = yes; then
13260 LIBS_MAIL=-lmail
13261 LIBS="$LIBS_MAIL $LIBS"
13262
13263 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13264
13265 else
13266 LIBS_MAIL=
13267 fi
13268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13269 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13270 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13271 $as_echo_n "(cached) " >&6
13272 else
13273 ac_check_lib_save_LIBS=$LIBS
13274 LIBS="-llockfile $LIBS"
13275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13276 /* end confdefs.h. */
13277
13278 /* Override any GCC internal prototype to avoid an error.
13279 Use char because int might match the return type of a GCC
13280 builtin and then its argument prototype would still apply. */
13281 #ifdef __cplusplus
13282 extern "C"
13283 #endif
13284 char maillock ();
13285 int
13286 main ()
13287 {
13288 return maillock ();
13289 ;
13290 return 0;
13291 }
13292 _ACEOF
13293 if ac_fn_c_try_link "$LINENO"; then :
13294 ac_cv_lib_lockfile_maillock=yes
13295 else
13296 ac_cv_lib_lockfile_maillock=no
13297 fi
13298 rm -f core conftest.err conftest.$ac_objext \
13299 conftest$ac_exeext conftest.$ac_ext
13300 LIBS=$ac_check_lib_save_LIBS
13301 fi
13302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13303 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13304 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13305 have_lockfile=yes
13306 else
13307 have_lockfile=no
13308 fi
13309
13310 if test $have_lockfile = yes; then
13311 LIBS_MAIL=-llockfile
13312 LIBS="$LIBS_MAIL $LIBS"
13313
13314 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13315
13316 else
13317 # If we have the shared liblockfile, assume we must use it for mail
13318 # locking (e.g. Debian). If we couldn't link against liblockfile
13319 # (no liblockfile.a installed), ensure that we don't need to.
13320 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13321 set dummy liblockfile.so; ac_word=$2
13322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13323 $as_echo_n "checking for $ac_word... " >&6; }
13324 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13325 $as_echo_n "(cached) " >&6
13326 else
13327 if test -n "$liblockfile"; then
13328 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13329 else
13330 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13331 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13332 for as_dir in $as_dummy
13333 do
13334 IFS=$as_save_IFS
13335 test -z "$as_dir" && as_dir=.
13336 for ac_exec_ext in '' $ac_executable_extensions; do
13337 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13338 ac_cv_prog_liblockfile="yes"
13339 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13340 break 2
13341 fi
13342 done
13343 done
13344 IFS=$as_save_IFS
13345
13346 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13347 fi
13348 fi
13349 liblockfile=$ac_cv_prog_liblockfile
13350 if test -n "$liblockfile"; then
13351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13352 $as_echo "$liblockfile" >&6; }
13353 else
13354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13355 $as_echo "no" >&6; }
13356 fi
13357
13358
13359 if test $ac_cv_prog_liblockfile = yes; then
13360 as_fn_error "Shared liblockfile found but can't link against it.
13361 This probably means that movemail could lose mail.
13362 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13363 fi
13364 fi
13365
13366
13367
13368
13369
13370 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13371 ## interlock access to the mail spool. The alternative is a lock file named
13372 ## /usr/spool/mail/$USER.lock.
13373 mail_lock=no
13374 case "$opsys" in
13375 aix4-2) mail_lock="lockf" ;;
13376
13377 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13378
13379 ## On GNU/Linux systems, both methods are used by various mail programs.
13380 ## I assume most people are using newer mailers that have heard of flock.
13381 ## Change this if you need to.
13382 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13383 ## configure gets the right answers, and that means *NOT* using flock.
13384 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13385 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13386 ## Debian maintainer hasn't provided a clean fix for Emacs.
13387 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13388 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13389 ## correct logic. -- fx
13390 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13391 ## liblockfile is a Free Software replacement for libmail, used on
13392 ## Debian systems and elsewhere. -rfr.
13393 gnu-*)
13394 mail_lock="flock"
13395 if test $have_mail = yes || test $have_lockfile = yes; then
13396 test $ac_cv_header_maillock_h = yes && mail_lock=no
13397 fi
13398 ;;
13399 esac
13400
13401 BLESSMAIL_TARGET=
13402 case "$mail_lock" in
13403 flock)
13404 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13405 ;;
13406
13407 lockf)
13408 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13409 ;;
13410
13411 *) BLESSMAIL_TARGET="need-blessmail" ;;
13412 esac
13413
13414
13415
13416 for ac_func in gethostname \
13417 closedir getrusage get_current_dir_name \
13418 lrand48 setsid \
13419 fpathconf select euidaccess getpagesize setlocale \
13420 utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
13421 __fpending strsignal setitimer \
13422 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13423 gai_strerror mkstemp getline getdelim fsync sync \
13424 difftime posix_memalign \
13425 getpwent endpwent getgrent endgrent \
13426 touchlock \
13427 cfmakeraw cfsetspeed copysign __executable_start
13428 do :
13429 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13430 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13431 eval as_val=\$$as_ac_var
13432 if test "x$as_val" = x""yes; then :
13433 cat >>confdefs.h <<_ACEOF
13434 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13435 _ACEOF
13436
13437 fi
13438 done
13439
13440
13441 if test $opsys = unixware; then
13442
13443 $as_echo "#define BROKEN_GETWD 1" >>confdefs.h
13444
13445 else
13446 for ac_func in getwd
13447 do :
13448 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13449 if test "x$ac_cv_func_getwd" = x""yes; then :
13450 cat >>confdefs.h <<_ACEOF
13451 #define HAVE_GETWD 1
13452 _ACEOF
13453
13454 fi
13455 done
13456
13457 fi
13458
13459 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13460 ## has a broken `rint' in some library versions including math library
13461 ## version number A.09.05.
13462 ## You can fix the math library by installing patch number PHSS_4630.
13463 ## But we can fix it more reliably for Emacs by just not using rint.
13464 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13465 case $opsys in
13466 hpux*) : ;;
13467 *) for ac_func in random rint
13468 do :
13469 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13470 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13471 eval as_val=\$$as_ac_var
13472 if test "x$as_val" = x""yes; then :
13473 cat >>confdefs.h <<_ACEOF
13474 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13475 _ACEOF
13476
13477 fi
13478 done
13479 ;;
13480 esac
13481
13482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13483 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13484 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13485 $as_echo_n "(cached) " >&6
13486 else
13487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13488 /* end confdefs.h. */
13489
13490 int
13491 main ()
13492 {
13493 __builtin_unwind_init ();
13494 ;
13495 return 0;
13496 }
13497 _ACEOF
13498 if ac_fn_c_try_link "$LINENO"; then :
13499 emacs_cv_func___builtin_unwind_init=yes
13500 else
13501 emacs_cv_func___builtin_unwind_init=no
13502 fi
13503 rm -f core conftest.err conftest.$ac_objext \
13504 conftest$ac_exeext conftest.$ac_ext
13505 fi
13506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13507 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13508 if test $emacs_cv_func___builtin_unwind_init = yes; then
13509
13510 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13511
13512 fi
13513
13514
13515
13516
13517
13518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13519 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13520 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13521 $as_echo_n "(cached) " >&6
13522 else
13523 while :; do
13524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13525 /* end confdefs.h. */
13526 #include <sys/types.h> /* for off_t */
13527 #include <stdio.h>
13528 int
13529 main ()
13530 {
13531 int (*fp) (FILE *, off_t, int) = fseeko;
13532 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13533 ;
13534 return 0;
13535 }
13536 _ACEOF
13537 if ac_fn_c_try_link "$LINENO"; then :
13538 ac_cv_sys_largefile_source=no; break
13539 fi
13540 rm -f core conftest.err conftest.$ac_objext \
13541 conftest$ac_exeext conftest.$ac_ext
13542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13543 /* end confdefs.h. */
13544 #define _LARGEFILE_SOURCE 1
13545 #include <sys/types.h> /* for off_t */
13546 #include <stdio.h>
13547 int
13548 main ()
13549 {
13550 int (*fp) (FILE *, off_t, int) = fseeko;
13551 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13552 ;
13553 return 0;
13554 }
13555 _ACEOF
13556 if ac_fn_c_try_link "$LINENO"; then :
13557 ac_cv_sys_largefile_source=1; break
13558 fi
13559 rm -f core conftest.err conftest.$ac_objext \
13560 conftest$ac_exeext conftest.$ac_ext
13561 ac_cv_sys_largefile_source=unknown
13562 break
13563 done
13564 fi
13565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13566 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13567 case $ac_cv_sys_largefile_source in #(
13568 no | unknown) ;;
13569 *)
13570 cat >>confdefs.h <<_ACEOF
13571 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13572 _ACEOF
13573 ;;
13574 esac
13575 rm -rf conftest*
13576
13577 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13578 # in glibc 2.1.3, but that breaks too many other things.
13579 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13580 if test $ac_cv_sys_largefile_source != unknown; then
13581
13582 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13583
13584 fi
13585
13586
13587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13588 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13589 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13590 $as_echo_n "(cached) " >&6
13591 else
13592 # Use it with a single arg.
13593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13594 /* end confdefs.h. */
13595 $ac_includes_default
13596 int
13597 main ()
13598 {
13599 getpgrp (0);
13600 ;
13601 return 0;
13602 }
13603 _ACEOF
13604 if ac_fn_c_try_compile "$LINENO"; then :
13605 ac_cv_func_getpgrp_void=no
13606 else
13607 ac_cv_func_getpgrp_void=yes
13608 fi
13609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13610
13611 fi
13612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13613 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13614 if test $ac_cv_func_getpgrp_void = yes; then
13615
13616 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13617
13618 fi
13619
13620
13621 # UNIX98 PTYs.
13622 for ac_func in grantpt
13623 do :
13624 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13625 if test "x$ac_cv_func_grantpt" = x""yes; then :
13626 cat >>confdefs.h <<_ACEOF
13627 #define HAVE_GRANTPT 1
13628 _ACEOF
13629
13630 fi
13631 done
13632
13633
13634 # PTY-related GNU extensions.
13635 for ac_func in getpt posix_openpt
13636 do :
13637 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13638 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13639 eval as_val=\$$as_ac_var
13640 if test "x$as_val" = x""yes; then :
13641 cat >>confdefs.h <<_ACEOF
13642 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13643 _ACEOF
13644
13645 fi
13646 done
13647
13648
13649 # Check this now, so that we will NOT find the above functions in ncurses.
13650 # That is because we have not set up to link ncurses in lib-src.
13651 # It's better to believe a function is not available
13652 # than to expect to find it in ncurses.
13653 # Also we need tputs and friends to be able to build at all.
13654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13655 $as_echo_n "checking for library containing tputs... " >&6; }
13656 # Run a test program that contains a call to tputs, a call that is
13657 # never executed. This tests whether a pre-'main' dynamic linker
13658 # works with the library. It's too much trouble to actually call
13659 # tputs in the test program, due to portability hassles. When
13660 # cross-compiling, assume the test program will run if it links.
13661
13662 # Maybe curses should be tried earlier?
13663 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13664 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13665 OLIBS=$LIBS
13666 if test -z "$tputs_library"; then
13667 LIBS_TERMCAP=
13668 msg='none required'
13669 else
13670 LIBS_TERMCAP=-l$tputs_library
13671 msg=$LIBS_TERMCAP
13672 LIBS="$LIBS_TERMCAP $LIBS"
13673 fi
13674 if test "$cross_compiling" = yes; then :
13675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13676 /* end confdefs.h. */
13677
13678 extern void tputs (const char *, int, int (*)(int));
13679 int main (int argc, char **argv)
13680 {
13681 if (argc == 10000)
13682 tputs (argv[0], 0, 0);
13683 return 0;
13684 }
13685
13686 _ACEOF
13687 if ac_fn_c_try_link "$LINENO"; then :
13688
13689 else
13690 msg=no
13691 fi
13692 rm -f core conftest.err conftest.$ac_objext \
13693 conftest$ac_exeext conftest.$ac_ext
13694 else
13695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13696 /* end confdefs.h. */
13697
13698 extern void tputs (const char *, int, int (*)(int));
13699 int main (int argc, char **argv)
13700 {
13701 if (argc == 10000)
13702 tputs (argv[0], 0, 0);
13703 return 0;
13704 }
13705
13706 _ACEOF
13707 if ac_fn_c_try_run "$LINENO"; then :
13708
13709 else
13710 msg=no
13711 fi
13712 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13713 conftest.$ac_objext conftest.beam conftest.$ac_ext
13714 fi
13715
13716 LIBS=$OLIBS
13717 if test "X$msg" != Xno; then
13718 break
13719 fi
13720 done
13721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13722 $as_echo "$msg" >&6; }
13723 if test "X$msg" = Xno; then
13724 as_fn_error "The required function \`tputs' was not found in any library.
13725 The following libraries were tried (in order):
13726 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13727 Please try installing whichever of these libraries is most appropriate
13728 for your system, together with its header files.
13729 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13730 fi
13731
13732 ## Use termcap instead of terminfo?
13733 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13734 TERMINFO=yes
13735 ## FIXME? In the cases below where we unconditionally set
13736 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13737 ## if that was found above to have tputs.
13738 ## Should we use the gnu* logic everywhere?
13739 case "$opsys" in
13740 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13741 ## The ncurses library has been moved out of the System framework in
13742 ## Mac OS X 10.2. So if configure detects it, set the command-line
13743 ## option to use it.
13744 darwin) LIBS_TERMCAP="-lncurses" ;;
13745
13746 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13747
13748 freebsd)
13749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13750 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13751 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13752 $as_echo_n "(cached) " >&6
13753 else
13754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13755 /* end confdefs.h. */
13756 #include <osreldate.h>
13757 int
13758 main ()
13759 {
13760 #if __FreeBSD_version < 400000
13761 fail;
13762 #endif
13763
13764 ;
13765 return 0;
13766 }
13767 _ACEOF
13768 if ac_fn_c_try_link "$LINENO"; then :
13769 emacs_cv_freebsd_terminfo=yes
13770 else
13771 emacs_cv_freebsd_terminfo=no
13772 fi
13773 rm -f core conftest.err conftest.$ac_objext \
13774 conftest$ac_exeext conftest.$ac_ext
13775 fi
13776
13777
13778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13779 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13780
13781 if test $emacs_cv_freebsd_terminfo = yes; then
13782 LIBS_TERMCAP="-lncurses"
13783 else
13784 TERMINFO=no
13785 LIBS_TERMCAP="-ltermcap"
13786 fi
13787 ;;
13788
13789 netbsd)
13790 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13791 TERMINFO=no
13792 LIBS_TERMCAP="-ltermcap"
13793 fi
13794 ;;
13795
13796 openbsd) LIBS_TERMCAP="-lncurses" ;;
13797
13798 ## hpux: Make sure we get select from libc rather than from libcurses
13799 ## because libcurses on HPUX 10.10 has a broken version of select.
13800 ## We used to use -lc -lcurses, but this may be cleaner.
13801 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13802 # set that way, now it uses the default). Isn't this a contradiction?
13803 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13804
13805 esac
13806
13807 TERMCAP_OBJ=tparam.o
13808 if test $TERMINFO = yes; then
13809
13810 $as_echo "#define TERMINFO 1" >>confdefs.h
13811
13812 TERMCAP_OBJ=terminfo.o
13813 fi
13814
13815
13816
13817
13818 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13819 # On Darwin, res_init appears not to be useful: see bug#562 and
13820 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13821 resolv=no
13822
13823 if test $opsys != darwin; then
13824
13825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13826 /* end confdefs.h. */
13827 #include <netinet/in.h>
13828 #include <arpa/nameser.h>
13829 #include <resolv.h>
13830 int
13831 main ()
13832 {
13833 return res_init();
13834 ;
13835 return 0;
13836 }
13837 _ACEOF
13838 if ac_fn_c_try_link "$LINENO"; then :
13839 have_res_init=yes
13840 else
13841 have_res_init=no
13842 fi
13843 rm -f core conftest.err conftest.$ac_objext \
13844 conftest$ac_exeext conftest.$ac_ext
13845 if test "$have_res_init" = no; then
13846 OLIBS="$LIBS"
13847 LIBS="$LIBS -lresolv"
13848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13849 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13851 /* end confdefs.h. */
13852 #include <netinet/in.h>
13853 #include <arpa/nameser.h>
13854 #include <resolv.h>
13855 int
13856 main ()
13857 {
13858 return res_init();
13859 ;
13860 return 0;
13861 }
13862 _ACEOF
13863 if ac_fn_c_try_link "$LINENO"; then :
13864 have_res_init=yes
13865 else
13866 have_res_init=no
13867 fi
13868 rm -f core conftest.err conftest.$ac_objext \
13869 conftest$ac_exeext conftest.$ac_ext
13870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13871 $as_echo "$have_res_init" >&6; }
13872 if test "$have_res_init" = yes ; then
13873 resolv=yes
13874 fi
13875 LIBS="$OLIBS"
13876 fi
13877
13878 if test "$have_res_init" = yes; then
13879
13880 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13881
13882 fi
13883 fi
13884 # Do we need the Hesiod library to provide the support routines?
13885 LIBHESIOD=
13886 if test "$with_hesiod" != no ; then
13887 # Don't set $LIBS here -- see comments above. FIXME which comments?
13888 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13889 if test "x$ac_cv_func_res_send" = x""yes; then :
13890
13891 else
13892 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13893 if test "x$ac_cv_func___res_send" = x""yes; then :
13894
13895 else
13896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13897 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13898 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13899 $as_echo_n "(cached) " >&6
13900 else
13901 ac_check_lib_save_LIBS=$LIBS
13902 LIBS="-lresolv $LIBS"
13903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13904 /* end confdefs.h. */
13905
13906 /* Override any GCC internal prototype to avoid an error.
13907 Use char because int might match the return type of a GCC
13908 builtin and then its argument prototype would still apply. */
13909 #ifdef __cplusplus
13910 extern "C"
13911 #endif
13912 char res_send ();
13913 int
13914 main ()
13915 {
13916 return res_send ();
13917 ;
13918 return 0;
13919 }
13920 _ACEOF
13921 if ac_fn_c_try_link "$LINENO"; then :
13922 ac_cv_lib_resolv_res_send=yes
13923 else
13924 ac_cv_lib_resolv_res_send=no
13925 fi
13926 rm -f core conftest.err conftest.$ac_objext \
13927 conftest$ac_exeext conftest.$ac_ext
13928 LIBS=$ac_check_lib_save_LIBS
13929 fi
13930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13931 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13932 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13933 resolv=yes
13934 else
13935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13936 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13937 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13938 $as_echo_n "(cached) " >&6
13939 else
13940 ac_check_lib_save_LIBS=$LIBS
13941 LIBS="-lresolv $LIBS"
13942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13943 /* end confdefs.h. */
13944
13945 /* Override any GCC internal prototype to avoid an error.
13946 Use char because int might match the return type of a GCC
13947 builtin and then its argument prototype would still apply. */
13948 #ifdef __cplusplus
13949 extern "C"
13950 #endif
13951 char __res_send ();
13952 int
13953 main ()
13954 {
13955 return __res_send ();
13956 ;
13957 return 0;
13958 }
13959 _ACEOF
13960 if ac_fn_c_try_link "$LINENO"; then :
13961 ac_cv_lib_resolv___res_send=yes
13962 else
13963 ac_cv_lib_resolv___res_send=no
13964 fi
13965 rm -f core conftest.err conftest.$ac_objext \
13966 conftest$ac_exeext conftest.$ac_ext
13967 LIBS=$ac_check_lib_save_LIBS
13968 fi
13969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13970 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13971 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13972 resolv=yes
13973 fi
13974
13975 fi
13976
13977 fi
13978
13979 fi
13980
13981 if test "$resolv" = yes ; then
13982 RESOLVLIB=-lresolv
13983 else
13984 RESOLVLIB=
13985 fi
13986 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13987 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13988
13989 else
13990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13991 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13992 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13993 $as_echo_n "(cached) " >&6
13994 else
13995 ac_check_lib_save_LIBS=$LIBS
13996 LIBS="-lhesiod $RESOLVLIB $LIBS"
13997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13998 /* end confdefs.h. */
13999
14000 /* Override any GCC internal prototype to avoid an error.
14001 Use char because int might match the return type of a GCC
14002 builtin and then its argument prototype would still apply. */
14003 #ifdef __cplusplus
14004 extern "C"
14005 #endif
14006 char hes_getmailhost ();
14007 int
14008 main ()
14009 {
14010 return hes_getmailhost ();
14011 ;
14012 return 0;
14013 }
14014 _ACEOF
14015 if ac_fn_c_try_link "$LINENO"; then :
14016 ac_cv_lib_hesiod_hes_getmailhost=yes
14017 else
14018 ac_cv_lib_hesiod_hes_getmailhost=no
14019 fi
14020 rm -f core conftest.err conftest.$ac_objext \
14021 conftest$ac_exeext conftest.$ac_ext
14022 LIBS=$ac_check_lib_save_LIBS
14023 fi
14024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
14025 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
14026 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
14027 hesiod=yes
14028 else
14029 :
14030 fi
14031
14032 fi
14033
14034
14035 if test x"$hesiod" = xyes; then
14036
14037 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14038
14039 LIBHESIOD=-lhesiod
14040 fi
14041 fi
14042
14043
14044 # Do we need libresolv (due to res_init or Hesiod)?
14045 if test "$resolv" = yes && test $opsys != darwin; then
14046
14047 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14048
14049 LIBRESOLV=-lresolv
14050 else
14051 LIBRESOLV=
14052 fi
14053
14054
14055 # These tell us which Kerberos-related libraries to use.
14056 COM_ERRLIB=
14057 CRYPTOLIB=
14058 KRB5LIB=
14059 DESLIB=
14060 KRB4LIB=
14061
14062 if test "${with_kerberos}" != no; then
14063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14064 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
14065 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
14066 $as_echo_n "(cached) " >&6
14067 else
14068 ac_check_lib_save_LIBS=$LIBS
14069 LIBS="-lcom_err $LIBS"
14070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14071 /* end confdefs.h. */
14072
14073 /* Override any GCC internal prototype to avoid an error.
14074 Use char because int might match the return type of a GCC
14075 builtin and then its argument prototype would still apply. */
14076 #ifdef __cplusplus
14077 extern "C"
14078 #endif
14079 char com_err ();
14080 int
14081 main ()
14082 {
14083 return com_err ();
14084 ;
14085 return 0;
14086 }
14087 _ACEOF
14088 if ac_fn_c_try_link "$LINENO"; then :
14089 ac_cv_lib_com_err_com_err=yes
14090 else
14091 ac_cv_lib_com_err_com_err=no
14092 fi
14093 rm -f core conftest.err conftest.$ac_objext \
14094 conftest$ac_exeext conftest.$ac_ext
14095 LIBS=$ac_check_lib_save_LIBS
14096 fi
14097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14098 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
14099 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
14100 have_com_err=yes
14101 else
14102 have_com_err=no
14103 fi
14104
14105 if test $have_com_err = yes; then
14106 COM_ERRLIB=-lcom_err
14107 LIBS="$COM_ERRLIB $LIBS"
14108
14109 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
14110
14111 fi
14112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14113 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
14114 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
14115 $as_echo_n "(cached) " >&6
14116 else
14117 ac_check_lib_save_LIBS=$LIBS
14118 LIBS="-lcrypto $LIBS"
14119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14120 /* end confdefs.h. */
14121
14122 /* Override any GCC internal prototype to avoid an error.
14123 Use char because int might match the return type of a GCC
14124 builtin and then its argument prototype would still apply. */
14125 #ifdef __cplusplus
14126 extern "C"
14127 #endif
14128 char mit_des_cbc_encrypt ();
14129 int
14130 main ()
14131 {
14132 return mit_des_cbc_encrypt ();
14133 ;
14134 return 0;
14135 }
14136 _ACEOF
14137 if ac_fn_c_try_link "$LINENO"; then :
14138 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14139 else
14140 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14141 fi
14142 rm -f core conftest.err conftest.$ac_objext \
14143 conftest$ac_exeext conftest.$ac_ext
14144 LIBS=$ac_check_lib_save_LIBS
14145 fi
14146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14147 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
14148 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
14149 have_crypto=yes
14150 else
14151 have_crypto=no
14152 fi
14153
14154 if test $have_crypto = yes; then
14155 CRYPTOLIB=-lcrypto
14156 LIBS="$CRYPTOLIB $LIBS"
14157
14158 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
14159
14160 fi
14161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14162 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
14163 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
14164 $as_echo_n "(cached) " >&6
14165 else
14166 ac_check_lib_save_LIBS=$LIBS
14167 LIBS="-lk5crypto $LIBS"
14168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14169 /* end confdefs.h. */
14170
14171 /* Override any GCC internal prototype to avoid an error.
14172 Use char because int might match the return type of a GCC
14173 builtin and then its argument prototype would still apply. */
14174 #ifdef __cplusplus
14175 extern "C"
14176 #endif
14177 char mit_des_cbc_encrypt ();
14178 int
14179 main ()
14180 {
14181 return mit_des_cbc_encrypt ();
14182 ;
14183 return 0;
14184 }
14185 _ACEOF
14186 if ac_fn_c_try_link "$LINENO"; then :
14187 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14188 else
14189 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14190 fi
14191 rm -f core conftest.err conftest.$ac_objext \
14192 conftest$ac_exeext conftest.$ac_ext
14193 LIBS=$ac_check_lib_save_LIBS
14194 fi
14195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14196 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
14197 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
14198 have_k5crypto=yes
14199 else
14200 have_k5crypto=no
14201 fi
14202
14203 if test $have_k5crypto = yes; then
14204 CRYPTOLIB=-lk5crypto
14205 LIBS="$CRYPTOLIB $LIBS"
14206
14207 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14208
14209 fi
14210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14211 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14212 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14213 $as_echo_n "(cached) " >&6
14214 else
14215 ac_check_lib_save_LIBS=$LIBS
14216 LIBS="-lkrb5 $LIBS"
14217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14218 /* end confdefs.h. */
14219
14220 /* Override any GCC internal prototype to avoid an error.
14221 Use char because int might match the return type of a GCC
14222 builtin and then its argument prototype would still apply. */
14223 #ifdef __cplusplus
14224 extern "C"
14225 #endif
14226 char krb5_init_context ();
14227 int
14228 main ()
14229 {
14230 return krb5_init_context ();
14231 ;
14232 return 0;
14233 }
14234 _ACEOF
14235 if ac_fn_c_try_link "$LINENO"; then :
14236 ac_cv_lib_krb5_krb5_init_context=yes
14237 else
14238 ac_cv_lib_krb5_krb5_init_context=no
14239 fi
14240 rm -f core conftest.err conftest.$ac_objext \
14241 conftest$ac_exeext conftest.$ac_ext
14242 LIBS=$ac_check_lib_save_LIBS
14243 fi
14244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14245 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14246 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14247 have_krb5=yes
14248 else
14249 have_krb5=no
14250 fi
14251
14252 if test $have_krb5=yes; then
14253 KRB5LIB=-lkrb5
14254 LIBS="$KRB5LIB $LIBS"
14255
14256 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14257
14258 fi
14259 if test "${with_kerberos5}" = no; then
14260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14261 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14262 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14263 $as_echo_n "(cached) " >&6
14264 else
14265 ac_check_lib_save_LIBS=$LIBS
14266 LIBS="-ldes425 $LIBS"
14267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14268 /* end confdefs.h. */
14269
14270 /* Override any GCC internal prototype to avoid an error.
14271 Use char because int might match the return type of a GCC
14272 builtin and then its argument prototype would still apply. */
14273 #ifdef __cplusplus
14274 extern "C"
14275 #endif
14276 char des_cbc_encrypt ();
14277 int
14278 main ()
14279 {
14280 return des_cbc_encrypt ();
14281 ;
14282 return 0;
14283 }
14284 _ACEOF
14285 if ac_fn_c_try_link "$LINENO"; then :
14286 ac_cv_lib_des425_des_cbc_encrypt=yes
14287 else
14288 ac_cv_lib_des425_des_cbc_encrypt=no
14289 fi
14290 rm -f core conftest.err conftest.$ac_objext \
14291 conftest$ac_exeext conftest.$ac_ext
14292 LIBS=$ac_check_lib_save_LIBS
14293 fi
14294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14295 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14296 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14297 have_des425=yes
14298 else
14299 have_des425=no
14300 fi
14301
14302 if test $have_des425 = yes; then
14303 DESLIB=-ldes425
14304 LIBS="$DESLIB $LIBS"
14305
14306 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14307
14308 else
14309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14310 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14311 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14312 $as_echo_n "(cached) " >&6
14313 else
14314 ac_check_lib_save_LIBS=$LIBS
14315 LIBS="-ldes $LIBS"
14316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14317 /* end confdefs.h. */
14318
14319 /* Override any GCC internal prototype to avoid an error.
14320 Use char because int might match the return type of a GCC
14321 builtin and then its argument prototype would still apply. */
14322 #ifdef __cplusplus
14323 extern "C"
14324 #endif
14325 char des_cbc_encrypt ();
14326 int
14327 main ()
14328 {
14329 return des_cbc_encrypt ();
14330 ;
14331 return 0;
14332 }
14333 _ACEOF
14334 if ac_fn_c_try_link "$LINENO"; then :
14335 ac_cv_lib_des_des_cbc_encrypt=yes
14336 else
14337 ac_cv_lib_des_des_cbc_encrypt=no
14338 fi
14339 rm -f core conftest.err conftest.$ac_objext \
14340 conftest$ac_exeext conftest.$ac_ext
14341 LIBS=$ac_check_lib_save_LIBS
14342 fi
14343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14344 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14345 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14346 have_des=yes
14347 else
14348 have_des=no
14349 fi
14350
14351 if test $have_des = yes; then
14352 DESLIB=-ldes
14353 LIBS="$DESLIB $LIBS"
14354
14355 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14356
14357 fi
14358 fi
14359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14360 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14361 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14362 $as_echo_n "(cached) " >&6
14363 else
14364 ac_check_lib_save_LIBS=$LIBS
14365 LIBS="-lkrb4 $LIBS"
14366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14367 /* end confdefs.h. */
14368
14369 /* Override any GCC internal prototype to avoid an error.
14370 Use char because int might match the return type of a GCC
14371 builtin and then its argument prototype would still apply. */
14372 #ifdef __cplusplus
14373 extern "C"
14374 #endif
14375 char krb_get_cred ();
14376 int
14377 main ()
14378 {
14379 return krb_get_cred ();
14380 ;
14381 return 0;
14382 }
14383 _ACEOF
14384 if ac_fn_c_try_link "$LINENO"; then :
14385 ac_cv_lib_krb4_krb_get_cred=yes
14386 else
14387 ac_cv_lib_krb4_krb_get_cred=no
14388 fi
14389 rm -f core conftest.err conftest.$ac_objext \
14390 conftest$ac_exeext conftest.$ac_ext
14391 LIBS=$ac_check_lib_save_LIBS
14392 fi
14393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14394 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14395 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14396 have_krb4=yes
14397 else
14398 have_krb4=no
14399 fi
14400
14401 if test $have_krb4 = yes; then
14402 KRB4LIB=-lkrb4
14403 LIBS="$KRB4LIB $LIBS"
14404
14405 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14406
14407 else
14408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14409 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14410 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14411 $as_echo_n "(cached) " >&6
14412 else
14413 ac_check_lib_save_LIBS=$LIBS
14414 LIBS="-lkrb $LIBS"
14415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14416 /* end confdefs.h. */
14417
14418 /* Override any GCC internal prototype to avoid an error.
14419 Use char because int might match the return type of a GCC
14420 builtin and then its argument prototype would still apply. */
14421 #ifdef __cplusplus
14422 extern "C"
14423 #endif
14424 char krb_get_cred ();
14425 int
14426 main ()
14427 {
14428 return krb_get_cred ();
14429 ;
14430 return 0;
14431 }
14432 _ACEOF
14433 if ac_fn_c_try_link "$LINENO"; then :
14434 ac_cv_lib_krb_krb_get_cred=yes
14435 else
14436 ac_cv_lib_krb_krb_get_cred=no
14437 fi
14438 rm -f core conftest.err conftest.$ac_objext \
14439 conftest$ac_exeext conftest.$ac_ext
14440 LIBS=$ac_check_lib_save_LIBS
14441 fi
14442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14443 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14444 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14445 have_krb=yes
14446 else
14447 have_krb=no
14448 fi
14449
14450 if test $have_krb = yes; then
14451 KRB4LIB=-lkrb
14452 LIBS="$KRB4LIB $LIBS"
14453
14454 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14455
14456 fi
14457 fi
14458 fi
14459
14460 if test "${with_kerberos5}" != no; then
14461 for ac_header in krb5.h
14462 do :
14463 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14464 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14465 cat >>confdefs.h <<_ACEOF
14466 #define HAVE_KRB5_H 1
14467 _ACEOF
14468 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14469 "
14470 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14471
14472 cat >>confdefs.h <<_ACEOF
14473 #define HAVE_KRB5_ERROR_TEXT 1
14474 _ACEOF
14475
14476
14477 fi
14478 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14479 "
14480 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14481
14482 cat >>confdefs.h <<_ACEOF
14483 #define HAVE_KRB5_ERROR_E_TEXT 1
14484 _ACEOF
14485
14486
14487 fi
14488
14489 fi
14490
14491 done
14492
14493 else
14494 for ac_header in des.h
14495 do :
14496 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14497 if test "x$ac_cv_header_des_h" = x""yes; then :
14498 cat >>confdefs.h <<_ACEOF
14499 #define HAVE_DES_H 1
14500 _ACEOF
14501
14502 else
14503 for ac_header in kerberosIV/des.h
14504 do :
14505 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14506 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14507 cat >>confdefs.h <<_ACEOF
14508 #define HAVE_KERBEROSIV_DES_H 1
14509 _ACEOF
14510
14511 else
14512 for ac_header in kerberos/des.h
14513 do :
14514 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14515 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14516 cat >>confdefs.h <<_ACEOF
14517 #define HAVE_KERBEROS_DES_H 1
14518 _ACEOF
14519
14520 fi
14521
14522 done
14523
14524 fi
14525
14526 done
14527
14528 fi
14529
14530 done
14531
14532 for ac_header in krb.h
14533 do :
14534 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14535 if test "x$ac_cv_header_krb_h" = x""yes; then :
14536 cat >>confdefs.h <<_ACEOF
14537 #define HAVE_KRB_H 1
14538 _ACEOF
14539
14540 else
14541 for ac_header in kerberosIV/krb.h
14542 do :
14543 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14544 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14545 cat >>confdefs.h <<_ACEOF
14546 #define HAVE_KERBEROSIV_KRB_H 1
14547 _ACEOF
14548
14549 else
14550 for ac_header in kerberos/krb.h
14551 do :
14552 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14553 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14554 cat >>confdefs.h <<_ACEOF
14555 #define HAVE_KERBEROS_KRB_H 1
14556 _ACEOF
14557
14558 fi
14559
14560 done
14561
14562 fi
14563
14564 done
14565
14566 fi
14567
14568 done
14569
14570 fi
14571 for ac_header in com_err.h
14572 do :
14573 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14574 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14575 cat >>confdefs.h <<_ACEOF
14576 #define HAVE_COM_ERR_H 1
14577 _ACEOF
14578
14579 fi
14580
14581 done
14582
14583 fi
14584
14585
14586
14587
14588
14589
14590
14591
14592
14593
14594 for ac_func in $ac_func_list
14595 do :
14596 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14597 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14598 eval as_val=\$$as_ac_var
14599 if test "x$as_val" = x""yes; then :
14600 cat >>confdefs.h <<_ACEOF
14601 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14602 _ACEOF
14603
14604 fi
14605 done
14606
14607
14608
14609
14610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14611 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14612 if test "${emacs_cv_localtime_cache+set}" = set; then :
14613 $as_echo_n "(cached) " >&6
14614 else
14615 if test x$ac_cv_func_tzset = xyes; then
14616 if test "$cross_compiling" = yes; then :
14617 # If we have tzset, assume the worst when cross-compiling.
14618 emacs_cv_localtime_cache=yes
14619 else
14620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14621 /* end confdefs.h. */
14622 #include <time.h>
14623 char TZ_GMT0[] = "TZ=GMT0";
14624 char TZ_PST8[] = "TZ=PST8";
14625 main()
14626 {
14627 time_t now = time ((time_t *) 0);
14628 int hour_GMT0, hour_unset;
14629 if (putenv (TZ_GMT0) != 0)
14630 exit (1);
14631 hour_GMT0 = localtime (&now)->tm_hour;
14632 unsetenv("TZ");
14633 hour_unset = localtime (&now)->tm_hour;
14634 if (putenv (TZ_PST8) != 0)
14635 exit (1);
14636 if (localtime (&now)->tm_hour == hour_GMT0)
14637 exit (1);
14638 unsetenv("TZ");
14639 if (localtime (&now)->tm_hour != hour_unset)
14640 exit (1);
14641 exit (0);
14642 }
14643 _ACEOF
14644 if ac_fn_c_try_run "$LINENO"; then :
14645 emacs_cv_localtime_cache=no
14646 else
14647 emacs_cv_localtime_cache=yes
14648 fi
14649 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14650 conftest.$ac_objext conftest.beam conftest.$ac_ext
14651 fi
14652
14653 else
14654 # If we lack tzset, report that localtime does not cache TZ,
14655 # since we can't invalidate the cache if we don't have tzset.
14656 emacs_cv_localtime_cache=no
14657 fi
14658 fi
14659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14660 $as_echo "$emacs_cv_localtime_cache" >&6; }
14661 if test $emacs_cv_localtime_cache = yes; then
14662
14663 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14664
14665 fi
14666
14667 ok_so_far=yes
14668 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14669 if test "x$ac_cv_func_socket" = x""yes; then :
14670
14671 else
14672 ok_so_far=no
14673 fi
14674
14675 if test $ok_so_far = yes; then
14676 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14677 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14678
14679 else
14680 ok_so_far=no
14681 fi
14682
14683
14684 fi
14685 if test $ok_so_far = yes; then
14686 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14687 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14688
14689 else
14690 ok_so_far=no
14691 fi
14692
14693
14694 fi
14695 if test $ok_so_far = yes; then
14696
14697 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14698
14699 fi
14700
14701 if test -f /usr/lpp/X11/bin/smt.exp; then
14702
14703 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14704
14705 fi
14706
14707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14708 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14709 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14711 $as_echo "yes" >&6; }
14712
14713 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14714
14715 else
14716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14717 $as_echo "no" >&6; }
14718 fi
14719
14720 case $canonical in
14721 *-solaris2.4 | *-solaris2.4.*)
14722 : ${ac_cv_func_vfork_works=no};;
14723 esac
14724
14725 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14726 if test "x$ac_cv_type_pid_t" = x""yes; then :
14727
14728 else
14729
14730 cat >>confdefs.h <<_ACEOF
14731 #define pid_t int
14732 _ACEOF
14733
14734 fi
14735
14736 for ac_header in vfork.h
14737 do :
14738 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14739 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14740 cat >>confdefs.h <<_ACEOF
14741 #define HAVE_VFORK_H 1
14742 _ACEOF
14743
14744 fi
14745
14746 done
14747
14748 for ac_func in fork vfork
14749 do :
14750 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14751 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14752 eval as_val=\$$as_ac_var
14753 if test "x$as_val" = x""yes; then :
14754 cat >>confdefs.h <<_ACEOF
14755 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14756 _ACEOF
14757
14758 fi
14759 done
14760
14761 if test "x$ac_cv_func_fork" = xyes; then
14762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14763 $as_echo_n "checking for working fork... " >&6; }
14764 if test "${ac_cv_func_fork_works+set}" = set; then :
14765 $as_echo_n "(cached) " >&6
14766 else
14767 if test "$cross_compiling" = yes; then :
14768 ac_cv_func_fork_works=cross
14769 else
14770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14771 /* end confdefs.h. */
14772 $ac_includes_default
14773 int
14774 main ()
14775 {
14776
14777 /* By Ruediger Kuhlmann. */
14778 return fork () < 0;
14779
14780 ;
14781 return 0;
14782 }
14783 _ACEOF
14784 if ac_fn_c_try_run "$LINENO"; then :
14785 ac_cv_func_fork_works=yes
14786 else
14787 ac_cv_func_fork_works=no
14788 fi
14789 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14790 conftest.$ac_objext conftest.beam conftest.$ac_ext
14791 fi
14792
14793 fi
14794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14795 $as_echo "$ac_cv_func_fork_works" >&6; }
14796
14797 else
14798 ac_cv_func_fork_works=$ac_cv_func_fork
14799 fi
14800 if test "x$ac_cv_func_fork_works" = xcross; then
14801 case $host in
14802 *-*-amigaos* | *-*-msdosdjgpp*)
14803 # Override, as these systems have only a dummy fork() stub
14804 ac_cv_func_fork_works=no
14805 ;;
14806 *)
14807 ac_cv_func_fork_works=yes
14808 ;;
14809 esac
14810 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14811 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14812 fi
14813 ac_cv_func_vfork_works=$ac_cv_func_vfork
14814 if test "x$ac_cv_func_vfork" = xyes; then
14815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14816 $as_echo_n "checking for working vfork... " >&6; }
14817 if test "${ac_cv_func_vfork_works+set}" = set; then :
14818 $as_echo_n "(cached) " >&6
14819 else
14820 if test "$cross_compiling" = yes; then :
14821 ac_cv_func_vfork_works=cross
14822 else
14823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14824 /* end confdefs.h. */
14825 /* Thanks to Paul Eggert for this test. */
14826 $ac_includes_default
14827 #include <sys/wait.h>
14828 #ifdef HAVE_VFORK_H
14829 # include <vfork.h>
14830 #endif
14831 /* On some sparc systems, changes by the child to local and incoming
14832 argument registers are propagated back to the parent. The compiler
14833 is told about this with #include <vfork.h>, but some compilers
14834 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14835 static variable whose address is put into a register that is
14836 clobbered by the vfork. */
14837 static void
14838 #ifdef __cplusplus
14839 sparc_address_test (int arg)
14840 # else
14841 sparc_address_test (arg) int arg;
14842 #endif
14843 {
14844 static pid_t child;
14845 if (!child) {
14846 child = vfork ();
14847 if (child < 0) {
14848 perror ("vfork");
14849 _exit(2);
14850 }
14851 if (!child) {
14852 arg = getpid();
14853 write(-1, "", 0);
14854 _exit (arg);
14855 }
14856 }
14857 }
14858
14859 int
14860 main ()
14861 {
14862 pid_t parent = getpid ();
14863 pid_t child;
14864
14865 sparc_address_test (0);
14866
14867 child = vfork ();
14868
14869 if (child == 0) {
14870 /* Here is another test for sparc vfork register problems. This
14871 test uses lots of local variables, at least as many local
14872 variables as main has allocated so far including compiler
14873 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14874 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14875 reuse the register of parent for one of the local variables,
14876 since it will think that parent can't possibly be used any more
14877 in this routine. Assigning to the local variable will thus
14878 munge parent in the parent process. */
14879 pid_t
14880 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14881 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14882 /* Convince the compiler that p..p7 are live; otherwise, it might
14883 use the same hardware register for all 8 local variables. */
14884 if (p != p1 || p != p2 || p != p3 || p != p4
14885 || p != p5 || p != p6 || p != p7)
14886 _exit(1);
14887
14888 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14889 from child file descriptors. If the child closes a descriptor
14890 before it execs or exits, this munges the parent's descriptor
14891 as well. Test for this by closing stdout in the child. */
14892 _exit(close(fileno(stdout)) != 0);
14893 } else {
14894 int status;
14895 struct stat st;
14896
14897 while (wait(&status) != child)
14898 ;
14899 return (
14900 /* Was there some problem with vforking? */
14901 child < 0
14902
14903 /* Did the child fail? (This shouldn't happen.) */
14904 || status
14905
14906 /* Did the vfork/compiler bug occur? */
14907 || parent != getpid()
14908
14909 /* Did the file descriptor bug occur? */
14910 || fstat(fileno(stdout), &st) != 0
14911 );
14912 }
14913 }
14914 _ACEOF
14915 if ac_fn_c_try_run "$LINENO"; then :
14916 ac_cv_func_vfork_works=yes
14917 else
14918 ac_cv_func_vfork_works=no
14919 fi
14920 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14921 conftest.$ac_objext conftest.beam conftest.$ac_ext
14922 fi
14923
14924 fi
14925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14926 $as_echo "$ac_cv_func_vfork_works" >&6; }
14927
14928 fi;
14929 if test "x$ac_cv_func_fork_works" = xcross; then
14930 ac_cv_func_vfork_works=$ac_cv_func_vfork
14931 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14932 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14933 fi
14934
14935 if test "x$ac_cv_func_vfork_works" = xyes; then
14936
14937 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14938
14939 else
14940
14941 $as_echo "#define vfork fork" >>confdefs.h
14942
14943 fi
14944 if test "x$ac_cv_func_fork_works" = xyes; then
14945
14946 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14947
14948 fi
14949
14950
14951 for ac_func in snprintf
14952 do :
14953 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14954 if test "x$ac_cv_func_snprintf" = x""yes; then :
14955 cat >>confdefs.h <<_ACEOF
14956 #define HAVE_SNPRINTF 1
14957 _ACEOF
14958
14959 fi
14960 done
14961
14962
14963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14964 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14965 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14966 $as_echo_n "(cached) " >&6
14967 else
14968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14969 /* end confdefs.h. */
14970 #include <langinfo.h>
14971 int
14972 main ()
14973 {
14974 char* cs = nl_langinfo(CODESET);
14975 ;
14976 return 0;
14977 }
14978 _ACEOF
14979 if ac_fn_c_try_link "$LINENO"; then :
14980 emacs_cv_langinfo_codeset=yes
14981 else
14982 emacs_cv_langinfo_codeset=no
14983 fi
14984 rm -f core conftest.err conftest.$ac_objext \
14985 conftest$ac_exeext conftest.$ac_ext
14986
14987 fi
14988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14989 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14990 if test $emacs_cv_langinfo_codeset = yes; then
14991
14992 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14993
14994 fi
14995
14996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14997 $as_echo_n "checking for mbstate_t... " >&6; }
14998 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14999 $as_echo_n "(cached) " >&6
15000 else
15001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15002 /* end confdefs.h. */
15003 $ac_includes_default
15004 # include <wchar.h>
15005 int
15006 main ()
15007 {
15008 mbstate_t x; return sizeof x;
15009 ;
15010 return 0;
15011 }
15012 _ACEOF
15013 if ac_fn_c_try_compile "$LINENO"; then :
15014 ac_cv_type_mbstate_t=yes
15015 else
15016 ac_cv_type_mbstate_t=no
15017 fi
15018 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15019 fi
15020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
15021 $as_echo "$ac_cv_type_mbstate_t" >&6; }
15022 if test $ac_cv_type_mbstate_t = yes; then
15023
15024 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
15025
15026 else
15027
15028 $as_echo "#define mbstate_t int" >>confdefs.h
15029
15030 fi
15031
15032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15033 $as_echo_n "checking for C restricted array declarations... " >&6; }
15034 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
15035 $as_echo_n "(cached) " >&6
15036 else
15037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15038 /* end confdefs.h. */
15039 void fred (int x[__restrict]);
15040 int
15041 main ()
15042 {
15043
15044 ;
15045 return 0;
15046 }
15047 _ACEOF
15048 if ac_fn_c_try_compile "$LINENO"; then :
15049 emacs_cv_c_restrict_arr=yes
15050 else
15051 emacs_cv_c_restrict_arr=no
15052 fi
15053 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15054 fi
15055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15056 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
15057 if test "$emacs_cv_c_restrict_arr" = yes; then
15058
15059 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
15060
15061 fi
15062
15063
15064
15065 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
15066
15067
15068
15069 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
15070
15071
15072 ## Note: PTYs are broken on darwin <6. Use at your own risk.
15073
15074 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
15075
15076
15077
15078 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
15079
15080
15081
15082
15083
15084 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
15085
15086
15087
15088 $as_echo "#define SEPCHAR ':'" >>confdefs.h
15089
15090
15091
15092 $as_echo "#define subprocesses 1" >>confdefs.h
15093
15094
15095
15096 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
15097
15098
15099
15100
15101 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
15102
15103
15104
15105
15106
15107 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
15108
15109
15110
15111 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
15112
15113
15114
15115 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
15116
15117
15118
15119
15120
15121 case $opsys in
15122 aix4-2)
15123 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
15124 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15125
15126 fi
15127 ;;
15128
15129 hpux*)
15130 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15131
15132 ;;
15133 esac
15134
15135
15136 case $opsys in
15137 irix6-5 | sol2* | unixware )
15138
15139 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
15140
15141 ;;
15142 esac
15143
15144 emacs_broken_SIGIO=no
15145
15146 case $opsys in
15147 hpux* | irix6-5 | openbsd | sol2* | unixware )
15148 emacs_broken_SIGIO=yes
15149 ;;
15150
15151 aix4-2)
15152
15153 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
15154
15155 ;;
15156
15157 freebsd)
15158
15159 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
15160
15161 ;;
15162 esac
15163
15164 case $opsys in
15165 gnu-* | sol2-10 )
15166
15167 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
15168
15169 ;;
15170 esac
15171
15172 case $opsys in
15173 darwin | freebsd | netbsd | openbsd )
15174
15175 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
15176
15177 ;;
15178 esac
15179
15180 case $opsys in
15181 netbsd | openbsd) sound_device="/dev/audio" ;;
15182 *) sound_device="/dev/dsp" ;;
15183 esac
15184
15185
15186 cat >>confdefs.h <<_ACEOF
15187 #define DEFAULT_SOUND_DEVICE "$sound_device"
15188 _ACEOF
15189
15190
15191
15192 case $opsys in
15193 darwin | gnu-linux | gnu-kfreebsd )
15194
15195 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
15196
15197 ;;
15198 esac
15199
15200
15201 case $opsys in
15202 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
15203
15204 $as_echo "#define NARROWPROTO 1" >>confdefs.h
15205
15206 ;;
15207 esac
15208
15209
15210
15211
15212
15213
15214
15215
15216 case $opsys in
15217 aix4-2 )
15218 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
15219
15220 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
15221
15222 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
15223
15224 ;;
15225
15226 cygwin )
15227 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15228
15229 $as_echo "#define PTY_OPEN do { int dummy; sigset_t blocked, procmask; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, &procmask); if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) fd = -1; pthread_sigmask (SIG_SETMASK, &procmask, 0); if (fd >= 0) emacs_close (dummy); } while (0)" >>confdefs.h
15230
15231 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15232
15233 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15234
15235 ;;
15236
15237 darwin )
15238 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15239
15240 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15241
15242 $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
15243
15244 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15245
15246 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15247
15248 ;;
15249
15250 gnu | openbsd )
15251 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15252
15253 ;;
15254
15255 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15256 if test "x$ac_cv_func_grantpt" = xyes; then
15257
15258 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15259
15260 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15261
15262 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15263
15264 if test "x$ac_cv_func_posix_openpt" = xyes; then
15265 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15266
15267 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15268
15269 elif test "x$ac_cv_func_getpt" = xyes; then
15270 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15271
15272 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15273
15274 else
15275 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15276
15277 fi
15278 else
15279 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15280
15281 fi
15282 ;;
15283
15284 hpux*)
15285 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15286
15287 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15288
15289 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15290
15291 ;;
15292
15293 irix6-5 )
15294 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15295
15296 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15297
15298 $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
15299
15300 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15301
15302 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15303
15304 ;;
15305
15306 sol2* )
15307 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15308
15309 ;;
15310
15311 unixware )
15312 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15313
15314 ;;
15315 esac
15316
15317
15318 case $opsys in
15319 sol2* | unixware )
15320 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15321
15322 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15323
15324
15325 $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
15326
15327 ;;
15328 esac
15329
15330
15331
15332
15333 case $opsys in
15334 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15335 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15336
15337 ;;
15338
15339 gnu-linux | gnu-kfreebsd )
15340
15341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15342 $as_echo_n "checking for signals via characters... " >&6; }
15343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15344 /* end confdefs.h. */
15345
15346 #include <linux/version.h>
15347 #if LINUX_VERSION_CODE < 0x20400
15348 # error "Linux version too old"
15349 #endif
15350
15351 int
15352 main ()
15353 {
15354
15355 ;
15356 return 0;
15357 }
15358 _ACEOF
15359 if ac_fn_c_try_cpp "$LINENO"; then :
15360 emacs_signals_via_chars=yes
15361 else
15362 emacs_signals_via_chars=no
15363 fi
15364 rm -f conftest.err conftest.$ac_ext
15365
15366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15367 $as_echo "$emacs_signals_via_chars" >&6; }
15368 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15369
15370 ;;
15371 esac
15372
15373
15374
15375
15376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C library" >&5
15377 $as_echo_n "checking whether we are using the GNU C library... " >&6; }
15378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15379 /* end confdefs.h. */
15380
15381 #include <features.h>
15382 #ifndef __GNU_LIBRARY__
15383 # error "this is not the GNU C library"
15384 #endif
15385
15386 int
15387 main ()
15388 {
15389
15390 ;
15391 return 0;
15392 }
15393 _ACEOF
15394 if ac_fn_c_try_cpp "$LINENO"; then :
15395 emacs_glibc=yes
15396 else
15397 emacs_glibc=no
15398 fi
15399 rm -f conftest.err conftest.$ac_ext
15400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_glibc" >&5
15401 $as_echo "$emacs_glibc" >&6; }
15402
15403 if test $emacs_glibc = yes; then
15404
15405 emacs_pending_output=unknown
15406
15407 case $opsys in
15408 gnu | gnu-linux | gnu-kfreebsd )
15409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of pending output formalism" >&5
15410 $as_echo_n "checking for style of pending output formalism... " >&6; }
15411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15412 /* end confdefs.h. */
15413
15414 #include <stdio.h>
15415 #if !defined (_IO_STDIO_H) && !defined (_STDIO_USES_IOSTREAM)
15416 # error "stdio definitions not found"
15417 #endif
15418
15419 int
15420 main ()
15421 {
15422
15423 ;
15424 return 0;
15425 }
15426 _ACEOF
15427 if ac_fn_c_try_cpp "$LINENO"; then :
15428 emacs_pending_output=new
15429 fi
15430 rm -f conftest.err conftest.$ac_ext
15431
15432 if test $emacs_pending_output = unknown; then
15433 case $opsys in
15434 gnu-linux | gnu-kfreebsd)
15435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15436 /* end confdefs.h. */
15437
15438 #include <stdio.h>
15439 #ifndef __UCLIBC__
15440 # error "not using uclibc"
15441 #endif
15442
15443 int
15444 main ()
15445 {
15446
15447 ;
15448 return 0;
15449 }
15450 _ACEOF
15451 if ac_fn_c_try_cpp "$LINENO"; then :
15452 emacs_pending_output=uclibc
15453 else
15454 emacs_pending_output=old
15455 fi
15456 rm -f conftest.err conftest.$ac_ext
15457 ;;
15458 esac
15459 fi
15460
15461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_pending_output" >&5
15462 $as_echo "$emacs_pending_output" >&6; }
15463
15464 case $emacs_pending_output in
15465 new)
15466 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_IO_write_ptr - (FILE)->_IO_write_base)" >>confdefs.h
15467
15468 ;;
15469 uclibc)
15470 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufpos - (FILE)->__bufstart)" >>confdefs.h
15471
15472 ;;
15473 old)
15474 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_pptr - (FILE)->_pbase)" >>confdefs.h
15475
15476 ;;
15477 esac
15478 ;;
15479 esac
15480 if test $emacs_pending_output = unknown; then
15481 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufp - (FILE)->__buffer)" >>confdefs.h
15482
15483 fi
15484
15485 else
15486 case $opsys in
15487 cygwin | darwin | freebsd | netbsd | openbsd )
15488 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)" >>confdefs.h
15489
15490 ;;
15491
15492 unixware)
15493 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__ptr - (FILE)->__base)" >>confdefs.h
15494
15495 ;;
15496
15497 *)
15498 if test x$ac_cv_header_stdio_ext_h = xyes && \
15499 test x$ac_cv_func___fpending = xyes; then
15500 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) __fpending (FILE)" >>confdefs.h
15501
15502
15503 $as_echo "#define DISPNEW_NEEDS_STDIO_EXT 1" >>confdefs.h
15504
15505 else
15506 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_ptr - (FILE)->_base)" >>confdefs.h
15507
15508 fi
15509 ;;
15510 esac
15511 fi
15512
15513
15514
15515
15516 case $opsys in
15517 gnu)
15518 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15519
15520 ;;
15521
15522 hpux*)
15523 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15524
15525 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15526
15527 ;;
15528 irix6-5)
15529 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15530
15531 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15532
15533 ;;
15534 esac
15535
15536
15537
15538
15539
15540 case $opsys in
15541 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15542 ;;
15543
15544 gnu | freebsd | netbsd | openbsd )
15545
15546 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15547
15548 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15549
15550 ;;
15551
15552 gnu-linux | gnu-kfreebsd )
15553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15554 /* end confdefs.h. */
15555
15556 #ifndef __i386__
15557 # error "not i386"
15558 #endif
15559
15560 int
15561 main ()
15562 {
15563
15564 ;
15565 return 0;
15566 }
15567 _ACEOF
15568 if ac_fn_c_try_cpp "$LINENO"; then :
15569 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15570
15571 fi
15572 rm -f conftest.err conftest.$ac_ext
15573
15574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15575 /* end confdefs.h. */
15576
15577 #ifndef __ia64__
15578 # error "not ia64"
15579 #endif
15580
15581 int
15582 main ()
15583 {
15584
15585 ;
15586 return 0;
15587 }
15588 _ACEOF
15589 if ac_fn_c_try_cpp "$LINENO"; then :
15590
15591 $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
15592
15593 fi
15594 rm -f conftest.err conftest.$ac_ext
15595 ;;
15596
15597 hpux*)
15598
15599 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15600
15601 ;;
15602
15603 irix6-5)
15604 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15605
15606 ;;
15607 esac
15608
15609
15610
15611
15612
15613
15614
15615 case $opsys in
15616 aix4-2 | hpux* | unixware)
15617 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15618
15619 ;;
15620
15621 gnu-linux | gnu-kfreebsd )
15622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15623 /* end confdefs.h. */
15624
15625 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15626 || defined __alpha__ || defined __mips__ || defined __s390__ \
15627 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15628 || defined __ia64__ || defined __sh__
15629 /* ok */
15630 #else
15631 # error "setjmp not known to work on this arch"
15632 #endif
15633
15634 int
15635 main ()
15636 {
15637
15638 ;
15639 return 0;
15640 }
15641 _ACEOF
15642 if ac_fn_c_try_cpp "$LINENO"; then :
15643 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15644
15645 else
15646 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15647
15648 fi
15649 rm -f conftest.err conftest.$ac_ext
15650 ;;
15651 esac
15652
15653
15654 if test x$GCC = xyes; then
15655 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15656
15657 else
15658 case $opsys in
15659 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15660 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15661
15662 ;;
15663 esac
15664 fi
15665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15666 $as_echo_n "checking for _setjmp... " >&6; }
15667 if test "${emacs_cv_func__setjmp+set}" = set; then :
15668 $as_echo_n "(cached) " >&6
15669 else
15670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15671 /* end confdefs.h. */
15672 #include <setjmp.h>
15673
15674 int
15675 main ()
15676 {
15677 jmp_buf j;
15678 if (! _setjmp (j))
15679 _longjmp (j, 1);
15680 ;
15681 return 0;
15682 }
15683 _ACEOF
15684 if ac_fn_c_try_link "$LINENO"; then :
15685 emacs_cv_func__setjmp=yes
15686 else
15687 emacs_cv_func__setjmp=no
15688 fi
15689 rm -f core conftest.err conftest.$ac_objext \
15690 conftest$ac_exeext conftest.$ac_ext
15691 fi
15692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15693 $as_echo "$emacs_cv_func__setjmp" >&6; }
15694 if test $emacs_cv_func__setjmp = yes; then
15695
15696 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
15697
15698 else
15699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
15700 $as_echo_n "checking for sigsetjmp... " >&6; }
15701 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
15702 $as_echo_n "(cached) " >&6
15703 else
15704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15705 /* end confdefs.h. */
15706 #include <setjmp.h>
15707
15708 int
15709 main ()
15710 {
15711 sigjmp_buf j;
15712 if (! sigsetjmp (j, 1))
15713 siglongjmp (j, 1);
15714 ;
15715 return 0;
15716 }
15717 _ACEOF
15718 if ac_fn_c_try_link "$LINENO"; then :
15719 emacs_cv_func_sigsetjmp=yes
15720 else
15721 emacs_cv_func_sigsetjmp=no
15722 fi
15723 rm -f core conftest.err conftest.$ac_objext \
15724 conftest$ac_exeext conftest.$ac_ext
15725 fi
15726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
15727 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
15728 if test $emacs_cv_func_sigsetjmp = yes; then
15729
15730 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
15731
15732 fi
15733 fi
15734
15735 case $opsys in
15736 sol2* | unixware )
15737
15738 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15739
15740 ;;
15741 esac
15742
15743
15744 case $opsys in
15745 hpux* | sol2* )
15746
15747 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15748
15749 ;;
15750 esac
15751
15752
15753
15754
15755
15756
15757
15758
15759
15760
15761 case $opsys in
15762 aix4-2)
15763 $as_echo "#define USG /**/" >>confdefs.h
15764
15765 $as_echo "#define USG5 /**/" >>confdefs.h
15766
15767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15768 /* end confdefs.h. */
15769
15770 #ifndef _AIX
15771 # error "_AIX not defined"
15772 #endif
15773
15774 int
15775 main ()
15776 {
15777
15778 ;
15779 return 0;
15780 }
15781 _ACEOF
15782 if ac_fn_c_try_cpp "$LINENO"; then :
15783
15784 else
15785
15786 $as_echo "#define _AIX /**/" >>confdefs.h
15787
15788 fi
15789 rm -f conftest.err conftest.$ac_ext
15790 ;;
15791
15792 cygwin)
15793
15794 $as_echo "#define CYGWIN 1" >>confdefs.h
15795
15796 ;;
15797
15798 darwin)
15799 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15800
15801 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15802
15803
15804 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15805
15806 ;;
15807
15808 freebsd)
15809 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15810
15811
15812 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15813
15814 ;;
15815
15816 gnu | netbsd | openbsd )
15817 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15818
15819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15820 /* end confdefs.h. */
15821
15822 #ifndef BSD_SYSTEM
15823 # error "BSD_SYSTEM not defined"
15824 #endif
15825
15826 int
15827 main ()
15828 {
15829
15830 ;
15831 return 0;
15832 }
15833 _ACEOF
15834 if ac_fn_c_try_cpp "$LINENO"; then :
15835
15836 else
15837 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15838
15839 fi
15840 rm -f conftest.err conftest.$ac_ext
15841 ;;
15842
15843 gnu-linux | gnu-kfreebsd )
15844 $as_echo "#define USG /**/" >>confdefs.h
15845
15846
15847 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15848
15849 ;;
15850
15851 hpux*)
15852 $as_echo "#define USG /**/" >>confdefs.h
15853
15854 $as_echo "#define USG5 /**/" >>confdefs.h
15855
15856
15857 $as_echo "#define HPUX /**/" >>confdefs.h
15858
15859 ;;
15860
15861 irix6-5)
15862 $as_echo "#define USG /**/" >>confdefs.h
15863
15864 $as_echo "#define USG5 /**/" >>confdefs.h
15865
15866 $as_echo "#define USG5_4 /**/" >>confdefs.h
15867
15868
15869 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15870
15871 ;;
15872
15873 sol2*)
15874 $as_echo "#define USG /**/" >>confdefs.h
15875
15876 $as_echo "#define USG5 /**/" >>confdefs.h
15877
15878 $as_echo "#define USG5_4 /**/" >>confdefs.h
15879
15880
15881 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15882
15883 ;;
15884
15885 unixware)
15886 $as_echo "#define USG /**/" >>confdefs.h
15887
15888 $as_echo "#define USG5 /**/" >>confdefs.h
15889
15890 $as_echo "#define USG5_4 /**/" >>confdefs.h
15891
15892 ;;
15893 esac
15894
15895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
15896 $as_echo_n "checking for usable FIONREAD... " >&6; }
15897 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
15898 $as_echo_n "(cached) " >&6
15899 else
15900 case $opsys in
15901 aix4-2)
15902 emacs_cv_usable_FIONREAD=no
15903 ;;
15904
15905 *)
15906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15907 /* end confdefs.h. */
15908 #include <sys/types.h>
15909 #include <sys/ioctl.h>
15910 #ifdef USG5_4
15911 # include <sys/filio.h>
15912 #endif
15913
15914 int
15915 main ()
15916 {
15917 int foo = ioctl (0, FIONREAD, &foo);
15918 ;
15919 return 0;
15920 }
15921 _ACEOF
15922 if ac_fn_c_try_compile "$LINENO"; then :
15923 emacs_cv_usable_FIONREAD=yes
15924 else
15925 emacs_cv_usable_FIONREAD=no
15926 fi
15927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15928 ;;
15929 esac
15930 fi
15931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
15932 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
15933 if test $emacs_cv_usable_FIONREAD = yes; then
15934
15935 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
15936
15937
15938 if test $emacs_broken_SIGIO = no; then
15939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
15940 $as_echo_n "checking for usable SIGIO... " >&6; }
15941 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
15942 $as_echo_n "(cached) " >&6
15943 else
15944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15945 /* end confdefs.h. */
15946 #include <fcntl.h>
15947 #include <signal.h>
15948
15949 int
15950 main ()
15951 {
15952 int foo = SIGIO | F_SETFL | FASYNC;
15953 ;
15954 return 0;
15955 }
15956 _ACEOF
15957 if ac_fn_c_try_compile "$LINENO"; then :
15958 emacs_cv_usable_SIGIO=yes
15959 else
15960 emacs_cv_usable_SIGIO=no
15961 fi
15962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15963 fi
15964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
15965 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
15966 if test $emacs_cv_usable_SIGIO = yes; then
15967
15968 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
15969
15970 fi
15971 fi
15972 fi
15973
15974
15975 case $opsys in
15976 cygwin)
15977
15978 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15979
15980 ;;
15981
15982 hpux11)
15983
15984 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15985
15986 ;;
15987
15988 irix6-5)
15989
15990 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15991
15992
15993 $as_echo "#define SETPGRP_RELEASES_CTTY 1" >>confdefs.h
15994
15995 ;;
15996
15997 sol2-10)
15998
15999 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
16000
16001 ;;
16002 esac
16003
16004 # Set up the CFLAGS for real compilation, so we can substitute it.
16005 CFLAGS="$REAL_CFLAGS"
16006 CPPFLAGS="$REAL_CPPFLAGS"
16007
16008 ## Hack to detect a buggy GCC version.
16009 if test "x$GCC" = xyes \
16010 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
16011 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
16012 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
16013 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
16014 fi
16015
16016 version=$PACKAGE_VERSION
16017
16018 copyright="Copyright (C) 2012 Free Software Foundation, Inc."
16019
16020 cat >>confdefs.h <<_ACEOF
16021 #define COPYRIGHT "$copyright"
16022 _ACEOF
16023
16024
16025
16026 ### Specify what sort of things we'll be editing into Makefile and config.h.
16027 ### Use configuration here uncanonicalized to avoid exceeding size limits.
16028
16029
16030 ## Unused?
16031
16032
16033
16034
16035
16036
16037
16038
16039
16040
16041
16042
16043
16044
16045
16046
16047
16048
16049
16050
16051
16052
16053 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
16054 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
16055 ## end of LIBX_BASE, but nothing ever set it.
16056
16057
16058
16059
16060 ## Used in lwlib/Makefile.in.
16061
16062
16063
16064
16065
16066
16067
16068
16069 if test -n "${term_header}"; then
16070
16071 cat >>confdefs.h <<_ACEOF
16072 #define TERM_HEADER "${term_header}"
16073 _ACEOF
16074
16075 fi
16076
16077
16078 cat >>confdefs.h <<_ACEOF
16079 #define EMACS_CONFIGURATION "${canonical}"
16080 _ACEOF
16081
16082
16083 cat >>confdefs.h <<_ACEOF
16084 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
16085 _ACEOF
16086
16087
16088
16089 XMENU_OBJ=
16090 XOBJ=
16091 FONT_OBJ=
16092 if test "${HAVE_X_WINDOWS}" = "yes" ; then
16093
16094 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
16095
16096 XMENU_OBJ=xmenu.o
16097 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
16098 FONT_OBJ=xfont.o
16099 if test "$HAVE_XFT" = "yes"; then
16100 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
16101 elif test "$HAVE_FREETYPE" = "yes"; then
16102 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
16103 fi
16104
16105 fi
16106
16107
16108
16109
16110 WIDGET_OBJ=
16111 MOTIF_LIBW=
16112 if test "${USE_X_TOOLKIT}" != "none" ; then
16113 WIDGET_OBJ=widget.o
16114
16115 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
16116
16117 if test "${USE_X_TOOLKIT}" = "LUCID"; then
16118
16119 $as_echo "#define USE_LUCID 1" >>confdefs.h
16120
16121 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
16122
16123 $as_echo "#define USE_MOTIF 1" >>confdefs.h
16124
16125 MOTIF_LIBW=-lXm
16126 case "$opsys" in
16127 gnu-linux)
16128 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
16129 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
16130 ;;
16131
16132 unixware)
16133 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
16134 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
16135 MOTIF_LIBW="MOTIF_LIBW -lXimp"
16136 ;;
16137
16138 aix4-2)
16139 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
16140 MOTIF_LIBW="$MOTIF_LIBW -li18n"
16141 ;;
16142 esac
16143 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
16144 fi
16145 fi
16146
16147
16148 TOOLKIT_LIBW=
16149 case "$USE_X_TOOLKIT" in
16150 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
16151 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
16152 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
16153 esac
16154
16155
16156 if test "$USE_X_TOOLKIT" = "none"; then
16157 LIBXT_OTHER="\$(LIBXSM)"
16158 OLDXMENU_TARGET="really-oldXMenu"
16159 else
16160 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
16161 OLDXMENU_TARGET="really-lwlib"
16162 fi
16163
16164
16165 ## The X Menu stuff is present in the X10 distribution, but missing
16166 ## from X11. If we have X10, just use the installed library;
16167 ## otherwise, use our own copy.
16168 if test "${HAVE_X11}" = "yes" ; then
16169
16170 $as_echo "#define HAVE_X11 1" >>confdefs.h
16171
16172
16173 if test "$USE_X_TOOLKIT" = "none"; then
16174 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
16175 else
16176 OLDXMENU="\${lwlibdir}/liblw.a"
16177 fi
16178 LIBXMENU="\$(OLDXMENU)"
16179 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
16180 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
16181 else
16182 ## For a syntactically valid Makefile; not actually used for anything.
16183 ## See comments in src/Makefile.in.
16184 OLDXMENU=nothing
16185 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
16186 if test "${HAVE_X_WINDOWS}" = "yes"; then
16187 LIBXMENU="-lXMenu"
16188 else
16189 LIBXMENU=
16190 fi
16191 LIBX_OTHER=
16192 OLDXMENU_DEPS=
16193 fi
16194
16195 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
16196 OLDXMENU_TARGET=
16197 OLDXMENU=nothing
16198 LIBXMENU=
16199 OLDXMENU_DEPS=
16200 fi
16201
16202
16203
16204
16205
16206
16207
16208 if test "${HAVE_MENUS}" = "yes" ; then
16209
16210 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
16211
16212 fi
16213
16214 if test "${GNU_MALLOC}" = "yes" ; then
16215
16216 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
16217
16218 fi
16219
16220 RALLOC_OBJ=
16221 if test "${REL_ALLOC}" = "yes" ; then
16222
16223 $as_echo "#define REL_ALLOC 1" >>confdefs.h
16224
16225
16226 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
16227 fi
16228
16229
16230 if test "$opsys" = "cygwin"; then
16231 CYGWIN_OBJ="sheap.o cygw32.o"
16232 ## Cygwin differs because of its unexec().
16233 PRE_ALLOC_OBJ=
16234 POST_ALLOC_OBJ=lastfile.o
16235 else
16236 CYGWIN_OBJ=
16237 PRE_ALLOC_OBJ=lastfile.o
16238 POST_ALLOC_OBJ=
16239 fi
16240
16241
16242
16243
16244 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
16245 # it temporarily reverts them to their pre-pkg-config values,
16246 # because gnulib needs to work with both src (which uses the
16247 # pkg-config stuff) and lib-src (which does not). For example, gnulib
16248 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
16249 # and it therefore needs to run in an environment where LIBS does not
16250 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
16251 # for some package unrelated to lib-src.
16252 SAVE_CFLAGS=$CFLAGS
16253 SAVE_LIBS=$LIBS
16254 CFLAGS=$pre_PKG_CONFIG_CFLAGS
16255 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
16256
16257
16258
16259
16260
16261
16262
16263
16264
16265
16266
16267 LIBC_FATAL_STDERR_=1
16268 export LIBC_FATAL_STDERR_
16269
16270 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
16271 # for constant arguments. Useless!
16272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
16273 $as_echo_n "checking for working alloca.h... " >&6; }
16274 if test "${ac_cv_working_alloca_h+set}" = set; then :
16275 $as_echo_n "(cached) " >&6
16276 else
16277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16278 /* end confdefs.h. */
16279 #include <alloca.h>
16280 int
16281 main ()
16282 {
16283 char *p = (char *) alloca (2 * sizeof (int));
16284 if (p) return 0;
16285 ;
16286 return 0;
16287 }
16288 _ACEOF
16289 if ac_fn_c_try_link "$LINENO"; then :
16290 ac_cv_working_alloca_h=yes
16291 else
16292 ac_cv_working_alloca_h=no
16293 fi
16294 rm -f core conftest.err conftest.$ac_objext \
16295 conftest$ac_exeext conftest.$ac_ext
16296 fi
16297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16298 $as_echo "$ac_cv_working_alloca_h" >&6; }
16299 if test $ac_cv_working_alloca_h = yes; then
16300
16301 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
16302
16303 fi
16304
16305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16306 $as_echo_n "checking for alloca... " >&6; }
16307 if test "${ac_cv_func_alloca_works+set}" = set; then :
16308 $as_echo_n "(cached) " >&6
16309 else
16310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16311 /* end confdefs.h. */
16312 #ifdef __GNUC__
16313 # define alloca __builtin_alloca
16314 #else
16315 # ifdef _MSC_VER
16316 # include <malloc.h>
16317 # define alloca _alloca
16318 # else
16319 # ifdef HAVE_ALLOCA_H
16320 # include <alloca.h>
16321 # else
16322 # ifdef _AIX
16323 #pragma alloca
16324 # else
16325 # ifndef alloca /* predefined by HP cc +Olibcalls */
16326 char *alloca ();
16327 # endif
16328 # endif
16329 # endif
16330 # endif
16331 #endif
16332
16333 int
16334 main ()
16335 {
16336 char *p = (char *) alloca (1);
16337 if (p) return 0;
16338 ;
16339 return 0;
16340 }
16341 _ACEOF
16342 if ac_fn_c_try_link "$LINENO"; then :
16343 ac_cv_func_alloca_works=yes
16344 else
16345 ac_cv_func_alloca_works=no
16346 fi
16347 rm -f core conftest.err conftest.$ac_objext \
16348 conftest$ac_exeext conftest.$ac_ext
16349 fi
16350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16351 $as_echo "$ac_cv_func_alloca_works" >&6; }
16352
16353 if test $ac_cv_func_alloca_works = yes; then
16354
16355 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16356
16357 else
16358 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16359 # that cause trouble. Some versions do not even contain alloca or
16360 # contain a buggy version. If you still want to use their alloca,
16361 # use ar to extract alloca.o from them instead of compiling alloca.c.
16362
16363
16364
16365
16366
16367 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16368
16369 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16370
16371
16372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16373 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16374 if test "${ac_cv_os_cray+set}" = set; then :
16375 $as_echo_n "(cached) " >&6
16376 else
16377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16378 /* end confdefs.h. */
16379 #if defined CRAY && ! defined CRAY2
16380 webecray
16381 #else
16382 wenotbecray
16383 #endif
16384
16385 _ACEOF
16386 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16387 $EGREP "webecray" >/dev/null 2>&1; then :
16388 ac_cv_os_cray=yes
16389 else
16390 ac_cv_os_cray=no
16391 fi
16392 rm -f conftest*
16393
16394 fi
16395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16396 $as_echo "$ac_cv_os_cray" >&6; }
16397 if test $ac_cv_os_cray = yes; then
16398 for ac_func in _getb67 GETB67 getb67; do
16399 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16400 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16401 eval as_val=\$$as_ac_var
16402 if test "x$as_val" = x""yes; then :
16403
16404 cat >>confdefs.h <<_ACEOF
16405 #define CRAY_STACKSEG_END $ac_func
16406 _ACEOF
16407
16408 break
16409 fi
16410
16411 done
16412 fi
16413
16414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16415 $as_echo_n "checking stack direction for C alloca... " >&6; }
16416 if test "${ac_cv_c_stack_direction+set}" = set; then :
16417 $as_echo_n "(cached) " >&6
16418 else
16419 if test "$cross_compiling" = yes; then :
16420 ac_cv_c_stack_direction=0
16421 else
16422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16423 /* end confdefs.h. */
16424 $ac_includes_default
16425 int
16426 find_stack_direction (int *addr, int depth)
16427 {
16428 int dir, dummy = 0;
16429 if (! addr)
16430 addr = &dummy;
16431 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16432 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16433 return dir + dummy;
16434 }
16435
16436 int
16437 main (int argc, char **argv)
16438 {
16439 return find_stack_direction (0, argc + !argv + 20) < 0;
16440 }
16441 _ACEOF
16442 if ac_fn_c_try_run "$LINENO"; then :
16443 ac_cv_c_stack_direction=1
16444 else
16445 ac_cv_c_stack_direction=-1
16446 fi
16447 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16448 conftest.$ac_objext conftest.beam conftest.$ac_ext
16449 fi
16450
16451 fi
16452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16453 $as_echo "$ac_cv_c_stack_direction" >&6; }
16454 cat >>confdefs.h <<_ACEOF
16455 #define STACK_DIRECTION $ac_cv_c_stack_direction
16456 _ACEOF
16457
16458
16459 fi
16460
16461
16462
16463
16464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16465 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16466 if test "${ac_cv_c_bigendian+set}" = set; then :
16467 $as_echo_n "(cached) " >&6
16468 else
16469 ac_cv_c_bigendian=unknown
16470 # See if we're dealing with a universal compiler.
16471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16472 /* end confdefs.h. */
16473 #ifndef __APPLE_CC__
16474 not a universal capable compiler
16475 #endif
16476 typedef int dummy;
16477
16478 _ACEOF
16479 if ac_fn_c_try_compile "$LINENO"; then :
16480
16481 # Check for potential -arch flags. It is not universal unless
16482 # there are at least two -arch flags with different values.
16483 ac_arch=
16484 ac_prev=
16485 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16486 if test -n "$ac_prev"; then
16487 case $ac_word in
16488 i?86 | x86_64 | ppc | ppc64)
16489 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16490 ac_arch=$ac_word
16491 else
16492 ac_cv_c_bigendian=universal
16493 break
16494 fi
16495 ;;
16496 esac
16497 ac_prev=
16498 elif test "x$ac_word" = "x-arch"; then
16499 ac_prev=arch
16500 fi
16501 done
16502 fi
16503 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16504 if test $ac_cv_c_bigendian = unknown; then
16505 # See if sys/param.h defines the BYTE_ORDER macro.
16506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16507 /* end confdefs.h. */
16508 #include <sys/types.h>
16509 #include <sys/param.h>
16510
16511 int
16512 main ()
16513 {
16514 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16515 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16516 && LITTLE_ENDIAN)
16517 bogus endian macros
16518 #endif
16519
16520 ;
16521 return 0;
16522 }
16523 _ACEOF
16524 if ac_fn_c_try_compile "$LINENO"; then :
16525 # It does; now see whether it defined to BIG_ENDIAN or not.
16526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16527 /* end confdefs.h. */
16528 #include <sys/types.h>
16529 #include <sys/param.h>
16530
16531 int
16532 main ()
16533 {
16534 #if BYTE_ORDER != BIG_ENDIAN
16535 not big endian
16536 #endif
16537
16538 ;
16539 return 0;
16540 }
16541 _ACEOF
16542 if ac_fn_c_try_compile "$LINENO"; then :
16543 ac_cv_c_bigendian=yes
16544 else
16545 ac_cv_c_bigendian=no
16546 fi
16547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16548 fi
16549 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16550 fi
16551 if test $ac_cv_c_bigendian = unknown; then
16552 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16554 /* end confdefs.h. */
16555 #include <limits.h>
16556
16557 int
16558 main ()
16559 {
16560 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16561 bogus endian macros
16562 #endif
16563
16564 ;
16565 return 0;
16566 }
16567 _ACEOF
16568 if ac_fn_c_try_compile "$LINENO"; then :
16569 # It does; now see whether it defined to _BIG_ENDIAN or not.
16570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16571 /* end confdefs.h. */
16572 #include <limits.h>
16573
16574 int
16575 main ()
16576 {
16577 #ifndef _BIG_ENDIAN
16578 not big endian
16579 #endif
16580
16581 ;
16582 return 0;
16583 }
16584 _ACEOF
16585 if ac_fn_c_try_compile "$LINENO"; then :
16586 ac_cv_c_bigendian=yes
16587 else
16588 ac_cv_c_bigendian=no
16589 fi
16590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16591 fi
16592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16593 fi
16594 if test $ac_cv_c_bigendian = unknown; then
16595 # Compile a test program.
16596 if test "$cross_compiling" = yes; then :
16597 # Try to guess by grepping values from an object file.
16598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16599 /* end confdefs.h. */
16600 short int ascii_mm[] =
16601 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16602 short int ascii_ii[] =
16603 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16604 int use_ascii (int i) {
16605 return ascii_mm[i] + ascii_ii[i];
16606 }
16607 short int ebcdic_ii[] =
16608 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16609 short int ebcdic_mm[] =
16610 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16611 int use_ebcdic (int i) {
16612 return ebcdic_mm[i] + ebcdic_ii[i];
16613 }
16614 extern int foo;
16615
16616 int
16617 main ()
16618 {
16619 return use_ascii (foo) == use_ebcdic (foo);
16620 ;
16621 return 0;
16622 }
16623 _ACEOF
16624 if ac_fn_c_try_compile "$LINENO"; then :
16625 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16626 ac_cv_c_bigendian=yes
16627 fi
16628 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16629 if test "$ac_cv_c_bigendian" = unknown; then
16630 ac_cv_c_bigendian=no
16631 else
16632 # finding both strings is unlikely to happen, but who knows?
16633 ac_cv_c_bigendian=unknown
16634 fi
16635 fi
16636 fi
16637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16638 else
16639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16640 /* end confdefs.h. */
16641 $ac_includes_default
16642 int
16643 main ()
16644 {
16645
16646 /* Are we little or big endian? From Harbison&Steele. */
16647 union
16648 {
16649 long int l;
16650 char c[sizeof (long int)];
16651 } u;
16652 u.l = 1;
16653 return u.c[sizeof (long int) - 1] == 1;
16654
16655 ;
16656 return 0;
16657 }
16658 _ACEOF
16659 if ac_fn_c_try_run "$LINENO"; then :
16660 ac_cv_c_bigendian=no
16661 else
16662 ac_cv_c_bigendian=yes
16663 fi
16664 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16665 conftest.$ac_objext conftest.beam conftest.$ac_ext
16666 fi
16667
16668 fi
16669 fi
16670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16671 $as_echo "$ac_cv_c_bigendian" >&6; }
16672 case $ac_cv_c_bigendian in #(
16673 yes)
16674 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16675 ;; #(
16676 no)
16677 ;; #(
16678 universal)
16679
16680 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16681
16682 ;; #(
16683 *)
16684 as_fn_error "unknown endianness
16685 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16686 esac
16687
16688
16689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16690 $as_echo_n "checking for inline... " >&6; }
16691 if test "${ac_cv_c_inline+set}" = set; then :
16692 $as_echo_n "(cached) " >&6
16693 else
16694 ac_cv_c_inline=no
16695 for ac_kw in inline __inline__ __inline; do
16696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16697 /* end confdefs.h. */
16698 #ifndef __cplusplus
16699 typedef int foo_t;
16700 static $ac_kw foo_t static_foo () {return 0; }
16701 $ac_kw foo_t foo () {return 0; }
16702 #endif
16703
16704 _ACEOF
16705 if ac_fn_c_try_compile "$LINENO"; then :
16706 ac_cv_c_inline=$ac_kw
16707 fi
16708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16709 test "$ac_cv_c_inline" != no && break
16710 done
16711
16712 fi
16713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16714 $as_echo "$ac_cv_c_inline" >&6; }
16715
16716 case $ac_cv_c_inline in
16717 inline | yes) ;;
16718 *)
16719 case $ac_cv_c_inline in
16720 no) ac_val=;;
16721 *) ac_val=$ac_cv_c_inline;;
16722 esac
16723 cat >>confdefs.h <<_ACEOF
16724 #ifndef __cplusplus
16725 #define inline $ac_val
16726 #endif
16727 _ACEOF
16728 ;;
16729 esac
16730
16731
16732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16733 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16734 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16735 $as_echo_n "(cached) " >&6
16736 else
16737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16738 /* end confdefs.h. */
16739 /* On HP-UX before 11.23, strtold returns a struct instead of
16740 long double. Reject implementations like that, by requiring
16741 compatibility with the C99 prototype. */
16742 #include <stdlib.h>
16743 static long double (*p) (char const *, char **) = strtold;
16744 static long double
16745 test (char const *nptr, char **endptr)
16746 {
16747 long double r;
16748 r = strtold (nptr, endptr);
16749 return r;
16750 }
16751 int
16752 main ()
16753 {
16754 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16755 ;
16756 return 0;
16757 }
16758 _ACEOF
16759 if ac_fn_c_try_link "$LINENO"; then :
16760 gl_cv_func_c99_strtold=yes
16761 else
16762 gl_cv_func_c99_strtold=no
16763 fi
16764 rm -f core conftest.err conftest.$ac_objext \
16765 conftest$ac_exeext conftest.$ac_ext
16766 fi
16767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16768 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16769 if test $gl_cv_func_c99_strtold = yes; then
16770
16771 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16772
16773 fi
16774
16775
16776 GNULIB_CHDIR=0;
16777 GNULIB_CHOWN=0;
16778 GNULIB_CLOSE=0;
16779 GNULIB_DUP=0;
16780 GNULIB_DUP2=0;
16781 GNULIB_DUP3=0;
16782 GNULIB_ENVIRON=0;
16783 GNULIB_EUIDACCESS=0;
16784 GNULIB_FACCESSAT=0;
16785 GNULIB_FCHDIR=0;
16786 GNULIB_FCHOWNAT=0;
16787 GNULIB_FDATASYNC=0;
16788 GNULIB_FSYNC=0;
16789 GNULIB_FTRUNCATE=0;
16790 GNULIB_GETCWD=0;
16791 GNULIB_GETDOMAINNAME=0;
16792 GNULIB_GETDTABLESIZE=0;
16793 GNULIB_GETGROUPS=0;
16794 GNULIB_GETHOSTNAME=0;
16795 GNULIB_GETLOGIN=0;
16796 GNULIB_GETLOGIN_R=0;
16797 GNULIB_GETPAGESIZE=0;
16798 GNULIB_GETUSERSHELL=0;
16799 GNULIB_GROUP_MEMBER=0;
16800 GNULIB_ISATTY=0;
16801 GNULIB_LCHOWN=0;
16802 GNULIB_LINK=0;
16803 GNULIB_LINKAT=0;
16804 GNULIB_LSEEK=0;
16805 GNULIB_PIPE=0;
16806 GNULIB_PIPE2=0;
16807 GNULIB_PREAD=0;
16808 GNULIB_PWRITE=0;
16809 GNULIB_READ=0;
16810 GNULIB_READLINK=0;
16811 GNULIB_READLINKAT=0;
16812 GNULIB_RMDIR=0;
16813 GNULIB_SETHOSTNAME=0;
16814 GNULIB_SLEEP=0;
16815 GNULIB_SYMLINK=0;
16816 GNULIB_SYMLINKAT=0;
16817 GNULIB_TTYNAME_R=0;
16818 GNULIB_UNISTD_H_NONBLOCKING=0;
16819 GNULIB_UNISTD_H_SIGPIPE=0;
16820 GNULIB_UNLINK=0;
16821 GNULIB_UNLINKAT=0;
16822 GNULIB_USLEEP=0;
16823 GNULIB_WRITE=0;
16824 HAVE_CHOWN=1;
16825 HAVE_DUP2=1;
16826 HAVE_DUP3=1;
16827 HAVE_EUIDACCESS=1;
16828 HAVE_FACCESSAT=1;
16829 HAVE_FCHDIR=1;
16830 HAVE_FCHOWNAT=1;
16831 HAVE_FDATASYNC=1;
16832 HAVE_FSYNC=1;
16833 HAVE_FTRUNCATE=1;
16834 HAVE_GETDTABLESIZE=1;
16835 HAVE_GETGROUPS=1;
16836 HAVE_GETHOSTNAME=1;
16837 HAVE_GETLOGIN=1;
16838 HAVE_GETPAGESIZE=1;
16839 HAVE_GROUP_MEMBER=1;
16840 HAVE_LCHOWN=1;
16841 HAVE_LINK=1;
16842 HAVE_LINKAT=1;
16843 HAVE_PIPE=1;
16844 HAVE_PIPE2=1;
16845 HAVE_PREAD=1;
16846 HAVE_PWRITE=1;
16847 HAVE_READLINK=1;
16848 HAVE_READLINKAT=1;
16849 HAVE_SETHOSTNAME=1;
16850 HAVE_SLEEP=1;
16851 HAVE_SYMLINK=1;
16852 HAVE_SYMLINKAT=1;
16853 HAVE_UNLINKAT=1;
16854 HAVE_USLEEP=1;
16855 HAVE_DECL_ENVIRON=1;
16856 HAVE_DECL_FCHDIR=1;
16857 HAVE_DECL_FDATASYNC=1;
16858 HAVE_DECL_GETDOMAINNAME=1;
16859 HAVE_DECL_GETLOGIN_R=1;
16860 HAVE_DECL_GETPAGESIZE=1;
16861 HAVE_DECL_GETUSERSHELL=1;
16862 HAVE_DECL_SETHOSTNAME=1;
16863 HAVE_DECL_TTYNAME_R=1;
16864 HAVE_OS_H=0;
16865 HAVE_SYS_PARAM_H=0;
16866 REPLACE_CHOWN=0;
16867 REPLACE_CLOSE=0;
16868 REPLACE_DUP=0;
16869 REPLACE_DUP2=0;
16870 REPLACE_FCHOWNAT=0;
16871 REPLACE_FTRUNCATE=0;
16872 REPLACE_GETCWD=0;
16873 REPLACE_GETDOMAINNAME=0;
16874 REPLACE_GETLOGIN_R=0;
16875 REPLACE_GETGROUPS=0;
16876 REPLACE_GETPAGESIZE=0;
16877 REPLACE_ISATTY=0;
16878 REPLACE_LCHOWN=0;
16879 REPLACE_LINK=0;
16880 REPLACE_LINKAT=0;
16881 REPLACE_LSEEK=0;
16882 REPLACE_PREAD=0;
16883 REPLACE_PWRITE=0;
16884 REPLACE_READ=0;
16885 REPLACE_READLINK=0;
16886 REPLACE_RMDIR=0;
16887 REPLACE_SLEEP=0;
16888 REPLACE_SYMLINK=0;
16889 REPLACE_TTYNAME_R=0;
16890 REPLACE_UNLINK=0;
16891 REPLACE_UNLINKAT=0;
16892 REPLACE_USLEEP=0;
16893 REPLACE_WRITE=0;
16894 UNISTD_H_HAVE_WINSOCK2_H=0;
16895 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16896
16897
16898
16899
16900
16901
16902
16903
16904
16905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16906 $as_echo_n "checking if environ is properly declared... " >&6; }
16907 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16908 $as_echo_n "(cached) " >&6
16909 else
16910
16911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16912 /* end confdefs.h. */
16913 #if HAVE_UNISTD_H
16914 #include <unistd.h>
16915 #endif
16916 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16917 #include <stdlib.h>
16918
16919 extern struct { int foo; } environ;
16920 int
16921 main ()
16922 {
16923 environ.foo = 1;
16924 ;
16925 return 0;
16926 }
16927 _ACEOF
16928 if ac_fn_c_try_compile "$LINENO"; then :
16929 gt_cv_var_environ_declaration=no
16930 else
16931 gt_cv_var_environ_declaration=yes
16932 fi
16933 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16934 fi
16935
16936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16937 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16938 if test $gt_cv_var_environ_declaration = yes; then
16939
16940 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16941
16942 fi
16943
16944
16945 if test $gt_cv_var_environ_declaration != yes; then
16946 HAVE_DECL_ENVIRON=0
16947 fi
16948
16949
16950
16951
16952
16953
16954
16955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16956 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16957 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16958 $as_echo_n "(cached) " >&6
16959 else
16960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16961 /* end confdefs.h. */
16962
16963 #include <sys/types.h>
16964 #include <sys/stat.h>
16965 int
16966 main ()
16967 {
16968 struct stat s; s.st_dm_mode;
16969 ;
16970 return 0;
16971 }
16972 _ACEOF
16973 if ac_fn_c_try_compile "$LINENO"; then :
16974 ac_cv_struct_st_dm_mode=yes
16975 else
16976 ac_cv_struct_st_dm_mode=no
16977 fi
16978 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16979 fi
16980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16981 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16982
16983 if test $ac_cv_struct_st_dm_mode = yes; then
16984
16985 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16986
16987 fi
16988
16989
16990 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16991 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16992 ac_have_decl=1
16993 else
16994 ac_have_decl=0
16995 fi
16996
16997 cat >>confdefs.h <<_ACEOF
16998 #define HAVE_DECL_STRMODE $ac_have_decl
16999 _ACEOF
17000
17001
17002 GNULIB__EXIT=0;
17003 GNULIB_ATOLL=0;
17004 GNULIB_CALLOC_POSIX=0;
17005 GNULIB_CANONICALIZE_FILE_NAME=0;
17006 GNULIB_GETLOADAVG=0;
17007 GNULIB_GETSUBOPT=0;
17008 GNULIB_GRANTPT=0;
17009 GNULIB_MALLOC_POSIX=0;
17010 GNULIB_MBTOWC=0;
17011 GNULIB_MKDTEMP=0;
17012 GNULIB_MKOSTEMP=0;
17013 GNULIB_MKOSTEMPS=0;
17014 GNULIB_MKSTEMP=0;
17015 GNULIB_MKSTEMPS=0;
17016 GNULIB_POSIX_OPENPT=0;
17017 GNULIB_PTSNAME=0;
17018 GNULIB_PTSNAME_R=0;
17019 GNULIB_PUTENV=0;
17020 GNULIB_RANDOM=0;
17021 GNULIB_RANDOM_R=0;
17022 GNULIB_REALLOC_POSIX=0;
17023 GNULIB_REALPATH=0;
17024 GNULIB_RPMATCH=0;
17025 GNULIB_SETENV=0;
17026 GNULIB_STRTOD=0;
17027 GNULIB_STRTOLL=0;
17028 GNULIB_STRTOULL=0;
17029 GNULIB_SYSTEM_POSIX=0;
17030 GNULIB_UNLOCKPT=0;
17031 GNULIB_UNSETENV=0;
17032 GNULIB_WCTOMB=0;
17033 HAVE__EXIT=1;
17034 HAVE_ATOLL=1;
17035 HAVE_CANONICALIZE_FILE_NAME=1;
17036 HAVE_DECL_GETLOADAVG=1;
17037 HAVE_GETSUBOPT=1;
17038 HAVE_GRANTPT=1;
17039 HAVE_MKDTEMP=1;
17040 HAVE_MKOSTEMP=1;
17041 HAVE_MKOSTEMPS=1;
17042 HAVE_MKSTEMP=1;
17043 HAVE_MKSTEMPS=1;
17044 HAVE_POSIX_OPENPT=1;
17045 HAVE_PTSNAME=1;
17046 HAVE_PTSNAME_R=1;
17047 HAVE_RANDOM=1;
17048 HAVE_RANDOM_H=1;
17049 HAVE_RANDOM_R=1;
17050 HAVE_REALPATH=1;
17051 HAVE_RPMATCH=1;
17052 HAVE_SETENV=1;
17053 HAVE_DECL_SETENV=1;
17054 HAVE_STRTOD=1;
17055 HAVE_STRTOLL=1;
17056 HAVE_STRTOULL=1;
17057 HAVE_STRUCT_RANDOM_DATA=1;
17058 HAVE_SYS_LOADAVG_H=0;
17059 HAVE_UNLOCKPT=1;
17060 HAVE_DECL_UNSETENV=1;
17061 REPLACE_CALLOC=0;
17062 REPLACE_CANONICALIZE_FILE_NAME=0;
17063 REPLACE_MALLOC=0;
17064 REPLACE_MBTOWC=0;
17065 REPLACE_MKSTEMP=0;
17066 REPLACE_PTSNAME=0;
17067 REPLACE_PTSNAME_R=0;
17068 REPLACE_PUTENV=0;
17069 REPLACE_RANDOM_R=0;
17070 REPLACE_REALLOC=0;
17071 REPLACE_REALPATH=0;
17072 REPLACE_SETENV=0;
17073 REPLACE_STRTOD=0;
17074 REPLACE_UNSETENV=0;
17075 REPLACE_WCTOMB=0;
17076
17077
17078
17079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
17080 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
17081 if test "${gl_cv_have_include_next+set}" = set; then :
17082 $as_echo_n "(cached) " >&6
17083 else
17084 rm -rf conftestd1a conftestd1b conftestd2
17085 mkdir conftestd1a conftestd1b conftestd2
17086 cat <<EOF > conftestd1a/conftest.h
17087 #define DEFINED_IN_CONFTESTD1
17088 #include_next <conftest.h>
17089 #ifdef DEFINED_IN_CONFTESTD2
17090 int foo;
17091 #else
17092 #error "include_next doesn't work"
17093 #endif
17094 EOF
17095 cat <<EOF > conftestd1b/conftest.h
17096 #define DEFINED_IN_CONFTESTD1
17097 #include <stdio.h>
17098 #include_next <conftest.h>
17099 #ifdef DEFINED_IN_CONFTESTD2
17100 int foo;
17101 #else
17102 #error "include_next doesn't work"
17103 #endif
17104 EOF
17105 cat <<EOF > conftestd2/conftest.h
17106 #ifndef DEFINED_IN_CONFTESTD1
17107 #error "include_next test doesn't work"
17108 #endif
17109 #define DEFINED_IN_CONFTESTD2
17110 EOF
17111 gl_save_CPPFLAGS="$CPPFLAGS"
17112 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17114 /* end confdefs.h. */
17115 #include <conftest.h>
17116 _ACEOF
17117 if ac_fn_c_try_compile "$LINENO"; then :
17118 gl_cv_have_include_next=yes
17119 else
17120 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
17121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17122 /* end confdefs.h. */
17123 #include <conftest.h>
17124 _ACEOF
17125 if ac_fn_c_try_compile "$LINENO"; then :
17126 gl_cv_have_include_next=buggy
17127 else
17128 gl_cv_have_include_next=no
17129 fi
17130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17131
17132 fi
17133 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17134 CPPFLAGS="$gl_save_CPPFLAGS"
17135 rm -rf conftestd1a conftestd1b conftestd2
17136
17137 fi
17138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
17139 $as_echo "$gl_cv_have_include_next" >&6; }
17140 PRAGMA_SYSTEM_HEADER=
17141 if test $gl_cv_have_include_next = yes; then
17142 INCLUDE_NEXT=include_next
17143 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17144 if test -n "$GCC"; then
17145 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
17146 fi
17147 else
17148 if test $gl_cv_have_include_next = buggy; then
17149 INCLUDE_NEXT=include
17150 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17151 else
17152 INCLUDE_NEXT=include
17153 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
17154 fi
17155 fi
17156
17157
17158
17159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
17160 $as_echo_n "checking whether system header files limit the line length... " >&6; }
17161 if test "${gl_cv_pragma_columns+set}" = set; then :
17162 $as_echo_n "(cached) " >&6
17163 else
17164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17165 /* end confdefs.h. */
17166
17167 #ifdef __TANDEM
17168 choke me
17169 #endif
17170
17171 _ACEOF
17172 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17173 $EGREP "choke me" >/dev/null 2>&1; then :
17174 gl_cv_pragma_columns=yes
17175 else
17176 gl_cv_pragma_columns=no
17177 fi
17178 rm -f conftest*
17179
17180
17181 fi
17182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
17183 $as_echo "$gl_cv_pragma_columns" >&6; }
17184 if test $gl_cv_pragma_columns = yes; then
17185 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
17186 else
17187 PRAGMA_COLUMNS=
17188 fi
17189
17190
17191
17192
17193
17194
17195
17196
17197
17198
17199
17200
17201
17202
17203
17204
17205
17206 if test $gl_cv_have_include_next = yes; then
17207 gl_cv_next_getopt_h='<'getopt.h'>'
17208 else
17209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
17210 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
17211 if test "${gl_cv_next_getopt_h+set}" = set; then :
17212 $as_echo_n "(cached) " >&6
17213 else
17214
17215 if test $ac_cv_header_getopt_h = yes; then
17216
17217
17218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17219 /* end confdefs.h. */
17220 #include <getopt.h>
17221
17222 _ACEOF
17223 case "$host_os" in
17224 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17225 *) gl_absname_cpp="$ac_cpp" ;;
17226 esac
17227
17228 case "$host_os" in
17229 mingw*)
17230 gl_dirsep_regex='[/\\]'
17231 ;;
17232 *)
17233 gl_dirsep_regex='\/'
17234 ;;
17235 esac
17236 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17237
17238 gl_header_literal_regex=`echo 'getopt.h' \
17239 | sed -e "$gl_make_literal_regex_sed"`
17240 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17241 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17242 s|^/[^/]|//&|
17243 p
17244 q
17245 }'
17246 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17247 sed -n "$gl_absolute_header_sed"`'"'
17248 else
17249 gl_cv_next_getopt_h='<'getopt.h'>'
17250 fi
17251
17252
17253 fi
17254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
17255 $as_echo "$gl_cv_next_getopt_h" >&6; }
17256 fi
17257 NEXT_GETOPT_H=$gl_cv_next_getopt_h
17258
17259 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17260 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17261 gl_next_as_first_directive='<'getopt.h'>'
17262 else
17263 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17264 gl_next_as_first_directive=$gl_cv_next_getopt_h
17265 fi
17266 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
17267
17268
17269
17270
17271 if test $ac_cv_header_getopt_h = yes; then
17272 HAVE_GETOPT_H=1
17273 else
17274 HAVE_GETOPT_H=0
17275 fi
17276
17277
17278 gl_replace_getopt=
17279
17280 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17281 for ac_header in getopt.h
17282 do :
17283 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
17284 if test "x$ac_cv_header_getopt_h" = x""yes; then :
17285 cat >>confdefs.h <<_ACEOF
17286 #define HAVE_GETOPT_H 1
17287 _ACEOF
17288
17289 else
17290 gl_replace_getopt=yes
17291 fi
17292
17293 done
17294
17295 fi
17296
17297 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17298 for ac_func in getopt_long_only
17299 do :
17300 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
17301 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
17302 cat >>confdefs.h <<_ACEOF
17303 #define HAVE_GETOPT_LONG_ONLY 1
17304 _ACEOF
17305
17306 else
17307 gl_replace_getopt=yes
17308 fi
17309 done
17310
17311 fi
17312
17313 if test -z "$gl_replace_getopt"; then
17314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17315 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17316 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17317 $as_echo_n "(cached) " >&6
17318 else
17319
17320 if test $cross_compiling = no; then
17321 if test "$cross_compiling" = yes; then :
17322 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17323 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17324 as_fn_error "cannot run test program while cross compiling
17325 See \`config.log' for more details." "$LINENO" 5; }
17326 else
17327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17328 /* end confdefs.h. */
17329
17330 #include <unistd.h>
17331 #include <stdlib.h>
17332 #include <string.h>
17333
17334 int
17335 main ()
17336 {
17337 static char program[] = "program";
17338 static char a[] = "-a";
17339 static char foo[] = "foo";
17340 static char bar[] = "bar";
17341 char *argv[] = { program, a, foo, bar, NULL };
17342 int c;
17343
17344 c = getopt (4, argv, "ab");
17345 if (!(c == 'a'))
17346 return 1;
17347 c = getopt (4, argv, "ab");
17348 if (!(c == -1))
17349 return 2;
17350 if (!(optind == 2))
17351 return 3;
17352 return 0;
17353 }
17354
17355 _ACEOF
17356 if ac_fn_c_try_run "$LINENO"; then :
17357 gl_cv_func_getopt_posix=maybe
17358 else
17359 gl_cv_func_getopt_posix=no
17360 fi
17361 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17362 conftest.$ac_objext conftest.beam conftest.$ac_ext
17363 fi
17364
17365 if test $gl_cv_func_getopt_posix = maybe; then
17366 if test "$cross_compiling" = yes; then :
17367 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17368 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17369 as_fn_error "cannot run test program while cross compiling
17370 See \`config.log' for more details." "$LINENO" 5; }
17371 else
17372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17373 /* end confdefs.h. */
17374
17375 #include <unistd.h>
17376 #include <stdlib.h>
17377 #include <string.h>
17378
17379 int
17380 main ()
17381 {
17382 static char program[] = "program";
17383 static char donald[] = "donald";
17384 static char p[] = "-p";
17385 static char billy[] = "billy";
17386 static char duck[] = "duck";
17387 static char a[] = "-a";
17388 static char bar[] = "bar";
17389 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17390 int c;
17391
17392 c = getopt (7, argv, "+abp:q:");
17393 if (!(c == -1))
17394 return 4;
17395 if (!(strcmp (argv[0], "program") == 0))
17396 return 5;
17397 if (!(strcmp (argv[1], "donald") == 0))
17398 return 6;
17399 if (!(strcmp (argv[2], "-p") == 0))
17400 return 7;
17401 if (!(strcmp (argv[3], "billy") == 0))
17402 return 8;
17403 if (!(strcmp (argv[4], "duck") == 0))
17404 return 9;
17405 if (!(strcmp (argv[5], "-a") == 0))
17406 return 10;
17407 if (!(strcmp (argv[6], "bar") == 0))
17408 return 11;
17409 if (!(optind == 1))
17410 return 12;
17411 return 0;
17412 }
17413
17414 _ACEOF
17415 if ac_fn_c_try_run "$LINENO"; then :
17416 gl_cv_func_getopt_posix=maybe
17417 else
17418 gl_cv_func_getopt_posix=no
17419 fi
17420 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17421 conftest.$ac_objext conftest.beam conftest.$ac_ext
17422 fi
17423
17424 fi
17425 if test $gl_cv_func_getopt_posix = maybe; then
17426 if test "$cross_compiling" = yes; then :
17427 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17428 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17429 as_fn_error "cannot run test program while cross compiling
17430 See \`config.log' for more details." "$LINENO" 5; }
17431 else
17432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17433 /* end confdefs.h. */
17434
17435 #include <unistd.h>
17436 #include <stdlib.h>
17437 #include <string.h>
17438
17439 int
17440 main ()
17441 {
17442 static char program[] = "program";
17443 static char ab[] = "-ab";
17444 char *argv[3] = { program, ab, NULL };
17445 if (getopt (2, argv, "ab:") != 'a')
17446 return 13;
17447 if (getopt (2, argv, "ab:") != '?')
17448 return 14;
17449 if (optopt != 'b')
17450 return 15;
17451 if (optind != 2)
17452 return 16;
17453 return 0;
17454 }
17455
17456 _ACEOF
17457 if ac_fn_c_try_run "$LINENO"; then :
17458 gl_cv_func_getopt_posix=yes
17459 else
17460 gl_cv_func_getopt_posix=no
17461 fi
17462 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17463 conftest.$ac_objext conftest.beam conftest.$ac_ext
17464 fi
17465
17466 fi
17467 else
17468 case "$host_os" in
17469 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17470 *) gl_cv_func_getopt_posix="guessing yes";;
17471 esac
17472 fi
17473
17474 fi
17475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17476 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17477 case "$gl_cv_func_getopt_posix" in
17478 *no) gl_replace_getopt=yes ;;
17479 esac
17480 fi
17481
17482 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17484 $as_echo_n "checking for working GNU getopt function... " >&6; }
17485 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17486 $as_echo_n "(cached) " >&6
17487 else
17488 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17489 # optstring is necessary for programs like m4 that have POSIX-mandated
17490 # semantics for supporting options interspersed with files.
17491 # Also, since getopt_long is a GNU extension, we require optind=0.
17492 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17493 # so take care to revert to the correct (non-)export state.
17494 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17495 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17496 xx) gl_had_POSIXLY_CORRECT=exported ;;
17497 x) gl_had_POSIXLY_CORRECT=yes ;;
17498 *) gl_had_POSIXLY_CORRECT= ;;
17499 esac
17500 POSIXLY_CORRECT=1
17501 export POSIXLY_CORRECT
17502 if test "$cross_compiling" = yes; then :
17503 gl_cv_func_getopt_gnu="guessing no"
17504
17505 else
17506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17507 /* end confdefs.h. */
17508 #include <getopt.h>
17509 #include <stddef.h>
17510 #include <string.h>
17511
17512 #include <stdlib.h>
17513 #if defined __MACH__ && defined __APPLE__
17514 /* Avoid a crash on Mac OS X. */
17515 #include <mach/mach.h>
17516 #include <mach/mach_error.h>
17517 #include <mach/thread_status.h>
17518 #include <mach/exception.h>
17519 #include <mach/task.h>
17520 #include <pthread.h>
17521 /* The exception port on which our thread listens. */
17522 static mach_port_t our_exception_port;
17523 /* The main function of the thread listening for exceptions of type
17524 EXC_BAD_ACCESS. */
17525 static void *
17526 mach_exception_thread (void *arg)
17527 {
17528 /* Buffer for a message to be received. */
17529 struct {
17530 mach_msg_header_t head;
17531 mach_msg_body_t msgh_body;
17532 char data[1024];
17533 } msg;
17534 mach_msg_return_t retval;
17535 /* Wait for a message on the exception port. */
17536 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17537 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17538 if (retval != MACH_MSG_SUCCESS)
17539 abort ();
17540 exit (1);
17541 }
17542 static void
17543 nocrash_init (void)
17544 {
17545 mach_port_t self = mach_task_self ();
17546 /* Allocate a port on which the thread shall listen for exceptions. */
17547 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17548 == KERN_SUCCESS) {
17549 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17550 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17551 MACH_MSG_TYPE_MAKE_SEND)
17552 == KERN_SUCCESS) {
17553 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17554 for us. */
17555 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17556 /* Create the thread listening on the exception port. */
17557 pthread_attr_t attr;
17558 pthread_t thread;
17559 if (pthread_attr_init (&attr) == 0
17560 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17561 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17562 pthread_attr_destroy (&attr);
17563 /* Replace the exception port info for these exceptions with our own.
17564 Note that we replace the exception port for the entire task, not only
17565 for a particular thread. This has the effect that when our exception
17566 port gets the message, the thread specific exception port has already
17567 been asked, and we don't need to bother about it.
17568 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17569 task_set_exception_ports (self, mask, our_exception_port,
17570 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17571 }
17572 }
17573 }
17574 }
17575 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17576 /* Avoid a crash on native Windows. */
17577 #define WIN32_LEAN_AND_MEAN
17578 #include <windows.h>
17579 #include <winerror.h>
17580 static LONG WINAPI
17581 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17582 {
17583 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17584 {
17585 case EXCEPTION_ACCESS_VIOLATION:
17586 case EXCEPTION_IN_PAGE_ERROR:
17587 case EXCEPTION_STACK_OVERFLOW:
17588 case EXCEPTION_GUARD_PAGE:
17589 case EXCEPTION_PRIV_INSTRUCTION:
17590 case EXCEPTION_ILLEGAL_INSTRUCTION:
17591 case EXCEPTION_DATATYPE_MISALIGNMENT:
17592 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17593 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17594 exit (1);
17595 }
17596 return EXCEPTION_CONTINUE_SEARCH;
17597 }
17598 static void
17599 nocrash_init (void)
17600 {
17601 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17602 }
17603 #else
17604 /* Avoid a crash on POSIX systems. */
17605 #include <signal.h>
17606 /* A POSIX signal handler. */
17607 static void
17608 exception_handler (int sig)
17609 {
17610 exit (1);
17611 }
17612 static void
17613 nocrash_init (void)
17614 {
17615 #ifdef SIGSEGV
17616 signal (SIGSEGV, exception_handler);
17617 #endif
17618 #ifdef SIGBUS
17619 signal (SIGBUS, exception_handler);
17620 #endif
17621 }
17622 #endif
17623
17624
17625 int
17626 main ()
17627 {
17628
17629 int result = 0;
17630
17631 nocrash_init();
17632
17633 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17634 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17635 OSF/1 5.1, Solaris 10. */
17636 {
17637 static char conftest[] = "conftest";
17638 static char plus[] = "-+";
17639 char *argv[3] = { conftest, plus, NULL };
17640 opterr = 0;
17641 if (getopt (2, argv, "+a") != '?')
17642 result |= 1;
17643 }
17644 /* This code succeeds on glibc 2.8, mingw,
17645 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17646 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17647 {
17648 static char program[] = "program";
17649 static char p[] = "-p";
17650 static char foo[] = "foo";
17651 static char bar[] = "bar";
17652 char *argv[] = { program, p, foo, bar, NULL };
17653
17654 optind = 1;
17655 if (getopt (4, argv, "p::") != 'p')
17656 result |= 2;
17657 else if (optarg != NULL)
17658 result |= 4;
17659 else if (getopt (4, argv, "p::") != -1)
17660 result |= 6;
17661 else if (optind != 2)
17662 result |= 8;
17663 }
17664 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17665 {
17666 static char program[] = "program";
17667 static char foo[] = "foo";
17668 static char p[] = "-p";
17669 char *argv[] = { program, foo, p, NULL };
17670 optind = 0;
17671 if (getopt (3, argv, "-p") != 1)
17672 result |= 16;
17673 else if (getopt (3, argv, "-p") != 'p')
17674 result |= 16;
17675 }
17676 /* This code fails on glibc 2.11. */
17677 {
17678 static char program[] = "program";
17679 static char b[] = "-b";
17680 static char a[] = "-a";
17681 char *argv[] = { program, b, a, NULL };
17682 optind = opterr = 0;
17683 if (getopt (3, argv, "+:a:b") != 'b')
17684 result |= 32;
17685 else if (getopt (3, argv, "+:a:b") != ':')
17686 result |= 32;
17687 }
17688 /* This code dumps core on glibc 2.14. */
17689 {
17690 static char program[] = "program";
17691 static char w[] = "-W";
17692 static char dummy[] = "dummy";
17693 char *argv[] = { program, w, dummy, NULL };
17694 optind = opterr = 1;
17695 if (getopt (3, argv, "W;") != 'W')
17696 result |= 64;
17697 }
17698 return result;
17699
17700 ;
17701 return 0;
17702 }
17703 _ACEOF
17704 if ac_fn_c_try_run "$LINENO"; then :
17705 gl_cv_func_getopt_gnu=yes
17706 else
17707 gl_cv_func_getopt_gnu=no
17708 fi
17709 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17710 conftest.$ac_objext conftest.beam conftest.$ac_ext
17711 fi
17712
17713 case $gl_had_POSIXLY_CORRECT in
17714 exported) ;;
17715 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17716 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17717 esac
17718
17719 fi
17720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17721 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17722 if test "$gl_cv_func_getopt_gnu" != yes; then
17723 gl_replace_getopt=yes
17724 else
17725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17726 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17727 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17728 $as_echo_n "(cached) " >&6
17729 else
17730 if test "$cross_compiling" = yes; then :
17731 case "$host_os" in
17732 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17733 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17734 esac
17735
17736 else
17737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17738 /* end confdefs.h. */
17739 #include <getopt.h>
17740 #include <stddef.h>
17741 #include <string.h>
17742
17743 int
17744 main ()
17745 {
17746 static const struct option long_options[] =
17747 {
17748 { "xtremely-",no_argument, NULL, 1003 },
17749 { "xtra", no_argument, NULL, 1001 },
17750 { "xtreme", no_argument, NULL, 1002 },
17751 { "xtremely", no_argument, NULL, 1003 },
17752 { NULL, 0, NULL, 0 }
17753 };
17754 /* This code fails on OpenBSD 5.0. */
17755 {
17756 static char program[] = "program";
17757 static char xtremel[] = "--xtremel";
17758 char *argv[] = { program, xtremel, NULL };
17759 int option_index;
17760 optind = 1; opterr = 0;
17761 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17762 return 1;
17763 }
17764 return 0;
17765
17766 ;
17767 return 0;
17768 }
17769 _ACEOF
17770 if ac_fn_c_try_run "$LINENO"; then :
17771 gl_cv_func_getopt_long_gnu=yes
17772 else
17773 gl_cv_func_getopt_long_gnu=no
17774 fi
17775 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17776 conftest.$ac_objext conftest.beam conftest.$ac_ext
17777 fi
17778
17779
17780 fi
17781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17782 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17783 case "$gl_cv_func_getopt_long_gnu" in
17784 *yes) ;;
17785 *) gl_replace_getopt=yes ;;
17786 esac
17787 fi
17788 fi
17789
17790
17791
17792
17793
17794
17795 REPLACE_GETOPT=0
17796 if test -n "$gl_replace_getopt"; then
17797 REPLACE_GETOPT=1
17798 fi
17799
17800 if test $REPLACE_GETOPT = 1; then
17801
17802 GETOPT_H=getopt.h
17803
17804 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17805
17806
17807
17808 fi
17809
17810 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17811 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17812 ac_have_decl=1
17813 else
17814 ac_have_decl=0
17815 fi
17816
17817 cat >>confdefs.h <<_ACEOF
17818 #define HAVE_DECL_GETENV $ac_have_decl
17819 _ACEOF
17820
17821 :
17822
17823
17824
17825
17826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17827 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17828 if test "${ac_cv_c_restrict+set}" = set; then :
17829 $as_echo_n "(cached) " >&6
17830 else
17831 ac_cv_c_restrict=no
17832 # The order here caters to the fact that C++ does not require restrict.
17833 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17834 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17835 /* end confdefs.h. */
17836 typedef int * int_ptr;
17837 int foo (int_ptr $ac_kw ip) {
17838 return ip[0];
17839 }
17840 int
17841 main ()
17842 {
17843 int s[1];
17844 int * $ac_kw t = s;
17845 t[0] = 0;
17846 return foo(t)
17847 ;
17848 return 0;
17849 }
17850 _ACEOF
17851 if ac_fn_c_try_compile "$LINENO"; then :
17852 ac_cv_c_restrict=$ac_kw
17853 fi
17854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17855 test "$ac_cv_c_restrict" != no && break
17856 done
17857
17858 fi
17859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17860 $as_echo "$ac_cv_c_restrict" >&6; }
17861
17862 case $ac_cv_c_restrict in
17863 restrict) ;;
17864 no) $as_echo "#define restrict /**/" >>confdefs.h
17865 ;;
17866 *) cat >>confdefs.h <<_ACEOF
17867 #define restrict $ac_cv_c_restrict
17868 _ACEOF
17869 ;;
17870 esac
17871
17872
17873 GNULIB_GETTIMEOFDAY=0;
17874 HAVE_GETTIMEOFDAY=1;
17875 HAVE_STRUCT_TIMEVAL=1;
17876 HAVE_SYS_TIME_H=1;
17877 REPLACE_GETTIMEOFDAY=0;
17878 REPLACE_STRUCT_TIMEVAL=0;
17879
17880
17881
17882
17883
17884
17885
17886
17887
17888
17889
17890
17891
17892
17893
17894
17895 if test $gl_cv_have_include_next = yes; then
17896 gl_cv_next_sys_time_h='<'sys/time.h'>'
17897 else
17898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17899 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17900 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17901 $as_echo_n "(cached) " >&6
17902 else
17903
17904 if test $ac_cv_header_sys_time_h = yes; then
17905
17906
17907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17908 /* end confdefs.h. */
17909 #include <sys/time.h>
17910
17911 _ACEOF
17912 case "$host_os" in
17913 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17914 *) gl_absname_cpp="$ac_cpp" ;;
17915 esac
17916
17917 case "$host_os" in
17918 mingw*)
17919 gl_dirsep_regex='[/\\]'
17920 ;;
17921 *)
17922 gl_dirsep_regex='\/'
17923 ;;
17924 esac
17925 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17926
17927 gl_header_literal_regex=`echo 'sys/time.h' \
17928 | sed -e "$gl_make_literal_regex_sed"`
17929 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17930 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17931 s|^/[^/]|//&|
17932 p
17933 q
17934 }'
17935 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17936 sed -n "$gl_absolute_header_sed"`'"'
17937 else
17938 gl_cv_next_sys_time_h='<'sys/time.h'>'
17939 fi
17940
17941
17942 fi
17943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17944 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17945 fi
17946 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17947
17948 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17949 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17950 gl_next_as_first_directive='<'sys/time.h'>'
17951 else
17952 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17953 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17954 fi
17955 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17956
17957
17958
17959
17960
17961 if test $ac_cv_header_sys_time_h != yes; then
17962 HAVE_SYS_TIME_H=0
17963 fi
17964
17965
17966
17967
17968
17969 if test $ac_cv_header_sys_socket_h != yes; then
17970 for ac_header in winsock2.h
17971 do :
17972 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17973 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17974 cat >>confdefs.h <<_ACEOF
17975 #define HAVE_WINSOCK2_H 1
17976 _ACEOF
17977
17978 fi
17979
17980 done
17981
17982 fi
17983 if test "$ac_cv_header_winsock2_h" = yes; then
17984 HAVE_WINSOCK2_H=1
17985 UNISTD_H_HAVE_WINSOCK2_H=1
17986 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17987 else
17988 HAVE_WINSOCK2_H=0
17989 fi
17990
17991
17992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17993 $as_echo_n "checking for struct timeval... " >&6; }
17994 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17995 $as_echo_n "(cached) " >&6
17996 else
17997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17998 /* end confdefs.h. */
17999 #if HAVE_SYS_TIME_H
18000 #include <sys/time.h>
18001 #endif
18002 #include <time.h>
18003 #if HAVE_WINSOCK2_H
18004 # include <winsock2.h>
18005 #endif
18006
18007 int
18008 main ()
18009 {
18010 static struct timeval x; x.tv_sec = x.tv_usec;
18011 ;
18012 return 0;
18013 }
18014 _ACEOF
18015 if ac_fn_c_try_compile "$LINENO"; then :
18016 gl_cv_sys_struct_timeval=yes
18017 else
18018 gl_cv_sys_struct_timeval=no
18019 fi
18020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18021
18022 fi
18023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
18024 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
18025 if test $gl_cv_sys_struct_timeval != yes; then
18026 HAVE_STRUCT_TIMEVAL=0
18027 else
18028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
18029 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
18030 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
18031 $as_echo_n "(cached) " >&6
18032 else
18033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18034 /* end confdefs.h. */
18035 #if HAVE_SYS_TIME_H
18036 #include <sys/time.h>
18037 #endif
18038 #include <time.h>
18039 #if HAVE_WINSOCK2_H
18040 # include <winsock2.h>
18041 #endif
18042
18043 int
18044 main ()
18045 {
18046 static struct timeval x;
18047 typedef int verify_tv_sec_type[
18048 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
18049 ];
18050
18051 ;
18052 return 0;
18053 }
18054 _ACEOF
18055 if ac_fn_c_try_compile "$LINENO"; then :
18056 gl_cv_sys_struct_timeval_tv_sec=yes
18057 else
18058 gl_cv_sys_struct_timeval_tv_sec=no
18059 fi
18060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18061
18062 fi
18063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
18064 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
18065 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
18066 REPLACE_STRUCT_TIMEVAL=1
18067 fi
18068 fi
18069
18070
18071
18072
18073
18074
18075
18076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
18077 $as_echo_n "checking for unsigned long long int... " >&6; }
18078 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
18079 $as_echo_n "(cached) " >&6
18080 else
18081 ac_cv_type_unsigned_long_long_int=yes
18082 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18084 /* end confdefs.h. */
18085
18086 /* For now, do not test the preprocessor; as of 2007 there are too many
18087 implementations with broken preprocessors. Perhaps this can
18088 be revisited in 2012. In the meantime, code should not expect
18089 #if to work with literals wider than 32 bits. */
18090 /* Test literals. */
18091 long long int ll = 9223372036854775807ll;
18092 long long int nll = -9223372036854775807LL;
18093 unsigned long long int ull = 18446744073709551615ULL;
18094 /* Test constant expressions. */
18095 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
18096 ? 1 : -1)];
18097 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
18098 ? 1 : -1)];
18099 int i = 63;
18100 int
18101 main ()
18102 {
18103 /* Test availability of runtime routines for shift and division. */
18104 long long int llmax = 9223372036854775807ll;
18105 unsigned long long int ullmax = 18446744073709551615ull;
18106 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
18107 | (llmax / ll) | (llmax % ll)
18108 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
18109 | (ullmax / ull) | (ullmax % ull));
18110 ;
18111 return 0;
18112 }
18113
18114 _ACEOF
18115 if ac_fn_c_try_link "$LINENO"; then :
18116
18117 else
18118 ac_cv_type_unsigned_long_long_int=no
18119 fi
18120 rm -f core conftest.err conftest.$ac_objext \
18121 conftest$ac_exeext conftest.$ac_ext
18122 fi
18123 fi
18124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
18125 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
18126 if test $ac_cv_type_unsigned_long_long_int = yes; then
18127
18128 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
18129
18130 fi
18131
18132
18133
18134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
18135 $as_echo_n "checking for long long int... " >&6; }
18136 if test "${ac_cv_type_long_long_int+set}" = set; then :
18137 $as_echo_n "(cached) " >&6
18138 else
18139 ac_cv_type_long_long_int=yes
18140 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
18141 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
18142 if test $ac_cv_type_long_long_int = yes; then
18143 if test "$cross_compiling" = yes; then :
18144 :
18145 else
18146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18147 /* end confdefs.h. */
18148 #include <limits.h>
18149 #ifndef LLONG_MAX
18150 # define HALF \
18151 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
18152 # define LLONG_MAX (HALF - 1 + HALF)
18153 #endif
18154 int
18155 main ()
18156 {
18157 long long int n = 1;
18158 int i;
18159 for (i = 0; ; i++)
18160 {
18161 long long int m = n << i;
18162 if (m >> i != n)
18163 return 1;
18164 if (LLONG_MAX / 2 < m)
18165 break;
18166 }
18167 return 0;
18168 ;
18169 return 0;
18170 }
18171 _ACEOF
18172 if ac_fn_c_try_run "$LINENO"; then :
18173
18174 else
18175 ac_cv_type_long_long_int=no
18176 fi
18177 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18178 conftest.$ac_objext conftest.beam conftest.$ac_ext
18179 fi
18180
18181 fi
18182 fi
18183 fi
18184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
18185 $as_echo "$ac_cv_type_long_long_int" >&6; }
18186 if test $ac_cv_type_long_long_int = yes; then
18187
18188 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
18189
18190 fi
18191
18192
18193
18194
18195
18196
18197 gl_cv_c_multiarch=no
18198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18199 /* end confdefs.h. */
18200 #ifndef __APPLE_CC__
18201 not a universal capable compiler
18202 #endif
18203 typedef int dummy;
18204
18205 _ACEOF
18206 if ac_fn_c_try_compile "$LINENO"; then :
18207
18208 arch=
18209 prev=
18210 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
18211 if test -n "$prev"; then
18212 case $word in
18213 i?86 | x86_64 | ppc | ppc64)
18214 if test -z "$arch" || test "$arch" = "$word"; then
18215 arch="$word"
18216 else
18217 gl_cv_c_multiarch=yes
18218 fi
18219 ;;
18220 esac
18221 prev=
18222 else
18223 if test "x$word" = "x-arch"; then
18224 prev=arch
18225 fi
18226 fi
18227 done
18228
18229 fi
18230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18231 if test $gl_cv_c_multiarch = yes; then
18232 APPLE_UNIVERSAL_BUILD=1
18233 else
18234 APPLE_UNIVERSAL_BUILD=0
18235 fi
18236
18237
18238
18239
18240
18241 if test $ac_cv_type_long_long_int = yes; then
18242 HAVE_LONG_LONG_INT=1
18243 else
18244 HAVE_LONG_LONG_INT=0
18245 fi
18246
18247
18248 if test $ac_cv_type_unsigned_long_long_int = yes; then
18249 HAVE_UNSIGNED_LONG_LONG_INT=1
18250 else
18251 HAVE_UNSIGNED_LONG_LONG_INT=0
18252 fi
18253
18254
18255
18256 if test $ac_cv_header_wchar_h = yes; then
18257 HAVE_WCHAR_H=1
18258 else
18259 HAVE_WCHAR_H=0
18260 fi
18261
18262
18263 if test $ac_cv_header_inttypes_h = yes; then
18264 HAVE_INTTYPES_H=1
18265 else
18266 HAVE_INTTYPES_H=0
18267 fi
18268
18269
18270 if test $ac_cv_header_sys_types_h = yes; then
18271 HAVE_SYS_TYPES_H=1
18272 else
18273 HAVE_SYS_TYPES_H=0
18274 fi
18275
18276
18277
18278
18279
18280
18281
18282
18283
18284
18285
18286 if test $gl_cv_have_include_next = yes; then
18287 gl_cv_next_stdint_h='<'stdint.h'>'
18288 else
18289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
18290 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
18291 if test "${gl_cv_next_stdint_h+set}" = set; then :
18292 $as_echo_n "(cached) " >&6
18293 else
18294
18295 if test $ac_cv_header_stdint_h = yes; then
18296
18297
18298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18299 /* end confdefs.h. */
18300 #include <stdint.h>
18301
18302 _ACEOF
18303 case "$host_os" in
18304 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18305 *) gl_absname_cpp="$ac_cpp" ;;
18306 esac
18307
18308 case "$host_os" in
18309 mingw*)
18310 gl_dirsep_regex='[/\\]'
18311 ;;
18312 *)
18313 gl_dirsep_regex='\/'
18314 ;;
18315 esac
18316 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18317
18318 gl_header_literal_regex=`echo 'stdint.h' \
18319 | sed -e "$gl_make_literal_regex_sed"`
18320 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18321 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18322 s|^/[^/]|//&|
18323 p
18324 q
18325 }'
18326 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18327 sed -n "$gl_absolute_header_sed"`'"'
18328 else
18329 gl_cv_next_stdint_h='<'stdint.h'>'
18330 fi
18331
18332
18333 fi
18334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18335 $as_echo "$gl_cv_next_stdint_h" >&6; }
18336 fi
18337 NEXT_STDINT_H=$gl_cv_next_stdint_h
18338
18339 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18340 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18341 gl_next_as_first_directive='<'stdint.h'>'
18342 else
18343 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18344 gl_next_as_first_directive=$gl_cv_next_stdint_h
18345 fi
18346 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18347
18348
18349
18350
18351 if test $ac_cv_header_stdint_h = yes; then
18352 HAVE_STDINT_H=1
18353 else
18354 HAVE_STDINT_H=0
18355 fi
18356
18357
18358 if test $ac_cv_header_stdint_h = yes; then
18359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18360 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18361 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18362 $as_echo_n "(cached) " >&6
18363 else
18364 gl_cv_header_working_stdint_h=no
18365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18366 /* end confdefs.h. */
18367
18368
18369 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18370 #include <stdint.h>
18371 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18372 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18373 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18374 #endif
18375
18376
18377 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18378 included before <wchar.h>. */
18379 #include <stddef.h>
18380 #include <signal.h>
18381 #if HAVE_WCHAR_H
18382 # include <stdio.h>
18383 # include <time.h>
18384 # include <wchar.h>
18385 #endif
18386
18387
18388 #ifdef INT8_MAX
18389 int8_t a1 = INT8_MAX;
18390 int8_t a1min = INT8_MIN;
18391 #endif
18392 #ifdef INT16_MAX
18393 int16_t a2 = INT16_MAX;
18394 int16_t a2min = INT16_MIN;
18395 #endif
18396 #ifdef INT32_MAX
18397 int32_t a3 = INT32_MAX;
18398 int32_t a3min = INT32_MIN;
18399 #endif
18400 #ifdef INT64_MAX
18401 int64_t a4 = INT64_MAX;
18402 int64_t a4min = INT64_MIN;
18403 #endif
18404 #ifdef UINT8_MAX
18405 uint8_t b1 = UINT8_MAX;
18406 #else
18407 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18408 #endif
18409 #ifdef UINT16_MAX
18410 uint16_t b2 = UINT16_MAX;
18411 #endif
18412 #ifdef UINT32_MAX
18413 uint32_t b3 = UINT32_MAX;
18414 #endif
18415 #ifdef UINT64_MAX
18416 uint64_t b4 = UINT64_MAX;
18417 #endif
18418 int_least8_t c1 = INT8_C (0x7f);
18419 int_least8_t c1max = INT_LEAST8_MAX;
18420 int_least8_t c1min = INT_LEAST8_MIN;
18421 int_least16_t c2 = INT16_C (0x7fff);
18422 int_least16_t c2max = INT_LEAST16_MAX;
18423 int_least16_t c2min = INT_LEAST16_MIN;
18424 int_least32_t c3 = INT32_C (0x7fffffff);
18425 int_least32_t c3max = INT_LEAST32_MAX;
18426 int_least32_t c3min = INT_LEAST32_MIN;
18427 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18428 int_least64_t c4max = INT_LEAST64_MAX;
18429 int_least64_t c4min = INT_LEAST64_MIN;
18430 uint_least8_t d1 = UINT8_C (0xff);
18431 uint_least8_t d1max = UINT_LEAST8_MAX;
18432 uint_least16_t d2 = UINT16_C (0xffff);
18433 uint_least16_t d2max = UINT_LEAST16_MAX;
18434 uint_least32_t d3 = UINT32_C (0xffffffff);
18435 uint_least32_t d3max = UINT_LEAST32_MAX;
18436 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18437 uint_least64_t d4max = UINT_LEAST64_MAX;
18438 int_fast8_t e1 = INT_FAST8_MAX;
18439 int_fast8_t e1min = INT_FAST8_MIN;
18440 int_fast16_t e2 = INT_FAST16_MAX;
18441 int_fast16_t e2min = INT_FAST16_MIN;
18442 int_fast32_t e3 = INT_FAST32_MAX;
18443 int_fast32_t e3min = INT_FAST32_MIN;
18444 int_fast64_t e4 = INT_FAST64_MAX;
18445 int_fast64_t e4min = INT_FAST64_MIN;
18446 uint_fast8_t f1 = UINT_FAST8_MAX;
18447 uint_fast16_t f2 = UINT_FAST16_MAX;
18448 uint_fast32_t f3 = UINT_FAST32_MAX;
18449 uint_fast64_t f4 = UINT_FAST64_MAX;
18450 #ifdef INTPTR_MAX
18451 intptr_t g = INTPTR_MAX;
18452 intptr_t gmin = INTPTR_MIN;
18453 #endif
18454 #ifdef UINTPTR_MAX
18455 uintptr_t h = UINTPTR_MAX;
18456 #endif
18457 intmax_t i = INTMAX_MAX;
18458 uintmax_t j = UINTMAX_MAX;
18459
18460 #include <limits.h> /* for CHAR_BIT */
18461 #define TYPE_MINIMUM(t) \
18462 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18463 #define TYPE_MAXIMUM(t) \
18464 ((t) ((t) 0 < (t) -1 \
18465 ? (t) -1 \
18466 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18467 struct s {
18468 int check_PTRDIFF:
18469 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18470 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18471 ? 1 : -1;
18472 /* Detect bug in FreeBSD 6.0 / ia64. */
18473 int check_SIG_ATOMIC:
18474 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18475 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18476 ? 1 : -1;
18477 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18478 int check_WCHAR:
18479 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18480 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18481 ? 1 : -1;
18482 /* Detect bug in mingw. */
18483 int check_WINT:
18484 WINT_MIN == TYPE_MINIMUM (wint_t)
18485 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18486 ? 1 : -1;
18487
18488 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18489 int check_UINT8_C:
18490 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18491 int check_UINT16_C:
18492 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18493
18494 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18495 #ifdef UINT8_MAX
18496 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18497 #endif
18498 #ifdef UINT16_MAX
18499 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18500 #endif
18501 #ifdef UINT32_MAX
18502 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18503 #endif
18504 #ifdef UINT64_MAX
18505 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18506 #endif
18507 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18508 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18509 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18510 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18511 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18512 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18513 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18514 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18515 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18516 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18517 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18518 };
18519
18520 int
18521 main ()
18522 {
18523
18524 ;
18525 return 0;
18526 }
18527 _ACEOF
18528 if ac_fn_c_try_compile "$LINENO"; then :
18529 if test "$cross_compiling" = yes; then :
18530 gl_cv_header_working_stdint_h=yes
18531
18532 else
18533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18534 /* end confdefs.h. */
18535
18536
18537 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18538 #include <stdint.h>
18539
18540
18541 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18542 included before <wchar.h>. */
18543 #include <stddef.h>
18544 #include <signal.h>
18545 #if HAVE_WCHAR_H
18546 # include <stdio.h>
18547 # include <time.h>
18548 # include <wchar.h>
18549 #endif
18550
18551
18552 #include <stdio.h>
18553 #include <string.h>
18554 #define MVAL(macro) MVAL1(macro)
18555 #define MVAL1(expression) #expression
18556 static const char *macro_values[] =
18557 {
18558 #ifdef INT8_MAX
18559 MVAL (INT8_MAX),
18560 #endif
18561 #ifdef INT16_MAX
18562 MVAL (INT16_MAX),
18563 #endif
18564 #ifdef INT32_MAX
18565 MVAL (INT32_MAX),
18566 #endif
18567 #ifdef INT64_MAX
18568 MVAL (INT64_MAX),
18569 #endif
18570 #ifdef UINT8_MAX
18571 MVAL (UINT8_MAX),
18572 #endif
18573 #ifdef UINT16_MAX
18574 MVAL (UINT16_MAX),
18575 #endif
18576 #ifdef UINT32_MAX
18577 MVAL (UINT32_MAX),
18578 #endif
18579 #ifdef UINT64_MAX
18580 MVAL (UINT64_MAX),
18581 #endif
18582 NULL
18583 };
18584
18585 int
18586 main ()
18587 {
18588
18589 const char **mv;
18590 for (mv = macro_values; *mv != NULL; mv++)
18591 {
18592 const char *value = *mv;
18593 /* Test whether it looks like a cast expression. */
18594 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18595 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18596 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18597 || strncmp (value, "((int)"/*)*/, 6) == 0
18598 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18599 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18600 return mv - macro_values + 1;
18601 }
18602 return 0;
18603
18604 ;
18605 return 0;
18606 }
18607 _ACEOF
18608 if ac_fn_c_try_run "$LINENO"; then :
18609 gl_cv_header_working_stdint_h=yes
18610 fi
18611 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18612 conftest.$ac_objext conftest.beam conftest.$ac_ext
18613 fi
18614
18615
18616 fi
18617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18618
18619 fi
18620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18621 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18622 fi
18623 if test "$gl_cv_header_working_stdint_h" = yes; then
18624 STDINT_H=
18625 else
18626 for ac_header in sys/inttypes.h sys/bitypes.h
18627 do :
18628 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18629 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18630 eval as_val=\$$as_ac_Header
18631 if test "x$as_val" = x""yes; then :
18632 cat >>confdefs.h <<_ACEOF
18633 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18634 _ACEOF
18635
18636 fi
18637
18638 done
18639
18640 if test $ac_cv_header_sys_inttypes_h = yes; then
18641 HAVE_SYS_INTTYPES_H=1
18642 else
18643 HAVE_SYS_INTTYPES_H=0
18644 fi
18645
18646 if test $ac_cv_header_sys_bitypes_h = yes; then
18647 HAVE_SYS_BITYPES_H=1
18648 else
18649 HAVE_SYS_BITYPES_H=0
18650 fi
18651
18652
18653
18654
18655 if test $APPLE_UNIVERSAL_BUILD = 0; then
18656
18657
18658 for gltype in ptrdiff_t size_t ; do
18659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18660 $as_echo_n "checking for bit size of $gltype... " >&6; }
18661 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18662 $as_echo_n "(cached) " >&6
18663 else
18664 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18665 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18666 included before <wchar.h>. */
18667 #include <stddef.h>
18668 #include <signal.h>
18669 #if HAVE_WCHAR_H
18670 # include <stdio.h>
18671 # include <time.h>
18672 # include <wchar.h>
18673 #endif
18674
18675 #include <limits.h>"; then :
18676
18677 else
18678 result=unknown
18679 fi
18680
18681 eval gl_cv_bitsizeof_${gltype}=\$result
18682
18683 fi
18684 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18686 $as_echo "$ac_res" >&6; }
18687 eval result=\$gl_cv_bitsizeof_${gltype}
18688 if test $result = unknown; then
18689 result=0
18690 fi
18691 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18692 cat >>confdefs.h <<_ACEOF
18693 #define BITSIZEOF_${GLTYPE} $result
18694 _ACEOF
18695
18696 eval BITSIZEOF_${GLTYPE}=\$result
18697 done
18698
18699
18700 fi
18701
18702
18703 for gltype in sig_atomic_t wchar_t wint_t ; do
18704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18705 $as_echo_n "checking for bit size of $gltype... " >&6; }
18706 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18707 $as_echo_n "(cached) " >&6
18708 else
18709 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18710 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18711 included before <wchar.h>. */
18712 #include <stddef.h>
18713 #include <signal.h>
18714 #if HAVE_WCHAR_H
18715 # include <stdio.h>
18716 # include <time.h>
18717 # include <wchar.h>
18718 #endif
18719
18720 #include <limits.h>"; then :
18721
18722 else
18723 result=unknown
18724 fi
18725
18726 eval gl_cv_bitsizeof_${gltype}=\$result
18727
18728 fi
18729 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18731 $as_echo "$ac_res" >&6; }
18732 eval result=\$gl_cv_bitsizeof_${gltype}
18733 if test $result = unknown; then
18734 result=0
18735 fi
18736 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18737 cat >>confdefs.h <<_ACEOF
18738 #define BITSIZEOF_${GLTYPE} $result
18739 _ACEOF
18740
18741 eval BITSIZEOF_${GLTYPE}=\$result
18742 done
18743
18744
18745
18746
18747 for gltype in sig_atomic_t wchar_t wint_t ; do
18748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18749 $as_echo_n "checking whether $gltype is signed... " >&6; }
18750 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18751 $as_echo_n "(cached) " >&6
18752 else
18753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18754 /* end confdefs.h. */
18755
18756 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18757 included before <wchar.h>. */
18758 #include <stddef.h>
18759 #include <signal.h>
18760 #if HAVE_WCHAR_H
18761 # include <stdio.h>
18762 # include <time.h>
18763 # include <wchar.h>
18764 #endif
18765
18766 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18767 int
18768 main ()
18769 {
18770
18771 ;
18772 return 0;
18773 }
18774 _ACEOF
18775 if ac_fn_c_try_compile "$LINENO"; then :
18776 result=yes
18777 else
18778 result=no
18779 fi
18780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18781 eval gl_cv_type_${gltype}_signed=\$result
18782
18783 fi
18784 eval ac_res=\$gl_cv_type_${gltype}_signed
18785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18786 $as_echo "$ac_res" >&6; }
18787 eval result=\$gl_cv_type_${gltype}_signed
18788 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18789 if test "$result" = yes; then
18790 cat >>confdefs.h <<_ACEOF
18791 #define HAVE_SIGNED_${GLTYPE} 1
18792 _ACEOF
18793
18794 eval HAVE_SIGNED_${GLTYPE}=1
18795 else
18796 eval HAVE_SIGNED_${GLTYPE}=0
18797 fi
18798 done
18799
18800
18801 gl_cv_type_ptrdiff_t_signed=yes
18802 gl_cv_type_size_t_signed=no
18803 if test $APPLE_UNIVERSAL_BUILD = 0; then
18804
18805
18806 for gltype in ptrdiff_t size_t ; do
18807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18808 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18809 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18810 $as_echo_n "(cached) " >&6
18811 else
18812 eval gl_cv_type_${gltype}_suffix=no
18813 eval result=\$gl_cv_type_${gltype}_signed
18814 if test "$result" = yes; then
18815 glsufu=
18816 else
18817 glsufu=u
18818 fi
18819 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18820 case $glsuf in
18821 '') gltype1='int';;
18822 l) gltype1='long int';;
18823 ll) gltype1='long long int';;
18824 i64) gltype1='__int64';;
18825 u) gltype1='unsigned int';;
18826 ul) gltype1='unsigned long int';;
18827 ull) gltype1='unsigned long long int';;
18828 ui64)gltype1='unsigned __int64';;
18829 esac
18830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18831 /* end confdefs.h. */
18832
18833 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18834 included before <wchar.h>. */
18835 #include <stddef.h>
18836 #include <signal.h>
18837 #if HAVE_WCHAR_H
18838 # include <stdio.h>
18839 # include <time.h>
18840 # include <wchar.h>
18841 #endif
18842
18843 extern $gltype foo;
18844 extern $gltype1 foo;
18845 int
18846 main ()
18847 {
18848
18849 ;
18850 return 0;
18851 }
18852 _ACEOF
18853 if ac_fn_c_try_compile "$LINENO"; then :
18854 eval gl_cv_type_${gltype}_suffix=\$glsuf
18855 fi
18856 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18857 eval result=\$gl_cv_type_${gltype}_suffix
18858 test "$result" != no && break
18859 done
18860 fi
18861 eval ac_res=\$gl_cv_type_${gltype}_suffix
18862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18863 $as_echo "$ac_res" >&6; }
18864 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18865 eval result=\$gl_cv_type_${gltype}_suffix
18866 test "$result" = no && result=
18867 eval ${GLTYPE}_SUFFIX=\$result
18868 cat >>confdefs.h <<_ACEOF
18869 #define ${GLTYPE}_SUFFIX $result
18870 _ACEOF
18871
18872 done
18873
18874
18875 fi
18876
18877
18878 for gltype in sig_atomic_t wchar_t wint_t ; do
18879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18880 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18881 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18882 $as_echo_n "(cached) " >&6
18883 else
18884 eval gl_cv_type_${gltype}_suffix=no
18885 eval result=\$gl_cv_type_${gltype}_signed
18886 if test "$result" = yes; then
18887 glsufu=
18888 else
18889 glsufu=u
18890 fi
18891 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18892 case $glsuf in
18893 '') gltype1='int';;
18894 l) gltype1='long int';;
18895 ll) gltype1='long long int';;
18896 i64) gltype1='__int64';;
18897 u) gltype1='unsigned int';;
18898 ul) gltype1='unsigned long int';;
18899 ull) gltype1='unsigned long long int';;
18900 ui64)gltype1='unsigned __int64';;
18901 esac
18902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18903 /* end confdefs.h. */
18904
18905 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18906 included before <wchar.h>. */
18907 #include <stddef.h>
18908 #include <signal.h>
18909 #if HAVE_WCHAR_H
18910 # include <stdio.h>
18911 # include <time.h>
18912 # include <wchar.h>
18913 #endif
18914
18915 extern $gltype foo;
18916 extern $gltype1 foo;
18917 int
18918 main ()
18919 {
18920
18921 ;
18922 return 0;
18923 }
18924 _ACEOF
18925 if ac_fn_c_try_compile "$LINENO"; then :
18926 eval gl_cv_type_${gltype}_suffix=\$glsuf
18927 fi
18928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18929 eval result=\$gl_cv_type_${gltype}_suffix
18930 test "$result" != no && break
18931 done
18932 fi
18933 eval ac_res=\$gl_cv_type_${gltype}_suffix
18934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18935 $as_echo "$ac_res" >&6; }
18936 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18937 eval result=\$gl_cv_type_${gltype}_suffix
18938 test "$result" = no && result=
18939 eval ${GLTYPE}_SUFFIX=\$result
18940 cat >>confdefs.h <<_ACEOF
18941 #define ${GLTYPE}_SUFFIX $result
18942 _ACEOF
18943
18944 done
18945
18946
18947
18948 if test $BITSIZEOF_WINT_T -lt 32; then
18949 BITSIZEOF_WINT_T=32
18950 fi
18951
18952 STDINT_H=stdint.h
18953 fi
18954
18955 if test -n "$STDINT_H"; then
18956 GL_GENERATE_STDINT_H_TRUE=
18957 GL_GENERATE_STDINT_H_FALSE='#'
18958 else
18959 GL_GENERATE_STDINT_H_TRUE='#'
18960 GL_GENERATE_STDINT_H_FALSE=
18961 fi
18962
18963
18964
18965
18966
18967 GNULIB_IMAXABS=0;
18968 GNULIB_IMAXDIV=0;
18969 GNULIB_STRTOIMAX=0;
18970 GNULIB_STRTOUMAX=0;
18971 HAVE_DECL_IMAXABS=1;
18972 HAVE_DECL_IMAXDIV=1;
18973 HAVE_DECL_STRTOIMAX=1;
18974 HAVE_DECL_STRTOUMAX=1;
18975 REPLACE_STRTOIMAX=0;
18976 INT32_MAX_LT_INTMAX_MAX=1;
18977 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18978 PRI_MACROS_BROKEN=0;
18979 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18980 UINT32_MAX_LT_UINTMAX_MAX=1;
18981 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18982
18983
18984
18985
18986
18987
18988
18989
18990
18991
18992
18993
18994
18995
18996
18997 if test $gl_cv_have_include_next = yes; then
18998 gl_cv_next_inttypes_h='<'inttypes.h'>'
18999 else
19000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
19001 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
19002 if test "${gl_cv_next_inttypes_h+set}" = set; then :
19003 $as_echo_n "(cached) " >&6
19004 else
19005
19006 if test $ac_cv_header_inttypes_h = yes; then
19007
19008
19009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19010 /* end confdefs.h. */
19011 #include <inttypes.h>
19012
19013 _ACEOF
19014 case "$host_os" in
19015 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19016 *) gl_absname_cpp="$ac_cpp" ;;
19017 esac
19018
19019 case "$host_os" in
19020 mingw*)
19021 gl_dirsep_regex='[/\\]'
19022 ;;
19023 *)
19024 gl_dirsep_regex='\/'
19025 ;;
19026 esac
19027 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19028
19029 gl_header_literal_regex=`echo 'inttypes.h' \
19030 | sed -e "$gl_make_literal_regex_sed"`
19031 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19032 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19033 s|^/[^/]|//&|
19034 p
19035 q
19036 }'
19037 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19038 sed -n "$gl_absolute_header_sed"`'"'
19039 else
19040 gl_cv_next_inttypes_h='<'inttypes.h'>'
19041 fi
19042
19043
19044 fi
19045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
19046 $as_echo "$gl_cv_next_inttypes_h" >&6; }
19047 fi
19048 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
19049
19050 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19051 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19052 gl_next_as_first_directive='<'inttypes.h'>'
19053 else
19054 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19055 gl_next_as_first_directive=$gl_cv_next_inttypes_h
19056 fi
19057 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
19058
19059
19060
19061
19062
19063
19064
19065
19066
19067
19068
19069 case "$host_os" in
19070 mingw*)
19071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
19072 $as_echo_n "checking for 64-bit off_t... " >&6; }
19073 if test "${gl_cv_type_off_t_64+set}" = set; then :
19074 $as_echo_n "(cached) " >&6
19075 else
19076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19077 /* end confdefs.h. */
19078 #include <sys/types.h>
19079 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
19080
19081 int
19082 main ()
19083 {
19084
19085 ;
19086 return 0;
19087 }
19088 _ACEOF
19089 if ac_fn_c_try_compile "$LINENO"; then :
19090 gl_cv_type_off_t_64=yes
19091 else
19092 gl_cv_type_off_t_64=no
19093 fi
19094 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19095
19096 fi
19097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
19098 $as_echo "$gl_cv_type_off_t_64" >&6; }
19099 if test $gl_cv_type_off_t_64 = no; then
19100 WINDOWS_64_BIT_OFF_T=1
19101 else
19102 WINDOWS_64_BIT_OFF_T=0
19103 fi
19104 WINDOWS_64_BIT_ST_SIZE=1
19105 ;;
19106 *)
19107 WINDOWS_64_BIT_OFF_T=0
19108 WINDOWS_64_BIT_ST_SIZE=0
19109 ;;
19110 esac
19111
19112
19113 GNULIB_FCHMODAT=0;
19114 GNULIB_FSTAT=0;
19115 GNULIB_FSTATAT=0;
19116 GNULIB_FUTIMENS=0;
19117 GNULIB_LCHMOD=0;
19118 GNULIB_LSTAT=0;
19119 GNULIB_MKDIRAT=0;
19120 GNULIB_MKFIFO=0;
19121 GNULIB_MKFIFOAT=0;
19122 GNULIB_MKNOD=0;
19123 GNULIB_MKNODAT=0;
19124 GNULIB_STAT=0;
19125 GNULIB_UTIMENSAT=0;
19126 HAVE_FCHMODAT=1;
19127 HAVE_FSTATAT=1;
19128 HAVE_FUTIMENS=1;
19129 HAVE_LCHMOD=1;
19130 HAVE_LSTAT=1;
19131 HAVE_MKDIRAT=1;
19132 HAVE_MKFIFO=1;
19133 HAVE_MKFIFOAT=1;
19134 HAVE_MKNOD=1;
19135 HAVE_MKNODAT=1;
19136 HAVE_UTIMENSAT=1;
19137 REPLACE_FSTAT=0;
19138 REPLACE_FSTATAT=0;
19139 REPLACE_FUTIMENS=0;
19140 REPLACE_LSTAT=0;
19141 REPLACE_MKDIR=0;
19142 REPLACE_MKFIFO=0;
19143 REPLACE_MKNOD=0;
19144 REPLACE_STAT=0;
19145 REPLACE_UTIMENSAT=0;
19146
19147
19148
19149
19150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
19151 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
19152 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
19153 $as_echo_n "(cached) " >&6
19154 else
19155 rm -f conftest.sym conftest.file
19156 echo >conftest.file
19157 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
19158 if test "$cross_compiling" = yes; then :
19159 case "$host_os" in
19160 # Guess yes on glibc systems.
19161 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
19162 # If we don't know, assume the worst.
19163 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
19164 esac
19165
19166 else
19167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19168 /* end confdefs.h. */
19169 $ac_includes_default
19170 int
19171 main ()
19172 {
19173 struct stat sbuf;
19174 /* Linux will dereference the symlink and fail, as required by
19175 POSIX. That is better in the sense that it means we will not
19176 have to compile and use the lstat wrapper. */
19177 return lstat ("conftest.sym/", &sbuf) == 0;
19178
19179 ;
19180 return 0;
19181 }
19182 _ACEOF
19183 if ac_fn_c_try_run "$LINENO"; then :
19184 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19185 else
19186 gl_cv_func_lstat_dereferences_slashed_symlink=no
19187 fi
19188 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19189 conftest.$ac_objext conftest.beam conftest.$ac_ext
19190 fi
19191
19192 else
19193 # If the 'ln -s' command failed, then we probably don't even
19194 # have an lstat function.
19195 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19196 fi
19197 rm -f conftest.sym conftest.file
19198
19199 fi
19200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19201 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19202 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19203 *yes)
19204
19205 cat >>confdefs.h <<_ACEOF
19206 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19207 _ACEOF
19208
19209 ;;
19210 esac
19211
19212
19213 GNULIB_MKTIME=0;
19214 GNULIB_NANOSLEEP=0;
19215 GNULIB_STRPTIME=0;
19216 GNULIB_TIMEGM=0;
19217 GNULIB_TIME_R=0;
19218 HAVE_DECL_LOCALTIME_R=1;
19219 HAVE_NANOSLEEP=1;
19220 HAVE_STRPTIME=1;
19221 HAVE_TIMEGM=1;
19222 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
19223 REPLACE_MKTIME=GNULIB_PORTCHECK;
19224 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
19225 REPLACE_TIMEGM=GNULIB_PORTCHECK;
19226
19227
19228
19229
19230 GNULIB_PSELECT=0;
19231 GNULIB_SELECT=0;
19232 HAVE_PSELECT=1;
19233 REPLACE_PSELECT=0;
19234 REPLACE_SELECT=0;
19235
19236
19237
19238
19239
19240
19241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
19242 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
19243 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
19244 $as_echo_n "(cached) " >&6
19245 else
19246
19247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19248 /* end confdefs.h. */
19249 #include <sys/select.h>
19250 int
19251 main ()
19252 {
19253 struct timeval b;
19254 ;
19255 return 0;
19256 }
19257 _ACEOF
19258 if ac_fn_c_try_compile "$LINENO"; then :
19259 gl_cv_header_sys_select_h_selfcontained=yes
19260 else
19261 gl_cv_header_sys_select_h_selfcontained=no
19262 fi
19263 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19264 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
19265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19266 /* end confdefs.h. */
19267 #include <sys/select.h>
19268 int
19269 main ()
19270 {
19271 int memset; int bzero;
19272 ;
19273 return 0;
19274 }
19275
19276 _ACEOF
19277 if ac_fn_c_try_compile "$LINENO"; then :
19278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19279 /* end confdefs.h. */
19280 #include <sys/select.h>
19281 int
19282 main ()
19283 {
19284
19285 #undef memset
19286 #define memset nonexistent_memset
19287 extern
19288 #ifdef __cplusplus
19289 "C"
19290 #endif
19291 void *memset (void *, int, unsigned long);
19292 #undef bzero
19293 #define bzero nonexistent_bzero
19294 extern
19295 #ifdef __cplusplus
19296 "C"
19297 #endif
19298 void bzero (void *, unsigned long);
19299 fd_set fds;
19300 FD_ZERO (&fds);
19301
19302 ;
19303 return 0;
19304 }
19305
19306 _ACEOF
19307 if ac_fn_c_try_link "$LINENO"; then :
19308
19309 else
19310 gl_cv_header_sys_select_h_selfcontained=no
19311 fi
19312 rm -f core conftest.err conftest.$ac_objext \
19313 conftest$ac_exeext conftest.$ac_ext
19314
19315 fi
19316 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19317 fi
19318
19319 fi
19320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19321 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19322
19323
19324
19325
19326
19327
19328
19329
19330
19331 if test $gl_cv_have_include_next = yes; then
19332 gl_cv_next_sys_select_h='<'sys/select.h'>'
19333 else
19334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19335 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19336 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19337 $as_echo_n "(cached) " >&6
19338 else
19339
19340 if test $ac_cv_header_sys_select_h = yes; then
19341
19342
19343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19344 /* end confdefs.h. */
19345 #include <sys/select.h>
19346
19347 _ACEOF
19348 case "$host_os" in
19349 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19350 *) gl_absname_cpp="$ac_cpp" ;;
19351 esac
19352
19353 case "$host_os" in
19354 mingw*)
19355 gl_dirsep_regex='[/\\]'
19356 ;;
19357 *)
19358 gl_dirsep_regex='\/'
19359 ;;
19360 esac
19361 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19362
19363 gl_header_literal_regex=`echo 'sys/select.h' \
19364 | sed -e "$gl_make_literal_regex_sed"`
19365 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19366 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19367 s|^/[^/]|//&|
19368 p
19369 q
19370 }'
19371 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19372 sed -n "$gl_absolute_header_sed"`'"'
19373 else
19374 gl_cv_next_sys_select_h='<'sys/select.h'>'
19375 fi
19376
19377
19378 fi
19379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19380 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19381 fi
19382 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19383
19384 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19385 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19386 gl_next_as_first_directive='<'sys/select.h'>'
19387 else
19388 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19389 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19390 fi
19391 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19392
19393
19394
19395
19396 if test $ac_cv_header_sys_select_h = yes; then
19397 HAVE_SYS_SELECT_H=1
19398 else
19399 HAVE_SYS_SELECT_H=0
19400 fi
19401
19402
19403
19404
19405
19406 if test $ac_cv_header_sys_socket_h != yes; then
19407 for ac_header in winsock2.h
19408 do :
19409 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19410 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19411 cat >>confdefs.h <<_ACEOF
19412 #define HAVE_WINSOCK2_H 1
19413 _ACEOF
19414
19415 fi
19416
19417 done
19418
19419 fi
19420 if test "$ac_cv_header_winsock2_h" = yes; then
19421 HAVE_WINSOCK2_H=1
19422 UNISTD_H_HAVE_WINSOCK2_H=1
19423 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19424 else
19425 HAVE_WINSOCK2_H=0
19426 fi
19427
19428
19429
19430
19431
19432
19433
19434
19435 GNULIB_PTHREAD_SIGMASK=0;
19436 GNULIB_RAISE=0;
19437 GNULIB_SIGNAL_H_SIGPIPE=0;
19438 GNULIB_SIGPROCMASK=0;
19439 GNULIB_SIGACTION=0;
19440 HAVE_POSIX_SIGNALBLOCKING=1;
19441 HAVE_PTHREAD_SIGMASK=1;
19442 HAVE_RAISE=1;
19443 HAVE_SIGSET_T=1;
19444 HAVE_SIGINFO_T=1;
19445 HAVE_SIGACTION=1;
19446 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19447
19448 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19449
19450 HAVE_SIGHANDLER_T=1;
19451 REPLACE_PTHREAD_SIGMASK=0;
19452 REPLACE_RAISE=0;
19453
19454
19455
19456
19457
19458
19459
19460 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19461 #include <signal.h>
19462 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19463 #include <sys/types.h>
19464
19465 "
19466 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19467
19468 cat >>confdefs.h <<_ACEOF
19469 #define HAVE_SIGSET_T 1
19470 _ACEOF
19471
19472 gl_cv_type_sigset_t=yes
19473 else
19474 gl_cv_type_sigset_t=no
19475 fi
19476
19477 if test $gl_cv_type_sigset_t != yes; then
19478 HAVE_SIGSET_T=0
19479 fi
19480
19481
19482
19483 if test $ac_cv_header_sys_socket_h = no; then
19484 for ac_header in ws2tcpip.h
19485 do :
19486 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19487 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19488 cat >>confdefs.h <<_ACEOF
19489 #define HAVE_WS2TCPIP_H 1
19490 _ACEOF
19491
19492 fi
19493
19494 done
19495
19496 fi
19497
19498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19499 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19500 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19501 $as_echo_n "(cached) " >&6
19502 else
19503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19504 /* end confdefs.h. */
19505
19506 #include <stdbool.h>
19507 #ifndef bool
19508 "error: bool is not defined"
19509 #endif
19510 #ifndef false
19511 "error: false is not defined"
19512 #endif
19513 #if false
19514 "error: false is not 0"
19515 #endif
19516 #ifndef true
19517 "error: true is not defined"
19518 #endif
19519 #if true != 1
19520 "error: true is not 1"
19521 #endif
19522 #ifndef __bool_true_false_are_defined
19523 "error: __bool_true_false_are_defined is not defined"
19524 #endif
19525
19526 struct s { _Bool s: 1; _Bool t; } s;
19527
19528 char a[true == 1 ? 1 : -1];
19529 char b[false == 0 ? 1 : -1];
19530 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19531 char d[(bool) 0.5 == true ? 1 : -1];
19532 /* See body of main program for 'e'. */
19533 char f[(_Bool) 0.0 == false ? 1 : -1];
19534 char g[true];
19535 char h[sizeof (_Bool)];
19536 char i[sizeof s.t];
19537 enum { j = false, k = true, l = false * true, m = true * 256 };
19538 /* The following fails for
19539 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19540 _Bool n[m];
19541 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19542 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19543 /* Catch a bug in an HP-UX C compiler. See
19544 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19545 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19546 */
19547 _Bool q = true;
19548 _Bool *pq = &q;
19549
19550 int
19551 main ()
19552 {
19553
19554 bool e = &s;
19555 *pq |= q;
19556 *pq |= ! q;
19557 /* Refer to every declared value, to avoid compiler optimizations. */
19558 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19559 + !m + !n + !o + !p + !q + !pq);
19560
19561 ;
19562 return 0;
19563 }
19564 _ACEOF
19565 if ac_fn_c_try_compile "$LINENO"; then :
19566 ac_cv_header_stdbool_h=yes
19567 else
19568 ac_cv_header_stdbool_h=no
19569 fi
19570 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19571 fi
19572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19573 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19574 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19575 if test "x$ac_cv_type__Bool" = x""yes; then :
19576
19577 cat >>confdefs.h <<_ACEOF
19578 #define HAVE__BOOL 1
19579 _ACEOF
19580
19581
19582 fi
19583
19584
19585
19586 REPLACE_NULL=0;
19587 HAVE_WCHAR_T=1;
19588
19589
19590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19591 $as_echo_n "checking for wchar_t... " >&6; }
19592 if test "${gt_cv_c_wchar_t+set}" = set; then :
19593 $as_echo_n "(cached) " >&6
19594 else
19595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19596 /* end confdefs.h. */
19597 #include <stddef.h>
19598 wchar_t foo = (wchar_t)'\0';
19599 int
19600 main ()
19601 {
19602
19603 ;
19604 return 0;
19605 }
19606 _ACEOF
19607 if ac_fn_c_try_compile "$LINENO"; then :
19608 gt_cv_c_wchar_t=yes
19609 else
19610 gt_cv_c_wchar_t=no
19611 fi
19612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19613 fi
19614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19615 $as_echo "$gt_cv_c_wchar_t" >&6; }
19616 if test $gt_cv_c_wchar_t = yes; then
19617
19618 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19619
19620 fi
19621
19622
19623 GNULIB_DPRINTF=0;
19624 GNULIB_FCLOSE=0;
19625 GNULIB_FDOPEN=0;
19626 GNULIB_FFLUSH=0;
19627 GNULIB_FGETC=0;
19628 GNULIB_FGETS=0;
19629 GNULIB_FOPEN=0;
19630 GNULIB_FPRINTF=0;
19631 GNULIB_FPRINTF_POSIX=0;
19632 GNULIB_FPURGE=0;
19633 GNULIB_FPUTC=0;
19634 GNULIB_FPUTS=0;
19635 GNULIB_FREAD=0;
19636 GNULIB_FREOPEN=0;
19637 GNULIB_FSCANF=0;
19638 GNULIB_FSEEK=0;
19639 GNULIB_FSEEKO=0;
19640 GNULIB_FTELL=0;
19641 GNULIB_FTELLO=0;
19642 GNULIB_FWRITE=0;
19643 GNULIB_GETC=0;
19644 GNULIB_GETCHAR=0;
19645 GNULIB_GETDELIM=0;
19646 GNULIB_GETLINE=0;
19647 GNULIB_OBSTACK_PRINTF=0;
19648 GNULIB_OBSTACK_PRINTF_POSIX=0;
19649 GNULIB_PCLOSE=0;
19650 GNULIB_PERROR=0;
19651 GNULIB_POPEN=0;
19652 GNULIB_PRINTF=0;
19653 GNULIB_PRINTF_POSIX=0;
19654 GNULIB_PUTC=0;
19655 GNULIB_PUTCHAR=0;
19656 GNULIB_PUTS=0;
19657 GNULIB_REMOVE=0;
19658 GNULIB_RENAME=0;
19659 GNULIB_RENAMEAT=0;
19660 GNULIB_SCANF=0;
19661 GNULIB_SNPRINTF=0;
19662 GNULIB_SPRINTF_POSIX=0;
19663 GNULIB_STDIO_H_NONBLOCKING=0;
19664 GNULIB_STDIO_H_SIGPIPE=0;
19665 GNULIB_TMPFILE=0;
19666 GNULIB_VASPRINTF=0;
19667 GNULIB_VFSCANF=0;
19668 GNULIB_VSCANF=0;
19669 GNULIB_VDPRINTF=0;
19670 GNULIB_VFPRINTF=0;
19671 GNULIB_VFPRINTF_POSIX=0;
19672 GNULIB_VPRINTF=0;
19673 GNULIB_VPRINTF_POSIX=0;
19674 GNULIB_VSNPRINTF=0;
19675 GNULIB_VSPRINTF_POSIX=0;
19676 HAVE_DECL_FPURGE=1;
19677 HAVE_DECL_FSEEKO=1;
19678 HAVE_DECL_FTELLO=1;
19679 HAVE_DECL_GETDELIM=1;
19680 HAVE_DECL_GETLINE=1;
19681 HAVE_DECL_OBSTACK_PRINTF=1;
19682 HAVE_DECL_SNPRINTF=1;
19683 HAVE_DECL_VSNPRINTF=1;
19684 HAVE_DPRINTF=1;
19685 HAVE_FSEEKO=1;
19686 HAVE_FTELLO=1;
19687 HAVE_PCLOSE=1;
19688 HAVE_POPEN=1;
19689 HAVE_RENAMEAT=1;
19690 HAVE_VASPRINTF=1;
19691 HAVE_VDPRINTF=1;
19692 REPLACE_DPRINTF=0;
19693 REPLACE_FCLOSE=0;
19694 REPLACE_FDOPEN=0;
19695 REPLACE_FFLUSH=0;
19696 REPLACE_FOPEN=0;
19697 REPLACE_FPRINTF=0;
19698 REPLACE_FPURGE=0;
19699 REPLACE_FREOPEN=0;
19700 REPLACE_FSEEK=0;
19701 REPLACE_FSEEKO=0;
19702 REPLACE_FTELL=0;
19703 REPLACE_FTELLO=0;
19704 REPLACE_GETDELIM=0;
19705 REPLACE_GETLINE=0;
19706 REPLACE_OBSTACK_PRINTF=0;
19707 REPLACE_PERROR=0;
19708 REPLACE_POPEN=0;
19709 REPLACE_PRINTF=0;
19710 REPLACE_REMOVE=0;
19711 REPLACE_RENAME=0;
19712 REPLACE_RENAMEAT=0;
19713 REPLACE_SNPRINTF=0;
19714 REPLACE_SPRINTF=0;
19715 REPLACE_STDIO_READ_FUNCS=0;
19716 REPLACE_STDIO_WRITE_FUNCS=0;
19717 REPLACE_TMPFILE=0;
19718 REPLACE_VASPRINTF=0;
19719 REPLACE_VDPRINTF=0;
19720 REPLACE_VFPRINTF=0;
19721 REPLACE_VPRINTF=0;
19722 REPLACE_VSNPRINTF=0;
19723 REPLACE_VSPRINTF=0;
19724
19725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19726 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19727 if test "${ac_cv_struct_tm+set}" = set; then :
19728 $as_echo_n "(cached) " >&6
19729 else
19730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19731 /* end confdefs.h. */
19732 #include <sys/types.h>
19733 #include <time.h>
19734
19735 int
19736 main ()
19737 {
19738 struct tm tm;
19739 int *p = &tm.tm_sec;
19740 return !p;
19741 ;
19742 return 0;
19743 }
19744 _ACEOF
19745 if ac_fn_c_try_compile "$LINENO"; then :
19746 ac_cv_struct_tm=time.h
19747 else
19748 ac_cv_struct_tm=sys/time.h
19749 fi
19750 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19751 fi
19752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19753 $as_echo "$ac_cv_struct_tm" >&6; }
19754 if test $ac_cv_struct_tm = sys/time.h; then
19755
19756 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19757
19758 fi
19759
19760 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19761 #include <$ac_cv_struct_tm>
19762
19763 "
19764 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19765
19766 cat >>confdefs.h <<_ACEOF
19767 #define HAVE_STRUCT_TM_TM_ZONE 1
19768 _ACEOF
19769
19770
19771 fi
19772
19773 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19774
19775 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19776
19777 else
19778 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19779 "
19780 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19781 ac_have_decl=1
19782 else
19783 ac_have_decl=0
19784 fi
19785
19786 cat >>confdefs.h <<_ACEOF
19787 #define HAVE_DECL_TZNAME $ac_have_decl
19788 _ACEOF
19789
19790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19791 $as_echo_n "checking for tzname... " >&6; }
19792 if test "${ac_cv_var_tzname+set}" = set; then :
19793 $as_echo_n "(cached) " >&6
19794 else
19795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19796 /* end confdefs.h. */
19797 #include <time.h>
19798 #if !HAVE_DECL_TZNAME
19799 extern char *tzname[];
19800 #endif
19801
19802 int
19803 main ()
19804 {
19805 return tzname[0][0];
19806 ;
19807 return 0;
19808 }
19809 _ACEOF
19810 if ac_fn_c_try_link "$LINENO"; then :
19811 ac_cv_var_tzname=yes
19812 else
19813 ac_cv_var_tzname=no
19814 fi
19815 rm -f core conftest.err conftest.$ac_objext \
19816 conftest$ac_exeext conftest.$ac_ext
19817 fi
19818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19819 $as_echo "$ac_cv_var_tzname" >&6; }
19820 if test $ac_cv_var_tzname = yes; then
19821
19822 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19823
19824 fi
19825 fi
19826
19827
19828 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19829 "
19830 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19831
19832 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19833
19834 fi
19835
19836
19837
19838
19839 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19840 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19841 ac_have_decl=1
19842 else
19843 ac_have_decl=0
19844 fi
19845
19846 cat >>confdefs.h <<_ACEOF
19847 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19848 _ACEOF
19849
19850
19851
19852 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19853 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19854 ac_have_decl=1
19855 else
19856 ac_have_decl=0
19857 fi
19858
19859 cat >>confdefs.h <<_ACEOF
19860 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19861 _ACEOF
19862
19863
19864
19865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19866 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19867 if test "${ac_cv_header_stat_broken+set}" = set; then :
19868 $as_echo_n "(cached) " >&6
19869 else
19870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19871 /* end confdefs.h. */
19872 #include <sys/types.h>
19873 #include <sys/stat.h>
19874
19875 #if defined S_ISBLK && defined S_IFDIR
19876 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19877 #endif
19878
19879 #if defined S_ISBLK && defined S_IFCHR
19880 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19881 #endif
19882
19883 #if defined S_ISLNK && defined S_IFREG
19884 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19885 #endif
19886
19887 #if defined S_ISSOCK && defined S_IFREG
19888 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19889 #endif
19890
19891 _ACEOF
19892 if ac_fn_c_try_compile "$LINENO"; then :
19893 ac_cv_header_stat_broken=no
19894 else
19895 ac_cv_header_stat_broken=yes
19896 fi
19897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19898 fi
19899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19900 $as_echo "$ac_cv_header_stat_broken" >&6; }
19901 if test $ac_cv_header_stat_broken = yes; then
19902
19903 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19904
19905 fi
19906
19907
19908
19909 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19910 if test "x$ac_cv_type_mode_t" = x""yes; then :
19911
19912 else
19913
19914 cat >>confdefs.h <<_ACEOF
19915 #define mode_t int
19916 _ACEOF
19917
19918 fi
19919
19920
19921
19922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19923 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19924 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19925 $as_echo_n "(cached) " >&6
19926 else
19927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19928 /* end confdefs.h. */
19929 #include <time.h>
19930
19931 int
19932 main ()
19933 {
19934 static struct timespec x; x.tv_sec = x.tv_nsec;
19935 ;
19936 return 0;
19937 }
19938 _ACEOF
19939 if ac_fn_c_try_compile "$LINENO"; then :
19940 gl_cv_sys_struct_timespec_in_time_h=yes
19941 else
19942 gl_cv_sys_struct_timespec_in_time_h=no
19943 fi
19944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19945 fi
19946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19947 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19948
19949 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19950 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19951 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19952 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19953 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19954 else
19955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19956 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19957 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19958 $as_echo_n "(cached) " >&6
19959 else
19960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19961 /* end confdefs.h. */
19962 #include <sys/time.h>
19963
19964 int
19965 main ()
19966 {
19967 static struct timespec x; x.tv_sec = x.tv_nsec;
19968 ;
19969 return 0;
19970 }
19971 _ACEOF
19972 if ac_fn_c_try_compile "$LINENO"; then :
19973 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19974 else
19975 gl_cv_sys_struct_timespec_in_sys_time_h=no
19976 fi
19977 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19978 fi
19979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19980 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19981 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19982 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19983 else
19984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19985 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19986 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19987 $as_echo_n "(cached) " >&6
19988 else
19989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19990 /* end confdefs.h. */
19991 #include <pthread.h>
19992
19993 int
19994 main ()
19995 {
19996 static struct timespec x; x.tv_sec = x.tv_nsec;
19997 ;
19998 return 0;
19999 }
20000 _ACEOF
20001 if ac_fn_c_try_compile "$LINENO"; then :
20002 gl_cv_sys_struct_timespec_in_pthread_h=yes
20003 else
20004 gl_cv_sys_struct_timespec_in_pthread_h=no
20005 fi
20006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20007 fi
20008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
20009 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
20010 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
20011 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
20012 fi
20013 fi
20014 fi
20015
20016
20017
20018
20019
20020
20021
20022
20023
20024
20025
20026
20027
20028
20029
20030 if test $gl_cv_have_include_next = yes; then
20031 gl_cv_next_time_h='<'time.h'>'
20032 else
20033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
20034 $as_echo_n "checking absolute name of <time.h>... " >&6; }
20035 if test "${gl_cv_next_time_h+set}" = set; then :
20036 $as_echo_n "(cached) " >&6
20037 else
20038
20039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20040 /* end confdefs.h. */
20041 #include <time.h>
20042
20043 _ACEOF
20044 case "$host_os" in
20045 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20046 *) gl_absname_cpp="$ac_cpp" ;;
20047 esac
20048
20049 case "$host_os" in
20050 mingw*)
20051 gl_dirsep_regex='[/\\]'
20052 ;;
20053 *)
20054 gl_dirsep_regex='\/'
20055 ;;
20056 esac
20057 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20058
20059 gl_header_literal_regex=`echo 'time.h' \
20060 | sed -e "$gl_make_literal_regex_sed"`
20061 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20062 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20063 s|^/[^/]|//&|
20064 p
20065 q
20066 }'
20067 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20068 sed -n "$gl_absolute_header_sed"`'"'
20069
20070
20071 fi
20072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
20073 $as_echo "$gl_cv_next_time_h" >&6; }
20074 fi
20075 NEXT_TIME_H=$gl_cv_next_time_h
20076
20077 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20078 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20079 gl_next_as_first_directive='<'time.h'>'
20080 else
20081 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20082 gl_next_as_first_directive=$gl_cv_next_time_h
20083 fi
20084 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
20085
20086
20087
20088
20089
20090
20091
20092
20093
20094
20095
20096
20097
20098
20099
20100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
20101 $as_echo_n "checking whether the utimes function works... " >&6; }
20102 if test "${gl_cv_func_working_utimes+set}" = set; then :
20103 $as_echo_n "(cached) " >&6
20104 else
20105
20106 if test "$cross_compiling" = yes; then :
20107 gl_cv_func_working_utimes=no
20108 else
20109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20110 /* end confdefs.h. */
20111
20112 #include <sys/types.h>
20113 #include <sys/stat.h>
20114 #include <fcntl.h>
20115 #include <sys/time.h>
20116 #include <time.h>
20117 #include <unistd.h>
20118 #include <stdlib.h>
20119 #include <stdio.h>
20120 #include <utime.h>
20121
20122 static int
20123 inorder (time_t a, time_t b, time_t c)
20124 {
20125 return a <= b && b <= c;
20126 }
20127
20128 int
20129 main ()
20130 {
20131 int result = 0;
20132 char const *file = "conftest.utimes";
20133 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
20134
20135 /* Test whether utimes() essentially works. */
20136 {
20137 struct stat sbuf;
20138 FILE *f = fopen (file, "w");
20139 if (f == NULL)
20140 result |= 1;
20141 else if (fclose (f) != 0)
20142 result |= 1;
20143 else if (utimes (file, timeval) != 0)
20144 result |= 2;
20145 else if (lstat (file, &sbuf) != 0)
20146 result |= 1;
20147 else if (!(sbuf.st_atime == timeval[0].tv_sec
20148 && sbuf.st_mtime == timeval[1].tv_sec))
20149 result |= 4;
20150 if (unlink (file) != 0)
20151 result |= 1;
20152 }
20153
20154 /* Test whether utimes() with a NULL argument sets the file's timestamp
20155 to the current time. Use 'fstat' as well as 'time' to
20156 determine the "current" time, to accommodate NFS file systems
20157 if there is a time skew between the host and the NFS server. */
20158 {
20159 int fd = open (file, O_WRONLY|O_CREAT, 0644);
20160 if (fd < 0)
20161 result |= 1;
20162 else
20163 {
20164 time_t t0, t2;
20165 struct stat st0, st1, st2;
20166 if (time (&t0) == (time_t) -1)
20167 result |= 1;
20168 else if (fstat (fd, &st0) != 0)
20169 result |= 1;
20170 else if (utimes (file, timeval) != 0)
20171 result |= 2;
20172 else if (utimes (file, NULL) != 0)
20173 result |= 8;
20174 else if (fstat (fd, &st1) != 0)
20175 result |= 1;
20176 else if (write (fd, "\n", 1) != 1)
20177 result |= 1;
20178 else if (fstat (fd, &st2) != 0)
20179 result |= 1;
20180 else if (time (&t2) == (time_t) -1)
20181 result |= 1;
20182 else
20183 {
20184 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
20185 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
20186 if (! (st1.st_atime == st1.st_mtime))
20187 result |= 16;
20188 if (! (m_ok_POSIX || m_ok_NFS))
20189 result |= 32;
20190 }
20191 if (close (fd) != 0)
20192 result |= 1;
20193 }
20194 if (unlink (file) != 0)
20195 result |= 1;
20196 }
20197
20198 /* Test whether utimes() with a NULL argument works on read-only files. */
20199 {
20200 int fd = open (file, O_WRONLY|O_CREAT, 0444);
20201 if (fd < 0)
20202 result |= 1;
20203 else if (close (fd) != 0)
20204 result |= 1;
20205 else if (utimes (file, NULL) != 0)
20206 result |= 64;
20207 if (unlink (file) != 0)
20208 result |= 1;
20209 }
20210
20211 return result;
20212 }
20213
20214 _ACEOF
20215 if ac_fn_c_try_run "$LINENO"; then :
20216 gl_cv_func_working_utimes=yes
20217 else
20218 gl_cv_func_working_utimes=no
20219 fi
20220 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20221 conftest.$ac_objext conftest.beam conftest.$ac_ext
20222 fi
20223
20224 fi
20225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
20226 $as_echo "$gl_cv_func_working_utimes" >&6; }
20227
20228 if test $gl_cv_func_working_utimes = yes; then
20229
20230 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
20231
20232 fi
20233
20234
20235
20236
20237
20238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
20239 $as_echo_n "checking for struct utimbuf... " >&6; }
20240 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
20241 $as_echo_n "(cached) " >&6
20242 else
20243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20244 /* end confdefs.h. */
20245 #if HAVE_SYS_TIME_H
20246 #include <sys/time.h>
20247 #endif
20248 #include <time.h>
20249 #ifdef HAVE_UTIME_H
20250 #include <utime.h>
20251 #endif
20252
20253 int
20254 main ()
20255 {
20256 static struct utimbuf x; x.actime = x.modtime;
20257 ;
20258 return 0;
20259 }
20260 _ACEOF
20261 if ac_fn_c_try_compile "$LINENO"; then :
20262 gl_cv_sys_struct_utimbuf=yes
20263 else
20264 gl_cv_sys_struct_utimbuf=no
20265 fi
20266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20267 fi
20268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
20269 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
20270
20271 if test $gl_cv_sys_struct_utimbuf = yes; then
20272
20273 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
20274
20275 fi
20276
20277
20278
20279
20280
20281
20282
20283
20284
20285
20286
20287
20288 if false; then
20289 GL_COND_LIBTOOL_TRUE=
20290 GL_COND_LIBTOOL_FALSE='#'
20291 else
20292 GL_COND_LIBTOOL_TRUE='#'
20293 GL_COND_LIBTOOL_FALSE=
20294 fi
20295
20296 gl_cond_libtool=false
20297 gl_libdeps=
20298 gl_ltlibdeps=
20299 gl_m4_base='m4'
20300
20301
20302
20303
20304
20305
20306
20307
20308
20309 gl_source_base='lib'
20310
20311
20312 if test $ac_cv_func_alloca_works = no; then
20313 :
20314 fi
20315
20316 # Define an additional variable used in the Makefile substitution.
20317 if test $ac_cv_working_alloca_h = yes; then
20318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20319 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20320 if test "${gl_cv_rpl_alloca+set}" = set; then :
20321 $as_echo_n "(cached) " >&6
20322 else
20323
20324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20325 /* end confdefs.h. */
20326
20327 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20328 Need own alloca
20329 #endif
20330
20331 _ACEOF
20332 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20333 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20334 gl_cv_rpl_alloca=yes
20335 else
20336 gl_cv_rpl_alloca=no
20337 fi
20338 rm -f conftest*
20339
20340
20341 fi
20342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20343 $as_echo "$gl_cv_rpl_alloca" >&6; }
20344 if test $gl_cv_rpl_alloca = yes; then
20345
20346 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20347
20348 ALLOCA_H=alloca.h
20349 else
20350 ALLOCA_H=
20351 fi
20352 else
20353 ALLOCA_H=alloca.h
20354 fi
20355
20356 if test -n "$ALLOCA_H"; then
20357 GL_GENERATE_ALLOCA_H_TRUE=
20358 GL_GENERATE_ALLOCA_H_FALSE='#'
20359 else
20360 GL_GENERATE_ALLOCA_H_TRUE='#'
20361 GL_GENERATE_ALLOCA_H_FALSE=
20362 fi
20363
20364
20365
20366
20367
20368
20369 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20370 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20371
20372 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20373 # programs in the package would end up linked with that potentially-shared
20374 # library, inducing unnecessary run-time overhead.
20375 LIB_CLOCK_GETTIME=
20376
20377 gl_saved_libs=$LIBS
20378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20379 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20380 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20381 $as_echo_n "(cached) " >&6
20382 else
20383 ac_func_search_save_LIBS=$LIBS
20384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20385 /* end confdefs.h. */
20386
20387 /* Override any GCC internal prototype to avoid an error.
20388 Use char because int might match the return type of a GCC
20389 builtin and then its argument prototype would still apply. */
20390 #ifdef __cplusplus
20391 extern "C"
20392 #endif
20393 char clock_gettime ();
20394 int
20395 main ()
20396 {
20397 return clock_gettime ();
20398 ;
20399 return 0;
20400 }
20401 _ACEOF
20402 for ac_lib in '' rt posix4; do
20403 if test -z "$ac_lib"; then
20404 ac_res="none required"
20405 else
20406 ac_res=-l$ac_lib
20407 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20408 fi
20409 if ac_fn_c_try_link "$LINENO"; then :
20410 ac_cv_search_clock_gettime=$ac_res
20411 fi
20412 rm -f core conftest.err conftest.$ac_objext \
20413 conftest$ac_exeext
20414 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20415 break
20416 fi
20417 done
20418 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20419
20420 else
20421 ac_cv_search_clock_gettime=no
20422 fi
20423 rm conftest.$ac_ext
20424 LIBS=$ac_func_search_save_LIBS
20425 fi
20426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20427 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20428 ac_res=$ac_cv_search_clock_gettime
20429 if test "$ac_res" != no; then :
20430 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20431 test "$ac_cv_search_clock_gettime" = "none required" ||
20432 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20433 fi
20434
20435 for ac_func in clock_gettime clock_settime
20436 do :
20437 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20438 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20439 eval as_val=\$$as_ac_var
20440 if test "x$as_val" = x""yes; then :
20441 cat >>confdefs.h <<_ACEOF
20442 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20443 _ACEOF
20444
20445 fi
20446 done
20447
20448 LIBS=$gl_saved_libs
20449
20450
20451
20452
20453 :
20454
20455
20456
20457
20458 :
20459
20460
20461
20462
20463
20464
20465
20466
20467
20468
20469
20470
20471
20472
20473
20474 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20475
20476
20477 if test $HAVE_DUP2 = 1; then
20478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20479 $as_echo_n "checking whether dup2 works... " >&6; }
20480 if test "${gl_cv_func_dup2_works+set}" = set; then :
20481 $as_echo_n "(cached) " >&6
20482 else
20483 if test "$cross_compiling" = yes; then :
20484 case "$host_os" in
20485 mingw*) # on this platform, dup2 always returns 0 for success
20486 gl_cv_func_dup2_works="guessing no" ;;
20487 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20488 gl_cv_func_dup2_works="guessing no" ;;
20489 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20490 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20491 gl_cv_func_dup2_works="guessing no" ;;
20492 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20493 gl_cv_func_dup2_works="guessing no" ;;
20494 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20495 gl_cv_func_dup2_works="guessing no" ;;
20496 *) gl_cv_func_dup2_works="guessing yes" ;;
20497 esac
20498 else
20499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20500 /* end confdefs.h. */
20501
20502 #include <unistd.h>
20503 #include <fcntl.h>
20504 #include <errno.h>
20505 int
20506 main ()
20507 {
20508 int result = 0;
20509 #ifdef FD_CLOEXEC
20510 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20511 result |= 1;
20512 #endif
20513 if (dup2 (1, 1) == 0)
20514 result |= 2;
20515 #ifdef FD_CLOEXEC
20516 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20517 result |= 4;
20518 #endif
20519 close (0);
20520 if (dup2 (0, 0) != -1)
20521 result |= 8;
20522 /* Many gnulib modules require POSIX conformance of EBADF. */
20523 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20524 result |= 16;
20525 return result;
20526
20527 ;
20528 return 0;
20529 }
20530
20531 _ACEOF
20532 if ac_fn_c_try_run "$LINENO"; then :
20533 gl_cv_func_dup2_works=yes
20534 else
20535 gl_cv_func_dup2_works=no
20536 fi
20537 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20538 conftest.$ac_objext conftest.beam conftest.$ac_ext
20539 fi
20540
20541
20542 fi
20543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20544 $as_echo "$gl_cv_func_dup2_works" >&6; }
20545 case "$gl_cv_func_dup2_works" in
20546 *yes) ;;
20547 *)
20548 REPLACE_DUP2=1
20549 ;;
20550 esac
20551 fi
20552
20553
20554 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20555
20556
20557
20558
20559
20560
20561
20562
20563 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20564
20565
20566 fi
20567
20568
20569
20570
20571
20572 GNULIB_DUP2=1
20573
20574
20575
20576
20577
20578
20579
20580
20581
20582
20583
20584 GNULIB_ENVIRON=1
20585
20586
20587
20588
20589
20590
20591
20592
20593 LIB_EXECINFO=''
20594 EXECINFO_H='execinfo.h'
20595
20596 if test $ac_cv_header_execinfo_h = yes; then
20597 gl_saved_libs=$LIBS
20598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20599 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20600 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20601 $as_echo_n "(cached) " >&6
20602 else
20603 ac_func_search_save_LIBS=$LIBS
20604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20605 /* end confdefs.h. */
20606
20607 /* Override any GCC internal prototype to avoid an error.
20608 Use char because int might match the return type of a GCC
20609 builtin and then its argument prototype would still apply. */
20610 #ifdef __cplusplus
20611 extern "C"
20612 #endif
20613 char backtrace_symbols_fd ();
20614 int
20615 main ()
20616 {
20617 return backtrace_symbols_fd ();
20618 ;
20619 return 0;
20620 }
20621 _ACEOF
20622 for ac_lib in '' execinfo; do
20623 if test -z "$ac_lib"; then
20624 ac_res="none required"
20625 else
20626 ac_res=-l$ac_lib
20627 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20628 fi
20629 if ac_fn_c_try_link "$LINENO"; then :
20630 ac_cv_search_backtrace_symbols_fd=$ac_res
20631 fi
20632 rm -f core conftest.err conftest.$ac_objext \
20633 conftest$ac_exeext
20634 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20635 break
20636 fi
20637 done
20638 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20639
20640 else
20641 ac_cv_search_backtrace_symbols_fd=no
20642 fi
20643 rm conftest.$ac_ext
20644 LIBS=$ac_func_search_save_LIBS
20645 fi
20646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20647 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20648 ac_res=$ac_cv_search_backtrace_symbols_fd
20649 if test "$ac_res" != no; then :
20650 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20651 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20652 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20653 fi
20654
20655 LIBS=$gl_saved_libs
20656 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20657 fi
20658
20659 if test -n "$EXECINFO_H"; then
20660
20661
20662
20663
20664
20665
20666
20667
20668 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20669
20670 fi
20671
20672
20673
20674 if test -n "$EXECINFO_H"; then
20675 GL_GENERATE_EXECINFO_H_TRUE=
20676 GL_GENERATE_EXECINFO_H_FALSE='#'
20677 else
20678 GL_GENERATE_EXECINFO_H_TRUE='#'
20679 GL_GENERATE_EXECINFO_H_FALSE=
20680 fi
20681
20682
20683
20684
20685
20686
20687
20688
20689
20690 # Persuade glibc <stdlib.h> to declare getloadavg().
20691
20692
20693 gl_save_LIBS=$LIBS
20694
20695 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20696 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20697 HAVE_GETLOADAVG=1
20698 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20699 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20700
20701 else
20702 gl_func_getloadavg_done=no
20703
20704 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20705 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20706 # to get the right answer into the cache.
20707 # For kstat on solaris, we need to test for libelf and libkvm to force the
20708 # definition of SVR4 below.
20709 if test $gl_func_getloadavg_done = no; then
20710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20711 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20712 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20713 $as_echo_n "(cached) " >&6
20714 else
20715 ac_check_lib_save_LIBS=$LIBS
20716 LIBS="-lelf $LIBS"
20717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20718 /* end confdefs.h. */
20719
20720 /* Override any GCC internal prototype to avoid an error.
20721 Use char because int might match the return type of a GCC
20722 builtin and then its argument prototype would still apply. */
20723 #ifdef __cplusplus
20724 extern "C"
20725 #endif
20726 char elf_begin ();
20727 int
20728 main ()
20729 {
20730 return elf_begin ();
20731 ;
20732 return 0;
20733 }
20734 _ACEOF
20735 if ac_fn_c_try_link "$LINENO"; then :
20736 ac_cv_lib_elf_elf_begin=yes
20737 else
20738 ac_cv_lib_elf_elf_begin=no
20739 fi
20740 rm -f core conftest.err conftest.$ac_objext \
20741 conftest$ac_exeext conftest.$ac_ext
20742 LIBS=$ac_check_lib_save_LIBS
20743 fi
20744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20745 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20746 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20747 LIBS="-lelf $LIBS"
20748 fi
20749
20750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20751 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20752 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20753 $as_echo_n "(cached) " >&6
20754 else
20755 ac_check_lib_save_LIBS=$LIBS
20756 LIBS="-lkvm $LIBS"
20757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20758 /* end confdefs.h. */
20759
20760 /* Override any GCC internal prototype to avoid an error.
20761 Use char because int might match the return type of a GCC
20762 builtin and then its argument prototype would still apply. */
20763 #ifdef __cplusplus
20764 extern "C"
20765 #endif
20766 char kvm_open ();
20767 int
20768 main ()
20769 {
20770 return kvm_open ();
20771 ;
20772 return 0;
20773 }
20774 _ACEOF
20775 if ac_fn_c_try_link "$LINENO"; then :
20776 ac_cv_lib_kvm_kvm_open=yes
20777 else
20778 ac_cv_lib_kvm_kvm_open=no
20779 fi
20780 rm -f core conftest.err conftest.$ac_objext \
20781 conftest$ac_exeext conftest.$ac_ext
20782 LIBS=$ac_check_lib_save_LIBS
20783 fi
20784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20785 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20786 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20787 LIBS="-lkvm $LIBS"
20788 fi
20789
20790 # Check for the 4.4BSD definition of getloadavg.
20791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20792 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20793 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20794 $as_echo_n "(cached) " >&6
20795 else
20796 ac_check_lib_save_LIBS=$LIBS
20797 LIBS="-lutil $LIBS"
20798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20799 /* end confdefs.h. */
20800
20801 /* Override any GCC internal prototype to avoid an error.
20802 Use char because int might match the return type of a GCC
20803 builtin and then its argument prototype would still apply. */
20804 #ifdef __cplusplus
20805 extern "C"
20806 #endif
20807 char getloadavg ();
20808 int
20809 main ()
20810 {
20811 return getloadavg ();
20812 ;
20813 return 0;
20814 }
20815 _ACEOF
20816 if ac_fn_c_try_link "$LINENO"; then :
20817 ac_cv_lib_util_getloadavg=yes
20818 else
20819 ac_cv_lib_util_getloadavg=no
20820 fi
20821 rm -f core conftest.err conftest.$ac_objext \
20822 conftest$ac_exeext conftest.$ac_ext
20823 LIBS=$ac_check_lib_save_LIBS
20824 fi
20825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20826 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20827 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20828 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20829 fi
20830
20831 fi
20832
20833 if test $gl_func_getloadavg_done = no; then
20834 # There is a commonly available library for RS/6000 AIX.
20835 # Since it is not a standard part of AIX, it might be installed locally.
20836 gl_getloadavg_LIBS=$LIBS
20837 LIBS="-L/usr/local/lib $LIBS"
20838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20839 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20840 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20841 $as_echo_n "(cached) " >&6
20842 else
20843 ac_check_lib_save_LIBS=$LIBS
20844 LIBS="-lgetloadavg $LIBS"
20845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20846 /* end confdefs.h. */
20847
20848 /* Override any GCC internal prototype to avoid an error.
20849 Use char because int might match the return type of a GCC
20850 builtin and then its argument prototype would still apply. */
20851 #ifdef __cplusplus
20852 extern "C"
20853 #endif
20854 char getloadavg ();
20855 int
20856 main ()
20857 {
20858 return getloadavg ();
20859 ;
20860 return 0;
20861 }
20862 _ACEOF
20863 if ac_fn_c_try_link "$LINENO"; then :
20864 ac_cv_lib_getloadavg_getloadavg=yes
20865 else
20866 ac_cv_lib_getloadavg_getloadavg=no
20867 fi
20868 rm -f core conftest.err conftest.$ac_objext \
20869 conftest$ac_exeext conftest.$ac_ext
20870 LIBS=$ac_check_lib_save_LIBS
20871 fi
20872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
20873 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20874 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20875 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20876 else
20877 LIBS=$gl_getloadavg_LIBS
20878 fi
20879
20880 fi
20881
20882 # Set up the replacement function if necessary.
20883 if test $gl_func_getloadavg_done = no; then
20884 HAVE_GETLOADAVG=0
20885
20886 # Solaris has libkstat which does not require root.
20887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20888 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20889 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20890 $as_echo_n "(cached) " >&6
20891 else
20892 ac_check_lib_save_LIBS=$LIBS
20893 LIBS="-lkstat $LIBS"
20894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20895 /* end confdefs.h. */
20896
20897 /* Override any GCC internal prototype to avoid an error.
20898 Use char because int might match the return type of a GCC
20899 builtin and then its argument prototype would still apply. */
20900 #ifdef __cplusplus
20901 extern "C"
20902 #endif
20903 char kstat_open ();
20904 int
20905 main ()
20906 {
20907 return kstat_open ();
20908 ;
20909 return 0;
20910 }
20911 _ACEOF
20912 if ac_fn_c_try_link "$LINENO"; then :
20913 ac_cv_lib_kstat_kstat_open=yes
20914 else
20915 ac_cv_lib_kstat_kstat_open=no
20916 fi
20917 rm -f core conftest.err conftest.$ac_objext \
20918 conftest$ac_exeext conftest.$ac_ext
20919 LIBS=$ac_check_lib_save_LIBS
20920 fi
20921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20922 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20923 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20924 cat >>confdefs.h <<_ACEOF
20925 #define HAVE_LIBKSTAT 1
20926 _ACEOF
20927
20928 LIBS="-lkstat $LIBS"
20929
20930 fi
20931
20932 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20933
20934 # AIX has libperfstat which does not require root
20935 if test $gl_func_getloadavg_done = no; then
20936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20937 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20938 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20939 $as_echo_n "(cached) " >&6
20940 else
20941 ac_check_lib_save_LIBS=$LIBS
20942 LIBS="-lperfstat $LIBS"
20943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20944 /* end confdefs.h. */
20945
20946 /* Override any GCC internal prototype to avoid an error.
20947 Use char because int might match the return type of a GCC
20948 builtin and then its argument prototype would still apply. */
20949 #ifdef __cplusplus
20950 extern "C"
20951 #endif
20952 char perfstat_cpu_total ();
20953 int
20954 main ()
20955 {
20956 return perfstat_cpu_total ();
20957 ;
20958 return 0;
20959 }
20960 _ACEOF
20961 if ac_fn_c_try_link "$LINENO"; then :
20962 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20963 else
20964 ac_cv_lib_perfstat_perfstat_cpu_total=no
20965 fi
20966 rm -f core conftest.err conftest.$ac_objext \
20967 conftest$ac_exeext conftest.$ac_ext
20968 LIBS=$ac_check_lib_save_LIBS
20969 fi
20970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20971 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20972 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20973 cat >>confdefs.h <<_ACEOF
20974 #define HAVE_LIBPERFSTAT 1
20975 _ACEOF
20976
20977 LIBS="-lperfstat $LIBS"
20978
20979 fi
20980
20981 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20982 fi
20983
20984 if test $gl_func_getloadavg_done = no; then
20985 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20986 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20987 gl_func_getloadavg_done=yes
20988
20989 $as_echo "#define DGUX 1" >>confdefs.h
20990
20991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20992 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20993 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20994 $as_echo_n "(cached) " >&6
20995 else
20996 ac_check_lib_save_LIBS=$LIBS
20997 LIBS="-ldgc $LIBS"
20998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20999 /* end confdefs.h. */
21000
21001 /* Override any GCC internal prototype to avoid an error.
21002 Use char because int might match the return type of a GCC
21003 builtin and then its argument prototype would still apply. */
21004 #ifdef __cplusplus
21005 extern "C"
21006 #endif
21007 char dg_sys_info ();
21008 int
21009 main ()
21010 {
21011 return dg_sys_info ();
21012 ;
21013 return 0;
21014 }
21015 _ACEOF
21016 if ac_fn_c_try_link "$LINENO"; then :
21017 ac_cv_lib_dgc_dg_sys_info=yes
21018 else
21019 ac_cv_lib_dgc_dg_sys_info=no
21020 fi
21021 rm -f core conftest.err conftest.$ac_objext \
21022 conftest$ac_exeext conftest.$ac_ext
21023 LIBS=$ac_check_lib_save_LIBS
21024 fi
21025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
21026 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
21027 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
21028 cat >>confdefs.h <<_ACEOF
21029 #define HAVE_LIBDGC 1
21030 _ACEOF
21031
21032 LIBS="-ldgc $LIBS"
21033
21034 fi
21035
21036 fi
21037
21038
21039 fi
21040 fi
21041 fi
21042
21043
21044 if test "x$gl_save_LIBS" = x; then
21045 GETLOADAVG_LIBS=$LIBS
21046 else
21047 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
21048 fi
21049 LIBS=$gl_save_LIBS
21050
21051
21052 # Test whether the system declares getloadavg. Solaris has the function
21053 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
21054 for ac_header in sys/loadavg.h
21055 do :
21056 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
21057 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
21058 cat >>confdefs.h <<_ACEOF
21059 #define HAVE_SYS_LOADAVG_H 1
21060 _ACEOF
21061
21062 fi
21063
21064 done
21065
21066 if test $ac_cv_header_sys_loadavg_h = yes; then
21067 HAVE_SYS_LOADAVG_H=1
21068 else
21069 HAVE_SYS_LOADAVG_H=0
21070 fi
21071 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
21072 # include <sys/loadavg.h>
21073 #endif
21074 #include <stdlib.h>
21075 "
21076 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
21077
21078 else
21079 HAVE_DECL_GETLOADAVG=0
21080 fi
21081
21082
21083 if test $HAVE_GETLOADAVG = 0; then
21084
21085
21086
21087
21088
21089
21090
21091
21092 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
21093
21094
21095 # Figure out what our getloadavg.c needs.
21096
21097
21098
21099 # On HPUX9, an unprivileged user can get load averages this way.
21100 if test $gl_func_getloadavg_done = no; then
21101 for ac_func in pstat_getdynamic
21102 do :
21103 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
21104 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
21105 cat >>confdefs.h <<_ACEOF
21106 #define HAVE_PSTAT_GETDYNAMIC 1
21107 _ACEOF
21108 gl_func_getloadavg_done=yes
21109 fi
21110 done
21111
21112 fi
21113
21114 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
21115 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
21116 # Irix 4.0.5F has the header but not the library.
21117 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
21118 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
21119 gl_func_getloadavg_done=yes
21120
21121 $as_echo "#define SVR4 1" >>confdefs.h
21122
21123 fi
21124
21125 if test $gl_func_getloadavg_done = no; then
21126 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
21127 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
21128 gl_func_getloadavg_done=yes
21129
21130 $as_echo "#define UMAX 1" >>confdefs.h
21131
21132
21133 $as_echo "#define UMAX4_3 1" >>confdefs.h
21134
21135 fi
21136
21137
21138 fi
21139
21140 if test $gl_func_getloadavg_done = no; then
21141 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
21142 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
21143 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
21144
21145 fi
21146
21147
21148 fi
21149
21150 if test $gl_func_getloadavg_done = no; then
21151 for ac_header in mach/mach.h
21152 do :
21153 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
21154 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
21155 cat >>confdefs.h <<_ACEOF
21156 #define HAVE_MACH_MACH_H 1
21157 _ACEOF
21158
21159 fi
21160
21161 done
21162
21163 fi
21164
21165 for ac_header in nlist.h
21166 do :
21167 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
21168 if test "x$ac_cv_header_nlist_h" = x""yes; then :
21169 cat >>confdefs.h <<_ACEOF
21170 #define HAVE_NLIST_H 1
21171 _ACEOF
21172 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
21173 "
21174 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
21175
21176 cat >>confdefs.h <<_ACEOF
21177 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
21178 _ACEOF
21179
21180
21181 fi
21182
21183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21184 /* end confdefs.h. */
21185 #include <nlist.h>
21186 int
21187 main ()
21188 {
21189 struct nlist x;
21190 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
21191 x.n_un.n_name = "";
21192 #else
21193 x.n_name = "";
21194 #endif
21195 ;
21196 return 0;
21197 }
21198 _ACEOF
21199 if ac_fn_c_try_link "$LINENO"; then :
21200
21201 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
21202
21203 fi
21204 rm -f core conftest.err conftest.$ac_objext \
21205 conftest$ac_exeext conftest.$ac_ext
21206
21207 fi
21208
21209 done
21210
21211 fi
21212
21213
21214
21215
21216
21217 GNULIB_GETLOADAVG=1
21218
21219
21220
21221
21222
21223
21224
21225
21226
21227
21228 if test $REPLACE_GETOPT = 1; then
21229
21230
21231
21232
21233
21234
21235
21236
21237 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21238
21239
21240
21241
21242
21243
21244
21245
21246
21247 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21248
21249
21250
21251
21252 GNULIB_GL_UNISTD_H_GETOPT=1
21253 fi
21254
21255
21256
21257
21258
21259
21260
21261 REPLACE_GETOPT=0
21262 if test -n "$gl_replace_getopt"; then
21263 REPLACE_GETOPT=1
21264 fi
21265
21266 if test $REPLACE_GETOPT = 1; then
21267
21268 GETOPT_H=getopt.h
21269
21270 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
21271
21272
21273
21274 fi
21275
21276 if test $REPLACE_GETOPT = 1; then
21277
21278
21279
21280
21281
21282
21283
21284
21285 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21286
21287
21288
21289
21290
21291
21292
21293
21294
21295 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21296
21297
21298
21299
21300 GNULIB_GL_UNISTD_H_GETOPT=1
21301 fi
21302
21303
21304
21305
21306
21307
21308
21309
21310
21311
21312
21313
21314 gl_gettimeofday_timezone=void
21315 if test $ac_cv_func_gettimeofday != yes; then
21316 HAVE_GETTIMEOFDAY=0
21317 else
21318
21319
21320
21321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21322 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21323 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21324 $as_echo_n "(cached) " >&6
21325 else
21326 if test "$cross_compiling" = yes; then :
21327 # When cross-compiling:
21328 case "$host_os" in
21329 # Guess all is fine on glibc systems.
21330 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21331 # If we don't know, assume the worst.
21332 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21333 esac
21334
21335 else
21336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21337 /* end confdefs.h. */
21338 #include <string.h>
21339 #include <sys/time.h>
21340 #include <time.h>
21341 #include <stdlib.h>
21342
21343 int
21344 main ()
21345 {
21346
21347 time_t t = 0;
21348 struct tm *lt;
21349 struct tm saved_lt;
21350 struct timeval tv;
21351 lt = localtime (&t);
21352 saved_lt = *lt;
21353 gettimeofday (&tv, NULL);
21354 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21355
21356 ;
21357 return 0;
21358 }
21359 _ACEOF
21360 if ac_fn_c_try_run "$LINENO"; then :
21361 gl_cv_func_gettimeofday_clobber=no
21362 else
21363 gl_cv_func_gettimeofday_clobber=yes
21364 fi
21365 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21366 conftest.$ac_objext conftest.beam conftest.$ac_ext
21367 fi
21368
21369 fi
21370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21371 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21372
21373 case "$gl_cv_func_gettimeofday_clobber" in
21374 *yes)
21375 REPLACE_GETTIMEOFDAY=1
21376
21377
21378 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21379
21380
21381 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21382
21383
21384
21385 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21386
21387 ;;
21388 esac
21389
21390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21391 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21392 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21393 $as_echo_n "(cached) " >&6
21394 else
21395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21396 /* end confdefs.h. */
21397 #include <sys/time.h>
21398 struct timeval c;
21399 int gettimeofday (struct timeval *restrict, void *restrict);
21400
21401 int
21402 main ()
21403 {
21404 /* glibc uses struct timezone * rather than the POSIX void *
21405 if _GNU_SOURCE is defined. However, since the only portable
21406 use of gettimeofday uses NULL as the second parameter, and
21407 since the glibc definition is actually more typesafe, it is
21408 not worth wrapping this to get a compliant signature. */
21409 int (*f) (struct timeval *restrict, void *restrict)
21410 = gettimeofday;
21411 int x = f (&c, 0);
21412 return !(x | c.tv_sec | c.tv_usec);
21413
21414 ;
21415 return 0;
21416 }
21417 _ACEOF
21418 if ac_fn_c_try_compile "$LINENO"; then :
21419 gl_cv_func_gettimeofday_posix_signature=yes
21420 else
21421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21422 /* end confdefs.h. */
21423 #include <sys/time.h>
21424 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21425
21426 int
21427 main ()
21428 {
21429
21430 ;
21431 return 0;
21432 }
21433 _ACEOF
21434 if ac_fn_c_try_compile "$LINENO"; then :
21435 gl_cv_func_gettimeofday_posix_signature=almost
21436 else
21437 gl_cv_func_gettimeofday_posix_signature=no
21438 fi
21439 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21440 fi
21441 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21442 fi
21443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21444 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21445 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21446 gl_gettimeofday_timezone='struct timezone'
21447 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21448 REPLACE_GETTIMEOFDAY=1
21449 fi
21450 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21451 REPLACE_GETTIMEOFDAY=1
21452 fi
21453
21454 fi
21455
21456 cat >>confdefs.h <<_ACEOF
21457 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21458 _ACEOF
21459
21460
21461 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21462
21463
21464
21465
21466
21467
21468
21469
21470 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21471
21472
21473 for ac_header in sys/timeb.h
21474 do :
21475 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21476 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21477 cat >>confdefs.h <<_ACEOF
21478 #define HAVE_SYS_TIMEB_H 1
21479 _ACEOF
21480
21481 fi
21482
21483 done
21484
21485 for ac_func in _ftime
21486 do :
21487 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21488 if test "x$ac_cv_func__ftime" = x""yes; then :
21489 cat >>confdefs.h <<_ACEOF
21490 #define HAVE__FTIME 1
21491 _ACEOF
21492
21493 fi
21494 done
21495
21496
21497 fi
21498
21499
21500
21501
21502
21503 GNULIB_GETTIMEOFDAY=1
21504
21505
21506
21507
21508
21509
21510
21511
21512
21513
21514 if test $ac_cv_func_lstat = yes; then
21515
21516 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21517 *no)
21518 REPLACE_LSTAT=1
21519 ;;
21520 esac
21521 else
21522 HAVE_LSTAT=0
21523 fi
21524
21525 if test $REPLACE_LSTAT = 1; then
21526
21527
21528
21529
21530
21531
21532
21533
21534 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21535
21536
21537
21538 :
21539
21540 fi
21541
21542
21543
21544
21545
21546 GNULIB_LSTAT=1
21547
21548
21549
21550
21551
21552
21553
21554
21555
21556
21557
21558 if test $APPLE_UNIVERSAL_BUILD = 1; then
21559 # A universal build on Apple Mac OS X platforms.
21560 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21561 # But we need a configuration result that is valid in both modes.
21562 gl_cv_func_working_mktime=no
21563 fi
21564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21565 $as_echo_n "checking for working mktime... " >&6; }
21566 if test "${gl_cv_func_working_mktime+set}" = set; then :
21567 $as_echo_n "(cached) " >&6
21568 else
21569 if test "$cross_compiling" = yes; then :
21570 gl_cv_func_working_mktime=no
21571 else
21572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21573 /* end confdefs.h. */
21574 /* Test program from Paul Eggert and Tony Leneis. */
21575 #include <limits.h>
21576 #include <stdlib.h>
21577 #include <time.h>
21578
21579 #ifdef HAVE_UNISTD_H
21580 # include <unistd.h>
21581 #endif
21582
21583 #ifndef HAVE_ALARM
21584 # define alarm(X) /* empty */
21585 #endif
21586
21587 /* Work around redefinition to rpl_putenv by other config tests. */
21588 #undef putenv
21589
21590 static time_t time_t_max;
21591 static time_t time_t_min;
21592
21593 /* Values we'll use to set the TZ environment variable. */
21594 static char *tz_strings[] = {
21595 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21596 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21597 };
21598 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21599
21600 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21601 Based on a problem report from Andreas Jaeger. */
21602 static int
21603 spring_forward_gap ()
21604 {
21605 /* glibc (up to about 1998-10-07) failed this test. */
21606 struct tm tm;
21607
21608 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21609 instead of "TZ=America/Vancouver" in order to detect the bug even
21610 on systems that don't support the Olson extension, or don't have the
21611 full zoneinfo tables installed. */
21612 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21613
21614 tm.tm_year = 98;
21615 tm.tm_mon = 3;
21616 tm.tm_mday = 5;
21617 tm.tm_hour = 2;
21618 tm.tm_min = 0;
21619 tm.tm_sec = 0;
21620 tm.tm_isdst = -1;
21621 return mktime (&tm) != (time_t) -1;
21622 }
21623
21624 static int
21625 mktime_test1 (time_t now)
21626 {
21627 struct tm *lt;
21628 return ! (lt = localtime (&now)) || mktime (lt) == now;
21629 }
21630
21631 static int
21632 mktime_test (time_t now)
21633 {
21634 return (mktime_test1 (now)
21635 && mktime_test1 ((time_t) (time_t_max - now))
21636 && mktime_test1 ((time_t) (time_t_min + now)));
21637 }
21638
21639 static int
21640 irix_6_4_bug ()
21641 {
21642 /* Based on code from Ariel Faigon. */
21643 struct tm tm;
21644 tm.tm_year = 96;
21645 tm.tm_mon = 3;
21646 tm.tm_mday = 0;
21647 tm.tm_hour = 0;
21648 tm.tm_min = 0;
21649 tm.tm_sec = 0;
21650 tm.tm_isdst = -1;
21651 mktime (&tm);
21652 return tm.tm_mon == 2 && tm.tm_mday == 31;
21653 }
21654
21655 static int
21656 bigtime_test (int j)
21657 {
21658 struct tm tm;
21659 time_t now;
21660 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21661 now = mktime (&tm);
21662 if (now != (time_t) -1)
21663 {
21664 struct tm *lt = localtime (&now);
21665 if (! (lt
21666 && lt->tm_year == tm.tm_year
21667 && lt->tm_mon == tm.tm_mon
21668 && lt->tm_mday == tm.tm_mday
21669 && lt->tm_hour == tm.tm_hour
21670 && lt->tm_min == tm.tm_min
21671 && lt->tm_sec == tm.tm_sec
21672 && lt->tm_yday == tm.tm_yday
21673 && lt->tm_wday == tm.tm_wday
21674 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21675 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21676 return 0;
21677 }
21678 return 1;
21679 }
21680
21681 static int
21682 year_2050_test ()
21683 {
21684 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21685 ignoring leap seconds. */
21686 unsigned long int answer = 2527315200UL;
21687
21688 struct tm tm;
21689 time_t t;
21690 tm.tm_year = 2050 - 1900;
21691 tm.tm_mon = 2 - 1;
21692 tm.tm_mday = 1;
21693 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21694 tm.tm_isdst = -1;
21695
21696 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21697 instead of "TZ=America/Vancouver" in order to detect the bug even
21698 on systems that don't support the Olson extension, or don't have the
21699 full zoneinfo tables installed. */
21700 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21701
21702 t = mktime (&tm);
21703
21704 /* Check that the result is either a failure, or close enough
21705 to the correct answer that we can assume the discrepancy is
21706 due to leap seconds. */
21707 return (t == (time_t) -1
21708 || (0 < t && answer - 120 <= t && t <= answer + 120));
21709 }
21710
21711 int
21712 main ()
21713 {
21714 int result = 0;
21715 time_t t, delta;
21716 int i, j;
21717 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21718 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21719
21720 /* This test makes some buggy mktime implementations loop.
21721 Give up after 60 seconds; a mktime slower than that
21722 isn't worth using anyway. */
21723 alarm (60);
21724
21725 time_t_max = (! time_t_signed
21726 ? (time_t) -1
21727 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21728 * 2 + 1));
21729 time_t_min = (! time_t_signed
21730 ? (time_t) 0
21731 : time_t_signed_magnitude
21732 ? ~ (time_t) 0
21733 : ~ time_t_max);
21734
21735 delta = time_t_max / 997; /* a suitable prime number */
21736 for (i = 0; i < N_STRINGS; i++)
21737 {
21738 if (tz_strings[i])
21739 putenv (tz_strings[i]);
21740
21741 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21742 if (! mktime_test (t))
21743 result |= 1;
21744 if ((result & 2) == 0
21745 && ! (mktime_test ((time_t) 1)
21746 && mktime_test ((time_t) (60 * 60))
21747 && mktime_test ((time_t) (60 * 60 * 24))))
21748 result |= 2;
21749
21750 for (j = 1; (result & 4) == 0; j <<= 1)
21751 {
21752 if (! bigtime_test (j))
21753 result |= 4;
21754 if (INT_MAX / 2 < j)
21755 break;
21756 }
21757 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21758 result |= 8;
21759 }
21760 if (! irix_6_4_bug ())
21761 result |= 16;
21762 if (! spring_forward_gap ())
21763 result |= 32;
21764 if (! year_2050_test ())
21765 result |= 64;
21766 return result;
21767 }
21768 _ACEOF
21769 if ac_fn_c_try_run "$LINENO"; then :
21770 gl_cv_func_working_mktime=yes
21771 else
21772 gl_cv_func_working_mktime=no
21773 fi
21774 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21775 conftest.$ac_objext conftest.beam conftest.$ac_ext
21776 fi
21777
21778
21779 fi
21780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21781 $as_echo "$gl_cv_func_working_mktime" >&6; }
21782
21783 if test $gl_cv_func_working_mktime = no; then
21784 REPLACE_MKTIME=1
21785 else
21786 REPLACE_MKTIME=0
21787 fi
21788
21789 if test $REPLACE_MKTIME = 1; then
21790
21791
21792
21793
21794
21795
21796
21797
21798 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21799
21800 :
21801 fi
21802
21803
21804
21805
21806
21807 GNULIB_MKTIME=1
21808
21809
21810
21811
21812
21813
21814
21815
21816
21817
21818
21819 if test $ac_cv_func_pselect = yes; then
21820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21821 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21822 if test "${gl_cv_sig_pselect+set}" = set; then :
21823 $as_echo_n "(cached) " >&6
21824 else
21825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21826 /* end confdefs.h. */
21827 #include <sys/select.h>
21828
21829 int
21830 main ()
21831 {
21832 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21833 struct timespec const *restrict,
21834 sigset_t const *restrict) = pselect;
21835 return !p;
21836 ;
21837 return 0;
21838 }
21839 _ACEOF
21840 if ac_fn_c_try_link "$LINENO"; then :
21841 gl_cv_sig_pselect=yes
21842 else
21843 gl_cv_sig_pselect=no
21844 fi
21845 rm -f core conftest.err conftest.$ac_objext \
21846 conftest$ac_exeext conftest.$ac_ext
21847 fi
21848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21849 $as_echo "$gl_cv_sig_pselect" >&6; }
21850
21851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
21852 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
21853 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
21854 $as_echo_n "(cached) " >&6
21855 else
21856
21857 if test "$cross_compiling" = yes; then :
21858
21859 case "$host_os" in
21860 # Guess yes on glibc systems.
21861 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
21862 # If we don't know, assume the worst.
21863 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
21864 esac
21865
21866 else
21867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21868 /* end confdefs.h. */
21869
21870 #include <sys/types.h>
21871 #include <sys/time.h>
21872 #if HAVE_SYS_SELECT_H
21873 # include <sys/select.h>
21874 #endif
21875 #include <unistd.h>
21876 #include <errno.h>
21877
21878 int
21879 main ()
21880 {
21881
21882 fd_set set;
21883 dup2(0, 16);
21884 FD_ZERO(&set);
21885 FD_SET(16, &set);
21886 close(16);
21887 struct timespec timeout;
21888 timeout.tv_sec = 0;
21889 timeout.tv_nsec = 5000;
21890 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
21891
21892 ;
21893 return 0;
21894 }
21895 _ACEOF
21896 if ac_fn_c_try_run "$LINENO"; then :
21897 gl_cv_func_pselect_detects_ebadf=yes
21898 else
21899 gl_cv_func_pselect_detects_ebadf=no
21900 fi
21901 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21902 conftest.$ac_objext conftest.beam conftest.$ac_ext
21903 fi
21904
21905
21906 fi
21907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
21908 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
21909 case $gl_cv_func_pselect_detects_ebadf in
21910 *yes) ;;
21911 *) REPLACE_PSELECT=1 ;;
21912 esac
21913 fi
21914
21915 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21916 REPLACE_PSELECT=1
21917 fi
21918
21919 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21920
21921
21922
21923
21924
21925
21926
21927
21928 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21929
21930 fi
21931
21932
21933
21934
21935
21936 GNULIB_PSELECT=1
21937
21938
21939
21940
21941
21942
21943
21944
21945
21946 LIB_PTHREAD_SIGMASK=
21947
21948
21949
21950
21951 if test "$gl_threads_api" = posix; then
21952 if test $ac_cv_func_pthread_sigmask = yes; then
21953 :
21954 else
21955 if test -n "$LIBMULTITHREAD"; then
21956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
21957 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
21958 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
21959 $as_echo_n "(cached) " >&6
21960 else
21961 gl_save_LIBS="$LIBS"
21962 LIBS="$LIBS $LIBMULTITHREAD"
21963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21964 /* end confdefs.h. */
21965 #include <pthread.h>
21966 #include <signal.h>
21967
21968 int
21969 main ()
21970 {
21971 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
21972 ;
21973 return 0;
21974 }
21975
21976 _ACEOF
21977 if ac_fn_c_try_link "$LINENO"; then :
21978 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
21979 else
21980 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
21981 fi
21982 rm -f core conftest.err conftest.$ac_objext \
21983 conftest$ac_exeext conftest.$ac_ext
21984 LIBS="$gl_save_LIBS"
21985
21986 fi
21987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
21988 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
21989 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
21990 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
21991 else
21992 HAVE_PTHREAD_SIGMASK=0
21993 fi
21994 else
21995 HAVE_PTHREAD_SIGMASK=0
21996 fi
21997 fi
21998 else
21999 if test $ac_cv_func_pthread_sigmask = yes; then
22000 REPLACE_PTHREAD_SIGMASK=1
22001 else
22002 HAVE_PTHREAD_SIGMASK=0
22003 fi
22004 fi
22005
22006
22007
22008
22009 if test $HAVE_PTHREAD_SIGMASK = 1; then
22010
22011
22012 if test -z "$LIB_PTHREAD_SIGMASK"; then
22013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
22014 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
22015 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
22016 $as_echo_n "(cached) " >&6
22017 else
22018
22019 if test "$cross_compiling" = yes; then :
22020
22021 case "$host_os" in
22022 freebsd* | hpux* | solaris | solaris2.[2-9]*)
22023 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
22024 *)
22025 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
22026 esac
22027
22028 else
22029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22030 /* end confdefs.h. */
22031
22032 #include <pthread.h>
22033 #include <signal.h>
22034 #include <stddef.h>
22035 int main ()
22036 {
22037 sigset_t set;
22038 sigemptyset (&set);
22039 return pthread_sigmask (1729, &set, NULL) != 0;
22040 }
22041 _ACEOF
22042 if ac_fn_c_try_run "$LINENO"; then :
22043 gl_cv_func_pthread_sigmask_in_libc_works=no
22044 else
22045 gl_cv_func_pthread_sigmask_in_libc_works=yes
22046 fi
22047 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22048 conftest.$ac_objext conftest.beam conftest.$ac_ext
22049 fi
22050
22051
22052 fi
22053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
22054 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
22055 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
22056 *no)
22057 REPLACE_PTHREAD_SIGMASK=1
22058
22059 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
22060
22061 ;;
22062 esac
22063 fi
22064
22065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
22066 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
22067 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
22068 $as_echo_n "(cached) " >&6
22069 else
22070
22071 gl_save_LIBS="$LIBS"
22072 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
22073 if test "$cross_compiling" = yes; then :
22074 case "$host_os" in
22075 cygwin*)
22076 gl_cv_func_pthread_sigmask_return_works="guessing no";;
22077 *)
22078 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
22079 esac
22080
22081 else
22082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22083 /* end confdefs.h. */
22084
22085 #include <pthread.h>
22086 #include <signal.h>
22087 #include <stddef.h>
22088 int main ()
22089 {
22090 sigset_t set;
22091 sigemptyset (&set);
22092 if (pthread_sigmask (1729, &set, NULL) == -1)
22093 return 1;
22094 return 0;
22095 }
22096 _ACEOF
22097 if ac_fn_c_try_run "$LINENO"; then :
22098 gl_cv_func_pthread_sigmask_return_works=yes
22099 else
22100 gl_cv_func_pthread_sigmask_return_works=no
22101 fi
22102 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22103 conftest.$ac_objext conftest.beam conftest.$ac_ext
22104 fi
22105
22106 LIBS="$gl_save_LIBS"
22107
22108 fi
22109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
22110 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
22111 case "$gl_cv_func_pthread_sigmask_return_works" in
22112 *no)
22113 REPLACE_PTHREAD_SIGMASK=1
22114
22115 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
22116
22117 ;;
22118 esac
22119
22120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
22121 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
22122 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
22123 $as_echo_n "(cached) " >&6
22124 else
22125
22126 case "$host_os" in
22127 irix*)
22128 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
22129 *)
22130 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
22131 esac
22132 gl_save_LIBS="$LIBS"
22133 LIBS="$LIBS $LIBMULTITHREAD"
22134 if test "$cross_compiling" = yes; then :
22135 :
22136 else
22137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22138 /* end confdefs.h. */
22139
22140 #include <pthread.h>
22141 #include <signal.h>
22142 #include <stdio.h>
22143 #include <stdlib.h>
22144 #include <unistd.h>
22145 static volatile int sigint_occurred;
22146 static void
22147 sigint_handler (int sig)
22148 {
22149 sigint_occurred++;
22150 }
22151 int main ()
22152 {
22153 sigset_t set;
22154 int pid = getpid ();
22155 char command[80];
22156 signal (SIGINT, sigint_handler);
22157 sigemptyset (&set);
22158 sigaddset (&set, SIGINT);
22159 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
22160 return 1;
22161 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
22162 if (!(system (command) == 0))
22163 return 2;
22164 sleep (2);
22165 if (!(sigint_occurred == 0))
22166 return 3;
22167 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
22168 return 4;
22169 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
22170 return 5;
22171 return 0;
22172 }
22173 _ACEOF
22174 if ac_fn_c_try_run "$LINENO"; then :
22175 :
22176 else
22177 gl_cv_func_pthread_sigmask_unblock_works=no
22178 fi
22179 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22180 conftest.$ac_objext conftest.beam conftest.$ac_ext
22181 fi
22182
22183 LIBS="$gl_save_LIBS"
22184
22185 fi
22186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
22187 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
22188 case "$gl_cv_func_pthread_sigmask_unblock_works" in
22189 *no)
22190 REPLACE_PTHREAD_SIGMASK=1
22191
22192 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
22193
22194 ;;
22195 esac
22196 fi
22197
22198 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22199
22200
22201
22202
22203
22204
22205
22206
22207 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
22208
22209
22210 if test $HAVE_PTHREAD_SIGMASK = 1; then
22211
22212 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
22213
22214 fi
22215
22216 fi
22217
22218
22219
22220
22221
22222 GNULIB_PTHREAD_SIGMASK=1
22223
22224
22225
22226
22227
22228
22229
22230
22231 if test $ac_cv_func_readlink = no; then
22232 HAVE_READLINK=0
22233 else
22234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
22235 $as_echo_n "checking whether readlink signature is correct... " >&6; }
22236 if test "${gl_cv_decl_readlink_works+set}" = set; then :
22237 $as_echo_n "(cached) " >&6
22238 else
22239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22240 /* end confdefs.h. */
22241 #include <unistd.h>
22242 /* Cause compilation failure if original declaration has wrong type. */
22243 ssize_t readlink (const char *, char *, size_t);
22244 int
22245 main ()
22246 {
22247
22248 ;
22249 return 0;
22250 }
22251 _ACEOF
22252 if ac_fn_c_try_compile "$LINENO"; then :
22253 gl_cv_decl_readlink_works=yes
22254 else
22255 gl_cv_decl_readlink_works=no
22256 fi
22257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22258 fi
22259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
22260 $as_echo "$gl_cv_decl_readlink_works" >&6; }
22261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
22262 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
22263 if test "${gl_cv_func_readlink_works+set}" = set; then :
22264 $as_echo_n "(cached) " >&6
22265 else
22266 # We have readlink, so assume ln -s works.
22267 ln -s conftest.no-such conftest.link
22268 ln -s conftest.link conftest.lnk2
22269 if test "$cross_compiling" = yes; then :
22270 case "$host_os" in
22271 # Guess yes on glibc systems.
22272 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
22273 # If we don't know, assume the worst.
22274 *) gl_cv_func_readlink_works="guessing no" ;;
22275 esac
22276
22277 else
22278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22279 /* end confdefs.h. */
22280 #include <unistd.h>
22281
22282 int
22283 main ()
22284 {
22285 char buf[20];
22286 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
22287 ;
22288 return 0;
22289 }
22290 _ACEOF
22291 if ac_fn_c_try_run "$LINENO"; then :
22292 gl_cv_func_readlink_works=yes
22293 else
22294 gl_cv_func_readlink_works=no
22295 fi
22296 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22297 conftest.$ac_objext conftest.beam conftest.$ac_ext
22298 fi
22299
22300 rm -f conftest.link conftest.lnk2
22301 fi
22302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
22303 $as_echo "$gl_cv_func_readlink_works" >&6; }
22304 case "$gl_cv_func_readlink_works" in
22305 *yes)
22306 if test "$gl_cv_decl_readlink_works" != yes; then
22307 REPLACE_READLINK=1
22308 fi
22309 ;;
22310 *)
22311
22312 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
22313
22314 REPLACE_READLINK=1
22315 ;;
22316 esac
22317 fi
22318
22319 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22320
22321
22322
22323
22324
22325
22326
22327
22328 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
22329
22330
22331 :
22332
22333 fi
22334
22335
22336
22337
22338
22339 GNULIB_READLINK=1
22340
22341
22342
22343
22344
22345
22346
22347
22348
22349
22350
22351
22352
22353
22354
22355
22356 if test $gl_cv_have_include_next = yes; then
22357 gl_cv_next_signal_h='<'signal.h'>'
22358 else
22359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22360 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22361 if test "${gl_cv_next_signal_h+set}" = set; then :
22362 $as_echo_n "(cached) " >&6
22363 else
22364
22365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22366 /* end confdefs.h. */
22367 #include <signal.h>
22368
22369 _ACEOF
22370 case "$host_os" in
22371 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22372 *) gl_absname_cpp="$ac_cpp" ;;
22373 esac
22374
22375 case "$host_os" in
22376 mingw*)
22377 gl_dirsep_regex='[/\\]'
22378 ;;
22379 *)
22380 gl_dirsep_regex='\/'
22381 ;;
22382 esac
22383 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22384
22385 gl_header_literal_regex=`echo 'signal.h' \
22386 | sed -e "$gl_make_literal_regex_sed"`
22387 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22388 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22389 s|^/[^/]|//&|
22390 p
22391 q
22392 }'
22393 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22394 sed -n "$gl_absolute_header_sed"`'"'
22395
22396
22397 fi
22398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22399 $as_echo "$gl_cv_next_signal_h" >&6; }
22400 fi
22401 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22402
22403 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22404 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22405 gl_next_as_first_directive='<'signal.h'>'
22406 else
22407 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22408 gl_next_as_first_directive=$gl_cv_next_signal_h
22409 fi
22410 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22411
22412
22413
22414
22415
22416 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22417 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22418 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22419 #include <signal.h>
22420
22421 "
22422 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22423
22424 else
22425 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22426 fi
22427
22428
22429
22430
22431
22432
22433
22434 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22435 #include <signal.h>
22436
22437 "
22438 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22439
22440 else
22441 HAVE_SIGHANDLER_T=0
22442 fi
22443
22444
22445
22446
22447 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22448 /* <sys/types.h> is not needed according to POSIX, but the
22449 <sys/socket.h> in i386-unknown-freebsd4.10 and
22450 powerpc-apple-darwin5.5 required it. */
22451 #include <sys/types.h>
22452 #if HAVE_SYS_SOCKET_H
22453 # include <sys/socket.h>
22454 #elif HAVE_WS2TCPIP_H
22455 # include <ws2tcpip.h>
22456 #endif
22457
22458 "
22459 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22460
22461 else
22462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22463 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22464 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22465 $as_echo_n "(cached) " >&6
22466 else
22467 # Systems have either "struct sockaddr *" or
22468 # "void *" as the second argument to getpeername
22469 gl_cv_socklen_t_equiv=
22470 for arg2 in "struct sockaddr" void; do
22471 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22473 /* end confdefs.h. */
22474 #include <sys/types.h>
22475 #include <sys/socket.h>
22476
22477 int getpeername (int, $arg2 *, $t *);
22478 int
22479 main ()
22480 {
22481 $t len;
22482 getpeername (0, 0, &len);
22483 ;
22484 return 0;
22485 }
22486 _ACEOF
22487 if ac_fn_c_try_compile "$LINENO"; then :
22488 gl_cv_socklen_t_equiv="$t"
22489 fi
22490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22491 test "$gl_cv_socklen_t_equiv" != "" && break
22492 done
22493 test "$gl_cv_socklen_t_equiv" != "" && break
22494 done
22495
22496 fi
22497
22498 if test "$gl_cv_socklen_t_equiv" = ""; then
22499 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22500 fi
22501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22502 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
22503
22504 cat >>confdefs.h <<_ACEOF
22505 #define socklen_t $gl_cv_socklen_t_equiv
22506 _ACEOF
22507
22508 fi
22509
22510
22511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22512 $as_echo_n "checking for ssize_t... " >&6; }
22513 if test "${gt_cv_ssize_t+set}" = set; then :
22514 $as_echo_n "(cached) " >&6
22515 else
22516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22517 /* end confdefs.h. */
22518 #include <sys/types.h>
22519 int
22520 main ()
22521 {
22522 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22523 return !x;
22524 ;
22525 return 0;
22526 }
22527 _ACEOF
22528 if ac_fn_c_try_compile "$LINENO"; then :
22529 gt_cv_ssize_t=yes
22530 else
22531 gt_cv_ssize_t=no
22532 fi
22533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22534 fi
22535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
22536 $as_echo "$gt_cv_ssize_t" >&6; }
22537 if test $gt_cv_ssize_t = no; then
22538
22539 $as_echo "#define ssize_t int" >>confdefs.h
22540
22541 fi
22542
22543
22544
22545
22546
22547 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>
22548 #include <sys/stat.h>
22549 "
22550 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
22551
22552 cat >>confdefs.h <<_ACEOF
22553 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
22554 _ACEOF
22555
22556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
22557 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
22558 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
22559 $as_echo_n "(cached) " >&6
22560 else
22561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22562 /* end confdefs.h. */
22563
22564 #include <sys/types.h>
22565 #include <sys/stat.h>
22566 #if HAVE_SYS_TIME_H
22567 # include <sys/time.h>
22568 #endif
22569 #include <time.h>
22570 struct timespec ts;
22571 struct stat st;
22572
22573 int
22574 main ()
22575 {
22576
22577 st.st_atim = ts;
22578
22579 ;
22580 return 0;
22581 }
22582 _ACEOF
22583 if ac_fn_c_try_compile "$LINENO"; then :
22584 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
22585 else
22586 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
22587 fi
22588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22589 fi
22590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
22591 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
22592 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
22593
22594 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
22595
22596 fi
22597 else
22598 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>
22599 #include <sys/stat.h>
22600 "
22601 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
22602
22603 cat >>confdefs.h <<_ACEOF
22604 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
22605 _ACEOF
22606
22607
22608 else
22609 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
22610 #include <sys/stat.h>
22611 "
22612 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
22613
22614 cat >>confdefs.h <<_ACEOF
22615 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
22616 _ACEOF
22617
22618
22619 else
22620 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>
22621 #include <sys/stat.h>
22622 "
22623 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
22624
22625 cat >>confdefs.h <<_ACEOF
22626 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
22627 _ACEOF
22628
22629
22630 fi
22631
22632 fi
22633
22634 fi
22635
22636 fi
22637
22638
22639
22640
22641
22642 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>
22643 #include <sys/stat.h>
22644 "
22645 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
22646
22647 cat >>confdefs.h <<_ACEOF
22648 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
22649 _ACEOF
22650
22651
22652 else
22653 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
22654 #include <sys/stat.h>
22655 "
22656 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
22657
22658 cat >>confdefs.h <<_ACEOF
22659 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
22660 _ACEOF
22661
22662
22663 else
22664 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>
22665 #include <sys/stat.h>
22666 "
22667 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
22668
22669 cat >>confdefs.h <<_ACEOF
22670 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
22671 _ACEOF
22672
22673
22674 fi
22675
22676 fi
22677
22678 fi
22679
22680
22681
22682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
22683 $as_echo_n "checking for working stdalign.h... " >&6; }
22684 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
22685 $as_echo_n "(cached) " >&6
22686 else
22687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22688 /* end confdefs.h. */
22689 #include <stdalign.h>
22690 #include <stddef.h>
22691
22692 /* Test that alignof yields a result consistent with offsetof.
22693 This catches GCC bug 52023
22694 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
22695 #ifdef __cplusplus
22696 template <class t> struct alignof_helper { char a; t b; };
22697 # define ao(type) offsetof (alignof_helper<type>, b)
22698 #else
22699 # define ao(type) offsetof (struct { char a; type b; }, b)
22700 #endif
22701 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
22702 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
22703 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
22704
22705 /* Test _Alignas only on platforms where gnulib can help. */
22706 #if \
22707 (__GNUC__ || __IBMC__ || __IBMCPP__ \
22708 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
22709 int alignas (8) alignas_int = 1;
22710 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
22711 #endif
22712
22713 int
22714 main ()
22715 {
22716
22717 ;
22718 return 0;
22719 }
22720 _ACEOF
22721 if ac_fn_c_try_compile "$LINENO"; then :
22722 gl_cv_header_working_stdalign_h=yes
22723 else
22724 gl_cv_header_working_stdalign_h=no
22725 fi
22726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22727 fi
22728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
22729 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
22730
22731 if test $gl_cv_header_working_stdalign_h = yes; then
22732 STDALIGN_H=''
22733 else
22734 STDALIGN_H='stdalign.h'
22735 fi
22736
22737
22738 if test -n "$STDALIGN_H"; then
22739 GL_GENERATE_STDALIGN_H_TRUE=
22740 GL_GENERATE_STDALIGN_H_FALSE='#'
22741 else
22742 GL_GENERATE_STDALIGN_H_TRUE='#'
22743 GL_GENERATE_STDALIGN_H_FALSE=
22744 fi
22745
22746
22747
22748 STDARG_H=''
22749 NEXT_STDARG_H='<stdarg.h>'
22750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
22751 $as_echo_n "checking for va_copy... " >&6; }
22752 if test "${gl_cv_func_va_copy+set}" = set; then :
22753 $as_echo_n "(cached) " >&6
22754 else
22755
22756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22757 /* end confdefs.h. */
22758 #include <stdarg.h>
22759 int
22760 main ()
22761 {
22762
22763 #ifndef va_copy
22764 void (*func) (va_list, va_list) = va_copy;
22765 #endif
22766
22767 ;
22768 return 0;
22769 }
22770 _ACEOF
22771 if ac_fn_c_try_compile "$LINENO"; then :
22772 gl_cv_func_va_copy=yes
22773 else
22774 gl_cv_func_va_copy=no
22775 fi
22776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22777 fi
22778
22779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
22780 $as_echo "$gl_cv_func_va_copy" >&6; }
22781 if test $gl_cv_func_va_copy = no; then
22782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22783 /* end confdefs.h. */
22784 #if defined _AIX && !defined __GNUC__
22785 AIX vaccine
22786 #endif
22787
22788 _ACEOF
22789 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22790 $EGREP "vaccine" >/dev/null 2>&1; then :
22791 gl_aixcc=yes
22792 else
22793 gl_aixcc=no
22794 fi
22795 rm -f conftest*
22796
22797 if test $gl_aixcc = yes; then
22798 STDARG_H=stdarg.h
22799
22800
22801
22802
22803
22804
22805
22806
22807 if test $gl_cv_have_include_next = yes; then
22808 gl_cv_next_stdarg_h='<'stdarg.h'>'
22809 else
22810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22811 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22812 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22813 $as_echo_n "(cached) " >&6
22814 else
22815
22816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22817 /* end confdefs.h. */
22818 #include <stdarg.h>
22819
22820 _ACEOF
22821 case "$host_os" in
22822 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22823 *) gl_absname_cpp="$ac_cpp" ;;
22824 esac
22825
22826 case "$host_os" in
22827 mingw*)
22828 gl_dirsep_regex='[/\\]'
22829 ;;
22830 *)
22831 gl_dirsep_regex='\/'
22832 ;;
22833 esac
22834 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22835
22836 gl_header_literal_regex=`echo 'stdarg.h' \
22837 | sed -e "$gl_make_literal_regex_sed"`
22838 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22839 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22840 s|^/[^/]|//&|
22841 p
22842 q
22843 }'
22844 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22845 sed -n "$gl_absolute_header_sed"`'"'
22846
22847
22848 fi
22849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22850 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22851 fi
22852 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22853
22854 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22855 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22856 gl_next_as_first_directive='<'stdarg.h'>'
22857 else
22858 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22859 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22860 fi
22861 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22862
22863
22864
22865
22866 if test "$gl_cv_next_stdarg_h" = '""'; then
22867 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22868 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22869 fi
22870 else
22871
22872 saved_as_echo_n="$as_echo_n"
22873 as_echo_n=':'
22874 if test "${gl_cv_func___va_copy+set}" = set; then :
22875 $as_echo_n "(cached) " >&6
22876 else
22877
22878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22879 /* end confdefs.h. */
22880 #include <stdarg.h>
22881 int
22882 main ()
22883 {
22884
22885 #ifndef __va_copy
22886 error, bail out
22887 #endif
22888
22889 ;
22890 return 0;
22891 }
22892 _ACEOF
22893 if ac_fn_c_try_compile "$LINENO"; then :
22894 gl_cv_func___va_copy=yes
22895 else
22896 gl_cv_func___va_copy=no
22897 fi
22898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22899 fi
22900
22901 as_echo_n="$saved_as_echo_n"
22902
22903 if test $gl_cv_func___va_copy = yes; then
22904
22905 $as_echo "#define va_copy __va_copy" >>confdefs.h
22906
22907 else
22908
22909
22910 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22911
22912 fi
22913 fi
22914 fi
22915
22916 if test -n "$STDARG_H"; then
22917 GL_GENERATE_STDARG_H_TRUE=
22918 GL_GENERATE_STDARG_H_FALSE='#'
22919 else
22920 GL_GENERATE_STDARG_H_TRUE='#'
22921 GL_GENERATE_STDARG_H_FALSE=
22922 fi
22923
22924
22925
22926
22927
22928
22929 # Define two additional variables used in the Makefile substitution.
22930
22931 if test "$ac_cv_header_stdbool_h" = yes; then
22932 STDBOOL_H=''
22933 else
22934 STDBOOL_H='stdbool.h'
22935 fi
22936
22937 if test -n "$STDBOOL_H"; then
22938 GL_GENERATE_STDBOOL_H_TRUE=
22939 GL_GENERATE_STDBOOL_H_FALSE='#'
22940 else
22941 GL_GENERATE_STDBOOL_H_TRUE='#'
22942 GL_GENERATE_STDBOOL_H_FALSE=
22943 fi
22944
22945
22946 if test "$ac_cv_type__Bool" = yes; then
22947 HAVE__BOOL=1
22948 else
22949 HAVE__BOOL=0
22950 fi
22951
22952
22953
22954
22955
22956 STDDEF_H=
22957 if test $gt_cv_c_wchar_t = no; then
22958 HAVE_WCHAR_T=0
22959 STDDEF_H=stddef.h
22960 fi
22961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22962 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22963 if test "${gl_cv_decl_null_works+set}" = set; then :
22964 $as_echo_n "(cached) " >&6
22965 else
22966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22967 /* end confdefs.h. */
22968 #include <stddef.h>
22969 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22970
22971 int
22972 main ()
22973 {
22974
22975 ;
22976 return 0;
22977 }
22978 _ACEOF
22979 if ac_fn_c_try_compile "$LINENO"; then :
22980 gl_cv_decl_null_works=yes
22981 else
22982 gl_cv_decl_null_works=no
22983 fi
22984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22985 fi
22986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22987 $as_echo "$gl_cv_decl_null_works" >&6; }
22988 if test $gl_cv_decl_null_works = no; then
22989 REPLACE_NULL=1
22990 STDDEF_H=stddef.h
22991 fi
22992
22993 if test -n "$STDDEF_H"; then
22994 GL_GENERATE_STDDEF_H_TRUE=
22995 GL_GENERATE_STDDEF_H_FALSE='#'
22996 else
22997 GL_GENERATE_STDDEF_H_TRUE='#'
22998 GL_GENERATE_STDDEF_H_FALSE=
22999 fi
23000
23001 if test -n "$STDDEF_H"; then
23002
23003
23004
23005
23006
23007
23008
23009
23010 if test $gl_cv_have_include_next = yes; then
23011 gl_cv_next_stddef_h='<'stddef.h'>'
23012 else
23013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
23014 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
23015 if test "${gl_cv_next_stddef_h+set}" = set; then :
23016 $as_echo_n "(cached) " >&6
23017 else
23018
23019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23020 /* end confdefs.h. */
23021 #include <stddef.h>
23022
23023 _ACEOF
23024 case "$host_os" in
23025 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23026 *) gl_absname_cpp="$ac_cpp" ;;
23027 esac
23028
23029 case "$host_os" in
23030 mingw*)
23031 gl_dirsep_regex='[/\\]'
23032 ;;
23033 *)
23034 gl_dirsep_regex='\/'
23035 ;;
23036 esac
23037 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23038
23039 gl_header_literal_regex=`echo 'stddef.h' \
23040 | sed -e "$gl_make_literal_regex_sed"`
23041 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23042 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23043 s|^/[^/]|//&|
23044 p
23045 q
23046 }'
23047 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23048 sed -n "$gl_absolute_header_sed"`'"'
23049
23050
23051 fi
23052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
23053 $as_echo "$gl_cv_next_stddef_h" >&6; }
23054 fi
23055 NEXT_STDDEF_H=$gl_cv_next_stddef_h
23056
23057 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23058 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23059 gl_next_as_first_directive='<'stddef.h'>'
23060 else
23061 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23062 gl_next_as_first_directive=$gl_cv_next_stddef_h
23063 fi
23064 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
23065
23066
23067
23068
23069 fi
23070
23071
23072
23073
23074
23075
23076
23077
23078
23079
23080
23081
23082
23083 if test $gl_cv_have_include_next = yes; then
23084 gl_cv_next_stdio_h='<'stdio.h'>'
23085 else
23086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
23087 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
23088 if test "${gl_cv_next_stdio_h+set}" = set; then :
23089 $as_echo_n "(cached) " >&6
23090 else
23091
23092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23093 /* end confdefs.h. */
23094 #include <stdio.h>
23095
23096 _ACEOF
23097 case "$host_os" in
23098 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23099 *) gl_absname_cpp="$ac_cpp" ;;
23100 esac
23101
23102 case "$host_os" in
23103 mingw*)
23104 gl_dirsep_regex='[/\\]'
23105 ;;
23106 *)
23107 gl_dirsep_regex='\/'
23108 ;;
23109 esac
23110 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23111
23112 gl_header_literal_regex=`echo 'stdio.h' \
23113 | sed -e "$gl_make_literal_regex_sed"`
23114 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23115 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23116 s|^/[^/]|//&|
23117 p
23118 q
23119 }'
23120 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23121 sed -n "$gl_absolute_header_sed"`'"'
23122
23123
23124 fi
23125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
23126 $as_echo "$gl_cv_next_stdio_h" >&6; }
23127 fi
23128 NEXT_STDIO_H=$gl_cv_next_stdio_h
23129
23130 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23131 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23132 gl_next_as_first_directive='<'stdio.h'>'
23133 else
23134 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23135 gl_next_as_first_directive=$gl_cv_next_stdio_h
23136 fi
23137 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
23138
23139
23140
23141
23142
23143 GNULIB_FSCANF=1
23144
23145
23146 cat >>confdefs.h <<_ACEOF
23147 #define GNULIB_FSCANF 1
23148 _ACEOF
23149
23150
23151 GNULIB_SCANF=1
23152
23153
23154 cat >>confdefs.h <<_ACEOF
23155 #define GNULIB_SCANF 1
23156 _ACEOF
23157
23158
23159 GNULIB_FGETC=1
23160 GNULIB_GETC=1
23161 GNULIB_GETCHAR=1
23162 GNULIB_FGETS=1
23163 GNULIB_FREAD=1
23164
23165
23166 GNULIB_FPRINTF=1
23167 GNULIB_PRINTF=1
23168 GNULIB_VFPRINTF=1
23169 GNULIB_VPRINTF=1
23170 GNULIB_FPUTC=1
23171 GNULIB_PUTC=1
23172 GNULIB_PUTCHAR=1
23173 GNULIB_FPUTS=1
23174 GNULIB_PUTS=1
23175 GNULIB_FWRITE=1
23176
23177
23178
23179
23180
23181
23182
23183
23184
23185
23186
23187
23188
23189
23190
23191 if test $gl_cv_have_include_next = yes; then
23192 gl_cv_next_stdlib_h='<'stdlib.h'>'
23193 else
23194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
23195 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
23196 if test "${gl_cv_next_stdlib_h+set}" = set; then :
23197 $as_echo_n "(cached) " >&6
23198 else
23199
23200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23201 /* end confdefs.h. */
23202 #include <stdlib.h>
23203
23204 _ACEOF
23205 case "$host_os" in
23206 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23207 *) gl_absname_cpp="$ac_cpp" ;;
23208 esac
23209
23210 case "$host_os" in
23211 mingw*)
23212 gl_dirsep_regex='[/\\]'
23213 ;;
23214 *)
23215 gl_dirsep_regex='\/'
23216 ;;
23217 esac
23218 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23219
23220 gl_header_literal_regex=`echo 'stdlib.h' \
23221 | sed -e "$gl_make_literal_regex_sed"`
23222 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23223 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23224 s|^/[^/]|//&|
23225 p
23226 q
23227 }'
23228 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23229 sed -n "$gl_absolute_header_sed"`'"'
23230
23231
23232 fi
23233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
23234 $as_echo "$gl_cv_next_stdlib_h" >&6; }
23235 fi
23236 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
23237
23238 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23239 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23240 gl_next_as_first_directive='<'stdlib.h'>'
23241 else
23242 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23243 gl_next_as_first_directive=$gl_cv_next_stdlib_h
23244 fi
23245 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
23246
23247
23248
23249
23250
23251
23252
23253
23254
23255 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
23256
23257
23258
23259
23260
23261
23262
23263 $as_echo "#define my_strftime nstrftime" >>confdefs.h
23264
23265
23266
23267
23268
23269
23270
23271
23272 if test "$ac_cv_have_decl_strtoimax" != yes; then
23273 HAVE_DECL_STRTOIMAX=0
23274 fi
23275
23276 if test $ac_cv_func_strtoimax = yes; then
23277 HAVE_STRTOIMAX=1
23278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
23279 $as_echo_n "checking whether strtoimax works... " >&6; }
23280 if test "${gl_cv_func_strtoimax+set}" = set; then :
23281 $as_echo_n "(cached) " >&6
23282 else
23283 if test "$cross_compiling" = yes; then :
23284 case "$host_os" in
23285 # Guess no on AIX 5.
23286 aix5*) gl_cv_func_strtoimax="guessing no" ;;
23287 # Guess yes otherwise.
23288 *) gl_cv_func_strtoimax="guessing yes" ;;
23289 esac
23290
23291 else
23292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23293 /* end confdefs.h. */
23294
23295 #include <errno.h>
23296 #include <string.h>
23297 #include <inttypes.h>
23298 int main ()
23299 {
23300 if (sizeof (intmax_t) > sizeof (int))
23301 {
23302 const char *s = "4294967295";
23303 char *p;
23304 intmax_t res;
23305 errno = 0;
23306 res = strtoimax (s, &p, 10);
23307 if (p != s + strlen (s))
23308 return 1;
23309 if (errno != 0)
23310 return 2;
23311 if (res != (intmax_t) 65535 * (intmax_t) 65537)
23312 return 3;
23313 }
23314 else
23315 {
23316 const char *s = "2147483647";
23317 char *p;
23318 intmax_t res;
23319 errno = 0;
23320 res = strtoimax (s, &p, 10);
23321 if (p != s + strlen (s))
23322 return 1;
23323 if (errno != 0)
23324 return 2;
23325 if (res != 2147483647)
23326 return 3;
23327 }
23328 return 0;
23329 }
23330
23331 _ACEOF
23332 if ac_fn_c_try_run "$LINENO"; then :
23333 gl_cv_func_strtoimax=yes
23334 else
23335 gl_cv_func_strtoimax=no
23336 fi
23337 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23338 conftest.$ac_objext conftest.beam conftest.$ac_ext
23339 fi
23340
23341
23342 fi
23343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
23344 $as_echo "$gl_cv_func_strtoimax" >&6; }
23345 case "$gl_cv_func_strtoimax" in
23346 *no) REPLACE_STRTOIMAX=1 ;;
23347 esac
23348 else
23349 HAVE_STRTOIMAX=0
23350 fi
23351
23352 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23353
23354
23355
23356
23357
23358
23359
23360
23361 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
23362
23363
23364 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23365 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
23366 ac_have_decl=1
23367 else
23368 ac_have_decl=0
23369 fi
23370
23371 cat >>confdefs.h <<_ACEOF
23372 #define HAVE_DECL_STRTOLL $ac_have_decl
23373 _ACEOF
23374
23375
23376
23377 fi
23378
23379
23380
23381
23382
23383 GNULIB_STRTOIMAX=1
23384
23385
23386
23387
23388
23389
23390
23391
23392
23393 if test "$ac_cv_have_decl_strtoumax" != yes; then
23394 HAVE_DECL_STRTOUMAX=0
23395 fi
23396
23397 if test $ac_cv_func_strtoumax = no; then
23398
23399
23400
23401
23402
23403
23404
23405
23406 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
23407
23408
23409 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23410 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
23411 ac_have_decl=1
23412 else
23413 ac_have_decl=0
23414 fi
23415
23416 cat >>confdefs.h <<_ACEOF
23417 #define HAVE_DECL_STRTOULL $ac_have_decl
23418 _ACEOF
23419
23420
23421
23422 fi
23423
23424
23425
23426
23427
23428 GNULIB_STRTOUMAX=1
23429
23430
23431
23432
23433
23434
23435
23436 if test $ac_cv_func_symlink = no; then
23437 HAVE_SYMLINK=0
23438 else
23439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23440 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23441 if test "${gl_cv_func_symlink_works+set}" = set; then :
23442 $as_echo_n "(cached) " >&6
23443 else
23444 if test "$cross_compiling" = yes; then :
23445 case "$host_os" in
23446 # Guess yes on glibc systems.
23447 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23448 # If we don't know, assume the worst.
23449 *) gl_cv_func_symlink_works="guessing no" ;;
23450 esac
23451
23452 else
23453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23454 /* end confdefs.h. */
23455 #include <unistd.h>
23456
23457 int
23458 main ()
23459 {
23460 int result = 0;
23461 if (!symlink ("a", "conftest.link/"))
23462 result |= 1;
23463 if (symlink ("conftest.f", "conftest.lnk2"))
23464 result |= 2;
23465 else if (!symlink ("a", "conftest.lnk2/"))
23466 result |= 4;
23467 return result;
23468
23469 ;
23470 return 0;
23471 }
23472 _ACEOF
23473 if ac_fn_c_try_run "$LINENO"; then :
23474 gl_cv_func_symlink_works=yes
23475 else
23476 gl_cv_func_symlink_works=no
23477 fi
23478 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23479 conftest.$ac_objext conftest.beam conftest.$ac_ext
23480 fi
23481
23482 rm -f conftest.f conftest.link conftest.lnk2
23483 fi
23484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23485 $as_echo "$gl_cv_func_symlink_works" >&6; }
23486 case "$gl_cv_func_symlink_works" in
23487 *yes) ;;
23488 *)
23489 REPLACE_SYMLINK=1
23490 ;;
23491 esac
23492 fi
23493
23494 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23495
23496
23497
23498
23499
23500
23501
23502
23503 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
23504
23505 fi
23506
23507
23508
23509
23510
23511 GNULIB_SYMLINK=1
23512
23513
23514
23515
23516
23517
23518
23519
23520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
23521 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
23522 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
23523 $as_echo_n "(cached) " >&6
23524 else
23525
23526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23527 /* end confdefs.h. */
23528 #include <sys/select.h>
23529 int
23530 main ()
23531 {
23532 struct timeval b;
23533 ;
23534 return 0;
23535 }
23536 _ACEOF
23537 if ac_fn_c_try_compile "$LINENO"; then :
23538 gl_cv_header_sys_select_h_selfcontained=yes
23539 else
23540 gl_cv_header_sys_select_h_selfcontained=no
23541 fi
23542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23543 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
23544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23545 /* end confdefs.h. */
23546 #include <sys/select.h>
23547 int
23548 main ()
23549 {
23550 int memset; int bzero;
23551 ;
23552 return 0;
23553 }
23554
23555 _ACEOF
23556 if ac_fn_c_try_compile "$LINENO"; then :
23557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23558 /* end confdefs.h. */
23559 #include <sys/select.h>
23560 int
23561 main ()
23562 {
23563
23564 #undef memset
23565 #define memset nonexistent_memset
23566 extern
23567 #ifdef __cplusplus
23568 "C"
23569 #endif
23570 void *memset (void *, int, unsigned long);
23571 #undef bzero
23572 #define bzero nonexistent_bzero
23573 extern
23574 #ifdef __cplusplus
23575 "C"
23576 #endif
23577 void bzero (void *, unsigned long);
23578 fd_set fds;
23579 FD_ZERO (&fds);
23580
23581 ;
23582 return 0;
23583 }
23584
23585 _ACEOF
23586 if ac_fn_c_try_link "$LINENO"; then :
23587
23588 else
23589 gl_cv_header_sys_select_h_selfcontained=no
23590 fi
23591 rm -f core conftest.err conftest.$ac_objext \
23592 conftest$ac_exeext conftest.$ac_ext
23593
23594 fi
23595 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23596 fi
23597
23598 fi
23599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
23600 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
23601
23602
23603
23604
23605
23606
23607
23608
23609
23610 if test $gl_cv_have_include_next = yes; then
23611 gl_cv_next_sys_select_h='<'sys/select.h'>'
23612 else
23613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
23614 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
23615 if test "${gl_cv_next_sys_select_h+set}" = set; then :
23616 $as_echo_n "(cached) " >&6
23617 else
23618
23619 if test $ac_cv_header_sys_select_h = yes; then
23620
23621
23622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23623 /* end confdefs.h. */
23624 #include <sys/select.h>
23625
23626 _ACEOF
23627 case "$host_os" in
23628 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23629 *) gl_absname_cpp="$ac_cpp" ;;
23630 esac
23631
23632 case "$host_os" in
23633 mingw*)
23634 gl_dirsep_regex='[/\\]'
23635 ;;
23636 *)
23637 gl_dirsep_regex='\/'
23638 ;;
23639 esac
23640 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23641
23642 gl_header_literal_regex=`echo 'sys/select.h' \
23643 | sed -e "$gl_make_literal_regex_sed"`
23644 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23645 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23646 s|^/[^/]|//&|
23647 p
23648 q
23649 }'
23650 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23651 sed -n "$gl_absolute_header_sed"`'"'
23652 else
23653 gl_cv_next_sys_select_h='<'sys/select.h'>'
23654 fi
23655
23656
23657 fi
23658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
23659 $as_echo "$gl_cv_next_sys_select_h" >&6; }
23660 fi
23661 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
23662
23663 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23664 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23665 gl_next_as_first_directive='<'sys/select.h'>'
23666 else
23667 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23668 gl_next_as_first_directive=$gl_cv_next_sys_select_h
23669 fi
23670 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
23671
23672
23673
23674
23675 if test $ac_cv_header_sys_select_h = yes; then
23676 HAVE_SYS_SELECT_H=1
23677 else
23678 HAVE_SYS_SELECT_H=0
23679 fi
23680
23681
23682
23683
23684
23685 if test $ac_cv_header_sys_socket_h != yes; then
23686 for ac_header in winsock2.h
23687 do :
23688 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23689 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
23690 cat >>confdefs.h <<_ACEOF
23691 #define HAVE_WINSOCK2_H 1
23692 _ACEOF
23693
23694 fi
23695
23696 done
23697
23698 fi
23699 if test "$ac_cv_header_winsock2_h" = yes; then
23700 HAVE_WINSOCK2_H=1
23701 UNISTD_H_HAVE_WINSOCK2_H=1
23702 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23703 else
23704 HAVE_WINSOCK2_H=0
23705 fi
23706
23707
23708
23709
23710
23711
23712
23713
23714
23715
23716
23717
23718
23719
23720
23721
23722
23723
23724
23725
23726
23727
23728 if test $gl_cv_have_include_next = yes; then
23729 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23730 else
23731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23732 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23733 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
23734 $as_echo_n "(cached) " >&6
23735 else
23736
23737 if test $ac_cv_header_sys_stat_h = yes; then
23738
23739
23740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23741 /* end confdefs.h. */
23742 #include <sys/stat.h>
23743
23744 _ACEOF
23745 case "$host_os" in
23746 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23747 *) gl_absname_cpp="$ac_cpp" ;;
23748 esac
23749
23750 case "$host_os" in
23751 mingw*)
23752 gl_dirsep_regex='[/\\]'
23753 ;;
23754 *)
23755 gl_dirsep_regex='\/'
23756 ;;
23757 esac
23758 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23759
23760 gl_header_literal_regex=`echo 'sys/stat.h' \
23761 | sed -e "$gl_make_literal_regex_sed"`
23762 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23763 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23764 s|^/[^/]|//&|
23765 p
23766 q
23767 }'
23768 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23769 sed -n "$gl_absolute_header_sed"`'"'
23770 else
23771 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23772 fi
23773
23774
23775 fi
23776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23777 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23778 fi
23779 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23780
23781 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23782 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23783 gl_next_as_first_directive='<'sys/stat.h'>'
23784 else
23785 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23786 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23787 fi
23788 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23789
23790
23791
23792
23793
23794
23795
23796
23797
23798
23799
23800 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23801
23802 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23803
23804 fi
23805
23806 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23807 #include <sys/stat.h>
23808 "
23809 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23810
23811 else
23812
23813 $as_echo "#define nlink_t int" >>confdefs.h
23814
23815 fi
23816
23817
23818
23819
23820
23821
23822
23823
23824
23825
23826
23827
23828
23829
23830
23831
23832
23833
23834 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23835 "
23836 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23837 ac_have_decl=1
23838 else
23839 ac_have_decl=0
23840 fi
23841
23842 cat >>confdefs.h <<_ACEOF
23843 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23844 _ACEOF
23845
23846 if test $ac_cv_have_decl_localtime_r = no; then
23847 HAVE_DECL_LOCALTIME_R=0
23848 fi
23849
23850
23851 if test $ac_cv_func_localtime_r = yes; then
23852 HAVE_LOCALTIME_R=1
23853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23854 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23855 if test "${gl_cv_time_r_posix+set}" = set; then :
23856 $as_echo_n "(cached) " >&6
23857 else
23858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23859 /* end confdefs.h. */
23860 #include <time.h>
23861 int
23862 main ()
23863 {
23864 /* We don't need to append 'restrict's to the argument types,
23865 even though the POSIX signature has the 'restrict's,
23866 since C99 says they can't affect type compatibility. */
23867 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23868 if (ptr) return 0;
23869 /* Check the return type is a pointer.
23870 On HP-UX 10 it is 'int'. */
23871 *localtime_r (0, 0);
23872 ;
23873 return 0;
23874 }
23875
23876 _ACEOF
23877 if ac_fn_c_try_compile "$LINENO"; then :
23878 gl_cv_time_r_posix=yes
23879 else
23880 gl_cv_time_r_posix=no
23881 fi
23882 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23883
23884 fi
23885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23886 $as_echo "$gl_cv_time_r_posix" >&6; }
23887 if test $gl_cv_time_r_posix = yes; then
23888 REPLACE_LOCALTIME_R=0
23889 else
23890 REPLACE_LOCALTIME_R=1
23891 fi
23892 else
23893 HAVE_LOCALTIME_R=0
23894 fi
23895
23896 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23897
23898
23899
23900
23901
23902
23903
23904
23905 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23906
23907
23908 :
23909
23910 fi
23911
23912
23913
23914
23915
23916 GNULIB_TIME_R=1
23917
23918
23919
23920
23921
23922
23923
23924
23925
23926
23927 LIB_TIMER_TIME=
23928
23929 gl_saved_libs=$LIBS
23930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
23931 $as_echo_n "checking for library containing timer_settime... " >&6; }
23932 if test "${ac_cv_search_timer_settime+set}" = set; then :
23933 $as_echo_n "(cached) " >&6
23934 else
23935 ac_func_search_save_LIBS=$LIBS
23936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23937 /* end confdefs.h. */
23938
23939 /* Override any GCC internal prototype to avoid an error.
23940 Use char because int might match the return type of a GCC
23941 builtin and then its argument prototype would still apply. */
23942 #ifdef __cplusplus
23943 extern "C"
23944 #endif
23945 char timer_settime ();
23946 int
23947 main ()
23948 {
23949 return timer_settime ();
23950 ;
23951 return 0;
23952 }
23953 _ACEOF
23954 for ac_lib in '' rt posix4; do
23955 if test -z "$ac_lib"; then
23956 ac_res="none required"
23957 else
23958 ac_res=-l$ac_lib
23959 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23960 fi
23961 if ac_fn_c_try_link "$LINENO"; then :
23962 ac_cv_search_timer_settime=$ac_res
23963 fi
23964 rm -f core conftest.err conftest.$ac_objext \
23965 conftest$ac_exeext
23966 if test "${ac_cv_search_timer_settime+set}" = set; then :
23967 break
23968 fi
23969 done
23970 if test "${ac_cv_search_timer_settime+set}" = set; then :
23971
23972 else
23973 ac_cv_search_timer_settime=no
23974 fi
23975 rm conftest.$ac_ext
23976 LIBS=$ac_func_search_save_LIBS
23977 fi
23978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
23979 $as_echo "$ac_cv_search_timer_settime" >&6; }
23980 ac_res=$ac_cv_search_timer_settime
23981 if test "$ac_res" != no; then :
23982 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23983 test "$ac_cv_search_timer_settime" = "none required" ||
23984 LIB_TIMER_TIME=$ac_cv_search_timer_settime
23985 fi
23986
23987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23988 /* end confdefs.h. */
23989
23990 #include <features.h>
23991 #ifdef __GNU_LIBRARY__
23992 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
23993 && !defined __UCLIBC__
23994 Thread emulation available
23995 #endif
23996 #endif
23997
23998 _ACEOF
23999 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24000 $EGREP "Thread" >/dev/null 2>&1; then :
24001 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
24002 fi
24003 rm -f conftest*
24004
24005 for ac_func in timer_settime
24006 do :
24007 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
24008 if test "x$ac_cv_func_timer_settime" = x""yes; then :
24009 cat >>confdefs.h <<_ACEOF
24010 #define HAVE_TIMER_SETTIME 1
24011 _ACEOF
24012
24013 fi
24014 done
24015
24016 LIBS=$gl_saved_libs
24017
24018 :
24019
24020
24021
24022
24023
24024
24025
24026
24027
24028
24029
24030
24031
24032 if test $gl_cv_have_include_next = yes; then
24033 gl_cv_next_unistd_h='<'unistd.h'>'
24034 else
24035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
24036 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
24037 if test "${gl_cv_next_unistd_h+set}" = set; then :
24038 $as_echo_n "(cached) " >&6
24039 else
24040
24041 if test $ac_cv_header_unistd_h = yes; then
24042
24043
24044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24045 /* end confdefs.h. */
24046 #include <unistd.h>
24047
24048 _ACEOF
24049 case "$host_os" in
24050 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24051 *) gl_absname_cpp="$ac_cpp" ;;
24052 esac
24053
24054 case "$host_os" in
24055 mingw*)
24056 gl_dirsep_regex='[/\\]'
24057 ;;
24058 *)
24059 gl_dirsep_regex='\/'
24060 ;;
24061 esac
24062 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24063
24064 gl_header_literal_regex=`echo 'unistd.h' \
24065 | sed -e "$gl_make_literal_regex_sed"`
24066 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24067 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24068 s|^/[^/]|//&|
24069 p
24070 q
24071 }'
24072 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24073 sed -n "$gl_absolute_header_sed"`'"'
24074 else
24075 gl_cv_next_unistd_h='<'unistd.h'>'
24076 fi
24077
24078
24079 fi
24080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
24081 $as_echo "$gl_cv_next_unistd_h" >&6; }
24082 fi
24083 NEXT_UNISTD_H=$gl_cv_next_unistd_h
24084
24085 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24086 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24087 gl_next_as_first_directive='<'unistd.h'>'
24088 else
24089 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24090 gl_next_as_first_directive=$gl_cv_next_unistd_h
24091 fi
24092 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
24093
24094
24095
24096
24097 if test $ac_cv_header_unistd_h = yes; then
24098 HAVE_UNISTD_H=1
24099 else
24100 HAVE_UNISTD_H=0
24101 fi
24102
24103
24104
24105
24106
24107
24108
24109
24110
24111
24112
24113
24114
24115
24116 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
24117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
24118 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
24119 if test "${gl_cv_func_futimesat_works+set}" = set; then :
24120 $as_echo_n "(cached) " >&6
24121 else
24122 touch conftest.file
24123 if test "$cross_compiling" = yes; then :
24124 case "$host_os" in
24125 # Guess yes on glibc systems.
24126 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
24127 # If we don't know, assume the worst.
24128 *) gl_cv_func_futimesat_works="guessing no" ;;
24129 esac
24130
24131 else
24132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24133 /* end confdefs.h. */
24134
24135 #include <stddef.h>
24136 #include <sys/times.h>
24137 #include <fcntl.h>
24138
24139 int
24140 main ()
24141 {
24142 int fd = open ("conftest.file", O_RDWR);
24143 if (fd < 0) return 1;
24144 if (futimesat (fd, NULL, NULL)) return 2;
24145
24146 ;
24147 return 0;
24148 }
24149 _ACEOF
24150 if ac_fn_c_try_run "$LINENO"; then :
24151 gl_cv_func_futimesat_works=yes
24152 else
24153 gl_cv_func_futimesat_works=no
24154 fi
24155 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24156 conftest.$ac_objext conftest.beam conftest.$ac_ext
24157 fi
24158
24159 rm -f conftest.file
24160 fi
24161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
24162 $as_echo "$gl_cv_func_futimesat_works" >&6; }
24163 case "$gl_cv_func_futimesat_works" in
24164 *yes) ;;
24165 *)
24166
24167 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
24168
24169 ;;
24170 esac
24171 fi
24172
24173 gl_gnulib_enabled_dosname=false
24174 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
24175 gl_gnulib_enabled_pathmax=false
24176 gl_gnulib_enabled_stat=false
24177 gl_gnulib_enabled_strtoll=false
24178 gl_gnulib_enabled_strtoull=false
24179 gl_gnulib_enabled_verify=false
24180 func_gl_gnulib_m4code_dosname ()
24181 {
24182 if ! $gl_gnulib_enabled_dosname; then
24183 gl_gnulib_enabled_dosname=true
24184 fi
24185 }
24186 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
24187 {
24188 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
24189
24190
24191 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
24192 fi
24193 }
24194 func_gl_gnulib_m4code_pathmax ()
24195 {
24196 if ! $gl_gnulib_enabled_pathmax; then
24197
24198
24199
24200 gl_gnulib_enabled_pathmax=true
24201 fi
24202 }
24203 func_gl_gnulib_m4code_stat ()
24204 {
24205 if ! $gl_gnulib_enabled_stat; then
24206
24207
24208
24209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
24210 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
24211 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
24212 $as_echo_n "(cached) " >&6
24213 else
24214 if test "$cross_compiling" = yes; then :
24215 case $host_os in
24216 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
24217 *) gl_cv_func_stat_dir_slash="guessing yes";;
24218 esac
24219 else
24220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24221 /* end confdefs.h. */
24222 #include <sys/stat.h>
24223
24224 int
24225 main ()
24226 {
24227 struct stat st; return stat (".", &st) != stat ("./", &st);
24228 ;
24229 return 0;
24230 }
24231 _ACEOF
24232 if ac_fn_c_try_run "$LINENO"; then :
24233 gl_cv_func_stat_dir_slash=yes
24234 else
24235 gl_cv_func_stat_dir_slash=no
24236 fi
24237 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24238 conftest.$ac_objext conftest.beam conftest.$ac_ext
24239 fi
24240
24241 fi
24242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
24243 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
24244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
24245 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
24246 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
24247 $as_echo_n "(cached) " >&6
24248 else
24249 touch conftest.tmp
24250 # Assume that if we have lstat, we can also check symlinks.
24251 if test $ac_cv_func_lstat = yes; then
24252 ln -s conftest.tmp conftest.lnk
24253 fi
24254 if test "$cross_compiling" = yes; then :
24255 case "$host_os" in
24256 # Guess yes on glibc systems.
24257 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
24258 # If we don't know, assume the worst.
24259 *) gl_cv_func_stat_file_slash="guessing no" ;;
24260 esac
24261
24262 else
24263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24264 /* end confdefs.h. */
24265 #include <sys/stat.h>
24266
24267 int
24268 main ()
24269 {
24270 int result = 0;
24271 struct stat st;
24272 if (!stat ("conftest.tmp/", &st))
24273 result |= 1;
24274 #if HAVE_LSTAT
24275 if (!stat ("conftest.lnk/", &st))
24276 result |= 2;
24277 #endif
24278 return result;
24279
24280 ;
24281 return 0;
24282 }
24283 _ACEOF
24284 if ac_fn_c_try_run "$LINENO"; then :
24285 gl_cv_func_stat_file_slash=yes
24286 else
24287 gl_cv_func_stat_file_slash=no
24288 fi
24289 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24290 conftest.$ac_objext conftest.beam conftest.$ac_ext
24291 fi
24292
24293 rm -f conftest.tmp conftest.lnk
24294 fi
24295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
24296 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
24297 case $gl_cv_func_stat_dir_slash in
24298 *no) REPLACE_STAT=1
24299
24300 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
24301 ;;
24302 esac
24303 case $gl_cv_func_stat_file_slash in
24304 *no) REPLACE_STAT=1
24305
24306 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
24307 ;;
24308 esac
24309
24310 if test $REPLACE_STAT = 1; then
24311
24312
24313
24314
24315
24316
24317
24318
24319 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
24320
24321
24322
24323 :
24324
24325 fi
24326
24327
24328
24329
24330
24331 GNULIB_STAT=1
24332
24333
24334
24335
24336
24337 gl_gnulib_enabled_stat=true
24338 if test $REPLACE_STAT = 1; then
24339 func_gl_gnulib_m4code_dosname
24340 fi
24341 if test $REPLACE_STAT = 1; then
24342 func_gl_gnulib_m4code_pathmax
24343 fi
24344 if test $REPLACE_STAT = 1; then
24345 func_gl_gnulib_m4code_verify
24346 fi
24347 fi
24348 }
24349 func_gl_gnulib_m4code_strtoll ()
24350 {
24351 if ! $gl_gnulib_enabled_strtoll; then
24352
24353
24354
24355 if test "$ac_cv_type_long_long_int" = yes; then
24356 for ac_func in strtoll
24357 do :
24358 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
24359 if test "x$ac_cv_func_strtoll" = x""yes; then :
24360 cat >>confdefs.h <<_ACEOF
24361 #define HAVE_STRTOLL 1
24362 _ACEOF
24363
24364 fi
24365 done
24366
24367 if test $ac_cv_func_strtoll = no; then
24368 HAVE_STRTOLL=0
24369 fi
24370 fi
24371
24372 if test $HAVE_STRTOLL = 0; then
24373
24374
24375
24376
24377
24378
24379
24380
24381 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
24382
24383
24384 :
24385
24386 fi
24387
24388
24389
24390
24391
24392 GNULIB_STRTOLL=1
24393
24394
24395
24396
24397
24398 gl_gnulib_enabled_strtoll=true
24399 fi
24400 }
24401 func_gl_gnulib_m4code_strtoull ()
24402 {
24403 if ! $gl_gnulib_enabled_strtoull; then
24404
24405
24406
24407 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
24408 for ac_func in strtoull
24409 do :
24410 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
24411 if test "x$ac_cv_func_strtoull" = x""yes; then :
24412 cat >>confdefs.h <<_ACEOF
24413 #define HAVE_STRTOULL 1
24414 _ACEOF
24415
24416 fi
24417 done
24418
24419 if test $ac_cv_func_strtoull = no; then
24420 HAVE_STRTOULL=0
24421 fi
24422 fi
24423
24424 if test $HAVE_STRTOULL = 0; then
24425
24426
24427
24428
24429
24430
24431
24432
24433 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
24434
24435
24436 :
24437
24438 fi
24439
24440
24441
24442
24443
24444 GNULIB_STRTOULL=1
24445
24446
24447
24448
24449
24450 gl_gnulib_enabled_strtoull=true
24451 fi
24452 }
24453 func_gl_gnulib_m4code_verify ()
24454 {
24455 if ! $gl_gnulib_enabled_verify; then
24456 gl_gnulib_enabled_verify=true
24457 fi
24458 }
24459 if test $REPLACE_GETOPT = 1; then
24460 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
24461 fi
24462 if test $REPLACE_LSTAT = 1; then
24463 func_gl_gnulib_m4code_dosname
24464 fi
24465 if test $REPLACE_LSTAT = 1; then
24466 func_gl_gnulib_m4code_stat
24467 fi
24468 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
24469 func_gl_gnulib_m4code_stat
24470 fi
24471 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
24472 func_gl_gnulib_m4code_strtoll
24473 fi
24474 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
24475 func_gl_gnulib_m4code_verify
24476 fi
24477 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
24478 func_gl_gnulib_m4code_strtoull
24479 fi
24480 if test $ac_cv_func_strtoumax = no; then
24481 func_gl_gnulib_m4code_verify
24482 fi
24483
24484 if $gl_gnulib_enabled_dosname; then
24485 gl_GNULIB_ENABLED_dosname_TRUE=
24486 gl_GNULIB_ENABLED_dosname_FALSE='#'
24487 else
24488 gl_GNULIB_ENABLED_dosname_TRUE='#'
24489 gl_GNULIB_ENABLED_dosname_FALSE=
24490 fi
24491
24492 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
24493 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
24494 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
24495 else
24496 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
24497 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
24498 fi
24499
24500 if $gl_gnulib_enabled_pathmax; then
24501 gl_GNULIB_ENABLED_pathmax_TRUE=
24502 gl_GNULIB_ENABLED_pathmax_FALSE='#'
24503 else
24504 gl_GNULIB_ENABLED_pathmax_TRUE='#'
24505 gl_GNULIB_ENABLED_pathmax_FALSE=
24506 fi
24507
24508 if $gl_gnulib_enabled_stat; then
24509 gl_GNULIB_ENABLED_stat_TRUE=
24510 gl_GNULIB_ENABLED_stat_FALSE='#'
24511 else
24512 gl_GNULIB_ENABLED_stat_TRUE='#'
24513 gl_GNULIB_ENABLED_stat_FALSE=
24514 fi
24515
24516 if $gl_gnulib_enabled_strtoll; then
24517 gl_GNULIB_ENABLED_strtoll_TRUE=
24518 gl_GNULIB_ENABLED_strtoll_FALSE='#'
24519 else
24520 gl_GNULIB_ENABLED_strtoll_TRUE='#'
24521 gl_GNULIB_ENABLED_strtoll_FALSE=
24522 fi
24523
24524 if $gl_gnulib_enabled_strtoull; then
24525 gl_GNULIB_ENABLED_strtoull_TRUE=
24526 gl_GNULIB_ENABLED_strtoull_FALSE='#'
24527 else
24528 gl_GNULIB_ENABLED_strtoull_TRUE='#'
24529 gl_GNULIB_ENABLED_strtoull_FALSE=
24530 fi
24531
24532 if $gl_gnulib_enabled_verify; then
24533 gl_GNULIB_ENABLED_verify_TRUE=
24534 gl_GNULIB_ENABLED_verify_FALSE='#'
24535 else
24536 gl_GNULIB_ENABLED_verify_TRUE='#'
24537 gl_GNULIB_ENABLED_verify_FALSE=
24538 fi
24539
24540 # End of code from modules
24541
24542
24543
24544
24545
24546
24547
24548
24549
24550 gltests_libdeps=
24551 gltests_ltlibdeps=
24552
24553
24554
24555
24556
24557
24558
24559
24560
24561 gl_source_base='tests'
24562 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
24563
24564 gl_module_indicator_condition=$gltests_WITNESS
24565
24566
24567
24568
24569
24570
24571
24572
24573
24574
24575 LIBGNU_LIBDEPS="$gl_libdeps"
24576
24577 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
24578
24579
24580 CFLAGS=$SAVE_CFLAGS
24581 LIBS=$SAVE_LIBS
24582
24583 case "$opsys" in
24584 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
24585
24586 darwin)
24587 ## The -headerpad option tells ld (see man page) to leave room at the
24588 ## end of the header for adding load commands. Needed for dumping.
24589 ## 0x690 is the total size of 30 segment load commands (at 56
24590 ## each); under Cocoa 31 commands are required.
24591 if test "$HAVE_NS" = "yes"; then
24592 libs_nsgui="-framework AppKit"
24593 headerpad_extra=6C8
24594 else
24595 libs_nsgui=
24596 headerpad_extra=690
24597 fi
24598 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
24599
24600 ## This is here because src/Makefile.in did some extra fiddling around
24601 ## with LD_SWITCH_SYSTEM. The cpp logic was:
24602 ## #ifndef LD_SWITCH_SYSTEM
24603 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
24604 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
24605 ## not using gcc, darwin.
24606 ## Because this was done in src/Makefile.in, the resulting part of
24607 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
24608 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
24609 ## rather than LD_SWITCH_SYSTEM.
24610 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
24611 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
24612 ;;
24613
24614 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
24615 ## find X at run-time.
24616 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
24617 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
24618 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
24619 ## had different values in configure (in ac_link) and src/Makefile.in.
24620 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
24621 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
24622
24623 *) LD_SWITCH_SYSTEM_TEMACS= ;;
24624 esac
24625
24626 if test "$NS_IMPL_GNUSTEP" = "yes"; then
24627 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
24628 fi
24629
24630
24631
24632
24633 LD_FIRSTFLAG=
24634 ORDINARY_LINK=
24635 case "$opsys" in
24636 ## gnu: GNU needs its own crt0.
24637 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
24638
24639 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
24640 ## library search parth, i.e. it won't search /usr/lib for libc and
24641 ## friends. Using -nostartfiles instead avoids this problem, and
24642 ## will also work on earlier NetBSD releases.
24643 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
24644
24645 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
24646 ## MkLinux/LinuxPPC needs this.
24647 ## s390x-* only supports opsys = gnu-linux so it can be added here.
24648 gnu-*)
24649 case "$canonical" in
24650 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
24651 esac
24652 ;;
24653 esac
24654
24655
24656 if test "x$ORDINARY_LINK" = "xyes"; then
24657
24658 LD_FIRSTFLAG=""
24659
24660 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
24661
24662
24663 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
24664 ## freebsd, gnu-* not on powerpc*|s390x*.
24665 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
24666
24667 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
24668 ## places that are difficult to figure out at make time. Fortunately,
24669 ## these same versions allow you to pass arbitrary flags on to the
24670 ## linker, so there is no reason not to use it as a linker.
24671 ##
24672 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
24673 ## searching for libraries in its internal directories, so we have to
24674 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
24675 LD_FIRSTFLAG="-nostdlib"
24676 fi
24677
24678 ## FIXME? What setting of EDIT_LDFLAGS should this have?
24679 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
24680
24681
24682
24683
24684 ## FIXME? The logic here is not precisely the same as that above.
24685 ## There is no check here for a pre-defined LD_FIRSTFLAG.
24686 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
24687 LIB_GCC=
24688 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
24689
24690 case "$opsys" in
24691 freebsd|netbsd|openbsd) LIB_GCC= ;;
24692
24693 gnu-*)
24694 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
24695 ## build on ARM EABI under GNU/Linux. (Bug#5518)
24696 case $host_cpu in
24697 arm*)
24698 LIB_GCC="-lgcc_s"
24699 ;;
24700 *)
24701 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
24702 ## immediately undefine it again and redefine it to empty.
24703 ## Was the C_SWITCH_X_SITE part really necessary?
24704 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
24705 LIB_GCC=
24706 ;;
24707 esac
24708 ;;
24709
24710 ## Ask GCC where to find libgcc.a.
24711 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
24712 esac
24713 fi
24714
24715 ## Common for all window systems
24716 if test "$window_system" != "none"; then
24717
24718 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
24719
24720
24721 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
24722
24723 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
24724 fi
24725
24726
24727
24728
24729
24730 #### Report on what we decided to do.
24731 #### Report GTK as a toolkit, even if it doesn't use Xt.
24732 #### It makes printing result more understandable as using GTK sets
24733 #### toolkit_scroll_bars to yes by default.
24734 if test "${HAVE_GTK}" = "yes"; then
24735 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
24736 fi
24737
24738 echo "
24739 Configured for \`${canonical}'.
24740
24741 Where should the build process find the source code? ${srcdir}
24742 What compiler should emacs be built with? ${CC} ${CFLAGS}
24743 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
24744 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
24745 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
24746 What window system should Emacs use? ${window_system}
24747 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
24748
24749 if test -n "${x_includes}"; then
24750 echo " Where do we find X Windows header files? ${x_includes}"
24751 else
24752 echo " Where do we find X Windows header files? Standard dirs"
24753 fi
24754 if test -n "${x_libraries}"; then
24755 echo " Where do we find X Windows libraries? ${x_libraries}"
24756 else
24757 echo " Where do we find X Windows libraries? Standard dirs"
24758 fi
24759
24760 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
24761 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
24762 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
24763 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
24764 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
24765 echo " Does Emacs use -lpng? ${HAVE_PNG}"
24766 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
24767 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
24768
24769 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
24770 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
24771 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
24772 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
24773 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
24774 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
24775 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
24776
24777 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
24778 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
24779 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
24780 echo " Does Emacs use -lxft? ${HAVE_XFT}"
24781
24782 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
24783 echo
24784
24785 if test -n "${EMACSDATA}"; then
24786 echo " Environment variable EMACSDATA set to: $EMACSDATA"
24787 fi
24788 if test -n "${EMACSDOC}"; then
24789 echo " Environment variable EMACSDOC set to: $EMACSDOC"
24790 fi
24791
24792 echo
24793
24794 if test "$HAVE_NS" = "yes"; then
24795 echo
24796 echo "You must run \"${MAKE-make} install\" in order to test the built application.
24797 The installed application will go to nextstep/Emacs.app and can be
24798 run or moved from there."
24799 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
24800 echo "The application will be fully self-contained."
24801 else
24802 echo "The lisp resources for the application will be installed under ${prefix}.
24803 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
24804 to run if these resources are not installed."
24805 fi
24806 echo
24807 fi
24808
24809 if test "${opsys}" = "cygwin"; then
24810 case `uname -r` in
24811 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
24812 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
24813 echo
24814 ;;
24815 esac
24816 fi
24817
24818 # Remove any trailing slashes in these variables.
24819 test "${prefix}" != NONE &&
24820 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
24821 test "${exec_prefix}" != NONE &&
24822 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
24823
24824 if test "$HAVE_NS" = "yes"; then
24825 if test "$NS_IMPL_GNUSTEP" = yes; then
24826 ac_config_files="$ac_config_files nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in"
24827
24828 else
24829 ac_config_files="$ac_config_files nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in"
24830
24831 fi
24832 fi
24833
24834 SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile"
24835
24836 ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile"
24837
24838
24839 opt_makefile=test/automated/Makefile
24840
24841 if test -f $srcdir/${opt_makefile}.in; then
24842 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24843 ac_config_files="$ac_config_files test/automated/Makefile"
24844
24845 fi
24846
24847
24848 opt_makefile=admin/unidata/Makefile
24849
24850 if test -f $srcdir/${opt_makefile}.in; then
24851 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24852 ac_config_files="$ac_config_files admin/unidata/Makefile"
24853
24854 fi
24855
24856
24857 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
24858
24859
24860
24861 ac_config_commands="$ac_config_commands mkdirs"
24862
24863
24864 ac_config_commands="$ac_config_commands epaths"
24865
24866
24867 ac_config_commands="$ac_config_commands gdbinit"
24868
24869
24870 cat >confcache <<\_ACEOF
24871 # This file is a shell script that caches the results of configure
24872 # tests run on this system so they can be shared between configure
24873 # scripts and configure runs, see configure's option --config-cache.
24874 # It is not useful on other systems. If it contains results you don't
24875 # want to keep, you may remove or edit it.
24876 #
24877 # config.status only pays attention to the cache file if you give it
24878 # the --recheck option to rerun configure.
24879 #
24880 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24881 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24882 # following values.
24883
24884 _ACEOF
24885
24886 # The following way of writing the cache mishandles newlines in values,
24887 # but we know of no workaround that is simple, portable, and efficient.
24888 # So, we kill variables containing newlines.
24889 # Ultrix sh set writes to stderr and can't be redirected directly,
24890 # and sets the high bit in the cache file unless we assign to the vars.
24891 (
24892 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24893 eval ac_val=\$$ac_var
24894 case $ac_val in #(
24895 *${as_nl}*)
24896 case $ac_var in #(
24897 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24898 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24899 esac
24900 case $ac_var in #(
24901 _ | IFS | as_nl) ;; #(
24902 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24903 *) { eval $ac_var=; unset $ac_var;} ;;
24904 esac ;;
24905 esac
24906 done
24907
24908 (set) 2>&1 |
24909 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24910 *${as_nl}ac_space=\ *)
24911 # `set' does not quote correctly, so add quotes: double-quote
24912 # substitution turns \\\\ into \\, and sed turns \\ into \.
24913 sed -n \
24914 "s/'/'\\\\''/g;
24915 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24916 ;; #(
24917 *)
24918 # `set' quotes correctly as required by POSIX, so do not add quotes.
24919 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24920 ;;
24921 esac |
24922 sort
24923 ) |
24924 sed '
24925 /^ac_cv_env_/b end
24926 t clear
24927 :clear
24928 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24929 t end
24930 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24931 :end' >>confcache
24932 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24933 if test -w "$cache_file"; then
24934 test "x$cache_file" != "x/dev/null" &&
24935 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24936 $as_echo "$as_me: updating cache $cache_file" >&6;}
24937 cat confcache >$cache_file
24938 else
24939 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24940 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24941 fi
24942 fi
24943 rm -f confcache
24944
24945 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24946 # Let make expand exec_prefix.
24947 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24948
24949 DEFS=-DHAVE_CONFIG_H
24950
24951 ac_libobjs=
24952 ac_ltlibobjs=
24953 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24954 # 1. Remove the extension, and $U if already installed.
24955 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24956 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24957 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24958 # will be set to the directory where LIBOBJS objects are built.
24959 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24960 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24961 done
24962 LIBOBJS=$ac_libobjs
24963
24964 LTLIBOBJS=$ac_ltlibobjs
24965
24966
24967 if test -n "$EXEEXT"; then
24968 am__EXEEXT_TRUE=
24969 am__EXEEXT_FALSE='#'
24970 else
24971 am__EXEEXT_TRUE='#'
24972 am__EXEEXT_FALSE=
24973 fi
24974
24975 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24976 as_fn_error "conditional \"AMDEP\" was never defined.
24977 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24978 fi
24979 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24980 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24981 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24982 fi
24983 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24984 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24985 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24986 fi
24987 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24988 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24989 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24990 fi
24991
24992 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
24993 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
24994 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24995 fi
24996 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24997 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24998 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24999 fi
25000 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
25001 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
25002 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25003 fi
25004 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
25005 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
25006 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25007 fi
25008 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
25009 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
25010 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25011 fi
25012 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
25013 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
25014 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25015 fi
25016 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
25017 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
25018 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25019 fi
25020 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
25021 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
25022 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25023 fi
25024 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
25025 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
25026 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25027 fi
25028 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
25029 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
25030 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25031 fi
25032 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
25033 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
25034 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25035 fi
25036 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
25037 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
25038 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25039 fi
25040 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
25041 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
25042 Usually this means the macro was only invoked conditionally." "$LINENO" 5
25043 fi
25044
25045 gl_libobjs=
25046 gl_ltlibobjs=
25047 if test -n "$gl_LIBOBJS"; then
25048 # Remove the extension.
25049 sed_drop_objext='s/\.o$//;s/\.obj$//'
25050 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25051 gl_libobjs="$gl_libobjs $i.$ac_objext"
25052 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
25053 done
25054 fi
25055 gl_LIBOBJS=$gl_libobjs
25056
25057 gl_LTLIBOBJS=$gl_ltlibobjs
25058
25059
25060
25061 gltests_libobjs=
25062 gltests_ltlibobjs=
25063 if test -n "$gltests_LIBOBJS"; then
25064 # Remove the extension.
25065 sed_drop_objext='s/\.o$//;s/\.obj$//'
25066 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25067 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
25068 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
25069 done
25070 fi
25071 gltests_LIBOBJS=$gltests_libobjs
25072
25073 gltests_LTLIBOBJS=$gltests_ltlibobjs
25074
25075
25076
25077 : ${CONFIG_STATUS=./config.status}
25078 ac_write_fail=0
25079 ac_clean_files_save=$ac_clean_files
25080 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25081 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
25082 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
25083 as_write_fail=0
25084 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
25085 #! $SHELL
25086 # Generated by $as_me.
25087 # Run this file to recreate the current configuration.
25088 # Compiler output produced by configure, useful for debugging
25089 # configure, is in config.log if it exists.
25090
25091 debug=false
25092 ac_cs_recheck=false
25093 ac_cs_silent=false
25094
25095 SHELL=\${CONFIG_SHELL-$SHELL}
25096 export SHELL
25097 _ASEOF
25098 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
25099 ## -------------------- ##
25100 ## M4sh Initialization. ##
25101 ## -------------------- ##
25102
25103 # Be more Bourne compatible
25104 DUALCASE=1; export DUALCASE # for MKS sh
25105 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
25106 emulate sh
25107 NULLCMD=:
25108 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25109 # is contrary to our usage. Disable this feature.
25110 alias -g '${1+"$@"}'='"$@"'
25111 setopt NO_GLOB_SUBST
25112 else
25113 case `(set -o) 2>/dev/null` in #(
25114 *posix*) :
25115 set -o posix ;; #(
25116 *) :
25117 ;;
25118 esac
25119 fi
25120
25121
25122 as_nl='
25123 '
25124 export as_nl
25125 # Printing a long string crashes Solaris 7 /usr/bin/printf.
25126 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
25127 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
25128 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
25129 # Prefer a ksh shell builtin over an external printf program on Solaris,
25130 # but without wasting forks for bash or zsh.
25131 if test -z "$BASH_VERSION$ZSH_VERSION" \
25132 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
25133 as_echo='print -r --'
25134 as_echo_n='print -rn --'
25135 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
25136 as_echo='printf %s\n'
25137 as_echo_n='printf %s'
25138 else
25139 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
25140 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
25141 as_echo_n='/usr/ucb/echo -n'
25142 else
25143 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
25144 as_echo_n_body='eval
25145 arg=$1;
25146 case $arg in #(
25147 *"$as_nl"*)
25148 expr "X$arg" : "X\\(.*\\)$as_nl";
25149 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
25150 esac;
25151 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
25152 '
25153 export as_echo_n_body
25154 as_echo_n='sh -c $as_echo_n_body as_echo'
25155 fi
25156 export as_echo_body
25157 as_echo='sh -c $as_echo_body as_echo'
25158 fi
25159
25160 # The user is always right.
25161 if test "${PATH_SEPARATOR+set}" != set; then
25162 PATH_SEPARATOR=:
25163 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
25164 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
25165 PATH_SEPARATOR=';'
25166 }
25167 fi
25168
25169
25170 # IFS
25171 # We need space, tab and new line, in precisely that order. Quoting is
25172 # there to prevent editors from complaining about space-tab.
25173 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
25174 # splitting by setting IFS to empty value.)
25175 IFS=" "" $as_nl"
25176
25177 # Find who we are. Look in the path if we contain no directory separator.
25178 case $0 in #((
25179 *[\\/]* ) as_myself=$0 ;;
25180 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25181 for as_dir in $PATH
25182 do
25183 IFS=$as_save_IFS
25184 test -z "$as_dir" && as_dir=.
25185 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
25186 done
25187 IFS=$as_save_IFS
25188
25189 ;;
25190 esac
25191 # We did not find ourselves, most probably we were run as `sh COMMAND'
25192 # in which case we are not to be found in the path.
25193 if test "x$as_myself" = x; then
25194 as_myself=$0
25195 fi
25196 if test ! -f "$as_myself"; then
25197 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
25198 exit 1
25199 fi
25200
25201 # Unset variables that we do not need and which cause bugs (e.g. in
25202 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
25203 # suppresses any "Segmentation fault" message there. '((' could
25204 # trigger a bug in pdksh 5.2.14.
25205 for as_var in BASH_ENV ENV MAIL MAILPATH
25206 do eval test x\${$as_var+set} = xset \
25207 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
25208 done
25209 PS1='$ '
25210 PS2='> '
25211 PS4='+ '
25212
25213 # NLS nuisances.
25214 LC_ALL=C
25215 export LC_ALL
25216 LANGUAGE=C
25217 export LANGUAGE
25218
25219 # CDPATH.
25220 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
25221
25222
25223 # as_fn_error ERROR [LINENO LOG_FD]
25224 # ---------------------------------
25225 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
25226 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
25227 # script with status $?, using 1 if that was 0.
25228 as_fn_error ()
25229 {
25230 as_status=$?; test $as_status -eq 0 && as_status=1
25231 if test "$3"; then
25232 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
25233 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
25234 fi
25235 $as_echo "$as_me: error: $1" >&2
25236 as_fn_exit $as_status
25237 } # as_fn_error
25238
25239
25240 # as_fn_set_status STATUS
25241 # -----------------------
25242 # Set $? to STATUS, without forking.
25243 as_fn_set_status ()
25244 {
25245 return $1
25246 } # as_fn_set_status
25247
25248 # as_fn_exit STATUS
25249 # -----------------
25250 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
25251 as_fn_exit ()
25252 {
25253 set +e
25254 as_fn_set_status $1
25255 exit $1
25256 } # as_fn_exit
25257
25258 # as_fn_unset VAR
25259 # ---------------
25260 # Portably unset VAR.
25261 as_fn_unset ()
25262 {
25263 { eval $1=; unset $1;}
25264 }
25265 as_unset=as_fn_unset
25266 # as_fn_append VAR VALUE
25267 # ----------------------
25268 # Append the text in VALUE to the end of the definition contained in VAR. Take
25269 # advantage of any shell optimizations that allow amortized linear growth over
25270 # repeated appends, instead of the typical quadratic growth present in naive
25271 # implementations.
25272 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
25273 eval 'as_fn_append ()
25274 {
25275 eval $1+=\$2
25276 }'
25277 else
25278 as_fn_append ()
25279 {
25280 eval $1=\$$1\$2
25281 }
25282 fi # as_fn_append
25283
25284 # as_fn_arith ARG...
25285 # ------------------
25286 # Perform arithmetic evaluation on the ARGs, and store the result in the
25287 # global $as_val. Take advantage of shells that can avoid forks. The arguments
25288 # must be portable across $(()) and expr.
25289 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
25290 eval 'as_fn_arith ()
25291 {
25292 as_val=$(( $* ))
25293 }'
25294 else
25295 as_fn_arith ()
25296 {
25297 as_val=`expr "$@" || test $? -eq 1`
25298 }
25299 fi # as_fn_arith
25300
25301
25302 if expr a : '\(a\)' >/dev/null 2>&1 &&
25303 test "X`expr 00001 : '.*\(...\)'`" = X001; then
25304 as_expr=expr
25305 else
25306 as_expr=false
25307 fi
25308
25309 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
25310 as_basename=basename
25311 else
25312 as_basename=false
25313 fi
25314
25315 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
25316 as_dirname=dirname
25317 else
25318 as_dirname=false
25319 fi
25320
25321 as_me=`$as_basename -- "$0" ||
25322 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
25323 X"$0" : 'X\(//\)$' \| \
25324 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
25325 $as_echo X/"$0" |
25326 sed '/^.*\/\([^/][^/]*\)\/*$/{
25327 s//\1/
25328 q
25329 }
25330 /^X\/\(\/\/\)$/{
25331 s//\1/
25332 q
25333 }
25334 /^X\/\(\/\).*/{
25335 s//\1/
25336 q
25337 }
25338 s/.*/./; q'`
25339
25340 # Avoid depending upon Character Ranges.
25341 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25342 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25343 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25344 as_cr_digits='0123456789'
25345 as_cr_alnum=$as_cr_Letters$as_cr_digits
25346
25347 ECHO_C= ECHO_N= ECHO_T=
25348 case `echo -n x` in #(((((
25349 -n*)
25350 case `echo 'xy\c'` in
25351 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
25352 xy) ECHO_C='\c';;
25353 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
25354 ECHO_T=' ';;
25355 esac;;
25356 *)
25357 ECHO_N='-n';;
25358 esac
25359
25360 rm -f conf$$ conf$$.exe conf$$.file
25361 if test -d conf$$.dir; then
25362 rm -f conf$$.dir/conf$$.file
25363 else
25364 rm -f conf$$.dir
25365 mkdir conf$$.dir 2>/dev/null
25366 fi
25367 if (echo >conf$$.file) 2>/dev/null; then
25368 if ln -s conf$$.file conf$$ 2>/dev/null; then
25369 as_ln_s='ln -s'
25370 # ... but there are two gotchas:
25371 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
25372 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
25373 # In both cases, we have to default to `cp -p'.
25374 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
25375 as_ln_s='cp -p'
25376 elif ln conf$$.file conf$$ 2>/dev/null; then
25377 as_ln_s=ln
25378 else
25379 as_ln_s='cp -p'
25380 fi
25381 else
25382 as_ln_s='cp -p'
25383 fi
25384 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
25385 rmdir conf$$.dir 2>/dev/null
25386
25387
25388 # as_fn_mkdir_p
25389 # -------------
25390 # Create "$as_dir" as a directory, including parents if necessary.
25391 as_fn_mkdir_p ()
25392 {
25393
25394 case $as_dir in #(
25395 -*) as_dir=./$as_dir;;
25396 esac
25397 test -d "$as_dir" || eval $as_mkdir_p || {
25398 as_dirs=
25399 while :; do
25400 case $as_dir in #(
25401 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
25402 *) as_qdir=$as_dir;;
25403 esac
25404 as_dirs="'$as_qdir' $as_dirs"
25405 as_dir=`$as_dirname -- "$as_dir" ||
25406 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25407 X"$as_dir" : 'X\(//\)[^/]' \| \
25408 X"$as_dir" : 'X\(//\)$' \| \
25409 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
25410 $as_echo X"$as_dir" |
25411 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25412 s//\1/
25413 q
25414 }
25415 /^X\(\/\/\)[^/].*/{
25416 s//\1/
25417 q
25418 }
25419 /^X\(\/\/\)$/{
25420 s//\1/
25421 q
25422 }
25423 /^X\(\/\).*/{
25424 s//\1/
25425 q
25426 }
25427 s/.*/./; q'`
25428 test -d "$as_dir" && break
25429 done
25430 test -z "$as_dirs" || eval "mkdir $as_dirs"
25431 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
25432
25433
25434 } # as_fn_mkdir_p
25435 if mkdir -p . 2>/dev/null; then
25436 as_mkdir_p='mkdir -p "$as_dir"'
25437 else
25438 test -d ./-p && rmdir ./-p
25439 as_mkdir_p=false
25440 fi
25441
25442 if test -x / >/dev/null 2>&1; then
25443 as_test_x='test -x'
25444 else
25445 if ls -dL / >/dev/null 2>&1; then
25446 as_ls_L_option=L
25447 else
25448 as_ls_L_option=
25449 fi
25450 as_test_x='
25451 eval sh -c '\''
25452 if test -d "$1"; then
25453 test -d "$1/.";
25454 else
25455 case $1 in #(
25456 -*)set "./$1";;
25457 esac;
25458 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
25459 ???[sx]*):;;*)false;;esac;fi
25460 '\'' sh
25461 '
25462 fi
25463 as_executable_p=$as_test_x
25464
25465 # Sed expression to map a string onto a valid CPP name.
25466 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
25467
25468 # Sed expression to map a string onto a valid variable name.
25469 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
25470
25471
25472 exec 6>&1
25473 ## ----------------------------------- ##
25474 ## Main body of $CONFIG_STATUS script. ##
25475 ## ----------------------------------- ##
25476 _ASEOF
25477 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
25478
25479 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25480 # Save the log message, to keep $0 and so on meaningful, and to
25481 # report actual input values of CONFIG_FILES etc. instead of their
25482 # values after options handling.
25483 ac_log="
25484 This file was extended by emacs $as_me 24.2.50, which was
25485 generated by GNU Autoconf 2.65. Invocation command line was
25486
25487 CONFIG_FILES = $CONFIG_FILES
25488 CONFIG_HEADERS = $CONFIG_HEADERS
25489 CONFIG_LINKS = $CONFIG_LINKS
25490 CONFIG_COMMANDS = $CONFIG_COMMANDS
25491 $ $0 $@
25492
25493 on `(hostname || uname -n) 2>/dev/null | sed 1q`
25494 "
25495
25496 _ACEOF
25497
25498 case $ac_config_files in *"
25499 "*) set x $ac_config_files; shift; ac_config_files=$*;;
25500 esac
25501
25502 case $ac_config_headers in *"
25503 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
25504 esac
25505
25506
25507 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25508 # Files that config.status was made for.
25509 config_files="$ac_config_files"
25510 config_headers="$ac_config_headers"
25511 config_commands="$ac_config_commands"
25512
25513 _ACEOF
25514
25515 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25516 ac_cs_usage="\
25517 \`$as_me' instantiates files and other configuration actions
25518 from templates according to the current configuration. Unless the files
25519 and actions are specified as TAGs, all are instantiated by default.
25520
25521 Usage: $0 [OPTION]... [TAG]...
25522
25523 -h, --help print this help, then exit
25524 -V, --version print version number and configuration settings, then exit
25525 --config print configuration, then exit
25526 -q, --quiet, --silent
25527 do not print progress messages
25528 -d, --debug don't remove temporary files
25529 --recheck update $as_me by reconfiguring in the same conditions
25530 --file=FILE[:TEMPLATE]
25531 instantiate the configuration file FILE
25532 --header=FILE[:TEMPLATE]
25533 instantiate the configuration header FILE
25534
25535 Configuration files:
25536 $config_files
25537
25538 Configuration headers:
25539 $config_headers
25540
25541 Configuration commands:
25542 $config_commands
25543
25544 Report bugs to the package provider."
25545
25546 _ACEOF
25547 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25548 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
25549 ac_cs_version="\\
25550 emacs config.status 24.2.50
25551 configured by $0, generated by GNU Autoconf 2.65,
25552 with options \\"\$ac_cs_config\\"
25553
25554 Copyright (C) 2009 Free Software Foundation, Inc.
25555 This config.status script is free software; the Free Software Foundation
25556 gives unlimited permission to copy, distribute and modify it."
25557
25558 ac_pwd='$ac_pwd'
25559 srcdir='$srcdir'
25560 INSTALL='$INSTALL'
25561 MKDIR_P='$MKDIR_P'
25562 AWK='$AWK'
25563 test -n "\$AWK" || AWK=awk
25564 _ACEOF
25565
25566 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25567 # The default lists apply if the user does not specify any file.
25568 ac_need_defaults=:
25569 while test $# != 0
25570 do
25571 case $1 in
25572 --*=*)
25573 ac_option=`expr "X$1" : 'X\([^=]*\)='`
25574 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
25575 ac_shift=:
25576 ;;
25577 *)
25578 ac_option=$1
25579 ac_optarg=$2
25580 ac_shift=shift
25581 ;;
25582 esac
25583
25584 case $ac_option in
25585 # Handling of the options.
25586 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25587 ac_cs_recheck=: ;;
25588 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
25589 $as_echo "$ac_cs_version"; exit ;;
25590 --config | --confi | --conf | --con | --co | --c )
25591 $as_echo "$ac_cs_config"; exit ;;
25592 --debug | --debu | --deb | --de | --d | -d )
25593 debug=: ;;
25594 --file | --fil | --fi | --f )
25595 $ac_shift
25596 case $ac_optarg in
25597 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25598 esac
25599 as_fn_append CONFIG_FILES " '$ac_optarg'"
25600 ac_need_defaults=false;;
25601 --header | --heade | --head | --hea )
25602 $ac_shift
25603 case $ac_optarg in
25604 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25605 esac
25606 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
25607 ac_need_defaults=false;;
25608 --he | --h)
25609 # Conflict between --help and --header
25610 as_fn_error "ambiguous option: \`$1'
25611 Try \`$0 --help' for more information.";;
25612 --help | --hel | -h )
25613 $as_echo "$ac_cs_usage"; exit ;;
25614 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25615 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25616 ac_cs_silent=: ;;
25617
25618 # This is an error.
25619 -*) as_fn_error "unrecognized option: \`$1'
25620 Try \`$0 --help' for more information." ;;
25621
25622 *) as_fn_append ac_config_targets " $1"
25623 ac_need_defaults=false ;;
25624
25625 esac
25626 shift
25627 done
25628
25629 ac_configure_extra_args=
25630
25631 if $ac_cs_silent; then
25632 exec 6>/dev/null
25633 ac_configure_extra_args="$ac_configure_extra_args --silent"
25634 fi
25635
25636 _ACEOF
25637 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25638 if \$ac_cs_recheck; then
25639 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
25640 shift
25641 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
25642 CONFIG_SHELL='$SHELL'
25643 export CONFIG_SHELL
25644 exec "\$@"
25645 fi
25646
25647 _ACEOF
25648 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25649 exec 5>>config.log
25650 {
25651 echo
25652 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25653 ## Running $as_me. ##
25654 _ASBOX
25655 $as_echo "$ac_log"
25656 } >&5
25657
25658 _ACEOF
25659 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25660 #
25661 # INIT-COMMANDS
25662 #
25663 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
25664 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
25665
25666 _ACEOF
25667
25668 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25669
25670 # Handling of arguments.
25671 for ac_config_target in $ac_config_targets
25672 do
25673 case $ac_config_target in
25674 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
25675 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25676 "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in" ;;
25677 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
25678 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
25679 "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in" ;;
25680 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25681 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
25682 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
25683 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
25684 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
25685 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
25686 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
25687 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
25688 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
25689 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
25690 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
25691 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
25692 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
25693 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
25694 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
25695 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
25696 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
25697 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
25698
25699 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25700 esac
25701 done
25702
25703
25704 # If the user did not use the arguments to specify the items to instantiate,
25705 # then the envvar interface is used. Set only those that are not.
25706 # We use the long form for the default assignment because of an extremely
25707 # bizarre bug on SunOS 4.1.3.
25708 if $ac_need_defaults; then
25709 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25710 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25711 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25712 fi
25713
25714 # Have a temporary directory for convenience. Make it in the build tree
25715 # simply because there is no reason against having it here, and in addition,
25716 # creating and moving files from /tmp can sometimes cause problems.
25717 # Hook for its removal unless debugging.
25718 # Note that there is a small window in which the directory will not be cleaned:
25719 # after its creation but before its name has been assigned to `$tmp'.
25720 $debug ||
25721 {
25722 tmp=
25723 trap 'exit_status=$?
25724 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25725 ' 0
25726 trap 'as_fn_exit 1' 1 2 13 15
25727 }
25728 # Create a (secure) tmp directory for tmp files.
25729
25730 {
25731 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25732 test -n "$tmp" && test -d "$tmp"
25733 } ||
25734 {
25735 tmp=./conf$$-$RANDOM
25736 (umask 077 && mkdir "$tmp")
25737 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25738
25739 # Set up the scripts for CONFIG_FILES section.
25740 # No need to generate them if there are no CONFIG_FILES.
25741 # This happens for instance with `./config.status config.h'.
25742 if test -n "$CONFIG_FILES"; then
25743
25744 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
25745 ac_cs_awk_getline=:
25746 ac_cs_awk_pipe_init=
25747 ac_cs_awk_read_file='
25748 while ((getline aline < (F[key])) > 0)
25749 print(aline)
25750 close(F[key])'
25751 ac_cs_awk_pipe_fini=
25752 else
25753 ac_cs_awk_getline=false
25754 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
25755 ac_cs_awk_read_file='
25756 print "|#_!!_#|"
25757 print "cat " F[key] " &&"
25758 '$ac_cs_awk_pipe_init
25759 # The final `:' finishes the AND list.
25760 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
25761 fi
25762 ac_cr=`echo X | tr X '\015'`
25763 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25764 # But we know of no other shell where ac_cr would be empty at this
25765 # point, so we can use a bashism as a fallback.
25766 if test "x$ac_cr" = x; then
25767 eval ac_cr=\$\'\\r\'
25768 fi
25769 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25770 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25771 ac_cs_awk_cr='\r'
25772 else
25773 ac_cs_awk_cr=$ac_cr
25774 fi
25775
25776 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25777 _ACEOF
25778
25779 # Create commands to substitute file output variables.
25780 {
25781 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
25782 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
25783 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
25784 echo "_ACAWK" &&
25785 echo "_ACEOF"
25786 } >conf$$files.sh &&
25787 . ./conf$$files.sh ||
25788 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25789 rm -f conf$$files.sh
25790
25791 {
25792 echo "cat >conf$$subs.awk <<_ACEOF" &&
25793 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25794 echo "_ACEOF"
25795 } >conf$$subs.sh ||
25796 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25797 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25798 ac_delim='%!_!# '
25799 for ac_last_try in false false false false false :; do
25800 . ./conf$$subs.sh ||
25801 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25802
25803 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25804 if test $ac_delim_n = $ac_delim_num; then
25805 break
25806 elif $ac_last_try; then
25807 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25808 else
25809 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25810 fi
25811 done
25812 rm -f conf$$subs.sh
25813
25814 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25815 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25816 _ACEOF
25817 sed -n '
25818 h
25819 s/^/S["/; s/!.*/"]=/
25820 p
25821 g
25822 s/^[^!]*!//
25823 :repl
25824 t repl
25825 s/'"$ac_delim"'$//
25826 t delim
25827 :nl
25828 h
25829 s/\(.\{148\}\)..*/\1/
25830 t more1
25831 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25832 p
25833 n
25834 b repl
25835 :more1
25836 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25837 p
25838 g
25839 s/.\{148\}//
25840 t nl
25841 :delim
25842 h
25843 s/\(.\{148\}\)..*/\1/
25844 t more2
25845 s/["\\]/\\&/g; s/^/"/; s/$/"/
25846 p
25847 b
25848 :more2
25849 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25850 p
25851 g
25852 s/.\{148\}//
25853 t delim
25854 ' <conf$$subs.awk | sed '
25855 /^[^""]/{
25856 N
25857 s/\n//
25858 }
25859 ' >>$CONFIG_STATUS || ac_write_fail=1
25860 rm -f conf$$subs.awk
25861 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25862 _ACAWK
25863 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25864 for (key in S) S_is_set[key] = 1
25865 FS = "\a"
25866 \$ac_cs_awk_pipe_init
25867 }
25868 {
25869 line = $ 0
25870 nfields = split(line, field, "@")
25871 substed = 0
25872 len = length(field[1])
25873 for (i = 2; i < nfields; i++) {
25874 key = field[i]
25875 keylen = length(key)
25876 if (S_is_set[key]) {
25877 value = S[key]
25878 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25879 len += length(value) + length(field[++i])
25880 substed = 1
25881 } else
25882 len += 1 + keylen
25883 }
25884 if (nfields == 3 && !substed) {
25885 key = field[2]
25886 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
25887 \$ac_cs_awk_read_file
25888 next
25889 }
25890 }
25891 print line
25892 }
25893 \$ac_cs_awk_pipe_fini
25894 _ACAWK
25895 _ACEOF
25896 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25897 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25898 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25899 else
25900 cat
25901 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25902 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25903 _ACEOF
25904
25905 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25906 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25907 # trailing colons and then remove the whole line if VPATH becomes empty
25908 # (actually we leave an empty line to preserve line numbers).
25909 if test "x$srcdir" = x.; then
25910 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25911 s/:*\$(srcdir):*/:/
25912 s/:*\${srcdir}:*/:/
25913 s/:*@srcdir@:*/:/
25914 s/^\([^=]*=[ ]*\):*/\1/
25915 s/:*$//
25916 s/^[^=]*=[ ]*$//
25917 }'
25918 fi
25919
25920 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25921 fi # test -n "$CONFIG_FILES"
25922
25923 # Set up the scripts for CONFIG_HEADERS section.
25924 # No need to generate them if there are no CONFIG_HEADERS.
25925 # This happens for instance with `./config.status Makefile'.
25926 if test -n "$CONFIG_HEADERS"; then
25927 cat >"$tmp/defines.awk" <<\_ACAWK ||
25928 BEGIN {
25929 _ACEOF
25930
25931 # Transform confdefs.h into an awk script `defines.awk', embedded as
25932 # here-document in config.status, that substitutes the proper values into
25933 # config.h.in to produce config.h.
25934
25935 # Create a delimiter string that does not exist in confdefs.h, to ease
25936 # handling of long lines.
25937 ac_delim='%!_!# '
25938 for ac_last_try in false false :; do
25939 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25940 if test -z "$ac_t"; then
25941 break
25942 elif $ac_last_try; then
25943 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25944 else
25945 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25946 fi
25947 done
25948
25949 # For the awk script, D is an array of macro values keyed by name,
25950 # likewise P contains macro parameters if any. Preserve backslash
25951 # newline sequences.
25952
25953 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25954 sed -n '
25955 s/.\{148\}/&'"$ac_delim"'/g
25956 t rset
25957 :rset
25958 s/^[ ]*#[ ]*define[ ][ ]*/ /
25959 t def
25960 d
25961 :def
25962 s/\\$//
25963 t bsnl
25964 s/["\\]/\\&/g
25965 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25966 D["\1"]=" \3"/p
25967 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25968 d
25969 :bsnl
25970 s/["\\]/\\&/g
25971 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25972 D["\1"]=" \3\\\\\\n"\\/p
25973 t cont
25974 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25975 t cont
25976 d
25977 :cont
25978 n
25979 s/.\{148\}/&'"$ac_delim"'/g
25980 t clear
25981 :clear
25982 s/\\$//
25983 t bsnlc
25984 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25985 d
25986 :bsnlc
25987 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25988 b cont
25989 ' <confdefs.h | sed '
25990 s/'"$ac_delim"'/"\\\
25991 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25992
25993 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25994 for (key in D) D_is_set[key] = 1
25995 FS = "\a"
25996 }
25997 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25998 line = \$ 0
25999 split(line, arg, " ")
26000 if (arg[1] == "#") {
26001 defundef = arg[2]
26002 mac1 = arg[3]
26003 } else {
26004 defundef = substr(arg[1], 2)
26005 mac1 = arg[2]
26006 }
26007 split(mac1, mac2, "(") #)
26008 macro = mac2[1]
26009 prefix = substr(line, 1, index(line, defundef) - 1)
26010 if (D_is_set[macro]) {
26011 # Preserve the white space surrounding the "#".
26012 print prefix "define", macro P[macro] D[macro]
26013 next
26014 } else {
26015 # Replace #undef with comments. This is necessary, for example,
26016 # in the case of _POSIX_SOURCE, which is predefined and required
26017 # on some systems where configure will not decide to define it.
26018 if (defundef == "undef") {
26019 print "/*", prefix defundef, macro, "*/"
26020 next
26021 }
26022 }
26023 }
26024 { print }
26025 _ACAWK
26026 _ACEOF
26027 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26028 as_fn_error "could not setup config headers machinery" "$LINENO" 5
26029 fi # test -n "$CONFIG_HEADERS"
26030
26031
26032 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
26033 shift
26034 for ac_tag
26035 do
26036 case $ac_tag in
26037 :[FHLC]) ac_mode=$ac_tag; continue;;
26038 esac
26039 case $ac_mode$ac_tag in
26040 :[FHL]*:*);;
26041 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
26042 :[FH]-) ac_tag=-:-;;
26043 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
26044 esac
26045 ac_save_IFS=$IFS
26046 IFS=:
26047 set x $ac_tag
26048 IFS=$ac_save_IFS
26049 shift
26050 ac_file=$1
26051 shift
26052
26053 case $ac_mode in
26054 :L) ac_source=$1;;
26055 :[FH])
26056 ac_file_inputs=
26057 for ac_f
26058 do
26059 case $ac_f in
26060 -) ac_f="$tmp/stdin";;
26061 *) # Look for the file first in the build tree, then in the source tree
26062 # (if the path is not absolute). The absolute path cannot be DOS-style,
26063 # because $ac_f cannot contain `:'.
26064 test -f "$ac_f" ||
26065 case $ac_f in
26066 [\\/$]*) false;;
26067 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26068 esac ||
26069 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
26070 esac
26071 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
26072 as_fn_append ac_file_inputs " '$ac_f'"
26073 done
26074
26075 # Let's still pretend it is `configure' which instantiates (i.e., don't
26076 # use $as_me), people would be surprised to read:
26077 # /* config.h. Generated by config.status. */
26078 configure_input='Generated from '`
26079 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
26080 `' by configure.'
26081 if test x"$ac_file" != x-; then
26082 configure_input="$ac_file. $configure_input"
26083 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
26084 $as_echo "$as_me: creating $ac_file" >&6;}
26085 fi
26086 # Neutralize special characters interpreted by sed in replacement strings.
26087 case $configure_input in #(
26088 *\&* | *\|* | *\\* )
26089 ac_sed_conf_input=`$as_echo "$configure_input" |
26090 sed 's/[\\\\&|]/\\\\&/g'`;; #(
26091 *) ac_sed_conf_input=$configure_input;;
26092 esac
26093
26094 case $ac_tag in
26095 *:-:* | *:-) cat >"$tmp/stdin" \
26096 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
26097 esac
26098 ;;
26099 esac
26100
26101 ac_dir=`$as_dirname -- "$ac_file" ||
26102 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26103 X"$ac_file" : 'X\(//\)[^/]' \| \
26104 X"$ac_file" : 'X\(//\)$' \| \
26105 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
26106 $as_echo X"$ac_file" |
26107 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26108 s//\1/
26109 q
26110 }
26111 /^X\(\/\/\)[^/].*/{
26112 s//\1/
26113 q
26114 }
26115 /^X\(\/\/\)$/{
26116 s//\1/
26117 q
26118 }
26119 /^X\(\/\).*/{
26120 s//\1/
26121 q
26122 }
26123 s/.*/./; q'`
26124 as_dir="$ac_dir"; as_fn_mkdir_p
26125 ac_builddir=.
26126
26127 case "$ac_dir" in
26128 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26129 *)
26130 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
26131 # A ".." for each directory in $ac_dir_suffix.
26132 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
26133 case $ac_top_builddir_sub in
26134 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26135 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26136 esac ;;
26137 esac
26138 ac_abs_top_builddir=$ac_pwd
26139 ac_abs_builddir=$ac_pwd$ac_dir_suffix
26140 # for backward compatibility:
26141 ac_top_builddir=$ac_top_build_prefix
26142
26143 case $srcdir in
26144 .) # We are building in place.
26145 ac_srcdir=.
26146 ac_top_srcdir=$ac_top_builddir_sub
26147 ac_abs_top_srcdir=$ac_pwd ;;
26148 [\\/]* | ?:[\\/]* ) # Absolute name.
26149 ac_srcdir=$srcdir$ac_dir_suffix;
26150 ac_top_srcdir=$srcdir
26151 ac_abs_top_srcdir=$srcdir ;;
26152 *) # Relative name.
26153 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26154 ac_top_srcdir=$ac_top_build_prefix$srcdir
26155 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
26156 esac
26157 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
26158
26159
26160 case $ac_mode in
26161 :F)
26162 #
26163 # CONFIG_FILE
26164 #
26165
26166 case $INSTALL in
26167 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
26168 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
26169 esac
26170 ac_MKDIR_P=$MKDIR_P
26171 case $MKDIR_P in
26172 [\\/$]* | ?:[\\/]* ) ;;
26173 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
26174 esac
26175 _ACEOF
26176
26177 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26178 # If the template does not know about datarootdir, expand it.
26179 # FIXME: This hack should be removed a few years after 2.60.
26180 ac_datarootdir_hack=; ac_datarootdir_seen=
26181 ac_sed_dataroot='
26182 /datarootdir/ {
26183 p
26184 q
26185 }
26186 /@datadir@/p
26187 /@docdir@/p
26188 /@infodir@/p
26189 /@localedir@/p
26190 /@mandir@/p'
26191 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
26192 *datarootdir*) ac_datarootdir_seen=yes;;
26193 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
26194 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26195 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
26196 _ACEOF
26197 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26198 ac_datarootdir_hack='
26199 s&@datadir@&$datadir&g
26200 s&@docdir@&$docdir&g
26201 s&@infodir@&$infodir&g
26202 s&@localedir@&$localedir&g
26203 s&@mandir@&$mandir&g
26204 s&\\\${datarootdir}&$datarootdir&g' ;;
26205 esac
26206 _ACEOF
26207
26208 # Neutralize VPATH when `$srcdir' = `.'.
26209 # Shell code in configure.ac might set extrasub.
26210 # FIXME: do we really want to maintain this feature?
26211 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26212 ac_sed_extra="$ac_vpsub
26213 $extrasub
26214 _ACEOF
26215 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26216 :t
26217 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26218 s|@configure_input@|$ac_sed_conf_input|;t t
26219 s&@top_builddir@&$ac_top_builddir_sub&;t t
26220 s&@top_build_prefix@&$ac_top_build_prefix&;t t
26221 s&@srcdir@&$ac_srcdir&;t t
26222 s&@abs_srcdir@&$ac_abs_srcdir&;t t
26223 s&@top_srcdir@&$ac_top_srcdir&;t t
26224 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
26225 s&@builddir@&$ac_builddir&;t t
26226 s&@abs_builddir@&$ac_abs_builddir&;t t
26227 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
26228 s&@INSTALL@&$ac_INSTALL&;t t
26229 s&@MKDIR_P@&$ac_MKDIR_P&;t t
26230 $ac_datarootdir_hack
26231 "
26232 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
26233 if $ac_cs_awk_getline; then
26234 $AWK -f "$tmp/subs.awk"
26235 else
26236 $AWK -f "$tmp/subs.awk" | $SHELL
26237 fi >$tmp/out \
26238 || as_fn_error "could not create $ac_file" "$LINENO" 5
26239
26240 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
26241 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
26242 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
26243 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26244 which seems to be undefined. Please make sure it is defined." >&5
26245 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26246 which seems to be undefined. Please make sure it is defined." >&2;}
26247
26248 rm -f "$tmp/stdin"
26249 case $ac_file in
26250 -) cat "$tmp/out" && rm -f "$tmp/out";;
26251 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
26252 esac \
26253 || as_fn_error "could not create $ac_file" "$LINENO" 5
26254 ;;
26255 :H)
26256 #
26257 # CONFIG_HEADER
26258 #
26259 if test x"$ac_file" != x-; then
26260 {
26261 $as_echo "/* $configure_input */" \
26262 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
26263 } >"$tmp/config.h" \
26264 || as_fn_error "could not create $ac_file" "$LINENO" 5
26265 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
26266 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
26267 $as_echo "$as_me: $ac_file is unchanged" >&6;}
26268 else
26269 rm -f "$ac_file"
26270 mv "$tmp/config.h" "$ac_file" \
26271 || as_fn_error "could not create $ac_file" "$LINENO" 5
26272 fi
26273 else
26274 $as_echo "/* $configure_input */" \
26275 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
26276 || as_fn_error "could not create -" "$LINENO" 5
26277 fi
26278 # Compute "$ac_file"'s index in $config_headers.
26279 _am_arg="$ac_file"
26280 _am_stamp_count=1
26281 for _am_header in $config_headers :; do
26282 case $_am_header in
26283 $_am_arg | $_am_arg:* )
26284 break ;;
26285 * )
26286 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
26287 esac
26288 done
26289 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
26290 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26291 X"$_am_arg" : 'X\(//\)[^/]' \| \
26292 X"$_am_arg" : 'X\(//\)$' \| \
26293 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
26294 $as_echo X"$_am_arg" |
26295 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26296 s//\1/
26297 q
26298 }
26299 /^X\(\/\/\)[^/].*/{
26300 s//\1/
26301 q
26302 }
26303 /^X\(\/\/\)$/{
26304 s//\1/
26305 q
26306 }
26307 /^X\(\/\).*/{
26308 s//\1/
26309 q
26310 }
26311 s/.*/./; q'`/stamp-h$_am_stamp_count
26312 ;;
26313
26314 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
26315 $as_echo "$as_me: executing $ac_file commands" >&6;}
26316 ;;
26317 esac
26318
26319
26320 case $ac_file$ac_mode in
26321 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
26322 # Autoconf 2.62 quotes --file arguments for eval, but not when files
26323 # are listed without --file. Let's play safe and only enable the eval
26324 # if we detect the quoting.
26325 case $CONFIG_FILES in
26326 *\'*) eval set x "$CONFIG_FILES" ;;
26327 *) set x $CONFIG_FILES ;;
26328 esac
26329 shift
26330 for mf
26331 do
26332 # Strip MF so we end up with the name of the file.
26333 mf=`echo "$mf" | sed -e 's/:.*$//'`
26334 # Check whether this is an Automake generated Makefile or not.
26335 # We used to match only the files named `Makefile.in', but
26336 # some people rename them; so instead we look at the file content.
26337 # Grep'ing the first line is not enough: some people post-process
26338 # each Makefile.in and add a new line on top of each file to say so.
26339 # Grep'ing the whole file is not good either: AIX grep has a line
26340 # limit of 2048, but all sed's we know have understand at least 4000.
26341 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
26342 dirpart=`$as_dirname -- "$mf" ||
26343 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26344 X"$mf" : 'X\(//\)[^/]' \| \
26345 X"$mf" : 'X\(//\)$' \| \
26346 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
26347 $as_echo X"$mf" |
26348 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26349 s//\1/
26350 q
26351 }
26352 /^X\(\/\/\)[^/].*/{
26353 s//\1/
26354 q
26355 }
26356 /^X\(\/\/\)$/{
26357 s//\1/
26358 q
26359 }
26360 /^X\(\/\).*/{
26361 s//\1/
26362 q
26363 }
26364 s/.*/./; q'`
26365 else
26366 continue
26367 fi
26368 # Extract the definition of DEPDIR, am__include, and am__quote
26369 # from the Makefile without running `make'.
26370 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
26371 test -z "$DEPDIR" && continue
26372 am__include=`sed -n 's/^am__include = //p' < "$mf"`
26373 test -z "am__include" && continue
26374 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
26375 # When using ansi2knr, U may be empty or an underscore; expand it
26376 U=`sed -n 's/^U = //p' < "$mf"`
26377 # Find all dependency output files, they are included files with
26378 # $(DEPDIR) in their names. We invoke sed twice because it is the
26379 # simplest approach to changing $(DEPDIR) to its actual value in the
26380 # expansion.
26381 for file in `sed -n "
26382 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
26383 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
26384 # Make sure the directory exists.
26385 test -f "$dirpart/$file" && continue
26386 fdir=`$as_dirname -- "$file" ||
26387 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26388 X"$file" : 'X\(//\)[^/]' \| \
26389 X"$file" : 'X\(//\)$' \| \
26390 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
26391 $as_echo X"$file" |
26392 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26393 s//\1/
26394 q
26395 }
26396 /^X\(\/\/\)[^/].*/{
26397 s//\1/
26398 q
26399 }
26400 /^X\(\/\/\)$/{
26401 s//\1/
26402 q
26403 }
26404 /^X\(\/\).*/{
26405 s//\1/
26406 q
26407 }
26408 s/.*/./; q'`
26409 as_dir=$dirpart/$fdir; as_fn_mkdir_p
26410 # echo "creating $dirpart/$file"
26411 echo '# dummy' > "$dirpart/$file"
26412 done
26413 done
26414 }
26415 ;;
26416 "mkdirs":C)
26417 for dir in etc lisp ; do
26418 test -d ${dir} || mkdir ${dir}
26419 done
26420 ;;
26421 "epaths":C)
26422 echo creating src/epaths.h
26423 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
26424 ;;
26425 "gdbinit":C)
26426 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
26427 echo creating src/.gdbinit
26428 echo source $srcdir/src/.gdbinit > src/.gdbinit
26429 fi
26430 ;;
26431
26432 esac
26433 done # for ac_tag
26434
26435
26436 as_fn_exit 0
26437 _ACEOF
26438 ac_clean_files=$ac_clean_files_save
26439
26440 test $ac_write_fail = 0 ||
26441 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
26442
26443
26444 # configure is writing to config.log, and then calls config.status.
26445 # config.status does its own redirection, appending to config.log.
26446 # Unfortunately, on DOS this fails, as config.log is still kept open
26447 # by configure, so config.status won't be able to write to it; its
26448 # output is simply discarded. So we exec the FD to /dev/null,
26449 # effectively closing config.log, so it can be properly (re)opened and
26450 # appended to by config.status. When coming back to configure, we
26451 # need to make the FD available again.
26452 if test "$no_create" != yes; then
26453 ac_cs_success=:
26454 ac_config_status_args=
26455 test "$silent" = yes &&
26456 ac_config_status_args="$ac_config_status_args --quiet"
26457 exec 5>/dev/null
26458 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
26459 exec 5>>config.log
26460 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26461 # would make configure fail if this is the last instruction.
26462 $ac_cs_success || as_fn_exit $?
26463 fi
26464 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
26465 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
26466 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
26467 fi
26468