]> code.delx.au - gnu-emacs/blob - autogen/configure
Merge from trunk.
[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.3.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.3.50'
553 PACKAGE_STRING='emacs 24.3.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.3.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.3.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 MS 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.3.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.3.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 " fcntl.h"
3188 as_fn_append ac_header_list " coff.h"
3189 as_fn_append ac_header_list " pty.h"
3190 as_fn_append ac_header_list " sys/vlimit.h"
3191 as_fn_append ac_header_list " sys/resource.h"
3192 as_fn_append ac_header_list " sys/utsname.h"
3193 as_fn_append ac_header_list " pwd.h"
3194 as_fn_append ac_header_list " utmp.h"
3195 as_fn_append ac_header_list " dirent.h"
3196 as_fn_append ac_header_list " util.h"
3197 as_fn_append ac_header_list " sys/socket.h"
3198 as_fn_append ac_header_list " stdlib.h"
3199 as_fn_append ac_header_list " unistd.h"
3200 as_fn_append ac_header_list " sys/param.h"
3201 as_fn_append ac_header_list " pthread.h"
3202 as_fn_append ac_header_list " malloc/malloc.h"
3203 as_fn_append ac_header_list " maillock.h"
3204 as_fn_append ac_header_list " sys/un.h"
3205 as_fn_append ac_func_list " tzset"
3206 as_fn_append ac_func_list " readlinkat"
3207 as_fn_append ac_header_list " execinfo.h"
3208 as_fn_append ac_header_list " stdio_ext.h"
3209 as_fn_append ac_func_list " __fpending"
3210 gl_getopt_required=GNU
3211 as_fn_append ac_header_list " getopt.h"
3212 as_fn_append ac_func_list " gettimeofday"
3213 as_fn_append ac_func_list " nanotime"
3214 as_fn_append ac_header_list " sys/time.h"
3215 as_fn_append ac_header_list " wchar.h"
3216 as_fn_append ac_header_list " stdint.h"
3217 as_fn_append ac_header_list " inttypes.h"
3218 as_fn_append ac_func_list " lstat"
3219 as_fn_append ac_func_list " alarm"
3220 as_fn_append ac_header_list " sys/select.h"
3221 as_fn_append ac_func_list " pselect"
3222 as_fn_append ac_func_list " pthread_sigmask"
3223 as_fn_append ac_func_list " readlink"
3224 as_fn_append ac_func_list " strtoimax"
3225 as_fn_append ac_func_list " strtoumax"
3226 as_fn_append ac_func_list " symlink"
3227 as_fn_append ac_header_list " sys/stat.h"
3228 as_fn_append ac_func_list " localtime_r"
3229 as_fn_append ac_header_list " utime.h"
3230 as_fn_append ac_func_list " futimes"
3231 as_fn_append ac_func_list " futimesat"
3232 as_fn_append ac_func_list " futimens"
3233 as_fn_append ac_func_list " utimensat"
3234 as_fn_append ac_func_list " lutimes"
3235 # Check that the precious variables saved in the cache have kept the same
3236 # value.
3237 ac_cache_corrupted=false
3238 for ac_var in $ac_precious_vars; do
3239 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3240 eval ac_new_set=\$ac_env_${ac_var}_set
3241 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3242 eval ac_new_val=\$ac_env_${ac_var}_value
3243 case $ac_old_set,$ac_new_set in
3244 set,)
3245 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3246 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3247 ac_cache_corrupted=: ;;
3248 ,set)
3249 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3250 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3251 ac_cache_corrupted=: ;;
3252 ,);;
3253 *)
3254 if test "x$ac_old_val" != "x$ac_new_val"; then
3255 # differences in whitespace do not lead to failure.
3256 ac_old_val_w=`echo x $ac_old_val`
3257 ac_new_val_w=`echo x $ac_new_val`
3258 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3259 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3260 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3261 ac_cache_corrupted=:
3262 else
3263 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3264 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3265 eval $ac_var=\$ac_old_val
3266 fi
3267 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3268 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3269 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3270 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3271 fi;;
3272 esac
3273 # Pass precious variables to config.status.
3274 if test "$ac_new_set" = set; then
3275 case $ac_new_val in
3276 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3277 *) ac_arg=$ac_var=$ac_new_val ;;
3278 esac
3279 case " $ac_configure_args " in
3280 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3281 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3282 esac
3283 fi
3284 done
3285 if $ac_cache_corrupted; then
3286 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3287 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3288 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3289 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3290 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3291 fi
3292 ## -------------------- ##
3293 ## Main body of script. ##
3294 ## -------------------- ##
3295
3296 ac_ext=c
3297 ac_cpp='$CPP $CPPFLAGS'
3298 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3299 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3300 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3301
3302
3303 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3304
3305
3306 ac_aux_dir=
3307 for ac_dir in build-aux "$srcdir"/build-aux; do
3308 for ac_t in install-sh install.sh shtool; do
3309 if test -f "$ac_dir/$ac_t"; then
3310 ac_aux_dir=$ac_dir
3311 ac_install_sh="$ac_aux_dir/$ac_t -c"
3312 break 2
3313 fi
3314 done
3315 done
3316 if test -z "$ac_aux_dir"; then
3317 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3318 fi
3319
3320 # These three variables are undocumented and unsupported,
3321 # and are intended to be withdrawn in a future Autoconf release.
3322 # They can cause serious problems if a builder's source tree is in a directory
3323 # whose full name contains unusual characters.
3324 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3325 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3326 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3327
3328
3329 am__api_version='1.11'
3330
3331 # Find a good install program. We prefer a C program (faster),
3332 # so one script is as good as another. But avoid the broken or
3333 # incompatible versions:
3334 # SysV /etc/install, /usr/sbin/install
3335 # SunOS /usr/etc/install
3336 # IRIX /sbin/install
3337 # AIX /bin/install
3338 # AmigaOS /C/install, which installs bootblocks on floppy discs
3339 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3340 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3341 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3342 # OS/2's system install, which has a completely different semantic
3343 # ./install, which can be erroneously created by make from ./install.sh.
3344 # Reject install programs that cannot install multiple files.
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3346 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3347 if test -z "$INSTALL"; then
3348 if test "${ac_cv_path_install+set}" = set; then :
3349 $as_echo_n "(cached) " >&6
3350 else
3351 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3352 for as_dir in $PATH
3353 do
3354 IFS=$as_save_IFS
3355 test -z "$as_dir" && as_dir=.
3356 # Account for people who put trailing slashes in PATH elements.
3357 case $as_dir/ in #((
3358 ./ | .// | /[cC]/* | \
3359 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3360 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3361 /usr/ucb/* ) ;;
3362 *)
3363 # OSF1 and SCO ODT 3.0 have their own names for install.
3364 # Don't use installbsd from OSF since it installs stuff as root
3365 # by default.
3366 for ac_prog in ginstall scoinst install; do
3367 for ac_exec_ext in '' $ac_executable_extensions; do
3368 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3369 if test $ac_prog = install &&
3370 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3371 # AIX install. It has an incompatible calling convention.
3372 :
3373 elif test $ac_prog = install &&
3374 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3375 # program-specific install script used by HP pwplus--don't use.
3376 :
3377 else
3378 rm -rf conftest.one conftest.two conftest.dir
3379 echo one > conftest.one
3380 echo two > conftest.two
3381 mkdir conftest.dir
3382 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3383 test -s conftest.one && test -s conftest.two &&
3384 test -s conftest.dir/conftest.one &&
3385 test -s conftest.dir/conftest.two
3386 then
3387 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3388 break 3
3389 fi
3390 fi
3391 fi
3392 done
3393 done
3394 ;;
3395 esac
3396
3397 done
3398 IFS=$as_save_IFS
3399
3400 rm -rf conftest.one conftest.two conftest.dir
3401
3402 fi
3403 if test "${ac_cv_path_install+set}" = set; then
3404 INSTALL=$ac_cv_path_install
3405 else
3406 # As a last resort, use the slow shell script. Don't cache a
3407 # value for INSTALL within a source directory, because that will
3408 # break other packages using the cache if that directory is
3409 # removed, or if the value is a relative name.
3410 INSTALL=$ac_install_sh
3411 fi
3412 fi
3413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3414 $as_echo "$INSTALL" >&6; }
3415
3416 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3417 # It thinks the first close brace ends the variable substitution.
3418 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3419
3420 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3421
3422 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3423
3424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3425 $as_echo_n "checking whether build environment is sane... " >&6; }
3426 # Just in case
3427 sleep 1
3428 echo timestamp > conftest.file
3429 # Reject unsafe characters in $srcdir or the absolute working directory
3430 # name. Accept space and tab only in the latter.
3431 am_lf='
3432 '
3433 case `pwd` in
3434 *[\\\"\#\$\&\'\`$am_lf]*)
3435 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3436 esac
3437 case $srcdir in
3438 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3439 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3440 esac
3441
3442 # Do `set' in a subshell so we don't clobber the current shell's
3443 # arguments. Must try -L first in case configure is actually a
3444 # symlink; some systems play weird games with the mod time of symlinks
3445 # (eg FreeBSD returns the mod time of the symlink's containing
3446 # directory).
3447 if (
3448 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3449 if test "$*" = "X"; then
3450 # -L didn't work.
3451 set X `ls -t "$srcdir/configure" conftest.file`
3452 fi
3453 rm -f conftest.file
3454 if test "$*" != "X $srcdir/configure conftest.file" \
3455 && test "$*" != "X conftest.file $srcdir/configure"; then
3456
3457 # If neither matched, then we have a broken ls. This can happen
3458 # if, for instance, CONFIG_SHELL is bash and it inherits a
3459 # broken ls alias from the environment. This has actually
3460 # happened. Such a system could not be considered "sane".
3461 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3462 alias in your environment" "$LINENO" 5
3463 fi
3464
3465 test "$2" = conftest.file
3466 )
3467 then
3468 # Ok.
3469 :
3470 else
3471 as_fn_error "newly created file is older than distributed files!
3472 Check your system clock" "$LINENO" 5
3473 fi
3474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3475 $as_echo "yes" >&6; }
3476 test "$program_prefix" != NONE &&
3477 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3478 # Use a double $ so make ignores it.
3479 test "$program_suffix" != NONE &&
3480 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3481 # Double any \ or $.
3482 # By default was `s,x,x', remove it if useless.
3483 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3484 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3485
3486 # expand $ac_aux_dir to an absolute path
3487 am_aux_dir=`cd $ac_aux_dir && pwd`
3488
3489 if test x"${MISSING+set}" != xset; then
3490 case $am_aux_dir in
3491 *\ * | *\ *)
3492 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3493 *)
3494 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3495 esac
3496 fi
3497 # Use eval to expand $SHELL
3498 if eval "$MISSING --run true"; then
3499 am_missing_run="$MISSING --run "
3500 else
3501 am_missing_run=
3502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3503 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3504 fi
3505
3506 if test x"${install_sh}" != xset; then
3507 case $am_aux_dir in
3508 *\ * | *\ *)
3509 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3510 *)
3511 install_sh="\${SHELL} $am_aux_dir/install-sh"
3512 esac
3513 fi
3514
3515 # Installed binaries are usually stripped using `strip' when the user
3516 # run `make install-strip'. However `strip' might not be the right
3517 # tool to use in cross-compilation environments, therefore Automake
3518 # will honor the `STRIP' environment variable to overrule this program.
3519 if test "$cross_compiling" != no; then
3520 if test -n "$ac_tool_prefix"; then
3521 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3522 set dummy ${ac_tool_prefix}strip; ac_word=$2
3523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3524 $as_echo_n "checking for $ac_word... " >&6; }
3525 if test "${ac_cv_prog_STRIP+set}" = set; then :
3526 $as_echo_n "(cached) " >&6
3527 else
3528 if test -n "$STRIP"; then
3529 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3530 else
3531 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3532 for as_dir in $PATH
3533 do
3534 IFS=$as_save_IFS
3535 test -z "$as_dir" && as_dir=.
3536 for ac_exec_ext in '' $ac_executable_extensions; do
3537 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3538 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3539 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3540 break 2
3541 fi
3542 done
3543 done
3544 IFS=$as_save_IFS
3545
3546 fi
3547 fi
3548 STRIP=$ac_cv_prog_STRIP
3549 if test -n "$STRIP"; then
3550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3551 $as_echo "$STRIP" >&6; }
3552 else
3553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3554 $as_echo "no" >&6; }
3555 fi
3556
3557
3558 fi
3559 if test -z "$ac_cv_prog_STRIP"; then
3560 ac_ct_STRIP=$STRIP
3561 # Extract the first word of "strip", so it can be a program name with args.
3562 set dummy strip; ac_word=$2
3563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3564 $as_echo_n "checking for $ac_word... " >&6; }
3565 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3566 $as_echo_n "(cached) " >&6
3567 else
3568 if test -n "$ac_ct_STRIP"; then
3569 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3570 else
3571 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3572 for as_dir in $PATH
3573 do
3574 IFS=$as_save_IFS
3575 test -z "$as_dir" && as_dir=.
3576 for ac_exec_ext in '' $ac_executable_extensions; do
3577 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3578 ac_cv_prog_ac_ct_STRIP="strip"
3579 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3580 break 2
3581 fi
3582 done
3583 done
3584 IFS=$as_save_IFS
3585
3586 fi
3587 fi
3588 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3589 if test -n "$ac_ct_STRIP"; then
3590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3591 $as_echo "$ac_ct_STRIP" >&6; }
3592 else
3593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3594 $as_echo "no" >&6; }
3595 fi
3596
3597 if test "x$ac_ct_STRIP" = x; then
3598 STRIP=":"
3599 else
3600 case $cross_compiling:$ac_tool_warned in
3601 yes:)
3602 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3603 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3604 ac_tool_warned=yes ;;
3605 esac
3606 STRIP=$ac_ct_STRIP
3607 fi
3608 else
3609 STRIP="$ac_cv_prog_STRIP"
3610 fi
3611
3612 fi
3613 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3614
3615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3616 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3617 if test -z "$MKDIR_P"; then
3618 if test "${ac_cv_path_mkdir+set}" = set; then :
3619 $as_echo_n "(cached) " >&6
3620 else
3621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3622 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3623 do
3624 IFS=$as_save_IFS
3625 test -z "$as_dir" && as_dir=.
3626 for ac_prog in mkdir gmkdir; do
3627 for ac_exec_ext in '' $ac_executable_extensions; do
3628 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3629 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3630 'mkdir (GNU coreutils) '* | \
3631 'mkdir (coreutils) '* | \
3632 'mkdir (fileutils) '4.1*)
3633 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3634 break 3;;
3635 esac
3636 done
3637 done
3638 done
3639 IFS=$as_save_IFS
3640
3641 fi
3642
3643 test -d ./--version && rmdir ./--version
3644 if test "${ac_cv_path_mkdir+set}" = set; then
3645 MKDIR_P="$ac_cv_path_mkdir -p"
3646 else
3647 # As a last resort, use the slow shell script. Don't cache a
3648 # value for MKDIR_P within a source directory, because that will
3649 # break other packages using the cache if that directory is
3650 # removed, or if the value is a relative name.
3651 MKDIR_P="$ac_install_sh -d"
3652 fi
3653 fi
3654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3655 $as_echo "$MKDIR_P" >&6; }
3656
3657
3658 mkdir_p="$MKDIR_P"
3659 case $mkdir_p in
3660 [\\/$]* | ?:[\\/]*) ;;
3661 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3662 esac
3663
3664 for ac_prog in gawk mawk nawk awk
3665 do
3666 # Extract the first word of "$ac_prog", so it can be a program name with args.
3667 set dummy $ac_prog; ac_word=$2
3668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3669 $as_echo_n "checking for $ac_word... " >&6; }
3670 if test "${ac_cv_prog_AWK+set}" = set; then :
3671 $as_echo_n "(cached) " >&6
3672 else
3673 if test -n "$AWK"; then
3674 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3675 else
3676 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3677 for as_dir in $PATH
3678 do
3679 IFS=$as_save_IFS
3680 test -z "$as_dir" && as_dir=.
3681 for ac_exec_ext in '' $ac_executable_extensions; do
3682 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3683 ac_cv_prog_AWK="$ac_prog"
3684 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3685 break 2
3686 fi
3687 done
3688 done
3689 IFS=$as_save_IFS
3690
3691 fi
3692 fi
3693 AWK=$ac_cv_prog_AWK
3694 if test -n "$AWK"; then
3695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3696 $as_echo "$AWK" >&6; }
3697 else
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3699 $as_echo "no" >&6; }
3700 fi
3701
3702
3703 test -n "$AWK" && break
3704 done
3705
3706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3707 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3708 set x ${MAKE-make}
3709 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3710 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3711 $as_echo_n "(cached) " >&6
3712 else
3713 cat >conftest.make <<\_ACEOF
3714 SHELL = /bin/sh
3715 all:
3716 @echo '@@@%%%=$(MAKE)=@@@%%%'
3717 _ACEOF
3718 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3719 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3720 *@@@%%%=?*=@@@%%%*)
3721 eval ac_cv_prog_make_${ac_make}_set=yes;;
3722 *)
3723 eval ac_cv_prog_make_${ac_make}_set=no;;
3724 esac
3725 rm -f conftest.make
3726 fi
3727 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3729 $as_echo "yes" >&6; }
3730 SET_MAKE=
3731 else
3732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3733 $as_echo "no" >&6; }
3734 SET_MAKE="MAKE=${MAKE-make}"
3735 fi
3736
3737 rm -rf .tst 2>/dev/null
3738 mkdir .tst 2>/dev/null
3739 if test -d .tst; then
3740 am__leading_dot=.
3741 else
3742 am__leading_dot=_
3743 fi
3744 rmdir .tst 2>/dev/null
3745
3746 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3747 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3748 # is not polluted with repeated "-I."
3749 am__isrc=' -I$(srcdir)'
3750 # test to see if srcdir already configured
3751 if test -f $srcdir/config.status; then
3752 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3753 fi
3754 fi
3755
3756 # test whether we have cygpath
3757 if test -z "$CYGPATH_W"; then
3758 if (cygpath --version) >/dev/null 2>/dev/null; then
3759 CYGPATH_W='cygpath -w'
3760 else
3761 CYGPATH_W=echo
3762 fi
3763 fi
3764
3765
3766 # Define the identity of the package.
3767 PACKAGE='emacs'
3768 VERSION='24.3.50'
3769
3770
3771 cat >>confdefs.h <<_ACEOF
3772 #define PACKAGE "$PACKAGE"
3773 _ACEOF
3774
3775
3776 cat >>confdefs.h <<_ACEOF
3777 #define VERSION "$VERSION"
3778 _ACEOF
3779
3780 # Some tools Automake needs.
3781
3782 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3783
3784
3785 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3786
3787
3788 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3789
3790
3791 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3792
3793
3794 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3795
3796 # We need awk for the "check" target. The system "awk" is bad on
3797 # some platforms.
3798 # Always define AMTAR for backward compatibility.
3799
3800 AMTAR=${AMTAR-"${am_missing_run}tar"}
3801
3802 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3803
3804
3805
3806
3807
3808
3809
3810
3811 lispdir='${datadir}/emacs/${version}/lisp'
3812 leimdir='${datadir}/emacs/${version}/leim'
3813 standardlisppath='${lispdir}:${leimdir}'
3814 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3815 '${datadir}/emacs/site-lisp'
3816 lisppath='${locallisppath}:${standardlisppath}'
3817 etcdir='${datadir}/emacs/${version}/etc'
3818 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3819 docdir='${datadir}/emacs/${version}/etc'
3820 gamedir='${localstatedir}/games/emacs'
3821
3822
3823 # Check whether --with-all was given.
3824 if test "${with_all+set}" = set; then :
3825 withval=$with_all; with_features=$withval
3826 else
3827 with_features=yes
3828 fi
3829
3830
3831
3832
3833
3834 # Check whether --with-pop was given.
3835 if test "${with_pop+set}" = set; then :
3836 withval=$with_pop;
3837 else
3838 with_pop=$with_features
3839 fi
3840
3841 if test "$with_pop" = yes; then
3842 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3843
3844 fi
3845
3846
3847 # Check whether --with-kerberos was given.
3848 if test "${with_kerberos+set}" = set; then :
3849 withval=$with_kerberos;
3850 else
3851 with_kerberos=no
3852 fi
3853
3854 if test "$with_kerberos" != no; then
3855 $as_echo "#define KERBEROS 1" >>confdefs.h
3856
3857 fi
3858
3859
3860 # Check whether --with-kerberos5 was given.
3861 if test "${with_kerberos5+set}" = set; then :
3862 withval=$with_kerberos5;
3863 else
3864 with_kerberos5=no
3865 fi
3866
3867 if test "${with_kerberos5}" != no; then
3868 if test "${with_kerberos}" = no; then
3869 with_kerberos=yes
3870 $as_echo "#define KERBEROS 1" >>confdefs.h
3871
3872 fi
3873
3874 $as_echo "#define KERBEROS5 1" >>confdefs.h
3875
3876 fi
3877
3878
3879 # Check whether --with-hesiod was given.
3880 if test "${with_hesiod+set}" = set; then :
3881 withval=$with_hesiod;
3882 else
3883 with_hesiod=no
3884 fi
3885
3886 if test "$with_hesiod" != no; then
3887
3888 $as_echo "#define HESIOD 1" >>confdefs.h
3889
3890 fi
3891
3892
3893 # Check whether --with-mmdf was given.
3894 if test "${with_mmdf+set}" = set; then :
3895 withval=$with_mmdf;
3896 else
3897 with_mmdf=no
3898 fi
3899
3900 if test "$with_mmdf" != no; then
3901
3902 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3903
3904 fi
3905
3906
3907 # Check whether --with-mail-unlink was given.
3908 if test "${with_mail_unlink+set}" = set; then :
3909 withval=$with_mail_unlink;
3910 else
3911 with_mail_unlink=no
3912 fi
3913
3914 if test "$with_mail_unlink" != no; then
3915
3916 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3917
3918 fi
3919
3920
3921 # Check whether --with-mailhost was given.
3922 if test "${with_mailhost+set}" = set; then :
3923 withval=$with_mailhost;
3924 cat >>confdefs.h <<_ACEOF
3925 #define MAILHOST "$withval"
3926 _ACEOF
3927
3928 fi
3929
3930
3931
3932 # Check whether --with-sound was given.
3933 if test "${with_sound+set}" = set; then :
3934 withval=$with_sound;
3935 else
3936 with_sound=$with_features
3937 fi
3938
3939
3940
3941 # Check whether --with-x-toolkit was given.
3942 if test "${with_x_toolkit+set}" = set; then :
3943 withval=$with_x_toolkit; case "${withval}" in
3944 y | ye | yes ) val=gtk ;;
3945 n | no ) val=no ;;
3946 l | lu | luc | luci | lucid ) val=lucid ;;
3947 a | at | ath | athe | athen | athena ) val=athena ;;
3948 m | mo | mot | moti | motif ) val=motif ;;
3949 g | gt | gtk ) val=gtk ;;
3950 gtk2 ) val=gtk2 ;;
3951 gtk3 ) val=gtk3 ;;
3952 * )
3953 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3954 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
3955 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
3956 \`athena' and \`lucid' are synonyms." "$LINENO" 5
3957 ;;
3958 esac
3959 with_x_toolkit=$val
3960
3961 fi
3962
3963
3964
3965 # Check whether --with-wide-int was given.
3966 if test "${with_wide_int+set}" = set; then :
3967 withval=$with_wide_int;
3968 else
3969 with_wide_int=no
3970 fi
3971
3972 if test "$with_wide_int" = yes; then
3973
3974 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3975
3976 fi
3977
3978
3979 # Check whether --with-xpm was given.
3980 if test "${with_xpm+set}" = set; then :
3981 withval=$with_xpm;
3982 else
3983 with_xpm=$with_features
3984 fi
3985
3986
3987 # Check whether --with-jpeg was given.
3988 if test "${with_jpeg+set}" = set; then :
3989 withval=$with_jpeg;
3990 else
3991 with_jpeg=$with_features
3992 fi
3993
3994
3995 # Check whether --with-tiff was given.
3996 if test "${with_tiff+set}" = set; then :
3997 withval=$with_tiff;
3998 else
3999 with_tiff=$with_features
4000 fi
4001
4002
4003 # Check whether --with-gif was given.
4004 if test "${with_gif+set}" = set; then :
4005 withval=$with_gif;
4006 else
4007 with_gif=$with_features
4008 fi
4009
4010
4011 # Check whether --with-png was given.
4012 if test "${with_png+set}" = set; then :
4013 withval=$with_png;
4014 else
4015 with_png=$with_features
4016 fi
4017
4018
4019 # Check whether --with-rsvg was given.
4020 if test "${with_rsvg+set}" = set; then :
4021 withval=$with_rsvg;
4022 else
4023 with_rsvg=$with_features
4024 fi
4025
4026
4027 # Check whether --with-xml2 was given.
4028 if test "${with_xml2+set}" = set; then :
4029 withval=$with_xml2;
4030 else
4031 with_xml2=$with_features
4032 fi
4033
4034
4035 # Check whether --with-imagemagick was given.
4036 if test "${with_imagemagick+set}" = set; then :
4037 withval=$with_imagemagick;
4038 else
4039 with_imagemagick=$with_features
4040 fi
4041
4042
4043
4044 # Check whether --with-xft was given.
4045 if test "${with_xft+set}" = set; then :
4046 withval=$with_xft;
4047 else
4048 with_xft=$with_features
4049 fi
4050
4051
4052 # Check whether --with-libotf was given.
4053 if test "${with_libotf+set}" = set; then :
4054 withval=$with_libotf;
4055 else
4056 with_libotf=$with_features
4057 fi
4058
4059
4060 # Check whether --with-m17n-flt was given.
4061 if test "${with_m17n_flt+set}" = set; then :
4062 withval=$with_m17n_flt;
4063 else
4064 with_m17n_flt=$with_features
4065 fi
4066
4067
4068
4069 # Check whether --with-toolkit-scroll-bars was given.
4070 if test "${with_toolkit_scroll_bars+set}" = set; then :
4071 withval=$with_toolkit_scroll_bars;
4072 else
4073 with_toolkit_scroll_bars=$with_features
4074 fi
4075
4076
4077 # Check whether --with-xaw3d was given.
4078 if test "${with_xaw3d+set}" = set; then :
4079 withval=$with_xaw3d;
4080 else
4081 with_xaw3d=$with_features
4082 fi
4083
4084
4085 # Check whether --with-xim was given.
4086 if test "${with_xim+set}" = set; then :
4087 withval=$with_xim;
4088 else
4089 with_xim=$with_features
4090 fi
4091
4092
4093 # Check whether --with-ns was given.
4094 if test "${with_ns+set}" = set; then :
4095 withval=$with_ns;
4096 else
4097 with_ns=no
4098 fi
4099
4100
4101 # Check whether --with-w32 was given.
4102 if test "${with_w32+set}" = set; then :
4103 withval=$with_w32;
4104 else
4105 with_w32=no
4106 fi
4107
4108
4109
4110 # Check whether --with-gpm was given.
4111 if test "${with_gpm+set}" = set; then :
4112 withval=$with_gpm;
4113 else
4114 with_gpm=$with_features
4115 fi
4116
4117
4118 # Check whether --with-dbus was given.
4119 if test "${with_dbus+set}" = set; then :
4120 withval=$with_dbus;
4121 else
4122 with_dbus=$with_features
4123 fi
4124
4125
4126 # Check whether --with-gconf was given.
4127 if test "${with_gconf+set}" = set; then :
4128 withval=$with_gconf;
4129 else
4130 with_gconf=$with_features
4131 fi
4132
4133
4134 # Check whether --with-gsettings was given.
4135 if test "${with_gsettings+set}" = set; then :
4136 withval=$with_gsettings;
4137 else
4138 with_gsettings=$with_features
4139 fi
4140
4141
4142 # Check whether --with-selinux was given.
4143 if test "${with_selinux+set}" = set; then :
4144 withval=$with_selinux;
4145 else
4146 with_selinux=$with_features
4147 fi
4148
4149
4150 # Check whether --with-gnutls was given.
4151 if test "${with_gnutls+set}" = set; then :
4152 withval=$with_gnutls;
4153 else
4154 with_gnutls=$with_features
4155 fi
4156
4157
4158 ## For the times when you want to build Emacs but don't have
4159 ## a suitable makeinfo, and can live without the manuals.
4160
4161 # Check whether --with-makeinfo was given.
4162 if test "${with_makeinfo+set}" = set; then :
4163 withval=$with_makeinfo;
4164 else
4165 with_makeinfo=$with_features
4166 fi
4167
4168
4169 ## Makefile.in needs the cache file name.
4170
4171
4172 ## This is an option because I do not know if all info/man support
4173 ## compressed files, nor how to test if they do so.
4174
4175 # Check whether --with-compress-info was given.
4176 if test "${with_compress_info+set}" = set; then :
4177 withval=$with_compress_info;
4178 else
4179 with_compress_info=$with_features
4180 fi
4181
4182 if test $with_compress_info = yes; then
4183 GZIP_INFO=yes
4184 else
4185 GZIP_INFO=
4186 fi
4187
4188
4189
4190 # Check whether --with-pkg-config-prog was given.
4191 if test "${with_pkg_config_prog+set}" = set; then :
4192 withval=$with_pkg_config_prog;
4193 fi
4194
4195 if test "X${with_pkg_config_prog}" != X; then
4196 if test "${with_pkg_config_prog}" != yes; then
4197 PKG_CONFIG="${with_pkg_config_prog}"
4198 fi
4199 fi
4200
4201 CRT_DIR=
4202
4203 # Check whether --with-crt-dir was given.
4204 if test "${with_crt_dir+set}" = set; then :
4205 withval=$with_crt_dir;
4206 fi
4207
4208 CRT_DIR="${with_crt_dir}"
4209
4210
4211 # Check whether --with-gameuser was given.
4212 if test "${with_gameuser+set}" = set; then :
4213 withval=$with_gameuser;
4214 fi
4215
4216 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4217 && gameuser="${with_gameuser}"
4218 test "X$gameuser" = X && gameuser=games
4219
4220
4221 # Check whether --with-gnustep-conf was given.
4222 if test "${with_gnustep_conf+set}" = set; then :
4223 withval=$with_gnustep_conf;
4224 fi
4225
4226 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4227 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4228 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4229 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4230
4231 # Check whether --enable-ns-self-contained was given.
4232 if test "${enable_ns_self_contained+set}" = set; then :
4233 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4234 else
4235 EN_NS_SELF_CONTAINED=yes
4236 fi
4237
4238
4239 # Check whether --enable-locallisppath was given.
4240 if test "${enable_locallisppath+set}" = set; then :
4241 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4242 locallisppath=
4243 elif test "${enableval}" != "yes"; then
4244 locallisppath=${enableval}
4245 fi
4246 fi
4247
4248
4249 # Check whether --enable-checking was given.
4250 if test "${enable_checking+set}" = set; then :
4251 enableval=$enable_checking; ac_checking_flags="${enableval}"
4252 fi
4253
4254 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4255 for check in $ac_checking_flags
4256 do
4257 case $check in
4258 # these set all the flags to specific states
4259 yes) ac_enable_checking=1 ;;
4260 no) ac_enable_checking= ;
4261 ac_gc_check_stringbytes= ;
4262 ac_gc_check_string_overrun= ;
4263 ac_gc_check_string_free_list= ;
4264 ac_xmalloc_overrun= ;
4265 ac_gc_check_cons_list= ;
4266 ac_glyphs_debug= ;;
4267 all) ac_enable_checking=1 ;
4268 ac_gc_check_stringbytes=1 ;
4269 ac_gc_check_string_overrun=1 ;
4270 ac_gc_check_string_free_list=1 ;
4271 ac_xmalloc_overrun=1 ;
4272 ac_gc_check_cons_list=1 ;
4273 ac_glyphs_debug=1 ;;
4274 # these enable particular checks
4275 stringbytes) ac_gc_check_stringbytes=1 ;;
4276 stringoverrun) ac_gc_check_string_overrun=1 ;;
4277 stringfreelist) ac_gc_check_string_free_list=1 ;;
4278 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4279 conslist) ac_gc_check_cons_list=1 ;;
4280 glyphs) ac_glyphs_debug=1 ;;
4281 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4282 esac
4283 done
4284 IFS="$ac_save_IFS"
4285
4286 if test x$ac_enable_checking != x ; then
4287
4288 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4289
4290 fi
4291 if test x$ac_gc_check_stringbytes != x ; then
4292
4293 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4294
4295 fi
4296 if test x$ac_gc_check_string_overrun != x ; then
4297
4298 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4299
4300 fi
4301 if test x$ac_gc_check_string_free_list != x ; then
4302
4303 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4304
4305 fi
4306 if test x$ac_xmalloc_overrun != x ; then
4307
4308 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4309
4310 fi
4311 if test x$ac_gc_check_cons_list != x ; then
4312
4313 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4314
4315 fi
4316 if test x$ac_glyphs_debug != x ; then
4317
4318 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4319
4320 fi
4321
4322 # Check whether --enable-check-lisp-object-type was given.
4323 if test "${enable_check_lisp_object_type+set}" = set; then :
4324 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4325
4326 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4327
4328 fi
4329 fi
4330
4331
4332
4333 # Check whether --enable-profiling was given.
4334 if test "${enable_profiling+set}" = set; then :
4335 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4336 fi
4337
4338 if test x$ac_enable_profiling != x ; then
4339 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4340 else
4341 PROFILING_CFLAGS=
4342 fi
4343
4344
4345 # Check whether --enable-autodepend was given.
4346 if test "${enable_autodepend+set}" = set; then :
4347 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4348 else
4349 ac_enable_autodepend=yes
4350 fi
4351
4352
4353 #### Make srcdir absolute, if it isn't already. It's important to
4354 #### avoid running the path through pwd unnecessarily, since pwd can
4355 #### give you automounter prefixes, which can go away. We do all this
4356 #### so Emacs can find its files when run uninstalled.
4357 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4358 unset CDPATH
4359 case "${srcdir}" in
4360 /* ) ;;
4361 . )
4362 ## We may be able to use the $PWD environment variable to make this
4363 ## absolute. But sometimes PWD is inaccurate.
4364 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4365 ## but that tested only for a well-formed and valid PWD,
4366 ## it did not object when PWD was well-formed and valid but just wrong.
4367 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4368 then
4369 srcdir="$PWD"
4370 else
4371 srcdir="`(cd ${srcdir}; pwd)`"
4372 fi
4373 ;;
4374 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4375 esac
4376
4377 ### Canonicalize the configuration name.
4378
4379 # Make sure we can run config.sub.
4380 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4381 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4382
4383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4384 $as_echo_n "checking build system type... " >&6; }
4385 if test "${ac_cv_build+set}" = set; then :
4386 $as_echo_n "(cached) " >&6
4387 else
4388 ac_build_alias=$build_alias
4389 test "x$ac_build_alias" = x &&
4390 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4391 test "x$ac_build_alias" = x &&
4392 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4393 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4394 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4395
4396 fi
4397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4398 $as_echo "$ac_cv_build" >&6; }
4399 case $ac_cv_build in
4400 *-*-*) ;;
4401 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4402 esac
4403 build=$ac_cv_build
4404 ac_save_IFS=$IFS; IFS='-'
4405 set x $ac_cv_build
4406 shift
4407 build_cpu=$1
4408 build_vendor=$2
4409 shift; shift
4410 # Remember, the first character of IFS is used to create $*,
4411 # except with old shells:
4412 build_os=$*
4413 IFS=$ac_save_IFS
4414 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4415
4416
4417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4418 $as_echo_n "checking host system type... " >&6; }
4419 if test "${ac_cv_host+set}" = set; then :
4420 $as_echo_n "(cached) " >&6
4421 else
4422 if test "x$host_alias" = x; then
4423 ac_cv_host=$ac_cv_build
4424 else
4425 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4426 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4427 fi
4428
4429 fi
4430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4431 $as_echo "$ac_cv_host" >&6; }
4432 case $ac_cv_host in
4433 *-*-*) ;;
4434 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4435 esac
4436 host=$ac_cv_host
4437 ac_save_IFS=$IFS; IFS='-'
4438 set x $ac_cv_host
4439 shift
4440 host_cpu=$1
4441 host_vendor=$2
4442 shift; shift
4443 # Remember, the first character of IFS is used to create $*,
4444 # except with old shells:
4445 host_os=$*
4446 IFS=$ac_save_IFS
4447 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4448
4449
4450 canonical=$host
4451 configuration=${host_alias-${build_alias-$host}}
4452
4453
4454
4455 ### If you add support for a new configuration, add code to this
4456 ### switch statement to recognize your configuration name and select
4457 ### the appropriate operating system file.
4458
4459 ### You would hope that you could choose an s/*.h
4460 ### file based on the operating system portion. However, it turns out
4461 ### that each s/*.h file is pretty manufacturer-specific.
4462 ### So we basically have to have a special case for each
4463 ### configuration name.
4464 ###
4465 ### As far as handling version numbers on operating systems is
4466 ### concerned, make sure things will fail in a fixable way. If
4467 ### /etc/MACHINES doesn't say anything about version numbers, be
4468 ### prepared to handle anything reasonably. If version numbers
4469 ### matter, be sure /etc/MACHINES says something about it.
4470
4471 opsys='' unported=no
4472 case "${canonical}" in
4473
4474 ## GNU/Linux and similar ports
4475 *-*-linux* )
4476 opsys=gnu-linux
4477 ;;
4478
4479 ## FreeBSD ports
4480 *-*-freebsd* )
4481 opsys=freebsd
4482 ;;
4483
4484 ## FreeBSD kernel + glibc based userland
4485 *-*-kfreebsd*gnu* )
4486 opsys=gnu-kfreebsd
4487 ;;
4488
4489 ## NetBSD ports
4490 *-*-netbsd* )
4491 opsys=netbsd
4492 ;;
4493
4494 ## OpenBSD ports
4495 *-*-openbsd* )
4496 opsys=openbsd
4497 ;;
4498
4499 ## Apple Darwin / Mac OS X
4500 *-apple-darwin* )
4501 case "${canonical}" in
4502 i[3456]86-* ) ;;
4503 powerpc-* ) ;;
4504 x86_64-* ) ;;
4505 * ) unported=yes ;;
4506 esac
4507 opsys=darwin
4508 ## Use fink packages if available.
4509 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4510 ## if test -d /sw/include && test -d /sw/lib; then
4511 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4512 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4513 ## fi
4514 ;;
4515
4516 ## HP 9000 series 700 and 800, running HP/UX
4517 hppa*-hp-hpux10.2* )
4518 opsys=hpux10-20
4519 ;;
4520 hppa*-hp-hpux1[1-9]* )
4521 opsys=hpux11
4522 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4523 ;;
4524
4525 ## IBM machines
4526 rs6000-ibm-aix4.[23]* )
4527 opsys=aix4-2
4528 ;;
4529 powerpc-ibm-aix4.[23]* )
4530 opsys=aix4-2
4531 ;;
4532 rs6000-ibm-aix[56]* )
4533 opsys=aix4-2
4534 ;;
4535 powerpc-ibm-aix[56]* )
4536 opsys=aix4-2
4537 ;;
4538
4539 ## Silicon Graphics machines
4540 ## Iris 4D
4541 mips-sgi-irix6.5 )
4542 opsys=irix6-5
4543 # Without defining _LANGUAGE_C, things get masked out in the headers
4544 # so that, for instance, grepping for `free' in stdlib.h fails and
4545 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4546 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4547 ;;
4548
4549 ## Suns
4550 *-sun-solaris* \
4551 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4552 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4553 case "${canonical}" in
4554 i[3456]86-*-* ) ;;
4555 amd64-*-*|x86_64-*-*) ;;
4556 sparc* ) ;;
4557 * ) unported=yes ;;
4558 esac
4559 case "${canonical}" in
4560 *-sunos5.6* | *-solaris2.6* )
4561 opsys=sol2-6
4562 RANLIB="ar -ts"
4563 ;;
4564 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4565 opsys=sol2-6
4566 emacs_check_sunpro_c=yes
4567 ;;
4568 *-sunos5* | *-solaris* )
4569 opsys=sol2-10
4570 emacs_check_sunpro_c=yes
4571 ;;
4572 esac
4573 ## Watch out for a compiler that we know will not work.
4574 case "${canonical}" in
4575 *-solaris* | *-sunos5* )
4576 if [ "x$CC" = x/usr/ucb/cc ]; then
4577 ## /usr/ucb/cc doesn't work;
4578 ## we should find some other compiler that does work.
4579 unset CC
4580 fi
4581 ;;
4582 *) ;;
4583 esac
4584 ;;
4585
4586 ## Intel 386 machines where we don't care about the manufacturer.
4587 i[3456]86-*-* )
4588 case "${canonical}" in
4589 *-cygwin ) opsys=cygwin ;;
4590 *-darwin* ) opsys=darwin ;;
4591 *-sysv4.2uw* ) opsys=unixware ;;
4592 *-sysv5uw* ) opsys=unixware ;;
4593 *-sysv5OpenUNIX* ) opsys=unixware ;;
4594 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4595 esac
4596 ;;
4597
4598 * )
4599 unported=yes
4600 ;;
4601 esac
4602
4603 ### If the code above didn't choose an operating system, just choose
4604 ### an operating system based on the configuration name. You really
4605 ### only want to use this when you have no idea what the right
4606 ### operating system is; if you know what operating systems a machine
4607 ### runs, it's cleaner to make it explicit in the case statement
4608 ### above.
4609 if test x"${opsys}" = x; then
4610 case "${canonical}" in
4611 *-gnu* ) opsys=gnu ;;
4612 * )
4613 unported=yes
4614 ;;
4615 esac
4616 fi
4617
4618
4619
4620 if test $unported = yes; then
4621 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4622 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4623 fi
4624
4625
4626 #### Choose a compiler.
4627
4628 ac_ext=c
4629 ac_cpp='$CPP $CPPFLAGS'
4630 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4631 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4632 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4633 if test -n "$ac_tool_prefix"; then
4634 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4635 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4637 $as_echo_n "checking for $ac_word... " >&6; }
4638 if test "${ac_cv_prog_CC+set}" = set; then :
4639 $as_echo_n "(cached) " >&6
4640 else
4641 if test -n "$CC"; then
4642 ac_cv_prog_CC="$CC" # Let the user override the test.
4643 else
4644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4645 for as_dir in $PATH
4646 do
4647 IFS=$as_save_IFS
4648 test -z "$as_dir" && as_dir=.
4649 for ac_exec_ext in '' $ac_executable_extensions; do
4650 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4651 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4653 break 2
4654 fi
4655 done
4656 done
4657 IFS=$as_save_IFS
4658
4659 fi
4660 fi
4661 CC=$ac_cv_prog_CC
4662 if test -n "$CC"; then
4663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4664 $as_echo "$CC" >&6; }
4665 else
4666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4667 $as_echo "no" >&6; }
4668 fi
4669
4670
4671 fi
4672 if test -z "$ac_cv_prog_CC"; then
4673 ac_ct_CC=$CC
4674 # Extract the first word of "gcc", so it can be a program name with args.
4675 set dummy gcc; ac_word=$2
4676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4677 $as_echo_n "checking for $ac_word... " >&6; }
4678 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4679 $as_echo_n "(cached) " >&6
4680 else
4681 if test -n "$ac_ct_CC"; then
4682 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4683 else
4684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4685 for as_dir in $PATH
4686 do
4687 IFS=$as_save_IFS
4688 test -z "$as_dir" && as_dir=.
4689 for ac_exec_ext in '' $ac_executable_extensions; do
4690 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4691 ac_cv_prog_ac_ct_CC="gcc"
4692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4693 break 2
4694 fi
4695 done
4696 done
4697 IFS=$as_save_IFS
4698
4699 fi
4700 fi
4701 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4702 if test -n "$ac_ct_CC"; then
4703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4704 $as_echo "$ac_ct_CC" >&6; }
4705 else
4706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4707 $as_echo "no" >&6; }
4708 fi
4709
4710 if test "x$ac_ct_CC" = x; then
4711 CC=""
4712 else
4713 case $cross_compiling:$ac_tool_warned in
4714 yes:)
4715 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4716 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4717 ac_tool_warned=yes ;;
4718 esac
4719 CC=$ac_ct_CC
4720 fi
4721 else
4722 CC="$ac_cv_prog_CC"
4723 fi
4724
4725 if test -z "$CC"; then
4726 if test -n "$ac_tool_prefix"; then
4727 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4728 set dummy ${ac_tool_prefix}cc; ac_word=$2
4729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4730 $as_echo_n "checking for $ac_word... " >&6; }
4731 if test "${ac_cv_prog_CC+set}" = set; then :
4732 $as_echo_n "(cached) " >&6
4733 else
4734 if test -n "$CC"; then
4735 ac_cv_prog_CC="$CC" # Let the user override the test.
4736 else
4737 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4738 for as_dir in $PATH
4739 do
4740 IFS=$as_save_IFS
4741 test -z "$as_dir" && as_dir=.
4742 for ac_exec_ext in '' $ac_executable_extensions; do
4743 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4744 ac_cv_prog_CC="${ac_tool_prefix}cc"
4745 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4746 break 2
4747 fi
4748 done
4749 done
4750 IFS=$as_save_IFS
4751
4752 fi
4753 fi
4754 CC=$ac_cv_prog_CC
4755 if test -n "$CC"; then
4756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4757 $as_echo "$CC" >&6; }
4758 else
4759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4760 $as_echo "no" >&6; }
4761 fi
4762
4763
4764 fi
4765 fi
4766 if test -z "$CC"; then
4767 # Extract the first word of "cc", so it can be a program name with args.
4768 set dummy cc; ac_word=$2
4769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4770 $as_echo_n "checking for $ac_word... " >&6; }
4771 if test "${ac_cv_prog_CC+set}" = set; then :
4772 $as_echo_n "(cached) " >&6
4773 else
4774 if test -n "$CC"; then
4775 ac_cv_prog_CC="$CC" # Let the user override the test.
4776 else
4777 ac_prog_rejected=no
4778 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4779 for as_dir in $PATH
4780 do
4781 IFS=$as_save_IFS
4782 test -z "$as_dir" && as_dir=.
4783 for ac_exec_ext in '' $ac_executable_extensions; do
4784 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4785 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4786 ac_prog_rejected=yes
4787 continue
4788 fi
4789 ac_cv_prog_CC="cc"
4790 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4791 break 2
4792 fi
4793 done
4794 done
4795 IFS=$as_save_IFS
4796
4797 if test $ac_prog_rejected = yes; then
4798 # We found a bogon in the path, so make sure we never use it.
4799 set dummy $ac_cv_prog_CC
4800 shift
4801 if test $# != 0; then
4802 # We chose a different compiler from the bogus one.
4803 # However, it has the same basename, so the bogon will be chosen
4804 # first if we set CC to just the basename; use the full file name.
4805 shift
4806 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4807 fi
4808 fi
4809 fi
4810 fi
4811 CC=$ac_cv_prog_CC
4812 if test -n "$CC"; then
4813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4814 $as_echo "$CC" >&6; }
4815 else
4816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4817 $as_echo "no" >&6; }
4818 fi
4819
4820
4821 fi
4822 if test -z "$CC"; then
4823 if test -n "$ac_tool_prefix"; then
4824 for ac_prog in cl.exe
4825 do
4826 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4827 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4829 $as_echo_n "checking for $ac_word... " >&6; }
4830 if test "${ac_cv_prog_CC+set}" = set; then :
4831 $as_echo_n "(cached) " >&6
4832 else
4833 if test -n "$CC"; then
4834 ac_cv_prog_CC="$CC" # Let the user override the test.
4835 else
4836 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4837 for as_dir in $PATH
4838 do
4839 IFS=$as_save_IFS
4840 test -z "$as_dir" && as_dir=.
4841 for ac_exec_ext in '' $ac_executable_extensions; do
4842 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4843 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4844 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4845 break 2
4846 fi
4847 done
4848 done
4849 IFS=$as_save_IFS
4850
4851 fi
4852 fi
4853 CC=$ac_cv_prog_CC
4854 if test -n "$CC"; then
4855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4856 $as_echo "$CC" >&6; }
4857 else
4858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4859 $as_echo "no" >&6; }
4860 fi
4861
4862
4863 test -n "$CC" && break
4864 done
4865 fi
4866 if test -z "$CC"; then
4867 ac_ct_CC=$CC
4868 for ac_prog in cl.exe
4869 do
4870 # Extract the first word of "$ac_prog", so it can be a program name with args.
4871 set dummy $ac_prog; ac_word=$2
4872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4873 $as_echo_n "checking for $ac_word... " >&6; }
4874 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4875 $as_echo_n "(cached) " >&6
4876 else
4877 if test -n "$ac_ct_CC"; then
4878 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4879 else
4880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4881 for as_dir in $PATH
4882 do
4883 IFS=$as_save_IFS
4884 test -z "$as_dir" && as_dir=.
4885 for ac_exec_ext in '' $ac_executable_extensions; do
4886 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4887 ac_cv_prog_ac_ct_CC="$ac_prog"
4888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4889 break 2
4890 fi
4891 done
4892 done
4893 IFS=$as_save_IFS
4894
4895 fi
4896 fi
4897 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4898 if test -n "$ac_ct_CC"; then
4899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4900 $as_echo "$ac_ct_CC" >&6; }
4901 else
4902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4903 $as_echo "no" >&6; }
4904 fi
4905
4906
4907 test -n "$ac_ct_CC" && break
4908 done
4909
4910 if test "x$ac_ct_CC" = x; then
4911 CC=""
4912 else
4913 case $cross_compiling:$ac_tool_warned in
4914 yes:)
4915 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4916 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4917 ac_tool_warned=yes ;;
4918 esac
4919 CC=$ac_ct_CC
4920 fi
4921 fi
4922
4923 fi
4924
4925
4926 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4927 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4928 as_fn_error "no acceptable C compiler found in \$PATH
4929 See \`config.log' for more details." "$LINENO" 5; }
4930
4931 # Provide some information about the compiler.
4932 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4933 set X $ac_compile
4934 ac_compiler=$2
4935 for ac_option in --version -v -V -qversion; do
4936 { { ac_try="$ac_compiler $ac_option >&5"
4937 case "(($ac_try" in
4938 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4939 *) ac_try_echo=$ac_try;;
4940 esac
4941 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4942 $as_echo "$ac_try_echo"; } >&5
4943 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4944 ac_status=$?
4945 if test -s conftest.err; then
4946 sed '10a\
4947 ... rest of stderr output deleted ...
4948 10q' conftest.err >conftest.er1
4949 cat conftest.er1 >&5
4950 fi
4951 rm -f conftest.er1 conftest.err
4952 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4953 test $ac_status = 0; }
4954 done
4955
4956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4957 /* end confdefs.h. */
4958
4959 int
4960 main ()
4961 {
4962
4963 ;
4964 return 0;
4965 }
4966 _ACEOF
4967 ac_clean_files_save=$ac_clean_files
4968 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4969 # Try to create an executable without -o first, disregard a.out.
4970 # It will help us diagnose broken compilers, and finding out an intuition
4971 # of exeext.
4972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4973 $as_echo_n "checking whether the C compiler works... " >&6; }
4974 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4975
4976 # The possible output files:
4977 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4978
4979 ac_rmfiles=
4980 for ac_file in $ac_files
4981 do
4982 case $ac_file in
4983 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4984 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4985 esac
4986 done
4987 rm -f $ac_rmfiles
4988
4989 if { { ac_try="$ac_link_default"
4990 case "(($ac_try" in
4991 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4992 *) ac_try_echo=$ac_try;;
4993 esac
4994 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4995 $as_echo "$ac_try_echo"; } >&5
4996 (eval "$ac_link_default") 2>&5
4997 ac_status=$?
4998 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4999 test $ac_status = 0; }; then :
5000 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5001 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5002 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5003 # so that the user can short-circuit this test for compilers unknown to
5004 # Autoconf.
5005 for ac_file in $ac_files ''
5006 do
5007 test -f "$ac_file" || continue
5008 case $ac_file in
5009 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5010 ;;
5011 [ab].out )
5012 # We found the default executable, but exeext='' is most
5013 # certainly right.
5014 break;;
5015 *.* )
5016 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5017 then :; else
5018 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5019 fi
5020 # We set ac_cv_exeext here because the later test for it is not
5021 # safe: cross compilers may not add the suffix if given an `-o'
5022 # argument, so we may need to know it at that point already.
5023 # Even if this section looks crufty: it has the advantage of
5024 # actually working.
5025 break;;
5026 * )
5027 break;;
5028 esac
5029 done
5030 test "$ac_cv_exeext" = no && ac_cv_exeext=
5031
5032 else
5033 ac_file=''
5034 fi
5035 if test -z "$ac_file"; then :
5036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5037 $as_echo "no" >&6; }
5038 $as_echo "$as_me: failed program was:" >&5
5039 sed 's/^/| /' conftest.$ac_ext >&5
5040
5041 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5042 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5043 { as_fn_set_status 77
5044 as_fn_error "C compiler cannot create executables
5045 See \`config.log' for more details." "$LINENO" 5; }; }
5046 else
5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5048 $as_echo "yes" >&6; }
5049 fi
5050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5051 $as_echo_n "checking for C compiler default output file name... " >&6; }
5052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5053 $as_echo "$ac_file" >&6; }
5054 ac_exeext=$ac_cv_exeext
5055
5056 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5057 ac_clean_files=$ac_clean_files_save
5058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5059 $as_echo_n "checking for suffix of executables... " >&6; }
5060 if { { ac_try="$ac_link"
5061 case "(($ac_try" in
5062 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5063 *) ac_try_echo=$ac_try;;
5064 esac
5065 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5066 $as_echo "$ac_try_echo"; } >&5
5067 (eval "$ac_link") 2>&5
5068 ac_status=$?
5069 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5070 test $ac_status = 0; }; then :
5071 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5072 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5073 # work properly (i.e., refer to `conftest.exe'), while it won't with
5074 # `rm'.
5075 for ac_file in conftest.exe conftest conftest.*; do
5076 test -f "$ac_file" || continue
5077 case $ac_file in
5078 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5079 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5080 break;;
5081 * ) break;;
5082 esac
5083 done
5084 else
5085 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5086 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5087 as_fn_error "cannot compute suffix of executables: cannot compile and link
5088 See \`config.log' for more details." "$LINENO" 5; }
5089 fi
5090 rm -f conftest conftest$ac_cv_exeext
5091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5092 $as_echo "$ac_cv_exeext" >&6; }
5093
5094 rm -f conftest.$ac_ext
5095 EXEEXT=$ac_cv_exeext
5096 ac_exeext=$EXEEXT
5097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5098 /* end confdefs.h. */
5099 #include <stdio.h>
5100 int
5101 main ()
5102 {
5103 FILE *f = fopen ("conftest.out", "w");
5104 return ferror (f) || fclose (f) != 0;
5105
5106 ;
5107 return 0;
5108 }
5109 _ACEOF
5110 ac_clean_files="$ac_clean_files conftest.out"
5111 # Check that the compiler produces executables we can run. If not, either
5112 # the compiler is broken, or we cross compile.
5113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5114 $as_echo_n "checking whether we are cross compiling... " >&6; }
5115 if test "$cross_compiling" != yes; then
5116 { { ac_try="$ac_link"
5117 case "(($ac_try" in
5118 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5119 *) ac_try_echo=$ac_try;;
5120 esac
5121 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5122 $as_echo "$ac_try_echo"; } >&5
5123 (eval "$ac_link") 2>&5
5124 ac_status=$?
5125 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5126 test $ac_status = 0; }
5127 if { ac_try='./conftest$ac_cv_exeext'
5128 { { case "(($ac_try" in
5129 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5130 *) ac_try_echo=$ac_try;;
5131 esac
5132 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5133 $as_echo "$ac_try_echo"; } >&5
5134 (eval "$ac_try") 2>&5
5135 ac_status=$?
5136 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5137 test $ac_status = 0; }; }; then
5138 cross_compiling=no
5139 else
5140 if test "$cross_compiling" = maybe; then
5141 cross_compiling=yes
5142 else
5143 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5144 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5145 as_fn_error "cannot run C compiled programs.
5146 If you meant to cross compile, use \`--host'.
5147 See \`config.log' for more details." "$LINENO" 5; }
5148 fi
5149 fi
5150 fi
5151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5152 $as_echo "$cross_compiling" >&6; }
5153
5154 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5155 ac_clean_files=$ac_clean_files_save
5156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5157 $as_echo_n "checking for suffix of object files... " >&6; }
5158 if test "${ac_cv_objext+set}" = set; then :
5159 $as_echo_n "(cached) " >&6
5160 else
5161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5162 /* end confdefs.h. */
5163
5164 int
5165 main ()
5166 {
5167
5168 ;
5169 return 0;
5170 }
5171 _ACEOF
5172 rm -f conftest.o conftest.obj
5173 if { { ac_try="$ac_compile"
5174 case "(($ac_try" in
5175 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5176 *) ac_try_echo=$ac_try;;
5177 esac
5178 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5179 $as_echo "$ac_try_echo"; } >&5
5180 (eval "$ac_compile") 2>&5
5181 ac_status=$?
5182 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5183 test $ac_status = 0; }; then :
5184 for ac_file in conftest.o conftest.obj conftest.*; do
5185 test -f "$ac_file" || continue;
5186 case $ac_file in
5187 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5188 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5189 break;;
5190 esac
5191 done
5192 else
5193 $as_echo "$as_me: failed program was:" >&5
5194 sed 's/^/| /' conftest.$ac_ext >&5
5195
5196 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5197 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5198 as_fn_error "cannot compute suffix of object files: cannot compile
5199 See \`config.log' for more details." "$LINENO" 5; }
5200 fi
5201 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5202 fi
5203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5204 $as_echo "$ac_cv_objext" >&6; }
5205 OBJEXT=$ac_cv_objext
5206 ac_objext=$OBJEXT
5207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5208 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5209 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5210 $as_echo_n "(cached) " >&6
5211 else
5212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5213 /* end confdefs.h. */
5214
5215 int
5216 main ()
5217 {
5218 #ifndef __GNUC__
5219 choke me
5220 #endif
5221
5222 ;
5223 return 0;
5224 }
5225 _ACEOF
5226 if ac_fn_c_try_compile "$LINENO"; then :
5227 ac_compiler_gnu=yes
5228 else
5229 ac_compiler_gnu=no
5230 fi
5231 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5232 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5233
5234 fi
5235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5236 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5237 if test $ac_compiler_gnu = yes; then
5238 GCC=yes
5239 else
5240 GCC=
5241 fi
5242 ac_test_CFLAGS=${CFLAGS+set}
5243 ac_save_CFLAGS=$CFLAGS
5244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5245 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5246 if test "${ac_cv_prog_cc_g+set}" = set; then :
5247 $as_echo_n "(cached) " >&6
5248 else
5249 ac_save_c_werror_flag=$ac_c_werror_flag
5250 ac_c_werror_flag=yes
5251 ac_cv_prog_cc_g=no
5252 CFLAGS="-g"
5253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5254 /* end confdefs.h. */
5255
5256 int
5257 main ()
5258 {
5259
5260 ;
5261 return 0;
5262 }
5263 _ACEOF
5264 if ac_fn_c_try_compile "$LINENO"; then :
5265 ac_cv_prog_cc_g=yes
5266 else
5267 CFLAGS=""
5268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5269 /* end confdefs.h. */
5270
5271 int
5272 main ()
5273 {
5274
5275 ;
5276 return 0;
5277 }
5278 _ACEOF
5279 if ac_fn_c_try_compile "$LINENO"; then :
5280
5281 else
5282 ac_c_werror_flag=$ac_save_c_werror_flag
5283 CFLAGS="-g"
5284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5285 /* end confdefs.h. */
5286
5287 int
5288 main ()
5289 {
5290
5291 ;
5292 return 0;
5293 }
5294 _ACEOF
5295 if ac_fn_c_try_compile "$LINENO"; then :
5296 ac_cv_prog_cc_g=yes
5297 fi
5298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5299 fi
5300 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5301 fi
5302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5303 ac_c_werror_flag=$ac_save_c_werror_flag
5304 fi
5305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5306 $as_echo "$ac_cv_prog_cc_g" >&6; }
5307 if test "$ac_test_CFLAGS" = set; then
5308 CFLAGS=$ac_save_CFLAGS
5309 elif test $ac_cv_prog_cc_g = yes; then
5310 if test "$GCC" = yes; then
5311 CFLAGS="-g -O2"
5312 else
5313 CFLAGS="-g"
5314 fi
5315 else
5316 if test "$GCC" = yes; then
5317 CFLAGS="-O2"
5318 else
5319 CFLAGS=
5320 fi
5321 fi
5322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5323 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5324 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5325 $as_echo_n "(cached) " >&6
5326 else
5327 ac_cv_prog_cc_c89=no
5328 ac_save_CC=$CC
5329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5330 /* end confdefs.h. */
5331 #include <stdarg.h>
5332 #include <stdio.h>
5333 #include <sys/types.h>
5334 #include <sys/stat.h>
5335 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5336 struct buf { int x; };
5337 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5338 static char *e (p, i)
5339 char **p;
5340 int i;
5341 {
5342 return p[i];
5343 }
5344 static char *f (char * (*g) (char **, int), char **p, ...)
5345 {
5346 char *s;
5347 va_list v;
5348 va_start (v,p);
5349 s = g (p, va_arg (v,int));
5350 va_end (v);
5351 return s;
5352 }
5353
5354 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5355 function prototypes and stuff, but not '\xHH' hex character constants.
5356 These don't provoke an error unfortunately, instead are silently treated
5357 as 'x'. The following induces an error, until -std is added to get
5358 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5359 array size at least. It's necessary to write '\x00'==0 to get something
5360 that's true only with -std. */
5361 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5362
5363 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5364 inside strings and character constants. */
5365 #define FOO(x) 'x'
5366 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5367
5368 int test (int i, double x);
5369 struct s1 {int (*f) (int a);};
5370 struct s2 {int (*f) (double a);};
5371 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5372 int argc;
5373 char **argv;
5374 int
5375 main ()
5376 {
5377 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5378 ;
5379 return 0;
5380 }
5381 _ACEOF
5382 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5383 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5384 do
5385 CC="$ac_save_CC $ac_arg"
5386 if ac_fn_c_try_compile "$LINENO"; then :
5387 ac_cv_prog_cc_c89=$ac_arg
5388 fi
5389 rm -f core conftest.err conftest.$ac_objext
5390 test "x$ac_cv_prog_cc_c89" != "xno" && break
5391 done
5392 rm -f conftest.$ac_ext
5393 CC=$ac_save_CC
5394
5395 fi
5396 # AC_CACHE_VAL
5397 case "x$ac_cv_prog_cc_c89" in
5398 x)
5399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5400 $as_echo "none needed" >&6; } ;;
5401 xno)
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5403 $as_echo "unsupported" >&6; } ;;
5404 *)
5405 CC="$CC $ac_cv_prog_cc_c89"
5406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5407 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5408 esac
5409 if test "x$ac_cv_prog_cc_c89" != xno; then :
5410
5411 fi
5412
5413 ac_ext=c
5414 ac_cpp='$CPP $CPPFLAGS'
5415 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5416 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5417 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5418 DEPDIR="${am__leading_dot}deps"
5419
5420 ac_config_commands="$ac_config_commands depfiles"
5421
5422
5423 am_make=${MAKE-make}
5424 cat > confinc << 'END'
5425 am__doit:
5426 @echo this is the am__doit target
5427 .PHONY: am__doit
5428 END
5429 # If we don't find an include directive, just comment out the code.
5430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5431 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5432 am__include="#"
5433 am__quote=
5434 _am_result=none
5435 # First try GNU make style include.
5436 echo "include confinc" > confmf
5437 # Ignore all kinds of additional output from `make'.
5438 case `$am_make -s -f confmf 2> /dev/null` in #(
5439 *the\ am__doit\ target*)
5440 am__include=include
5441 am__quote=
5442 _am_result=GNU
5443 ;;
5444 esac
5445 # Now try BSD make style include.
5446 if test "$am__include" = "#"; then
5447 echo '.include "confinc"' > confmf
5448 case `$am_make -s -f confmf 2> /dev/null` in #(
5449 *the\ am__doit\ target*)
5450 am__include=.include
5451 am__quote="\""
5452 _am_result=BSD
5453 ;;
5454 esac
5455 fi
5456
5457
5458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5459 $as_echo "$_am_result" >&6; }
5460 rm -f confinc confmf
5461
5462 # Check whether --enable-dependency-tracking was given.
5463 if test "${enable_dependency_tracking+set}" = set; then :
5464 enableval=$enable_dependency_tracking;
5465 fi
5466
5467 if test "x$enable_dependency_tracking" != xno; then
5468 am_depcomp="$ac_aux_dir/depcomp"
5469 AMDEPBACKSLASH='\'
5470 fi
5471 if test "x$enable_dependency_tracking" != xno; then
5472 AMDEP_TRUE=
5473 AMDEP_FALSE='#'
5474 else
5475 AMDEP_TRUE='#'
5476 AMDEP_FALSE=
5477 fi
5478
5479
5480
5481 depcc="$CC" am_compiler_list=
5482
5483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5484 $as_echo_n "checking dependency style of $depcc... " >&6; }
5485 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5486 $as_echo_n "(cached) " >&6
5487 else
5488 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5489 # We make a subdir and do the tests there. Otherwise we can end up
5490 # making bogus files that we don't know about and never remove. For
5491 # instance it was reported that on HP-UX the gcc test will end up
5492 # making a dummy file named `D' -- because `-MD' means `put the output
5493 # in D'.
5494 mkdir conftest.dir
5495 # Copy depcomp to subdir because otherwise we won't find it if we're
5496 # using a relative directory.
5497 cp "$am_depcomp" conftest.dir
5498 cd conftest.dir
5499 # We will build objects and dependencies in a subdirectory because
5500 # it helps to detect inapplicable dependency modes. For instance
5501 # both Tru64's cc and ICC support -MD to output dependencies as a
5502 # side effect of compilation, but ICC will put the dependencies in
5503 # the current directory while Tru64 will put them in the object
5504 # directory.
5505 mkdir sub
5506
5507 am_cv_CC_dependencies_compiler_type=none
5508 if test "$am_compiler_list" = ""; then
5509 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5510 fi
5511 am__universal=false
5512 case " $depcc " in #(
5513 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5514 esac
5515
5516 for depmode in $am_compiler_list; do
5517 # Setup a source with many dependencies, because some compilers
5518 # like to wrap large dependency lists on column 80 (with \), and
5519 # we should not choose a depcomp mode which is confused by this.
5520 #
5521 # We need to recreate these files for each test, as the compiler may
5522 # overwrite some of them when testing with obscure command lines.
5523 # This happens at least with the AIX C compiler.
5524 : > sub/conftest.c
5525 for i in 1 2 3 4 5 6; do
5526 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5527 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5528 # Solaris 8's {/usr,}/bin/sh.
5529 touch sub/conftst$i.h
5530 done
5531 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5532
5533 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5534 # mode. It turns out that the SunPro C++ compiler does not properly
5535 # handle `-M -o', and we need to detect this. Also, some Intel
5536 # versions had trouble with output in subdirs
5537 am__obj=sub/conftest.${OBJEXT-o}
5538 am__minus_obj="-o $am__obj"
5539 case $depmode in
5540 gcc)
5541 # This depmode causes a compiler race in universal mode.
5542 test "$am__universal" = false || continue
5543 ;;
5544 nosideeffect)
5545 # after this tag, mechanisms are not by side-effect, so they'll
5546 # only be used when explicitly requested
5547 if test "x$enable_dependency_tracking" = xyes; then
5548 continue
5549 else
5550 break
5551 fi
5552 ;;
5553 msvisualcpp | msvcmsys)
5554 # This compiler won't grok `-c -o', but also, the minuso test has
5555 # not run yet. These depmodes are late enough in the game, and
5556 # so weak that their functioning should not be impacted.
5557 am__obj=conftest.${OBJEXT-o}
5558 am__minus_obj=
5559 ;;
5560 none) break ;;
5561 esac
5562 if depmode=$depmode \
5563 source=sub/conftest.c object=$am__obj \
5564 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5565 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5566 >/dev/null 2>conftest.err &&
5567 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5568 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5569 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5570 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5571 # icc doesn't choke on unknown options, it will just issue warnings
5572 # or remarks (even with -Werror). So we grep stderr for any message
5573 # that says an option was ignored or not supported.
5574 # When given -MP, icc 7.0 and 7.1 complain thusly:
5575 # icc: Command line warning: ignoring option '-M'; no argument required
5576 # The diagnosis changed in icc 8.0:
5577 # icc: Command line remark: option '-MP' not supported
5578 if (grep 'ignoring option' conftest.err ||
5579 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5580 am_cv_CC_dependencies_compiler_type=$depmode
5581 break
5582 fi
5583 fi
5584 done
5585
5586 cd ..
5587 rm -rf conftest.dir
5588 else
5589 am_cv_CC_dependencies_compiler_type=none
5590 fi
5591
5592 fi
5593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5594 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5595 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5596
5597 if
5598 test "x$enable_dependency_tracking" != xno \
5599 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5600 am__fastdepCC_TRUE=
5601 am__fastdepCC_FALSE='#'
5602 else
5603 am__fastdepCC_TRUE='#'
5604 am__fastdepCC_FALSE=
5605 fi
5606
5607
5608 if test "x$CC" != xcc; then
5609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5610 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5611 else
5612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5613 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5614 fi
5615 set dummy $CC; ac_cc=`$as_echo "$2" |
5616 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5617 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5618 $as_echo_n "(cached) " >&6
5619 else
5620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5621 /* end confdefs.h. */
5622
5623 int
5624 main ()
5625 {
5626
5627 ;
5628 return 0;
5629 }
5630 _ACEOF
5631 # Make sure it works both with $CC and with simple cc.
5632 # We do the test twice because some compilers refuse to overwrite an
5633 # existing .o file with -o, though they will create one.
5634 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5635 rm -f conftest2.*
5636 if { { case "(($ac_try" in
5637 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5638 *) ac_try_echo=$ac_try;;
5639 esac
5640 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5641 $as_echo "$ac_try_echo"; } >&5
5642 (eval "$ac_try") 2>&5
5643 ac_status=$?
5644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5645 test $ac_status = 0; } &&
5646 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5647 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5648 *) ac_try_echo=$ac_try;;
5649 esac
5650 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5651 $as_echo "$ac_try_echo"; } >&5
5652 (eval "$ac_try") 2>&5
5653 ac_status=$?
5654 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5655 test $ac_status = 0; };
5656 then
5657 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5658 if test "x$CC" != xcc; then
5659 # Test first that cc exists at all.
5660 if { ac_try='cc -c conftest.$ac_ext >&5'
5661 { { case "(($ac_try" in
5662 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5663 *) ac_try_echo=$ac_try;;
5664 esac
5665 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5666 $as_echo "$ac_try_echo"; } >&5
5667 (eval "$ac_try") 2>&5
5668 ac_status=$?
5669 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5670 test $ac_status = 0; }; }; then
5671 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5672 rm -f conftest2.*
5673 if { { case "(($ac_try" in
5674 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5675 *) ac_try_echo=$ac_try;;
5676 esac
5677 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5678 $as_echo "$ac_try_echo"; } >&5
5679 (eval "$ac_try") 2>&5
5680 ac_status=$?
5681 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5682 test $ac_status = 0; } &&
5683 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5684 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5685 *) ac_try_echo=$ac_try;;
5686 esac
5687 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5688 $as_echo "$ac_try_echo"; } >&5
5689 (eval "$ac_try") 2>&5
5690 ac_status=$?
5691 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5692 test $ac_status = 0; };
5693 then
5694 # cc works too.
5695 :
5696 else
5697 # cc exists but doesn't like -o.
5698 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5699 fi
5700 fi
5701 fi
5702 else
5703 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5704 fi
5705 rm -f core conftest*
5706
5707 fi
5708 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5710 $as_echo "yes" >&6; }
5711 else
5712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5713 $as_echo "no" >&6; }
5714
5715 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5716
5717 fi
5718
5719 # FIXME: we rely on the cache variable name because
5720 # there is no other way.
5721 set dummy $CC
5722 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5723 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5724 if test "$am_t" != yes; then
5725 # Losing compiler, so override with the script.
5726 # FIXME: It is wrong to rewrite CC.
5727 # But if we don't then we get into trouble of one sort or another.
5728 # A longer-term fix would be to have automake use am__CC in this case,
5729 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5730 CC="$am_aux_dir/compile $CC"
5731 fi
5732
5733
5734
5735 if test x$GCC = xyes; then
5736 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5737 else
5738 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5739 fi
5740
5741 # Avoid gnulib's threadlib module, as we do threads our own way.
5742
5743
5744 # Initialize gnulib right after choosing the compiler.
5745
5746 ac_ext=c
5747 ac_cpp='$CPP $CPPFLAGS'
5748 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5749 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5750 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5752 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5753 # On Suns, sometimes $CPP names a directory.
5754 if test -n "$CPP" && test -d "$CPP"; then
5755 CPP=
5756 fi
5757 if test -z "$CPP"; then
5758 if test "${ac_cv_prog_CPP+set}" = set; then :
5759 $as_echo_n "(cached) " >&6
5760 else
5761 # Double quotes because CPP needs to be expanded
5762 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5763 do
5764 ac_preproc_ok=false
5765 for ac_c_preproc_warn_flag in '' yes
5766 do
5767 # Use a header file that comes with gcc, so configuring glibc
5768 # with a fresh cross-compiler works.
5769 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5770 # <limits.h> exists even on freestanding compilers.
5771 # On the NeXT, cc -E runs the code through the compiler's parser,
5772 # not just through cpp. "Syntax error" is here to catch this case.
5773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5774 /* end confdefs.h. */
5775 #ifdef __STDC__
5776 # include <limits.h>
5777 #else
5778 # include <assert.h>
5779 #endif
5780 Syntax error
5781 _ACEOF
5782 if ac_fn_c_try_cpp "$LINENO"; then :
5783
5784 else
5785 # Broken: fails on valid input.
5786 continue
5787 fi
5788 rm -f conftest.err conftest.$ac_ext
5789
5790 # OK, works on sane cases. Now check whether nonexistent headers
5791 # can be detected and how.
5792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5793 /* end confdefs.h. */
5794 #include <ac_nonexistent.h>
5795 _ACEOF
5796 if ac_fn_c_try_cpp "$LINENO"; then :
5797 # Broken: success on invalid input.
5798 continue
5799 else
5800 # Passes both tests.
5801 ac_preproc_ok=:
5802 break
5803 fi
5804 rm -f conftest.err conftest.$ac_ext
5805
5806 done
5807 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5808 rm -f conftest.err conftest.$ac_ext
5809 if $ac_preproc_ok; then :
5810 break
5811 fi
5812
5813 done
5814 ac_cv_prog_CPP=$CPP
5815
5816 fi
5817 CPP=$ac_cv_prog_CPP
5818 else
5819 ac_cv_prog_CPP=$CPP
5820 fi
5821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5822 $as_echo "$CPP" >&6; }
5823 ac_preproc_ok=false
5824 for ac_c_preproc_warn_flag in '' yes
5825 do
5826 # Use a header file that comes with gcc, so configuring glibc
5827 # with a fresh cross-compiler works.
5828 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5829 # <limits.h> exists even on freestanding compilers.
5830 # On the NeXT, cc -E runs the code through the compiler's parser,
5831 # not just through cpp. "Syntax error" is here to catch this case.
5832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5833 /* end confdefs.h. */
5834 #ifdef __STDC__
5835 # include <limits.h>
5836 #else
5837 # include <assert.h>
5838 #endif
5839 Syntax error
5840 _ACEOF
5841 if ac_fn_c_try_cpp "$LINENO"; then :
5842
5843 else
5844 # Broken: fails on valid input.
5845 continue
5846 fi
5847 rm -f conftest.err conftest.$ac_ext
5848
5849 # OK, works on sane cases. Now check whether nonexistent headers
5850 # can be detected and how.
5851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5852 /* end confdefs.h. */
5853 #include <ac_nonexistent.h>
5854 _ACEOF
5855 if ac_fn_c_try_cpp "$LINENO"; then :
5856 # Broken: success on invalid input.
5857 continue
5858 else
5859 # Passes both tests.
5860 ac_preproc_ok=:
5861 break
5862 fi
5863 rm -f conftest.err conftest.$ac_ext
5864
5865 done
5866 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5867 rm -f conftest.err conftest.$ac_ext
5868 if $ac_preproc_ok; then :
5869
5870 else
5871 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5872 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5873 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5874 See \`config.log' for more details." "$LINENO" 5; }
5875 fi
5876
5877 ac_ext=c
5878 ac_cpp='$CPP $CPPFLAGS'
5879 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5880 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5881 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5882
5883
5884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5885 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5886 if test "${ac_cv_path_GREP+set}" = set; then :
5887 $as_echo_n "(cached) " >&6
5888 else
5889 if test -z "$GREP"; then
5890 ac_path_GREP_found=false
5891 # Loop through the user's path and test for each of PROGNAME-LIST
5892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5893 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5894 do
5895 IFS=$as_save_IFS
5896 test -z "$as_dir" && as_dir=.
5897 for ac_prog in grep ggrep; do
5898 for ac_exec_ext in '' $ac_executable_extensions; do
5899 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5900 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5901 # Check for GNU ac_path_GREP and select it if it is found.
5902 # Check for GNU $ac_path_GREP
5903 case `"$ac_path_GREP" --version 2>&1` in
5904 *GNU*)
5905 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5906 *)
5907 ac_count=0
5908 $as_echo_n 0123456789 >"conftest.in"
5909 while :
5910 do
5911 cat "conftest.in" "conftest.in" >"conftest.tmp"
5912 mv "conftest.tmp" "conftest.in"
5913 cp "conftest.in" "conftest.nl"
5914 $as_echo 'GREP' >> "conftest.nl"
5915 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5916 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5917 as_fn_arith $ac_count + 1 && ac_count=$as_val
5918 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5919 # Best one so far, save it but keep looking for a better one
5920 ac_cv_path_GREP="$ac_path_GREP"
5921 ac_path_GREP_max=$ac_count
5922 fi
5923 # 10*(2^10) chars as input seems more than enough
5924 test $ac_count -gt 10 && break
5925 done
5926 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5927 esac
5928
5929 $ac_path_GREP_found && break 3
5930 done
5931 done
5932 done
5933 IFS=$as_save_IFS
5934 if test -z "$ac_cv_path_GREP"; then
5935 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5936 fi
5937 else
5938 ac_cv_path_GREP=$GREP
5939 fi
5940
5941 fi
5942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5943 $as_echo "$ac_cv_path_GREP" >&6; }
5944 GREP="$ac_cv_path_GREP"
5945
5946
5947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5948 $as_echo_n "checking for egrep... " >&6; }
5949 if test "${ac_cv_path_EGREP+set}" = set; then :
5950 $as_echo_n "(cached) " >&6
5951 else
5952 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5953 then ac_cv_path_EGREP="$GREP -E"
5954 else
5955 if test -z "$EGREP"; then
5956 ac_path_EGREP_found=false
5957 # Loop through the user's path and test for each of PROGNAME-LIST
5958 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5959 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5960 do
5961 IFS=$as_save_IFS
5962 test -z "$as_dir" && as_dir=.
5963 for ac_prog in egrep; do
5964 for ac_exec_ext in '' $ac_executable_extensions; do
5965 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5966 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5967 # Check for GNU ac_path_EGREP and select it if it is found.
5968 # Check for GNU $ac_path_EGREP
5969 case `"$ac_path_EGREP" --version 2>&1` in
5970 *GNU*)
5971 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5972 *)
5973 ac_count=0
5974 $as_echo_n 0123456789 >"conftest.in"
5975 while :
5976 do
5977 cat "conftest.in" "conftest.in" >"conftest.tmp"
5978 mv "conftest.tmp" "conftest.in"
5979 cp "conftest.in" "conftest.nl"
5980 $as_echo 'EGREP' >> "conftest.nl"
5981 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5982 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5983 as_fn_arith $ac_count + 1 && ac_count=$as_val
5984 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5985 # Best one so far, save it but keep looking for a better one
5986 ac_cv_path_EGREP="$ac_path_EGREP"
5987 ac_path_EGREP_max=$ac_count
5988 fi
5989 # 10*(2^10) chars as input seems more than enough
5990 test $ac_count -gt 10 && break
5991 done
5992 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5993 esac
5994
5995 $ac_path_EGREP_found && break 3
5996 done
5997 done
5998 done
5999 IFS=$as_save_IFS
6000 if test -z "$ac_cv_path_EGREP"; then
6001 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6002 fi
6003 else
6004 ac_cv_path_EGREP=$EGREP
6005 fi
6006
6007 fi
6008 fi
6009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6010 $as_echo "$ac_cv_path_EGREP" >&6; }
6011 EGREP="$ac_cv_path_EGREP"
6012
6013
6014
6015
6016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6017 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6018 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6019 $as_echo_n "(cached) " >&6
6020 else
6021
6022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6023 /* end confdefs.h. */
6024
6025 #ifdef __ACK__
6026 Amsterdam
6027 #endif
6028
6029 _ACEOF
6030 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6031 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6032 gl_cv_c_amsterdam_compiler=yes
6033 else
6034 gl_cv_c_amsterdam_compiler=no
6035 fi
6036 rm -f conftest*
6037
6038
6039 fi
6040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6041 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6042 if test -z "$AR"; then
6043 if test $gl_cv_c_amsterdam_compiler = yes; then
6044 AR='cc -c.a'
6045 if test -z "$ARFLAGS"; then
6046 ARFLAGS='-o'
6047 fi
6048 else
6049 if test -n "$ac_tool_prefix"; then
6050 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6051 set dummy ${ac_tool_prefix}ar; ac_word=$2
6052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6053 $as_echo_n "checking for $ac_word... " >&6; }
6054 if test "${ac_cv_prog_AR+set}" = set; then :
6055 $as_echo_n "(cached) " >&6
6056 else
6057 if test -n "$AR"; then
6058 ac_cv_prog_AR="$AR" # Let the user override the test.
6059 else
6060 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6061 for as_dir in $PATH
6062 do
6063 IFS=$as_save_IFS
6064 test -z "$as_dir" && as_dir=.
6065 for ac_exec_ext in '' $ac_executable_extensions; do
6066 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6067 ac_cv_prog_AR="${ac_tool_prefix}ar"
6068 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6069 break 2
6070 fi
6071 done
6072 done
6073 IFS=$as_save_IFS
6074
6075 fi
6076 fi
6077 AR=$ac_cv_prog_AR
6078 if test -n "$AR"; then
6079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6080 $as_echo "$AR" >&6; }
6081 else
6082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6083 $as_echo "no" >&6; }
6084 fi
6085
6086
6087 fi
6088 if test -z "$ac_cv_prog_AR"; then
6089 ac_ct_AR=$AR
6090 # Extract the first word of "ar", so it can be a program name with args.
6091 set dummy ar; ac_word=$2
6092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6093 $as_echo_n "checking for $ac_word... " >&6; }
6094 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6095 $as_echo_n "(cached) " >&6
6096 else
6097 if test -n "$ac_ct_AR"; then
6098 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6099 else
6100 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6101 for as_dir in $PATH
6102 do
6103 IFS=$as_save_IFS
6104 test -z "$as_dir" && as_dir=.
6105 for ac_exec_ext in '' $ac_executable_extensions; do
6106 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6107 ac_cv_prog_ac_ct_AR="ar"
6108 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6109 break 2
6110 fi
6111 done
6112 done
6113 IFS=$as_save_IFS
6114
6115 fi
6116 fi
6117 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6118 if test -n "$ac_ct_AR"; then
6119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6120 $as_echo "$ac_ct_AR" >&6; }
6121 else
6122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6123 $as_echo "no" >&6; }
6124 fi
6125
6126 if test "x$ac_ct_AR" = x; then
6127 AR="ar"
6128 else
6129 case $cross_compiling:$ac_tool_warned in
6130 yes:)
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6132 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6133 ac_tool_warned=yes ;;
6134 esac
6135 AR=$ac_ct_AR
6136 fi
6137 else
6138 AR="$ac_cv_prog_AR"
6139 fi
6140
6141 if test -z "$ARFLAGS"; then
6142 ARFLAGS='cru'
6143 fi
6144 fi
6145 else
6146 if test -z "$ARFLAGS"; then
6147 ARFLAGS='cru'
6148 fi
6149 fi
6150
6151
6152 if test -z "$RANLIB"; then
6153 if test $gl_cv_c_amsterdam_compiler = yes; then
6154 RANLIB=':'
6155 else
6156 if test -n "$ac_tool_prefix"; then
6157 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6158 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6160 $as_echo_n "checking for $ac_word... " >&6; }
6161 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6162 $as_echo_n "(cached) " >&6
6163 else
6164 if test -n "$RANLIB"; then
6165 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6166 else
6167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6168 for as_dir in $PATH
6169 do
6170 IFS=$as_save_IFS
6171 test -z "$as_dir" && as_dir=.
6172 for ac_exec_ext in '' $ac_executable_extensions; do
6173 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6174 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6176 break 2
6177 fi
6178 done
6179 done
6180 IFS=$as_save_IFS
6181
6182 fi
6183 fi
6184 RANLIB=$ac_cv_prog_RANLIB
6185 if test -n "$RANLIB"; then
6186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6187 $as_echo "$RANLIB" >&6; }
6188 else
6189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6190 $as_echo "no" >&6; }
6191 fi
6192
6193
6194 fi
6195 if test -z "$ac_cv_prog_RANLIB"; then
6196 ac_ct_RANLIB=$RANLIB
6197 # Extract the first word of "ranlib", so it can be a program name with args.
6198 set dummy ranlib; ac_word=$2
6199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6200 $as_echo_n "checking for $ac_word... " >&6; }
6201 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6202 $as_echo_n "(cached) " >&6
6203 else
6204 if test -n "$ac_ct_RANLIB"; then
6205 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6206 else
6207 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6208 for as_dir in $PATH
6209 do
6210 IFS=$as_save_IFS
6211 test -z "$as_dir" && as_dir=.
6212 for ac_exec_ext in '' $ac_executable_extensions; do
6213 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6214 ac_cv_prog_ac_ct_RANLIB="ranlib"
6215 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6216 break 2
6217 fi
6218 done
6219 done
6220 IFS=$as_save_IFS
6221
6222 fi
6223 fi
6224 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6225 if test -n "$ac_ct_RANLIB"; then
6226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6227 $as_echo "$ac_ct_RANLIB" >&6; }
6228 else
6229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6230 $as_echo "no" >&6; }
6231 fi
6232
6233 if test "x$ac_ct_RANLIB" = x; then
6234 RANLIB=":"
6235 else
6236 case $cross_compiling:$ac_tool_warned in
6237 yes:)
6238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6239 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6240 ac_tool_warned=yes ;;
6241 esac
6242 RANLIB=$ac_ct_RANLIB
6243 fi
6244 else
6245 RANLIB="$ac_cv_prog_RANLIB"
6246 fi
6247
6248 fi
6249 fi
6250
6251
6252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6253 $as_echo_n "checking for ANSI C header files... " >&6; }
6254 if test "${ac_cv_header_stdc+set}" = set; then :
6255 $as_echo_n "(cached) " >&6
6256 else
6257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6258 /* end confdefs.h. */
6259 #include <stdlib.h>
6260 #include <stdarg.h>
6261 #include <string.h>
6262 #include <float.h>
6263
6264 int
6265 main ()
6266 {
6267
6268 ;
6269 return 0;
6270 }
6271 _ACEOF
6272 if ac_fn_c_try_compile "$LINENO"; then :
6273 ac_cv_header_stdc=yes
6274 else
6275 ac_cv_header_stdc=no
6276 fi
6277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6278
6279 if test $ac_cv_header_stdc = yes; then
6280 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6282 /* end confdefs.h. */
6283 #include <string.h>
6284
6285 _ACEOF
6286 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6287 $EGREP "memchr" >/dev/null 2>&1; then :
6288
6289 else
6290 ac_cv_header_stdc=no
6291 fi
6292 rm -f conftest*
6293
6294 fi
6295
6296 if test $ac_cv_header_stdc = yes; then
6297 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6299 /* end confdefs.h. */
6300 #include <stdlib.h>
6301
6302 _ACEOF
6303 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6304 $EGREP "free" >/dev/null 2>&1; then :
6305
6306 else
6307 ac_cv_header_stdc=no
6308 fi
6309 rm -f conftest*
6310
6311 fi
6312
6313 if test $ac_cv_header_stdc = yes; then
6314 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6315 if test "$cross_compiling" = yes; then :
6316 :
6317 else
6318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6319 /* end confdefs.h. */
6320 #include <ctype.h>
6321 #include <stdlib.h>
6322 #if ((' ' & 0x0FF) == 0x020)
6323 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6324 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6325 #else
6326 # define ISLOWER(c) \
6327 (('a' <= (c) && (c) <= 'i') \
6328 || ('j' <= (c) && (c) <= 'r') \
6329 || ('s' <= (c) && (c) <= 'z'))
6330 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6331 #endif
6332
6333 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6334 int
6335 main ()
6336 {
6337 int i;
6338 for (i = 0; i < 256; i++)
6339 if (XOR (islower (i), ISLOWER (i))
6340 || toupper (i) != TOUPPER (i))
6341 return 2;
6342 return 0;
6343 }
6344 _ACEOF
6345 if ac_fn_c_try_run "$LINENO"; then :
6346
6347 else
6348 ac_cv_header_stdc=no
6349 fi
6350 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6351 conftest.$ac_objext conftest.beam conftest.$ac_ext
6352 fi
6353
6354 fi
6355 fi
6356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6357 $as_echo "$ac_cv_header_stdc" >&6; }
6358 if test $ac_cv_header_stdc = yes; then
6359
6360 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6361
6362 fi
6363
6364 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6365 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6366 inttypes.h stdint.h unistd.h
6367 do :
6368 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6369 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6370 "
6371 eval as_val=\$$as_ac_Header
6372 if test "x$as_val" = x""yes; then :
6373 cat >>confdefs.h <<_ACEOF
6374 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6375 _ACEOF
6376
6377 fi
6378
6379 done
6380
6381
6382
6383
6384
6385 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6386 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6387 MINIX=yes
6388 else
6389 MINIX=
6390 fi
6391
6392
6393 if test "$MINIX" = yes; then
6394
6395 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6396
6397
6398 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6399
6400
6401 $as_echo "#define _MINIX 1" >>confdefs.h
6402
6403 fi
6404
6405 case "$host_os" in
6406 hpux*)
6407
6408 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6409
6410 ;;
6411 esac
6412
6413
6414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6415 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6416 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6417 $as_echo_n "(cached) " >&6
6418 else
6419 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6420 /* end confdefs.h. */
6421
6422 # define __EXTENSIONS__ 1
6423 $ac_includes_default
6424 int
6425 main ()
6426 {
6427
6428 ;
6429 return 0;
6430 }
6431 _ACEOF
6432 if ac_fn_c_try_compile "$LINENO"; then :
6433 ac_cv_safe_to_define___extensions__=yes
6434 else
6435 ac_cv_safe_to_define___extensions__=no
6436 fi
6437 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6438 fi
6439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6440 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6441 test $ac_cv_safe_to_define___extensions__ = yes &&
6442 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6443
6444 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6445
6446 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6447
6448 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6449
6450 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6451
6452 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6453
6454
6455
6456
6457
6458
6459
6460
6461 # Check whether --enable-largefile was given.
6462 if test "${enable_largefile+set}" = set; then :
6463 enableval=$enable_largefile;
6464 fi
6465
6466 if test "$enable_largefile" != no; then
6467
6468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6469 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6470 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6471 $as_echo_n "(cached) " >&6
6472 else
6473 ac_cv_sys_largefile_CC=no
6474 if test "$GCC" != yes; then
6475 ac_save_CC=$CC
6476 while :; do
6477 # IRIX 6.2 and later do not support large files by default,
6478 # so use the C compiler's -n32 option if that helps.
6479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6480 /* end confdefs.h. */
6481 #include <sys/types.h>
6482 /* Check that off_t can represent 2**63 - 1 correctly.
6483 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6484 since some C++ compilers masquerading as C compilers
6485 incorrectly reject 9223372036854775807. */
6486 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6487 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6488 && LARGE_OFF_T % 2147483647 == 1)
6489 ? 1 : -1];
6490 int
6491 main ()
6492 {
6493
6494 ;
6495 return 0;
6496 }
6497 _ACEOF
6498 if ac_fn_c_try_compile "$LINENO"; then :
6499 break
6500 fi
6501 rm -f core conftest.err conftest.$ac_objext
6502 CC="$CC -n32"
6503 if ac_fn_c_try_compile "$LINENO"; then :
6504 ac_cv_sys_largefile_CC=' -n32'; break
6505 fi
6506 rm -f core conftest.err conftest.$ac_objext
6507 break
6508 done
6509 CC=$ac_save_CC
6510 rm -f conftest.$ac_ext
6511 fi
6512 fi
6513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6514 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6515 if test "$ac_cv_sys_largefile_CC" != no; then
6516 CC=$CC$ac_cv_sys_largefile_CC
6517 fi
6518
6519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6520 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6521 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6522 $as_echo_n "(cached) " >&6
6523 else
6524 while :; do
6525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6526 /* end confdefs.h. */
6527 #include <sys/types.h>
6528 /* Check that off_t can represent 2**63 - 1 correctly.
6529 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6530 since some C++ compilers masquerading as C compilers
6531 incorrectly reject 9223372036854775807. */
6532 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6533 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6534 && LARGE_OFF_T % 2147483647 == 1)
6535 ? 1 : -1];
6536 int
6537 main ()
6538 {
6539
6540 ;
6541 return 0;
6542 }
6543 _ACEOF
6544 if ac_fn_c_try_compile "$LINENO"; then :
6545 ac_cv_sys_file_offset_bits=no; break
6546 fi
6547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6549 /* end confdefs.h. */
6550 #define _FILE_OFFSET_BITS 64
6551 #include <sys/types.h>
6552 /* Check that off_t can represent 2**63 - 1 correctly.
6553 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6554 since some C++ compilers masquerading as C compilers
6555 incorrectly reject 9223372036854775807. */
6556 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6557 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6558 && LARGE_OFF_T % 2147483647 == 1)
6559 ? 1 : -1];
6560 int
6561 main ()
6562 {
6563
6564 ;
6565 return 0;
6566 }
6567 _ACEOF
6568 if ac_fn_c_try_compile "$LINENO"; then :
6569 ac_cv_sys_file_offset_bits=64; break
6570 fi
6571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6572 ac_cv_sys_file_offset_bits=unknown
6573 break
6574 done
6575 fi
6576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6577 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6578 case $ac_cv_sys_file_offset_bits in #(
6579 no | unknown) ;;
6580 *)
6581 cat >>confdefs.h <<_ACEOF
6582 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6583 _ACEOF
6584 ;;
6585 esac
6586 rm -rf conftest*
6587 if test $ac_cv_sys_file_offset_bits = unknown; then
6588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6589 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6590 if test "${ac_cv_sys_large_files+set}" = set; then :
6591 $as_echo_n "(cached) " >&6
6592 else
6593 while :; do
6594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6595 /* end confdefs.h. */
6596 #include <sys/types.h>
6597 /* Check that off_t can represent 2**63 - 1 correctly.
6598 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6599 since some C++ compilers masquerading as C compilers
6600 incorrectly reject 9223372036854775807. */
6601 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6602 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6603 && LARGE_OFF_T % 2147483647 == 1)
6604 ? 1 : -1];
6605 int
6606 main ()
6607 {
6608
6609 ;
6610 return 0;
6611 }
6612 _ACEOF
6613 if ac_fn_c_try_compile "$LINENO"; then :
6614 ac_cv_sys_large_files=no; break
6615 fi
6616 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6618 /* end confdefs.h. */
6619 #define _LARGE_FILES 1
6620 #include <sys/types.h>
6621 /* Check that off_t can represent 2**63 - 1 correctly.
6622 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6623 since some C++ compilers masquerading as C compilers
6624 incorrectly reject 9223372036854775807. */
6625 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6626 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6627 && LARGE_OFF_T % 2147483647 == 1)
6628 ? 1 : -1];
6629 int
6630 main ()
6631 {
6632
6633 ;
6634 return 0;
6635 }
6636 _ACEOF
6637 if ac_fn_c_try_compile "$LINENO"; then :
6638 ac_cv_sys_large_files=1; break
6639 fi
6640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6641 ac_cv_sys_large_files=unknown
6642 break
6643 done
6644 fi
6645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6646 $as_echo "$ac_cv_sys_large_files" >&6; }
6647 case $ac_cv_sys_large_files in #(
6648 no | unknown) ;;
6649 *)
6650 cat >>confdefs.h <<_ACEOF
6651 #define _LARGE_FILES $ac_cv_sys_large_files
6652 _ACEOF
6653 ;;
6654 esac
6655 rm -rf conftest*
6656 fi
6657
6658
6659 fi
6660
6661 case $ac_cv_prog_cc_stdc in #(
6662 no) :
6663 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6664 *) :
6665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6666 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6667 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6668 $as_echo_n "(cached) " >&6
6669 else
6670 ac_cv_prog_cc_c99=no
6671 ac_save_CC=$CC
6672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6673 /* end confdefs.h. */
6674 #include <stdarg.h>
6675 #include <stdbool.h>
6676 #include <stdlib.h>
6677 #include <wchar.h>
6678 #include <stdio.h>
6679
6680 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6681 #define debug(...) fprintf (stderr, __VA_ARGS__)
6682 #define showlist(...) puts (#__VA_ARGS__)
6683 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6684 static void
6685 test_varargs_macros (void)
6686 {
6687 int x = 1234;
6688 int y = 5678;
6689 debug ("Flag");
6690 debug ("X = %d\n", x);
6691 showlist (The first, second, and third items.);
6692 report (x>y, "x is %d but y is %d", x, y);
6693 }
6694
6695 // Check long long types.
6696 #define BIG64 18446744073709551615ull
6697 #define BIG32 4294967295ul
6698 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6699 #if !BIG_OK
6700 your preprocessor is broken;
6701 #endif
6702 #if BIG_OK
6703 #else
6704 your preprocessor is broken;
6705 #endif
6706 static long long int bignum = -9223372036854775807LL;
6707 static unsigned long long int ubignum = BIG64;
6708
6709 struct incomplete_array
6710 {
6711 int datasize;
6712 double data[];
6713 };
6714
6715 struct named_init {
6716 int number;
6717 const wchar_t *name;
6718 double average;
6719 };
6720
6721 typedef const char *ccp;
6722
6723 static inline int
6724 test_restrict (ccp restrict text)
6725 {
6726 // See if C++-style comments work.
6727 // Iterate through items via the restricted pointer.
6728 // Also check for declarations in for loops.
6729 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6730 continue;
6731 return 0;
6732 }
6733
6734 // Check varargs and va_copy.
6735 static void
6736 test_varargs (const char *format, ...)
6737 {
6738 va_list args;
6739 va_start (args, format);
6740 va_list args_copy;
6741 va_copy (args_copy, args);
6742
6743 const char *str;
6744 int number;
6745 float fnumber;
6746
6747 while (*format)
6748 {
6749 switch (*format++)
6750 {
6751 case 's': // string
6752 str = va_arg (args_copy, const char *);
6753 break;
6754 case 'd': // int
6755 number = va_arg (args_copy, int);
6756 break;
6757 case 'f': // float
6758 fnumber = va_arg (args_copy, double);
6759 break;
6760 default:
6761 break;
6762 }
6763 }
6764 va_end (args_copy);
6765 va_end (args);
6766 }
6767
6768 int
6769 main ()
6770 {
6771
6772 // Check bool.
6773 _Bool success = false;
6774
6775 // Check restrict.
6776 if (test_restrict ("String literal") == 0)
6777 success = true;
6778 char *restrict newvar = "Another string";
6779
6780 // Check varargs.
6781 test_varargs ("s, d' f .", "string", 65, 34.234);
6782 test_varargs_macros ();
6783
6784 // Check flexible array members.
6785 struct incomplete_array *ia =
6786 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6787 ia->datasize = 10;
6788 for (int i = 0; i < ia->datasize; ++i)
6789 ia->data[i] = i * 1.234;
6790
6791 // Check named initializers.
6792 struct named_init ni = {
6793 .number = 34,
6794 .name = L"Test wide string",
6795 .average = 543.34343,
6796 };
6797
6798 ni.number = 58;
6799
6800 int dynamic_array[ni.number];
6801 dynamic_array[ni.number - 1] = 543;
6802
6803 // work around unused variable warnings
6804 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6805 || dynamic_array[ni.number - 1] != 543);
6806
6807 ;
6808 return 0;
6809 }
6810 _ACEOF
6811 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6812 do
6813 CC="$ac_save_CC $ac_arg"
6814 if ac_fn_c_try_compile "$LINENO"; then :
6815 ac_cv_prog_cc_c99=$ac_arg
6816 fi
6817 rm -f core conftest.err conftest.$ac_objext
6818 test "x$ac_cv_prog_cc_c99" != "xno" && break
6819 done
6820 rm -f conftest.$ac_ext
6821 CC=$ac_save_CC
6822
6823 fi
6824 # AC_CACHE_VAL
6825 case "x$ac_cv_prog_cc_c99" in
6826 x)
6827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6828 $as_echo "none needed" >&6; } ;;
6829 xno)
6830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6831 $as_echo "unsupported" >&6; } ;;
6832 *)
6833 CC="$CC $ac_cv_prog_cc_c99"
6834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6835 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6836 esac
6837 if test "x$ac_cv_prog_cc_c99" != xno; then :
6838 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6839 else
6840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6841 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6842 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6843 $as_echo_n "(cached) " >&6
6844 else
6845 ac_cv_prog_cc_c89=no
6846 ac_save_CC=$CC
6847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6848 /* end confdefs.h. */
6849 #include <stdarg.h>
6850 #include <stdio.h>
6851 #include <sys/types.h>
6852 #include <sys/stat.h>
6853 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6854 struct buf { int x; };
6855 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6856 static char *e (p, i)
6857 char **p;
6858 int i;
6859 {
6860 return p[i];
6861 }
6862 static char *f (char * (*g) (char **, int), char **p, ...)
6863 {
6864 char *s;
6865 va_list v;
6866 va_start (v,p);
6867 s = g (p, va_arg (v,int));
6868 va_end (v);
6869 return s;
6870 }
6871
6872 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6873 function prototypes and stuff, but not '\xHH' hex character constants.
6874 These don't provoke an error unfortunately, instead are silently treated
6875 as 'x'. The following induces an error, until -std is added to get
6876 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6877 array size at least. It's necessary to write '\x00'==0 to get something
6878 that's true only with -std. */
6879 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6880
6881 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6882 inside strings and character constants. */
6883 #define FOO(x) 'x'
6884 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6885
6886 int test (int i, double x);
6887 struct s1 {int (*f) (int a);};
6888 struct s2 {int (*f) (double a);};
6889 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6890 int argc;
6891 char **argv;
6892 int
6893 main ()
6894 {
6895 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6896 ;
6897 return 0;
6898 }
6899 _ACEOF
6900 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6901 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6902 do
6903 CC="$ac_save_CC $ac_arg"
6904 if ac_fn_c_try_compile "$LINENO"; then :
6905 ac_cv_prog_cc_c89=$ac_arg
6906 fi
6907 rm -f core conftest.err conftest.$ac_objext
6908 test "x$ac_cv_prog_cc_c89" != "xno" && break
6909 done
6910 rm -f conftest.$ac_ext
6911 CC=$ac_save_CC
6912
6913 fi
6914 # AC_CACHE_VAL
6915 case "x$ac_cv_prog_cc_c89" in
6916 x)
6917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6918 $as_echo "none needed" >&6; } ;;
6919 xno)
6920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6921 $as_echo "unsupported" >&6; } ;;
6922 *)
6923 CC="$CC $ac_cv_prog_cc_c89"
6924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6925 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6926 esac
6927 if test "x$ac_cv_prog_cc_c89" != xno; then :
6928 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6929 else
6930 ac_cv_prog_cc_stdc=no
6931 fi
6932
6933 fi
6934 ;;
6935 esac
6936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6937 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6938 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6939 $as_echo_n "(cached) " >&6
6940 fi
6941
6942 case $ac_cv_prog_cc_stdc in #(
6943 no) :
6944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6945 $as_echo "unsupported" >&6; } ;; #(
6946 '') :
6947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6948 $as_echo "none needed" >&6; } ;; #(
6949 *) :
6950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6951 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6952 esac
6953
6954
6955
6956 # Code from module alloca-opt:
6957 # Code from module allocator:
6958 # Code from module c-ctype:
6959 # Code from module c-strcase:
6960 # Code from module careadlinkat:
6961 # Code from module clock-time:
6962 # Code from module close-stream:
6963 # Code from module crypto/md5:
6964 # Code from module crypto/sha1:
6965 # Code from module crypto/sha256:
6966 # Code from module crypto/sha512:
6967 # Code from module dosname:
6968 # Code from module dtoastr:
6969 # Code from module dtotimespec:
6970 # Code from module dup2:
6971 # Code from module environ:
6972 # Code from module execinfo:
6973 # Code from module extensions:
6974
6975 # Code from module extern-inline:
6976 # Code from module filemode:
6977 # Code from module fpending:
6978 # Code from module getloadavg:
6979 # Code from module getopt-gnu:
6980 # Code from module getopt-posix:
6981 # Code from module gettext-h:
6982 # Code from module gettime:
6983 # Code from module gettimeofday:
6984 # Code from module ignore-value:
6985 # Code from module include_next:
6986 # Code from module intprops:
6987 # Code from module inttypes-incomplete:
6988 # Code from module largefile:
6989
6990 # Code from module lstat:
6991 # Code from module manywarnings:
6992 # Code from module mktime:
6993 # Code from module multiarch:
6994 # Code from module nocrash:
6995 # Code from module pathmax:
6996 # Code from module pselect:
6997 # Code from module pthread_sigmask:
6998 # Code from module readlink:
6999 # Code from module signal-h:
7000 # Code from module snippet/_Noreturn:
7001 # Code from module snippet/arg-nonnull:
7002 # Code from module snippet/c++defs:
7003 # Code from module snippet/warn-on-use:
7004 # Code from module socklen:
7005 # Code from module ssize_t:
7006 # Code from module stat:
7007 # Code from module stat-time:
7008 # Code from module stdalign:
7009 # Code from module stdarg:
7010
7011
7012
7013 # Code from module stdbool:
7014 # Code from module stddef:
7015 # Code from module stdint:
7016 # Code from module stdio:
7017 # Code from module stdlib:
7018 # Code from module strftime:
7019 # Code from module strtoimax:
7020 # Code from module strtoll:
7021 # Code from module strtoull:
7022 # Code from module strtoumax:
7023 # Code from module symlink:
7024 # Code from module sys_select:
7025 # Code from module sys_stat:
7026 # Code from module sys_time:
7027 # Code from module time:
7028 # Code from module time_r:
7029 # Code from module timer-time:
7030 # Code from module timespec:
7031 # Code from module timespec-add:
7032 # Code from module timespec-sub:
7033 # Code from module u64:
7034 # Code from module unistd:
7035 # Code from module utimens:
7036 # Code from module verify:
7037 # Code from module warnings:
7038
7039
7040 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7041 # if -g3 works and the user does not specify CFLAGS.
7042 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7043 if test "$ac_test_CFLAGS" != set; then
7044 case $CFLAGS in
7045 '-g')
7046 emacs_g3_CFLAGS='-g3';;
7047 '-g -O2')
7048 emacs_g3_CFLAGS='-g3 -O2';;
7049 *)
7050 emacs_g3_CFLAGS='';;
7051 esac
7052 if test -n "$emacs_g3_CFLAGS"; then
7053 emacs_save_CFLAGS=$CFLAGS
7054 CFLAGS=$emacs_g3_CFLAGS
7055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7056 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7057 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7058 $as_echo_n "(cached) " >&6
7059 else
7060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7061 /* end confdefs.h. */
7062
7063 int
7064 main ()
7065 {
7066
7067 ;
7068 return 0;
7069 }
7070 _ACEOF
7071 if ac_fn_c_try_link "$LINENO"; then :
7072 emacs_cv_prog_cc_g3=yes
7073 else
7074 emacs_cv_prog_cc_g3=no
7075 fi
7076 rm -f core conftest.err conftest.$ac_objext \
7077 conftest$ac_exeext conftest.$ac_ext
7078 fi
7079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7080 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7081 if test $emacs_cv_prog_cc_g3 = yes; then
7082 CFLAGS=$emacs_g3_CFLAGS
7083 else
7084 CFLAGS=$emacs_save_CFLAGS
7085 fi
7086 fi
7087 fi
7088
7089 # Check whether --enable-gcc-warnings was given.
7090 if test "${enable_gcc_warnings+set}" = set; then :
7091 enableval=$enable_gcc_warnings; case $enableval in
7092 yes|no) ;;
7093 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7094 esac
7095 gl_gcc_warnings=$enableval
7096 else
7097 gl_gcc_warnings=no
7098
7099 fi
7100
7101
7102 # Check whether --enable-link-time-optimization was given.
7103 if test "${enable_link_time_optimization+set}" = set; then :
7104 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7106 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7107 ac_lto_supported=no
7108 if test x$GCC = xyes; then
7109 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7110 if test x$CPUS != x; then
7111 LTO="-flto=$CPUS"
7112 else
7113 LTO="-flto"
7114 fi
7115 old_CFLAGS=$CFLAGS
7116 CFLAGS="$CFLAGS $LTO"
7117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7118 /* end confdefs.h. */
7119
7120 int
7121 main ()
7122 {
7123
7124 ;
7125 return 0;
7126 }
7127 _ACEOF
7128 if ac_fn_c_try_compile "$LINENO"; then :
7129 ac_lto_supported=yes
7130 else
7131 ac_lto_supported=no
7132 fi
7133 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7134 CFLAGS="$old_CFLAGS"
7135 fi
7136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7137 $as_echo "$ac_lto_supported" >&6; }
7138 if test "$ac_lto_supported" = "yes"; then
7139 CFLAGS="$CFLAGS $LTO"
7140 fi
7141 fi
7142 fi
7143
7144
7145 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7146 # ------------------------------------------------
7147 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7148 # Otherwise, run RUN-IF-NOT-FOUND.
7149
7150
7151 # When compiling with GCC, prefer -isystem to -I when including system
7152 # include files, to avoid generating useless diagnostics for the files.
7153 if test "$gl_gcc_warnings" != yes; then
7154 isystem='-I'
7155 else
7156 isystem='-isystem '
7157
7158 # This, $nw, is the list of warnings we disable.
7159 nw=
7160
7161 case $with_x_toolkit in
7162 lucid | athena | motif)
7163 # Old toolkits mishandle 'const'.
7164 nw="$nw -Wwrite-strings"
7165 ;;
7166 *)
7167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7168 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7169 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7170 $as_echo_n "(cached) " >&6
7171 else
7172
7173 gl_save_compiler_FLAGS="$CFLAGS"
7174 as_fn_append CFLAGS " -Werror"
7175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7176 /* end confdefs.h. */
7177
7178 int
7179 main ()
7180 {
7181
7182 ;
7183 return 0;
7184 }
7185 _ACEOF
7186 if ac_fn_c_try_compile "$LINENO"; then :
7187 gl_cv_warn_c__Werror=yes
7188 else
7189 gl_cv_warn_c__Werror=no
7190 fi
7191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7192 CFLAGS="$gl_save_compiler_FLAGS"
7193
7194 fi
7195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7196 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7197 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7198 as_fn_append WERROR_CFLAGS " -Werror"
7199 fi
7200
7201
7202 ;;
7203 esac
7204
7205
7206 nw="$nw -Waggregate-return" # anachronistic
7207 nw="$nw -Wlong-long" # C90 is anachronistic
7208 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7209 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7210 nw="$nw -Wtraditional" # Warns on #elif which we use often
7211 nw="$nw -Wcast-qual" # Too many warnings for now
7212 nw="$nw -Wconversion" # Too many warnings for now
7213 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7214 nw="$nw -Wsign-conversion" # Too many warnings for now
7215 nw="$nw -Woverlength-strings" # Not a problem these days
7216 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7217 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7218 nw="$nw -Wpadded" # Our structs are not padded
7219 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7220 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7221 nw="$nw -Wformat-nonliteral" # we do this a lot
7222 nw="$nw -Wvla" # warnings in gettext.h
7223 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7224 nw="$nw -Wswitch-enum" # Too many warnings for now
7225 nw="$nw -Wswitch-default" # Too many warnings for now
7226 nw="$nw -Wfloat-equal" # warns about high-quality code
7227 nw="$nw -Winline" # OK to ignore 'inline'
7228 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7229 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7230 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7231
7232 # Emacs doesn't care about shadowing; see
7233 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7234 nw="$nw -Wshadow"
7235
7236 # The following lines should be removable at some point.
7237 nw="$nw -Wstack-protector"
7238 nw="$nw -Wstrict-overflow"
7239 nw="$nw -Wsuggest-attribute=pure"
7240
7241
7242
7243 if test -n "$GCC"; then
7244
7245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7246 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7247 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7248 $as_echo_n "(cached) " >&6
7249 else
7250
7251 gl_save_CFLAGS="$CFLAGS"
7252 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7254 /* end confdefs.h. */
7255
7256 int
7257 main ()
7258 {
7259
7260 ;
7261 return 0;
7262 }
7263 _ACEOF
7264 if ac_fn_c_try_compile "$LINENO"; then :
7265 gl_cv_cc_nomfi_supported=yes
7266 else
7267 gl_cv_cc_nomfi_supported=no
7268 fi
7269 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7270 CFLAGS="$gl_save_CFLAGS"
7271 fi
7272
7273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7274 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7275
7276 if test "$gl_cv_cc_nomfi_supported" = yes; then
7277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7278 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7279 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7280 $as_echo_n "(cached) " >&6
7281 else
7282
7283 gl_save_CFLAGS="$CFLAGS"
7284 CFLAGS="$CFLAGS -W -Werror"
7285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7286 /* end confdefs.h. */
7287 void f (void)
7288 {
7289 typedef struct { int a; int b; } s_t;
7290 s_t s1 = { 0, };
7291 }
7292
7293 int
7294 main ()
7295 {
7296
7297 ;
7298 return 0;
7299 }
7300 _ACEOF
7301 if ac_fn_c_try_compile "$LINENO"; then :
7302 gl_cv_cc_nomfi_needed=no
7303 else
7304 gl_cv_cc_nomfi_needed=yes
7305 fi
7306 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7307 CFLAGS="$gl_save_CFLAGS"
7308
7309 fi
7310
7311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7312 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7313 fi
7314
7315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7316 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7317 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7318 $as_echo_n "(cached) " >&6
7319 else
7320
7321 gl_save_CFLAGS="$CFLAGS"
7322 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7324 /* end confdefs.h. */
7325
7326 int
7327 main ()
7328 {
7329
7330 ;
7331 return 0;
7332 }
7333 _ACEOF
7334 if ac_fn_c_try_compile "$LINENO"; then :
7335 gl_cv_cc_uninitialized_supported=yes
7336 else
7337 gl_cv_cc_uninitialized_supported=no
7338 fi
7339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7340 CFLAGS="$gl_save_CFLAGS"
7341 fi
7342
7343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7344 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7345
7346 fi
7347
7348 # List all gcc warning categories.
7349 gl_manywarn_set=
7350 for gl_manywarn_item in \
7351 -W \
7352 -Wabi \
7353 -Waddress \
7354 -Wall \
7355 -Warray-bounds \
7356 -Wattributes \
7357 -Wbad-function-cast \
7358 -Wbuiltin-macro-redefined \
7359 -Wcast-align \
7360 -Wchar-subscripts \
7361 -Wclobbered \
7362 -Wcomment \
7363 -Wcomments \
7364 -Wcoverage-mismatch \
7365 -Wcpp \
7366 -Wdeprecated \
7367 -Wdeprecated-declarations \
7368 -Wdisabled-optimization \
7369 -Wdiv-by-zero \
7370 -Wdouble-promotion \
7371 -Wempty-body \
7372 -Wendif-labels \
7373 -Wenum-compare \
7374 -Wextra \
7375 -Wformat-contains-nul \
7376 -Wformat-extra-args \
7377 -Wformat-nonliteral \
7378 -Wformat-security \
7379 -Wformat-y2k \
7380 -Wformat-zero-length \
7381 -Wformat=2 \
7382 -Wfree-nonheap-object \
7383 -Wignored-qualifiers \
7384 -Wimplicit \
7385 -Wimplicit-function-declaration \
7386 -Wimplicit-int \
7387 -Winit-self \
7388 -Winline \
7389 -Wint-to-pointer-cast \
7390 -Winvalid-memory-model \
7391 -Winvalid-pch \
7392 -Wjump-misses-init \
7393 -Wlogical-op \
7394 -Wmain \
7395 -Wmaybe-uninitialized \
7396 -Wmissing-braces \
7397 -Wmissing-declarations \
7398 -Wmissing-field-initializers \
7399 -Wmissing-format-attribute \
7400 -Wmissing-include-dirs \
7401 -Wmissing-noreturn \
7402 -Wmissing-parameter-type \
7403 -Wmissing-prototypes \
7404 -Wmudflap \
7405 -Wmultichar \
7406 -Wnarrowing \
7407 -Wnested-externs \
7408 -Wnonnull \
7409 -Wnormalized=nfc \
7410 -Wold-style-declaration \
7411 -Wold-style-definition \
7412 -Woverflow \
7413 -Woverlength-strings \
7414 -Woverride-init \
7415 -Wpacked \
7416 -Wpacked-bitfield-compat \
7417 -Wparentheses \
7418 -Wpointer-arith \
7419 -Wpointer-sign \
7420 -Wpointer-to-int-cast \
7421 -Wpragmas \
7422 -Wreturn-type \
7423 -Wsequence-point \
7424 -Wshadow \
7425 -Wsizeof-pointer-memaccess \
7426 -Wstack-protector \
7427 -Wstrict-aliasing \
7428 -Wstrict-overflow \
7429 -Wstrict-prototypes \
7430 -Wsuggest-attribute=const \
7431 -Wsuggest-attribute=format \
7432 -Wsuggest-attribute=noreturn \
7433 -Wsuggest-attribute=pure \
7434 -Wswitch \
7435 -Wswitch-default \
7436 -Wsync-nand \
7437 -Wsystem-headers \
7438 -Wtrampolines \
7439 -Wtrigraphs \
7440 -Wtype-limits \
7441 -Wuninitialized \
7442 -Wunknown-pragmas \
7443 -Wunreachable-code \
7444 -Wunsafe-loop-optimizations \
7445 -Wunused \
7446 -Wunused-but-set-parameter \
7447 -Wunused-but-set-variable \
7448 -Wunused-function \
7449 -Wunused-label \
7450 -Wunused-local-typedefs \
7451 -Wunused-macros \
7452 -Wunused-parameter \
7453 -Wunused-result \
7454 -Wunused-value \
7455 -Wunused-variable \
7456 -Wvarargs \
7457 -Wvariadic-macros \
7458 -Wvector-operation-performance \
7459 -Wvla \
7460 -Wvolatile-register-var \
7461 -Wwrite-strings \
7462 \
7463 ; do
7464 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7465 done
7466
7467 # Disable specific options as needed.
7468 if test "$gl_cv_cc_nomfi_needed" = yes; then
7469 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7470 fi
7471
7472 if test "$gl_cv_cc_uninitialized_supported" = no; then
7473 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7474 fi
7475
7476 ws=$gl_manywarn_set
7477
7478
7479 gl_warn_set=
7480 set x $ws; shift
7481 for gl_warn_item
7482 do
7483 case " $nw " in
7484 *" $gl_warn_item "*)
7485 ;;
7486 *)
7487 gl_warn_set="$gl_warn_set $gl_warn_item"
7488 ;;
7489 esac
7490 done
7491 ws=$gl_warn_set
7492
7493 for w in $ws; do
7494 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7496 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7497 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7498 $as_echo_n "(cached) " >&6
7499 else
7500
7501 gl_save_compiler_FLAGS="$CFLAGS"
7502 as_fn_append CFLAGS " $w"
7503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7504 /* end confdefs.h. */
7505
7506 int
7507 main ()
7508 {
7509
7510 ;
7511 return 0;
7512 }
7513 _ACEOF
7514 if ac_fn_c_try_compile "$LINENO"; then :
7515 eval "$as_gl_Warn=yes"
7516 else
7517 eval "$as_gl_Warn=no"
7518 fi
7519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7520 CFLAGS="$gl_save_compiler_FLAGS"
7521
7522 fi
7523 eval ac_res=\$$as_gl_Warn
7524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7525 $as_echo "$ac_res" >&6; }
7526 eval as_val=\$$as_gl_Warn
7527 if test "x$as_val" = x""yes; then :
7528 as_fn_append WARN_CFLAGS " $w"
7529 fi
7530
7531
7532 done
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7534 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7535 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7536 $as_echo_n "(cached) " >&6
7537 else
7538
7539 gl_save_compiler_FLAGS="$CFLAGS"
7540 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7542 /* end confdefs.h. */
7543
7544 int
7545 main ()
7546 {
7547
7548 ;
7549 return 0;
7550 }
7551 _ACEOF
7552 if ac_fn_c_try_compile "$LINENO"; then :
7553 gl_cv_warn_c__Wno_missing_field_initializers=yes
7554 else
7555 gl_cv_warn_c__Wno_missing_field_initializers=no
7556 fi
7557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7558 CFLAGS="$gl_save_compiler_FLAGS"
7559
7560 fi
7561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7562 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7563 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7564 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7565 fi
7566
7567 # We need this one
7568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7569 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7570 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7571 $as_echo_n "(cached) " >&6
7572 else
7573
7574 gl_save_compiler_FLAGS="$CFLAGS"
7575 as_fn_append CFLAGS " -Wno-sign-compare"
7576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7577 /* end confdefs.h. */
7578
7579 int
7580 main ()
7581 {
7582
7583 ;
7584 return 0;
7585 }
7586 _ACEOF
7587 if ac_fn_c_try_compile "$LINENO"; then :
7588 gl_cv_warn_c__Wno_sign_compare=yes
7589 else
7590 gl_cv_warn_c__Wno_sign_compare=no
7591 fi
7592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7593 CFLAGS="$gl_save_compiler_FLAGS"
7594
7595 fi
7596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7597 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7598 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7599 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7600 fi
7601
7602 # Too many warnings for now
7603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7604 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7605 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7606 $as_echo_n "(cached) " >&6
7607 else
7608
7609 gl_save_compiler_FLAGS="$CFLAGS"
7610 as_fn_append CFLAGS " -Wno-type-limits"
7611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7612 /* end confdefs.h. */
7613
7614 int
7615 main ()
7616 {
7617
7618 ;
7619 return 0;
7620 }
7621 _ACEOF
7622 if ac_fn_c_try_compile "$LINENO"; then :
7623 gl_cv_warn_c__Wno_type_limits=yes
7624 else
7625 gl_cv_warn_c__Wno_type_limits=no
7626 fi
7627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7628 CFLAGS="$gl_save_compiler_FLAGS"
7629
7630 fi
7631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7632 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7633 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7634 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7635 fi
7636
7637 # Too many warnings for now
7638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7639 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7640 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7641 $as_echo_n "(cached) " >&6
7642 else
7643
7644 gl_save_compiler_FLAGS="$CFLAGS"
7645 as_fn_append CFLAGS " -Wno-switch"
7646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7647 /* end confdefs.h. */
7648
7649 int
7650 main ()
7651 {
7652
7653 ;
7654 return 0;
7655 }
7656 _ACEOF
7657 if ac_fn_c_try_compile "$LINENO"; then :
7658 gl_cv_warn_c__Wno_switch=yes
7659 else
7660 gl_cv_warn_c__Wno_switch=no
7661 fi
7662 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7663 CFLAGS="$gl_save_compiler_FLAGS"
7664
7665 fi
7666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7667 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7668 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7669 as_fn_append WARN_CFLAGS " -Wno-switch"
7670 fi
7671
7672 # Too many warnings for now
7673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7674 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7675 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7676 $as_echo_n "(cached) " >&6
7677 else
7678
7679 gl_save_compiler_FLAGS="$CFLAGS"
7680 as_fn_append CFLAGS " -Wno-unused-parameter"
7681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7682 /* end confdefs.h. */
7683
7684 int
7685 main ()
7686 {
7687
7688 ;
7689 return 0;
7690 }
7691 _ACEOF
7692 if ac_fn_c_try_compile "$LINENO"; then :
7693 gl_cv_warn_c__Wno_unused_parameter=yes
7694 else
7695 gl_cv_warn_c__Wno_unused_parameter=no
7696 fi
7697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7698 CFLAGS="$gl_save_compiler_FLAGS"
7699
7700 fi
7701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7702 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7703 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7704 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7705 fi
7706
7707 # Too many warnings for now
7708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7709 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7710 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7711 $as_echo_n "(cached) " >&6
7712 else
7713
7714 gl_save_compiler_FLAGS="$CFLAGS"
7715 as_fn_append CFLAGS " -Wno-format-nonliteral"
7716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7717 /* end confdefs.h. */
7718
7719 int
7720 main ()
7721 {
7722
7723 ;
7724 return 0;
7725 }
7726 _ACEOF
7727 if ac_fn_c_try_compile "$LINENO"; then :
7728 gl_cv_warn_c__Wno_format_nonliteral=yes
7729 else
7730 gl_cv_warn_c__Wno_format_nonliteral=no
7731 fi
7732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7733 CFLAGS="$gl_save_compiler_FLAGS"
7734
7735 fi
7736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7737 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7738 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7739 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7740 fi
7741
7742
7743
7744 # In spite of excluding -Wlogical-op above, it is enabled, as of
7745 # gcc 4.5.0 20090517.
7746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7747 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7748 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7749 $as_echo_n "(cached) " >&6
7750 else
7751
7752 gl_save_compiler_FLAGS="$CFLAGS"
7753 as_fn_append CFLAGS " -Wno-logical-op"
7754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7755 /* end confdefs.h. */
7756
7757 int
7758 main ()
7759 {
7760
7761 ;
7762 return 0;
7763 }
7764 _ACEOF
7765 if ac_fn_c_try_compile "$LINENO"; then :
7766 gl_cv_warn_c__Wno_logical_op=yes
7767 else
7768 gl_cv_warn_c__Wno_logical_op=no
7769 fi
7770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7771 CFLAGS="$gl_save_compiler_FLAGS"
7772
7773 fi
7774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7775 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7776 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7777 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7778 fi
7779
7780
7781
7782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7783 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7784 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7785 $as_echo_n "(cached) " >&6
7786 else
7787
7788 gl_save_compiler_FLAGS="$CFLAGS"
7789 as_fn_append CFLAGS " -fdiagnostics-show-option"
7790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7791 /* end confdefs.h. */
7792
7793 int
7794 main ()
7795 {
7796
7797 ;
7798 return 0;
7799 }
7800 _ACEOF
7801 if ac_fn_c_try_compile "$LINENO"; then :
7802 gl_cv_warn_c__fdiagnostics_show_option=yes
7803 else
7804 gl_cv_warn_c__fdiagnostics_show_option=no
7805 fi
7806 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7807 CFLAGS="$gl_save_compiler_FLAGS"
7808
7809 fi
7810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7811 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7812 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7813 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7814 fi
7815
7816
7817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7818 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7819 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7820 $as_echo_n "(cached) " >&6
7821 else
7822
7823 gl_save_compiler_FLAGS="$CFLAGS"
7824 as_fn_append CFLAGS " -funit-at-a-time"
7825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7826 /* end confdefs.h. */
7827
7828 int
7829 main ()
7830 {
7831
7832 ;
7833 return 0;
7834 }
7835 _ACEOF
7836 if ac_fn_c_try_compile "$LINENO"; then :
7837 gl_cv_warn_c__funit_at_a_time=yes
7838 else
7839 gl_cv_warn_c__funit_at_a_time=no
7840 fi
7841 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7842 CFLAGS="$gl_save_compiler_FLAGS"
7843
7844 fi
7845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7846 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7847 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7848 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7849 fi
7850
7851
7852
7853
7854 $as_echo "#define lint 1" >>confdefs.h
7855
7856
7857
7858 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7859
7860
7861 # We use a slightly smaller set of warning options for lib/.
7862 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7863 nw=
7864 nw="$nw -Wunused-macros"
7865
7866
7867 gl_warn_set=
7868 set x $WARN_CFLAGS; shift
7869 for gl_warn_item
7870 do
7871 case " $nw " in
7872 *" $gl_warn_item "*)
7873 ;;
7874 *)
7875 gl_warn_set="$gl_warn_set $gl_warn_item"
7876 ;;
7877 esac
7878 done
7879 GNULIB_WARN_CFLAGS=$gl_warn_set
7880
7881
7882 fi
7883
7884
7885
7886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7887 $as_echo_n "checking whether ln -s works... " >&6; }
7888 LN_S=$as_ln_s
7889 if test "$LN_S" = "ln -s"; then
7890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7891 $as_echo "yes" >&6; }
7892 else
7893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7894 $as_echo "no, using $LN_S" >&6; }
7895 fi
7896
7897
7898 # Extract the first word of "install-info", so it can be a program name with args.
7899 set dummy install-info; ac_word=$2
7900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7901 $as_echo_n "checking for $ac_word... " >&6; }
7902 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7903 $as_echo_n "(cached) " >&6
7904 else
7905 case $INSTALL_INFO in
7906 [\\/]* | ?:[\\/]*)
7907 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7908 ;;
7909 *)
7910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7911 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7912 do
7913 IFS=$as_save_IFS
7914 test -z "$as_dir" && as_dir=.
7915 for ac_exec_ext in '' $ac_executable_extensions; do
7916 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7917 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7918 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7919 break 2
7920 fi
7921 done
7922 done
7923 IFS=$as_save_IFS
7924
7925 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7926 ;;
7927 esac
7928 fi
7929 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7930 if test -n "$INSTALL_INFO"; then
7931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7932 $as_echo "$INSTALL_INFO" >&6; }
7933 else
7934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7935 $as_echo "no" >&6; }
7936 fi
7937
7938
7939 # Extract the first word of "gzip", so it can be a program name with args.
7940 set dummy gzip; ac_word=$2
7941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7942 $as_echo_n "checking for $ac_word... " >&6; }
7943 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7944 $as_echo_n "(cached) " >&6
7945 else
7946 case $GZIP_PROG in
7947 [\\/]* | ?:[\\/]*)
7948 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7949 ;;
7950 *)
7951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7952 for as_dir in $PATH
7953 do
7954 IFS=$as_save_IFS
7955 test -z "$as_dir" && as_dir=.
7956 for ac_exec_ext in '' $ac_executable_extensions; do
7957 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7958 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7959 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7960 break 2
7961 fi
7962 done
7963 done
7964 IFS=$as_save_IFS
7965
7966 ;;
7967 esac
7968 fi
7969 GZIP_PROG=$ac_cv_path_GZIP_PROG
7970 if test -n "$GZIP_PROG"; then
7971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7972 $as_echo "$GZIP_PROG" >&6; }
7973 else
7974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7975 $as_echo "no" >&6; }
7976 fi
7977
7978
7979
7980 if test $opsys = gnu-linux; then
7981 # Extract the first word of "paxctl", so it can be a program name with args.
7982 set dummy paxctl; ac_word=$2
7983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7984 $as_echo_n "checking for $ac_word... " >&6; }
7985 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7986 $as_echo_n "(cached) " >&6
7987 else
7988 case $PAXCTL in
7989 [\\/]* | ?:[\\/]*)
7990 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7991 ;;
7992 *)
7993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7994 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7995 do
7996 IFS=$as_save_IFS
7997 test -z "$as_dir" && as_dir=.
7998 for ac_exec_ext in '' $ac_executable_extensions; do
7999 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8000 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8001 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8002 break 2
8003 fi
8004 done
8005 done
8006 IFS=$as_save_IFS
8007
8008 ;;
8009 esac
8010 fi
8011 PAXCTL=$ac_cv_path_PAXCTL
8012 if test -n "$PAXCTL"; then
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8014 $as_echo "$PAXCTL" >&6; }
8015 else
8016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8017 $as_echo "no" >&6; }
8018 fi
8019
8020
8021 if test "X$PAXCTL" != X; then
8022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8023 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8025 /* end confdefs.h. */
8026
8027 int
8028 main ()
8029 {
8030
8031 ;
8032 return 0;
8033 }
8034 _ACEOF
8035 if ac_fn_c_try_link "$LINENO"; then :
8036 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8037 $as_echo "yes" >&6; }
8038 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8039 $as_echo "no" >&6; }; PAXCTL=""; fi
8040 fi
8041 rm -f core conftest.err conftest.$ac_objext \
8042 conftest$ac_exeext conftest.$ac_ext
8043 fi
8044 fi
8045
8046 ## Need makeinfo >= 4.7 (?) to build the manuals.
8047 # Extract the first word of "makeinfo", so it can be a program name with args.
8048 set dummy makeinfo; ac_word=$2
8049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8050 $as_echo_n "checking for $ac_word... " >&6; }
8051 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8052 $as_echo_n "(cached) " >&6
8053 else
8054 case $MAKEINFO in
8055 [\\/]* | ?:[\\/]*)
8056 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8057 ;;
8058 *)
8059 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8060 for as_dir in $PATH
8061 do
8062 IFS=$as_save_IFS
8063 test -z "$as_dir" && as_dir=.
8064 for ac_exec_ext in '' $ac_executable_extensions; do
8065 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8066 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8068 break 2
8069 fi
8070 done
8071 done
8072 IFS=$as_save_IFS
8073
8074 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8075 ;;
8076 esac
8077 fi
8078 MAKEINFO=$ac_cv_path_MAKEINFO
8079 if test -n "$MAKEINFO"; then
8080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8081 $as_echo "$MAKEINFO" >&6; }
8082 else
8083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8084 $as_echo "no" >&6; }
8085 fi
8086
8087
8088 if test "$MAKEINFO" != "no" && \
8089 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
8090 MAKEINFO=no
8091 fi
8092
8093 ## Makeinfo is unusual. For a released Emacs, the manuals are
8094 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8095 ## therefore in the category of "special tools" not normally required, which
8096 ## configure does not have to check for (eg autoconf itself).
8097 ## In a Bazaar checkout on the other hand, the manuals are not included.
8098 ## So makeinfo is a requirement to build from Bazaar, and configure
8099 ## should test for it as it does for any other build requirement.
8100 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8101 ## with pre-built manuals, from a Bazaar checkout.
8102 HAVE_MAKEINFO=yes
8103
8104 if test "$MAKEINFO" = "no"; then
8105 MAKEINFO=makeinfo
8106 if test "x${with_makeinfo}" = "xno"; then
8107 HAVE_MAKEINFO=no
8108 elif test ! -e $srcdir/info/emacs; then
8109 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8110 source tree does not seem to have pre-built manuals in the \`info' directory.
8111 Either install a suitable version of makeinfo, or re-run configure
8112 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8113 fi
8114 fi
8115
8116
8117 INFO_EXT=.info
8118 INFO_OPTS=--no-split
8119
8120
8121
8122
8123 if test x$GCC = xyes; then
8124 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8125 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8126 else
8127 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8128 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8129 fi
8130
8131
8132 late_LDFLAGS=$LDFLAGS
8133 if test x$GCC = xyes; then
8134 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8135 else
8136 LDFLAGS="$LDFLAGS -znocombreloc"
8137 fi
8138
8139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8140 $as_echo_n "checking for -znocombreloc... " >&6; }
8141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8142 /* end confdefs.h. */
8143
8144 int
8145 main ()
8146 {
8147
8148 ;
8149 return 0;
8150 }
8151 _ACEOF
8152 if ac_fn_c_try_link "$LINENO"; then :
8153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8154 $as_echo "yes" >&6; }
8155 else
8156 LDFLAGS=$late_LDFLAGS
8157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8158 $as_echo "no" >&6; }
8159 fi
8160 rm -f core conftest.err conftest.$ac_objext \
8161 conftest$ac_exeext conftest.$ac_ext
8162
8163
8164 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8165 case "$opsys" in
8166 your-opsys-here) CANNOT_DUMP=yes ;;
8167 esac
8168
8169 test "$CANNOT_DUMP" = "yes" && \
8170
8171 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8172
8173
8174
8175
8176
8177 UNEXEC_OBJ=unexelf.o
8178 case "$opsys" in
8179 # MSDOS uses unexcoff.o
8180 # MSWindows uses unexw32.o
8181 aix4-2)
8182 UNEXEC_OBJ=unexaix.o
8183 ;;
8184 cygwin)
8185 UNEXEC_OBJ=unexcw.o
8186 ;;
8187 darwin)
8188 UNEXEC_OBJ=unexmacosx.o
8189 ;;
8190 hpux10-20 | hpux11)
8191 UNEXEC_OBJ=unexhp9k800.o
8192 ;;
8193 sol2-10)
8194 # Use the Solaris dldump() function, called from unexsol.c, to dump
8195 # emacs, instead of the generic ELF dump code found in unexelf.c.
8196 # The resulting binary has a complete symbol table, and is better
8197 # for debugging and other observability tools (debuggers, pstack, etc).
8198 #
8199 # If you encounter a problem using dldump(), please consider sending
8200 # a message to the OpenSolaris tools-linking mailing list:
8201 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8202 #
8203 # It is likely that dldump() works with older Solaris too, but this has
8204 # not been tested, so for now this change is for Solaris 10 or newer.
8205 UNEXEC_OBJ=unexsol.o
8206 ;;
8207 esac
8208
8209 LD_SWITCH_SYSTEM=
8210 case "$opsys" in
8211 freebsd)
8212 ## Let `ld' find image libs and similar things in /usr/local/lib.
8213 ## The system compiler, GCC, has apparently been modified to not
8214 ## look there, contrary to what a stock GCC would do.
8215 ### It's not our place to do this. See bug#10313#17.
8216 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8217 :
8218 ;;
8219
8220 gnu-linux)
8221 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8222 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8223 ;;
8224
8225 netbsd)
8226 ### It's not our place to do this. See bug#10313#17.
8227 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8228 :
8229 ;;
8230
8231 openbsd)
8232 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8233 ## otherwise Emacs dumps core on elf systems.
8234 LD_SWITCH_SYSTEM="-Z"
8235 ;;
8236 esac
8237
8238
8239 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8240
8241 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8242 ## which has not been defined yet. When this was handled with cpp,
8243 ## it was expanded to null when configure sourced the s/*.h file.
8244 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8245 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8246 ## (or somesuch), but because it is supposed to go at the _front_
8247 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8248 ## Compare with the gnu-linux case below, which added to the end
8249 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8250 ## LD_SWITCH_SYSTEM_TEMACS.
8251 case "$opsys" in
8252 netbsd|openbsd)
8253 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8254 esac
8255
8256
8257 C_SWITCH_MACHINE=
8258 case $canonical in
8259 alpha*)
8260 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8261 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8262
8263 fi
8264
8265 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8266 ## With ELF, make sure that all common symbols get allocated to in the
8267 ## data section. Otherwise, the dump of temacs may miss variables in
8268 ## the shared library that have been initialized. For example, with
8269 ## GNU libc, __malloc_initialized would normally be resolved to the
8270 ## shared library's .bss section, which is fatal.
8271 if test "x$GCC" = "xyes"; then
8272 C_SWITCH_MACHINE="-fno-common"
8273 else
8274 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8275 fi
8276 else
8277 UNEXEC_OBJ=unexalpha.o
8278 fi
8279 ;;
8280 esac
8281
8282
8283
8284
8285 C_SWITCH_SYSTEM=
8286 ## Some programs in src produce warnings saying certain subprograms
8287 ## are too complex and need a MAXMEM value greater than 2000 for
8288 ## additional optimization. --nils@exp-math.uni-essen.de
8289 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8290 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8291 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8292 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8293
8294
8295
8296 LIBS_SYSTEM=
8297 case "$opsys" in
8298 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8299 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8300
8301 freebsd) LIBS_SYSTEM="-lutil" ;;
8302
8303 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8304
8305 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8306
8307 ## Motif needs -lgen.
8308 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8309 esac
8310
8311
8312
8313 ### Make sure subsequent tests use flags consistent with the build flags.
8314
8315 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8316 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8317 else
8318 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8319 fi
8320
8321 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8322
8323 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8324
8325
8326
8327 LIB_MATH=-lm
8328 LIB_STANDARD=
8329 START_FILES=
8330 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8331
8332 case $opsys in
8333 cygwin )
8334 LIB_MATH=
8335 START_FILES='pre-crt0.o'
8336 ;;
8337 darwin )
8338 ## Adding -lm confuses the dynamic linker, so omit it.
8339 LIB_MATH=
8340 START_FILES='pre-crt0.o'
8341 ;;
8342 freebsd )
8343 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8344 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8345 SYSTEM_TYPE=berkeley-unix
8346 ;;
8347 gnu-linux | gnu-kfreebsd )
8348 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8349 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8350 ;;
8351 hpux10-20 | hpux11 )
8352 LIB_STANDARD=-lc
8353 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8354 ;;
8355 netbsd | openbsd )
8356 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8357 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8358 SYSTEM_TYPE=berkeley-unix
8359 ;;
8360
8361 sol2* | unixware )
8362 SYSTEM_TYPE=usg-unix-v
8363 ;;
8364
8365 esac
8366
8367
8368
8369
8370 cat >>confdefs.h <<_ACEOF
8371 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8372 _ACEOF
8373
8374
8375 crt_files=
8376
8377 for file in x $LIB_STANDARD $START_FILES; do
8378 case "$file" in
8379 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8380 esac
8381 done
8382
8383 if test "x$crt_files" != x; then
8384
8385 ## If user specified a crt-dir, use that unconditionally.
8386 crt_gcc=no
8387
8388 if test "X$CRT_DIR" = "X"; then
8389
8390 CRT_DIR=/usr/lib # default
8391
8392 case "$canonical" in
8393 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8394 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8395 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8396 ## For anything else (eg /usr/lib32), it is up the user to specify
8397 ## the location (bug#5655).
8398 ## Test for crtn.o, not just the directory, because sometimes the
8399 ## directory exists but does not have the relevant files (bug#1287).
8400 ## FIXME better to test for binary compatibility somehow.
8401 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8402 ;;
8403
8404 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8405 esac
8406
8407 case "$opsys" in
8408 hpux10-20) CRT_DIR=/lib ;;
8409 esac
8410
8411 test "x${GCC}" = xyes && crt_gcc=yes
8412
8413 fi # CRT_DIR = ""
8414
8415 crt_missing=
8416
8417 for file in $crt_files; do
8418
8419 ## If we're using gcc, try to determine it automatically by asking
8420 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8421 ## system-dependent default from above.]
8422 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8423
8424 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8425 case "$crt_file" in
8426 */*)
8427 CRT_DIR=`$as_dirname -- "$crt_file" ||
8428 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8429 X"$crt_file" : 'X\(//\)[^/]' \| \
8430 X"$crt_file" : 'X\(//\)$' \| \
8431 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8432 $as_echo X"$crt_file" |
8433 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8434 s//\1/
8435 q
8436 }
8437 /^X\(\/\/\)[^/].*/{
8438 s//\1/
8439 q
8440 }
8441 /^X\(\/\/\)$/{
8442 s//\1/
8443 q
8444 }
8445 /^X\(\/\).*/{
8446 s//\1/
8447 q
8448 }
8449 s/.*/./; q'`
8450 ;;
8451 esac
8452 fi
8453
8454 crt_gcc=no
8455
8456 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8457 done # $crt_files
8458
8459 test "x$crt_missing" = x || \
8460 as_fn_error "Required file(s) not found:$crt_missing
8461 Try using the --with-crt-dir option." "$LINENO" 5
8462
8463 fi # crt_files != ""
8464
8465
8466
8467 case $opsys in
8468 netbsd | openbsd )
8469 if test -f $CRT_DIR/crti.o; then
8470
8471 test -f $CRT_DIR/crtn.o || \
8472 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8473
8474 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8475 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8476 fi
8477 ;;
8478 esac
8479
8480
8481 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8482 pre_PKG_CONFIG_LIBS=$LIBS
8483
8484 # Extract the first word of "pkg-config", so it can be a program name with args.
8485 set dummy pkg-config; ac_word=$2
8486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8487 $as_echo_n "checking for $ac_word... " >&6; }
8488 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8489 $as_echo_n "(cached) " >&6
8490 else
8491 case $PKG_CONFIG in
8492 [\\/]* | ?:[\\/]*)
8493 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8494 ;;
8495 *)
8496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8497 for as_dir in $PATH
8498 do
8499 IFS=$as_save_IFS
8500 test -z "$as_dir" && as_dir=.
8501 for ac_exec_ext in '' $ac_executable_extensions; do
8502 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8503 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8505 break 2
8506 fi
8507 done
8508 done
8509 IFS=$as_save_IFS
8510
8511 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8512 ;;
8513 esac
8514 fi
8515 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8516 if test -n "$PKG_CONFIG"; then
8517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8518 $as_echo "$PKG_CONFIG" >&6; }
8519 else
8520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8521 $as_echo "no" >&6; }
8522 fi
8523
8524
8525
8526
8527
8528
8529 if test "${with_sound}" != "no"; then
8530 # Sound support for GNU/Linux and the free BSDs.
8531 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8532 do :
8533 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8534 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8535 eval as_val=\$$as_ac_Header
8536 if test "x$as_val" = x""yes; then :
8537 cat >>confdefs.h <<_ACEOF
8538 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8539 _ACEOF
8540 have_sound_header=yes
8541 fi
8542
8543 done
8544
8545 # Emulation library used on NetBSD.
8546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8547 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8548 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8549 $as_echo_n "(cached) " >&6
8550 else
8551 ac_check_lib_save_LIBS=$LIBS
8552 LIBS="-lossaudio $LIBS"
8553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8554 /* end confdefs.h. */
8555
8556 /* Override any GCC internal prototype to avoid an error.
8557 Use char because int might match the return type of a GCC
8558 builtin and then its argument prototype would still apply. */
8559 #ifdef __cplusplus
8560 extern "C"
8561 #endif
8562 char _oss_ioctl ();
8563 int
8564 main ()
8565 {
8566 return _oss_ioctl ();
8567 ;
8568 return 0;
8569 }
8570 _ACEOF
8571 if ac_fn_c_try_link "$LINENO"; then :
8572 ac_cv_lib_ossaudio__oss_ioctl=yes
8573 else
8574 ac_cv_lib_ossaudio__oss_ioctl=no
8575 fi
8576 rm -f core conftest.err conftest.$ac_objext \
8577 conftest$ac_exeext conftest.$ac_ext
8578 LIBS=$ac_check_lib_save_LIBS
8579 fi
8580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8581 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8582 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8583 LIBSOUND=-lossaudio
8584 else
8585 LIBSOUND=
8586 fi
8587
8588
8589
8590 ALSA_REQUIRED=1.0.0
8591 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8592
8593 succeeded=no
8594
8595 if test "$PKG_CONFIG" = "no" ; then
8596 HAVE_ALSA=no
8597 else
8598 PKG_CONFIG_MIN_VERSION=0.9.0
8599 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8601 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8602
8603 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8604 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8605 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8606 edit_cflags="
8607 s,///*,/,g
8608 s/^/ /
8609 s/ -I/ $isystem/g
8610 s/^ //
8611 "
8612 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8613 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8615 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8616 succeeded=yes
8617 else
8618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8619 $as_echo "no" >&6; }
8620 ALSA_CFLAGS=""
8621 ALSA_LIBS=""
8622 ## If we have a custom action on failure, don't print errors, but
8623 ## do set a variable so people can do so. Do it in a subshell
8624 ## to capture any diagnostics in invoking pkg-config.
8625 ALSA_PKG_ERRORS=`($PKG_CONFIG --print-errors "$ALSA_MODULES") 2>&1`
8626
8627 fi
8628
8629
8630
8631 else
8632 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8633 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8634 fi
8635 fi
8636
8637 if test $succeeded = yes; then
8638 HAVE_ALSA=yes
8639 else
8640 HAVE_ALSA=no
8641 fi
8642
8643 if test $HAVE_ALSA = yes; then
8644 SAVE_CFLAGS="$CFLAGS"
8645 SAVE_LIBS="$LIBS"
8646 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8647 LIBS="$ALSA_LIBS $LIBS"
8648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8649 /* end confdefs.h. */
8650 #include <asoundlib.h>
8651 int
8652 main ()
8653 {
8654 snd_lib_error_set_handler (0);
8655 ;
8656 return 0;
8657 }
8658 _ACEOF
8659 if ac_fn_c_try_compile "$LINENO"; then :
8660 emacs_alsa_normal=yes
8661 else
8662 emacs_alsa_normal=no
8663 fi
8664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8665 if test "$emacs_alsa_normal" != yes; then
8666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8667 /* end confdefs.h. */
8668 #include <alsa/asoundlib.h>
8669 int
8670 main ()
8671 {
8672 snd_lib_error_set_handler (0);
8673 ;
8674 return 0;
8675 }
8676 _ACEOF
8677 if ac_fn_c_try_compile "$LINENO"; then :
8678 emacs_alsa_subdir=yes
8679 else
8680 emacs_alsa_subdir=no
8681 fi
8682 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8683 if test "$emacs_alsa_subdir" != yes; then
8684 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8685 fi
8686 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8687 fi
8688
8689 CFLAGS="$SAVE_CFLAGS"
8690 LIBS="$SAVE_LIBS"
8691 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8692 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8693
8694 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8695
8696 fi
8697
8698 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8699 case "$opsys" in
8700 gnu-linux|freebsd|netbsd)
8701
8702 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8703
8704 ;;
8705 esac
8706 fi
8707
8708
8709 fi
8710
8711
8712
8713
8714 for ac_header in $ac_header_list
8715 do :
8716 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8717 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8718 "
8719 eval as_val=\$$as_ac_Header
8720 if test "x$as_val" = x""yes; then :
8721 cat >>confdefs.h <<_ACEOF
8722 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8723 _ACEOF
8724
8725 fi
8726
8727 done
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
8755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8756 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8758 /* end confdefs.h. */
8759 #include <sys/personality.h>
8760 int
8761 main ()
8762 {
8763 personality (PER_LINUX32)
8764 ;
8765 return 0;
8766 }
8767 _ACEOF
8768 if ac_fn_c_try_compile "$LINENO"; then :
8769 emacs_cv_personality_linux32=yes
8770 else
8771 emacs_cv_personality_linux32=no
8772 fi
8773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8775 $as_echo "$emacs_cv_personality_linux32" >&6; }
8776
8777 if test $emacs_cv_personality_linux32 = yes; then
8778
8779 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8780
8781 fi
8782
8783 for ac_header in term.h
8784 do :
8785 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8786 if test "x$ac_cv_header_term_h" = x""yes; then :
8787 cat >>confdefs.h <<_ACEOF
8788 #define HAVE_TERM_H 1
8789 _ACEOF
8790
8791 fi
8792
8793 done
8794
8795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8796 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8797 if test "${ac_cv_header_time+set}" = set; then :
8798 $as_echo_n "(cached) " >&6
8799 else
8800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8801 /* end confdefs.h. */
8802 #include <sys/types.h>
8803 #include <sys/time.h>
8804 #include <time.h>
8805
8806 int
8807 main ()
8808 {
8809 if ((struct tm *) 0)
8810 return 0;
8811 ;
8812 return 0;
8813 }
8814 _ACEOF
8815 if ac_fn_c_try_compile "$LINENO"; then :
8816 ac_cv_header_time=yes
8817 else
8818 ac_cv_header_time=no
8819 fi
8820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8821 fi
8822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8823 $as_echo "$ac_cv_header_time" >&6; }
8824 if test $ac_cv_header_time = yes; then
8825
8826 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8827
8828 fi
8829
8830 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
8831
8832 "
8833 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8834 ac_have_decl=1
8835 else
8836 ac_have_decl=0
8837 fi
8838
8839 cat >>confdefs.h <<_ACEOF
8840 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8841 _ACEOF
8842
8843 if test $ac_cv_have_decl_sys_siglist != yes; then
8844 # For Tru64, at least:
8845 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
8846
8847 "
8848 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8849 ac_have_decl=1
8850 else
8851 ac_have_decl=0
8852 fi
8853
8854 cat >>confdefs.h <<_ACEOF
8855 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8856 _ACEOF
8857
8858 if test $ac_cv_have_decl___sys_siglist = yes; then
8859
8860 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8861
8862 fi
8863 fi
8864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8865 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8866 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8867 $as_echo_n "(cached) " >&6
8868 else
8869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8870 /* end confdefs.h. */
8871 #include <sys/types.h>
8872 #include <sys/wait.h>
8873 #ifndef WEXITSTATUS
8874 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8875 #endif
8876 #ifndef WIFEXITED
8877 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8878 #endif
8879
8880 int
8881 main ()
8882 {
8883 int s;
8884 wait (&s);
8885 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8886 ;
8887 return 0;
8888 }
8889 _ACEOF
8890 if ac_fn_c_try_compile "$LINENO"; then :
8891 ac_cv_header_sys_wait_h=yes
8892 else
8893 ac_cv_header_sys_wait_h=no
8894 fi
8895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8896 fi
8897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8898 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8899 if test $ac_cv_header_sys_wait_h = yes; then
8900
8901 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8902
8903 fi
8904
8905
8906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8907 $as_echo_n "checking for speed_t... " >&6; }
8908 if test "${emacs_cv_speed_t+set}" = set; then :
8909 $as_echo_n "(cached) " >&6
8910 else
8911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8912 /* end confdefs.h. */
8913 #include <termios.h>
8914 int
8915 main ()
8916 {
8917 speed_t x = 1;
8918 ;
8919 return 0;
8920 }
8921 _ACEOF
8922 if ac_fn_c_try_compile "$LINENO"; then :
8923 emacs_cv_speed_t=yes
8924 else
8925 emacs_cv_speed_t=no
8926 fi
8927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8928 fi
8929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8930 $as_echo "$emacs_cv_speed_t" >&6; }
8931 if test $emacs_cv_speed_t = yes; then
8932
8933 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8934
8935 fi
8936
8937
8938
8939
8940 for ac_header in net/if.h
8941 do :
8942 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8943 #if HAVE_SYS_SOCKET_H
8944 #include <sys/socket.h>
8945 #endif
8946 "
8947 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8948 cat >>confdefs.h <<_ACEOF
8949 #define HAVE_NET_IF_H 1
8950 _ACEOF
8951
8952 fi
8953
8954 done
8955
8956 for ac_header in ifaddrs.h
8957 do :
8958 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8959 #if HAVE_SYS_SOCKET_H
8960 #include <sys/socket.h>
8961 #endif
8962 "
8963 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8964 cat >>confdefs.h <<_ACEOF
8965 #define HAVE_IFADDRS_H 1
8966 _ACEOF
8967
8968 fi
8969
8970 done
8971
8972 for ac_header in net/if_dl.h
8973 do :
8974 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8975 #if HAVE_SYS_SOCKET_H
8976 #include <sys/socket.h>
8977 #endif
8978 "
8979 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8980 cat >>confdefs.h <<_ACEOF
8981 #define HAVE_NET_IF_DL_H 1
8982 _ACEOF
8983
8984 fi
8985
8986 done
8987
8988
8989 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8990 #if HAVE_SYS_SOCKET_H
8991 #include <sys/socket.h>
8992 #endif
8993 #if HAVE_NET_IF_H
8994 #include <net/if.h>
8995 #endif
8996 "
8997 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8998
8999 cat >>confdefs.h <<_ACEOF
9000 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9001 _ACEOF
9002
9003
9004 fi
9005 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9006 #if HAVE_SYS_SOCKET_H
9007 #include <sys/socket.h>
9008 #endif
9009 #if HAVE_NET_IF_H
9010 #include <net/if.h>
9011 #endif
9012 "
9013 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9014
9015 cat >>confdefs.h <<_ACEOF
9016 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9017 _ACEOF
9018
9019
9020 fi
9021 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9022 #if HAVE_SYS_SOCKET_H
9023 #include <sys/socket.h>
9024 #endif
9025 #if HAVE_NET_IF_H
9026 #include <net/if.h>
9027 #endif
9028 "
9029 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9030
9031 cat >>confdefs.h <<_ACEOF
9032 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9033 _ACEOF
9034
9035
9036 fi
9037 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9038 #if HAVE_SYS_SOCKET_H
9039 #include <sys/socket.h>
9040 #endif
9041 #if HAVE_NET_IF_H
9042 #include <net/if.h>
9043 #endif
9044 "
9045 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9046
9047 cat >>confdefs.h <<_ACEOF
9048 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9049 _ACEOF
9050
9051
9052 fi
9053 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9054 #if HAVE_SYS_SOCKET_H
9055 #include <sys/socket.h>
9056 #endif
9057 #if HAVE_NET_IF_H
9058 #include <net/if.h>
9059 #endif
9060 "
9061 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9062
9063 cat >>confdefs.h <<_ACEOF
9064 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9065 _ACEOF
9066
9067
9068 fi
9069 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9070 #if HAVE_SYS_SOCKET_H
9071 #include <sys/socket.h>
9072 #endif
9073 #if HAVE_NET_IF_H
9074 #include <net/if.h>
9075 #endif
9076 "
9077 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9078
9079 cat >>confdefs.h <<_ACEOF
9080 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9081 _ACEOF
9082
9083
9084 fi
9085
9086
9087
9088
9089 DEPFLAGS=
9090 MKDEPDIR=":"
9091 deps_frag=deps.mk
9092 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9094 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9095 HAVE_GNU_MAKE=no
9096 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9097 if test "x$testval" != x; then
9098 HAVE_GNU_MAKE=yes
9099 else
9100 ac_enable_autodepend=no
9101 fi
9102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9103 $as_echo "$HAVE_GNU_MAKE" >&6; }
9104 if test $HAVE_GNU_MAKE = yes; then
9105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9106 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9107 SAVE_CFLAGS="$CFLAGS"
9108 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9110 /* end confdefs.h. */
9111
9112 int
9113 main ()
9114 {
9115
9116 ;
9117 return 0;
9118 }
9119 _ACEOF
9120 if ac_fn_c_try_compile "$LINENO"; then :
9121
9122 else
9123 ac_enable_autodepend=no
9124 fi
9125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9126 CFLAGS="$SAVE_CFLAGS"
9127 test -f deps.d || ac_enable_autodepend=no
9128 rm -rf deps.d
9129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9130 $as_echo "$ac_enable_autodepend" >&6; }
9131 fi
9132 if test $ac_enable_autodepend = yes; then
9133 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9134 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9135 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9136 deps_frag=autodeps.mk
9137 fi
9138 fi
9139 deps_frag=$srcdir/src/$deps_frag
9140
9141
9142
9143
9144
9145 lisp_frag=$srcdir/src/lisp.mk
9146
9147
9148
9149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9150 $as_echo_n "checking for long file names... " >&6; }
9151 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9152 $as_echo_n "(cached) " >&6
9153 else
9154 ac_cv_sys_long_file_names=yes
9155 # Test for long file names in all the places we know might matter:
9156 # . the current directory, where building will happen
9157 # $prefix/lib where we will be installing things
9158 # $exec_prefix/lib likewise
9159 # $TMPDIR if set, where it might want to write temporary files
9160 # /tmp where it might want to write temporary files
9161 # /var/tmp likewise
9162 # /usr/tmp likewise
9163 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9164 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9165 # in the usual case where exec_prefix is '${prefix}'.
9166 case $ac_dir in #(
9167 . | /* | ?:[\\/]*) ;; #(
9168 *) continue;;
9169 esac
9170 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9171 ac_xdir=$ac_dir/cf$$
9172 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9173 ac_tf1=$ac_xdir/conftest9012345
9174 ac_tf2=$ac_xdir/conftest9012346
9175 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9176 ac_cv_sys_long_file_names=no
9177 rm -f -r "$ac_xdir" 2>/dev/null
9178 test $ac_cv_sys_long_file_names = no && break
9179 done
9180 fi
9181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9182 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9183 if test $ac_cv_sys_long_file_names = yes; then
9184
9185 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9186
9187 fi
9188
9189
9190 #### Choose a window system.
9191
9192 ## We leave window_system equal to none if
9193 ## we end up building without one. Any new window system should
9194 ## set window_system to an appropriate value and add objects to
9195 ## window-system-specific substs.
9196
9197 window_system=none
9198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9199 $as_echo_n "checking for X... " >&6; }
9200
9201
9202 # Check whether --with-x was given.
9203 if test "${with_x+set}" = set; then :
9204 withval=$with_x;
9205 fi
9206
9207 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9208 if test "x$with_x" = xno; then
9209 # The user explicitly disabled X.
9210 have_x=disabled
9211 else
9212 case $x_includes,$x_libraries in #(
9213 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9214 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9215 $as_echo_n "(cached) " >&6
9216 else
9217 # One or both of the vars are not set, and there is no cached value.
9218 ac_x_includes=no ac_x_libraries=no
9219 rm -f -r conftest.dir
9220 if mkdir conftest.dir; then
9221 cd conftest.dir
9222 cat >Imakefile <<'_ACEOF'
9223 incroot:
9224 @echo incroot='${INCROOT}'
9225 usrlibdir:
9226 @echo usrlibdir='${USRLIBDIR}'
9227 libdir:
9228 @echo libdir='${LIBDIR}'
9229 _ACEOF
9230 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9231 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9232 for ac_var in incroot usrlibdir libdir; do
9233 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9234 done
9235 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9236 for ac_extension in a so sl dylib la dll; do
9237 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9238 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9239 ac_im_usrlibdir=$ac_im_libdir; break
9240 fi
9241 done
9242 # Screen out bogus values from the imake configuration. They are
9243 # bogus both because they are the default anyway, and because
9244 # using them would break gcc on systems where it needs fixed includes.
9245 case $ac_im_incroot in
9246 /usr/include) ac_x_includes= ;;
9247 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9248 esac
9249 case $ac_im_usrlibdir in
9250 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9251 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9252 esac
9253 fi
9254 cd ..
9255 rm -f -r conftest.dir
9256 fi
9257
9258 # Standard set of common directories for X headers.
9259 # Check X11 before X11Rn because it is often a symlink to the current release.
9260 ac_x_header_dirs='
9261 /usr/X11/include
9262 /usr/X11R7/include
9263 /usr/X11R6/include
9264 /usr/X11R5/include
9265 /usr/X11R4/include
9266
9267 /usr/include/X11
9268 /usr/include/X11R7
9269 /usr/include/X11R6
9270 /usr/include/X11R5
9271 /usr/include/X11R4
9272
9273 /usr/local/X11/include
9274 /usr/local/X11R7/include
9275 /usr/local/X11R6/include
9276 /usr/local/X11R5/include
9277 /usr/local/X11R4/include
9278
9279 /usr/local/include/X11
9280 /usr/local/include/X11R7
9281 /usr/local/include/X11R6
9282 /usr/local/include/X11R5
9283 /usr/local/include/X11R4
9284
9285 /usr/X386/include
9286 /usr/x386/include
9287 /usr/XFree86/include/X11
9288
9289 /usr/include
9290 /usr/local/include
9291 /usr/unsupported/include
9292 /usr/athena/include
9293 /usr/local/x11r5/include
9294 /usr/lpp/Xamples/include
9295
9296 /usr/openwin/include
9297 /usr/openwin/share/include'
9298
9299 if test "$ac_x_includes" = no; then
9300 # Guess where to find include files, by looking for Xlib.h.
9301 # First, try using that file with no special directory specified.
9302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9303 /* end confdefs.h. */
9304 #include <X11/Xlib.h>
9305 _ACEOF
9306 if ac_fn_c_try_cpp "$LINENO"; then :
9307 # We can compile using X headers with no special include directory.
9308 ac_x_includes=
9309 else
9310 for ac_dir in $ac_x_header_dirs; do
9311 if test -r "$ac_dir/X11/Xlib.h"; then
9312 ac_x_includes=$ac_dir
9313 break
9314 fi
9315 done
9316 fi
9317 rm -f conftest.err conftest.$ac_ext
9318 fi # $ac_x_includes = no
9319
9320 if test "$ac_x_libraries" = no; then
9321 # Check for the libraries.
9322 # See if we find them without any special options.
9323 # Don't add to $LIBS permanently.
9324 ac_save_LIBS=$LIBS
9325 LIBS="-lX11 $LIBS"
9326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9327 /* end confdefs.h. */
9328 #include <X11/Xlib.h>
9329 int
9330 main ()
9331 {
9332 XrmInitialize ()
9333 ;
9334 return 0;
9335 }
9336 _ACEOF
9337 if ac_fn_c_try_link "$LINENO"; then :
9338 LIBS=$ac_save_LIBS
9339 # We can link X programs with no special library path.
9340 ac_x_libraries=
9341 else
9342 LIBS=$ac_save_LIBS
9343 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9344 do
9345 # Don't even attempt the hair of trying to link an X program!
9346 for ac_extension in a so sl dylib la dll; do
9347 if test -r "$ac_dir/libX11.$ac_extension"; then
9348 ac_x_libraries=$ac_dir
9349 break 2
9350 fi
9351 done
9352 done
9353 fi
9354 rm -f core conftest.err conftest.$ac_objext \
9355 conftest$ac_exeext conftest.$ac_ext
9356 fi # $ac_x_libraries = no
9357
9358 case $ac_x_includes,$ac_x_libraries in #(
9359 no,* | *,no | *\'*)
9360 # Didn't find X, or a directory has "'" in its name.
9361 ac_cv_have_x="have_x=no";; #(
9362 *)
9363 # Record where we found X for the cache.
9364 ac_cv_have_x="have_x=yes\
9365 ac_x_includes='$ac_x_includes'\
9366 ac_x_libraries='$ac_x_libraries'"
9367 esac
9368 fi
9369 ;; #(
9370 *) have_x=yes;;
9371 esac
9372 eval "$ac_cv_have_x"
9373 fi # $with_x != no
9374
9375 if test "$have_x" != yes; then
9376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9377 $as_echo "$have_x" >&6; }
9378 no_x=yes
9379 else
9380 # If each of the values was on the command line, it overrides each guess.
9381 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9382 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9383 # Update the cache value to reflect the command line values.
9384 ac_cv_have_x="have_x=yes\
9385 ac_x_includes='$x_includes'\
9386 ac_x_libraries='$x_libraries'"
9387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9388 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9389 fi
9390
9391 if test "$no_x" != yes; then
9392 window_system=x11
9393 fi
9394
9395 LD_SWITCH_X_SITE_RPATH=
9396 if test "${x_libraries}" != NONE; then
9397 if test -n "${x_libraries}"; then
9398 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9399 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9400 fi
9401 x_default_search_path=""
9402 x_search_path=${x_libraries}
9403 if test -z "${x_search_path}"; then
9404 x_search_path=/usr/lib
9405 fi
9406 for x_library in `echo ${x_search_path}: | \
9407 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9408 x_search_path="\
9409 ${x_library}/X11/%L/%T/%N%C%S:\
9410 ${x_library}/X11/%l/%T/%N%C%S:\
9411 ${x_library}/X11/%T/%N%C%S:\
9412 ${x_library}/X11/%L/%T/%N%S:\
9413 ${x_library}/X11/%l/%T/%N%S:\
9414 ${x_library}/X11/%T/%N%S"
9415 if test x"${x_default_search_path}" = x; then
9416 x_default_search_path=${x_search_path}
9417 else
9418 x_default_search_path="${x_search_path}:${x_default_search_path}"
9419 fi
9420 done
9421 fi
9422
9423
9424 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9425 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9426 fi
9427
9428 if test x"${x_includes}" = x; then
9429 bitmapdir=/usr/include/X11/bitmaps
9430 else
9431 # accumulate include directories that have X11 bitmap subdirectories
9432 bmd_acc="dummyval"
9433 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9434 if test -d "${bmd}/X11/bitmaps"; then
9435 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9436 fi
9437 if test -d "${bmd}/bitmaps"; then
9438 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9439 fi
9440 done
9441 if test ${bmd_acc} != "dummyval"; then
9442 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9443 fi
9444 fi
9445
9446 HAVE_NS=no
9447 NS_IMPL_COCOA=no
9448 NS_IMPL_GNUSTEP=no
9449 tmp_CPPFLAGS="$CPPFLAGS"
9450 tmp_CFLAGS="$CFLAGS"
9451 CPPFLAGS="$CPPFLAGS -x objective-c"
9452 CFLAGS="$CFLAGS -x objective-c"
9453 TEMACS_LDFLAGS2="\${LDFLAGS}"
9454 GNU_OBJC_CFLAGS=
9455 if test "${with_ns}" != no; then
9456 if test "${opsys}" = darwin; then
9457 NS_IMPL_COCOA=yes
9458 ns_appdir=`pwd`/nextstep/Emacs.app
9459 ns_appbindir=${ns_appdir}/Contents/MacOS
9460 ns_appresdir=${ns_appdir}/Contents/Resources
9461 ns_appsrc=Cocoa/Emacs.base
9462 elif test -f $GNUSTEP_CONFIG_FILE; then
9463 NS_IMPL_GNUSTEP=yes
9464 ns_appdir=`pwd`/nextstep/Emacs.app
9465 ns_appbindir=${ns_appdir}
9466 ns_appresdir=${ns_appdir}/Resources
9467 ns_appsrc=GNUstep/Emacs.base
9468 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9469 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9470 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9471 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9472 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9473 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9474 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9475 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9476 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9477 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9478 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9479 LIB_STANDARD=
9480 START_FILES=
9481 TEMACS_LDFLAGS2=
9482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9483 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9484 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9485 $as_echo_n "(cached) " >&6
9486 else
9487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9488 /* end confdefs.h. */
9489 #include <GNUstepBase/GSConfig.h>
9490 int
9491 main ()
9492 {
9493 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9494 1;
9495 #else
9496 fail;
9497 #endif
9498 ;
9499 return 0;
9500 }
9501 _ACEOF
9502 if ac_fn_c_try_compile "$LINENO"; then :
9503 emacs_cv_objc_exceptions=yes
9504 else
9505 emacs_cv_objc_exceptions=no
9506 fi
9507 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9508 fi
9509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9510 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9511 if test $emacs_cv_objc_exceptions = yes; then
9512
9513 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9514
9515 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9516 fi
9517 fi
9518
9519 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9520
9521 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9522 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9523 HAVE_NS=yes
9524 else
9525 as_fn_error "\`--with-ns' was specified, but the include
9526 files are missing or cannot be compiled." "$LINENO" 5
9527 fi
9528
9529
9530
9531 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9532 /* end confdefs.h. */
9533 #include <AppKit/AppKit.h>
9534 int
9535 main ()
9536 {
9537
9538 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9539 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
9540 ; /* OK */
9541 #else
9542 #error "OSX 10.4 or newer required"
9543 #endif
9544 #endif
9545
9546 ;
9547 return 0;
9548 }
9549 _ACEOF
9550 if ac_fn_c_try_compile "$LINENO"; then :
9551 ns_osx_have_104=yes
9552 else
9553 ns_osx_have_104=no
9554 fi
9555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9557 /* end confdefs.h. */
9558 #include <Foundation/NSObjCRuntime.h>
9559 int
9560 main ()
9561 {
9562 NSInteger i;
9563 ;
9564 return 0;
9565 }
9566 _ACEOF
9567 if ac_fn_c_try_compile "$LINENO"; then :
9568 ns_have_nsinteger=yes
9569 else
9570 ns_have_nsinteger=no
9571 fi
9572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9573 if test $ns_osx_have_104 = no; then
9574 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
9575 fi
9576 if test $ns_have_nsinteger = yes; then
9577
9578 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9579
9580 fi
9581 fi
9582
9583
9584
9585 INSTALL_ARCH_INDEP_EXTRA=install-etc
9586 ns_self_contained=no
9587 NS_OBJ=
9588 NS_OBJC_OBJ=
9589 if test "${HAVE_NS}" = yes; then
9590 if test "$with_toolkit_scroll_bars" = "no"; then
9591 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9592 fi
9593
9594 window_system=nextstep
9595 # set up packaging dirs
9596 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9597 ns_self_contained=yes
9598 prefix=${ns_appresdir}
9599 exec_prefix=${ns_appbindir}
9600 libexecdir="\${ns_appbindir}/libexec"
9601 archlibdir="\${ns_appbindir}/libexec"
9602 docdir="\${ns_appresdir}/etc"
9603 etcdir="\${ns_appresdir}/etc"
9604 infodir="\${ns_appresdir}/info"
9605 mandir="\${ns_appresdir}/man"
9606 lispdir="\${ns_appresdir}/lisp"
9607 leimdir="\${ns_appresdir}/leim"
9608 INSTALL_ARCH_INDEP_EXTRA=
9609 fi
9610 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9611 fi
9612 CFLAGS="$tmp_CFLAGS"
9613 CPPFLAGS="$tmp_CPPFLAGS"
9614
9615
9616
9617
9618
9619
9620 HAVE_W32=no
9621 W32_OBJ=
9622 W32_LIBS=
9623 if test "${with_w32}" != no; then
9624 if test "${opsys}" != "cygwin"; then
9625 as_fn_error "Using w32 with an autotools build is only supported for Cygwin." "$LINENO" 5
9626 fi
9627 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
9628 if test "x$ac_cv_header_windows_h" = x""yes; then :
9629 HAVE_W32=yes
9630 else
9631 as_fn_error "\`--with-w32' was specified, but windows.h
9632 cannot be found." "$LINENO" 5
9633 fi
9634
9635
9636
9637 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
9638
9639 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
9640 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
9641 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
9642 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
9643 fi
9644
9645
9646
9647 if test "${HAVE_W32}" = "yes"; then
9648 window_system=w32
9649 with_xft=no
9650 fi
9651
9652 ## $window_system is now set to the window system we will
9653 ## ultimately use.
9654
9655 term_header=
9656 HAVE_X_WINDOWS=no
9657 HAVE_X11=no
9658 USE_X_TOOLKIT=none
9659
9660 case "${window_system}" in
9661 x11 )
9662 HAVE_X_WINDOWS=yes
9663 HAVE_X11=yes
9664 term_header=xterm.h
9665 case "${with_x_toolkit}" in
9666 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9667 motif ) USE_X_TOOLKIT=MOTIF ;;
9668 gtk ) with_gtk=yes
9669 term_header=gtkutil.h
9670 USE_X_TOOLKIT=none ;;
9671 gtk2 ) with_gtk2=yes
9672 term_header=gtkutil.h
9673 USE_X_TOOLKIT=none ;;
9674 gtk3 ) with_gtk3=yes
9675 term_header=gtkutil.h
9676 USE_X_TOOLKIT=none ;;
9677 no ) USE_X_TOOLKIT=none ;;
9678 * ) USE_X_TOOLKIT=maybe ;;
9679 esac
9680 ;;
9681 nextstep )
9682 term_header=nsterm.h
9683 ;;
9684 w32 )
9685 term_header=w32term.h
9686 ;;
9687 esac
9688
9689 if test -n "${term_header}"; then
9690
9691 cat >>confdefs.h <<_ACEOF
9692 #define TERM_HEADER "${term_header}"
9693 _ACEOF
9694
9695 fi
9696
9697 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9698 # Extract the first word of "X", so it can be a program name with args.
9699 set dummy X; ac_word=$2
9700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9701 $as_echo_n "checking for $ac_word... " >&6; }
9702 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9703 $as_echo_n "(cached) " >&6
9704 else
9705 if test -n "$HAVE_XSERVER"; then
9706 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9707 else
9708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9709 for as_dir in $PATH
9710 do
9711 IFS=$as_save_IFS
9712 test -z "$as_dir" && as_dir=.
9713 for ac_exec_ext in '' $ac_executable_extensions; do
9714 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9715 ac_cv_prog_HAVE_XSERVER="true"
9716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9717 break 2
9718 fi
9719 done
9720 done
9721 IFS=$as_save_IFS
9722
9723 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9724 fi
9725 fi
9726 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9727 if test -n "$HAVE_XSERVER"; then
9728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9729 $as_echo "$HAVE_XSERVER" >&6; }
9730 else
9731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9732 $as_echo "no" >&6; }
9733 fi
9734
9735
9736 if test "$HAVE_XSERVER" = true ||
9737 test -n "$DISPLAY" ||
9738 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9739 as_fn_error "You seem to be running X, but no X development libraries
9740 were found. You should install the relevant development files for X
9741 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9742 sure you have development files for image handling, i.e.
9743 tiff, gif, jpeg, png and xpm.
9744 If you are sure you want Emacs compiled without X window support, pass
9745 --without-x
9746 to configure." "$LINENO" 5
9747 fi
9748 fi
9749
9750 ### If we're using X11, we should use the X menu package.
9751 HAVE_MENUS=no
9752 case ${HAVE_X11} in
9753 yes ) HAVE_MENUS=yes ;;
9754 esac
9755
9756 # Does the opsystem file prohibit the use of the GNU malloc?
9757 # Assume not, until told otherwise.
9758 GNU_MALLOC=yes
9759
9760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9761 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9762 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9763 $as_echo_n "(cached) " >&6
9764 else
9765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9766 /* end confdefs.h. */
9767 #include <malloc.h>
9768 static void hook (void) {}
9769 int
9770 main ()
9771 {
9772 malloc_set_state (malloc_get_state ());
9773 __after_morecore_hook = hook;
9774 __malloc_initialize_hook = hook;
9775 ;
9776 return 0;
9777 }
9778 _ACEOF
9779 if ac_fn_c_try_link "$LINENO"; then :
9780 emacs_cv_var_doug_lea_malloc=yes
9781 else
9782 emacs_cv_var_doug_lea_malloc=no
9783 fi
9784 rm -f core conftest.err conftest.$ac_objext \
9785 conftest$ac_exeext conftest.$ac_ext
9786 fi
9787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9788 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9789 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9790
9791
9792 system_malloc=no
9793 case "$opsys" in
9794 ## darwin ld insists on the use of malloc routines in the System framework.
9795 darwin|sol2-10) system_malloc=yes ;;
9796 esac
9797
9798 if test "${system_malloc}" = "yes"; then
9799
9800 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9801
9802 GNU_MALLOC=no
9803 GNU_MALLOC_reason="
9804 (The GNU allocators don't work with this system configuration.)"
9805 GMALLOC_OBJ=
9806 VMLIMIT_OBJ=
9807 else
9808 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9809 VMLIMIT_OBJ=vm-limit.o
9810 fi
9811
9812
9813
9814 if test "$doug_lea_malloc" = "yes" ; then
9815 if test "$GNU_MALLOC" = yes ; then
9816 GNU_MALLOC_reason="
9817 (Using Doug Lea's new malloc from the GNU C Library.)"
9818 fi
9819
9820 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9821
9822
9823 ## Use mmap directly for allocating larger buffers.
9824 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9825 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9826 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9827 case "$opsys" in
9828 gnu*) REL_ALLOC=no ;;
9829 esac
9830 fi
9831
9832 if test x"${REL_ALLOC}" = x; then
9833 REL_ALLOC=${GNU_MALLOC}
9834 fi
9835
9836 use_mmap_for_buffers=no
9837 case "$opsys" in
9838 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9839 esac
9840
9841
9842
9843
9844
9845
9846
9847
9848 for ac_func in getpagesize
9849 do :
9850 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9851 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9852 cat >>confdefs.h <<_ACEOF
9853 #define HAVE_GETPAGESIZE 1
9854 _ACEOF
9855
9856 fi
9857 done
9858
9859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9860 $as_echo_n "checking for working mmap... " >&6; }
9861 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9862 $as_echo_n "(cached) " >&6
9863 else
9864 if test "$cross_compiling" = yes; then :
9865 ac_cv_func_mmap_fixed_mapped=no
9866 else
9867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9868 /* end confdefs.h. */
9869 $ac_includes_default
9870 /* malloc might have been renamed as rpl_malloc. */
9871 #undef malloc
9872
9873 /* Thanks to Mike Haertel and Jim Avera for this test.
9874 Here is a matrix of mmap possibilities:
9875 mmap private not fixed
9876 mmap private fixed at somewhere currently unmapped
9877 mmap private fixed at somewhere already mapped
9878 mmap shared not fixed
9879 mmap shared fixed at somewhere currently unmapped
9880 mmap shared fixed at somewhere already mapped
9881 For private mappings, we should verify that changes cannot be read()
9882 back from the file, nor mmap's back from the file at a different
9883 address. (There have been systems where private was not correctly
9884 implemented like the infamous i386 svr4.0, and systems where the
9885 VM page cache was not coherent with the file system buffer cache
9886 like early versions of FreeBSD and possibly contemporary NetBSD.)
9887 For shared mappings, we should conversely verify that changes get
9888 propagated back to all the places they're supposed to be.
9889
9890 Grep wants private fixed already mapped.
9891 The main things grep needs to know about mmap are:
9892 * does it exist and is it safe to write into the mmap'd area
9893 * how to use it (BSD variants) */
9894
9895 #include <fcntl.h>
9896 #include <sys/mman.h>
9897
9898 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9899 char *malloc ();
9900 #endif
9901
9902 /* This mess was copied from the GNU getpagesize.h. */
9903 #ifndef HAVE_GETPAGESIZE
9904 # ifdef _SC_PAGESIZE
9905 # define getpagesize() sysconf(_SC_PAGESIZE)
9906 # else /* no _SC_PAGESIZE */
9907 # ifdef HAVE_SYS_PARAM_H
9908 # include <sys/param.h>
9909 # ifdef EXEC_PAGESIZE
9910 # define getpagesize() EXEC_PAGESIZE
9911 # else /* no EXEC_PAGESIZE */
9912 # ifdef NBPG
9913 # define getpagesize() NBPG * CLSIZE
9914 # ifndef CLSIZE
9915 # define CLSIZE 1
9916 # endif /* no CLSIZE */
9917 # else /* no NBPG */
9918 # ifdef NBPC
9919 # define getpagesize() NBPC
9920 # else /* no NBPC */
9921 # ifdef PAGESIZE
9922 # define getpagesize() PAGESIZE
9923 # endif /* PAGESIZE */
9924 # endif /* no NBPC */
9925 # endif /* no NBPG */
9926 # endif /* no EXEC_PAGESIZE */
9927 # else /* no HAVE_SYS_PARAM_H */
9928 # define getpagesize() 8192 /* punt totally */
9929 # endif /* no HAVE_SYS_PARAM_H */
9930 # endif /* no _SC_PAGESIZE */
9931
9932 #endif /* no HAVE_GETPAGESIZE */
9933
9934 int
9935 main ()
9936 {
9937 char *data, *data2, *data3;
9938 const char *cdata2;
9939 int i, pagesize;
9940 int fd, fd2;
9941
9942 pagesize = getpagesize ();
9943
9944 /* First, make a file with some known garbage in it. */
9945 data = (char *) malloc (pagesize);
9946 if (!data)
9947 return 1;
9948 for (i = 0; i < pagesize; ++i)
9949 *(data + i) = rand ();
9950 umask (0);
9951 fd = creat ("conftest.mmap", 0600);
9952 if (fd < 0)
9953 return 2;
9954 if (write (fd, data, pagesize) != pagesize)
9955 return 3;
9956 close (fd);
9957
9958 /* Next, check that the tail of a page is zero-filled. File must have
9959 non-zero length, otherwise we risk SIGBUS for entire page. */
9960 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9961 if (fd2 < 0)
9962 return 4;
9963 cdata2 = "";
9964 if (write (fd2, cdata2, 1) != 1)
9965 return 5;
9966 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9967 if (data2 == MAP_FAILED)
9968 return 6;
9969 for (i = 0; i < pagesize; ++i)
9970 if (*(data2 + i))
9971 return 7;
9972 close (fd2);
9973 if (munmap (data2, pagesize))
9974 return 8;
9975
9976 /* Next, try to mmap the file at a fixed address which already has
9977 something else allocated at it. If we can, also make sure that
9978 we see the same garbage. */
9979 fd = open ("conftest.mmap", O_RDWR);
9980 if (fd < 0)
9981 return 9;
9982 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9983 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9984 return 10;
9985 for (i = 0; i < pagesize; ++i)
9986 if (*(data + i) != *(data2 + i))
9987 return 11;
9988
9989 /* Finally, make sure that changes to the mapped area do not
9990 percolate back to the file as seen by read(). (This is a bug on
9991 some variants of i386 svr4.0.) */
9992 for (i = 0; i < pagesize; ++i)
9993 *(data2 + i) = *(data2 + i) + 1;
9994 data3 = (char *) malloc (pagesize);
9995 if (!data3)
9996 return 12;
9997 if (read (fd, data3, pagesize) != pagesize)
9998 return 13;
9999 for (i = 0; i < pagesize; ++i)
10000 if (*(data + i) != *(data3 + i))
10001 return 14;
10002 close (fd);
10003 return 0;
10004 }
10005 _ACEOF
10006 if ac_fn_c_try_run "$LINENO"; then :
10007 ac_cv_func_mmap_fixed_mapped=yes
10008 else
10009 ac_cv_func_mmap_fixed_mapped=no
10010 fi
10011 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10012 conftest.$ac_objext conftest.beam conftest.$ac_ext
10013 fi
10014
10015 fi
10016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10017 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10018 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10019
10020 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10021
10022 fi
10023 rm -f conftest.mmap conftest.txt
10024
10025 if test $use_mmap_for_buffers = yes; then
10026
10027 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10028
10029 REL_ALLOC=no
10030 fi
10031
10032 LIBS="$LIBS_SYSTEM $LIBS"
10033
10034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10035 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10036 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10037 $as_echo_n "(cached) " >&6
10038 else
10039 ac_check_lib_save_LIBS=$LIBS
10040 LIBS="-ldnet $LIBS"
10041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10042 /* end confdefs.h. */
10043
10044 /* Override any GCC internal prototype to avoid an error.
10045 Use char because int might match the return type of a GCC
10046 builtin and then its argument prototype would still apply. */
10047 #ifdef __cplusplus
10048 extern "C"
10049 #endif
10050 char dnet_ntoa ();
10051 int
10052 main ()
10053 {
10054 return dnet_ntoa ();
10055 ;
10056 return 0;
10057 }
10058 _ACEOF
10059 if ac_fn_c_try_link "$LINENO"; then :
10060 ac_cv_lib_dnet_dnet_ntoa=yes
10061 else
10062 ac_cv_lib_dnet_dnet_ntoa=no
10063 fi
10064 rm -f core conftest.err conftest.$ac_objext \
10065 conftest$ac_exeext conftest.$ac_ext
10066 LIBS=$ac_check_lib_save_LIBS
10067 fi
10068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10069 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10070 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10071 cat >>confdefs.h <<_ACEOF
10072 #define HAVE_LIBDNET 1
10073 _ACEOF
10074
10075 LIBS="-ldnet $LIBS"
10076
10077 fi
10078
10079
10080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10081 $as_echo_n "checking for main in -lXbsd... " >&6; }
10082 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10083 $as_echo_n "(cached) " >&6
10084 else
10085 ac_check_lib_save_LIBS=$LIBS
10086 LIBS="-lXbsd $LIBS"
10087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10088 /* end confdefs.h. */
10089
10090
10091 int
10092 main ()
10093 {
10094 return main ();
10095 ;
10096 return 0;
10097 }
10098 _ACEOF
10099 if ac_fn_c_try_link "$LINENO"; then :
10100 ac_cv_lib_Xbsd_main=yes
10101 else
10102 ac_cv_lib_Xbsd_main=no
10103 fi
10104 rm -f core conftest.err conftest.$ac_objext \
10105 conftest$ac_exeext conftest.$ac_ext
10106 LIBS=$ac_check_lib_save_LIBS
10107 fi
10108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10109 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10110 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10111 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10112 fi
10113
10114
10115 LIB_PTHREAD=
10116
10117
10118
10119 if test "$ac_cv_header_pthread_h"; then
10120 if test "$GMALLOC_OBJ" = gmalloc.o; then
10121 emacs_pthread_function=pthread_atfork
10122 else
10123 emacs_pthread_function=pthread_self
10124 fi
10125 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10127 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10128 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10129 $as_echo_n "(cached) " >&6
10130 else
10131 ac_check_lib_save_LIBS=$LIBS
10132 LIBS="-lpthread $LIBS"
10133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10134 /* end confdefs.h. */
10135
10136 /* Override any GCC internal prototype to avoid an error.
10137 Use char because int might match the return type of a GCC
10138 builtin and then its argument prototype would still apply. */
10139 #ifdef __cplusplus
10140 extern "C"
10141 #endif
10142 char $emacs_pthread_function ();
10143 int
10144 main ()
10145 {
10146 return $emacs_pthread_function ();
10147 ;
10148 return 0;
10149 }
10150 _ACEOF
10151 if ac_fn_c_try_link "$LINENO"; then :
10152 eval "$as_ac_Lib=yes"
10153 else
10154 eval "$as_ac_Lib=no"
10155 fi
10156 rm -f core conftest.err conftest.$ac_objext \
10157 conftest$ac_exeext conftest.$ac_ext
10158 LIBS=$ac_check_lib_save_LIBS
10159 fi
10160 eval ac_res=\$$as_ac_Lib
10161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10162 $as_echo "$ac_res" >&6; }
10163 eval as_val=\$$as_ac_Lib
10164 if test "x$as_val" = x""yes; then :
10165 HAVE_PTHREAD=yes
10166 fi
10167
10168 fi
10169 if test "$HAVE_PTHREAD" = yes; then
10170 case "${canonical}" in
10171 *-hpux*) ;;
10172 *) LIB_PTHREAD="-lpthread"
10173 LIBS="$LIB_PTHREAD $LIBS" ;;
10174 esac
10175
10176 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10177
10178 fi
10179
10180
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10182 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10183 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10184 $as_echo_n "(cached) " >&6
10185 else
10186 ac_check_lib_save_LIBS=$LIBS
10187 LIBS="-lpthreads $LIBS"
10188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10189 /* end confdefs.h. */
10190
10191 /* Override any GCC internal prototype to avoid an error.
10192 Use char because int might match the return type of a GCC
10193 builtin and then its argument prototype would still apply. */
10194 #ifdef __cplusplus
10195 extern "C"
10196 #endif
10197 char cma_open ();
10198 int
10199 main ()
10200 {
10201 return cma_open ();
10202 ;
10203 return 0;
10204 }
10205 _ACEOF
10206 if ac_fn_c_try_link "$LINENO"; then :
10207 ac_cv_lib_pthreads_cma_open=yes
10208 else
10209 ac_cv_lib_pthreads_cma_open=no
10210 fi
10211 rm -f core conftest.err conftest.$ac_objext \
10212 conftest$ac_exeext conftest.$ac_ext
10213 LIBS=$ac_check_lib_save_LIBS
10214 fi
10215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10216 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10217 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10218 cat >>confdefs.h <<_ACEOF
10219 #define HAVE_LIBPTHREADS 1
10220 _ACEOF
10221
10222 LIBS="-lpthreads $LIBS"
10223
10224 fi
10225
10226
10227 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10228 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10229 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10230 ## added to LIBS in configure would never contain the pthreads part,
10231 ## but the value used in Makefiles might. FIXME?
10232 ##
10233 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10234 ## be harmless on older versions of X where it happens to exist.
10235 test "$opsys" = "aix4-2" && \
10236 test $ac_cv_lib_pthreads_cma_open = yes && \
10237 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10238
10239
10240 case ${host_os} in
10241 aix*)
10242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10243 $as_echo_n "checking for -bbigtoc option... " >&6; }
10244 if test "${gdb_cv_bigtoc+set}" = set; then :
10245 $as_echo_n "(cached) " >&6
10246 else
10247
10248 case $GCC in
10249 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10250 *) gdb_cv_bigtoc=-bbigtoc ;;
10251 esac
10252
10253 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10255 /* end confdefs.h. */
10256
10257 int
10258 main ()
10259 {
10260 int i;
10261 ;
10262 return 0;
10263 }
10264 _ACEOF
10265 if ac_fn_c_try_link "$LINENO"; then :
10266
10267 else
10268 gdb_cv_bigtoc=
10269 fi
10270 rm -f core conftest.err conftest.$ac_objext \
10271 conftest$ac_exeext conftest.$ac_ext
10272
10273 fi
10274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10275 $as_echo "$gdb_cv_bigtoc" >&6; }
10276 ;;
10277 esac
10278
10279 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10280 # used for the tests that follow. We set them back to REAL_CFLAGS and
10281 # REAL_CPPFLAGS later on.
10282
10283 REAL_CFLAGS="$CFLAGS"
10284 REAL_CPPFLAGS="$CPPFLAGS"
10285
10286 if test "${HAVE_X11}" = "yes"; then
10287 DEFS="$C_SWITCH_X_SITE $DEFS"
10288 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10289 LIBS="-lX11 $LIBS"
10290 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10291 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10292
10293 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10294 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10295 # but it's more convenient here to set LD_RUN_PATH since this
10296 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10297 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10298 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10299 export LD_RUN_PATH
10300 fi
10301
10302 if test "${opsys}" = "gnu-linux"; then
10303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10304 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10306 /* end confdefs.h. */
10307
10308 int
10309 main ()
10310 {
10311 XOpenDisplay ("foo");
10312 ;
10313 return 0;
10314 }
10315 _ACEOF
10316 if ac_fn_c_try_link "$LINENO"; then :
10317 xgnu_linux_first_failure=no
10318 else
10319 xgnu_linux_first_failure=yes
10320 fi
10321 rm -f core conftest.err conftest.$ac_objext \
10322 conftest$ac_exeext conftest.$ac_ext
10323 if test "${xgnu_linux_first_failure}" = "yes"; then
10324 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10325 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10326 OLD_CPPFLAGS="$CPPFLAGS"
10327 OLD_LIBS="$LIBS"
10328 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10329 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10330 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10331 LIBS="$LIBS -b i486-linuxaout"
10332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10333 /* end confdefs.h. */
10334
10335 int
10336 main ()
10337 {
10338 XOpenDisplay ("foo");
10339 ;
10340 return 0;
10341 }
10342 _ACEOF
10343 if ac_fn_c_try_link "$LINENO"; then :
10344 xgnu_linux_second_failure=no
10345 else
10346 xgnu_linux_second_failure=yes
10347 fi
10348 rm -f core conftest.err conftest.$ac_objext \
10349 conftest$ac_exeext conftest.$ac_ext
10350 if test "${xgnu_linux_second_failure}" = "yes"; then
10351 # If we get the same failure with -b, there is no use adding -b.
10352 # So take it out. This plays safe.
10353 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10354 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10355 CPPFLAGS="$OLD_CPPFLAGS"
10356 LIBS="$OLD_LIBS"
10357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10358 $as_echo "no" >&6; }
10359 else
10360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10361 $as_echo "yes" >&6; }
10362 fi
10363 else
10364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10365 $as_echo "no" >&6; }
10366 fi
10367 fi
10368
10369 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10370 # header files included from there.
10371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10372 $as_echo_n "checking for Xkb... " >&6; }
10373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10374 /* end confdefs.h. */
10375 #include <X11/Xlib.h>
10376 #include <X11/XKBlib.h>
10377 int
10378 main ()
10379 {
10380 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10381 ;
10382 return 0;
10383 }
10384 _ACEOF
10385 if ac_fn_c_try_link "$LINENO"; then :
10386 emacs_xkb=yes
10387 else
10388 emacs_xkb=no
10389 fi
10390 rm -f core conftest.err conftest.$ac_objext \
10391 conftest$ac_exeext conftest.$ac_ext
10392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10393 $as_echo "$emacs_xkb" >&6; }
10394 if test $emacs_xkb = yes; then
10395
10396 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10397
10398 fi
10399
10400 for ac_func in XrmSetDatabase XScreenResourceString \
10401 XScreenNumberOfScreen
10402 do :
10403 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10404 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10405 eval as_val=\$$as_ac_var
10406 if test "x$as_val" = x""yes; then :
10407 cat >>confdefs.h <<_ACEOF
10408 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10409 _ACEOF
10410
10411 fi
10412 done
10413
10414 fi
10415
10416 if test "${window_system}" = "x11"; then
10417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10418 $as_echo_n "checking X11 version 6... " >&6; }
10419 if test "${emacs_cv_x11_version_6+set}" = set; then :
10420 $as_echo_n "(cached) " >&6
10421 else
10422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10423 /* end confdefs.h. */
10424 #include <X11/Xlib.h>
10425 int
10426 main ()
10427 {
10428 #if XlibSpecificationRelease < 6
10429 fail;
10430 #endif
10431
10432 ;
10433 return 0;
10434 }
10435 _ACEOF
10436 if ac_fn_c_try_link "$LINENO"; then :
10437 emacs_cv_x11_version_6=yes
10438 else
10439 emacs_cv_x11_version_6=no
10440 fi
10441 rm -f core conftest.err conftest.$ac_objext \
10442 conftest$ac_exeext conftest.$ac_ext
10443 fi
10444
10445 if test $emacs_cv_x11_version_6 = yes; then
10446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10447 $as_echo "6 or newer" >&6; }
10448
10449 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10450
10451
10452 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10453
10454 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10455 ## XIM support.
10456 case "$opsys" in
10457 sol2-*) : ;;
10458 *)
10459 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10460
10461 ;;
10462 esac
10463 else
10464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10465 $as_echo "before 6" >&6; }
10466 fi
10467 fi
10468
10469
10470 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10471 HAVE_RSVG=no
10472 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10473 if test "${with_rsvg}" != "no"; then
10474 RSVG_REQUIRED=2.11.0
10475 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10476
10477
10478 succeeded=no
10479
10480 if test "$PKG_CONFIG" = "no" ; then
10481 :
10482 else
10483 PKG_CONFIG_MIN_VERSION=0.9.0
10484 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10486 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10487
10488 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10489 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10490 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10491 edit_cflags="
10492 s,///*,/,g
10493 s/^/ /
10494 s/ -I/ $isystem/g
10495 s/^ //
10496 "
10497 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10498 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10500 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10501 succeeded=yes
10502 else
10503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10504 $as_echo "no" >&6; }
10505 RSVG_CFLAGS=""
10506 RSVG_LIBS=""
10507 ## If we have a custom action on failure, don't print errors, but
10508 ## do set a variable so people can do so. Do it in a subshell
10509 ## to capture any diagnostics in invoking pkg-config.
10510 RSVG_PKG_ERRORS=`($PKG_CONFIG --print-errors "$RSVG_MODULE") 2>&1`
10511
10512 fi
10513
10514
10515
10516 else
10517 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10518 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10519 fi
10520 fi
10521
10522 if test $succeeded = yes; then
10523 HAVE_RSVG=yes
10524 else
10525 :
10526 fi
10527
10528
10529
10530
10531 if test $HAVE_RSVG = yes; then
10532
10533 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10534
10535 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10536 LIBS="$RSVG_LIBS $LIBS"
10537 fi
10538 fi
10539 fi
10540
10541 HAVE_IMAGEMAGICK=no
10542 if test "${HAVE_X11}" = "yes"; then
10543 if test "${with_imagemagick}" != "no"; then
10544 ## 6.2.8 is the earliest version known to work, but earlier versions
10545 ## might work - let us know if you find one.
10546 ## 6.0.7 does not work. See bug#7955.
10547 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10548
10549 succeeded=no
10550
10551 if test "$PKG_CONFIG" = "no" ; then
10552 :
10553 else
10554 PKG_CONFIG_MIN_VERSION=0.9.0
10555 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10557 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10558
10559 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10560 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10561 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10562 edit_cflags="
10563 s,///*,/,g
10564 s/^/ /
10565 s/ -I/ $isystem/g
10566 s/^ //
10567 "
10568 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10569 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10571 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10572 succeeded=yes
10573 else
10574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10575 $as_echo "no" >&6; }
10576 IMAGEMAGICK_CFLAGS=""
10577 IMAGEMAGICK_LIBS=""
10578 ## If we have a custom action on failure, don't print errors, but
10579 ## do set a variable so people can do so. Do it in a subshell
10580 ## to capture any diagnostics in invoking pkg-config.
10581 IMAGEMAGICK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
10582
10583 fi
10584
10585
10586
10587 else
10588 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10589 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10590 fi
10591 fi
10592
10593 if test $succeeded = yes; then
10594 HAVE_IMAGEMAGICK=yes
10595 else
10596 :
10597 fi
10598
10599
10600
10601
10602 if test $HAVE_IMAGEMAGICK = yes; then
10603
10604 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10605
10606 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10607 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10608 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10609 do :
10610 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10611 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10612 eval as_val=\$$as_ac_var
10613 if test "x$as_val" = x""yes; then :
10614 cat >>confdefs.h <<_ACEOF
10615 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10616 _ACEOF
10617
10618 fi
10619 done
10620
10621 fi
10622 fi
10623 fi
10624
10625
10626 HAVE_GTK=no
10627 GTK_OBJ=
10628 check_gtk2=no
10629 gtk3_pkg_errors=
10630 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10631 GLIB_REQUIRED=2.28
10632 GTK_REQUIRED=3.0
10633 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10634
10635
10636 succeeded=no
10637
10638 if test "$PKG_CONFIG" = "no" ; then
10639 pkg_check_gtk=no
10640 else
10641 PKG_CONFIG_MIN_VERSION=0.9.0
10642 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10644 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10645
10646 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10647 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10648 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10649 edit_cflags="
10650 s,///*,/,g
10651 s/^/ /
10652 s/ -I/ $isystem/g
10653 s/^ //
10654 "
10655 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10656 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10658 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10659 succeeded=yes
10660 else
10661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10662 $as_echo "no" >&6; }
10663 GTK_CFLAGS=""
10664 GTK_LIBS=""
10665 ## If we have a custom action on failure, don't print errors, but
10666 ## do set a variable so people can do so. Do it in a subshell
10667 ## to capture any diagnostics in invoking pkg-config.
10668 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10669
10670 fi
10671
10672
10673
10674 else
10675 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10676 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10677 fi
10678 fi
10679
10680 if test $succeeded = yes; then
10681 pkg_check_gtk=yes
10682 else
10683 pkg_check_gtk=no
10684 fi
10685
10686 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
10687 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10688 fi
10689 if test "$pkg_check_gtk" = "yes"; then
10690
10691 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10692
10693 GTK_OBJ=emacsgtkfixed.o
10694 term_header=gtkutil.h
10695 USE_GTK_TOOLKIT="GTK3"
10696 else
10697 check_gtk2=yes
10698 gtk3_pkg_errors="$GTK_PKG_ERRORS "
10699 fi
10700 fi
10701
10702 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
10703 GLIB_REQUIRED=2.10
10704 GTK_REQUIRED=2.10
10705 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10706
10707
10708 succeeded=no
10709
10710 if test "$PKG_CONFIG" = "no" ; then
10711 pkg_check_gtk=no
10712 else
10713 PKG_CONFIG_MIN_VERSION=0.9.0
10714 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10716 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10717
10718 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10719 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10720 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10721 edit_cflags="
10722 s,///*,/,g
10723 s/^/ /
10724 s/ -I/ $isystem/g
10725 s/^ //
10726 "
10727 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10728 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10730 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10731 succeeded=yes
10732 else
10733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10734 $as_echo "no" >&6; }
10735 GTK_CFLAGS=""
10736 GTK_LIBS=""
10737 ## If we have a custom action on failure, don't print errors, but
10738 ## do set a variable so people can do so. Do it in a subshell
10739 ## to capture any diagnostics in invoking pkg-config.
10740 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10741
10742 fi
10743
10744
10745
10746 else
10747 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10748 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10749 fi
10750 fi
10751
10752 if test $succeeded = yes; then
10753 pkg_check_gtk=yes
10754 else
10755 pkg_check_gtk=no
10756 fi
10757
10758 if test "$pkg_check_gtk" = "no" &&
10759 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
10760 then
10761 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
10762 fi
10763 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
10764 fi
10765
10766 if test x"$pkg_check_gtk" = xyes; then
10767
10768
10769
10770 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10771 CFLAGS="$CFLAGS $GTK_CFLAGS"
10772 LIBS="$GTK_LIBS $LIBS"
10773 GTK_COMPILES=no
10774 for ac_func in gtk_main
10775 do :
10776 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10777 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10778 cat >>confdefs.h <<_ACEOF
10779 #define HAVE_GTK_MAIN 1
10780 _ACEOF
10781 GTK_COMPILES=yes
10782 fi
10783 done
10784
10785 if test "${GTK_COMPILES}" != "yes"; then
10786 if test "$USE_X_TOOLKIT" != "maybe"; then
10787 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10788 fi
10789 else
10790 HAVE_GTK=yes
10791
10792 $as_echo "#define USE_GTK 1" >>confdefs.h
10793
10794 GTK_OBJ="gtkutil.o $GTK_OBJ"
10795 USE_X_TOOLKIT=none
10796 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10797 :
10798 else
10799 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10800 closing open displays. This is no problem if you just use
10801 one display, but if you use more than one and close one of them
10802 Emacs may crash." >&5
10803 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10804 closing open displays. This is no problem if you just use
10805 one display, but if you use more than one and close one of them
10806 Emacs may crash." >&2;}
10807 sleep 3
10808 fi
10809 fi
10810
10811 fi
10812
10813
10814
10815 if test "${HAVE_GTK}" = "yes"; then
10816
10817 if test "$with_toolkit_scroll_bars" != no; then
10818 with_toolkit_scroll_bars=yes
10819 fi
10820
10821 HAVE_GTK_FILE_SELECTION=no
10822 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10823 #include <gtk/gtk.h>
10824 "
10825 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10826 HAVE_GTK_FILE_SELECTION=yes
10827 else
10828 HAVE_GTK_FILE_SELECTION=no
10829 fi
10830
10831 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10832 for ac_func in gtk_file_selection_new
10833 do :
10834 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10835 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10836 cat >>confdefs.h <<_ACEOF
10837 #define HAVE_GTK_FILE_SELECTION_NEW 1
10838 _ACEOF
10839
10840 fi
10841 done
10842
10843 fi
10844
10845
10846 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10847 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10848 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10849 gtk_orientable_set_orientation \
10850 gtk_window_set_has_resize_grip
10851 do :
10852 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10853 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10854 eval as_val=\$$as_ac_var
10855 if test "x$as_val" = x""yes; then :
10856 cat >>confdefs.h <<_ACEOF
10857 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10858 _ACEOF
10859
10860 fi
10861 done
10862
10863
10864 term_header=gtkutil.h
10865 fi
10866
10867 HAVE_DBUS=no
10868 DBUS_OBJ=
10869 if test "${with_dbus}" = "yes"; then
10870
10871 succeeded=no
10872
10873 if test "$PKG_CONFIG" = "no" ; then
10874 HAVE_DBUS=no
10875 else
10876 PKG_CONFIG_MIN_VERSION=0.9.0
10877 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10879 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10880
10881 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10882 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10883 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10884 edit_cflags="
10885 s,///*,/,g
10886 s/^/ /
10887 s/ -I/ $isystem/g
10888 s/^ //
10889 "
10890 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10891 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10893 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10894 succeeded=yes
10895 else
10896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10897 $as_echo "no" >&6; }
10898 DBUS_CFLAGS=""
10899 DBUS_LIBS=""
10900 ## If we have a custom action on failure, don't print errors, but
10901 ## do set a variable so people can do so. Do it in a subshell
10902 ## to capture any diagnostics in invoking pkg-config.
10903 DBUS_PKG_ERRORS=`($PKG_CONFIG --print-errors "dbus-1 >= 1.0") 2>&1`
10904
10905 fi
10906
10907
10908
10909 else
10910 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10911 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10912 fi
10913 fi
10914
10915 if test $succeeded = yes; then
10916 HAVE_DBUS=yes
10917 else
10918 HAVE_DBUS=no
10919 fi
10920
10921 if test "$HAVE_DBUS" = yes; then
10922 LIBS="$LIBS $DBUS_LIBS"
10923
10924 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10925
10926 for ac_func in dbus_watch_get_unix_fd \
10927 dbus_type_is_valid \
10928 dbus_validate_bus_name \
10929 dbus_validate_path \
10930 dbus_validate_interface \
10931 dbus_validate_member
10932 do :
10933 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10934 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10935 eval as_val=\$$as_ac_var
10936 if test "x$as_val" = x""yes; then :
10937 cat >>confdefs.h <<_ACEOF
10938 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10939 _ACEOF
10940
10941 fi
10942 done
10943
10944 DBUS_OBJ=dbusbind.o
10945 fi
10946 fi
10947
10948
10949 HAVE_GSETTINGS=no
10950 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10951
10952 succeeded=no
10953
10954 if test "$PKG_CONFIG" = "no" ; then
10955 HAVE_GSETTINGS=no
10956 else
10957 PKG_CONFIG_MIN_VERSION=0.9.0
10958 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10960 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10961
10962 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10963 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10964 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10965 edit_cflags="
10966 s,///*,/,g
10967 s/^/ /
10968 s/ -I/ $isystem/g
10969 s/^ //
10970 "
10971 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10972 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10974 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10975 succeeded=yes
10976 else
10977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10978 $as_echo "no" >&6; }
10979 GSETTINGS_CFLAGS=""
10980 GSETTINGS_LIBS=""
10981 ## If we have a custom action on failure, don't print errors, but
10982 ## do set a variable so people can do so. Do it in a subshell
10983 ## to capture any diagnostics in invoking pkg-config.
10984 GSETTINGS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gio-2.0 >= 2.26") 2>&1`
10985
10986 fi
10987
10988
10989
10990 else
10991 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10992 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10993 fi
10994 fi
10995
10996 if test $succeeded = yes; then
10997 HAVE_GSETTINGS=yes
10998 else
10999 HAVE_GSETTINGS=no
11000 fi
11001
11002 if test "$HAVE_GSETTINGS" = "yes"; then
11003
11004 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11005
11006 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11007 SETTINGS_LIBS="$GSETTINGS_LIBS"
11008 fi
11009 fi
11010
11011 HAVE_GCONF=no
11012 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11013
11014 succeeded=no
11015
11016 if test "$PKG_CONFIG" = "no" ; then
11017 HAVE_GCONF=no
11018 else
11019 PKG_CONFIG_MIN_VERSION=0.9.0
11020 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11022 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11023
11024 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
11025 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11026 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
11027 edit_cflags="
11028 s,///*,/,g
11029 s/^/ /
11030 s/ -I/ $isystem/g
11031 s/^ //
11032 "
11033 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11034 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11036 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11037 succeeded=yes
11038 else
11039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11040 $as_echo "no" >&6; }
11041 GCONF_CFLAGS=""
11042 GCONF_LIBS=""
11043 ## If we have a custom action on failure, don't print errors, but
11044 ## do set a variable so people can do so. Do it in a subshell
11045 ## to capture any diagnostics in invoking pkg-config.
11046 GCONF_PKG_ERRORS=`($PKG_CONFIG --print-errors "gconf-2.0 >= 2.13") 2>&1`
11047
11048 fi
11049
11050
11051
11052 else
11053 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11054 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11055 fi
11056 fi
11057
11058 if test $succeeded = yes; then
11059 HAVE_GCONF=yes
11060 else
11061 HAVE_GCONF=no
11062 fi
11063
11064 if test "$HAVE_GCONF" = yes; then
11065
11066 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11067
11068 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11069 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11070 fi
11071 fi
11072
11073 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11074
11075 succeeded=no
11076
11077 if test "$PKG_CONFIG" = "no" ; then
11078 HAVE_GOBJECT=no
11079 else
11080 PKG_CONFIG_MIN_VERSION=0.9.0
11081 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11083 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11084
11085 if $PKG_CONFIG --exists "gobject-2.0 >= 2.0" 2>&5 &&
11086 GOBJECT_CFLAGS=`$PKG_CONFIG --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11087 GOBJECT_LIBS=`$PKG_CONFIG --libs "gobject-2.0 >= 2.0" 2>&5`; then
11088 edit_cflags="
11089 s,///*,/,g
11090 s/^/ /
11091 s/ -I/ $isystem/g
11092 s/^ //
11093 "
11094 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11095 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11097 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11098 succeeded=yes
11099 else
11100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11101 $as_echo "no" >&6; }
11102 GOBJECT_CFLAGS=""
11103 GOBJECT_LIBS=""
11104 ## If we have a custom action on failure, don't print errors, but
11105 ## do set a variable so people can do so. Do it in a subshell
11106 ## to capture any diagnostics in invoking pkg-config.
11107 GOBJECT_PKG_ERRORS=`($PKG_CONFIG --print-errors "gobject-2.0 >= 2.0") 2>&1`
11108
11109 fi
11110
11111
11112
11113 else
11114 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11115 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11116 fi
11117 fi
11118
11119 if test $succeeded = yes; then
11120 HAVE_GOBJECT=yes
11121 else
11122 HAVE_GOBJECT=no
11123 fi
11124
11125 if test "$HAVE_GOBJECT" = "yes"; then
11126 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11127 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11128 fi
11129 SAVE_CFLAGS="$CFLAGS"
11130 SAVE_LIBS="$LIBS"
11131 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11132 LIBS="$SETTINGS_LIBS $LIBS"
11133 for ac_func in g_type_init
11134 do :
11135 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11136 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11137 cat >>confdefs.h <<_ACEOF
11138 #define HAVE_G_TYPE_INIT 1
11139 _ACEOF
11140
11141 fi
11142 done
11143
11144 CFLAGS="$SAVE_CFLAGS"
11145 LIBS="$SAVE_LIBS"
11146 fi
11147
11148
11149
11150
11151 HAVE_LIBSELINUX=no
11152 LIBSELINUX_LIBS=
11153 if test "${with_selinux}" = "yes"; then
11154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11155 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11156 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11157 $as_echo_n "(cached) " >&6
11158 else
11159 ac_check_lib_save_LIBS=$LIBS
11160 LIBS="-lselinux $LIBS"
11161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11162 /* end confdefs.h. */
11163
11164 /* Override any GCC internal prototype to avoid an error.
11165 Use char because int might match the return type of a GCC
11166 builtin and then its argument prototype would still apply. */
11167 #ifdef __cplusplus
11168 extern "C"
11169 #endif
11170 char lgetfilecon ();
11171 int
11172 main ()
11173 {
11174 return lgetfilecon ();
11175 ;
11176 return 0;
11177 }
11178 _ACEOF
11179 if ac_fn_c_try_link "$LINENO"; then :
11180 ac_cv_lib_selinux_lgetfilecon=yes
11181 else
11182 ac_cv_lib_selinux_lgetfilecon=no
11183 fi
11184 rm -f core conftest.err conftest.$ac_objext \
11185 conftest$ac_exeext conftest.$ac_ext
11186 LIBS=$ac_check_lib_save_LIBS
11187 fi
11188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11189 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11190 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11191 HAVE_LIBSELINUX=yes
11192 else
11193 HAVE_LIBSELINUX=no
11194 fi
11195
11196 if test "$HAVE_LIBSELINUX" = yes; then
11197
11198 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11199
11200 LIBSELINUX_LIBS=-lselinux
11201 fi
11202 fi
11203
11204
11205 HAVE_GNUTLS=no
11206 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11207 if test "${with_gnutls}" = "yes" ; then
11208
11209 succeeded=no
11210
11211 if test "$PKG_CONFIG" = "no" ; then
11212 HAVE_GNUTLS=no
11213 else
11214 PKG_CONFIG_MIN_VERSION=0.9.0
11215 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11217 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11218
11219 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11220 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11221 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11222 edit_cflags="
11223 s,///*,/,g
11224 s/^/ /
11225 s/ -I/ $isystem/g
11226 s/^ //
11227 "
11228 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11229 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11231 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11232 succeeded=yes
11233 else
11234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11235 $as_echo "no" >&6; }
11236 LIBGNUTLS_CFLAGS=""
11237 LIBGNUTLS_LIBS=""
11238 ## If we have a custom action on failure, don't print errors, but
11239 ## do set a variable so people can do so. Do it in a subshell
11240 ## to capture any diagnostics in invoking pkg-config.
11241 LIBGNUTLS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gnutls >= 2.6.6") 2>&1`
11242
11243 fi
11244
11245
11246
11247 else
11248 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11249 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11250 fi
11251 fi
11252
11253 if test $succeeded = yes; then
11254 HAVE_GNUTLS=yes
11255 else
11256 HAVE_GNUTLS=no
11257 fi
11258
11259 if test "${HAVE_GNUTLS}" = "yes"; then
11260
11261 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11262
11263 fi
11264
11265 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11266 LIBS="$LIBGNUTLS_LIBS $LIBS"
11267 for ac_func in gnutls_certificate_set_verify_function
11268 do :
11269 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11270 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11271 cat >>confdefs.h <<_ACEOF
11272 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11273 _ACEOF
11274 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11275 fi
11276 done
11277
11278
11279 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11280
11281 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11282
11283 fi
11284 fi
11285
11286
11287
11288
11289 HAVE_XAW3D=no
11290 LUCID_LIBW=
11291 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11292 if test "$with_xaw3d" != no; then
11293 if test "${emacs_cv_xaw3d+set}" = set; then :
11294 $as_echo_n "(cached) " >&6
11295 else
11296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11297 /* end confdefs.h. */
11298
11299 #include <X11/Intrinsic.h>
11300 #include <X11/Xaw3d/Simple.h>
11301 int
11302 main ()
11303 {
11304
11305 ;
11306 return 0;
11307 }
11308 _ACEOF
11309 if ac_fn_c_try_link "$LINENO"; then :
11310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11311 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11312 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11313 $as_echo_n "(cached) " >&6
11314 else
11315 ac_check_lib_save_LIBS=$LIBS
11316 LIBS="-lXaw3d $LIBS"
11317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11318 /* end confdefs.h. */
11319
11320 /* Override any GCC internal prototype to avoid an error.
11321 Use char because int might match the return type of a GCC
11322 builtin and then its argument prototype would still apply. */
11323 #ifdef __cplusplus
11324 extern "C"
11325 #endif
11326 char XawScrollbarSetThumb ();
11327 int
11328 main ()
11329 {
11330 return XawScrollbarSetThumb ();
11331 ;
11332 return 0;
11333 }
11334 _ACEOF
11335 if ac_fn_c_try_link "$LINENO"; then :
11336 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11337 else
11338 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11339 fi
11340 rm -f core conftest.err conftest.$ac_objext \
11341 conftest$ac_exeext conftest.$ac_ext
11342 LIBS=$ac_check_lib_save_LIBS
11343 fi
11344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11345 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11346 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11347 emacs_cv_xaw3d=yes
11348 else
11349 emacs_cv_xaw3d=no
11350 fi
11351
11352 else
11353 emacs_cv_xaw3d=no
11354 fi
11355 rm -f core conftest.err conftest.$ac_objext \
11356 conftest$ac_exeext conftest.$ac_ext
11357 fi
11358
11359 else
11360 emacs_cv_xaw3d=no
11361 fi
11362 if test $emacs_cv_xaw3d = yes; then
11363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11364 $as_echo_n "checking for xaw3d... " >&6; }
11365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11366 $as_echo "yes; using Lucid toolkit" >&6; }
11367 USE_X_TOOLKIT=LUCID
11368 HAVE_XAW3D=yes
11369 LUCID_LIBW=-lXaw3d
11370
11371 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11372
11373 else
11374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11375 $as_echo_n "checking for xaw3d... " >&6; }
11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11377 $as_echo "no" >&6; }
11378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11379 $as_echo_n "checking for libXaw... " >&6; }
11380 if test "${emacs_cv_xaw+set}" = set; then :
11381 $as_echo_n "(cached) " >&6
11382 else
11383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11384 /* end confdefs.h. */
11385
11386 #include <X11/Intrinsic.h>
11387 #include <X11/Xaw/Simple.h>
11388 int
11389 main ()
11390 {
11391
11392 ;
11393 return 0;
11394 }
11395 _ACEOF
11396 if ac_fn_c_try_link "$LINENO"; then :
11397 emacs_cv_xaw=yes
11398 else
11399 emacs_cv_xaw=no
11400 fi
11401 rm -f core conftest.err conftest.$ac_objext \
11402 conftest$ac_exeext conftest.$ac_ext
11403 fi
11404
11405 if test $emacs_cv_xaw = yes; then
11406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11407 $as_echo "yes; using Lucid toolkit" >&6; }
11408 USE_X_TOOLKIT=LUCID
11409 LUCID_LIBW=-lXaw
11410 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11411 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11412 else
11413 as_fn_error "No X toolkit could be found.
11414 If you are sure you want Emacs compiled without an X toolkit, pass
11415 --with-x-toolkit=no
11416 to configure. Otherwise, install the development libraries for the toolkit
11417 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11418 fi
11419 fi
11420 fi
11421
11422 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11423
11424 LIBXTR6=
11425 if test "${USE_X_TOOLKIT}" != "none"; then
11426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11427 $as_echo_n "checking X11 toolkit version... " >&6; }
11428 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11429 $as_echo_n "(cached) " >&6
11430 else
11431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11432 /* end confdefs.h. */
11433 #include <X11/Intrinsic.h>
11434 int
11435 main ()
11436 {
11437 #if XtSpecificationRelease < 6
11438 fail;
11439 #endif
11440
11441 ;
11442 return 0;
11443 }
11444 _ACEOF
11445 if ac_fn_c_try_link "$LINENO"; then :
11446 emacs_cv_x11_toolkit_version_6=yes
11447 else
11448 emacs_cv_x11_toolkit_version_6=no
11449 fi
11450 rm -f core conftest.err conftest.$ac_objext \
11451 conftest$ac_exeext conftest.$ac_ext
11452 fi
11453
11454 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11455 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11457 $as_echo "6 or newer" >&6; }
11458
11459 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11460
11461 LIBXTR6="-lSM -lICE"
11462 case "$opsys" in
11463 ## Use libw.a along with X11R6 Xt.
11464 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11465 esac
11466 else
11467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11468 $as_echo "before 6" >&6; }
11469 fi
11470
11471 OLDLIBS="$LIBS"
11472 if test x$HAVE_X11XTR6 = xyes; then
11473 LIBS="-lXt -lSM -lICE $LIBS"
11474 else
11475 LIBS="-lXt $LIBS"
11476 fi
11477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11478 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11479 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11480 $as_echo_n "(cached) " >&6
11481 else
11482 ac_check_lib_save_LIBS=$LIBS
11483 LIBS="-lXmu $LIBS"
11484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11485 /* end confdefs.h. */
11486
11487 /* Override any GCC internal prototype to avoid an error.
11488 Use char because int might match the return type of a GCC
11489 builtin and then its argument prototype would still apply. */
11490 #ifdef __cplusplus
11491 extern "C"
11492 #endif
11493 char XmuConvertStandardSelection ();
11494 int
11495 main ()
11496 {
11497 return XmuConvertStandardSelection ();
11498 ;
11499 return 0;
11500 }
11501 _ACEOF
11502 if ac_fn_c_try_link "$LINENO"; then :
11503 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11504 else
11505 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11506 fi
11507 rm -f core conftest.err conftest.$ac_objext \
11508 conftest$ac_exeext conftest.$ac_ext
11509 LIBS=$ac_check_lib_save_LIBS
11510 fi
11511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11512 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11513 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11514 cat >>confdefs.h <<_ACEOF
11515 #define HAVE_LIBXMU 1
11516 _ACEOF
11517
11518 LIBS="-lXmu $LIBS"
11519
11520 fi
11521
11522 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11523 fi
11524
11525
11526 LIBXMU=-lXmu
11527 case $opsys in
11528 ## These systems don't supply Xmu.
11529 hpux* | aix4-2 )
11530 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11531 ;;
11532 esac
11533
11534
11535 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11536 if test "${HAVE_X11}" = "yes"; then
11537 if test "${USE_X_TOOLKIT}" != "none"; then
11538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11539 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11540 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11541 $as_echo_n "(cached) " >&6
11542 else
11543 ac_check_lib_save_LIBS=$LIBS
11544 LIBS="-lXext $LIBS"
11545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11546 /* end confdefs.h. */
11547
11548 /* Override any GCC internal prototype to avoid an error.
11549 Use char because int might match the return type of a GCC
11550 builtin and then its argument prototype would still apply. */
11551 #ifdef __cplusplus
11552 extern "C"
11553 #endif
11554 char XShapeQueryExtension ();
11555 int
11556 main ()
11557 {
11558 return XShapeQueryExtension ();
11559 ;
11560 return 0;
11561 }
11562 _ACEOF
11563 if ac_fn_c_try_link "$LINENO"; then :
11564 ac_cv_lib_Xext_XShapeQueryExtension=yes
11565 else
11566 ac_cv_lib_Xext_XShapeQueryExtension=no
11567 fi
11568 rm -f core conftest.err conftest.$ac_objext \
11569 conftest$ac_exeext conftest.$ac_ext
11570 LIBS=$ac_check_lib_save_LIBS
11571 fi
11572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11573 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11574 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11575 cat >>confdefs.h <<_ACEOF
11576 #define HAVE_LIBXEXT 1
11577 _ACEOF
11578
11579 LIBS="-lXext $LIBS"
11580
11581 fi
11582
11583 fi
11584 fi
11585
11586 LIBXP=
11587 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11588 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11589 if test -d /usr/include/openmotif; then
11590 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11591 emacs_cv_openmotif=yes
11592 case "$canonical" in
11593 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11594 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11595 ;;
11596 *)
11597 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11598 esac
11599 else
11600 emacs_cv_openmotif=no
11601 fi
11602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11603 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11604 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11605 $as_echo_n "(cached) " >&6
11606 else
11607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11608 /* end confdefs.h. */
11609 #include <Xm/Xm.h>
11610 int
11611 main ()
11612 {
11613 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11614 int x = 5;
11615 #else
11616 Motif version prior to 2.1.
11617 #endif
11618 ;
11619 return 0;
11620 }
11621 _ACEOF
11622 if ac_fn_c_try_compile "$LINENO"; then :
11623 emacs_cv_motif_version_2_1=yes
11624 else
11625 emacs_cv_motif_version_2_1=no
11626 fi
11627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11628 fi
11629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11630 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11631 if test $emacs_cv_motif_version_2_1 = yes; then
11632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11633 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11634 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11635 $as_echo_n "(cached) " >&6
11636 else
11637 ac_check_lib_save_LIBS=$LIBS
11638 LIBS="-lXp $LIBS"
11639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11640 /* end confdefs.h. */
11641
11642 /* Override any GCC internal prototype to avoid an error.
11643 Use char because int might match the return type of a GCC
11644 builtin and then its argument prototype would still apply. */
11645 #ifdef __cplusplus
11646 extern "C"
11647 #endif
11648 char XpCreateContext ();
11649 int
11650 main ()
11651 {
11652 return XpCreateContext ();
11653 ;
11654 return 0;
11655 }
11656 _ACEOF
11657 if ac_fn_c_try_link "$LINENO"; then :
11658 ac_cv_lib_Xp_XpCreateContext=yes
11659 else
11660 ac_cv_lib_Xp_XpCreateContext=no
11661 fi
11662 rm -f core conftest.err conftest.$ac_objext \
11663 conftest$ac_exeext conftest.$ac_ext
11664 LIBS=$ac_check_lib_save_LIBS
11665 fi
11666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11667 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11668 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11669 LIBXP=-lXp
11670 fi
11671
11672 if test x$emacs_cv_openmotif = xyes; then
11673 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11674 fi
11675 else
11676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11677 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11678 if test "${emacs_cv_lesstif+set}" = set; then :
11679 $as_echo_n "(cached) " >&6
11680 else
11681 # We put this in CFLAGS temporarily to precede other -I options
11682 # that might be in CFLAGS temporarily.
11683 # We put this in CPPFLAGS where it precedes the other -I options.
11684 OLD_CPPFLAGS=$CPPFLAGS
11685 OLD_CFLAGS=$CFLAGS
11686 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11687 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11689 /* end confdefs.h. */
11690 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11691 int
11692 main ()
11693 {
11694 int x = 5;
11695 ;
11696 return 0;
11697 }
11698 _ACEOF
11699 if ac_fn_c_try_compile "$LINENO"; then :
11700 emacs_cv_lesstif=yes
11701 else
11702 emacs_cv_lesstif=no
11703 fi
11704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11705 fi
11706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11707 $as_echo "$emacs_cv_lesstif" >&6; }
11708 if test $emacs_cv_lesstif = yes; then
11709 # Make sure this -I option remains in CPPFLAGS after it is set
11710 # back to REAL_CPPFLAGS.
11711 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11712 # have those other -I options anyway. Ultimately, having this
11713 # directory ultimately in CPPFLAGS will be enough.
11714 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11715 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11716 else
11717 CFLAGS=$OLD_CFLAGS
11718 CPPFLAGS=$OLD_CPPFLAGS
11719 fi
11720 fi
11721 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11722 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11723
11724 else
11725 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11726 fi
11727
11728
11729 fi
11730
11731
11732 USE_TOOLKIT_SCROLL_BARS=no
11733 if test "${with_toolkit_scroll_bars}" != "no"; then
11734 if test "${USE_X_TOOLKIT}" != "none"; then
11735 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11736 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11737
11738 HAVE_XAW3D=no
11739 USE_TOOLKIT_SCROLL_BARS=yes
11740 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11741 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11742
11743 USE_TOOLKIT_SCROLL_BARS=yes
11744 fi
11745 elif test "${HAVE_GTK}" = "yes"; then
11746 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11747
11748 USE_TOOLKIT_SCROLL_BARS=yes
11749 elif test "${HAVE_NS}" = "yes"; then
11750 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11751
11752 USE_TOOLKIT_SCROLL_BARS=yes
11753 elif test "${HAVE_W32}" = "yes"; then
11754 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11755
11756 USE_TOOLKIT_SCROLL_BARS=yes
11757 fi
11758 fi
11759
11760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11761 /* end confdefs.h. */
11762
11763 #include <X11/Xlib.h>
11764 #include <X11/Xresource.h>
11765 int
11766 main ()
11767 {
11768 XIMProc callback;
11769 ;
11770 return 0;
11771 }
11772 _ACEOF
11773 if ac_fn_c_try_compile "$LINENO"; then :
11774 HAVE_XIM=yes
11775
11776 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11777
11778 else
11779 HAVE_XIM=no
11780 fi
11781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11782
11783
11784 if test "${with_xim}" != "no"; then
11785
11786 $as_echo "#define USE_XIM 1" >>confdefs.h
11787
11788 fi
11789
11790
11791 if test "${HAVE_XIM}" != "no"; then
11792 late_CFLAGS=$CFLAGS
11793 if test "$GCC" = yes; then
11794 CFLAGS="$CFLAGS --pedantic-errors"
11795 fi
11796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11797 /* end confdefs.h. */
11798
11799 #include <X11/Xlib.h>
11800 #include <X11/Xresource.h>
11801 int
11802 main ()
11803 {
11804 Display *display;
11805 XrmDatabase db;
11806 char *res_name;
11807 char *res_class;
11808 XIMProc callback;
11809 XPointer *client_data;
11810 #ifndef __GNUC__
11811 /* If we're not using GCC, it's probably not XFree86, and this is
11812 probably right, but we can't use something like --pedantic-errors. */
11813 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11814 char*, XIMProc, XPointer*);
11815 #endif
11816 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11817 client_data);
11818 ;
11819 return 0;
11820 }
11821 _ACEOF
11822 if ac_fn_c_try_compile "$LINENO"; then :
11823 emacs_cv_arg6_star=yes
11824 fi
11825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11826 if test "$emacs_cv_arg6_star" = yes; then
11827 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11828
11829 else
11830 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11831
11832 fi
11833 CFLAGS=$late_CFLAGS
11834 fi
11835
11836 ### Start of font-backend (under any platform) section.
11837 # (nothing here yet -- this is a placeholder)
11838 ### End of font-backend (under any platform) section.
11839
11840 ### Start of font-backend (under X11) section.
11841 if test "${HAVE_X11}" = "yes"; then
11842
11843 succeeded=no
11844
11845 if test "$PKG_CONFIG" = "no" ; then
11846 HAVE_FC=no
11847 else
11848 PKG_CONFIG_MIN_VERSION=0.9.0
11849 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11851 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11852
11853 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11854 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11855 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11856 edit_cflags="
11857 s,///*,/,g
11858 s/^/ /
11859 s/ -I/ $isystem/g
11860 s/^ //
11861 "
11862 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11863 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11865 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11866 succeeded=yes
11867 else
11868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11869 $as_echo "no" >&6; }
11870 FONTCONFIG_CFLAGS=""
11871 FONTCONFIG_LIBS=""
11872 ## If we have a custom action on failure, don't print errors, but
11873 ## do set a variable so people can do so. Do it in a subshell
11874 ## to capture any diagnostics in invoking pkg-config.
11875 FONTCONFIG_PKG_ERRORS=`($PKG_CONFIG --print-errors "fontconfig >= 2.2.0") 2>&1`
11876
11877 fi
11878
11879
11880
11881 else
11882 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11883 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11884 fi
11885 fi
11886
11887 if test $succeeded = yes; then
11888 HAVE_FC=yes
11889 else
11890 HAVE_FC=no
11891 fi
11892
11893
11894 ## Use -lXft if available, unless `--with-xft=no'.
11895 HAVE_XFT=maybe
11896 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11897 with_xft="no";
11898 fi
11899 if test "x${with_xft}" != "xno"; then
11900
11901
11902 succeeded=no
11903
11904 if test "$PKG_CONFIG" = "no" ; then
11905 HAVE_XFT=no
11906 else
11907 PKG_CONFIG_MIN_VERSION=0.9.0
11908 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11910 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11911
11912 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11913 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11914 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11915 edit_cflags="
11916 s,///*,/,g
11917 s/^/ /
11918 s/ -I/ $isystem/g
11919 s/^ //
11920 "
11921 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11922 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11924 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11925 succeeded=yes
11926 else
11927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11928 $as_echo "no" >&6; }
11929 XFT_CFLAGS=""
11930 XFT_LIBS=""
11931 ## If we have a custom action on failure, don't print errors, but
11932 ## do set a variable so people can do so. Do it in a subshell
11933 ## to capture any diagnostics in invoking pkg-config.
11934 XFT_PKG_ERRORS=`($PKG_CONFIG --print-errors "xft >= 0.13.0") 2>&1`
11935
11936 fi
11937
11938
11939
11940 else
11941 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11942 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11943 fi
11944 fi
11945
11946 if test $succeeded = yes; then
11947 :
11948 else
11949 HAVE_XFT=no
11950 fi
11951
11952 ## Because xftfont.c uses XRenderQueryExtension, we also
11953 ## need to link to -lXrender.
11954 HAVE_XRENDER=no
11955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11956 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11957 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11958 $as_echo_n "(cached) " >&6
11959 else
11960 ac_check_lib_save_LIBS=$LIBS
11961 LIBS="-lXrender $LIBS"
11962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11963 /* end confdefs.h. */
11964
11965 /* Override any GCC internal prototype to avoid an error.
11966 Use char because int might match the return type of a GCC
11967 builtin and then its argument prototype would still apply. */
11968 #ifdef __cplusplus
11969 extern "C"
11970 #endif
11971 char XRenderQueryExtension ();
11972 int
11973 main ()
11974 {
11975 return XRenderQueryExtension ();
11976 ;
11977 return 0;
11978 }
11979 _ACEOF
11980 if ac_fn_c_try_link "$LINENO"; then :
11981 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11982 else
11983 ac_cv_lib_Xrender_XRenderQueryExtension=no
11984 fi
11985 rm -f core conftest.err conftest.$ac_objext \
11986 conftest$ac_exeext conftest.$ac_ext
11987 LIBS=$ac_check_lib_save_LIBS
11988 fi
11989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11990 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11991 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11992 HAVE_XRENDER=yes
11993 fi
11994
11995 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11996 OLD_CPPFLAGS="$CPPFLAGS"
11997 OLD_CFLAGS="$CFLAGS"
11998 OLD_LIBS="$LIBS"
11999 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12000 CFLAGS="$CFLAGS $XFT_CFLAGS"
12001 XFT_LIBS="-lXrender $XFT_LIBS"
12002 LIBS="$XFT_LIBS $LIBS"
12003 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12004 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12006 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12007 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12008 $as_echo_n "(cached) " >&6
12009 else
12010 ac_check_lib_save_LIBS=$LIBS
12011 LIBS="-lXft $XFT_LIBS $LIBS"
12012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12013 /* end confdefs.h. */
12014
12015 /* Override any GCC internal prototype to avoid an error.
12016 Use char because int might match the return type of a GCC
12017 builtin and then its argument prototype would still apply. */
12018 #ifdef __cplusplus
12019 extern "C"
12020 #endif
12021 char XftFontOpen ();
12022 int
12023 main ()
12024 {
12025 return XftFontOpen ();
12026 ;
12027 return 0;
12028 }
12029 _ACEOF
12030 if ac_fn_c_try_link "$LINENO"; then :
12031 ac_cv_lib_Xft_XftFontOpen=yes
12032 else
12033 ac_cv_lib_Xft_XftFontOpen=no
12034 fi
12035 rm -f core conftest.err conftest.$ac_objext \
12036 conftest$ac_exeext conftest.$ac_ext
12037 LIBS=$ac_check_lib_save_LIBS
12038 fi
12039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12040 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12041 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12042 HAVE_XFT=yes
12043 fi
12044
12045 fi
12046
12047
12048
12049 if test "${HAVE_XFT}" = "yes"; then
12050
12051 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12052
12053
12054 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12055 else
12056 CPPFLAGS="$OLD_CPPFLAGS"
12057 CFLAGS="$OLD_CFLAGS"
12058 LIBS="$OLD_LIBS"
12059 fi # "${HAVE_XFT}" = "yes"
12060 fi # "$HAVE_XFT" != no
12061 fi # "x${with_xft}" != "xno"
12062
12063 ## We used to allow building with FreeType and without Xft.
12064 ## However, the ftx font backend driver is not in good shape.
12065 if test "$HAVE_XFT" != "yes"; then
12066 HAVE_XFT=no
12067 HAVE_FREETYPE=no
12068 else
12069
12070 succeeded=no
12071
12072 if test "$PKG_CONFIG" = "no" ; then
12073 HAVE_FREETYPE=no
12074 else
12075 PKG_CONFIG_MIN_VERSION=0.9.0
12076 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12078 $as_echo_n "checking for freetype2... " >&6; }
12079
12080 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
12081 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
12082 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
12083 edit_cflags="
12084 s,///*,/,g
12085 s/^/ /
12086 s/ -I/ $isystem/g
12087 s/^ //
12088 "
12089 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12090 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12092 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12093 succeeded=yes
12094 else
12095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12096 $as_echo "no" >&6; }
12097 FREETYPE_CFLAGS=""
12098 FREETYPE_LIBS=""
12099 ## If we have a custom action on failure, don't print errors, but
12100 ## do set a variable so people can do so. Do it in a subshell
12101 ## to capture any diagnostics in invoking pkg-config.
12102 FREETYPE_PKG_ERRORS=`($PKG_CONFIG --print-errors "freetype2") 2>&1`
12103
12104 fi
12105
12106
12107
12108 else
12109 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12110 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12111 fi
12112 fi
12113
12114 if test $succeeded = yes; then
12115 HAVE_FREETYPE=yes
12116 else
12117 HAVE_FREETYPE=no
12118 fi
12119
12120
12121 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12122 fi
12123
12124 HAVE_LIBOTF=no
12125 if test "${HAVE_FREETYPE}" = "yes"; then
12126
12127 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12128
12129 if test "${with_libotf}" != "no"; then
12130
12131 succeeded=no
12132
12133 if test "$PKG_CONFIG" = "no" ; then
12134 HAVE_LIBOTF=no
12135 else
12136 PKG_CONFIG_MIN_VERSION=0.9.0
12137 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12139 $as_echo_n "checking for libotf... " >&6; }
12140
12141 if $PKG_CONFIG --exists "libotf" 2>&5 &&
12142 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
12143 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
12144 edit_cflags="
12145 s,///*,/,g
12146 s/^/ /
12147 s/ -I/ $isystem/g
12148 s/^ //
12149 "
12150 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12151 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12153 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12154 succeeded=yes
12155 else
12156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12157 $as_echo "no" >&6; }
12158 LIBOTF_CFLAGS=""
12159 LIBOTF_LIBS=""
12160 ## If we have a custom action on failure, don't print errors, but
12161 ## do set a variable so people can do so. Do it in a subshell
12162 ## to capture any diagnostics in invoking pkg-config.
12163 LIBOTF_PKG_ERRORS=`($PKG_CONFIG --print-errors "libotf") 2>&1`
12164
12165 fi
12166
12167
12168
12169 else
12170 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12171 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12172 fi
12173 fi
12174
12175 if test $succeeded = yes; then
12176 HAVE_LIBOTF=yes
12177 else
12178 HAVE_LIBOTF=no
12179 fi
12180
12181 if test "$HAVE_LIBOTF" = "yes"; then
12182
12183 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12184
12185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12186 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12187 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12188 $as_echo_n "(cached) " >&6
12189 else
12190 ac_check_lib_save_LIBS=$LIBS
12191 LIBS="-lotf $LIBS"
12192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12193 /* end confdefs.h. */
12194
12195 /* Override any GCC internal prototype to avoid an error.
12196 Use char because int might match the return type of a GCC
12197 builtin and then its argument prototype would still apply. */
12198 #ifdef __cplusplus
12199 extern "C"
12200 #endif
12201 char OTF_get_variation_glyphs ();
12202 int
12203 main ()
12204 {
12205 return OTF_get_variation_glyphs ();
12206 ;
12207 return 0;
12208 }
12209 _ACEOF
12210 if ac_fn_c_try_link "$LINENO"; then :
12211 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12212 else
12213 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12214 fi
12215 rm -f core conftest.err conftest.$ac_objext \
12216 conftest$ac_exeext conftest.$ac_ext
12217 LIBS=$ac_check_lib_save_LIBS
12218 fi
12219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12220 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12221 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12222 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12223 else
12224 HAVE_OTF_GET_VARIATION_GLYPHS=no
12225 fi
12226
12227 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12228
12229 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12230
12231 fi
12232 fi
12233 fi
12234 fi
12235
12236 HAVE_M17N_FLT=no
12237 if test "${HAVE_LIBOTF}" = yes; then
12238 if test "${with_m17n_flt}" != "no"; then
12239
12240 succeeded=no
12241
12242 if test "$PKG_CONFIG" = "no" ; then
12243 HAVE_M17N_FLT=no
12244 else
12245 PKG_CONFIG_MIN_VERSION=0.9.0
12246 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12248 $as_echo_n "checking for m17n-flt... " >&6; }
12249
12250 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12251 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12252 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12253 edit_cflags="
12254 s,///*,/,g
12255 s/^/ /
12256 s/ -I/ $isystem/g
12257 s/^ //
12258 "
12259 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12260 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12262 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12263 succeeded=yes
12264 else
12265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12266 $as_echo "no" >&6; }
12267 M17N_FLT_CFLAGS=""
12268 M17N_FLT_LIBS=""
12269 ## If we have a custom action on failure, don't print errors, but
12270 ## do set a variable so people can do so. Do it in a subshell
12271 ## to capture any diagnostics in invoking pkg-config.
12272 M17N_FLT_PKG_ERRORS=`($PKG_CONFIG --print-errors "m17n-flt") 2>&1`
12273
12274 fi
12275
12276
12277
12278 else
12279 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12280 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12281 fi
12282 fi
12283
12284 if test $succeeded = yes; then
12285 HAVE_M17N_FLT=yes
12286 else
12287 HAVE_M17N_FLT=no
12288 fi
12289
12290 if test "$HAVE_M17N_FLT" = "yes"; then
12291
12292 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12293
12294 fi
12295 fi
12296 fi
12297 else
12298 HAVE_XFT=no
12299 HAVE_FREETYPE=no
12300 HAVE_LIBOTF=no
12301 HAVE_M17N_FLT=no
12302 fi
12303
12304 ### End of font-backend (under X11) section.
12305
12306
12307
12308
12309
12310
12311
12312
12313
12314
12315 ### Use -lXpm if available, unless `--with-xpm=no'.
12316 HAVE_XPM=no
12317 LIBXPM=
12318
12319 if test "${HAVE_W32}" = "yes"; then
12320 if test "${with_xpm}" != "no"; then
12321 SAVE_CPPFLAGS="$CPPFLAGS"
12322 SAVE_LDFLAGS="$LDFLAGS"
12323 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
12324 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
12325 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12326 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
12328 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
12329 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
12330 $as_echo_n "(cached) " >&6
12331 else
12332 ac_check_lib_save_LIBS=$LIBS
12333 LIBS="-lXpm $LIBS"
12334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12335 /* end confdefs.h. */
12336
12337 /* Override any GCC internal prototype to avoid an error.
12338 Use char because int might match the return type of a GCC
12339 builtin and then its argument prototype would still apply. */
12340 #ifdef __cplusplus
12341 extern "C"
12342 #endif
12343 char XpmReadFileToImage ();
12344 int
12345 main ()
12346 {
12347 return XpmReadFileToImage ();
12348 ;
12349 return 0;
12350 }
12351 _ACEOF
12352 if ac_fn_c_try_link "$LINENO"; then :
12353 ac_cv_lib_Xpm_XpmReadFileToImage=yes
12354 else
12355 ac_cv_lib_Xpm_XpmReadFileToImage=no
12356 fi
12357 rm -f core conftest.err conftest.$ac_objext \
12358 conftest$ac_exeext conftest.$ac_ext
12359 LIBS=$ac_check_lib_save_LIBS
12360 fi
12361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
12362 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
12363 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
12364 HAVE_XPM=yes
12365 fi
12366
12367 fi
12368
12369
12370 if test "${HAVE_XPM}" = "yes"; then
12371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12372 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12374 /* end confdefs.h. */
12375 #include "X11/xpm.h"
12376 #ifndef XpmReturnAllocPixels
12377 no_return_alloc_pixels
12378 #endif
12379
12380 _ACEOF
12381 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12382 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12383 HAVE_XPM=no
12384 else
12385 HAVE_XPM=yes
12386 fi
12387 rm -f conftest*
12388
12389
12390 if test "${HAVE_XPM}" = "yes"; then
12391 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
12392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12393 $as_echo "yes" >&6; }
12394 else
12395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12396 $as_echo "no" >&6; }
12397 CPPFLAGS="$SAVE_CPPFLAGS"
12398 LDFLAGS="$SAVE_LDFLAGS"
12399 fi
12400 fi
12401 fi
12402
12403 if test "${HAVE_XPM}" = "yes"; then
12404
12405 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12406
12407 LIBXPM=-lXpm
12408 fi
12409 fi
12410
12411 if test "${HAVE_X11}" = "yes"; then
12412 if test "${with_xpm}" != "no"; then
12413 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12414 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12416 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12417 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12418 $as_echo_n "(cached) " >&6
12419 else
12420 ac_check_lib_save_LIBS=$LIBS
12421 LIBS="-lXpm -lX11 $LIBS"
12422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12423 /* end confdefs.h. */
12424
12425 /* Override any GCC internal prototype to avoid an error.
12426 Use char because int might match the return type of a GCC
12427 builtin and then its argument prototype would still apply. */
12428 #ifdef __cplusplus
12429 extern "C"
12430 #endif
12431 char XpmReadFileToPixmap ();
12432 int
12433 main ()
12434 {
12435 return XpmReadFileToPixmap ();
12436 ;
12437 return 0;
12438 }
12439 _ACEOF
12440 if ac_fn_c_try_link "$LINENO"; then :
12441 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12442 else
12443 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12444 fi
12445 rm -f core conftest.err conftest.$ac_objext \
12446 conftest$ac_exeext conftest.$ac_ext
12447 LIBS=$ac_check_lib_save_LIBS
12448 fi
12449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12450 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12451 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12452 HAVE_XPM=yes
12453 fi
12454
12455 fi
12456
12457
12458 if test "${HAVE_XPM}" = "yes"; then
12459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12460 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12462 /* end confdefs.h. */
12463 #include "X11/xpm.h"
12464 #ifndef XpmReturnAllocPixels
12465 no_return_alloc_pixels
12466 #endif
12467
12468 _ACEOF
12469 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12470 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12471 HAVE_XPM=no
12472 else
12473 HAVE_XPM=yes
12474 fi
12475 rm -f conftest*
12476
12477
12478 if test "${HAVE_XPM}" = "yes"; then
12479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12480 $as_echo "yes" >&6; }
12481 else
12482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12483 $as_echo "no" >&6; }
12484 fi
12485 fi
12486 fi
12487
12488 if test "${HAVE_XPM}" = "yes"; then
12489
12490 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12491
12492 LIBXPM=-lXpm
12493 fi
12494 fi
12495
12496
12497
12498 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12499 HAVE_JPEG=no
12500 LIBJPEG=
12501 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12502 if test "${with_jpeg}" != "no"; then
12503 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12504 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12506 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12507 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12508 $as_echo_n "(cached) " >&6
12509 else
12510 ac_check_lib_save_LIBS=$LIBS
12511 LIBS="-ljpeg $LIBS"
12512 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12513 /* end confdefs.h. */
12514
12515 /* Override any GCC internal prototype to avoid an error.
12516 Use char because int might match the return type of a GCC
12517 builtin and then its argument prototype would still apply. */
12518 #ifdef __cplusplus
12519 extern "C"
12520 #endif
12521 char jpeg_destroy_compress ();
12522 int
12523 main ()
12524 {
12525 return jpeg_destroy_compress ();
12526 ;
12527 return 0;
12528 }
12529 _ACEOF
12530 if ac_fn_c_try_link "$LINENO"; then :
12531 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12532 else
12533 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12534 fi
12535 rm -f core conftest.err conftest.$ac_objext \
12536 conftest$ac_exeext conftest.$ac_ext
12537 LIBS=$ac_check_lib_save_LIBS
12538 fi
12539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12540 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12541 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12542 HAVE_JPEG=yes
12543 fi
12544
12545 fi
12546
12547
12548 fi
12549
12550 if test "${HAVE_JPEG}" = "yes"; then
12551 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12552
12553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12554 /* end confdefs.h. */
12555 #include <jpeglib.h>
12556 version=JPEG_LIB_VERSION
12557
12558 _ACEOF
12559 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12560 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12561 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12562
12563 else
12564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12565 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12566 HAVE_JPEG=no
12567 fi
12568 rm -f conftest*
12569
12570 fi
12571 if test "${HAVE_JPEG}" = "yes"; then
12572 LIBJPEG=-ljpeg
12573 fi
12574 fi
12575
12576
12577 ### Use -lpng if available, unless `--with-png=no'.
12578 HAVE_PNG=no
12579 LIBPNG=
12580 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12581 if test "${with_png}" != "no"; then
12582 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12583 # in /usr/include/libpng.
12584 for ac_header in png.h libpng/png.h
12585 do :
12586 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12587 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12588 eval as_val=\$$as_ac_Header
12589 if test "x$as_val" = x""yes; then :
12590 cat >>confdefs.h <<_ACEOF
12591 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12592 _ACEOF
12593 break
12594 fi
12595
12596 done
12597
12598 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12600 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12601 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12602 $as_echo_n "(cached) " >&6
12603 else
12604 ac_check_lib_save_LIBS=$LIBS
12605 LIBS="-lpng -lz -lm $LIBS"
12606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12607 /* end confdefs.h. */
12608
12609 /* Override any GCC internal prototype to avoid an error.
12610 Use char because int might match the return type of a GCC
12611 builtin and then its argument prototype would still apply. */
12612 #ifdef __cplusplus
12613 extern "C"
12614 #endif
12615 char png_get_channels ();
12616 int
12617 main ()
12618 {
12619 return png_get_channels ();
12620 ;
12621 return 0;
12622 }
12623 _ACEOF
12624 if ac_fn_c_try_link "$LINENO"; then :
12625 ac_cv_lib_png_png_get_channels=yes
12626 else
12627 ac_cv_lib_png_png_get_channels=no
12628 fi
12629 rm -f core conftest.err conftest.$ac_objext \
12630 conftest$ac_exeext conftest.$ac_ext
12631 LIBS=$ac_check_lib_save_LIBS
12632 fi
12633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12634 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12635 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12636 HAVE_PNG=yes
12637 fi
12638
12639 fi
12640 fi
12641
12642 if test "${HAVE_PNG}" = "yes"; then
12643
12644 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12645
12646 LIBPNG="-lpng -lz -lm"
12647
12648 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12649 # include <libpng/png.h>
12650 #else
12651 # include <png.h>
12652 #endif
12653
12654 "
12655 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12656
12657 else
12658
12659 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12660
12661 fi
12662
12663 fi
12664 fi
12665
12666
12667 ### Use -ltiff if available, unless `--with-tiff=no'.
12668 HAVE_TIFF=no
12669 LIBTIFF=
12670 if test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
12671 if test "${with_tiff}" != "no"; then
12672 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12673 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12674 tifflibs="-lz -lm"
12675 # At least one tiff package requires the jpeg library.
12676 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12678 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12679 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12680 $as_echo_n "(cached) " >&6
12681 else
12682 ac_check_lib_save_LIBS=$LIBS
12683 LIBS="-ltiff $tifflibs $LIBS"
12684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12685 /* end confdefs.h. */
12686
12687 /* Override any GCC internal prototype to avoid an error.
12688 Use char because int might match the return type of a GCC
12689 builtin and then its argument prototype would still apply. */
12690 #ifdef __cplusplus
12691 extern "C"
12692 #endif
12693 char TIFFGetVersion ();
12694 int
12695 main ()
12696 {
12697 return TIFFGetVersion ();
12698 ;
12699 return 0;
12700 }
12701 _ACEOF
12702 if ac_fn_c_try_link "$LINENO"; then :
12703 ac_cv_lib_tiff_TIFFGetVersion=yes
12704 else
12705 ac_cv_lib_tiff_TIFFGetVersion=no
12706 fi
12707 rm -f core conftest.err conftest.$ac_objext \
12708 conftest$ac_exeext conftest.$ac_ext
12709 LIBS=$ac_check_lib_save_LIBS
12710 fi
12711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12712 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12713 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12714 HAVE_TIFF=yes
12715 fi
12716
12717 fi
12718
12719
12720 fi
12721
12722 if test "${HAVE_TIFF}" = "yes"; then
12723
12724 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12725
12726 LIBTIFF=-ltiff
12727 fi
12728 fi
12729
12730
12731 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12732 HAVE_GIF=no
12733 LIBGIF=
12734 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
12735 || test "${HAVE_W32}" = "yes"; then
12736 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12737 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12738 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12739 # Earlier versions can crash Emacs.
12740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12741 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12742 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12743 $as_echo_n "(cached) " >&6
12744 else
12745 ac_check_lib_save_LIBS=$LIBS
12746 LIBS="-lgif $LIBS"
12747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12748 /* end confdefs.h. */
12749
12750 /* Override any GCC internal prototype to avoid an error.
12751 Use char because int might match the return type of a GCC
12752 builtin and then its argument prototype would still apply. */
12753 #ifdef __cplusplus
12754 extern "C"
12755 #endif
12756 char EGifPutExtensionLast ();
12757 int
12758 main ()
12759 {
12760 return EGifPutExtensionLast ();
12761 ;
12762 return 0;
12763 }
12764 _ACEOF
12765 if ac_fn_c_try_link "$LINENO"; then :
12766 ac_cv_lib_gif_EGifPutExtensionLast=yes
12767 else
12768 ac_cv_lib_gif_EGifPutExtensionLast=no
12769 fi
12770 rm -f core conftest.err conftest.$ac_objext \
12771 conftest$ac_exeext conftest.$ac_ext
12772 LIBS=$ac_check_lib_save_LIBS
12773 fi
12774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12775 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12776 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12777 HAVE_GIF=yes
12778 else
12779 HAVE_GIF=maybe
12780 fi
12781
12782 fi
12783
12784
12785
12786 if test "$HAVE_GIF" = yes; then
12787 LIBGIF=-lgif
12788 elif test "$HAVE_GIF" = maybe; then
12789 # If gif_lib.h but no libgif, try libungif.
12790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12791 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12792 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12793 $as_echo_n "(cached) " >&6
12794 else
12795 ac_check_lib_save_LIBS=$LIBS
12796 LIBS="-lungif $LIBS"
12797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12798 /* end confdefs.h. */
12799
12800 /* Override any GCC internal prototype to avoid an error.
12801 Use char because int might match the return type of a GCC
12802 builtin and then its argument prototype would still apply. */
12803 #ifdef __cplusplus
12804 extern "C"
12805 #endif
12806 char EGifPutExtensionLast ();
12807 int
12808 main ()
12809 {
12810 return EGifPutExtensionLast ();
12811 ;
12812 return 0;
12813 }
12814 _ACEOF
12815 if ac_fn_c_try_link "$LINENO"; then :
12816 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12817 else
12818 ac_cv_lib_ungif_EGifPutExtensionLast=no
12819 fi
12820 rm -f core conftest.err conftest.$ac_objext \
12821 conftest$ac_exeext conftest.$ac_ext
12822 LIBS=$ac_check_lib_save_LIBS
12823 fi
12824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12825 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12826 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12827 HAVE_GIF=yes
12828 else
12829 HAVE_GIF=no
12830 fi
12831
12832 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12833 fi
12834
12835 if test "${HAVE_GIF}" = "yes"; then
12836
12837 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12838
12839 fi
12840 fi
12841
12842
12843 if test "${HAVE_X11}" = "yes"; then
12844 MISSING=""
12845 WITH_NO=""
12846 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12847 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12848 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12849 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12850 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12851 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12852 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12853 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12854 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12855 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12856
12857 if test "X${MISSING}" != X; then
12858 as_fn_error "The following required libraries were not found:
12859 $MISSING
12860 Maybe some development libraries/packages are missing?
12861 If you don't want to link with them give
12862 $WITH_NO
12863 as options to configure" "$LINENO" 5
12864 fi
12865 fi
12866
12867 ### Use -lgpm if available, unless `--with-gpm=no'.
12868 HAVE_GPM=no
12869 LIBGPM=
12870 if test "${with_gpm}" != "no"; then
12871 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12872 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12874 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12875 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12876 $as_echo_n "(cached) " >&6
12877 else
12878 ac_check_lib_save_LIBS=$LIBS
12879 LIBS="-lgpm $LIBS"
12880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12881 /* end confdefs.h. */
12882
12883 /* Override any GCC internal prototype to avoid an error.
12884 Use char because int might match the return type of a GCC
12885 builtin and then its argument prototype would still apply. */
12886 #ifdef __cplusplus
12887 extern "C"
12888 #endif
12889 char Gpm_Open ();
12890 int
12891 main ()
12892 {
12893 return Gpm_Open ();
12894 ;
12895 return 0;
12896 }
12897 _ACEOF
12898 if ac_fn_c_try_link "$LINENO"; then :
12899 ac_cv_lib_gpm_Gpm_Open=yes
12900 else
12901 ac_cv_lib_gpm_Gpm_Open=no
12902 fi
12903 rm -f core conftest.err conftest.$ac_objext \
12904 conftest$ac_exeext conftest.$ac_ext
12905 LIBS=$ac_check_lib_save_LIBS
12906 fi
12907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12908 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12909 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12910 HAVE_GPM=yes
12911 fi
12912
12913 fi
12914
12915
12916
12917 if test "${HAVE_GPM}" = "yes"; then
12918
12919 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12920
12921 LIBGPM=-lgpm
12922 fi
12923 fi
12924
12925
12926
12927
12928
12929
12930 GNUSTEP_CFLAGS=
12931 ### Use NeXTstep API to implement GUI.
12932 if test "${HAVE_NS}" = "yes"; then
12933
12934 $as_echo "#define HAVE_NS 1" >>confdefs.h
12935
12936 if test "${NS_IMPL_COCOA}" = "yes"; then
12937
12938 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12939
12940 fi
12941 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12942
12943 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12944
12945 # See also .m.o rule in Makefile.in */
12946 # FIXME: are all these flags really needed? Document here why. */
12947 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12948 ## Extra CFLAGS applied to src/*.m files.
12949 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"
12950 fi
12951 # We also have mouse menus.
12952 HAVE_MENUS=yes
12953 OTHER_FILES=ns-app
12954 fi
12955
12956 if test "${HAVE_W32}" = "yes"; then
12957 HAVE_MENUS=yes
12958 fi
12959
12960 ### Use session management (-lSM -lICE) if available
12961 HAVE_X_SM=no
12962 LIBXSM=
12963 if test "${HAVE_X11}" = "yes"; then
12964 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12965 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12967 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12968 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12969 $as_echo_n "(cached) " >&6
12970 else
12971 ac_check_lib_save_LIBS=$LIBS
12972 LIBS="-lSM -lICE $LIBS"
12973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12974 /* end confdefs.h. */
12975
12976 /* Override any GCC internal prototype to avoid an error.
12977 Use char because int might match the return type of a GCC
12978 builtin and then its argument prototype would still apply. */
12979 #ifdef __cplusplus
12980 extern "C"
12981 #endif
12982 char SmcOpenConnection ();
12983 int
12984 main ()
12985 {
12986 return SmcOpenConnection ();
12987 ;
12988 return 0;
12989 }
12990 _ACEOF
12991 if ac_fn_c_try_link "$LINENO"; then :
12992 ac_cv_lib_SM_SmcOpenConnection=yes
12993 else
12994 ac_cv_lib_SM_SmcOpenConnection=no
12995 fi
12996 rm -f core conftest.err conftest.$ac_objext \
12997 conftest$ac_exeext conftest.$ac_ext
12998 LIBS=$ac_check_lib_save_LIBS
12999 fi
13000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13001 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13002 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13003 HAVE_X_SM=yes
13004 fi
13005
13006 fi
13007
13008
13009
13010 if test "${HAVE_X_SM}" = "yes"; then
13011
13012 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13013
13014 LIBXSM="-lSM -lICE"
13015 case "$LIBS" in
13016 *-lSM*) ;;
13017 *) LIBS="$LIBXSM $LIBS" ;;
13018 esac
13019 fi
13020 fi
13021
13022
13023 ### Use libxml (-lxml2) if available
13024 HAVE_LIBXML2=no
13025 if test "${with_xml2}" != "no"; then
13026 ### I'm not sure what the version number should be, so I just guessed.
13027
13028 succeeded=no
13029
13030 if test "$PKG_CONFIG" = "no" ; then
13031 HAVE_LIBXML2=no
13032 else
13033 PKG_CONFIG_MIN_VERSION=0.9.0
13034 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13036 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13037
13038 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
13039 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
13040 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
13041 edit_cflags="
13042 s,///*,/,g
13043 s/^/ /
13044 s/ -I/ $isystem/g
13045 s/^ //
13046 "
13047 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
13048 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
13049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
13050 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
13051 succeeded=yes
13052 else
13053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13054 $as_echo "no" >&6; }
13055 LIBXML2_CFLAGS=""
13056 LIBXML2_LIBS=""
13057 ## If we have a custom action on failure, don't print errors, but
13058 ## do set a variable so people can do so. Do it in a subshell
13059 ## to capture any diagnostics in invoking pkg-config.
13060 LIBXML2_PKG_ERRORS=`($PKG_CONFIG --print-errors "libxml-2.0 > 2.6.17") 2>&1`
13061
13062 fi
13063
13064
13065
13066 else
13067 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13068 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13069 fi
13070 fi
13071
13072 if test $succeeded = yes; then
13073 HAVE_LIBXML2=yes
13074 else
13075 HAVE_LIBXML2=no
13076 fi
13077
13078 if test "${HAVE_LIBXML2}" = "yes"; then
13079 LIBS="$LIBXML2_LIBS $LIBS"
13080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13081 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13082 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13083 $as_echo_n "(cached) " >&6
13084 else
13085 ac_check_lib_save_LIBS=$LIBS
13086 LIBS="-lxml2 $LIBS"
13087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13088 /* end confdefs.h. */
13089
13090 /* Override any GCC internal prototype to avoid an error.
13091 Use char because int might match the return type of a GCC
13092 builtin and then its argument prototype would still apply. */
13093 #ifdef __cplusplus
13094 extern "C"
13095 #endif
13096 char htmlReadMemory ();
13097 int
13098 main ()
13099 {
13100 return htmlReadMemory ();
13101 ;
13102 return 0;
13103 }
13104 _ACEOF
13105 if ac_fn_c_try_link "$LINENO"; then :
13106 ac_cv_lib_xml2_htmlReadMemory=yes
13107 else
13108 ac_cv_lib_xml2_htmlReadMemory=no
13109 fi
13110 rm -f core conftest.err conftest.$ac_objext \
13111 conftest$ac_exeext conftest.$ac_ext
13112 LIBS=$ac_check_lib_save_LIBS
13113 fi
13114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13115 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13116 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13117 HAVE_LIBXML2=yes
13118 else
13119 HAVE_LIBXML2=no
13120 fi
13121
13122 if test "${HAVE_LIBXML2}" = "yes"; then
13123
13124 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13125
13126 else
13127 LIBXML2_LIBS=""
13128 LIBXML2_CFLAGS=""
13129 fi
13130 fi
13131 fi
13132
13133
13134
13135 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13137 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13138 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13139 $as_echo_n "(cached) " >&6
13140 else
13141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13142 /* end confdefs.h. */
13143 #include <netdb.h>
13144 int
13145 main ()
13146 {
13147 return h_errno;
13148 ;
13149 return 0;
13150 }
13151 _ACEOF
13152 if ac_fn_c_try_link "$LINENO"; then :
13153 emacs_cv_netdb_declares_h_errno=yes
13154 else
13155 emacs_cv_netdb_declares_h_errno=no
13156 fi
13157 rm -f core conftest.err conftest.$ac_objext \
13158 conftest$ac_exeext conftest.$ac_ext
13159 fi
13160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13161 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13162 if test $emacs_cv_netdb_declares_h_errno = yes; then
13163
13164 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13165
13166 fi
13167
13168 # sqrt and other floating-point functions such as fmod and frexp
13169 # are found in -lm on most systems.
13170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13171 $as_echo_n "checking for sqrt in -lm... " >&6; }
13172 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13173 $as_echo_n "(cached) " >&6
13174 else
13175 ac_check_lib_save_LIBS=$LIBS
13176 LIBS="-lm $LIBS"
13177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13178 /* end confdefs.h. */
13179
13180 /* Override any GCC internal prototype to avoid an error.
13181 Use char because int might match the return type of a GCC
13182 builtin and then its argument prototype would still apply. */
13183 #ifdef __cplusplus
13184 extern "C"
13185 #endif
13186 char sqrt ();
13187 int
13188 main ()
13189 {
13190 return sqrt ();
13191 ;
13192 return 0;
13193 }
13194 _ACEOF
13195 if ac_fn_c_try_link "$LINENO"; then :
13196 ac_cv_lib_m_sqrt=yes
13197 else
13198 ac_cv_lib_m_sqrt=no
13199 fi
13200 rm -f core conftest.err conftest.$ac_objext \
13201 conftest$ac_exeext conftest.$ac_ext
13202 LIBS=$ac_check_lib_save_LIBS
13203 fi
13204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13205 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13206 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13207 cat >>confdefs.h <<_ACEOF
13208 #define HAVE_LIBM 1
13209 _ACEOF
13210
13211 LIBS="-lm $LIBS"
13212
13213 fi
13214
13215
13216 # Check for mail-locking functions in a "mail" library. Probably this should
13217 # have the same check as for liblockfile below.
13218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13219 $as_echo_n "checking for maillock in -lmail... " >&6; }
13220 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13221 $as_echo_n "(cached) " >&6
13222 else
13223 ac_check_lib_save_LIBS=$LIBS
13224 LIBS="-lmail $LIBS"
13225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13226 /* end confdefs.h. */
13227
13228 /* Override any GCC internal prototype to avoid an error.
13229 Use char because int might match the return type of a GCC
13230 builtin and then its argument prototype would still apply. */
13231 #ifdef __cplusplus
13232 extern "C"
13233 #endif
13234 char maillock ();
13235 int
13236 main ()
13237 {
13238 return maillock ();
13239 ;
13240 return 0;
13241 }
13242 _ACEOF
13243 if ac_fn_c_try_link "$LINENO"; then :
13244 ac_cv_lib_mail_maillock=yes
13245 else
13246 ac_cv_lib_mail_maillock=no
13247 fi
13248 rm -f core conftest.err conftest.$ac_objext \
13249 conftest$ac_exeext conftest.$ac_ext
13250 LIBS=$ac_check_lib_save_LIBS
13251 fi
13252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13253 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13254 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13255 have_mail=yes
13256 else
13257 have_mail=no
13258 fi
13259
13260 if test $have_mail = yes; then
13261 LIBS_MAIL=-lmail
13262 LIBS="$LIBS_MAIL $LIBS"
13263
13264 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13265
13266 else
13267 LIBS_MAIL=
13268 fi
13269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13270 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13271 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13272 $as_echo_n "(cached) " >&6
13273 else
13274 ac_check_lib_save_LIBS=$LIBS
13275 LIBS="-llockfile $LIBS"
13276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13277 /* end confdefs.h. */
13278
13279 /* Override any GCC internal prototype to avoid an error.
13280 Use char because int might match the return type of a GCC
13281 builtin and then its argument prototype would still apply. */
13282 #ifdef __cplusplus
13283 extern "C"
13284 #endif
13285 char maillock ();
13286 int
13287 main ()
13288 {
13289 return maillock ();
13290 ;
13291 return 0;
13292 }
13293 _ACEOF
13294 if ac_fn_c_try_link "$LINENO"; then :
13295 ac_cv_lib_lockfile_maillock=yes
13296 else
13297 ac_cv_lib_lockfile_maillock=no
13298 fi
13299 rm -f core conftest.err conftest.$ac_objext \
13300 conftest$ac_exeext conftest.$ac_ext
13301 LIBS=$ac_check_lib_save_LIBS
13302 fi
13303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13304 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13305 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13306 have_lockfile=yes
13307 else
13308 have_lockfile=no
13309 fi
13310
13311 if test $have_lockfile = yes; then
13312 LIBS_MAIL=-llockfile
13313 LIBS="$LIBS_MAIL $LIBS"
13314
13315 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13316
13317 else
13318 # If we have the shared liblockfile, assume we must use it for mail
13319 # locking (e.g. Debian). If we couldn't link against liblockfile
13320 # (no liblockfile.a installed), ensure that we don't need to.
13321 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13322 set dummy liblockfile.so; ac_word=$2
13323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13324 $as_echo_n "checking for $ac_word... " >&6; }
13325 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13326 $as_echo_n "(cached) " >&6
13327 else
13328 if test -n "$liblockfile"; then
13329 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13330 else
13331 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13332 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13333 for as_dir in $as_dummy
13334 do
13335 IFS=$as_save_IFS
13336 test -z "$as_dir" && as_dir=.
13337 for ac_exec_ext in '' $ac_executable_extensions; do
13338 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13339 ac_cv_prog_liblockfile="yes"
13340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13341 break 2
13342 fi
13343 done
13344 done
13345 IFS=$as_save_IFS
13346
13347 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13348 fi
13349 fi
13350 liblockfile=$ac_cv_prog_liblockfile
13351 if test -n "$liblockfile"; then
13352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13353 $as_echo "$liblockfile" >&6; }
13354 else
13355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13356 $as_echo "no" >&6; }
13357 fi
13358
13359
13360 if test $ac_cv_prog_liblockfile = yes; then
13361 as_fn_error "Shared liblockfile found but can't link against it.
13362 This probably means that movemail could lose mail.
13363 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13364 fi
13365 fi
13366
13367
13368
13369
13370
13371 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13372 ## interlock access to the mail spool. The alternative is a lock file named
13373 ## /usr/spool/mail/$USER.lock.
13374 mail_lock=no
13375 case "$opsys" in
13376 aix4-2) mail_lock="lockf" ;;
13377
13378 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13379
13380 ## On GNU/Linux systems, both methods are used by various mail programs.
13381 ## I assume most people are using newer mailers that have heard of flock.
13382 ## Change this if you need to.
13383 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13384 ## configure gets the right answers, and that means *NOT* using flock.
13385 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13386 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13387 ## Debian maintainer hasn't provided a clean fix for Emacs.
13388 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13389 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13390 ## correct logic. -- fx
13391 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13392 ## liblockfile is a Free Software replacement for libmail, used on
13393 ## Debian systems and elsewhere. -rfr.
13394 gnu-*)
13395 mail_lock="flock"
13396 if test $have_mail = yes || test $have_lockfile = yes; then
13397 test $ac_cv_header_maillock_h = yes && mail_lock=no
13398 fi
13399 ;;
13400 esac
13401
13402 BLESSMAIL_TARGET=
13403 case "$mail_lock" in
13404 flock)
13405 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13406 ;;
13407
13408 lockf)
13409 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13410 ;;
13411
13412 *) BLESSMAIL_TARGET="need-blessmail" ;;
13413 esac
13414
13415
13416
13417 for ac_func in gethostname \
13418 closedir getrusage get_current_dir_name \
13419 lrand48 \
13420 fpathconf select euidaccess getpagesize setlocale \
13421 utimes getrlimit setrlimit getcwd shutdown getaddrinfo \
13422 strsignal setitimer \
13423 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13424 gai_strerror mkstemp getline getdelim fsync sync \
13425 difftime posix_memalign \
13426 getpwent endpwent getgrent endgrent \
13427 touchlock \
13428 cfmakeraw cfsetspeed copysign __executable_start
13429 do :
13430 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13431 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13432 eval as_val=\$$as_ac_var
13433 if test "x$as_val" = x""yes; then :
13434 cat >>confdefs.h <<_ACEOF
13435 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13436 _ACEOF
13437
13438 fi
13439 done
13440
13441
13442 if test $opsys = unixware; then
13443
13444 $as_echo "#define BROKEN_GETWD 1" >>confdefs.h
13445
13446 else
13447 for ac_func in getwd
13448 do :
13449 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13450 if test "x$ac_cv_func_getwd" = x""yes; then :
13451 cat >>confdefs.h <<_ACEOF
13452 #define HAVE_GETWD 1
13453 _ACEOF
13454
13455 fi
13456 done
13457
13458 fi
13459
13460 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13461 ## has a broken `rint' in some library versions including math library
13462 ## version number A.09.05.
13463 ## You can fix the math library by installing patch number PHSS_4630.
13464 ## But we can fix it more reliably for Emacs by just not using rint.
13465 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13466 case $opsys in
13467 hpux*) : ;;
13468 *) for ac_func in random rint
13469 do :
13470 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13471 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13472 eval as_val=\$$as_ac_var
13473 if test "x$as_val" = x""yes; then :
13474 cat >>confdefs.h <<_ACEOF
13475 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13476 _ACEOF
13477
13478 fi
13479 done
13480 ;;
13481 esac
13482
13483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13484 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13485 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13486 $as_echo_n "(cached) " >&6
13487 else
13488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13489 /* end confdefs.h. */
13490
13491 int
13492 main ()
13493 {
13494 __builtin_unwind_init ();
13495 ;
13496 return 0;
13497 }
13498 _ACEOF
13499 if ac_fn_c_try_link "$LINENO"; then :
13500 emacs_cv_func___builtin_unwind_init=yes
13501 else
13502 emacs_cv_func___builtin_unwind_init=no
13503 fi
13504 rm -f core conftest.err conftest.$ac_objext \
13505 conftest$ac_exeext conftest.$ac_ext
13506 fi
13507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13508 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13509 if test $emacs_cv_func___builtin_unwind_init = yes; then
13510
13511 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13512
13513 fi
13514
13515
13516
13517
13518
13519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13520 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13521 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13522 $as_echo_n "(cached) " >&6
13523 else
13524 while :; do
13525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13526 /* end confdefs.h. */
13527 #include <sys/types.h> /* for off_t */
13528 #include <stdio.h>
13529 int
13530 main ()
13531 {
13532 int (*fp) (FILE *, off_t, int) = fseeko;
13533 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13534 ;
13535 return 0;
13536 }
13537 _ACEOF
13538 if ac_fn_c_try_link "$LINENO"; then :
13539 ac_cv_sys_largefile_source=no; break
13540 fi
13541 rm -f core conftest.err conftest.$ac_objext \
13542 conftest$ac_exeext conftest.$ac_ext
13543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13544 /* end confdefs.h. */
13545 #define _LARGEFILE_SOURCE 1
13546 #include <sys/types.h> /* for off_t */
13547 #include <stdio.h>
13548 int
13549 main ()
13550 {
13551 int (*fp) (FILE *, off_t, int) = fseeko;
13552 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13553 ;
13554 return 0;
13555 }
13556 _ACEOF
13557 if ac_fn_c_try_link "$LINENO"; then :
13558 ac_cv_sys_largefile_source=1; break
13559 fi
13560 rm -f core conftest.err conftest.$ac_objext \
13561 conftest$ac_exeext conftest.$ac_ext
13562 ac_cv_sys_largefile_source=unknown
13563 break
13564 done
13565 fi
13566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13567 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13568 case $ac_cv_sys_largefile_source in #(
13569 no | unknown) ;;
13570 *)
13571 cat >>confdefs.h <<_ACEOF
13572 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13573 _ACEOF
13574 ;;
13575 esac
13576 rm -rf conftest*
13577
13578 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13579 # in glibc 2.1.3, but that breaks too many other things.
13580 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13581 if test $ac_cv_sys_largefile_source != unknown; then
13582
13583 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13584
13585 fi
13586
13587
13588 # UNIX98 PTYs.
13589 for ac_func in grantpt
13590 do :
13591 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13592 if test "x$ac_cv_func_grantpt" = x""yes; then :
13593 cat >>confdefs.h <<_ACEOF
13594 #define HAVE_GRANTPT 1
13595 _ACEOF
13596
13597 fi
13598 done
13599
13600
13601 # PTY-related GNU extensions.
13602 for ac_func in getpt posix_openpt
13603 do :
13604 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13605 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13606 eval as_val=\$$as_ac_var
13607 if test "x$as_val" = x""yes; then :
13608 cat >>confdefs.h <<_ACEOF
13609 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13610 _ACEOF
13611
13612 fi
13613 done
13614
13615
13616 # Check this now, so that we will NOT find the above functions in ncurses.
13617 # That is because we have not set up to link ncurses in lib-src.
13618 # It's better to believe a function is not available
13619 # than to expect to find it in ncurses.
13620 # Also we need tputs and friends to be able to build at all.
13621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13622 $as_echo_n "checking for library containing tputs... " >&6; }
13623 # Run a test program that contains a call to tputs, a call that is
13624 # never executed. This tests whether a pre-'main' dynamic linker
13625 # works with the library. It's too much trouble to actually call
13626 # tputs in the test program, due to portability hassles. When
13627 # cross-compiling, assume the test program will run if it links.
13628
13629 # Maybe curses should be tried earlier?
13630 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13631 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13632 OLIBS=$LIBS
13633 if test -z "$tputs_library"; then
13634 LIBS_TERMCAP=
13635 msg='none required'
13636 else
13637 LIBS_TERMCAP=-l$tputs_library
13638 msg=$LIBS_TERMCAP
13639 LIBS="$LIBS_TERMCAP $LIBS"
13640 fi
13641 if test "$cross_compiling" = yes; then :
13642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13643 /* end confdefs.h. */
13644
13645 extern void tputs (const char *, int, int (*)(int));
13646 int main (int argc, char **argv)
13647 {
13648 if (argc == 10000)
13649 tputs (argv[0], 0, 0);
13650 return 0;
13651 }
13652
13653 _ACEOF
13654 if ac_fn_c_try_link "$LINENO"; then :
13655
13656 else
13657 msg=no
13658 fi
13659 rm -f core conftest.err conftest.$ac_objext \
13660 conftest$ac_exeext conftest.$ac_ext
13661 else
13662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13663 /* end confdefs.h. */
13664
13665 extern void tputs (const char *, int, int (*)(int));
13666 int main (int argc, char **argv)
13667 {
13668 if (argc == 10000)
13669 tputs (argv[0], 0, 0);
13670 return 0;
13671 }
13672
13673 _ACEOF
13674 if ac_fn_c_try_run "$LINENO"; then :
13675
13676 else
13677 msg=no
13678 fi
13679 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13680 conftest.$ac_objext conftest.beam conftest.$ac_ext
13681 fi
13682
13683 LIBS=$OLIBS
13684 if test "X$msg" != Xno; then
13685 break
13686 fi
13687 done
13688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13689 $as_echo "$msg" >&6; }
13690 if test "X$msg" = Xno; then
13691 as_fn_error "The required function \`tputs' was not found in any library.
13692 The following libraries were tried (in order):
13693 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13694 Please try installing whichever of these libraries is most appropriate
13695 for your system, together with its header files.
13696 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13697 fi
13698
13699 ## Use termcap instead of terminfo?
13700 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13701 TERMINFO=yes
13702 ## FIXME? In the cases below where we unconditionally set
13703 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13704 ## if that was found above to have tputs.
13705 ## Should we use the gnu* logic everywhere?
13706 case "$opsys" in
13707 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13708 ## The ncurses library has been moved out of the System framework in
13709 ## Mac OS X 10.2. So if configure detects it, set the command-line
13710 ## option to use it.
13711 darwin) LIBS_TERMCAP="-lncurses" ;;
13712
13713 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13714
13715 freebsd)
13716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13717 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13718 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13719 $as_echo_n "(cached) " >&6
13720 else
13721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13722 /* end confdefs.h. */
13723 #include <osreldate.h>
13724 int
13725 main ()
13726 {
13727 #if __FreeBSD_version < 400000
13728 fail;
13729 #endif
13730
13731 ;
13732 return 0;
13733 }
13734 _ACEOF
13735 if ac_fn_c_try_link "$LINENO"; then :
13736 emacs_cv_freebsd_terminfo=yes
13737 else
13738 emacs_cv_freebsd_terminfo=no
13739 fi
13740 rm -f core conftest.err conftest.$ac_objext \
13741 conftest$ac_exeext conftest.$ac_ext
13742 fi
13743
13744
13745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13746 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13747
13748 if test $emacs_cv_freebsd_terminfo = yes; then
13749 LIBS_TERMCAP="-lncurses"
13750 else
13751 TERMINFO=no
13752 LIBS_TERMCAP="-ltermcap"
13753 fi
13754 ;;
13755
13756 netbsd)
13757 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13758 TERMINFO=no
13759 LIBS_TERMCAP="-ltermcap"
13760 fi
13761 ;;
13762
13763 openbsd) LIBS_TERMCAP="-lncurses" ;;
13764
13765 ## hpux: Make sure we get select from libc rather than from libcurses
13766 ## because libcurses on HPUX 10.10 has a broken version of select.
13767 ## We used to use -lc -lcurses, but this may be cleaner.
13768 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13769 # set that way, now it uses the default). Isn't this a contradiction?
13770 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13771
13772 esac
13773
13774 TERMCAP_OBJ=tparam.o
13775 if test $TERMINFO = yes; then
13776
13777 $as_echo "#define TERMINFO 1" >>confdefs.h
13778
13779 TERMCAP_OBJ=terminfo.o
13780 fi
13781
13782
13783
13784
13785 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13786 # On Darwin, res_init appears not to be useful: see bug#562 and
13787 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13788 resolv=no
13789
13790 if test $opsys != darwin; then
13791
13792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13793 /* end confdefs.h. */
13794 #include <netinet/in.h>
13795 #include <arpa/nameser.h>
13796 #include <resolv.h>
13797 int
13798 main ()
13799 {
13800 return res_init();
13801 ;
13802 return 0;
13803 }
13804 _ACEOF
13805 if ac_fn_c_try_link "$LINENO"; then :
13806 have_res_init=yes
13807 else
13808 have_res_init=no
13809 fi
13810 rm -f core conftest.err conftest.$ac_objext \
13811 conftest$ac_exeext conftest.$ac_ext
13812 if test "$have_res_init" = no; then
13813 OLIBS="$LIBS"
13814 LIBS="$LIBS -lresolv"
13815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13816 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13818 /* end confdefs.h. */
13819 #include <netinet/in.h>
13820 #include <arpa/nameser.h>
13821 #include <resolv.h>
13822 int
13823 main ()
13824 {
13825 return res_init();
13826 ;
13827 return 0;
13828 }
13829 _ACEOF
13830 if ac_fn_c_try_link "$LINENO"; then :
13831 have_res_init=yes
13832 else
13833 have_res_init=no
13834 fi
13835 rm -f core conftest.err conftest.$ac_objext \
13836 conftest$ac_exeext conftest.$ac_ext
13837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13838 $as_echo "$have_res_init" >&6; }
13839 if test "$have_res_init" = yes ; then
13840 resolv=yes
13841 fi
13842 LIBS="$OLIBS"
13843 fi
13844
13845 if test "$have_res_init" = yes; then
13846
13847 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13848
13849 fi
13850 fi
13851 # Do we need the Hesiod library to provide the support routines?
13852 LIBHESIOD=
13853 if test "$with_hesiod" != no ; then
13854 # Don't set $LIBS here -- see comments above. FIXME which comments?
13855 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13856 if test "x$ac_cv_func_res_send" = x""yes; then :
13857
13858 else
13859 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13860 if test "x$ac_cv_func___res_send" = x""yes; then :
13861
13862 else
13863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13864 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13865 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13866 $as_echo_n "(cached) " >&6
13867 else
13868 ac_check_lib_save_LIBS=$LIBS
13869 LIBS="-lresolv $LIBS"
13870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13871 /* end confdefs.h. */
13872
13873 /* Override any GCC internal prototype to avoid an error.
13874 Use char because int might match the return type of a GCC
13875 builtin and then its argument prototype would still apply. */
13876 #ifdef __cplusplus
13877 extern "C"
13878 #endif
13879 char res_send ();
13880 int
13881 main ()
13882 {
13883 return res_send ();
13884 ;
13885 return 0;
13886 }
13887 _ACEOF
13888 if ac_fn_c_try_link "$LINENO"; then :
13889 ac_cv_lib_resolv_res_send=yes
13890 else
13891 ac_cv_lib_resolv_res_send=no
13892 fi
13893 rm -f core conftest.err conftest.$ac_objext \
13894 conftest$ac_exeext conftest.$ac_ext
13895 LIBS=$ac_check_lib_save_LIBS
13896 fi
13897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13898 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13899 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13900 resolv=yes
13901 else
13902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13903 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13904 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13905 $as_echo_n "(cached) " >&6
13906 else
13907 ac_check_lib_save_LIBS=$LIBS
13908 LIBS="-lresolv $LIBS"
13909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13910 /* end confdefs.h. */
13911
13912 /* Override any GCC internal prototype to avoid an error.
13913 Use char because int might match the return type of a GCC
13914 builtin and then its argument prototype would still apply. */
13915 #ifdef __cplusplus
13916 extern "C"
13917 #endif
13918 char __res_send ();
13919 int
13920 main ()
13921 {
13922 return __res_send ();
13923 ;
13924 return 0;
13925 }
13926 _ACEOF
13927 if ac_fn_c_try_link "$LINENO"; then :
13928 ac_cv_lib_resolv___res_send=yes
13929 else
13930 ac_cv_lib_resolv___res_send=no
13931 fi
13932 rm -f core conftest.err conftest.$ac_objext \
13933 conftest$ac_exeext conftest.$ac_ext
13934 LIBS=$ac_check_lib_save_LIBS
13935 fi
13936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13937 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13938 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13939 resolv=yes
13940 fi
13941
13942 fi
13943
13944 fi
13945
13946 fi
13947
13948 if test "$resolv" = yes ; then
13949 RESOLVLIB=-lresolv
13950 else
13951 RESOLVLIB=
13952 fi
13953 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13954 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13955
13956 else
13957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13958 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13959 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13960 $as_echo_n "(cached) " >&6
13961 else
13962 ac_check_lib_save_LIBS=$LIBS
13963 LIBS="-lhesiod $RESOLVLIB $LIBS"
13964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13965 /* end confdefs.h. */
13966
13967 /* Override any GCC internal prototype to avoid an error.
13968 Use char because int might match the return type of a GCC
13969 builtin and then its argument prototype would still apply. */
13970 #ifdef __cplusplus
13971 extern "C"
13972 #endif
13973 char hes_getmailhost ();
13974 int
13975 main ()
13976 {
13977 return hes_getmailhost ();
13978 ;
13979 return 0;
13980 }
13981 _ACEOF
13982 if ac_fn_c_try_link "$LINENO"; then :
13983 ac_cv_lib_hesiod_hes_getmailhost=yes
13984 else
13985 ac_cv_lib_hesiod_hes_getmailhost=no
13986 fi
13987 rm -f core conftest.err conftest.$ac_objext \
13988 conftest$ac_exeext conftest.$ac_ext
13989 LIBS=$ac_check_lib_save_LIBS
13990 fi
13991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
13992 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
13993 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
13994 hesiod=yes
13995 else
13996 :
13997 fi
13998
13999 fi
14000
14001
14002 if test x"$hesiod" = xyes; then
14003
14004 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14005
14006 LIBHESIOD=-lhesiod
14007 fi
14008 fi
14009
14010
14011 # Do we need libresolv (due to res_init or Hesiod)?
14012 if test "$resolv" = yes && test $opsys != darwin; then
14013
14014 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14015
14016 LIBRESOLV=-lresolv
14017 else
14018 LIBRESOLV=
14019 fi
14020
14021
14022 # These tell us which Kerberos-related libraries to use.
14023 COM_ERRLIB=
14024 CRYPTOLIB=
14025 KRB5LIB=
14026 DESLIB=
14027 KRB4LIB=
14028
14029 if test "${with_kerberos}" != no; then
14030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14031 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
14032 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
14033 $as_echo_n "(cached) " >&6
14034 else
14035 ac_check_lib_save_LIBS=$LIBS
14036 LIBS="-lcom_err $LIBS"
14037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14038 /* end confdefs.h. */
14039
14040 /* Override any GCC internal prototype to avoid an error.
14041 Use char because int might match the return type of a GCC
14042 builtin and then its argument prototype would still apply. */
14043 #ifdef __cplusplus
14044 extern "C"
14045 #endif
14046 char com_err ();
14047 int
14048 main ()
14049 {
14050 return com_err ();
14051 ;
14052 return 0;
14053 }
14054 _ACEOF
14055 if ac_fn_c_try_link "$LINENO"; then :
14056 ac_cv_lib_com_err_com_err=yes
14057 else
14058 ac_cv_lib_com_err_com_err=no
14059 fi
14060 rm -f core conftest.err conftest.$ac_objext \
14061 conftest$ac_exeext conftest.$ac_ext
14062 LIBS=$ac_check_lib_save_LIBS
14063 fi
14064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14065 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
14066 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
14067 have_com_err=yes
14068 else
14069 have_com_err=no
14070 fi
14071
14072 if test $have_com_err = yes; then
14073 COM_ERRLIB=-lcom_err
14074 LIBS="$COM_ERRLIB $LIBS"
14075
14076 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
14077
14078 fi
14079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14080 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
14081 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
14082 $as_echo_n "(cached) " >&6
14083 else
14084 ac_check_lib_save_LIBS=$LIBS
14085 LIBS="-lcrypto $LIBS"
14086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14087 /* end confdefs.h. */
14088
14089 /* Override any GCC internal prototype to avoid an error.
14090 Use char because int might match the return type of a GCC
14091 builtin and then its argument prototype would still apply. */
14092 #ifdef __cplusplus
14093 extern "C"
14094 #endif
14095 char mit_des_cbc_encrypt ();
14096 int
14097 main ()
14098 {
14099 return mit_des_cbc_encrypt ();
14100 ;
14101 return 0;
14102 }
14103 _ACEOF
14104 if ac_fn_c_try_link "$LINENO"; then :
14105 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14106 else
14107 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14108 fi
14109 rm -f core conftest.err conftest.$ac_objext \
14110 conftest$ac_exeext conftest.$ac_ext
14111 LIBS=$ac_check_lib_save_LIBS
14112 fi
14113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14114 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
14115 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
14116 have_crypto=yes
14117 else
14118 have_crypto=no
14119 fi
14120
14121 if test $have_crypto = yes; then
14122 CRYPTOLIB=-lcrypto
14123 LIBS="$CRYPTOLIB $LIBS"
14124
14125 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
14126
14127 fi
14128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14129 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
14130 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
14131 $as_echo_n "(cached) " >&6
14132 else
14133 ac_check_lib_save_LIBS=$LIBS
14134 LIBS="-lk5crypto $LIBS"
14135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14136 /* end confdefs.h. */
14137
14138 /* Override any GCC internal prototype to avoid an error.
14139 Use char because int might match the return type of a GCC
14140 builtin and then its argument prototype would still apply. */
14141 #ifdef __cplusplus
14142 extern "C"
14143 #endif
14144 char mit_des_cbc_encrypt ();
14145 int
14146 main ()
14147 {
14148 return mit_des_cbc_encrypt ();
14149 ;
14150 return 0;
14151 }
14152 _ACEOF
14153 if ac_fn_c_try_link "$LINENO"; then :
14154 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14155 else
14156 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14157 fi
14158 rm -f core conftest.err conftest.$ac_objext \
14159 conftest$ac_exeext conftest.$ac_ext
14160 LIBS=$ac_check_lib_save_LIBS
14161 fi
14162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14163 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
14164 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
14165 have_k5crypto=yes
14166 else
14167 have_k5crypto=no
14168 fi
14169
14170 if test $have_k5crypto = yes; then
14171 CRYPTOLIB=-lk5crypto
14172 LIBS="$CRYPTOLIB $LIBS"
14173
14174 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14175
14176 fi
14177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14178 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14179 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14180 $as_echo_n "(cached) " >&6
14181 else
14182 ac_check_lib_save_LIBS=$LIBS
14183 LIBS="-lkrb5 $LIBS"
14184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14185 /* end confdefs.h. */
14186
14187 /* Override any GCC internal prototype to avoid an error.
14188 Use char because int might match the return type of a GCC
14189 builtin and then its argument prototype would still apply. */
14190 #ifdef __cplusplus
14191 extern "C"
14192 #endif
14193 char krb5_init_context ();
14194 int
14195 main ()
14196 {
14197 return krb5_init_context ();
14198 ;
14199 return 0;
14200 }
14201 _ACEOF
14202 if ac_fn_c_try_link "$LINENO"; then :
14203 ac_cv_lib_krb5_krb5_init_context=yes
14204 else
14205 ac_cv_lib_krb5_krb5_init_context=no
14206 fi
14207 rm -f core conftest.err conftest.$ac_objext \
14208 conftest$ac_exeext conftest.$ac_ext
14209 LIBS=$ac_check_lib_save_LIBS
14210 fi
14211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14212 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14213 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14214 have_krb5=yes
14215 else
14216 have_krb5=no
14217 fi
14218
14219 if test $have_krb5=yes; then
14220 KRB5LIB=-lkrb5
14221 LIBS="$KRB5LIB $LIBS"
14222
14223 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14224
14225 fi
14226 if test "${with_kerberos5}" = no; then
14227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14228 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14229 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14230 $as_echo_n "(cached) " >&6
14231 else
14232 ac_check_lib_save_LIBS=$LIBS
14233 LIBS="-ldes425 $LIBS"
14234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14235 /* end confdefs.h. */
14236
14237 /* Override any GCC internal prototype to avoid an error.
14238 Use char because int might match the return type of a GCC
14239 builtin and then its argument prototype would still apply. */
14240 #ifdef __cplusplus
14241 extern "C"
14242 #endif
14243 char des_cbc_encrypt ();
14244 int
14245 main ()
14246 {
14247 return des_cbc_encrypt ();
14248 ;
14249 return 0;
14250 }
14251 _ACEOF
14252 if ac_fn_c_try_link "$LINENO"; then :
14253 ac_cv_lib_des425_des_cbc_encrypt=yes
14254 else
14255 ac_cv_lib_des425_des_cbc_encrypt=no
14256 fi
14257 rm -f core conftest.err conftest.$ac_objext \
14258 conftest$ac_exeext conftest.$ac_ext
14259 LIBS=$ac_check_lib_save_LIBS
14260 fi
14261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14262 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14263 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14264 have_des425=yes
14265 else
14266 have_des425=no
14267 fi
14268
14269 if test $have_des425 = yes; then
14270 DESLIB=-ldes425
14271 LIBS="$DESLIB $LIBS"
14272
14273 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14274
14275 else
14276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14277 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14278 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14279 $as_echo_n "(cached) " >&6
14280 else
14281 ac_check_lib_save_LIBS=$LIBS
14282 LIBS="-ldes $LIBS"
14283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14284 /* end confdefs.h. */
14285
14286 /* Override any GCC internal prototype to avoid an error.
14287 Use char because int might match the return type of a GCC
14288 builtin and then its argument prototype would still apply. */
14289 #ifdef __cplusplus
14290 extern "C"
14291 #endif
14292 char des_cbc_encrypt ();
14293 int
14294 main ()
14295 {
14296 return des_cbc_encrypt ();
14297 ;
14298 return 0;
14299 }
14300 _ACEOF
14301 if ac_fn_c_try_link "$LINENO"; then :
14302 ac_cv_lib_des_des_cbc_encrypt=yes
14303 else
14304 ac_cv_lib_des_des_cbc_encrypt=no
14305 fi
14306 rm -f core conftest.err conftest.$ac_objext \
14307 conftest$ac_exeext conftest.$ac_ext
14308 LIBS=$ac_check_lib_save_LIBS
14309 fi
14310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14311 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14312 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14313 have_des=yes
14314 else
14315 have_des=no
14316 fi
14317
14318 if test $have_des = yes; then
14319 DESLIB=-ldes
14320 LIBS="$DESLIB $LIBS"
14321
14322 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14323
14324 fi
14325 fi
14326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14327 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14328 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14329 $as_echo_n "(cached) " >&6
14330 else
14331 ac_check_lib_save_LIBS=$LIBS
14332 LIBS="-lkrb4 $LIBS"
14333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14334 /* end confdefs.h. */
14335
14336 /* Override any GCC internal prototype to avoid an error.
14337 Use char because int might match the return type of a GCC
14338 builtin and then its argument prototype would still apply. */
14339 #ifdef __cplusplus
14340 extern "C"
14341 #endif
14342 char krb_get_cred ();
14343 int
14344 main ()
14345 {
14346 return krb_get_cred ();
14347 ;
14348 return 0;
14349 }
14350 _ACEOF
14351 if ac_fn_c_try_link "$LINENO"; then :
14352 ac_cv_lib_krb4_krb_get_cred=yes
14353 else
14354 ac_cv_lib_krb4_krb_get_cred=no
14355 fi
14356 rm -f core conftest.err conftest.$ac_objext \
14357 conftest$ac_exeext conftest.$ac_ext
14358 LIBS=$ac_check_lib_save_LIBS
14359 fi
14360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14361 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14362 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14363 have_krb4=yes
14364 else
14365 have_krb4=no
14366 fi
14367
14368 if test $have_krb4 = yes; then
14369 KRB4LIB=-lkrb4
14370 LIBS="$KRB4LIB $LIBS"
14371
14372 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14373
14374 else
14375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14376 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14377 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14378 $as_echo_n "(cached) " >&6
14379 else
14380 ac_check_lib_save_LIBS=$LIBS
14381 LIBS="-lkrb $LIBS"
14382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14383 /* end confdefs.h. */
14384
14385 /* Override any GCC internal prototype to avoid an error.
14386 Use char because int might match the return type of a GCC
14387 builtin and then its argument prototype would still apply. */
14388 #ifdef __cplusplus
14389 extern "C"
14390 #endif
14391 char krb_get_cred ();
14392 int
14393 main ()
14394 {
14395 return krb_get_cred ();
14396 ;
14397 return 0;
14398 }
14399 _ACEOF
14400 if ac_fn_c_try_link "$LINENO"; then :
14401 ac_cv_lib_krb_krb_get_cred=yes
14402 else
14403 ac_cv_lib_krb_krb_get_cred=no
14404 fi
14405 rm -f core conftest.err conftest.$ac_objext \
14406 conftest$ac_exeext conftest.$ac_ext
14407 LIBS=$ac_check_lib_save_LIBS
14408 fi
14409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14410 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14411 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14412 have_krb=yes
14413 else
14414 have_krb=no
14415 fi
14416
14417 if test $have_krb = yes; then
14418 KRB4LIB=-lkrb
14419 LIBS="$KRB4LIB $LIBS"
14420
14421 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14422
14423 fi
14424 fi
14425 fi
14426
14427 if test "${with_kerberos5}" != no; then
14428 for ac_header in krb5.h
14429 do :
14430 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14431 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14432 cat >>confdefs.h <<_ACEOF
14433 #define HAVE_KRB5_H 1
14434 _ACEOF
14435 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14436 "
14437 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14438
14439 cat >>confdefs.h <<_ACEOF
14440 #define HAVE_KRB5_ERROR_TEXT 1
14441 _ACEOF
14442
14443
14444 fi
14445 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14446 "
14447 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14448
14449 cat >>confdefs.h <<_ACEOF
14450 #define HAVE_KRB5_ERROR_E_TEXT 1
14451 _ACEOF
14452
14453
14454 fi
14455
14456 fi
14457
14458 done
14459
14460 else
14461 for ac_header in des.h
14462 do :
14463 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14464 if test "x$ac_cv_header_des_h" = x""yes; then :
14465 cat >>confdefs.h <<_ACEOF
14466 #define HAVE_DES_H 1
14467 _ACEOF
14468
14469 else
14470 for ac_header in kerberosIV/des.h
14471 do :
14472 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14473 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14474 cat >>confdefs.h <<_ACEOF
14475 #define HAVE_KERBEROSIV_DES_H 1
14476 _ACEOF
14477
14478 else
14479 for ac_header in kerberos/des.h
14480 do :
14481 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14482 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14483 cat >>confdefs.h <<_ACEOF
14484 #define HAVE_KERBEROS_DES_H 1
14485 _ACEOF
14486
14487 fi
14488
14489 done
14490
14491 fi
14492
14493 done
14494
14495 fi
14496
14497 done
14498
14499 for ac_header in krb.h
14500 do :
14501 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14502 if test "x$ac_cv_header_krb_h" = x""yes; then :
14503 cat >>confdefs.h <<_ACEOF
14504 #define HAVE_KRB_H 1
14505 _ACEOF
14506
14507 else
14508 for ac_header in kerberosIV/krb.h
14509 do :
14510 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14511 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14512 cat >>confdefs.h <<_ACEOF
14513 #define HAVE_KERBEROSIV_KRB_H 1
14514 _ACEOF
14515
14516 else
14517 for ac_header in kerberos/krb.h
14518 do :
14519 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14520 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14521 cat >>confdefs.h <<_ACEOF
14522 #define HAVE_KERBEROS_KRB_H 1
14523 _ACEOF
14524
14525 fi
14526
14527 done
14528
14529 fi
14530
14531 done
14532
14533 fi
14534
14535 done
14536
14537 fi
14538 for ac_header in com_err.h
14539 do :
14540 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14541 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14542 cat >>confdefs.h <<_ACEOF
14543 #define HAVE_COM_ERR_H 1
14544 _ACEOF
14545
14546 fi
14547
14548 done
14549
14550 fi
14551
14552
14553
14554
14555
14556
14557
14558
14559
14560
14561 for ac_func in $ac_func_list
14562 do :
14563 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14564 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14565 eval as_val=\$$as_ac_var
14566 if test "x$as_val" = x""yes; then :
14567 cat >>confdefs.h <<_ACEOF
14568 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14569 _ACEOF
14570
14571 fi
14572 done
14573
14574
14575
14576
14577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14578 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14579 if test "${emacs_cv_localtime_cache+set}" = set; then :
14580 $as_echo_n "(cached) " >&6
14581 else
14582 if test x$ac_cv_func_tzset = xyes; then
14583 if test "$cross_compiling" = yes; then :
14584 # If we have tzset, assume the worst when cross-compiling.
14585 emacs_cv_localtime_cache=yes
14586 else
14587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14588 /* end confdefs.h. */
14589 #include <time.h>
14590 char TZ_GMT0[] = "TZ=GMT0";
14591 char TZ_PST8[] = "TZ=PST8";
14592 main()
14593 {
14594 time_t now = time ((time_t *) 0);
14595 int hour_GMT0, hour_unset;
14596 if (putenv (TZ_GMT0) != 0)
14597 exit (1);
14598 hour_GMT0 = localtime (&now)->tm_hour;
14599 unsetenv("TZ");
14600 hour_unset = localtime (&now)->tm_hour;
14601 if (putenv (TZ_PST8) != 0)
14602 exit (1);
14603 if (localtime (&now)->tm_hour == hour_GMT0)
14604 exit (1);
14605 unsetenv("TZ");
14606 if (localtime (&now)->tm_hour != hour_unset)
14607 exit (1);
14608 exit (0);
14609 }
14610 _ACEOF
14611 if ac_fn_c_try_run "$LINENO"; then :
14612 emacs_cv_localtime_cache=no
14613 else
14614 emacs_cv_localtime_cache=yes
14615 fi
14616 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14617 conftest.$ac_objext conftest.beam conftest.$ac_ext
14618 fi
14619
14620 else
14621 # If we lack tzset, report that localtime does not cache TZ,
14622 # since we can't invalidate the cache if we don't have tzset.
14623 emacs_cv_localtime_cache=no
14624 fi
14625 fi
14626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14627 $as_echo "$emacs_cv_localtime_cache" >&6; }
14628 if test $emacs_cv_localtime_cache = yes; then
14629
14630 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14631
14632 fi
14633
14634 ok_so_far=yes
14635 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14636 if test "x$ac_cv_func_socket" = x""yes; then :
14637
14638 else
14639 ok_so_far=no
14640 fi
14641
14642 if test $ok_so_far = yes; then
14643 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14644 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14645
14646 else
14647 ok_so_far=no
14648 fi
14649
14650
14651 fi
14652 if test $ok_so_far = yes; then
14653 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14654 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14655
14656 else
14657 ok_so_far=no
14658 fi
14659
14660
14661 fi
14662 if test $ok_so_far = yes; then
14663
14664 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14665
14666 fi
14667
14668 if test -f /usr/lpp/X11/bin/smt.exp; then
14669
14670 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14671
14672 fi
14673
14674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14675 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14676 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14678 $as_echo "yes" >&6; }
14679
14680 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14681
14682 else
14683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14684 $as_echo "no" >&6; }
14685 fi
14686
14687 case $canonical in
14688 *-solaris2.4 | *-solaris2.4.*)
14689 : ${ac_cv_func_vfork_works=no};;
14690 esac
14691
14692 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14693 if test "x$ac_cv_type_pid_t" = x""yes; then :
14694
14695 else
14696
14697 cat >>confdefs.h <<_ACEOF
14698 #define pid_t int
14699 _ACEOF
14700
14701 fi
14702
14703 for ac_header in vfork.h
14704 do :
14705 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14706 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14707 cat >>confdefs.h <<_ACEOF
14708 #define HAVE_VFORK_H 1
14709 _ACEOF
14710
14711 fi
14712
14713 done
14714
14715 for ac_func in fork vfork
14716 do :
14717 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14718 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14719 eval as_val=\$$as_ac_var
14720 if test "x$as_val" = x""yes; then :
14721 cat >>confdefs.h <<_ACEOF
14722 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14723 _ACEOF
14724
14725 fi
14726 done
14727
14728 if test "x$ac_cv_func_fork" = xyes; then
14729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14730 $as_echo_n "checking for working fork... " >&6; }
14731 if test "${ac_cv_func_fork_works+set}" = set; then :
14732 $as_echo_n "(cached) " >&6
14733 else
14734 if test "$cross_compiling" = yes; then :
14735 ac_cv_func_fork_works=cross
14736 else
14737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14738 /* end confdefs.h. */
14739 $ac_includes_default
14740 int
14741 main ()
14742 {
14743
14744 /* By Ruediger Kuhlmann. */
14745 return fork () < 0;
14746
14747 ;
14748 return 0;
14749 }
14750 _ACEOF
14751 if ac_fn_c_try_run "$LINENO"; then :
14752 ac_cv_func_fork_works=yes
14753 else
14754 ac_cv_func_fork_works=no
14755 fi
14756 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14757 conftest.$ac_objext conftest.beam conftest.$ac_ext
14758 fi
14759
14760 fi
14761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14762 $as_echo "$ac_cv_func_fork_works" >&6; }
14763
14764 else
14765 ac_cv_func_fork_works=$ac_cv_func_fork
14766 fi
14767 if test "x$ac_cv_func_fork_works" = xcross; then
14768 case $host in
14769 *-*-amigaos* | *-*-msdosdjgpp*)
14770 # Override, as these systems have only a dummy fork() stub
14771 ac_cv_func_fork_works=no
14772 ;;
14773 *)
14774 ac_cv_func_fork_works=yes
14775 ;;
14776 esac
14777 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14778 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14779 fi
14780 ac_cv_func_vfork_works=$ac_cv_func_vfork
14781 if test "x$ac_cv_func_vfork" = xyes; then
14782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14783 $as_echo_n "checking for working vfork... " >&6; }
14784 if test "${ac_cv_func_vfork_works+set}" = set; then :
14785 $as_echo_n "(cached) " >&6
14786 else
14787 if test "$cross_compiling" = yes; then :
14788 ac_cv_func_vfork_works=cross
14789 else
14790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14791 /* end confdefs.h. */
14792 /* Thanks to Paul Eggert for this test. */
14793 $ac_includes_default
14794 #include <sys/wait.h>
14795 #ifdef HAVE_VFORK_H
14796 # include <vfork.h>
14797 #endif
14798 /* On some sparc systems, changes by the child to local and incoming
14799 argument registers are propagated back to the parent. The compiler
14800 is told about this with #include <vfork.h>, but some compilers
14801 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14802 static variable whose address is put into a register that is
14803 clobbered by the vfork. */
14804 static void
14805 #ifdef __cplusplus
14806 sparc_address_test (int arg)
14807 # else
14808 sparc_address_test (arg) int arg;
14809 #endif
14810 {
14811 static pid_t child;
14812 if (!child) {
14813 child = vfork ();
14814 if (child < 0) {
14815 perror ("vfork");
14816 _exit(2);
14817 }
14818 if (!child) {
14819 arg = getpid();
14820 write(-1, "", 0);
14821 _exit (arg);
14822 }
14823 }
14824 }
14825
14826 int
14827 main ()
14828 {
14829 pid_t parent = getpid ();
14830 pid_t child;
14831
14832 sparc_address_test (0);
14833
14834 child = vfork ();
14835
14836 if (child == 0) {
14837 /* Here is another test for sparc vfork register problems. This
14838 test uses lots of local variables, at least as many local
14839 variables as main has allocated so far including compiler
14840 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14841 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14842 reuse the register of parent for one of the local variables,
14843 since it will think that parent can't possibly be used any more
14844 in this routine. Assigning to the local variable will thus
14845 munge parent in the parent process. */
14846 pid_t
14847 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14848 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14849 /* Convince the compiler that p..p7 are live; otherwise, it might
14850 use the same hardware register for all 8 local variables. */
14851 if (p != p1 || p != p2 || p != p3 || p != p4
14852 || p != p5 || p != p6 || p != p7)
14853 _exit(1);
14854
14855 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14856 from child file descriptors. If the child closes a descriptor
14857 before it execs or exits, this munges the parent's descriptor
14858 as well. Test for this by closing stdout in the child. */
14859 _exit(close(fileno(stdout)) != 0);
14860 } else {
14861 int status;
14862 struct stat st;
14863
14864 while (wait(&status) != child)
14865 ;
14866 return (
14867 /* Was there some problem with vforking? */
14868 child < 0
14869
14870 /* Did the child fail? (This shouldn't happen.) */
14871 || status
14872
14873 /* Did the vfork/compiler bug occur? */
14874 || parent != getpid()
14875
14876 /* Did the file descriptor bug occur? */
14877 || fstat(fileno(stdout), &st) != 0
14878 );
14879 }
14880 }
14881 _ACEOF
14882 if ac_fn_c_try_run "$LINENO"; then :
14883 ac_cv_func_vfork_works=yes
14884 else
14885 ac_cv_func_vfork_works=no
14886 fi
14887 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14888 conftest.$ac_objext conftest.beam conftest.$ac_ext
14889 fi
14890
14891 fi
14892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14893 $as_echo "$ac_cv_func_vfork_works" >&6; }
14894
14895 fi;
14896 if test "x$ac_cv_func_fork_works" = xcross; then
14897 ac_cv_func_vfork_works=$ac_cv_func_vfork
14898 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14899 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14900 fi
14901
14902 if test "x$ac_cv_func_vfork_works" = xyes; then
14903
14904 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14905
14906 else
14907
14908 $as_echo "#define vfork fork" >>confdefs.h
14909
14910 fi
14911 if test "x$ac_cv_func_fork_works" = xyes; then
14912
14913 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14914
14915 fi
14916
14917
14918 for ac_func in snprintf
14919 do :
14920 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14921 if test "x$ac_cv_func_snprintf" = x""yes; then :
14922 cat >>confdefs.h <<_ACEOF
14923 #define HAVE_SNPRINTF 1
14924 _ACEOF
14925
14926 fi
14927 done
14928
14929
14930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14931 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14932 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14933 $as_echo_n "(cached) " >&6
14934 else
14935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14936 /* end confdefs.h. */
14937 #include <langinfo.h>
14938 int
14939 main ()
14940 {
14941 char* cs = nl_langinfo(CODESET);
14942 ;
14943 return 0;
14944 }
14945 _ACEOF
14946 if ac_fn_c_try_link "$LINENO"; then :
14947 emacs_cv_langinfo_codeset=yes
14948 else
14949 emacs_cv_langinfo_codeset=no
14950 fi
14951 rm -f core conftest.err conftest.$ac_objext \
14952 conftest$ac_exeext conftest.$ac_ext
14953
14954 fi
14955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14956 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14957 if test $emacs_cv_langinfo_codeset = yes; then
14958
14959 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14960
14961 fi
14962
14963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14964 $as_echo_n "checking for mbstate_t... " >&6; }
14965 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14966 $as_echo_n "(cached) " >&6
14967 else
14968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14969 /* end confdefs.h. */
14970 $ac_includes_default
14971 # include <wchar.h>
14972 int
14973 main ()
14974 {
14975 mbstate_t x; return sizeof x;
14976 ;
14977 return 0;
14978 }
14979 _ACEOF
14980 if ac_fn_c_try_compile "$LINENO"; then :
14981 ac_cv_type_mbstate_t=yes
14982 else
14983 ac_cv_type_mbstate_t=no
14984 fi
14985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14986 fi
14987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
14988 $as_echo "$ac_cv_type_mbstate_t" >&6; }
14989 if test $ac_cv_type_mbstate_t = yes; then
14990
14991 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
14992
14993 else
14994
14995 $as_echo "#define mbstate_t int" >>confdefs.h
14996
14997 fi
14998
14999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15000 $as_echo_n "checking for C restricted array declarations... " >&6; }
15001 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
15002 $as_echo_n "(cached) " >&6
15003 else
15004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15005 /* end confdefs.h. */
15006 void fred (int x[__restrict]);
15007 int
15008 main ()
15009 {
15010
15011 ;
15012 return 0;
15013 }
15014 _ACEOF
15015 if ac_fn_c_try_compile "$LINENO"; then :
15016 emacs_cv_c_restrict_arr=yes
15017 else
15018 emacs_cv_c_restrict_arr=no
15019 fi
15020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15021 fi
15022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15023 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
15024 if test "$emacs_cv_c_restrict_arr" = yes; then
15025
15026 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
15027
15028 fi
15029
15030
15031
15032 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
15033
15034
15035
15036 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
15037
15038
15039 ## Note: PTYs are broken on darwin <6. Use at your own risk.
15040
15041 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
15042
15043
15044
15045 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
15046
15047
15048
15049
15050
15051 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
15052
15053
15054
15055 $as_echo "#define SEPCHAR ':'" >>confdefs.h
15056
15057
15058
15059 $as_echo "#define subprocesses 1" >>confdefs.h
15060
15061
15062
15063 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
15064
15065
15066
15067
15068 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
15069
15070
15071
15072
15073
15074 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
15075
15076
15077
15078 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
15079
15080
15081
15082 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
15083
15084
15085
15086
15087
15088 case $opsys in
15089 aix4-2)
15090 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
15091 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15092
15093 fi
15094 ;;
15095
15096 hpux*)
15097 $as_echo "#define NO_EDITRES 1" >>confdefs.h
15098
15099 ;;
15100 esac
15101
15102
15103 case $opsys in
15104 irix6-5 | sol2* | unixware )
15105
15106 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
15107
15108 ;;
15109 esac
15110
15111 emacs_broken_SIGIO=no
15112
15113 case $opsys in
15114 hpux* | irix6-5 | openbsd | sol2* | unixware )
15115 emacs_broken_SIGIO=yes
15116 ;;
15117
15118 aix4-2)
15119
15120 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
15121
15122 ;;
15123
15124 freebsd)
15125
15126 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
15127
15128 ;;
15129 esac
15130
15131 case $opsys in
15132 gnu-* | sol2-10 )
15133
15134 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
15135
15136 ;;
15137 esac
15138
15139 case $opsys in
15140 darwin | freebsd | netbsd | openbsd )
15141
15142 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
15143
15144 ;;
15145 esac
15146
15147 case $opsys in
15148 netbsd | openbsd) sound_device="/dev/audio" ;;
15149 *) sound_device="/dev/dsp" ;;
15150 esac
15151
15152
15153 cat >>confdefs.h <<_ACEOF
15154 #define DEFAULT_SOUND_DEVICE "$sound_device"
15155 _ACEOF
15156
15157
15158
15159 case $opsys in
15160 darwin | gnu-linux | gnu-kfreebsd )
15161
15162 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
15163
15164 ;;
15165 esac
15166
15167
15168 case $opsys in
15169 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
15170
15171 $as_echo "#define NARROWPROTO 1" >>confdefs.h
15172
15173 ;;
15174 esac
15175
15176
15177
15178
15179
15180
15181
15182
15183 case $opsys in
15184 aix4-2 )
15185 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
15186
15187 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
15188
15189 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
15190
15191 ;;
15192
15193 cygwin )
15194 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15195
15196 $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
15197
15198 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15199
15200 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15201
15202 ;;
15203
15204 darwin )
15205 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15206
15207 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15208
15209 $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
15210
15211 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15212
15213 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15214
15215 ;;
15216
15217 gnu | openbsd )
15218 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15219
15220 ;;
15221
15222 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15223 if test "x$ac_cv_func_grantpt" = xyes; then
15224
15225 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15226
15227 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15228
15229 $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
15230
15231 if test "x$ac_cv_func_posix_openpt" = xyes; then
15232 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15233
15234 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15235
15236 elif test "x$ac_cv_func_getpt" = xyes; then
15237 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15238
15239 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15240
15241 else
15242 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15243
15244 fi
15245 else
15246 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15247
15248 fi
15249 ;;
15250
15251 hpux*)
15252 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15253
15254 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15255
15256 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15257
15258 ;;
15259
15260 irix6-5 )
15261 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15262
15263 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15264
15265 $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
15266
15267 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15268
15269 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15270
15271 ;;
15272
15273 sol2* )
15274 $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
15275
15276 ;;
15277
15278 unixware )
15279 $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
15280
15281 ;;
15282 esac
15283
15284
15285 case $opsys in
15286 sol2* | unixware )
15287 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15288
15289 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15290
15291
15292 $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
15293
15294 ;;
15295 esac
15296
15297
15298
15299
15300 case $opsys in
15301 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15302 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15303
15304 ;;
15305
15306 gnu-linux | gnu-kfreebsd )
15307
15308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15309 $as_echo_n "checking for signals via characters... " >&6; }
15310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15311 /* end confdefs.h. */
15312
15313 #include <linux/version.h>
15314 #if LINUX_VERSION_CODE < 0x20400
15315 # error "Linux version too old"
15316 #endif
15317
15318 int
15319 main ()
15320 {
15321
15322 ;
15323 return 0;
15324 }
15325 _ACEOF
15326 if ac_fn_c_try_cpp "$LINENO"; then :
15327 emacs_signals_via_chars=yes
15328 else
15329 emacs_signals_via_chars=no
15330 fi
15331 rm -f conftest.err conftest.$ac_ext
15332
15333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15334 $as_echo "$emacs_signals_via_chars" >&6; }
15335 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15336
15337 ;;
15338 esac
15339
15340
15341
15342
15343
15344 case $opsys in
15345 gnu)
15346 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15347
15348 ;;
15349
15350 hpux*)
15351 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15352
15353 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15354
15355 ;;
15356 irix6-5)
15357 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15358
15359 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15360
15361 ;;
15362 esac
15363
15364
15365
15366
15367
15368 case $opsys in
15369 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15370 ;;
15371
15372 gnu | freebsd | netbsd | openbsd )
15373
15374 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15375
15376 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15377
15378 ;;
15379
15380 gnu-linux | gnu-kfreebsd )
15381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15382 /* end confdefs.h. */
15383
15384 #ifndef __i386__
15385 # error "not i386"
15386 #endif
15387
15388 int
15389 main ()
15390 {
15391
15392 ;
15393 return 0;
15394 }
15395 _ACEOF
15396 if ac_fn_c_try_cpp "$LINENO"; then :
15397 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15398
15399 fi
15400 rm -f conftest.err conftest.$ac_ext
15401
15402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15403 /* end confdefs.h. */
15404
15405 #ifndef __ia64__
15406 # error "not ia64"
15407 #endif
15408
15409 int
15410 main ()
15411 {
15412
15413 ;
15414 return 0;
15415 }
15416 _ACEOF
15417 if ac_fn_c_try_cpp "$LINENO"; then :
15418
15419 $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
15420
15421 fi
15422 rm -f conftest.err conftest.$ac_ext
15423 ;;
15424
15425 hpux*)
15426
15427 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15428
15429 ;;
15430
15431 irix6-5)
15432 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15433
15434 ;;
15435 esac
15436
15437
15438
15439
15440
15441
15442
15443 case $opsys in
15444 aix4-2 | hpux* | unixware)
15445 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15446
15447 ;;
15448
15449 gnu-linux | gnu-kfreebsd )
15450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15451 /* end confdefs.h. */
15452
15453 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15454 || defined __alpha__ || defined __mips__ || defined __s390__ \
15455 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15456 || defined __ia64__ || defined __sh__
15457 /* ok */
15458 #else
15459 # error "setjmp not known to work on this arch"
15460 #endif
15461
15462 int
15463 main ()
15464 {
15465
15466 ;
15467 return 0;
15468 }
15469 _ACEOF
15470 if ac_fn_c_try_cpp "$LINENO"; then :
15471 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15472
15473 else
15474 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15475
15476 fi
15477 rm -f conftest.err conftest.$ac_ext
15478 ;;
15479 esac
15480
15481
15482 if test x$GCC = xyes; then
15483 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15484
15485 else
15486 case $opsys in
15487 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15488 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15489
15490 ;;
15491 esac
15492 fi
15493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15494 $as_echo_n "checking for _setjmp... " >&6; }
15495 if test "${emacs_cv_func__setjmp+set}" = set; then :
15496 $as_echo_n "(cached) " >&6
15497 else
15498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15499 /* end confdefs.h. */
15500 #include <setjmp.h>
15501
15502 int
15503 main ()
15504 {
15505 jmp_buf j;
15506 if (! _setjmp (j))
15507 _longjmp (j, 1);
15508 ;
15509 return 0;
15510 }
15511 _ACEOF
15512 if ac_fn_c_try_link "$LINENO"; then :
15513 emacs_cv_func__setjmp=yes
15514 else
15515 emacs_cv_func__setjmp=no
15516 fi
15517 rm -f core conftest.err conftest.$ac_objext \
15518 conftest$ac_exeext conftest.$ac_ext
15519 fi
15520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15521 $as_echo "$emacs_cv_func__setjmp" >&6; }
15522 if test $emacs_cv_func__setjmp = yes; then
15523
15524 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
15525
15526 else
15527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
15528 $as_echo_n "checking for sigsetjmp... " >&6; }
15529 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
15530 $as_echo_n "(cached) " >&6
15531 else
15532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15533 /* end confdefs.h. */
15534 #include <setjmp.h>
15535
15536 int
15537 main ()
15538 {
15539 sigjmp_buf j;
15540 if (! sigsetjmp (j, 1))
15541 siglongjmp (j, 1);
15542 ;
15543 return 0;
15544 }
15545 _ACEOF
15546 if ac_fn_c_try_link "$LINENO"; then :
15547 emacs_cv_func_sigsetjmp=yes
15548 else
15549 emacs_cv_func_sigsetjmp=no
15550 fi
15551 rm -f core conftest.err conftest.$ac_objext \
15552 conftest$ac_exeext conftest.$ac_ext
15553 fi
15554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
15555 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
15556 if test $emacs_cv_func_sigsetjmp = yes; then
15557
15558 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
15559
15560 fi
15561 fi
15562
15563 case $opsys in
15564 sol2* | unixware )
15565
15566 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15567
15568 ;;
15569 esac
15570
15571
15572 case $opsys in
15573 hpux* | sol2* )
15574
15575 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15576
15577 ;;
15578 esac
15579
15580
15581
15582
15583
15584
15585
15586
15587
15588
15589 case $opsys in
15590 aix4-2)
15591 $as_echo "#define USG /**/" >>confdefs.h
15592
15593 $as_echo "#define USG5 /**/" >>confdefs.h
15594
15595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15596 /* end confdefs.h. */
15597
15598 #ifndef _AIX
15599 # error "_AIX not defined"
15600 #endif
15601
15602 int
15603 main ()
15604 {
15605
15606 ;
15607 return 0;
15608 }
15609 _ACEOF
15610 if ac_fn_c_try_cpp "$LINENO"; then :
15611
15612 else
15613
15614 $as_echo "#define _AIX /**/" >>confdefs.h
15615
15616 fi
15617 rm -f conftest.err conftest.$ac_ext
15618 ;;
15619
15620 cygwin)
15621
15622 $as_echo "#define CYGWIN 1" >>confdefs.h
15623
15624 ;;
15625
15626 darwin)
15627 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15628
15629 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15630
15631
15632 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15633
15634 ;;
15635
15636 freebsd)
15637 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15638
15639
15640 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15641
15642 ;;
15643
15644 gnu | netbsd | openbsd )
15645 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15646
15647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15648 /* end confdefs.h. */
15649
15650 #ifndef BSD_SYSTEM
15651 # error "BSD_SYSTEM not defined"
15652 #endif
15653
15654 int
15655 main ()
15656 {
15657
15658 ;
15659 return 0;
15660 }
15661 _ACEOF
15662 if ac_fn_c_try_cpp "$LINENO"; then :
15663
15664 else
15665 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15666
15667 fi
15668 rm -f conftest.err conftest.$ac_ext
15669 ;;
15670
15671 gnu-linux | gnu-kfreebsd )
15672 $as_echo "#define USG /**/" >>confdefs.h
15673
15674
15675 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15676
15677 ;;
15678
15679 hpux*)
15680 $as_echo "#define USG /**/" >>confdefs.h
15681
15682 $as_echo "#define USG5 /**/" >>confdefs.h
15683
15684
15685 $as_echo "#define HPUX /**/" >>confdefs.h
15686
15687 ;;
15688
15689 irix6-5)
15690 $as_echo "#define USG /**/" >>confdefs.h
15691
15692 $as_echo "#define USG5 /**/" >>confdefs.h
15693
15694 $as_echo "#define USG5_4 /**/" >>confdefs.h
15695
15696
15697 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15698
15699 ;;
15700
15701 sol2*)
15702 $as_echo "#define USG /**/" >>confdefs.h
15703
15704 $as_echo "#define USG5 /**/" >>confdefs.h
15705
15706 $as_echo "#define USG5_4 /**/" >>confdefs.h
15707
15708
15709 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15710
15711 ;;
15712
15713 unixware)
15714 $as_echo "#define USG /**/" >>confdefs.h
15715
15716 $as_echo "#define USG5 /**/" >>confdefs.h
15717
15718 $as_echo "#define USG5_4 /**/" >>confdefs.h
15719
15720 ;;
15721 esac
15722
15723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
15724 $as_echo_n "checking for usable FIONREAD... " >&6; }
15725 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
15726 $as_echo_n "(cached) " >&6
15727 else
15728 case $opsys in
15729 aix4-2)
15730 emacs_cv_usable_FIONREAD=no
15731 ;;
15732
15733 *)
15734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15735 /* end confdefs.h. */
15736 #include <sys/types.h>
15737 #include <sys/ioctl.h>
15738 #ifdef USG5_4
15739 # include <sys/filio.h>
15740 #endif
15741
15742 int
15743 main ()
15744 {
15745 int foo = ioctl (0, FIONREAD, &foo);
15746 ;
15747 return 0;
15748 }
15749 _ACEOF
15750 if ac_fn_c_try_compile "$LINENO"; then :
15751 emacs_cv_usable_FIONREAD=yes
15752 else
15753 emacs_cv_usable_FIONREAD=no
15754 fi
15755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15756 ;;
15757 esac
15758 fi
15759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
15760 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
15761 if test $emacs_cv_usable_FIONREAD = yes; then
15762
15763 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
15764
15765
15766 if test $emacs_broken_SIGIO = no; then
15767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
15768 $as_echo_n "checking for usable SIGIO... " >&6; }
15769 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
15770 $as_echo_n "(cached) " >&6
15771 else
15772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15773 /* end confdefs.h. */
15774 #include <fcntl.h>
15775 #include <signal.h>
15776
15777 int
15778 main ()
15779 {
15780 int foo = SIGIO | F_SETFL | FASYNC;
15781 ;
15782 return 0;
15783 }
15784 _ACEOF
15785 if ac_fn_c_try_compile "$LINENO"; then :
15786 emacs_cv_usable_SIGIO=yes
15787 else
15788 emacs_cv_usable_SIGIO=no
15789 fi
15790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15791 fi
15792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
15793 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
15794 if test $emacs_cv_usable_SIGIO = yes; then
15795
15796 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
15797
15798 fi
15799 fi
15800 fi
15801
15802
15803 case $opsys in
15804 cygwin)
15805
15806 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15807
15808 ;;
15809
15810 hpux11)
15811
15812 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15813
15814 ;;
15815
15816 irix6-5)
15817
15818 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15819
15820 ;;
15821
15822 sol2-10)
15823
15824 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15825
15826 ;;
15827 esac
15828
15829 # Set up the CFLAGS for real compilation, so we can substitute it.
15830 CFLAGS="$REAL_CFLAGS"
15831 CPPFLAGS="$REAL_CPPFLAGS"
15832
15833 ## Hack to detect a buggy GCC version.
15834 if test "x$GCC" = xyes \
15835 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15836 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15837 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15838 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15839 fi
15840
15841 version=$PACKAGE_VERSION
15842
15843 copyright="Copyright (C) 2012 Free Software Foundation, Inc."
15844
15845 cat >>confdefs.h <<_ACEOF
15846 #define COPYRIGHT "$copyright"
15847 _ACEOF
15848
15849
15850
15851 ### Specify what sort of things we'll be editing into Makefile and config.h.
15852 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15853
15854
15855 ## Unused?
15856
15857
15858
15859
15860
15861
15862
15863
15864
15865
15866
15867
15868
15869
15870
15871
15872
15873
15874
15875
15876
15877
15878 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15879 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15880 ## end of LIBX_BASE, but nothing ever set it.
15881
15882
15883
15884
15885 ## Used in lwlib/Makefile.in.
15886
15887
15888
15889
15890
15891
15892
15893
15894 if test -n "${term_header}"; then
15895
15896 cat >>confdefs.h <<_ACEOF
15897 #define TERM_HEADER "${term_header}"
15898 _ACEOF
15899
15900 fi
15901
15902
15903 cat >>confdefs.h <<_ACEOF
15904 #define EMACS_CONFIGURATION "${canonical}"
15905 _ACEOF
15906
15907
15908 cat >>confdefs.h <<_ACEOF
15909 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15910 _ACEOF
15911
15912
15913
15914 XMENU_OBJ=
15915 XOBJ=
15916 FONT_OBJ=
15917 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15918
15919 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15920
15921 XMENU_OBJ=xmenu.o
15922 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
15923 FONT_OBJ=xfont.o
15924 if test "$HAVE_XFT" = "yes"; then
15925 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15926 elif test "$HAVE_FREETYPE" = "yes"; then
15927 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15928 fi
15929
15930 fi
15931
15932
15933
15934
15935 WIDGET_OBJ=
15936 MOTIF_LIBW=
15937 if test "${USE_X_TOOLKIT}" != "none" ; then
15938 WIDGET_OBJ=widget.o
15939
15940 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15941
15942 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15943
15944 $as_echo "#define USE_LUCID 1" >>confdefs.h
15945
15946 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15947
15948 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15949
15950 MOTIF_LIBW=-lXm
15951 case "$opsys" in
15952 gnu-linux)
15953 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15954 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15955 ;;
15956
15957 unixware)
15958 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15959 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15960 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15961 ;;
15962
15963 aix4-2)
15964 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15965 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15966 ;;
15967 esac
15968 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15969 fi
15970 fi
15971
15972
15973 TOOLKIT_LIBW=
15974 case "$USE_X_TOOLKIT" in
15975 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15976 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15977 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15978 esac
15979
15980
15981 if test "$USE_X_TOOLKIT" = "none"; then
15982 LIBXT_OTHER="\$(LIBXSM)"
15983 OLDXMENU_TARGET="really-oldXMenu"
15984 else
15985 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15986 OLDXMENU_TARGET="really-lwlib"
15987 fi
15988
15989
15990 ## The X Menu stuff is present in the X10 distribution, but missing
15991 ## from X11. If we have X10, just use the installed library;
15992 ## otherwise, use our own copy.
15993 if test "${HAVE_X11}" = "yes" ; then
15994
15995 $as_echo "#define HAVE_X11 1" >>confdefs.h
15996
15997
15998 if test "$USE_X_TOOLKIT" = "none"; then
15999 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
16000 else
16001 OLDXMENU="\${lwlibdir}/liblw.a"
16002 fi
16003 LIBXMENU="\$(OLDXMENU)"
16004 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
16005 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
16006 else
16007 ## For a syntactically valid Makefile; not actually used for anything.
16008 ## See comments in src/Makefile.in.
16009 OLDXMENU=nothing
16010 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
16011 if test "${HAVE_X_WINDOWS}" = "yes"; then
16012 LIBXMENU="-lXMenu"
16013 else
16014 LIBXMENU=
16015 fi
16016 LIBX_OTHER=
16017 OLDXMENU_DEPS=
16018 fi
16019
16020 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
16021 OLDXMENU_TARGET=
16022 OLDXMENU=nothing
16023 LIBXMENU=
16024 OLDXMENU_DEPS=
16025 fi
16026
16027
16028
16029
16030
16031
16032
16033 if test "${HAVE_MENUS}" = "yes" ; then
16034
16035 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
16036
16037 fi
16038
16039 if test "${GNU_MALLOC}" = "yes" ; then
16040
16041 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
16042
16043 fi
16044
16045 RALLOC_OBJ=
16046 if test "${REL_ALLOC}" = "yes" ; then
16047
16048 $as_echo "#define REL_ALLOC 1" >>confdefs.h
16049
16050
16051 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
16052 fi
16053
16054
16055 if test "$opsys" = "cygwin"; then
16056 CYGWIN_OBJ="sheap.o cygw32.o"
16057 ## Cygwin differs because of its unexec().
16058 PRE_ALLOC_OBJ=
16059 POST_ALLOC_OBJ=lastfile.o
16060 else
16061 CYGWIN_OBJ=
16062 PRE_ALLOC_OBJ=lastfile.o
16063 POST_ALLOC_OBJ=
16064 fi
16065
16066
16067
16068
16069 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
16070 # it temporarily reverts them to their pre-pkg-config values,
16071 # because gnulib needs to work with both src (which uses the
16072 # pkg-config stuff) and lib-src (which does not). For example, gnulib
16073 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
16074 # and it therefore needs to run in an environment where LIBS does not
16075 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
16076 # for some package unrelated to lib-src.
16077 SAVE_CFLAGS=$CFLAGS
16078 SAVE_LIBS=$LIBS
16079 CFLAGS=$pre_PKG_CONFIG_CFLAGS
16080 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
16081
16082
16083
16084
16085
16086
16087
16088
16089
16090
16091
16092 LIBC_FATAL_STDERR_=1
16093 export LIBC_FATAL_STDERR_
16094
16095 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
16096 # for constant arguments. Useless!
16097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
16098 $as_echo_n "checking for working alloca.h... " >&6; }
16099 if test "${ac_cv_working_alloca_h+set}" = set; then :
16100 $as_echo_n "(cached) " >&6
16101 else
16102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16103 /* end confdefs.h. */
16104 #include <alloca.h>
16105 int
16106 main ()
16107 {
16108 char *p = (char *) alloca (2 * sizeof (int));
16109 if (p) return 0;
16110 ;
16111 return 0;
16112 }
16113 _ACEOF
16114 if ac_fn_c_try_link "$LINENO"; then :
16115 ac_cv_working_alloca_h=yes
16116 else
16117 ac_cv_working_alloca_h=no
16118 fi
16119 rm -f core conftest.err conftest.$ac_objext \
16120 conftest$ac_exeext conftest.$ac_ext
16121 fi
16122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16123 $as_echo "$ac_cv_working_alloca_h" >&6; }
16124 if test $ac_cv_working_alloca_h = yes; then
16125
16126 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
16127
16128 fi
16129
16130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16131 $as_echo_n "checking for alloca... " >&6; }
16132 if test "${ac_cv_func_alloca_works+set}" = set; then :
16133 $as_echo_n "(cached) " >&6
16134 else
16135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16136 /* end confdefs.h. */
16137 #ifdef __GNUC__
16138 # define alloca __builtin_alloca
16139 #else
16140 # ifdef _MSC_VER
16141 # include <malloc.h>
16142 # define alloca _alloca
16143 # else
16144 # ifdef HAVE_ALLOCA_H
16145 # include <alloca.h>
16146 # else
16147 # ifdef _AIX
16148 #pragma alloca
16149 # else
16150 # ifndef alloca /* predefined by HP cc +Olibcalls */
16151 char *alloca ();
16152 # endif
16153 # endif
16154 # endif
16155 # endif
16156 #endif
16157
16158 int
16159 main ()
16160 {
16161 char *p = (char *) alloca (1);
16162 if (p) return 0;
16163 ;
16164 return 0;
16165 }
16166 _ACEOF
16167 if ac_fn_c_try_link "$LINENO"; then :
16168 ac_cv_func_alloca_works=yes
16169 else
16170 ac_cv_func_alloca_works=no
16171 fi
16172 rm -f core conftest.err conftest.$ac_objext \
16173 conftest$ac_exeext conftest.$ac_ext
16174 fi
16175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16176 $as_echo "$ac_cv_func_alloca_works" >&6; }
16177
16178 if test $ac_cv_func_alloca_works = yes; then
16179
16180 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16181
16182 else
16183 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16184 # that cause trouble. Some versions do not even contain alloca or
16185 # contain a buggy version. If you still want to use their alloca,
16186 # use ar to extract alloca.o from them instead of compiling alloca.c.
16187
16188
16189
16190
16191
16192 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16193
16194 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16195
16196
16197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16198 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16199 if test "${ac_cv_os_cray+set}" = set; then :
16200 $as_echo_n "(cached) " >&6
16201 else
16202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16203 /* end confdefs.h. */
16204 #if defined CRAY && ! defined CRAY2
16205 webecray
16206 #else
16207 wenotbecray
16208 #endif
16209
16210 _ACEOF
16211 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16212 $EGREP "webecray" >/dev/null 2>&1; then :
16213 ac_cv_os_cray=yes
16214 else
16215 ac_cv_os_cray=no
16216 fi
16217 rm -f conftest*
16218
16219 fi
16220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16221 $as_echo "$ac_cv_os_cray" >&6; }
16222 if test $ac_cv_os_cray = yes; then
16223 for ac_func in _getb67 GETB67 getb67; do
16224 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16225 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16226 eval as_val=\$$as_ac_var
16227 if test "x$as_val" = x""yes; then :
16228
16229 cat >>confdefs.h <<_ACEOF
16230 #define CRAY_STACKSEG_END $ac_func
16231 _ACEOF
16232
16233 break
16234 fi
16235
16236 done
16237 fi
16238
16239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16240 $as_echo_n "checking stack direction for C alloca... " >&6; }
16241 if test "${ac_cv_c_stack_direction+set}" = set; then :
16242 $as_echo_n "(cached) " >&6
16243 else
16244 if test "$cross_compiling" = yes; then :
16245 ac_cv_c_stack_direction=0
16246 else
16247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16248 /* end confdefs.h. */
16249 $ac_includes_default
16250 int
16251 find_stack_direction (int *addr, int depth)
16252 {
16253 int dir, dummy = 0;
16254 if (! addr)
16255 addr = &dummy;
16256 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16257 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16258 return dir + dummy;
16259 }
16260
16261 int
16262 main (int argc, char **argv)
16263 {
16264 return find_stack_direction (0, argc + !argv + 20) < 0;
16265 }
16266 _ACEOF
16267 if ac_fn_c_try_run "$LINENO"; then :
16268 ac_cv_c_stack_direction=1
16269 else
16270 ac_cv_c_stack_direction=-1
16271 fi
16272 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16273 conftest.$ac_objext conftest.beam conftest.$ac_ext
16274 fi
16275
16276 fi
16277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16278 $as_echo "$ac_cv_c_stack_direction" >&6; }
16279 cat >>confdefs.h <<_ACEOF
16280 #define STACK_DIRECTION $ac_cv_c_stack_direction
16281 _ACEOF
16282
16283
16284 fi
16285
16286
16287
16288
16289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16290 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16291 if test "${ac_cv_c_bigendian+set}" = set; then :
16292 $as_echo_n "(cached) " >&6
16293 else
16294 ac_cv_c_bigendian=unknown
16295 # See if we're dealing with a universal compiler.
16296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16297 /* end confdefs.h. */
16298 #ifndef __APPLE_CC__
16299 not a universal capable compiler
16300 #endif
16301 typedef int dummy;
16302
16303 _ACEOF
16304 if ac_fn_c_try_compile "$LINENO"; then :
16305
16306 # Check for potential -arch flags. It is not universal unless
16307 # there are at least two -arch flags with different values.
16308 ac_arch=
16309 ac_prev=
16310 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16311 if test -n "$ac_prev"; then
16312 case $ac_word in
16313 i?86 | x86_64 | ppc | ppc64)
16314 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16315 ac_arch=$ac_word
16316 else
16317 ac_cv_c_bigendian=universal
16318 break
16319 fi
16320 ;;
16321 esac
16322 ac_prev=
16323 elif test "x$ac_word" = "x-arch"; then
16324 ac_prev=arch
16325 fi
16326 done
16327 fi
16328 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16329 if test $ac_cv_c_bigendian = unknown; then
16330 # See if sys/param.h defines the BYTE_ORDER macro.
16331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16332 /* end confdefs.h. */
16333 #include <sys/types.h>
16334 #include <sys/param.h>
16335
16336 int
16337 main ()
16338 {
16339 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16340 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16341 && LITTLE_ENDIAN)
16342 bogus endian macros
16343 #endif
16344
16345 ;
16346 return 0;
16347 }
16348 _ACEOF
16349 if ac_fn_c_try_compile "$LINENO"; then :
16350 # It does; now see whether it defined to BIG_ENDIAN or not.
16351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16352 /* end confdefs.h. */
16353 #include <sys/types.h>
16354 #include <sys/param.h>
16355
16356 int
16357 main ()
16358 {
16359 #if BYTE_ORDER != BIG_ENDIAN
16360 not big endian
16361 #endif
16362
16363 ;
16364 return 0;
16365 }
16366 _ACEOF
16367 if ac_fn_c_try_compile "$LINENO"; then :
16368 ac_cv_c_bigendian=yes
16369 else
16370 ac_cv_c_bigendian=no
16371 fi
16372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16373 fi
16374 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16375 fi
16376 if test $ac_cv_c_bigendian = unknown; then
16377 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16379 /* end confdefs.h. */
16380 #include <limits.h>
16381
16382 int
16383 main ()
16384 {
16385 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16386 bogus endian macros
16387 #endif
16388
16389 ;
16390 return 0;
16391 }
16392 _ACEOF
16393 if ac_fn_c_try_compile "$LINENO"; then :
16394 # It does; now see whether it defined to _BIG_ENDIAN or not.
16395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16396 /* end confdefs.h. */
16397 #include <limits.h>
16398
16399 int
16400 main ()
16401 {
16402 #ifndef _BIG_ENDIAN
16403 not big endian
16404 #endif
16405
16406 ;
16407 return 0;
16408 }
16409 _ACEOF
16410 if ac_fn_c_try_compile "$LINENO"; then :
16411 ac_cv_c_bigendian=yes
16412 else
16413 ac_cv_c_bigendian=no
16414 fi
16415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16416 fi
16417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16418 fi
16419 if test $ac_cv_c_bigendian = unknown; then
16420 # Compile a test program.
16421 if test "$cross_compiling" = yes; then :
16422 # Try to guess by grepping values from an object file.
16423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16424 /* end confdefs.h. */
16425 short int ascii_mm[] =
16426 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16427 short int ascii_ii[] =
16428 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16429 int use_ascii (int i) {
16430 return ascii_mm[i] + ascii_ii[i];
16431 }
16432 short int ebcdic_ii[] =
16433 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16434 short int ebcdic_mm[] =
16435 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16436 int use_ebcdic (int i) {
16437 return ebcdic_mm[i] + ebcdic_ii[i];
16438 }
16439 extern int foo;
16440
16441 int
16442 main ()
16443 {
16444 return use_ascii (foo) == use_ebcdic (foo);
16445 ;
16446 return 0;
16447 }
16448 _ACEOF
16449 if ac_fn_c_try_compile "$LINENO"; then :
16450 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16451 ac_cv_c_bigendian=yes
16452 fi
16453 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16454 if test "$ac_cv_c_bigendian" = unknown; then
16455 ac_cv_c_bigendian=no
16456 else
16457 # finding both strings is unlikely to happen, but who knows?
16458 ac_cv_c_bigendian=unknown
16459 fi
16460 fi
16461 fi
16462 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16463 else
16464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16465 /* end confdefs.h. */
16466 $ac_includes_default
16467 int
16468 main ()
16469 {
16470
16471 /* Are we little or big endian? From Harbison&Steele. */
16472 union
16473 {
16474 long int l;
16475 char c[sizeof (long int)];
16476 } u;
16477 u.l = 1;
16478 return u.c[sizeof (long int) - 1] == 1;
16479
16480 ;
16481 return 0;
16482 }
16483 _ACEOF
16484 if ac_fn_c_try_run "$LINENO"; then :
16485 ac_cv_c_bigendian=no
16486 else
16487 ac_cv_c_bigendian=yes
16488 fi
16489 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16490 conftest.$ac_objext conftest.beam conftest.$ac_ext
16491 fi
16492
16493 fi
16494 fi
16495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16496 $as_echo "$ac_cv_c_bigendian" >&6; }
16497 case $ac_cv_c_bigendian in #(
16498 yes)
16499 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16500 ;; #(
16501 no)
16502 ;; #(
16503 universal)
16504
16505 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16506
16507 ;; #(
16508 *)
16509 as_fn_error "unknown endianness
16510 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16511 esac
16512
16513
16514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16515 $as_echo_n "checking for inline... " >&6; }
16516 if test "${ac_cv_c_inline+set}" = set; then :
16517 $as_echo_n "(cached) " >&6
16518 else
16519 ac_cv_c_inline=no
16520 for ac_kw in inline __inline__ __inline; do
16521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16522 /* end confdefs.h. */
16523 #ifndef __cplusplus
16524 typedef int foo_t;
16525 static $ac_kw foo_t static_foo () {return 0; }
16526 $ac_kw foo_t foo () {return 0; }
16527 #endif
16528
16529 _ACEOF
16530 if ac_fn_c_try_compile "$LINENO"; then :
16531 ac_cv_c_inline=$ac_kw
16532 fi
16533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16534 test "$ac_cv_c_inline" != no && break
16535 done
16536
16537 fi
16538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16539 $as_echo "$ac_cv_c_inline" >&6; }
16540
16541 case $ac_cv_c_inline in
16542 inline | yes) ;;
16543 *)
16544 case $ac_cv_c_inline in
16545 no) ac_val=;;
16546 *) ac_val=$ac_cv_c_inline;;
16547 esac
16548 cat >>confdefs.h <<_ACEOF
16549 #ifndef __cplusplus
16550 #define inline $ac_val
16551 #endif
16552 _ACEOF
16553 ;;
16554 esac
16555
16556
16557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16558 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16559 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16560 $as_echo_n "(cached) " >&6
16561 else
16562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16563 /* end confdefs.h. */
16564 /* On HP-UX before 11.23, strtold returns a struct instead of
16565 long double. Reject implementations like that, by requiring
16566 compatibility with the C99 prototype. */
16567 #include <stdlib.h>
16568 static long double (*p) (char const *, char **) = strtold;
16569 static long double
16570 test (char const *nptr, char **endptr)
16571 {
16572 long double r;
16573 r = strtold (nptr, endptr);
16574 return r;
16575 }
16576 int
16577 main ()
16578 {
16579 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16580 ;
16581 return 0;
16582 }
16583 _ACEOF
16584 if ac_fn_c_try_link "$LINENO"; then :
16585 gl_cv_func_c99_strtold=yes
16586 else
16587 gl_cv_func_c99_strtold=no
16588 fi
16589 rm -f core conftest.err conftest.$ac_objext \
16590 conftest$ac_exeext conftest.$ac_ext
16591 fi
16592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16593 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16594 if test $gl_cv_func_c99_strtold = yes; then
16595
16596 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16597
16598 fi
16599
16600
16601 GNULIB_CHDIR=0;
16602 GNULIB_CHOWN=0;
16603 GNULIB_CLOSE=0;
16604 GNULIB_DUP=0;
16605 GNULIB_DUP2=0;
16606 GNULIB_DUP3=0;
16607 GNULIB_ENVIRON=0;
16608 GNULIB_EUIDACCESS=0;
16609 GNULIB_FACCESSAT=0;
16610 GNULIB_FCHDIR=0;
16611 GNULIB_FCHOWNAT=0;
16612 GNULIB_FDATASYNC=0;
16613 GNULIB_FSYNC=0;
16614 GNULIB_FTRUNCATE=0;
16615 GNULIB_GETCWD=0;
16616 GNULIB_GETDOMAINNAME=0;
16617 GNULIB_GETDTABLESIZE=0;
16618 GNULIB_GETGROUPS=0;
16619 GNULIB_GETHOSTNAME=0;
16620 GNULIB_GETLOGIN=0;
16621 GNULIB_GETLOGIN_R=0;
16622 GNULIB_GETPAGESIZE=0;
16623 GNULIB_GETUSERSHELL=0;
16624 GNULIB_GROUP_MEMBER=0;
16625 GNULIB_ISATTY=0;
16626 GNULIB_LCHOWN=0;
16627 GNULIB_LINK=0;
16628 GNULIB_LINKAT=0;
16629 GNULIB_LSEEK=0;
16630 GNULIB_PIPE=0;
16631 GNULIB_PIPE2=0;
16632 GNULIB_PREAD=0;
16633 GNULIB_PWRITE=0;
16634 GNULIB_READ=0;
16635 GNULIB_READLINK=0;
16636 GNULIB_READLINKAT=0;
16637 GNULIB_RMDIR=0;
16638 GNULIB_SETHOSTNAME=0;
16639 GNULIB_SLEEP=0;
16640 GNULIB_SYMLINK=0;
16641 GNULIB_SYMLINKAT=0;
16642 GNULIB_TTYNAME_R=0;
16643 GNULIB_UNISTD_H_NONBLOCKING=0;
16644 GNULIB_UNISTD_H_SIGPIPE=0;
16645 GNULIB_UNLINK=0;
16646 GNULIB_UNLINKAT=0;
16647 GNULIB_USLEEP=0;
16648 GNULIB_WRITE=0;
16649 HAVE_CHOWN=1;
16650 HAVE_DUP2=1;
16651 HAVE_DUP3=1;
16652 HAVE_EUIDACCESS=1;
16653 HAVE_FACCESSAT=1;
16654 HAVE_FCHDIR=1;
16655 HAVE_FCHOWNAT=1;
16656 HAVE_FDATASYNC=1;
16657 HAVE_FSYNC=1;
16658 HAVE_FTRUNCATE=1;
16659 HAVE_GETDTABLESIZE=1;
16660 HAVE_GETGROUPS=1;
16661 HAVE_GETHOSTNAME=1;
16662 HAVE_GETLOGIN=1;
16663 HAVE_GETPAGESIZE=1;
16664 HAVE_GROUP_MEMBER=1;
16665 HAVE_LCHOWN=1;
16666 HAVE_LINK=1;
16667 HAVE_LINKAT=1;
16668 HAVE_PIPE=1;
16669 HAVE_PIPE2=1;
16670 HAVE_PREAD=1;
16671 HAVE_PWRITE=1;
16672 HAVE_READLINK=1;
16673 HAVE_READLINKAT=1;
16674 HAVE_SETHOSTNAME=1;
16675 HAVE_SLEEP=1;
16676 HAVE_SYMLINK=1;
16677 HAVE_SYMLINKAT=1;
16678 HAVE_UNLINKAT=1;
16679 HAVE_USLEEP=1;
16680 HAVE_DECL_ENVIRON=1;
16681 HAVE_DECL_FCHDIR=1;
16682 HAVE_DECL_FDATASYNC=1;
16683 HAVE_DECL_GETDOMAINNAME=1;
16684 HAVE_DECL_GETLOGIN_R=1;
16685 HAVE_DECL_GETPAGESIZE=1;
16686 HAVE_DECL_GETUSERSHELL=1;
16687 HAVE_DECL_SETHOSTNAME=1;
16688 HAVE_DECL_TTYNAME_R=1;
16689 HAVE_OS_H=0;
16690 HAVE_SYS_PARAM_H=0;
16691 REPLACE_CHOWN=0;
16692 REPLACE_CLOSE=0;
16693 REPLACE_DUP=0;
16694 REPLACE_DUP2=0;
16695 REPLACE_FCHOWNAT=0;
16696 REPLACE_FTRUNCATE=0;
16697 REPLACE_GETCWD=0;
16698 REPLACE_GETDOMAINNAME=0;
16699 REPLACE_GETLOGIN_R=0;
16700 REPLACE_GETGROUPS=0;
16701 REPLACE_GETPAGESIZE=0;
16702 REPLACE_ISATTY=0;
16703 REPLACE_LCHOWN=0;
16704 REPLACE_LINK=0;
16705 REPLACE_LINKAT=0;
16706 REPLACE_LSEEK=0;
16707 REPLACE_PREAD=0;
16708 REPLACE_PWRITE=0;
16709 REPLACE_READ=0;
16710 REPLACE_READLINK=0;
16711 REPLACE_RMDIR=0;
16712 REPLACE_SLEEP=0;
16713 REPLACE_SYMLINK=0;
16714 REPLACE_TTYNAME_R=0;
16715 REPLACE_UNLINK=0;
16716 REPLACE_UNLINKAT=0;
16717 REPLACE_USLEEP=0;
16718 REPLACE_WRITE=0;
16719 UNISTD_H_HAVE_WINSOCK2_H=0;
16720 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16721
16722
16723
16724
16725
16726
16727
16728
16729
16730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16731 $as_echo_n "checking if environ is properly declared... " >&6; }
16732 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16733 $as_echo_n "(cached) " >&6
16734 else
16735
16736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16737 /* end confdefs.h. */
16738 #if HAVE_UNISTD_H
16739 #include <unistd.h>
16740 #endif
16741 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16742 #include <stdlib.h>
16743
16744 extern struct { int foo; } environ;
16745 int
16746 main ()
16747 {
16748 environ.foo = 1;
16749 ;
16750 return 0;
16751 }
16752 _ACEOF
16753 if ac_fn_c_try_compile "$LINENO"; then :
16754 gt_cv_var_environ_declaration=no
16755 else
16756 gt_cv_var_environ_declaration=yes
16757 fi
16758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16759 fi
16760
16761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16762 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16763 if test $gt_cv_var_environ_declaration = yes; then
16764
16765 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16766
16767 fi
16768
16769
16770 if test $gt_cv_var_environ_declaration != yes; then
16771 HAVE_DECL_ENVIRON=0
16772 fi
16773
16774
16775
16776
16777
16778
16779
16780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16781 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16782 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16783 $as_echo_n "(cached) " >&6
16784 else
16785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16786 /* end confdefs.h. */
16787
16788 #include <sys/types.h>
16789 #include <sys/stat.h>
16790 int
16791 main ()
16792 {
16793 struct stat s; s.st_dm_mode;
16794 ;
16795 return 0;
16796 }
16797 _ACEOF
16798 if ac_fn_c_try_compile "$LINENO"; then :
16799 ac_cv_struct_st_dm_mode=yes
16800 else
16801 ac_cv_struct_st_dm_mode=no
16802 fi
16803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16804 fi
16805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16806 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16807
16808 if test $ac_cv_struct_st_dm_mode = yes; then
16809
16810 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16811
16812 fi
16813
16814
16815 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16816 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16817 ac_have_decl=1
16818 else
16819 ac_have_decl=0
16820 fi
16821
16822 cat >>confdefs.h <<_ACEOF
16823 #define HAVE_DECL_STRMODE $ac_have_decl
16824 _ACEOF
16825
16826
16827
16828
16829
16830
16831 GNULIB__EXIT=0;
16832 GNULIB_ATOLL=0;
16833 GNULIB_CALLOC_POSIX=0;
16834 GNULIB_CANONICALIZE_FILE_NAME=0;
16835 GNULIB_GETLOADAVG=0;
16836 GNULIB_GETSUBOPT=0;
16837 GNULIB_GRANTPT=0;
16838 GNULIB_MALLOC_POSIX=0;
16839 GNULIB_MBTOWC=0;
16840 GNULIB_MKDTEMP=0;
16841 GNULIB_MKOSTEMP=0;
16842 GNULIB_MKOSTEMPS=0;
16843 GNULIB_MKSTEMP=0;
16844 GNULIB_MKSTEMPS=0;
16845 GNULIB_POSIX_OPENPT=0;
16846 GNULIB_PTSNAME=0;
16847 GNULIB_PTSNAME_R=0;
16848 GNULIB_PUTENV=0;
16849 GNULIB_RANDOM=0;
16850 GNULIB_RANDOM_R=0;
16851 GNULIB_REALLOC_POSIX=0;
16852 GNULIB_REALPATH=0;
16853 GNULIB_RPMATCH=0;
16854 GNULIB_SETENV=0;
16855 GNULIB_STRTOD=0;
16856 GNULIB_STRTOLL=0;
16857 GNULIB_STRTOULL=0;
16858 GNULIB_SYSTEM_POSIX=0;
16859 GNULIB_UNLOCKPT=0;
16860 GNULIB_UNSETENV=0;
16861 GNULIB_WCTOMB=0;
16862 HAVE__EXIT=1;
16863 HAVE_ATOLL=1;
16864 HAVE_CANONICALIZE_FILE_NAME=1;
16865 HAVE_DECL_GETLOADAVG=1;
16866 HAVE_GETSUBOPT=1;
16867 HAVE_GRANTPT=1;
16868 HAVE_MKDTEMP=1;
16869 HAVE_MKOSTEMP=1;
16870 HAVE_MKOSTEMPS=1;
16871 HAVE_MKSTEMP=1;
16872 HAVE_MKSTEMPS=1;
16873 HAVE_POSIX_OPENPT=1;
16874 HAVE_PTSNAME=1;
16875 HAVE_PTSNAME_R=1;
16876 HAVE_RANDOM=1;
16877 HAVE_RANDOM_H=1;
16878 HAVE_RANDOM_R=1;
16879 HAVE_REALPATH=1;
16880 HAVE_RPMATCH=1;
16881 HAVE_SETENV=1;
16882 HAVE_DECL_SETENV=1;
16883 HAVE_STRTOD=1;
16884 HAVE_STRTOLL=1;
16885 HAVE_STRTOULL=1;
16886 HAVE_STRUCT_RANDOM_DATA=1;
16887 HAVE_SYS_LOADAVG_H=0;
16888 HAVE_UNLOCKPT=1;
16889 HAVE_DECL_UNSETENV=1;
16890 REPLACE_CALLOC=0;
16891 REPLACE_CANONICALIZE_FILE_NAME=0;
16892 REPLACE_MALLOC=0;
16893 REPLACE_MBTOWC=0;
16894 REPLACE_MKSTEMP=0;
16895 REPLACE_PTSNAME=0;
16896 REPLACE_PTSNAME_R=0;
16897 REPLACE_PUTENV=0;
16898 REPLACE_RANDOM_R=0;
16899 REPLACE_REALLOC=0;
16900 REPLACE_REALPATH=0;
16901 REPLACE_SETENV=0;
16902 REPLACE_STRTOD=0;
16903 REPLACE_UNSETENV=0;
16904 REPLACE_WCTOMB=0;
16905
16906
16907
16908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16909 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16910 if test "${gl_cv_have_include_next+set}" = set; then :
16911 $as_echo_n "(cached) " >&6
16912 else
16913 rm -rf conftestd1a conftestd1b conftestd2
16914 mkdir conftestd1a conftestd1b conftestd2
16915 cat <<EOF > conftestd1a/conftest.h
16916 #define DEFINED_IN_CONFTESTD1
16917 #include_next <conftest.h>
16918 #ifdef DEFINED_IN_CONFTESTD2
16919 int foo;
16920 #else
16921 #error "include_next doesn't work"
16922 #endif
16923 EOF
16924 cat <<EOF > conftestd1b/conftest.h
16925 #define DEFINED_IN_CONFTESTD1
16926 #include <stdio.h>
16927 #include_next <conftest.h>
16928 #ifdef DEFINED_IN_CONFTESTD2
16929 int foo;
16930 #else
16931 #error "include_next doesn't work"
16932 #endif
16933 EOF
16934 cat <<EOF > conftestd2/conftest.h
16935 #ifndef DEFINED_IN_CONFTESTD1
16936 #error "include_next test doesn't work"
16937 #endif
16938 #define DEFINED_IN_CONFTESTD2
16939 EOF
16940 gl_save_CPPFLAGS="$CPPFLAGS"
16941 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16943 /* end confdefs.h. */
16944 #include <conftest.h>
16945 _ACEOF
16946 if ac_fn_c_try_compile "$LINENO"; then :
16947 gl_cv_have_include_next=yes
16948 else
16949 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16951 /* end confdefs.h. */
16952 #include <conftest.h>
16953 _ACEOF
16954 if ac_fn_c_try_compile "$LINENO"; then :
16955 gl_cv_have_include_next=buggy
16956 else
16957 gl_cv_have_include_next=no
16958 fi
16959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16960
16961 fi
16962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16963 CPPFLAGS="$gl_save_CPPFLAGS"
16964 rm -rf conftestd1a conftestd1b conftestd2
16965
16966 fi
16967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16968 $as_echo "$gl_cv_have_include_next" >&6; }
16969 PRAGMA_SYSTEM_HEADER=
16970 if test $gl_cv_have_include_next = yes; then
16971 INCLUDE_NEXT=include_next
16972 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16973 if test -n "$GCC"; then
16974 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16975 fi
16976 else
16977 if test $gl_cv_have_include_next = buggy; then
16978 INCLUDE_NEXT=include
16979 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16980 else
16981 INCLUDE_NEXT=include
16982 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16983 fi
16984 fi
16985
16986
16987
16988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16989 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16990 if test "${gl_cv_pragma_columns+set}" = set; then :
16991 $as_echo_n "(cached) " >&6
16992 else
16993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16994 /* end confdefs.h. */
16995
16996 #ifdef __TANDEM
16997 choke me
16998 #endif
16999
17000 _ACEOF
17001 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17002 $EGREP "choke me" >/dev/null 2>&1; then :
17003 gl_cv_pragma_columns=yes
17004 else
17005 gl_cv_pragma_columns=no
17006 fi
17007 rm -f conftest*
17008
17009
17010 fi
17011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
17012 $as_echo "$gl_cv_pragma_columns" >&6; }
17013 if test $gl_cv_pragma_columns = yes; then
17014 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
17015 else
17016 PRAGMA_COLUMNS=
17017 fi
17018
17019
17020
17021
17022
17023
17024
17025
17026
17027
17028
17029
17030
17031
17032
17033
17034
17035 if test $gl_cv_have_include_next = yes; then
17036 gl_cv_next_getopt_h='<'getopt.h'>'
17037 else
17038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
17039 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
17040 if test "${gl_cv_next_getopt_h+set}" = set; then :
17041 $as_echo_n "(cached) " >&6
17042 else
17043
17044 if test $ac_cv_header_getopt_h = yes; then
17045
17046
17047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17048 /* end confdefs.h. */
17049 #include <getopt.h>
17050
17051 _ACEOF
17052 case "$host_os" in
17053 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17054 *) gl_absname_cpp="$ac_cpp" ;;
17055 esac
17056
17057 case "$host_os" in
17058 mingw*)
17059 gl_dirsep_regex='[/\\]'
17060 ;;
17061 *)
17062 gl_dirsep_regex='\/'
17063 ;;
17064 esac
17065 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17066
17067 gl_header_literal_regex=`echo 'getopt.h' \
17068 | sed -e "$gl_make_literal_regex_sed"`
17069 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17070 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17071 s|^/[^/]|//&|
17072 p
17073 q
17074 }'
17075 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17076 sed -n "$gl_absolute_header_sed"`'"'
17077 else
17078 gl_cv_next_getopt_h='<'getopt.h'>'
17079 fi
17080
17081
17082 fi
17083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
17084 $as_echo "$gl_cv_next_getopt_h" >&6; }
17085 fi
17086 NEXT_GETOPT_H=$gl_cv_next_getopt_h
17087
17088 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17089 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17090 gl_next_as_first_directive='<'getopt.h'>'
17091 else
17092 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17093 gl_next_as_first_directive=$gl_cv_next_getopt_h
17094 fi
17095 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
17096
17097
17098
17099
17100 if test $ac_cv_header_getopt_h = yes; then
17101 HAVE_GETOPT_H=1
17102 else
17103 HAVE_GETOPT_H=0
17104 fi
17105
17106
17107 gl_replace_getopt=
17108
17109 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17110 for ac_header in getopt.h
17111 do :
17112 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
17113 if test "x$ac_cv_header_getopt_h" = x""yes; then :
17114 cat >>confdefs.h <<_ACEOF
17115 #define HAVE_GETOPT_H 1
17116 _ACEOF
17117
17118 else
17119 gl_replace_getopt=yes
17120 fi
17121
17122 done
17123
17124 fi
17125
17126 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17127 for ac_func in getopt_long_only
17128 do :
17129 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
17130 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
17131 cat >>confdefs.h <<_ACEOF
17132 #define HAVE_GETOPT_LONG_ONLY 1
17133 _ACEOF
17134
17135 else
17136 gl_replace_getopt=yes
17137 fi
17138 done
17139
17140 fi
17141
17142 if test -z "$gl_replace_getopt"; then
17143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17144 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17145 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17146 $as_echo_n "(cached) " >&6
17147 else
17148
17149 if test $cross_compiling = no; then
17150 if test "$cross_compiling" = yes; then :
17151 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17152 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17153 as_fn_error "cannot run test program while cross compiling
17154 See \`config.log' for more details." "$LINENO" 5; }
17155 else
17156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17157 /* end confdefs.h. */
17158
17159 #include <unistd.h>
17160 #include <stdlib.h>
17161 #include <string.h>
17162
17163 int
17164 main ()
17165 {
17166 static char program[] = "program";
17167 static char a[] = "-a";
17168 static char foo[] = "foo";
17169 static char bar[] = "bar";
17170 char *argv[] = { program, a, foo, bar, NULL };
17171 int c;
17172
17173 c = getopt (4, argv, "ab");
17174 if (!(c == 'a'))
17175 return 1;
17176 c = getopt (4, argv, "ab");
17177 if (!(c == -1))
17178 return 2;
17179 if (!(optind == 2))
17180 return 3;
17181 return 0;
17182 }
17183
17184 _ACEOF
17185 if ac_fn_c_try_run "$LINENO"; then :
17186 gl_cv_func_getopt_posix=maybe
17187 else
17188 gl_cv_func_getopt_posix=no
17189 fi
17190 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17191 conftest.$ac_objext conftest.beam conftest.$ac_ext
17192 fi
17193
17194 if test $gl_cv_func_getopt_posix = maybe; then
17195 if test "$cross_compiling" = yes; then :
17196 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17197 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17198 as_fn_error "cannot run test program while cross compiling
17199 See \`config.log' for more details." "$LINENO" 5; }
17200 else
17201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17202 /* end confdefs.h. */
17203
17204 #include <unistd.h>
17205 #include <stdlib.h>
17206 #include <string.h>
17207
17208 int
17209 main ()
17210 {
17211 static char program[] = "program";
17212 static char donald[] = "donald";
17213 static char p[] = "-p";
17214 static char billy[] = "billy";
17215 static char duck[] = "duck";
17216 static char a[] = "-a";
17217 static char bar[] = "bar";
17218 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17219 int c;
17220
17221 c = getopt (7, argv, "+abp:q:");
17222 if (!(c == -1))
17223 return 4;
17224 if (!(strcmp (argv[0], "program") == 0))
17225 return 5;
17226 if (!(strcmp (argv[1], "donald") == 0))
17227 return 6;
17228 if (!(strcmp (argv[2], "-p") == 0))
17229 return 7;
17230 if (!(strcmp (argv[3], "billy") == 0))
17231 return 8;
17232 if (!(strcmp (argv[4], "duck") == 0))
17233 return 9;
17234 if (!(strcmp (argv[5], "-a") == 0))
17235 return 10;
17236 if (!(strcmp (argv[6], "bar") == 0))
17237 return 11;
17238 if (!(optind == 1))
17239 return 12;
17240 return 0;
17241 }
17242
17243 _ACEOF
17244 if ac_fn_c_try_run "$LINENO"; then :
17245 gl_cv_func_getopt_posix=maybe
17246 else
17247 gl_cv_func_getopt_posix=no
17248 fi
17249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17250 conftest.$ac_objext conftest.beam conftest.$ac_ext
17251 fi
17252
17253 fi
17254 if test $gl_cv_func_getopt_posix = maybe; then
17255 if test "$cross_compiling" = yes; then :
17256 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17257 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17258 as_fn_error "cannot run test program while cross compiling
17259 See \`config.log' for more details." "$LINENO" 5; }
17260 else
17261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17262 /* end confdefs.h. */
17263
17264 #include <unistd.h>
17265 #include <stdlib.h>
17266 #include <string.h>
17267
17268 int
17269 main ()
17270 {
17271 static char program[] = "program";
17272 static char ab[] = "-ab";
17273 char *argv[3] = { program, ab, NULL };
17274 if (getopt (2, argv, "ab:") != 'a')
17275 return 13;
17276 if (getopt (2, argv, "ab:") != '?')
17277 return 14;
17278 if (optopt != 'b')
17279 return 15;
17280 if (optind != 2)
17281 return 16;
17282 return 0;
17283 }
17284
17285 _ACEOF
17286 if ac_fn_c_try_run "$LINENO"; then :
17287 gl_cv_func_getopt_posix=yes
17288 else
17289 gl_cv_func_getopt_posix=no
17290 fi
17291 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17292 conftest.$ac_objext conftest.beam conftest.$ac_ext
17293 fi
17294
17295 fi
17296 else
17297 case "$host_os" in
17298 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17299 *) gl_cv_func_getopt_posix="guessing yes";;
17300 esac
17301 fi
17302
17303 fi
17304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17305 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17306 case "$gl_cv_func_getopt_posix" in
17307 *no) gl_replace_getopt=yes ;;
17308 esac
17309 fi
17310
17311 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17313 $as_echo_n "checking for working GNU getopt function... " >&6; }
17314 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17315 $as_echo_n "(cached) " >&6
17316 else
17317 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17318 # optstring is necessary for programs like m4 that have POSIX-mandated
17319 # semantics for supporting options interspersed with files.
17320 # Also, since getopt_long is a GNU extension, we require optind=0.
17321 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17322 # so take care to revert to the correct (non-)export state.
17323 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17324 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17325 xx) gl_had_POSIXLY_CORRECT=exported ;;
17326 x) gl_had_POSIXLY_CORRECT=yes ;;
17327 *) gl_had_POSIXLY_CORRECT= ;;
17328 esac
17329 POSIXLY_CORRECT=1
17330 export POSIXLY_CORRECT
17331 if test "$cross_compiling" = yes; then :
17332 gl_cv_func_getopt_gnu="guessing no"
17333
17334 else
17335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17336 /* end confdefs.h. */
17337 #include <getopt.h>
17338 #include <stddef.h>
17339 #include <string.h>
17340
17341 #include <stdlib.h>
17342 #if defined __MACH__ && defined __APPLE__
17343 /* Avoid a crash on Mac OS X. */
17344 #include <mach/mach.h>
17345 #include <mach/mach_error.h>
17346 #include <mach/thread_status.h>
17347 #include <mach/exception.h>
17348 #include <mach/task.h>
17349 #include <pthread.h>
17350 /* The exception port on which our thread listens. */
17351 static mach_port_t our_exception_port;
17352 /* The main function of the thread listening for exceptions of type
17353 EXC_BAD_ACCESS. */
17354 static void *
17355 mach_exception_thread (void *arg)
17356 {
17357 /* Buffer for a message to be received. */
17358 struct {
17359 mach_msg_header_t head;
17360 mach_msg_body_t msgh_body;
17361 char data[1024];
17362 } msg;
17363 mach_msg_return_t retval;
17364 /* Wait for a message on the exception port. */
17365 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17366 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17367 if (retval != MACH_MSG_SUCCESS)
17368 abort ();
17369 exit (1);
17370 }
17371 static void
17372 nocrash_init (void)
17373 {
17374 mach_port_t self = mach_task_self ();
17375 /* Allocate a port on which the thread shall listen for exceptions. */
17376 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17377 == KERN_SUCCESS) {
17378 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17379 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17380 MACH_MSG_TYPE_MAKE_SEND)
17381 == KERN_SUCCESS) {
17382 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17383 for us. */
17384 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17385 /* Create the thread listening on the exception port. */
17386 pthread_attr_t attr;
17387 pthread_t thread;
17388 if (pthread_attr_init (&attr) == 0
17389 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17390 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17391 pthread_attr_destroy (&attr);
17392 /* Replace the exception port info for these exceptions with our own.
17393 Note that we replace the exception port for the entire task, not only
17394 for a particular thread. This has the effect that when our exception
17395 port gets the message, the thread specific exception port has already
17396 been asked, and we don't need to bother about it.
17397 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17398 task_set_exception_ports (self, mask, our_exception_port,
17399 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17400 }
17401 }
17402 }
17403 }
17404 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17405 /* Avoid a crash on native Windows. */
17406 #define WIN32_LEAN_AND_MEAN
17407 #include <windows.h>
17408 #include <winerror.h>
17409 static LONG WINAPI
17410 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17411 {
17412 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17413 {
17414 case EXCEPTION_ACCESS_VIOLATION:
17415 case EXCEPTION_IN_PAGE_ERROR:
17416 case EXCEPTION_STACK_OVERFLOW:
17417 case EXCEPTION_GUARD_PAGE:
17418 case EXCEPTION_PRIV_INSTRUCTION:
17419 case EXCEPTION_ILLEGAL_INSTRUCTION:
17420 case EXCEPTION_DATATYPE_MISALIGNMENT:
17421 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17422 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17423 exit (1);
17424 }
17425 return EXCEPTION_CONTINUE_SEARCH;
17426 }
17427 static void
17428 nocrash_init (void)
17429 {
17430 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17431 }
17432 #else
17433 /* Avoid a crash on POSIX systems. */
17434 #include <signal.h>
17435 /* A POSIX signal handler. */
17436 static void
17437 exception_handler (int sig)
17438 {
17439 exit (1);
17440 }
17441 static void
17442 nocrash_init (void)
17443 {
17444 #ifdef SIGSEGV
17445 signal (SIGSEGV, exception_handler);
17446 #endif
17447 #ifdef SIGBUS
17448 signal (SIGBUS, exception_handler);
17449 #endif
17450 }
17451 #endif
17452
17453
17454 int
17455 main ()
17456 {
17457
17458 int result = 0;
17459
17460 nocrash_init();
17461
17462 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17463 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17464 OSF/1 5.1, Solaris 10. */
17465 {
17466 static char conftest[] = "conftest";
17467 static char plus[] = "-+";
17468 char *argv[3] = { conftest, plus, NULL };
17469 opterr = 0;
17470 if (getopt (2, argv, "+a") != '?')
17471 result |= 1;
17472 }
17473 /* This code succeeds on glibc 2.8, mingw,
17474 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17475 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17476 {
17477 static char program[] = "program";
17478 static char p[] = "-p";
17479 static char foo[] = "foo";
17480 static char bar[] = "bar";
17481 char *argv[] = { program, p, foo, bar, NULL };
17482
17483 optind = 1;
17484 if (getopt (4, argv, "p::") != 'p')
17485 result |= 2;
17486 else if (optarg != NULL)
17487 result |= 4;
17488 else if (getopt (4, argv, "p::") != -1)
17489 result |= 6;
17490 else if (optind != 2)
17491 result |= 8;
17492 }
17493 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17494 {
17495 static char program[] = "program";
17496 static char foo[] = "foo";
17497 static char p[] = "-p";
17498 char *argv[] = { program, foo, p, NULL };
17499 optind = 0;
17500 if (getopt (3, argv, "-p") != 1)
17501 result |= 16;
17502 else if (getopt (3, argv, "-p") != 'p')
17503 result |= 16;
17504 }
17505 /* This code fails on glibc 2.11. */
17506 {
17507 static char program[] = "program";
17508 static char b[] = "-b";
17509 static char a[] = "-a";
17510 char *argv[] = { program, b, a, NULL };
17511 optind = opterr = 0;
17512 if (getopt (3, argv, "+:a:b") != 'b')
17513 result |= 32;
17514 else if (getopt (3, argv, "+:a:b") != ':')
17515 result |= 32;
17516 }
17517 /* This code dumps core on glibc 2.14. */
17518 {
17519 static char program[] = "program";
17520 static char w[] = "-W";
17521 static char dummy[] = "dummy";
17522 char *argv[] = { program, w, dummy, NULL };
17523 optind = opterr = 1;
17524 if (getopt (3, argv, "W;") != 'W')
17525 result |= 64;
17526 }
17527 return result;
17528
17529 ;
17530 return 0;
17531 }
17532 _ACEOF
17533 if ac_fn_c_try_run "$LINENO"; then :
17534 gl_cv_func_getopt_gnu=yes
17535 else
17536 gl_cv_func_getopt_gnu=no
17537 fi
17538 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17539 conftest.$ac_objext conftest.beam conftest.$ac_ext
17540 fi
17541
17542 case $gl_had_POSIXLY_CORRECT in
17543 exported) ;;
17544 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17545 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17546 esac
17547
17548 fi
17549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17550 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17551 if test "$gl_cv_func_getopt_gnu" != yes; then
17552 gl_replace_getopt=yes
17553 else
17554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17555 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17556 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17557 $as_echo_n "(cached) " >&6
17558 else
17559 if test "$cross_compiling" = yes; then :
17560 case "$host_os" in
17561 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17562 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17563 esac
17564
17565 else
17566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17567 /* end confdefs.h. */
17568 #include <getopt.h>
17569 #include <stddef.h>
17570 #include <string.h>
17571
17572 int
17573 main ()
17574 {
17575 static const struct option long_options[] =
17576 {
17577 { "xtremely-",no_argument, NULL, 1003 },
17578 { "xtra", no_argument, NULL, 1001 },
17579 { "xtreme", no_argument, NULL, 1002 },
17580 { "xtremely", no_argument, NULL, 1003 },
17581 { NULL, 0, NULL, 0 }
17582 };
17583 /* This code fails on OpenBSD 5.0. */
17584 {
17585 static char program[] = "program";
17586 static char xtremel[] = "--xtremel";
17587 char *argv[] = { program, xtremel, NULL };
17588 int option_index;
17589 optind = 1; opterr = 0;
17590 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17591 return 1;
17592 }
17593 return 0;
17594
17595 ;
17596 return 0;
17597 }
17598 _ACEOF
17599 if ac_fn_c_try_run "$LINENO"; then :
17600 gl_cv_func_getopt_long_gnu=yes
17601 else
17602 gl_cv_func_getopt_long_gnu=no
17603 fi
17604 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17605 conftest.$ac_objext conftest.beam conftest.$ac_ext
17606 fi
17607
17608
17609 fi
17610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17611 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17612 case "$gl_cv_func_getopt_long_gnu" in
17613 *yes) ;;
17614 *) gl_replace_getopt=yes ;;
17615 esac
17616 fi
17617 fi
17618
17619
17620
17621
17622
17623
17624 REPLACE_GETOPT=0
17625 if test -n "$gl_replace_getopt"; then
17626 REPLACE_GETOPT=1
17627 fi
17628
17629 if test $REPLACE_GETOPT = 1; then
17630
17631 GETOPT_H=getopt.h
17632
17633 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17634
17635
17636
17637 fi
17638
17639 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17640 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17641 ac_have_decl=1
17642 else
17643 ac_have_decl=0
17644 fi
17645
17646 cat >>confdefs.h <<_ACEOF
17647 #define HAVE_DECL_GETENV $ac_have_decl
17648 _ACEOF
17649
17650 :
17651
17652
17653
17654
17655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17656 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17657 if test "${ac_cv_c_restrict+set}" = set; then :
17658 $as_echo_n "(cached) " >&6
17659 else
17660 ac_cv_c_restrict=no
17661 # The order here caters to the fact that C++ does not require restrict.
17662 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17664 /* end confdefs.h. */
17665 typedef int * int_ptr;
17666 int foo (int_ptr $ac_kw ip) {
17667 return ip[0];
17668 }
17669 int
17670 main ()
17671 {
17672 int s[1];
17673 int * $ac_kw t = s;
17674 t[0] = 0;
17675 return foo(t)
17676 ;
17677 return 0;
17678 }
17679 _ACEOF
17680 if ac_fn_c_try_compile "$LINENO"; then :
17681 ac_cv_c_restrict=$ac_kw
17682 fi
17683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17684 test "$ac_cv_c_restrict" != no && break
17685 done
17686
17687 fi
17688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17689 $as_echo "$ac_cv_c_restrict" >&6; }
17690
17691 case $ac_cv_c_restrict in
17692 restrict) ;;
17693 no) $as_echo "#define restrict /**/" >>confdefs.h
17694 ;;
17695 *) cat >>confdefs.h <<_ACEOF
17696 #define restrict $ac_cv_c_restrict
17697 _ACEOF
17698 ;;
17699 esac
17700
17701
17702 GNULIB_GETTIMEOFDAY=0;
17703 HAVE_GETTIMEOFDAY=1;
17704 HAVE_STRUCT_TIMEVAL=1;
17705 HAVE_SYS_TIME_H=1;
17706 REPLACE_GETTIMEOFDAY=0;
17707 REPLACE_STRUCT_TIMEVAL=0;
17708
17709
17710
17711
17712
17713
17714
17715
17716
17717
17718
17719
17720
17721
17722
17723
17724 if test $gl_cv_have_include_next = yes; then
17725 gl_cv_next_sys_time_h='<'sys/time.h'>'
17726 else
17727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17728 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17729 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17730 $as_echo_n "(cached) " >&6
17731 else
17732
17733 if test $ac_cv_header_sys_time_h = yes; then
17734
17735
17736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17737 /* end confdefs.h. */
17738 #include <sys/time.h>
17739
17740 _ACEOF
17741 case "$host_os" in
17742 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17743 *) gl_absname_cpp="$ac_cpp" ;;
17744 esac
17745
17746 case "$host_os" in
17747 mingw*)
17748 gl_dirsep_regex='[/\\]'
17749 ;;
17750 *)
17751 gl_dirsep_regex='\/'
17752 ;;
17753 esac
17754 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17755
17756 gl_header_literal_regex=`echo 'sys/time.h' \
17757 | sed -e "$gl_make_literal_regex_sed"`
17758 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17759 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17760 s|^/[^/]|//&|
17761 p
17762 q
17763 }'
17764 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17765 sed -n "$gl_absolute_header_sed"`'"'
17766 else
17767 gl_cv_next_sys_time_h='<'sys/time.h'>'
17768 fi
17769
17770
17771 fi
17772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17773 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17774 fi
17775 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17776
17777 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17778 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17779 gl_next_as_first_directive='<'sys/time.h'>'
17780 else
17781 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17782 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17783 fi
17784 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17785
17786
17787
17788
17789
17790 if test $ac_cv_header_sys_time_h != yes; then
17791 HAVE_SYS_TIME_H=0
17792 fi
17793
17794
17795
17796
17797
17798 if test $ac_cv_header_sys_socket_h != yes; then
17799 for ac_header in winsock2.h
17800 do :
17801 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17802 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17803 cat >>confdefs.h <<_ACEOF
17804 #define HAVE_WINSOCK2_H 1
17805 _ACEOF
17806
17807 fi
17808
17809 done
17810
17811 fi
17812 if test "$ac_cv_header_winsock2_h" = yes; then
17813 HAVE_WINSOCK2_H=1
17814 UNISTD_H_HAVE_WINSOCK2_H=1
17815 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17816 else
17817 HAVE_WINSOCK2_H=0
17818 fi
17819
17820
17821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17822 $as_echo_n "checking for struct timeval... " >&6; }
17823 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17824 $as_echo_n "(cached) " >&6
17825 else
17826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17827 /* end confdefs.h. */
17828 #if HAVE_SYS_TIME_H
17829 #include <sys/time.h>
17830 #endif
17831 #include <time.h>
17832 #if HAVE_WINSOCK2_H
17833 # include <winsock2.h>
17834 #endif
17835
17836 int
17837 main ()
17838 {
17839 static struct timeval x; x.tv_sec = x.tv_usec;
17840 ;
17841 return 0;
17842 }
17843 _ACEOF
17844 if ac_fn_c_try_compile "$LINENO"; then :
17845 gl_cv_sys_struct_timeval=yes
17846 else
17847 gl_cv_sys_struct_timeval=no
17848 fi
17849 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17850
17851 fi
17852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
17853 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
17854 if test $gl_cv_sys_struct_timeval != yes; then
17855 HAVE_STRUCT_TIMEVAL=0
17856 else
17857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
17858 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
17859 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
17860 $as_echo_n "(cached) " >&6
17861 else
17862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17863 /* end confdefs.h. */
17864 #if HAVE_SYS_TIME_H
17865 #include <sys/time.h>
17866 #endif
17867 #include <time.h>
17868 #if HAVE_WINSOCK2_H
17869 # include <winsock2.h>
17870 #endif
17871
17872 int
17873 main ()
17874 {
17875 static struct timeval x;
17876 typedef int verify_tv_sec_type[
17877 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
17878 ];
17879
17880 ;
17881 return 0;
17882 }
17883 _ACEOF
17884 if ac_fn_c_try_compile "$LINENO"; then :
17885 gl_cv_sys_struct_timeval_tv_sec=yes
17886 else
17887 gl_cv_sys_struct_timeval_tv_sec=no
17888 fi
17889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17890
17891 fi
17892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
17893 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
17894 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
17895 REPLACE_STRUCT_TIMEVAL=1
17896 fi
17897 fi
17898
17899
17900
17901
17902
17903
17904
17905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17906 $as_echo_n "checking for unsigned long long int... " >&6; }
17907 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17908 $as_echo_n "(cached) " >&6
17909 else
17910 ac_cv_type_unsigned_long_long_int=yes
17911 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17913 /* end confdefs.h. */
17914
17915 /* For now, do not test the preprocessor; as of 2007 there are too many
17916 implementations with broken preprocessors. Perhaps this can
17917 be revisited in 2012. In the meantime, code should not expect
17918 #if to work with literals wider than 32 bits. */
17919 /* Test literals. */
17920 long long int ll = 9223372036854775807ll;
17921 long long int nll = -9223372036854775807LL;
17922 unsigned long long int ull = 18446744073709551615ULL;
17923 /* Test constant expressions. */
17924 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17925 ? 1 : -1)];
17926 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17927 ? 1 : -1)];
17928 int i = 63;
17929 int
17930 main ()
17931 {
17932 /* Test availability of runtime routines for shift and division. */
17933 long long int llmax = 9223372036854775807ll;
17934 unsigned long long int ullmax = 18446744073709551615ull;
17935 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17936 | (llmax / ll) | (llmax % ll)
17937 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17938 | (ullmax / ull) | (ullmax % ull));
17939 ;
17940 return 0;
17941 }
17942
17943 _ACEOF
17944 if ac_fn_c_try_link "$LINENO"; then :
17945
17946 else
17947 ac_cv_type_unsigned_long_long_int=no
17948 fi
17949 rm -f core conftest.err conftest.$ac_objext \
17950 conftest$ac_exeext conftest.$ac_ext
17951 fi
17952 fi
17953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17954 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17955 if test $ac_cv_type_unsigned_long_long_int = yes; then
17956
17957 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17958
17959 fi
17960
17961
17962
17963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17964 $as_echo_n "checking for long long int... " >&6; }
17965 if test "${ac_cv_type_long_long_int+set}" = set; then :
17966 $as_echo_n "(cached) " >&6
17967 else
17968 ac_cv_type_long_long_int=yes
17969 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17970 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17971 if test $ac_cv_type_long_long_int = yes; then
17972 if test "$cross_compiling" = yes; then :
17973 :
17974 else
17975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17976 /* end confdefs.h. */
17977 #include <limits.h>
17978 #ifndef LLONG_MAX
17979 # define HALF \
17980 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17981 # define LLONG_MAX (HALF - 1 + HALF)
17982 #endif
17983 int
17984 main ()
17985 {
17986 long long int n = 1;
17987 int i;
17988 for (i = 0; ; i++)
17989 {
17990 long long int m = n << i;
17991 if (m >> i != n)
17992 return 1;
17993 if (LLONG_MAX / 2 < m)
17994 break;
17995 }
17996 return 0;
17997 ;
17998 return 0;
17999 }
18000 _ACEOF
18001 if ac_fn_c_try_run "$LINENO"; then :
18002
18003 else
18004 ac_cv_type_long_long_int=no
18005 fi
18006 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18007 conftest.$ac_objext conftest.beam conftest.$ac_ext
18008 fi
18009
18010 fi
18011 fi
18012 fi
18013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
18014 $as_echo "$ac_cv_type_long_long_int" >&6; }
18015 if test $ac_cv_type_long_long_int = yes; then
18016
18017 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
18018
18019 fi
18020
18021
18022
18023
18024
18025
18026 gl_cv_c_multiarch=no
18027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18028 /* end confdefs.h. */
18029 #ifndef __APPLE_CC__
18030 not a universal capable compiler
18031 #endif
18032 typedef int dummy;
18033
18034 _ACEOF
18035 if ac_fn_c_try_compile "$LINENO"; then :
18036
18037 arch=
18038 prev=
18039 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
18040 if test -n "$prev"; then
18041 case $word in
18042 i?86 | x86_64 | ppc | ppc64)
18043 if test -z "$arch" || test "$arch" = "$word"; then
18044 arch="$word"
18045 else
18046 gl_cv_c_multiarch=yes
18047 fi
18048 ;;
18049 esac
18050 prev=
18051 else
18052 if test "x$word" = "x-arch"; then
18053 prev=arch
18054 fi
18055 fi
18056 done
18057
18058 fi
18059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18060 if test $gl_cv_c_multiarch = yes; then
18061 APPLE_UNIVERSAL_BUILD=1
18062 else
18063 APPLE_UNIVERSAL_BUILD=0
18064 fi
18065
18066
18067
18068
18069
18070 if test $ac_cv_type_long_long_int = yes; then
18071 HAVE_LONG_LONG_INT=1
18072 else
18073 HAVE_LONG_LONG_INT=0
18074 fi
18075
18076
18077 if test $ac_cv_type_unsigned_long_long_int = yes; then
18078 HAVE_UNSIGNED_LONG_LONG_INT=1
18079 else
18080 HAVE_UNSIGNED_LONG_LONG_INT=0
18081 fi
18082
18083
18084
18085 if test $ac_cv_header_wchar_h = yes; then
18086 HAVE_WCHAR_H=1
18087 else
18088 HAVE_WCHAR_H=0
18089 fi
18090
18091
18092 if test $ac_cv_header_inttypes_h = yes; then
18093 HAVE_INTTYPES_H=1
18094 else
18095 HAVE_INTTYPES_H=0
18096 fi
18097
18098
18099 if test $ac_cv_header_sys_types_h = yes; then
18100 HAVE_SYS_TYPES_H=1
18101 else
18102 HAVE_SYS_TYPES_H=0
18103 fi
18104
18105
18106
18107
18108
18109
18110
18111
18112
18113
18114
18115 if test $gl_cv_have_include_next = yes; then
18116 gl_cv_next_stdint_h='<'stdint.h'>'
18117 else
18118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
18119 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
18120 if test "${gl_cv_next_stdint_h+set}" = set; then :
18121 $as_echo_n "(cached) " >&6
18122 else
18123
18124 if test $ac_cv_header_stdint_h = yes; then
18125
18126
18127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18128 /* end confdefs.h. */
18129 #include <stdint.h>
18130
18131 _ACEOF
18132 case "$host_os" in
18133 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18134 *) gl_absname_cpp="$ac_cpp" ;;
18135 esac
18136
18137 case "$host_os" in
18138 mingw*)
18139 gl_dirsep_regex='[/\\]'
18140 ;;
18141 *)
18142 gl_dirsep_regex='\/'
18143 ;;
18144 esac
18145 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18146
18147 gl_header_literal_regex=`echo 'stdint.h' \
18148 | sed -e "$gl_make_literal_regex_sed"`
18149 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18150 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18151 s|^/[^/]|//&|
18152 p
18153 q
18154 }'
18155 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18156 sed -n "$gl_absolute_header_sed"`'"'
18157 else
18158 gl_cv_next_stdint_h='<'stdint.h'>'
18159 fi
18160
18161
18162 fi
18163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18164 $as_echo "$gl_cv_next_stdint_h" >&6; }
18165 fi
18166 NEXT_STDINT_H=$gl_cv_next_stdint_h
18167
18168 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18169 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18170 gl_next_as_first_directive='<'stdint.h'>'
18171 else
18172 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18173 gl_next_as_first_directive=$gl_cv_next_stdint_h
18174 fi
18175 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18176
18177
18178
18179
18180 if test $ac_cv_header_stdint_h = yes; then
18181 HAVE_STDINT_H=1
18182 else
18183 HAVE_STDINT_H=0
18184 fi
18185
18186
18187 if test $ac_cv_header_stdint_h = yes; then
18188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18189 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18190 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18191 $as_echo_n "(cached) " >&6
18192 else
18193 gl_cv_header_working_stdint_h=no
18194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18195 /* end confdefs.h. */
18196
18197
18198 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18199 #include <stdint.h>
18200 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18201 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18202 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18203 #endif
18204
18205
18206 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18207 included before <wchar.h>. */
18208 #include <stddef.h>
18209 #include <signal.h>
18210 #if HAVE_WCHAR_H
18211 # include <stdio.h>
18212 # include <time.h>
18213 # include <wchar.h>
18214 #endif
18215
18216
18217 #ifdef INT8_MAX
18218 int8_t a1 = INT8_MAX;
18219 int8_t a1min = INT8_MIN;
18220 #endif
18221 #ifdef INT16_MAX
18222 int16_t a2 = INT16_MAX;
18223 int16_t a2min = INT16_MIN;
18224 #endif
18225 #ifdef INT32_MAX
18226 int32_t a3 = INT32_MAX;
18227 int32_t a3min = INT32_MIN;
18228 #endif
18229 #ifdef INT64_MAX
18230 int64_t a4 = INT64_MAX;
18231 int64_t a4min = INT64_MIN;
18232 #endif
18233 #ifdef UINT8_MAX
18234 uint8_t b1 = UINT8_MAX;
18235 #else
18236 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18237 #endif
18238 #ifdef UINT16_MAX
18239 uint16_t b2 = UINT16_MAX;
18240 #endif
18241 #ifdef UINT32_MAX
18242 uint32_t b3 = UINT32_MAX;
18243 #endif
18244 #ifdef UINT64_MAX
18245 uint64_t b4 = UINT64_MAX;
18246 #endif
18247 int_least8_t c1 = INT8_C (0x7f);
18248 int_least8_t c1max = INT_LEAST8_MAX;
18249 int_least8_t c1min = INT_LEAST8_MIN;
18250 int_least16_t c2 = INT16_C (0x7fff);
18251 int_least16_t c2max = INT_LEAST16_MAX;
18252 int_least16_t c2min = INT_LEAST16_MIN;
18253 int_least32_t c3 = INT32_C (0x7fffffff);
18254 int_least32_t c3max = INT_LEAST32_MAX;
18255 int_least32_t c3min = INT_LEAST32_MIN;
18256 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18257 int_least64_t c4max = INT_LEAST64_MAX;
18258 int_least64_t c4min = INT_LEAST64_MIN;
18259 uint_least8_t d1 = UINT8_C (0xff);
18260 uint_least8_t d1max = UINT_LEAST8_MAX;
18261 uint_least16_t d2 = UINT16_C (0xffff);
18262 uint_least16_t d2max = UINT_LEAST16_MAX;
18263 uint_least32_t d3 = UINT32_C (0xffffffff);
18264 uint_least32_t d3max = UINT_LEAST32_MAX;
18265 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18266 uint_least64_t d4max = UINT_LEAST64_MAX;
18267 int_fast8_t e1 = INT_FAST8_MAX;
18268 int_fast8_t e1min = INT_FAST8_MIN;
18269 int_fast16_t e2 = INT_FAST16_MAX;
18270 int_fast16_t e2min = INT_FAST16_MIN;
18271 int_fast32_t e3 = INT_FAST32_MAX;
18272 int_fast32_t e3min = INT_FAST32_MIN;
18273 int_fast64_t e4 = INT_FAST64_MAX;
18274 int_fast64_t e4min = INT_FAST64_MIN;
18275 uint_fast8_t f1 = UINT_FAST8_MAX;
18276 uint_fast16_t f2 = UINT_FAST16_MAX;
18277 uint_fast32_t f3 = UINT_FAST32_MAX;
18278 uint_fast64_t f4 = UINT_FAST64_MAX;
18279 #ifdef INTPTR_MAX
18280 intptr_t g = INTPTR_MAX;
18281 intptr_t gmin = INTPTR_MIN;
18282 #endif
18283 #ifdef UINTPTR_MAX
18284 uintptr_t h = UINTPTR_MAX;
18285 #endif
18286 intmax_t i = INTMAX_MAX;
18287 uintmax_t j = UINTMAX_MAX;
18288
18289 #include <limits.h> /* for CHAR_BIT */
18290 #define TYPE_MINIMUM(t) \
18291 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18292 #define TYPE_MAXIMUM(t) \
18293 ((t) ((t) 0 < (t) -1 \
18294 ? (t) -1 \
18295 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18296 struct s {
18297 int check_PTRDIFF:
18298 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18299 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18300 ? 1 : -1;
18301 /* Detect bug in FreeBSD 6.0 / ia64. */
18302 int check_SIG_ATOMIC:
18303 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18304 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18305 ? 1 : -1;
18306 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18307 int check_WCHAR:
18308 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18309 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18310 ? 1 : -1;
18311 /* Detect bug in mingw. */
18312 int check_WINT:
18313 WINT_MIN == TYPE_MINIMUM (wint_t)
18314 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18315 ? 1 : -1;
18316
18317 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18318 int check_UINT8_C:
18319 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18320 int check_UINT16_C:
18321 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18322
18323 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18324 #ifdef UINT8_MAX
18325 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18326 #endif
18327 #ifdef UINT16_MAX
18328 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18329 #endif
18330 #ifdef UINT32_MAX
18331 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18332 #endif
18333 #ifdef UINT64_MAX
18334 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18335 #endif
18336 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18337 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18338 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18339 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18340 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18341 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18342 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18343 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18344 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18345 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18346 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18347 };
18348
18349 int
18350 main ()
18351 {
18352
18353 ;
18354 return 0;
18355 }
18356 _ACEOF
18357 if ac_fn_c_try_compile "$LINENO"; then :
18358 if test "$cross_compiling" = yes; then :
18359 gl_cv_header_working_stdint_h=yes
18360
18361 else
18362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18363 /* end confdefs.h. */
18364
18365
18366 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18367 #include <stdint.h>
18368
18369
18370 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18371 included before <wchar.h>. */
18372 #include <stddef.h>
18373 #include <signal.h>
18374 #if HAVE_WCHAR_H
18375 # include <stdio.h>
18376 # include <time.h>
18377 # include <wchar.h>
18378 #endif
18379
18380
18381 #include <stdio.h>
18382 #include <string.h>
18383 #define MVAL(macro) MVAL1(macro)
18384 #define MVAL1(expression) #expression
18385 static const char *macro_values[] =
18386 {
18387 #ifdef INT8_MAX
18388 MVAL (INT8_MAX),
18389 #endif
18390 #ifdef INT16_MAX
18391 MVAL (INT16_MAX),
18392 #endif
18393 #ifdef INT32_MAX
18394 MVAL (INT32_MAX),
18395 #endif
18396 #ifdef INT64_MAX
18397 MVAL (INT64_MAX),
18398 #endif
18399 #ifdef UINT8_MAX
18400 MVAL (UINT8_MAX),
18401 #endif
18402 #ifdef UINT16_MAX
18403 MVAL (UINT16_MAX),
18404 #endif
18405 #ifdef UINT32_MAX
18406 MVAL (UINT32_MAX),
18407 #endif
18408 #ifdef UINT64_MAX
18409 MVAL (UINT64_MAX),
18410 #endif
18411 NULL
18412 };
18413
18414 int
18415 main ()
18416 {
18417
18418 const char **mv;
18419 for (mv = macro_values; *mv != NULL; mv++)
18420 {
18421 const char *value = *mv;
18422 /* Test whether it looks like a cast expression. */
18423 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18424 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18425 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18426 || strncmp (value, "((int)"/*)*/, 6) == 0
18427 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18428 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18429 return mv - macro_values + 1;
18430 }
18431 return 0;
18432
18433 ;
18434 return 0;
18435 }
18436 _ACEOF
18437 if ac_fn_c_try_run "$LINENO"; then :
18438 gl_cv_header_working_stdint_h=yes
18439 fi
18440 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18441 conftest.$ac_objext conftest.beam conftest.$ac_ext
18442 fi
18443
18444
18445 fi
18446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18447
18448 fi
18449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18450 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18451 fi
18452 if test "$gl_cv_header_working_stdint_h" = yes; then
18453 STDINT_H=
18454 else
18455 for ac_header in sys/inttypes.h sys/bitypes.h
18456 do :
18457 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18458 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18459 eval as_val=\$$as_ac_Header
18460 if test "x$as_val" = x""yes; then :
18461 cat >>confdefs.h <<_ACEOF
18462 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18463 _ACEOF
18464
18465 fi
18466
18467 done
18468
18469 if test $ac_cv_header_sys_inttypes_h = yes; then
18470 HAVE_SYS_INTTYPES_H=1
18471 else
18472 HAVE_SYS_INTTYPES_H=0
18473 fi
18474
18475 if test $ac_cv_header_sys_bitypes_h = yes; then
18476 HAVE_SYS_BITYPES_H=1
18477 else
18478 HAVE_SYS_BITYPES_H=0
18479 fi
18480
18481
18482
18483
18484 if test $APPLE_UNIVERSAL_BUILD = 0; then
18485
18486
18487 for gltype in ptrdiff_t size_t ; do
18488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18489 $as_echo_n "checking for bit size of $gltype... " >&6; }
18490 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18491 $as_echo_n "(cached) " >&6
18492 else
18493 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18494 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18495 included before <wchar.h>. */
18496 #include <stddef.h>
18497 #include <signal.h>
18498 #if HAVE_WCHAR_H
18499 # include <stdio.h>
18500 # include <time.h>
18501 # include <wchar.h>
18502 #endif
18503
18504 #include <limits.h>"; then :
18505
18506 else
18507 result=unknown
18508 fi
18509
18510 eval gl_cv_bitsizeof_${gltype}=\$result
18511
18512 fi
18513 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18515 $as_echo "$ac_res" >&6; }
18516 eval result=\$gl_cv_bitsizeof_${gltype}
18517 if test $result = unknown; then
18518 result=0
18519 fi
18520 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18521 cat >>confdefs.h <<_ACEOF
18522 #define BITSIZEOF_${GLTYPE} $result
18523 _ACEOF
18524
18525 eval BITSIZEOF_${GLTYPE}=\$result
18526 done
18527
18528
18529 fi
18530
18531
18532 for gltype in sig_atomic_t wchar_t wint_t ; do
18533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18534 $as_echo_n "checking for bit size of $gltype... " >&6; }
18535 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18536 $as_echo_n "(cached) " >&6
18537 else
18538 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18539 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18540 included before <wchar.h>. */
18541 #include <stddef.h>
18542 #include <signal.h>
18543 #if HAVE_WCHAR_H
18544 # include <stdio.h>
18545 # include <time.h>
18546 # include <wchar.h>
18547 #endif
18548
18549 #include <limits.h>"; then :
18550
18551 else
18552 result=unknown
18553 fi
18554
18555 eval gl_cv_bitsizeof_${gltype}=\$result
18556
18557 fi
18558 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18560 $as_echo "$ac_res" >&6; }
18561 eval result=\$gl_cv_bitsizeof_${gltype}
18562 if test $result = unknown; then
18563 result=0
18564 fi
18565 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18566 cat >>confdefs.h <<_ACEOF
18567 #define BITSIZEOF_${GLTYPE} $result
18568 _ACEOF
18569
18570 eval BITSIZEOF_${GLTYPE}=\$result
18571 done
18572
18573
18574
18575
18576 for gltype in sig_atomic_t wchar_t wint_t ; do
18577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18578 $as_echo_n "checking whether $gltype is signed... " >&6; }
18579 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18580 $as_echo_n "(cached) " >&6
18581 else
18582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18583 /* end confdefs.h. */
18584
18585 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18586 included before <wchar.h>. */
18587 #include <stddef.h>
18588 #include <signal.h>
18589 #if HAVE_WCHAR_H
18590 # include <stdio.h>
18591 # include <time.h>
18592 # include <wchar.h>
18593 #endif
18594
18595 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18596 int
18597 main ()
18598 {
18599
18600 ;
18601 return 0;
18602 }
18603 _ACEOF
18604 if ac_fn_c_try_compile "$LINENO"; then :
18605 result=yes
18606 else
18607 result=no
18608 fi
18609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18610 eval gl_cv_type_${gltype}_signed=\$result
18611
18612 fi
18613 eval ac_res=\$gl_cv_type_${gltype}_signed
18614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18615 $as_echo "$ac_res" >&6; }
18616 eval result=\$gl_cv_type_${gltype}_signed
18617 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18618 if test "$result" = yes; then
18619 cat >>confdefs.h <<_ACEOF
18620 #define HAVE_SIGNED_${GLTYPE} 1
18621 _ACEOF
18622
18623 eval HAVE_SIGNED_${GLTYPE}=1
18624 else
18625 eval HAVE_SIGNED_${GLTYPE}=0
18626 fi
18627 done
18628
18629
18630 gl_cv_type_ptrdiff_t_signed=yes
18631 gl_cv_type_size_t_signed=no
18632 if test $APPLE_UNIVERSAL_BUILD = 0; then
18633
18634
18635 for gltype in ptrdiff_t size_t ; do
18636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18637 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18638 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18639 $as_echo_n "(cached) " >&6
18640 else
18641 eval gl_cv_type_${gltype}_suffix=no
18642 eval result=\$gl_cv_type_${gltype}_signed
18643 if test "$result" = yes; then
18644 glsufu=
18645 else
18646 glsufu=u
18647 fi
18648 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18649 case $glsuf in
18650 '') gltype1='int';;
18651 l) gltype1='long int';;
18652 ll) gltype1='long long int';;
18653 i64) gltype1='__int64';;
18654 u) gltype1='unsigned int';;
18655 ul) gltype1='unsigned long int';;
18656 ull) gltype1='unsigned long long int';;
18657 ui64)gltype1='unsigned __int64';;
18658 esac
18659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18660 /* end confdefs.h. */
18661
18662 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18663 included before <wchar.h>. */
18664 #include <stddef.h>
18665 #include <signal.h>
18666 #if HAVE_WCHAR_H
18667 # include <stdio.h>
18668 # include <time.h>
18669 # include <wchar.h>
18670 #endif
18671
18672 extern $gltype foo;
18673 extern $gltype1 foo;
18674 int
18675 main ()
18676 {
18677
18678 ;
18679 return 0;
18680 }
18681 _ACEOF
18682 if ac_fn_c_try_compile "$LINENO"; then :
18683 eval gl_cv_type_${gltype}_suffix=\$glsuf
18684 fi
18685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18686 eval result=\$gl_cv_type_${gltype}_suffix
18687 test "$result" != no && break
18688 done
18689 fi
18690 eval ac_res=\$gl_cv_type_${gltype}_suffix
18691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18692 $as_echo "$ac_res" >&6; }
18693 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18694 eval result=\$gl_cv_type_${gltype}_suffix
18695 test "$result" = no && result=
18696 eval ${GLTYPE}_SUFFIX=\$result
18697 cat >>confdefs.h <<_ACEOF
18698 #define ${GLTYPE}_SUFFIX $result
18699 _ACEOF
18700
18701 done
18702
18703
18704 fi
18705
18706
18707 for gltype in sig_atomic_t wchar_t wint_t ; do
18708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18709 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18710 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18711 $as_echo_n "(cached) " >&6
18712 else
18713 eval gl_cv_type_${gltype}_suffix=no
18714 eval result=\$gl_cv_type_${gltype}_signed
18715 if test "$result" = yes; then
18716 glsufu=
18717 else
18718 glsufu=u
18719 fi
18720 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18721 case $glsuf in
18722 '') gltype1='int';;
18723 l) gltype1='long int';;
18724 ll) gltype1='long long int';;
18725 i64) gltype1='__int64';;
18726 u) gltype1='unsigned int';;
18727 ul) gltype1='unsigned long int';;
18728 ull) gltype1='unsigned long long int';;
18729 ui64)gltype1='unsigned __int64';;
18730 esac
18731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18732 /* end confdefs.h. */
18733
18734 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18735 included before <wchar.h>. */
18736 #include <stddef.h>
18737 #include <signal.h>
18738 #if HAVE_WCHAR_H
18739 # include <stdio.h>
18740 # include <time.h>
18741 # include <wchar.h>
18742 #endif
18743
18744 extern $gltype foo;
18745 extern $gltype1 foo;
18746 int
18747 main ()
18748 {
18749
18750 ;
18751 return 0;
18752 }
18753 _ACEOF
18754 if ac_fn_c_try_compile "$LINENO"; then :
18755 eval gl_cv_type_${gltype}_suffix=\$glsuf
18756 fi
18757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18758 eval result=\$gl_cv_type_${gltype}_suffix
18759 test "$result" != no && break
18760 done
18761 fi
18762 eval ac_res=\$gl_cv_type_${gltype}_suffix
18763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18764 $as_echo "$ac_res" >&6; }
18765 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18766 eval result=\$gl_cv_type_${gltype}_suffix
18767 test "$result" = no && result=
18768 eval ${GLTYPE}_SUFFIX=\$result
18769 cat >>confdefs.h <<_ACEOF
18770 #define ${GLTYPE}_SUFFIX $result
18771 _ACEOF
18772
18773 done
18774
18775
18776
18777 if test $BITSIZEOF_WINT_T -lt 32; then
18778 BITSIZEOF_WINT_T=32
18779 fi
18780
18781 STDINT_H=stdint.h
18782 fi
18783
18784 if test -n "$STDINT_H"; then
18785 GL_GENERATE_STDINT_H_TRUE=
18786 GL_GENERATE_STDINT_H_FALSE='#'
18787 else
18788 GL_GENERATE_STDINT_H_TRUE='#'
18789 GL_GENERATE_STDINT_H_FALSE=
18790 fi
18791
18792
18793
18794
18795
18796 GNULIB_IMAXABS=0;
18797 GNULIB_IMAXDIV=0;
18798 GNULIB_STRTOIMAX=0;
18799 GNULIB_STRTOUMAX=0;
18800 HAVE_DECL_IMAXABS=1;
18801 HAVE_DECL_IMAXDIV=1;
18802 HAVE_DECL_STRTOIMAX=1;
18803 HAVE_DECL_STRTOUMAX=1;
18804 REPLACE_STRTOIMAX=0;
18805 INT32_MAX_LT_INTMAX_MAX=1;
18806 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18807 PRI_MACROS_BROKEN=0;
18808 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18809 UINT32_MAX_LT_UINTMAX_MAX=1;
18810 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18811
18812
18813
18814
18815
18816
18817
18818
18819
18820
18821
18822
18823
18824
18825
18826 if test $gl_cv_have_include_next = yes; then
18827 gl_cv_next_inttypes_h='<'inttypes.h'>'
18828 else
18829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18830 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18831 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18832 $as_echo_n "(cached) " >&6
18833 else
18834
18835 if test $ac_cv_header_inttypes_h = yes; then
18836
18837
18838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18839 /* end confdefs.h. */
18840 #include <inttypes.h>
18841
18842 _ACEOF
18843 case "$host_os" in
18844 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18845 *) gl_absname_cpp="$ac_cpp" ;;
18846 esac
18847
18848 case "$host_os" in
18849 mingw*)
18850 gl_dirsep_regex='[/\\]'
18851 ;;
18852 *)
18853 gl_dirsep_regex='\/'
18854 ;;
18855 esac
18856 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18857
18858 gl_header_literal_regex=`echo 'inttypes.h' \
18859 | sed -e "$gl_make_literal_regex_sed"`
18860 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18861 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18862 s|^/[^/]|//&|
18863 p
18864 q
18865 }'
18866 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18867 sed -n "$gl_absolute_header_sed"`'"'
18868 else
18869 gl_cv_next_inttypes_h='<'inttypes.h'>'
18870 fi
18871
18872
18873 fi
18874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18875 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18876 fi
18877 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18878
18879 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18880 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18881 gl_next_as_first_directive='<'inttypes.h'>'
18882 else
18883 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18884 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18885 fi
18886 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18887
18888
18889
18890
18891
18892
18893
18894
18895
18896
18897
18898 case "$host_os" in
18899 mingw*)
18900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
18901 $as_echo_n "checking for 64-bit off_t... " >&6; }
18902 if test "${gl_cv_type_off_t_64+set}" = set; then :
18903 $as_echo_n "(cached) " >&6
18904 else
18905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18906 /* end confdefs.h. */
18907 #include <sys/types.h>
18908 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
18909
18910 int
18911 main ()
18912 {
18913
18914 ;
18915 return 0;
18916 }
18917 _ACEOF
18918 if ac_fn_c_try_compile "$LINENO"; then :
18919 gl_cv_type_off_t_64=yes
18920 else
18921 gl_cv_type_off_t_64=no
18922 fi
18923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18924
18925 fi
18926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
18927 $as_echo "$gl_cv_type_off_t_64" >&6; }
18928 if test $gl_cv_type_off_t_64 = no; then
18929 WINDOWS_64_BIT_OFF_T=1
18930 else
18931 WINDOWS_64_BIT_OFF_T=0
18932 fi
18933 WINDOWS_64_BIT_ST_SIZE=1
18934 ;;
18935 *)
18936 WINDOWS_64_BIT_OFF_T=0
18937 WINDOWS_64_BIT_ST_SIZE=0
18938 ;;
18939 esac
18940
18941
18942 GNULIB_FCHMODAT=0;
18943 GNULIB_FSTAT=0;
18944 GNULIB_FSTATAT=0;
18945 GNULIB_FUTIMENS=0;
18946 GNULIB_LCHMOD=0;
18947 GNULIB_LSTAT=0;
18948 GNULIB_MKDIRAT=0;
18949 GNULIB_MKFIFO=0;
18950 GNULIB_MKFIFOAT=0;
18951 GNULIB_MKNOD=0;
18952 GNULIB_MKNODAT=0;
18953 GNULIB_STAT=0;
18954 GNULIB_UTIMENSAT=0;
18955 HAVE_FCHMODAT=1;
18956 HAVE_FSTATAT=1;
18957 HAVE_FUTIMENS=1;
18958 HAVE_LCHMOD=1;
18959 HAVE_LSTAT=1;
18960 HAVE_MKDIRAT=1;
18961 HAVE_MKFIFO=1;
18962 HAVE_MKFIFOAT=1;
18963 HAVE_MKNOD=1;
18964 HAVE_MKNODAT=1;
18965 HAVE_UTIMENSAT=1;
18966 REPLACE_FSTAT=0;
18967 REPLACE_FSTATAT=0;
18968 REPLACE_FUTIMENS=0;
18969 REPLACE_LSTAT=0;
18970 REPLACE_MKDIR=0;
18971 REPLACE_MKFIFO=0;
18972 REPLACE_MKNOD=0;
18973 REPLACE_STAT=0;
18974 REPLACE_UTIMENSAT=0;
18975
18976
18977
18978
18979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18980 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18981 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18982 $as_echo_n "(cached) " >&6
18983 else
18984 rm -f conftest.sym conftest.file
18985 echo >conftest.file
18986 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18987 if test "$cross_compiling" = yes; then :
18988 case "$host_os" in
18989 # Guess yes on glibc systems.
18990 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18991 # If we don't know, assume the worst.
18992 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18993 esac
18994
18995 else
18996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18997 /* end confdefs.h. */
18998 $ac_includes_default
18999 int
19000 main ()
19001 {
19002 struct stat sbuf;
19003 /* Linux will dereference the symlink and fail, as required by
19004 POSIX. That is better in the sense that it means we will not
19005 have to compile and use the lstat wrapper. */
19006 return lstat ("conftest.sym/", &sbuf) == 0;
19007
19008 ;
19009 return 0;
19010 }
19011 _ACEOF
19012 if ac_fn_c_try_run "$LINENO"; then :
19013 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19014 else
19015 gl_cv_func_lstat_dereferences_slashed_symlink=no
19016 fi
19017 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19018 conftest.$ac_objext conftest.beam conftest.$ac_ext
19019 fi
19020
19021 else
19022 # If the 'ln -s' command failed, then we probably don't even
19023 # have an lstat function.
19024 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19025 fi
19026 rm -f conftest.sym conftest.file
19027
19028 fi
19029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19030 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19031 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19032 *yes)
19033
19034 cat >>confdefs.h <<_ACEOF
19035 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19036 _ACEOF
19037
19038 ;;
19039 esac
19040
19041
19042 GNULIB_MKTIME=0;
19043 GNULIB_NANOSLEEP=0;
19044 GNULIB_STRPTIME=0;
19045 GNULIB_TIMEGM=0;
19046 GNULIB_TIME_R=0;
19047 HAVE_DECL_LOCALTIME_R=1;
19048 HAVE_NANOSLEEP=1;
19049 HAVE_STRPTIME=1;
19050 HAVE_TIMEGM=1;
19051 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
19052 REPLACE_MKTIME=GNULIB_PORTCHECK;
19053 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
19054 REPLACE_TIMEGM=GNULIB_PORTCHECK;
19055
19056
19057
19058
19059 GNULIB_PSELECT=0;
19060 GNULIB_SELECT=0;
19061 HAVE_PSELECT=1;
19062 REPLACE_PSELECT=0;
19063 REPLACE_SELECT=0;
19064
19065
19066
19067
19068
19069
19070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
19071 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
19072 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
19073 $as_echo_n "(cached) " >&6
19074 else
19075
19076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19077 /* end confdefs.h. */
19078 #include <sys/select.h>
19079 int
19080 main ()
19081 {
19082 struct timeval b;
19083 ;
19084 return 0;
19085 }
19086 _ACEOF
19087 if ac_fn_c_try_compile "$LINENO"; then :
19088 gl_cv_header_sys_select_h_selfcontained=yes
19089 else
19090 gl_cv_header_sys_select_h_selfcontained=no
19091 fi
19092 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19093 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
19094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19095 /* end confdefs.h. */
19096 #include <sys/select.h>
19097 int
19098 main ()
19099 {
19100 int memset; int bzero;
19101 ;
19102 return 0;
19103 }
19104
19105 _ACEOF
19106 if ac_fn_c_try_compile "$LINENO"; then :
19107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19108 /* end confdefs.h. */
19109 #include <sys/select.h>
19110 int
19111 main ()
19112 {
19113
19114 #undef memset
19115 #define memset nonexistent_memset
19116 extern
19117 #ifdef __cplusplus
19118 "C"
19119 #endif
19120 void *memset (void *, int, unsigned long);
19121 #undef bzero
19122 #define bzero nonexistent_bzero
19123 extern
19124 #ifdef __cplusplus
19125 "C"
19126 #endif
19127 void bzero (void *, unsigned long);
19128 fd_set fds;
19129 FD_ZERO (&fds);
19130
19131 ;
19132 return 0;
19133 }
19134
19135 _ACEOF
19136 if ac_fn_c_try_link "$LINENO"; then :
19137
19138 else
19139 gl_cv_header_sys_select_h_selfcontained=no
19140 fi
19141 rm -f core conftest.err conftest.$ac_objext \
19142 conftest$ac_exeext conftest.$ac_ext
19143
19144 fi
19145 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19146 fi
19147
19148 fi
19149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19150 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19151
19152
19153
19154
19155
19156
19157
19158
19159
19160 if test $gl_cv_have_include_next = yes; then
19161 gl_cv_next_sys_select_h='<'sys/select.h'>'
19162 else
19163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19164 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19165 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19166 $as_echo_n "(cached) " >&6
19167 else
19168
19169 if test $ac_cv_header_sys_select_h = yes; then
19170
19171
19172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19173 /* end confdefs.h. */
19174 #include <sys/select.h>
19175
19176 _ACEOF
19177 case "$host_os" in
19178 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19179 *) gl_absname_cpp="$ac_cpp" ;;
19180 esac
19181
19182 case "$host_os" in
19183 mingw*)
19184 gl_dirsep_regex='[/\\]'
19185 ;;
19186 *)
19187 gl_dirsep_regex='\/'
19188 ;;
19189 esac
19190 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19191
19192 gl_header_literal_regex=`echo 'sys/select.h' \
19193 | sed -e "$gl_make_literal_regex_sed"`
19194 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19195 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19196 s|^/[^/]|//&|
19197 p
19198 q
19199 }'
19200 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19201 sed -n "$gl_absolute_header_sed"`'"'
19202 else
19203 gl_cv_next_sys_select_h='<'sys/select.h'>'
19204 fi
19205
19206
19207 fi
19208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19209 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19210 fi
19211 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19212
19213 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19214 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19215 gl_next_as_first_directive='<'sys/select.h'>'
19216 else
19217 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19218 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19219 fi
19220 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19221
19222
19223
19224
19225 if test $ac_cv_header_sys_select_h = yes; then
19226 HAVE_SYS_SELECT_H=1
19227 else
19228 HAVE_SYS_SELECT_H=0
19229 fi
19230
19231
19232
19233
19234
19235 if test $ac_cv_header_sys_socket_h != yes; then
19236 for ac_header in winsock2.h
19237 do :
19238 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19239 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19240 cat >>confdefs.h <<_ACEOF
19241 #define HAVE_WINSOCK2_H 1
19242 _ACEOF
19243
19244 fi
19245
19246 done
19247
19248 fi
19249 if test "$ac_cv_header_winsock2_h" = yes; then
19250 HAVE_WINSOCK2_H=1
19251 UNISTD_H_HAVE_WINSOCK2_H=1
19252 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19253 else
19254 HAVE_WINSOCK2_H=0
19255 fi
19256
19257
19258
19259
19260
19261
19262
19263
19264 GNULIB_PTHREAD_SIGMASK=0;
19265 GNULIB_RAISE=0;
19266 GNULIB_SIGNAL_H_SIGPIPE=0;
19267 GNULIB_SIGPROCMASK=0;
19268 GNULIB_SIGACTION=0;
19269 HAVE_POSIX_SIGNALBLOCKING=1;
19270 HAVE_PTHREAD_SIGMASK=1;
19271 HAVE_RAISE=1;
19272 HAVE_SIGSET_T=1;
19273 HAVE_SIGINFO_T=1;
19274 HAVE_SIGACTION=1;
19275 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19276
19277 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19278
19279 HAVE_SIGHANDLER_T=1;
19280 REPLACE_PTHREAD_SIGMASK=0;
19281 REPLACE_RAISE=0;
19282
19283
19284
19285
19286
19287
19288
19289 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19290 #include <signal.h>
19291 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19292 #include <sys/types.h>
19293
19294 "
19295 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19296
19297 cat >>confdefs.h <<_ACEOF
19298 #define HAVE_SIGSET_T 1
19299 _ACEOF
19300
19301 gl_cv_type_sigset_t=yes
19302 else
19303 gl_cv_type_sigset_t=no
19304 fi
19305
19306 if test $gl_cv_type_sigset_t != yes; then
19307 HAVE_SIGSET_T=0
19308 fi
19309
19310
19311
19312 if test $ac_cv_header_sys_socket_h = no; then
19313 for ac_header in ws2tcpip.h
19314 do :
19315 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19316 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19317 cat >>confdefs.h <<_ACEOF
19318 #define HAVE_WS2TCPIP_H 1
19319 _ACEOF
19320
19321 fi
19322
19323 done
19324
19325 fi
19326
19327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19328 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19329 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19330 $as_echo_n "(cached) " >&6
19331 else
19332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19333 /* end confdefs.h. */
19334
19335 #include <stdbool.h>
19336 #ifndef bool
19337 "error: bool is not defined"
19338 #endif
19339 #ifndef false
19340 "error: false is not defined"
19341 #endif
19342 #if false
19343 "error: false is not 0"
19344 #endif
19345 #ifndef true
19346 "error: true is not defined"
19347 #endif
19348 #if true != 1
19349 "error: true is not 1"
19350 #endif
19351 #ifndef __bool_true_false_are_defined
19352 "error: __bool_true_false_are_defined is not defined"
19353 #endif
19354
19355 struct s { _Bool s: 1; _Bool t; } s;
19356
19357 char a[true == 1 ? 1 : -1];
19358 char b[false == 0 ? 1 : -1];
19359 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19360 char d[(bool) 0.5 == true ? 1 : -1];
19361 /* See body of main program for 'e'. */
19362 char f[(_Bool) 0.0 == false ? 1 : -1];
19363 char g[true];
19364 char h[sizeof (_Bool)];
19365 char i[sizeof s.t];
19366 enum { j = false, k = true, l = false * true, m = true * 256 };
19367 /* The following fails for
19368 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19369 _Bool n[m];
19370 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19371 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19372 /* Catch a bug in an HP-UX C compiler. See
19373 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19374 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19375 */
19376 _Bool q = true;
19377 _Bool *pq = &q;
19378
19379 int
19380 main ()
19381 {
19382
19383 bool e = &s;
19384 *pq |= q;
19385 *pq |= ! q;
19386 /* Refer to every declared value, to avoid compiler optimizations. */
19387 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19388 + !m + !n + !o + !p + !q + !pq);
19389
19390 ;
19391 return 0;
19392 }
19393 _ACEOF
19394 if ac_fn_c_try_compile "$LINENO"; then :
19395 ac_cv_header_stdbool_h=yes
19396 else
19397 ac_cv_header_stdbool_h=no
19398 fi
19399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19400 fi
19401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19402 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19403 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19404 if test "x$ac_cv_type__Bool" = x""yes; then :
19405
19406 cat >>confdefs.h <<_ACEOF
19407 #define HAVE__BOOL 1
19408 _ACEOF
19409
19410
19411 fi
19412
19413
19414
19415 REPLACE_NULL=0;
19416 HAVE_WCHAR_T=1;
19417
19418
19419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19420 $as_echo_n "checking for wchar_t... " >&6; }
19421 if test "${gt_cv_c_wchar_t+set}" = set; then :
19422 $as_echo_n "(cached) " >&6
19423 else
19424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19425 /* end confdefs.h. */
19426 #include <stddef.h>
19427 wchar_t foo = (wchar_t)'\0';
19428 int
19429 main ()
19430 {
19431
19432 ;
19433 return 0;
19434 }
19435 _ACEOF
19436 if ac_fn_c_try_compile "$LINENO"; then :
19437 gt_cv_c_wchar_t=yes
19438 else
19439 gt_cv_c_wchar_t=no
19440 fi
19441 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19442 fi
19443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19444 $as_echo "$gt_cv_c_wchar_t" >&6; }
19445 if test $gt_cv_c_wchar_t = yes; then
19446
19447 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19448
19449 fi
19450
19451
19452 GNULIB_DPRINTF=0;
19453 GNULIB_FCLOSE=0;
19454 GNULIB_FDOPEN=0;
19455 GNULIB_FFLUSH=0;
19456 GNULIB_FGETC=0;
19457 GNULIB_FGETS=0;
19458 GNULIB_FOPEN=0;
19459 GNULIB_FPRINTF=0;
19460 GNULIB_FPRINTF_POSIX=0;
19461 GNULIB_FPURGE=0;
19462 GNULIB_FPUTC=0;
19463 GNULIB_FPUTS=0;
19464 GNULIB_FREAD=0;
19465 GNULIB_FREOPEN=0;
19466 GNULIB_FSCANF=0;
19467 GNULIB_FSEEK=0;
19468 GNULIB_FSEEKO=0;
19469 GNULIB_FTELL=0;
19470 GNULIB_FTELLO=0;
19471 GNULIB_FWRITE=0;
19472 GNULIB_GETC=0;
19473 GNULIB_GETCHAR=0;
19474 GNULIB_GETDELIM=0;
19475 GNULIB_GETLINE=0;
19476 GNULIB_OBSTACK_PRINTF=0;
19477 GNULIB_OBSTACK_PRINTF_POSIX=0;
19478 GNULIB_PCLOSE=0;
19479 GNULIB_PERROR=0;
19480 GNULIB_POPEN=0;
19481 GNULIB_PRINTF=0;
19482 GNULIB_PRINTF_POSIX=0;
19483 GNULIB_PUTC=0;
19484 GNULIB_PUTCHAR=0;
19485 GNULIB_PUTS=0;
19486 GNULIB_REMOVE=0;
19487 GNULIB_RENAME=0;
19488 GNULIB_RENAMEAT=0;
19489 GNULIB_SCANF=0;
19490 GNULIB_SNPRINTF=0;
19491 GNULIB_SPRINTF_POSIX=0;
19492 GNULIB_STDIO_H_NONBLOCKING=0;
19493 GNULIB_STDIO_H_SIGPIPE=0;
19494 GNULIB_TMPFILE=0;
19495 GNULIB_VASPRINTF=0;
19496 GNULIB_VFSCANF=0;
19497 GNULIB_VSCANF=0;
19498 GNULIB_VDPRINTF=0;
19499 GNULIB_VFPRINTF=0;
19500 GNULIB_VFPRINTF_POSIX=0;
19501 GNULIB_VPRINTF=0;
19502 GNULIB_VPRINTF_POSIX=0;
19503 GNULIB_VSNPRINTF=0;
19504 GNULIB_VSPRINTF_POSIX=0;
19505 HAVE_DECL_FPURGE=1;
19506 HAVE_DECL_FSEEKO=1;
19507 HAVE_DECL_FTELLO=1;
19508 HAVE_DECL_GETDELIM=1;
19509 HAVE_DECL_GETLINE=1;
19510 HAVE_DECL_OBSTACK_PRINTF=1;
19511 HAVE_DECL_SNPRINTF=1;
19512 HAVE_DECL_VSNPRINTF=1;
19513 HAVE_DPRINTF=1;
19514 HAVE_FSEEKO=1;
19515 HAVE_FTELLO=1;
19516 HAVE_PCLOSE=1;
19517 HAVE_POPEN=1;
19518 HAVE_RENAMEAT=1;
19519 HAVE_VASPRINTF=1;
19520 HAVE_VDPRINTF=1;
19521 REPLACE_DPRINTF=0;
19522 REPLACE_FCLOSE=0;
19523 REPLACE_FDOPEN=0;
19524 REPLACE_FFLUSH=0;
19525 REPLACE_FOPEN=0;
19526 REPLACE_FPRINTF=0;
19527 REPLACE_FPURGE=0;
19528 REPLACE_FREOPEN=0;
19529 REPLACE_FSEEK=0;
19530 REPLACE_FSEEKO=0;
19531 REPLACE_FTELL=0;
19532 REPLACE_FTELLO=0;
19533 REPLACE_GETDELIM=0;
19534 REPLACE_GETLINE=0;
19535 REPLACE_OBSTACK_PRINTF=0;
19536 REPLACE_PERROR=0;
19537 REPLACE_POPEN=0;
19538 REPLACE_PRINTF=0;
19539 REPLACE_REMOVE=0;
19540 REPLACE_RENAME=0;
19541 REPLACE_RENAMEAT=0;
19542 REPLACE_SNPRINTF=0;
19543 REPLACE_SPRINTF=0;
19544 REPLACE_STDIO_READ_FUNCS=0;
19545 REPLACE_STDIO_WRITE_FUNCS=0;
19546 REPLACE_TMPFILE=0;
19547 REPLACE_VASPRINTF=0;
19548 REPLACE_VDPRINTF=0;
19549 REPLACE_VFPRINTF=0;
19550 REPLACE_VPRINTF=0;
19551 REPLACE_VSNPRINTF=0;
19552 REPLACE_VSPRINTF=0;
19553
19554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19555 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19556 if test "${ac_cv_struct_tm+set}" = set; then :
19557 $as_echo_n "(cached) " >&6
19558 else
19559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19560 /* end confdefs.h. */
19561 #include <sys/types.h>
19562 #include <time.h>
19563
19564 int
19565 main ()
19566 {
19567 struct tm tm;
19568 int *p = &tm.tm_sec;
19569 return !p;
19570 ;
19571 return 0;
19572 }
19573 _ACEOF
19574 if ac_fn_c_try_compile "$LINENO"; then :
19575 ac_cv_struct_tm=time.h
19576 else
19577 ac_cv_struct_tm=sys/time.h
19578 fi
19579 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19580 fi
19581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19582 $as_echo "$ac_cv_struct_tm" >&6; }
19583 if test $ac_cv_struct_tm = sys/time.h; then
19584
19585 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19586
19587 fi
19588
19589 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19590 #include <$ac_cv_struct_tm>
19591
19592 "
19593 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19594
19595 cat >>confdefs.h <<_ACEOF
19596 #define HAVE_STRUCT_TM_TM_ZONE 1
19597 _ACEOF
19598
19599
19600 fi
19601
19602 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19603
19604 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19605
19606 else
19607 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19608 "
19609 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19610 ac_have_decl=1
19611 else
19612 ac_have_decl=0
19613 fi
19614
19615 cat >>confdefs.h <<_ACEOF
19616 #define HAVE_DECL_TZNAME $ac_have_decl
19617 _ACEOF
19618
19619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19620 $as_echo_n "checking for tzname... " >&6; }
19621 if test "${ac_cv_var_tzname+set}" = set; then :
19622 $as_echo_n "(cached) " >&6
19623 else
19624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19625 /* end confdefs.h. */
19626 #include <time.h>
19627 #if !HAVE_DECL_TZNAME
19628 extern char *tzname[];
19629 #endif
19630
19631 int
19632 main ()
19633 {
19634 return tzname[0][0];
19635 ;
19636 return 0;
19637 }
19638 _ACEOF
19639 if ac_fn_c_try_link "$LINENO"; then :
19640 ac_cv_var_tzname=yes
19641 else
19642 ac_cv_var_tzname=no
19643 fi
19644 rm -f core conftest.err conftest.$ac_objext \
19645 conftest$ac_exeext conftest.$ac_ext
19646 fi
19647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19648 $as_echo "$ac_cv_var_tzname" >&6; }
19649 if test $ac_cv_var_tzname = yes; then
19650
19651 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19652
19653 fi
19654 fi
19655
19656
19657 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19658 "
19659 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19660
19661 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19662
19663 fi
19664
19665
19666
19667
19668 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19669 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19670 ac_have_decl=1
19671 else
19672 ac_have_decl=0
19673 fi
19674
19675 cat >>confdefs.h <<_ACEOF
19676 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19677 _ACEOF
19678
19679
19680
19681 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19682 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19683 ac_have_decl=1
19684 else
19685 ac_have_decl=0
19686 fi
19687
19688 cat >>confdefs.h <<_ACEOF
19689 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19690 _ACEOF
19691
19692
19693
19694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19695 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19696 if test "${ac_cv_header_stat_broken+set}" = set; then :
19697 $as_echo_n "(cached) " >&6
19698 else
19699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19700 /* end confdefs.h. */
19701 #include <sys/types.h>
19702 #include <sys/stat.h>
19703
19704 #if defined S_ISBLK && defined S_IFDIR
19705 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19706 #endif
19707
19708 #if defined S_ISBLK && defined S_IFCHR
19709 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19710 #endif
19711
19712 #if defined S_ISLNK && defined S_IFREG
19713 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19714 #endif
19715
19716 #if defined S_ISSOCK && defined S_IFREG
19717 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19718 #endif
19719
19720 _ACEOF
19721 if ac_fn_c_try_compile "$LINENO"; then :
19722 ac_cv_header_stat_broken=no
19723 else
19724 ac_cv_header_stat_broken=yes
19725 fi
19726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19727 fi
19728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19729 $as_echo "$ac_cv_header_stat_broken" >&6; }
19730 if test $ac_cv_header_stat_broken = yes; then
19731
19732 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19733
19734 fi
19735
19736
19737
19738 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19739 if test "x$ac_cv_type_mode_t" = x""yes; then :
19740
19741 else
19742
19743 cat >>confdefs.h <<_ACEOF
19744 #define mode_t int
19745 _ACEOF
19746
19747 fi
19748
19749
19750
19751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19752 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19753 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19754 $as_echo_n "(cached) " >&6
19755 else
19756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19757 /* end confdefs.h. */
19758 #include <time.h>
19759
19760 int
19761 main ()
19762 {
19763 static struct timespec x; x.tv_sec = x.tv_nsec;
19764 ;
19765 return 0;
19766 }
19767 _ACEOF
19768 if ac_fn_c_try_compile "$LINENO"; then :
19769 gl_cv_sys_struct_timespec_in_time_h=yes
19770 else
19771 gl_cv_sys_struct_timespec_in_time_h=no
19772 fi
19773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19774 fi
19775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19776 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19777
19778 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19779 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19780 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19781 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19782 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19783 else
19784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19785 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19786 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19787 $as_echo_n "(cached) " >&6
19788 else
19789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19790 /* end confdefs.h. */
19791 #include <sys/time.h>
19792
19793 int
19794 main ()
19795 {
19796 static struct timespec x; x.tv_sec = x.tv_nsec;
19797 ;
19798 return 0;
19799 }
19800 _ACEOF
19801 if ac_fn_c_try_compile "$LINENO"; then :
19802 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19803 else
19804 gl_cv_sys_struct_timespec_in_sys_time_h=no
19805 fi
19806 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19807 fi
19808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19809 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19810 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19811 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19812 else
19813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19814 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19815 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19816 $as_echo_n "(cached) " >&6
19817 else
19818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19819 /* end confdefs.h. */
19820 #include <pthread.h>
19821
19822 int
19823 main ()
19824 {
19825 static struct timespec x; x.tv_sec = x.tv_nsec;
19826 ;
19827 return 0;
19828 }
19829 _ACEOF
19830 if ac_fn_c_try_compile "$LINENO"; then :
19831 gl_cv_sys_struct_timespec_in_pthread_h=yes
19832 else
19833 gl_cv_sys_struct_timespec_in_pthread_h=no
19834 fi
19835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19836 fi
19837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19838 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19839 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19840 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19841 fi
19842 fi
19843 fi
19844
19845
19846
19847
19848
19849
19850
19851
19852
19853
19854
19855
19856
19857
19858
19859 if test $gl_cv_have_include_next = yes; then
19860 gl_cv_next_time_h='<'time.h'>'
19861 else
19862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19863 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19864 if test "${gl_cv_next_time_h+set}" = set; then :
19865 $as_echo_n "(cached) " >&6
19866 else
19867
19868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19869 /* end confdefs.h. */
19870 #include <time.h>
19871
19872 _ACEOF
19873 case "$host_os" in
19874 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19875 *) gl_absname_cpp="$ac_cpp" ;;
19876 esac
19877
19878 case "$host_os" in
19879 mingw*)
19880 gl_dirsep_regex='[/\\]'
19881 ;;
19882 *)
19883 gl_dirsep_regex='\/'
19884 ;;
19885 esac
19886 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19887
19888 gl_header_literal_regex=`echo 'time.h' \
19889 | sed -e "$gl_make_literal_regex_sed"`
19890 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19891 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19892 s|^/[^/]|//&|
19893 p
19894 q
19895 }'
19896 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19897 sed -n "$gl_absolute_header_sed"`'"'
19898
19899
19900 fi
19901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19902 $as_echo "$gl_cv_next_time_h" >&6; }
19903 fi
19904 NEXT_TIME_H=$gl_cv_next_time_h
19905
19906 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19907 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19908 gl_next_as_first_directive='<'time.h'>'
19909 else
19910 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19911 gl_next_as_first_directive=$gl_cv_next_time_h
19912 fi
19913 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19914
19915
19916
19917
19918
19919
19920
19921
19922
19923
19924
19925
19926
19927
19928
19929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
19930 $as_echo_n "checking whether the utimes function works... " >&6; }
19931 if test "${gl_cv_func_working_utimes+set}" = set; then :
19932 $as_echo_n "(cached) " >&6
19933 else
19934
19935 if test "$cross_compiling" = yes; then :
19936 gl_cv_func_working_utimes=no
19937 else
19938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19939 /* end confdefs.h. */
19940
19941 #include <sys/types.h>
19942 #include <sys/stat.h>
19943 #include <fcntl.h>
19944 #include <sys/time.h>
19945 #include <time.h>
19946 #include <unistd.h>
19947 #include <stdlib.h>
19948 #include <stdio.h>
19949 #include <utime.h>
19950
19951 static int
19952 inorder (time_t a, time_t b, time_t c)
19953 {
19954 return a <= b && b <= c;
19955 }
19956
19957 int
19958 main ()
19959 {
19960 int result = 0;
19961 char const *file = "conftest.utimes";
19962 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
19963
19964 /* Test whether utimes() essentially works. */
19965 {
19966 struct stat sbuf;
19967 FILE *f = fopen (file, "w");
19968 if (f == NULL)
19969 result |= 1;
19970 else if (fclose (f) != 0)
19971 result |= 1;
19972 else if (utimes (file, timeval) != 0)
19973 result |= 2;
19974 else if (lstat (file, &sbuf) != 0)
19975 result |= 1;
19976 else if (!(sbuf.st_atime == timeval[0].tv_sec
19977 && sbuf.st_mtime == timeval[1].tv_sec))
19978 result |= 4;
19979 if (unlink (file) != 0)
19980 result |= 1;
19981 }
19982
19983 /* Test whether utimes() with a NULL argument sets the file's timestamp
19984 to the current time. Use 'fstat' as well as 'time' to
19985 determine the "current" time, to accommodate NFS file systems
19986 if there is a time skew between the host and the NFS server. */
19987 {
19988 int fd = open (file, O_WRONLY|O_CREAT, 0644);
19989 if (fd < 0)
19990 result |= 1;
19991 else
19992 {
19993 time_t t0, t2;
19994 struct stat st0, st1, st2;
19995 if (time (&t0) == (time_t) -1)
19996 result |= 1;
19997 else if (fstat (fd, &st0) != 0)
19998 result |= 1;
19999 else if (utimes (file, timeval) != 0)
20000 result |= 2;
20001 else if (utimes (file, NULL) != 0)
20002 result |= 8;
20003 else if (fstat (fd, &st1) != 0)
20004 result |= 1;
20005 else if (write (fd, "\n", 1) != 1)
20006 result |= 1;
20007 else if (fstat (fd, &st2) != 0)
20008 result |= 1;
20009 else if (time (&t2) == (time_t) -1)
20010 result |= 1;
20011 else
20012 {
20013 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
20014 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
20015 if (! (st1.st_atime == st1.st_mtime))
20016 result |= 16;
20017 if (! (m_ok_POSIX || m_ok_NFS))
20018 result |= 32;
20019 }
20020 if (close (fd) != 0)
20021 result |= 1;
20022 }
20023 if (unlink (file) != 0)
20024 result |= 1;
20025 }
20026
20027 /* Test whether utimes() with a NULL argument works on read-only files. */
20028 {
20029 int fd = open (file, O_WRONLY|O_CREAT, 0444);
20030 if (fd < 0)
20031 result |= 1;
20032 else if (close (fd) != 0)
20033 result |= 1;
20034 else if (utimes (file, NULL) != 0)
20035 result |= 64;
20036 if (unlink (file) != 0)
20037 result |= 1;
20038 }
20039
20040 return result;
20041 }
20042
20043 _ACEOF
20044 if ac_fn_c_try_run "$LINENO"; then :
20045 gl_cv_func_working_utimes=yes
20046 else
20047 gl_cv_func_working_utimes=no
20048 fi
20049 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20050 conftest.$ac_objext conftest.beam conftest.$ac_ext
20051 fi
20052
20053 fi
20054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
20055 $as_echo "$gl_cv_func_working_utimes" >&6; }
20056
20057 if test $gl_cv_func_working_utimes = yes; then
20058
20059 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
20060
20061 fi
20062
20063
20064
20065
20066
20067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
20068 $as_echo_n "checking for struct utimbuf... " >&6; }
20069 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
20070 $as_echo_n "(cached) " >&6
20071 else
20072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20073 /* end confdefs.h. */
20074 #if HAVE_SYS_TIME_H
20075 #include <sys/time.h>
20076 #endif
20077 #include <time.h>
20078 #ifdef HAVE_UTIME_H
20079 #include <utime.h>
20080 #endif
20081
20082 int
20083 main ()
20084 {
20085 static struct utimbuf x; x.actime = x.modtime;
20086 ;
20087 return 0;
20088 }
20089 _ACEOF
20090 if ac_fn_c_try_compile "$LINENO"; then :
20091 gl_cv_sys_struct_utimbuf=yes
20092 else
20093 gl_cv_sys_struct_utimbuf=no
20094 fi
20095 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20096 fi
20097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
20098 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
20099
20100 if test $gl_cv_sys_struct_utimbuf = yes; then
20101
20102 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
20103
20104 fi
20105
20106
20107
20108
20109
20110
20111
20112
20113
20114
20115
20116
20117 if false; then
20118 GL_COND_LIBTOOL_TRUE=
20119 GL_COND_LIBTOOL_FALSE='#'
20120 else
20121 GL_COND_LIBTOOL_TRUE='#'
20122 GL_COND_LIBTOOL_FALSE=
20123 fi
20124
20125 gl_cond_libtool=false
20126 gl_libdeps=
20127 gl_ltlibdeps=
20128 gl_m4_base='m4'
20129
20130
20131
20132
20133
20134
20135
20136
20137
20138 gl_source_base='lib'
20139
20140
20141 if test $ac_cv_func_alloca_works = no; then
20142 :
20143 fi
20144
20145 # Define an additional variable used in the Makefile substitution.
20146 if test $ac_cv_working_alloca_h = yes; then
20147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20148 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20149 if test "${gl_cv_rpl_alloca+set}" = set; then :
20150 $as_echo_n "(cached) " >&6
20151 else
20152
20153 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20154 /* end confdefs.h. */
20155
20156 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20157 Need own alloca
20158 #endif
20159
20160 _ACEOF
20161 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20162 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20163 gl_cv_rpl_alloca=yes
20164 else
20165 gl_cv_rpl_alloca=no
20166 fi
20167 rm -f conftest*
20168
20169
20170 fi
20171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20172 $as_echo "$gl_cv_rpl_alloca" >&6; }
20173 if test $gl_cv_rpl_alloca = yes; then
20174
20175 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20176
20177 ALLOCA_H=alloca.h
20178 else
20179 ALLOCA_H=
20180 fi
20181 else
20182 ALLOCA_H=alloca.h
20183 fi
20184
20185 if test -n "$ALLOCA_H"; then
20186 GL_GENERATE_ALLOCA_H_TRUE=
20187 GL_GENERATE_ALLOCA_H_FALSE='#'
20188 else
20189 GL_GENERATE_ALLOCA_H_TRUE='#'
20190 GL_GENERATE_ALLOCA_H_FALSE=
20191 fi
20192
20193
20194
20195
20196
20197
20198 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20199 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20200
20201 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20202 # programs in the package would end up linked with that potentially-shared
20203 # library, inducing unnecessary run-time overhead.
20204 LIB_CLOCK_GETTIME=
20205
20206 gl_saved_libs=$LIBS
20207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20208 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20209 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20210 $as_echo_n "(cached) " >&6
20211 else
20212 ac_func_search_save_LIBS=$LIBS
20213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20214 /* end confdefs.h. */
20215
20216 /* Override any GCC internal prototype to avoid an error.
20217 Use char because int might match the return type of a GCC
20218 builtin and then its argument prototype would still apply. */
20219 #ifdef __cplusplus
20220 extern "C"
20221 #endif
20222 char clock_gettime ();
20223 int
20224 main ()
20225 {
20226 return clock_gettime ();
20227 ;
20228 return 0;
20229 }
20230 _ACEOF
20231 for ac_lib in '' rt posix4; do
20232 if test -z "$ac_lib"; then
20233 ac_res="none required"
20234 else
20235 ac_res=-l$ac_lib
20236 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20237 fi
20238 if ac_fn_c_try_link "$LINENO"; then :
20239 ac_cv_search_clock_gettime=$ac_res
20240 fi
20241 rm -f core conftest.err conftest.$ac_objext \
20242 conftest$ac_exeext
20243 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20244 break
20245 fi
20246 done
20247 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20248
20249 else
20250 ac_cv_search_clock_gettime=no
20251 fi
20252 rm conftest.$ac_ext
20253 LIBS=$ac_func_search_save_LIBS
20254 fi
20255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20256 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20257 ac_res=$ac_cv_search_clock_gettime
20258 if test "$ac_res" != no; then :
20259 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20260 test "$ac_cv_search_clock_gettime" = "none required" ||
20261 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20262 fi
20263
20264 for ac_func in clock_gettime clock_settime
20265 do :
20266 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20267 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20268 eval as_val=\$$as_ac_var
20269 if test "x$as_val" = x""yes; then :
20270 cat >>confdefs.h <<_ACEOF
20271 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20272 _ACEOF
20273
20274 fi
20275 done
20276
20277 LIBS=$gl_saved_libs
20278
20279
20280 :
20281
20282
20283
20284 cat >>confdefs.h <<_ACEOF
20285 #define GNULIB_CLOSE_STREAM 1
20286 _ACEOF
20287
20288
20289
20290
20291
20292 :
20293
20294
20295
20296
20297 :
20298
20299
20300
20301
20302
20303
20304
20305
20306
20307
20308
20309
20310
20311
20312
20313 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20314
20315
20316 if test $HAVE_DUP2 = 1; then
20317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20318 $as_echo_n "checking whether dup2 works... " >&6; }
20319 if test "${gl_cv_func_dup2_works+set}" = set; then :
20320 $as_echo_n "(cached) " >&6
20321 else
20322 if test "$cross_compiling" = yes; then :
20323 case "$host_os" in
20324 mingw*) # on this platform, dup2 always returns 0 for success
20325 gl_cv_func_dup2_works="guessing no" ;;
20326 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20327 gl_cv_func_dup2_works="guessing no" ;;
20328 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20329 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20330 gl_cv_func_dup2_works="guessing no" ;;
20331 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20332 gl_cv_func_dup2_works="guessing no" ;;
20333 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20334 gl_cv_func_dup2_works="guessing no" ;;
20335 *) gl_cv_func_dup2_works="guessing yes" ;;
20336 esac
20337 else
20338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20339 /* end confdefs.h. */
20340
20341 #include <unistd.h>
20342 #include <fcntl.h>
20343 #include <errno.h>
20344 int
20345 main ()
20346 {
20347 int result = 0;
20348 #ifdef FD_CLOEXEC
20349 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20350 result |= 1;
20351 #endif
20352 if (dup2 (1, 1) == 0)
20353 result |= 2;
20354 #ifdef FD_CLOEXEC
20355 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20356 result |= 4;
20357 #endif
20358 close (0);
20359 if (dup2 (0, 0) != -1)
20360 result |= 8;
20361 /* Many gnulib modules require POSIX conformance of EBADF. */
20362 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20363 result |= 16;
20364 return result;
20365
20366 ;
20367 return 0;
20368 }
20369
20370 _ACEOF
20371 if ac_fn_c_try_run "$LINENO"; then :
20372 gl_cv_func_dup2_works=yes
20373 else
20374 gl_cv_func_dup2_works=no
20375 fi
20376 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20377 conftest.$ac_objext conftest.beam conftest.$ac_ext
20378 fi
20379
20380
20381 fi
20382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20383 $as_echo "$gl_cv_func_dup2_works" >&6; }
20384 case "$gl_cv_func_dup2_works" in
20385 *yes) ;;
20386 *)
20387 REPLACE_DUP2=1
20388 ;;
20389 esac
20390 fi
20391
20392
20393 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20394
20395
20396
20397
20398
20399
20400
20401
20402 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20403
20404
20405 fi
20406
20407
20408
20409
20410
20411 GNULIB_DUP2=1
20412
20413
20414
20415
20416
20417
20418
20419
20420
20421
20422
20423 GNULIB_ENVIRON=1
20424
20425
20426
20427
20428
20429
20430
20431
20432 LIB_EXECINFO=''
20433 EXECINFO_H='execinfo.h'
20434
20435 if test $ac_cv_header_execinfo_h = yes; then
20436 gl_saved_libs=$LIBS
20437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20438 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20439 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20440 $as_echo_n "(cached) " >&6
20441 else
20442 ac_func_search_save_LIBS=$LIBS
20443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20444 /* end confdefs.h. */
20445
20446 /* Override any GCC internal prototype to avoid an error.
20447 Use char because int might match the return type of a GCC
20448 builtin and then its argument prototype would still apply. */
20449 #ifdef __cplusplus
20450 extern "C"
20451 #endif
20452 char backtrace_symbols_fd ();
20453 int
20454 main ()
20455 {
20456 return backtrace_symbols_fd ();
20457 ;
20458 return 0;
20459 }
20460 _ACEOF
20461 for ac_lib in '' execinfo; do
20462 if test -z "$ac_lib"; then
20463 ac_res="none required"
20464 else
20465 ac_res=-l$ac_lib
20466 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20467 fi
20468 if ac_fn_c_try_link "$LINENO"; then :
20469 ac_cv_search_backtrace_symbols_fd=$ac_res
20470 fi
20471 rm -f core conftest.err conftest.$ac_objext \
20472 conftest$ac_exeext
20473 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20474 break
20475 fi
20476 done
20477 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20478
20479 else
20480 ac_cv_search_backtrace_symbols_fd=no
20481 fi
20482 rm conftest.$ac_ext
20483 LIBS=$ac_func_search_save_LIBS
20484 fi
20485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20486 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20487 ac_res=$ac_cv_search_backtrace_symbols_fd
20488 if test "$ac_res" != no; then :
20489 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20490 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20491 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20492 fi
20493
20494 LIBS=$gl_saved_libs
20495 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20496 fi
20497
20498 if test -n "$EXECINFO_H"; then
20499
20500
20501
20502
20503
20504
20505
20506
20507 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20508
20509 fi
20510
20511
20512
20513 if test -n "$EXECINFO_H"; then
20514 GL_GENERATE_EXECINFO_H_TRUE=
20515 GL_GENERATE_EXECINFO_H_FALSE='#'
20516 else
20517 GL_GENERATE_EXECINFO_H_TRUE='#'
20518 GL_GENERATE_EXECINFO_H_FALSE=
20519 fi
20520
20521
20522
20523
20524
20525
20526
20527
20528
20529
20530 fp_headers='
20531 # include <stdio.h>
20532 # if HAVE_STDIO_EXT_H
20533 # include <stdio_ext.h>
20534 # endif
20535 '
20536 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
20537 "
20538 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
20539 ac_have_decl=1
20540 else
20541 ac_have_decl=0
20542 fi
20543
20544 cat >>confdefs.h <<_ACEOF
20545 #define HAVE_DECL___FPENDING $ac_have_decl
20546 _ACEOF
20547
20548
20549 if test $ac_cv_func___fpending = no; then
20550
20551
20552
20553
20554
20555
20556
20557
20558 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
20559
20560
20561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
20562 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
20563 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
20564 $as_echo_n "(cached) " >&6
20565 else
20566
20567 for ac_expr in \
20568 \
20569 '# glibc2' \
20570 'fp->_IO_write_ptr - fp->_IO_write_base' \
20571 \
20572 '# traditional Unix' \
20573 'fp->_ptr - fp->_base' \
20574 \
20575 '# BSD' \
20576 'fp->_p - fp->_bf._base' \
20577 \
20578 '# SCO, Unixware' \
20579 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
20580 \
20581 '# QNX' \
20582 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
20583 \
20584 '# old glibc?' \
20585 'fp->__bufp - fp->__buffer' \
20586 \
20587 '# old glibc iostream?' \
20588 'fp->_pptr - fp->_pbase' \
20589 \
20590 '# emx+gcc' \
20591 'fp->_ptr - fp->_buffer' \
20592 \
20593 '# Minix' \
20594 'fp->_ptr - fp->_buf' \
20595 \
20596 '# Plan9' \
20597 'fp->wp - fp->buf' \
20598 \
20599 '# VMS' \
20600 '(*fp)->_ptr - (*fp)->_base' \
20601 \
20602 '# e.g., DGUX R4.11; the info is not available' \
20603 1 \
20604 ; do
20605
20606 # Skip each embedded comment.
20607 case "$ac_expr" in '#'*) continue;; esac
20608
20609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20610 /* end confdefs.h. */
20611 #include <stdio.h>
20612 int
20613 main ()
20614 {
20615 FILE *fp = stdin; (void) ($ac_expr);
20616 ;
20617 return 0;
20618 }
20619 _ACEOF
20620 if ac_fn_c_try_compile "$LINENO"; then :
20621 fp_done=yes
20622
20623 fi
20624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20625 test "$fp_done" = yes && break
20626 done
20627
20628 ac_cv_sys_pending_output_n_bytes=$ac_expr
20629
20630
20631 fi
20632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
20633 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
20634
20635 cat >>confdefs.h <<_ACEOF
20636 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
20637 _ACEOF
20638
20639
20640 fi
20641
20642
20643 # Persuade glibc <stdlib.h> to declare getloadavg().
20644
20645
20646 gl_save_LIBS=$LIBS
20647
20648 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20649 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20650 HAVE_GETLOADAVG=1
20651 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20652 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20653
20654 else
20655 gl_func_getloadavg_done=no
20656
20657 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20658 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20659 # to get the right answer into the cache.
20660 # For kstat on solaris, we need to test for libelf and libkvm to force the
20661 # definition of SVR4 below.
20662 if test $gl_func_getloadavg_done = no; then
20663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20664 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20665 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20666 $as_echo_n "(cached) " >&6
20667 else
20668 ac_check_lib_save_LIBS=$LIBS
20669 LIBS="-lelf $LIBS"
20670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20671 /* end confdefs.h. */
20672
20673 /* Override any GCC internal prototype to avoid an error.
20674 Use char because int might match the return type of a GCC
20675 builtin and then its argument prototype would still apply. */
20676 #ifdef __cplusplus
20677 extern "C"
20678 #endif
20679 char elf_begin ();
20680 int
20681 main ()
20682 {
20683 return elf_begin ();
20684 ;
20685 return 0;
20686 }
20687 _ACEOF
20688 if ac_fn_c_try_link "$LINENO"; then :
20689 ac_cv_lib_elf_elf_begin=yes
20690 else
20691 ac_cv_lib_elf_elf_begin=no
20692 fi
20693 rm -f core conftest.err conftest.$ac_objext \
20694 conftest$ac_exeext conftest.$ac_ext
20695 LIBS=$ac_check_lib_save_LIBS
20696 fi
20697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20698 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20699 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20700 LIBS="-lelf $LIBS"
20701 fi
20702
20703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20704 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20705 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20706 $as_echo_n "(cached) " >&6
20707 else
20708 ac_check_lib_save_LIBS=$LIBS
20709 LIBS="-lkvm $LIBS"
20710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20711 /* end confdefs.h. */
20712
20713 /* Override any GCC internal prototype to avoid an error.
20714 Use char because int might match the return type of a GCC
20715 builtin and then its argument prototype would still apply. */
20716 #ifdef __cplusplus
20717 extern "C"
20718 #endif
20719 char kvm_open ();
20720 int
20721 main ()
20722 {
20723 return kvm_open ();
20724 ;
20725 return 0;
20726 }
20727 _ACEOF
20728 if ac_fn_c_try_link "$LINENO"; then :
20729 ac_cv_lib_kvm_kvm_open=yes
20730 else
20731 ac_cv_lib_kvm_kvm_open=no
20732 fi
20733 rm -f core conftest.err conftest.$ac_objext \
20734 conftest$ac_exeext conftest.$ac_ext
20735 LIBS=$ac_check_lib_save_LIBS
20736 fi
20737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20738 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20739 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20740 LIBS="-lkvm $LIBS"
20741 fi
20742
20743 # Check for the 4.4BSD definition of getloadavg.
20744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20745 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20746 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20747 $as_echo_n "(cached) " >&6
20748 else
20749 ac_check_lib_save_LIBS=$LIBS
20750 LIBS="-lutil $LIBS"
20751 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20752 /* end confdefs.h. */
20753
20754 /* Override any GCC internal prototype to avoid an error.
20755 Use char because int might match the return type of a GCC
20756 builtin and then its argument prototype would still apply. */
20757 #ifdef __cplusplus
20758 extern "C"
20759 #endif
20760 char getloadavg ();
20761 int
20762 main ()
20763 {
20764 return getloadavg ();
20765 ;
20766 return 0;
20767 }
20768 _ACEOF
20769 if ac_fn_c_try_link "$LINENO"; then :
20770 ac_cv_lib_util_getloadavg=yes
20771 else
20772 ac_cv_lib_util_getloadavg=no
20773 fi
20774 rm -f core conftest.err conftest.$ac_objext \
20775 conftest$ac_exeext conftest.$ac_ext
20776 LIBS=$ac_check_lib_save_LIBS
20777 fi
20778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20779 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20780 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20781 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20782 fi
20783
20784 fi
20785
20786 if test $gl_func_getloadavg_done = no; then
20787 # There is a commonly available library for RS/6000 AIX.
20788 # Since it is not a standard part of AIX, it might be installed locally.
20789 gl_getloadavg_LIBS=$LIBS
20790 LIBS="-L/usr/local/lib $LIBS"
20791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20792 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20793 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20794 $as_echo_n "(cached) " >&6
20795 else
20796 ac_check_lib_save_LIBS=$LIBS
20797 LIBS="-lgetloadavg $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_getloadavg_getloadavg=yes
20818 else
20819 ac_cv_lib_getloadavg_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_getloadavg_getloadavg" >&5
20826 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20827 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20828 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20829 else
20830 LIBS=$gl_getloadavg_LIBS
20831 fi
20832
20833 fi
20834
20835 # Set up the replacement function if necessary.
20836 if test $gl_func_getloadavg_done = no; then
20837 HAVE_GETLOADAVG=0
20838
20839 # Solaris has libkstat which does not require root.
20840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20841 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20842 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20843 $as_echo_n "(cached) " >&6
20844 else
20845 ac_check_lib_save_LIBS=$LIBS
20846 LIBS="-lkstat $LIBS"
20847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20848 /* end confdefs.h. */
20849
20850 /* Override any GCC internal prototype to avoid an error.
20851 Use char because int might match the return type of a GCC
20852 builtin and then its argument prototype would still apply. */
20853 #ifdef __cplusplus
20854 extern "C"
20855 #endif
20856 char kstat_open ();
20857 int
20858 main ()
20859 {
20860 return kstat_open ();
20861 ;
20862 return 0;
20863 }
20864 _ACEOF
20865 if ac_fn_c_try_link "$LINENO"; then :
20866 ac_cv_lib_kstat_kstat_open=yes
20867 else
20868 ac_cv_lib_kstat_kstat_open=no
20869 fi
20870 rm -f core conftest.err conftest.$ac_objext \
20871 conftest$ac_exeext conftest.$ac_ext
20872 LIBS=$ac_check_lib_save_LIBS
20873 fi
20874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20875 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20876 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20877 cat >>confdefs.h <<_ACEOF
20878 #define HAVE_LIBKSTAT 1
20879 _ACEOF
20880
20881 LIBS="-lkstat $LIBS"
20882
20883 fi
20884
20885 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20886
20887 # AIX has libperfstat which does not require root
20888 if test $gl_func_getloadavg_done = no; then
20889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20890 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20891 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20892 $as_echo_n "(cached) " >&6
20893 else
20894 ac_check_lib_save_LIBS=$LIBS
20895 LIBS="-lperfstat $LIBS"
20896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20897 /* end confdefs.h. */
20898
20899 /* Override any GCC internal prototype to avoid an error.
20900 Use char because int might match the return type of a GCC
20901 builtin and then its argument prototype would still apply. */
20902 #ifdef __cplusplus
20903 extern "C"
20904 #endif
20905 char perfstat_cpu_total ();
20906 int
20907 main ()
20908 {
20909 return perfstat_cpu_total ();
20910 ;
20911 return 0;
20912 }
20913 _ACEOF
20914 if ac_fn_c_try_link "$LINENO"; then :
20915 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20916 else
20917 ac_cv_lib_perfstat_perfstat_cpu_total=no
20918 fi
20919 rm -f core conftest.err conftest.$ac_objext \
20920 conftest$ac_exeext conftest.$ac_ext
20921 LIBS=$ac_check_lib_save_LIBS
20922 fi
20923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20924 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20925 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20926 cat >>confdefs.h <<_ACEOF
20927 #define HAVE_LIBPERFSTAT 1
20928 _ACEOF
20929
20930 LIBS="-lperfstat $LIBS"
20931
20932 fi
20933
20934 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20935 fi
20936
20937 if test $gl_func_getloadavg_done = no; then
20938 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20939 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20940 gl_func_getloadavg_done=yes
20941
20942 $as_echo "#define DGUX 1" >>confdefs.h
20943
20944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20945 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20946 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20947 $as_echo_n "(cached) " >&6
20948 else
20949 ac_check_lib_save_LIBS=$LIBS
20950 LIBS="-ldgc $LIBS"
20951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20952 /* end confdefs.h. */
20953
20954 /* Override any GCC internal prototype to avoid an error.
20955 Use char because int might match the return type of a GCC
20956 builtin and then its argument prototype would still apply. */
20957 #ifdef __cplusplus
20958 extern "C"
20959 #endif
20960 char dg_sys_info ();
20961 int
20962 main ()
20963 {
20964 return dg_sys_info ();
20965 ;
20966 return 0;
20967 }
20968 _ACEOF
20969 if ac_fn_c_try_link "$LINENO"; then :
20970 ac_cv_lib_dgc_dg_sys_info=yes
20971 else
20972 ac_cv_lib_dgc_dg_sys_info=no
20973 fi
20974 rm -f core conftest.err conftest.$ac_objext \
20975 conftest$ac_exeext conftest.$ac_ext
20976 LIBS=$ac_check_lib_save_LIBS
20977 fi
20978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
20979 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
20980 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
20981 cat >>confdefs.h <<_ACEOF
20982 #define HAVE_LIBDGC 1
20983 _ACEOF
20984
20985 LIBS="-ldgc $LIBS"
20986
20987 fi
20988
20989 fi
20990
20991
20992 fi
20993 fi
20994 fi
20995
20996
20997 if test "x$gl_save_LIBS" = x; then
20998 GETLOADAVG_LIBS=$LIBS
20999 else
21000 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
21001 fi
21002 LIBS=$gl_save_LIBS
21003
21004
21005 # Test whether the system declares getloadavg. Solaris has the function
21006 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
21007 for ac_header in sys/loadavg.h
21008 do :
21009 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
21010 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
21011 cat >>confdefs.h <<_ACEOF
21012 #define HAVE_SYS_LOADAVG_H 1
21013 _ACEOF
21014
21015 fi
21016
21017 done
21018
21019 if test $ac_cv_header_sys_loadavg_h = yes; then
21020 HAVE_SYS_LOADAVG_H=1
21021 else
21022 HAVE_SYS_LOADAVG_H=0
21023 fi
21024 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
21025 # include <sys/loadavg.h>
21026 #endif
21027 #include <stdlib.h>
21028 "
21029 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
21030
21031 else
21032 HAVE_DECL_GETLOADAVG=0
21033 fi
21034
21035
21036 if test $HAVE_GETLOADAVG = 0; then
21037
21038
21039
21040
21041
21042
21043
21044
21045 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
21046
21047
21048 # Figure out what our getloadavg.c needs.
21049
21050
21051
21052 # On HPUX9, an unprivileged user can get load averages this way.
21053 if test $gl_func_getloadavg_done = no; then
21054 for ac_func in pstat_getdynamic
21055 do :
21056 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
21057 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
21058 cat >>confdefs.h <<_ACEOF
21059 #define HAVE_PSTAT_GETDYNAMIC 1
21060 _ACEOF
21061 gl_func_getloadavg_done=yes
21062 fi
21063 done
21064
21065 fi
21066
21067 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
21068 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
21069 # Irix 4.0.5F has the header but not the library.
21070 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
21071 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
21072 gl_func_getloadavg_done=yes
21073
21074 $as_echo "#define SVR4 1" >>confdefs.h
21075
21076 fi
21077
21078 if test $gl_func_getloadavg_done = no; then
21079 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
21080 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
21081 gl_func_getloadavg_done=yes
21082
21083 $as_echo "#define UMAX 1" >>confdefs.h
21084
21085
21086 $as_echo "#define UMAX4_3 1" >>confdefs.h
21087
21088 fi
21089
21090
21091 fi
21092
21093 if test $gl_func_getloadavg_done = no; then
21094 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
21095 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
21096 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
21097
21098 fi
21099
21100
21101 fi
21102
21103 if test $gl_func_getloadavg_done = no; then
21104 for ac_header in mach/mach.h
21105 do :
21106 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
21107 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
21108 cat >>confdefs.h <<_ACEOF
21109 #define HAVE_MACH_MACH_H 1
21110 _ACEOF
21111
21112 fi
21113
21114 done
21115
21116 fi
21117
21118 for ac_header in nlist.h
21119 do :
21120 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
21121 if test "x$ac_cv_header_nlist_h" = x""yes; then :
21122 cat >>confdefs.h <<_ACEOF
21123 #define HAVE_NLIST_H 1
21124 _ACEOF
21125 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
21126 "
21127 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
21128
21129 cat >>confdefs.h <<_ACEOF
21130 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
21131 _ACEOF
21132
21133
21134 fi
21135
21136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21137 /* end confdefs.h. */
21138 #include <nlist.h>
21139 int
21140 main ()
21141 {
21142 struct nlist x;
21143 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
21144 x.n_un.n_name = "";
21145 #else
21146 x.n_name = "";
21147 #endif
21148 ;
21149 return 0;
21150 }
21151 _ACEOF
21152 if ac_fn_c_try_link "$LINENO"; then :
21153
21154 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
21155
21156 fi
21157 rm -f core conftest.err conftest.$ac_objext \
21158 conftest$ac_exeext conftest.$ac_ext
21159
21160 fi
21161
21162 done
21163
21164 fi
21165
21166
21167
21168
21169
21170 GNULIB_GETLOADAVG=1
21171
21172
21173
21174
21175
21176
21177
21178
21179
21180
21181 if test $REPLACE_GETOPT = 1; then
21182
21183
21184
21185
21186
21187
21188
21189
21190 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21191
21192
21193
21194
21195
21196
21197
21198
21199
21200 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21201
21202
21203
21204
21205 GNULIB_GL_UNISTD_H_GETOPT=1
21206 fi
21207
21208
21209
21210
21211
21212
21213
21214 REPLACE_GETOPT=0
21215 if test -n "$gl_replace_getopt"; then
21216 REPLACE_GETOPT=1
21217 fi
21218
21219 if test $REPLACE_GETOPT = 1; then
21220
21221 GETOPT_H=getopt.h
21222
21223 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
21224
21225
21226
21227 fi
21228
21229 if test $REPLACE_GETOPT = 1; then
21230
21231
21232
21233
21234
21235
21236
21237
21238 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21239
21240
21241
21242
21243
21244
21245
21246
21247
21248 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21249
21250
21251
21252
21253 GNULIB_GL_UNISTD_H_GETOPT=1
21254 fi
21255
21256
21257
21258
21259
21260
21261
21262
21263
21264
21265
21266
21267 gl_gettimeofday_timezone=void
21268 if test $ac_cv_func_gettimeofday != yes; then
21269 HAVE_GETTIMEOFDAY=0
21270 else
21271
21272
21273
21274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21275 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21276 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21277 $as_echo_n "(cached) " >&6
21278 else
21279 if test "$cross_compiling" = yes; then :
21280 # When cross-compiling:
21281 case "$host_os" in
21282 # Guess all is fine on glibc systems.
21283 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21284 # If we don't know, assume the worst.
21285 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21286 esac
21287
21288 else
21289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21290 /* end confdefs.h. */
21291 #include <string.h>
21292 #include <sys/time.h>
21293 #include <time.h>
21294 #include <stdlib.h>
21295
21296 int
21297 main ()
21298 {
21299
21300 time_t t = 0;
21301 struct tm *lt;
21302 struct tm saved_lt;
21303 struct timeval tv;
21304 lt = localtime (&t);
21305 saved_lt = *lt;
21306 gettimeofday (&tv, NULL);
21307 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21308
21309 ;
21310 return 0;
21311 }
21312 _ACEOF
21313 if ac_fn_c_try_run "$LINENO"; then :
21314 gl_cv_func_gettimeofday_clobber=no
21315 else
21316 gl_cv_func_gettimeofday_clobber=yes
21317 fi
21318 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21319 conftest.$ac_objext conftest.beam conftest.$ac_ext
21320 fi
21321
21322 fi
21323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21324 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21325
21326 case "$gl_cv_func_gettimeofday_clobber" in
21327 *yes)
21328 REPLACE_GETTIMEOFDAY=1
21329
21330
21331 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21332
21333
21334 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21335
21336
21337
21338 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21339
21340 ;;
21341 esac
21342
21343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21344 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21345 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21346 $as_echo_n "(cached) " >&6
21347 else
21348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21349 /* end confdefs.h. */
21350 #include <sys/time.h>
21351 struct timeval c;
21352 int gettimeofday (struct timeval *restrict, void *restrict);
21353
21354 int
21355 main ()
21356 {
21357 /* glibc uses struct timezone * rather than the POSIX void *
21358 if _GNU_SOURCE is defined. However, since the only portable
21359 use of gettimeofday uses NULL as the second parameter, and
21360 since the glibc definition is actually more typesafe, it is
21361 not worth wrapping this to get a compliant signature. */
21362 int (*f) (struct timeval *restrict, void *restrict)
21363 = gettimeofday;
21364 int x = f (&c, 0);
21365 return !(x | c.tv_sec | c.tv_usec);
21366
21367 ;
21368 return 0;
21369 }
21370 _ACEOF
21371 if ac_fn_c_try_compile "$LINENO"; then :
21372 gl_cv_func_gettimeofday_posix_signature=yes
21373 else
21374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21375 /* end confdefs.h. */
21376 #include <sys/time.h>
21377 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21378
21379 int
21380 main ()
21381 {
21382
21383 ;
21384 return 0;
21385 }
21386 _ACEOF
21387 if ac_fn_c_try_compile "$LINENO"; then :
21388 gl_cv_func_gettimeofday_posix_signature=almost
21389 else
21390 gl_cv_func_gettimeofday_posix_signature=no
21391 fi
21392 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21393 fi
21394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21395 fi
21396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21397 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21398 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21399 gl_gettimeofday_timezone='struct timezone'
21400 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21401 REPLACE_GETTIMEOFDAY=1
21402 fi
21403 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21404 REPLACE_GETTIMEOFDAY=1
21405 fi
21406
21407 fi
21408
21409 cat >>confdefs.h <<_ACEOF
21410 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21411 _ACEOF
21412
21413
21414 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21415
21416
21417
21418
21419
21420
21421
21422
21423 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21424
21425
21426 for ac_header in sys/timeb.h
21427 do :
21428 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21429 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21430 cat >>confdefs.h <<_ACEOF
21431 #define HAVE_SYS_TIMEB_H 1
21432 _ACEOF
21433
21434 fi
21435
21436 done
21437
21438 for ac_func in _ftime
21439 do :
21440 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21441 if test "x$ac_cv_func__ftime" = x""yes; then :
21442 cat >>confdefs.h <<_ACEOF
21443 #define HAVE__FTIME 1
21444 _ACEOF
21445
21446 fi
21447 done
21448
21449
21450 fi
21451
21452
21453
21454
21455
21456 GNULIB_GETTIMEOFDAY=1
21457
21458
21459
21460
21461
21462
21463
21464
21465
21466
21467 if test $ac_cv_func_lstat = yes; then
21468
21469 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21470 *no)
21471 REPLACE_LSTAT=1
21472 ;;
21473 esac
21474 else
21475 HAVE_LSTAT=0
21476 fi
21477
21478 if test $REPLACE_LSTAT = 1; then
21479
21480
21481
21482
21483
21484
21485
21486
21487 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21488
21489
21490
21491 :
21492
21493 fi
21494
21495
21496
21497
21498
21499 GNULIB_LSTAT=1
21500
21501
21502
21503
21504
21505
21506
21507
21508
21509
21510
21511 if test $APPLE_UNIVERSAL_BUILD = 1; then
21512 # A universal build on Apple Mac OS X platforms.
21513 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21514 # But we need a configuration result that is valid in both modes.
21515 gl_cv_func_working_mktime=no
21516 fi
21517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21518 $as_echo_n "checking for working mktime... " >&6; }
21519 if test "${gl_cv_func_working_mktime+set}" = set; then :
21520 $as_echo_n "(cached) " >&6
21521 else
21522 if test "$cross_compiling" = yes; then :
21523 gl_cv_func_working_mktime=no
21524 else
21525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21526 /* end confdefs.h. */
21527 /* Test program from Paul Eggert and Tony Leneis. */
21528 #include <limits.h>
21529 #include <stdlib.h>
21530 #include <time.h>
21531
21532 #ifdef HAVE_UNISTD_H
21533 # include <unistd.h>
21534 #endif
21535
21536 #ifndef HAVE_ALARM
21537 # define alarm(X) /* empty */
21538 #endif
21539
21540 /* Work around redefinition to rpl_putenv by other config tests. */
21541 #undef putenv
21542
21543 static time_t time_t_max;
21544 static time_t time_t_min;
21545
21546 /* Values we'll use to set the TZ environment variable. */
21547 static char *tz_strings[] = {
21548 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21549 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21550 };
21551 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21552
21553 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21554 Based on a problem report from Andreas Jaeger. */
21555 static int
21556 spring_forward_gap ()
21557 {
21558 /* glibc (up to about 1998-10-07) failed this test. */
21559 struct tm tm;
21560
21561 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21562 instead of "TZ=America/Vancouver" in order to detect the bug even
21563 on systems that don't support the Olson extension, or don't have the
21564 full zoneinfo tables installed. */
21565 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21566
21567 tm.tm_year = 98;
21568 tm.tm_mon = 3;
21569 tm.tm_mday = 5;
21570 tm.tm_hour = 2;
21571 tm.tm_min = 0;
21572 tm.tm_sec = 0;
21573 tm.tm_isdst = -1;
21574 return mktime (&tm) != (time_t) -1;
21575 }
21576
21577 static int
21578 mktime_test1 (time_t now)
21579 {
21580 struct tm *lt;
21581 return ! (lt = localtime (&now)) || mktime (lt) == now;
21582 }
21583
21584 static int
21585 mktime_test (time_t now)
21586 {
21587 return (mktime_test1 (now)
21588 && mktime_test1 ((time_t) (time_t_max - now))
21589 && mktime_test1 ((time_t) (time_t_min + now)));
21590 }
21591
21592 static int
21593 irix_6_4_bug ()
21594 {
21595 /* Based on code from Ariel Faigon. */
21596 struct tm tm;
21597 tm.tm_year = 96;
21598 tm.tm_mon = 3;
21599 tm.tm_mday = 0;
21600 tm.tm_hour = 0;
21601 tm.tm_min = 0;
21602 tm.tm_sec = 0;
21603 tm.tm_isdst = -1;
21604 mktime (&tm);
21605 return tm.tm_mon == 2 && tm.tm_mday == 31;
21606 }
21607
21608 static int
21609 bigtime_test (int j)
21610 {
21611 struct tm tm;
21612 time_t now;
21613 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21614 now = mktime (&tm);
21615 if (now != (time_t) -1)
21616 {
21617 struct tm *lt = localtime (&now);
21618 if (! (lt
21619 && lt->tm_year == tm.tm_year
21620 && lt->tm_mon == tm.tm_mon
21621 && lt->tm_mday == tm.tm_mday
21622 && lt->tm_hour == tm.tm_hour
21623 && lt->tm_min == tm.tm_min
21624 && lt->tm_sec == tm.tm_sec
21625 && lt->tm_yday == tm.tm_yday
21626 && lt->tm_wday == tm.tm_wday
21627 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21628 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21629 return 0;
21630 }
21631 return 1;
21632 }
21633
21634 static int
21635 year_2050_test ()
21636 {
21637 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21638 ignoring leap seconds. */
21639 unsigned long int answer = 2527315200UL;
21640
21641 struct tm tm;
21642 time_t t;
21643 tm.tm_year = 2050 - 1900;
21644 tm.tm_mon = 2 - 1;
21645 tm.tm_mday = 1;
21646 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21647 tm.tm_isdst = -1;
21648
21649 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21650 instead of "TZ=America/Vancouver" in order to detect the bug even
21651 on systems that don't support the Olson extension, or don't have the
21652 full zoneinfo tables installed. */
21653 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21654
21655 t = mktime (&tm);
21656
21657 /* Check that the result is either a failure, or close enough
21658 to the correct answer that we can assume the discrepancy is
21659 due to leap seconds. */
21660 return (t == (time_t) -1
21661 || (0 < t && answer - 120 <= t && t <= answer + 120));
21662 }
21663
21664 int
21665 main ()
21666 {
21667 int result = 0;
21668 time_t t, delta;
21669 int i, j;
21670 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21671 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21672
21673 /* This test makes some buggy mktime implementations loop.
21674 Give up after 60 seconds; a mktime slower than that
21675 isn't worth using anyway. */
21676 alarm (60);
21677
21678 time_t_max = (! time_t_signed
21679 ? (time_t) -1
21680 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21681 * 2 + 1));
21682 time_t_min = (! time_t_signed
21683 ? (time_t) 0
21684 : time_t_signed_magnitude
21685 ? ~ (time_t) 0
21686 : ~ time_t_max);
21687
21688 delta = time_t_max / 997; /* a suitable prime number */
21689 for (i = 0; i < N_STRINGS; i++)
21690 {
21691 if (tz_strings[i])
21692 putenv (tz_strings[i]);
21693
21694 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21695 if (! mktime_test (t))
21696 result |= 1;
21697 if ((result & 2) == 0
21698 && ! (mktime_test ((time_t) 1)
21699 && mktime_test ((time_t) (60 * 60))
21700 && mktime_test ((time_t) (60 * 60 * 24))))
21701 result |= 2;
21702
21703 for (j = 1; (result & 4) == 0; j <<= 1)
21704 {
21705 if (! bigtime_test (j))
21706 result |= 4;
21707 if (INT_MAX / 2 < j)
21708 break;
21709 }
21710 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21711 result |= 8;
21712 }
21713 if (! irix_6_4_bug ())
21714 result |= 16;
21715 if (! spring_forward_gap ())
21716 result |= 32;
21717 if (! year_2050_test ())
21718 result |= 64;
21719 return result;
21720 }
21721 _ACEOF
21722 if ac_fn_c_try_run "$LINENO"; then :
21723 gl_cv_func_working_mktime=yes
21724 else
21725 gl_cv_func_working_mktime=no
21726 fi
21727 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21728 conftest.$ac_objext conftest.beam conftest.$ac_ext
21729 fi
21730
21731
21732 fi
21733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21734 $as_echo "$gl_cv_func_working_mktime" >&6; }
21735
21736 if test $gl_cv_func_working_mktime = no; then
21737 REPLACE_MKTIME=1
21738 else
21739 REPLACE_MKTIME=0
21740 fi
21741
21742 if test $REPLACE_MKTIME = 1; then
21743
21744
21745
21746
21747
21748
21749
21750
21751 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21752
21753 :
21754 fi
21755
21756
21757
21758
21759
21760 GNULIB_MKTIME=1
21761
21762
21763
21764
21765
21766
21767
21768
21769
21770
21771
21772 if test $ac_cv_func_pselect = yes; then
21773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21774 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21775 if test "${gl_cv_sig_pselect+set}" = set; then :
21776 $as_echo_n "(cached) " >&6
21777 else
21778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21779 /* end confdefs.h. */
21780 #include <sys/select.h>
21781
21782 int
21783 main ()
21784 {
21785 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21786 struct timespec const *restrict,
21787 sigset_t const *restrict) = pselect;
21788 return !p;
21789 ;
21790 return 0;
21791 }
21792 _ACEOF
21793 if ac_fn_c_try_link "$LINENO"; then :
21794 gl_cv_sig_pselect=yes
21795 else
21796 gl_cv_sig_pselect=no
21797 fi
21798 rm -f core conftest.err conftest.$ac_objext \
21799 conftest$ac_exeext conftest.$ac_ext
21800 fi
21801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21802 $as_echo "$gl_cv_sig_pselect" >&6; }
21803
21804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
21805 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
21806 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
21807 $as_echo_n "(cached) " >&6
21808 else
21809
21810 if test "$cross_compiling" = yes; then :
21811
21812 case "$host_os" in
21813 # Guess yes on glibc systems.
21814 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
21815 # If we don't know, assume the worst.
21816 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
21817 esac
21818
21819 else
21820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21821 /* end confdefs.h. */
21822
21823 #include <sys/types.h>
21824 #include <sys/time.h>
21825 #if HAVE_SYS_SELECT_H
21826 # include <sys/select.h>
21827 #endif
21828 #include <unistd.h>
21829 #include <errno.h>
21830
21831 int
21832 main ()
21833 {
21834
21835 fd_set set;
21836 dup2(0, 16);
21837 FD_ZERO(&set);
21838 FD_SET(16, &set);
21839 close(16);
21840 struct timespec timeout;
21841 timeout.tv_sec = 0;
21842 timeout.tv_nsec = 5000;
21843 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
21844
21845 ;
21846 return 0;
21847 }
21848 _ACEOF
21849 if ac_fn_c_try_run "$LINENO"; then :
21850 gl_cv_func_pselect_detects_ebadf=yes
21851 else
21852 gl_cv_func_pselect_detects_ebadf=no
21853 fi
21854 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21855 conftest.$ac_objext conftest.beam conftest.$ac_ext
21856 fi
21857
21858
21859 fi
21860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
21861 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
21862 case $gl_cv_func_pselect_detects_ebadf in
21863 *yes) ;;
21864 *) REPLACE_PSELECT=1 ;;
21865 esac
21866 fi
21867
21868 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21869 REPLACE_PSELECT=1
21870 fi
21871
21872 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21873
21874
21875
21876
21877
21878
21879
21880
21881 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21882
21883 fi
21884
21885
21886
21887
21888
21889 GNULIB_PSELECT=1
21890
21891
21892
21893
21894
21895
21896
21897
21898
21899 LIB_PTHREAD_SIGMASK=
21900
21901
21902
21903
21904 if test "$gl_threads_api" = posix; then
21905 if test $ac_cv_func_pthread_sigmask = yes; then
21906 :
21907 else
21908 if test -n "$LIBMULTITHREAD"; then
21909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
21910 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
21911 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
21912 $as_echo_n "(cached) " >&6
21913 else
21914 gl_save_LIBS="$LIBS"
21915 LIBS="$LIBS $LIBMULTITHREAD"
21916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21917 /* end confdefs.h. */
21918 #include <pthread.h>
21919 #include <signal.h>
21920
21921 int
21922 main ()
21923 {
21924 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
21925 ;
21926 return 0;
21927 }
21928
21929 _ACEOF
21930 if ac_fn_c_try_link "$LINENO"; then :
21931 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
21932 else
21933 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
21934 fi
21935 rm -f core conftest.err conftest.$ac_objext \
21936 conftest$ac_exeext conftest.$ac_ext
21937 LIBS="$gl_save_LIBS"
21938
21939 fi
21940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
21941 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
21942 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
21943 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
21944 else
21945 HAVE_PTHREAD_SIGMASK=0
21946 fi
21947 else
21948 HAVE_PTHREAD_SIGMASK=0
21949 fi
21950 fi
21951 else
21952 if test $ac_cv_func_pthread_sigmask = yes; then
21953 REPLACE_PTHREAD_SIGMASK=1
21954 else
21955 HAVE_PTHREAD_SIGMASK=0
21956 fi
21957 fi
21958
21959
21960
21961
21962 if test $HAVE_PTHREAD_SIGMASK = 1; then
21963
21964
21965 if test -z "$LIB_PTHREAD_SIGMASK"; then
21966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
21967 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
21968 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
21969 $as_echo_n "(cached) " >&6
21970 else
21971
21972 if test "$cross_compiling" = yes; then :
21973
21974 case "$host_os" in
21975 freebsd* | hpux* | solaris | solaris2.[2-9]*)
21976 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
21977 *)
21978 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
21979 esac
21980
21981 else
21982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21983 /* end confdefs.h. */
21984
21985 #include <pthread.h>
21986 #include <signal.h>
21987 #include <stddef.h>
21988 int main ()
21989 {
21990 sigset_t set;
21991 sigemptyset (&set);
21992 return pthread_sigmask (1729, &set, NULL) != 0;
21993 }
21994 _ACEOF
21995 if ac_fn_c_try_run "$LINENO"; then :
21996 gl_cv_func_pthread_sigmask_in_libc_works=no
21997 else
21998 gl_cv_func_pthread_sigmask_in_libc_works=yes
21999 fi
22000 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22001 conftest.$ac_objext conftest.beam conftest.$ac_ext
22002 fi
22003
22004
22005 fi
22006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
22007 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
22008 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
22009 *no)
22010 REPLACE_PTHREAD_SIGMASK=1
22011
22012 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
22013
22014 ;;
22015 esac
22016 fi
22017
22018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
22019 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
22020 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
22021 $as_echo_n "(cached) " >&6
22022 else
22023
22024 gl_save_LIBS="$LIBS"
22025 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
22026 if test "$cross_compiling" = yes; then :
22027 case "$host_os" in
22028 cygwin*)
22029 gl_cv_func_pthread_sigmask_return_works="guessing no";;
22030 *)
22031 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
22032 esac
22033
22034 else
22035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22036 /* end confdefs.h. */
22037
22038 #include <pthread.h>
22039 #include <signal.h>
22040 #include <stddef.h>
22041 int main ()
22042 {
22043 sigset_t set;
22044 sigemptyset (&set);
22045 if (pthread_sigmask (1729, &set, NULL) == -1)
22046 return 1;
22047 return 0;
22048 }
22049 _ACEOF
22050 if ac_fn_c_try_run "$LINENO"; then :
22051 gl_cv_func_pthread_sigmask_return_works=yes
22052 else
22053 gl_cv_func_pthread_sigmask_return_works=no
22054 fi
22055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22056 conftest.$ac_objext conftest.beam conftest.$ac_ext
22057 fi
22058
22059 LIBS="$gl_save_LIBS"
22060
22061 fi
22062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
22063 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
22064 case "$gl_cv_func_pthread_sigmask_return_works" in
22065 *no)
22066 REPLACE_PTHREAD_SIGMASK=1
22067
22068 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
22069
22070 ;;
22071 esac
22072
22073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
22074 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
22075 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
22076 $as_echo_n "(cached) " >&6
22077 else
22078
22079 case "$host_os" in
22080 irix*)
22081 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
22082 *)
22083 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
22084 esac
22085 gl_save_LIBS="$LIBS"
22086 LIBS="$LIBS $LIBMULTITHREAD"
22087 if test "$cross_compiling" = yes; then :
22088 :
22089 else
22090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22091 /* end confdefs.h. */
22092
22093 #include <pthread.h>
22094 #include <signal.h>
22095 #include <stdio.h>
22096 #include <stdlib.h>
22097 #include <unistd.h>
22098 static volatile int sigint_occurred;
22099 static void
22100 sigint_handler (int sig)
22101 {
22102 sigint_occurred++;
22103 }
22104 int main ()
22105 {
22106 sigset_t set;
22107 int pid = getpid ();
22108 char command[80];
22109 signal (SIGINT, sigint_handler);
22110 sigemptyset (&set);
22111 sigaddset (&set, SIGINT);
22112 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
22113 return 1;
22114 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
22115 if (!(system (command) == 0))
22116 return 2;
22117 sleep (2);
22118 if (!(sigint_occurred == 0))
22119 return 3;
22120 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
22121 return 4;
22122 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
22123 return 5;
22124 return 0;
22125 }
22126 _ACEOF
22127 if ac_fn_c_try_run "$LINENO"; then :
22128 :
22129 else
22130 gl_cv_func_pthread_sigmask_unblock_works=no
22131 fi
22132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22133 conftest.$ac_objext conftest.beam conftest.$ac_ext
22134 fi
22135
22136 LIBS="$gl_save_LIBS"
22137
22138 fi
22139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
22140 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
22141 case "$gl_cv_func_pthread_sigmask_unblock_works" in
22142 *no)
22143 REPLACE_PTHREAD_SIGMASK=1
22144
22145 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
22146
22147 ;;
22148 esac
22149 fi
22150
22151 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22152
22153
22154
22155
22156
22157
22158
22159
22160 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
22161
22162
22163 if test $HAVE_PTHREAD_SIGMASK = 1; then
22164
22165 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
22166
22167 fi
22168
22169 fi
22170
22171
22172
22173
22174
22175 GNULIB_PTHREAD_SIGMASK=1
22176
22177
22178
22179
22180
22181
22182
22183
22184 if test $ac_cv_func_readlink = no; then
22185 HAVE_READLINK=0
22186 else
22187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
22188 $as_echo_n "checking whether readlink signature is correct... " >&6; }
22189 if test "${gl_cv_decl_readlink_works+set}" = set; then :
22190 $as_echo_n "(cached) " >&6
22191 else
22192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22193 /* end confdefs.h. */
22194 #include <unistd.h>
22195 /* Cause compilation failure if original declaration has wrong type. */
22196 ssize_t readlink (const char *, char *, size_t);
22197 int
22198 main ()
22199 {
22200
22201 ;
22202 return 0;
22203 }
22204 _ACEOF
22205 if ac_fn_c_try_compile "$LINENO"; then :
22206 gl_cv_decl_readlink_works=yes
22207 else
22208 gl_cv_decl_readlink_works=no
22209 fi
22210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22211 fi
22212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
22213 $as_echo "$gl_cv_decl_readlink_works" >&6; }
22214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
22215 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
22216 if test "${gl_cv_func_readlink_works+set}" = set; then :
22217 $as_echo_n "(cached) " >&6
22218 else
22219 # We have readlink, so assume ln -s works.
22220 ln -s conftest.no-such conftest.link
22221 ln -s conftest.link conftest.lnk2
22222 if test "$cross_compiling" = yes; then :
22223 case "$host_os" in
22224 # Guess yes on glibc systems.
22225 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
22226 # If we don't know, assume the worst.
22227 *) gl_cv_func_readlink_works="guessing no" ;;
22228 esac
22229
22230 else
22231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22232 /* end confdefs.h. */
22233 #include <unistd.h>
22234
22235 int
22236 main ()
22237 {
22238 char buf[20];
22239 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
22240 ;
22241 return 0;
22242 }
22243 _ACEOF
22244 if ac_fn_c_try_run "$LINENO"; then :
22245 gl_cv_func_readlink_works=yes
22246 else
22247 gl_cv_func_readlink_works=no
22248 fi
22249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22250 conftest.$ac_objext conftest.beam conftest.$ac_ext
22251 fi
22252
22253 rm -f conftest.link conftest.lnk2
22254 fi
22255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
22256 $as_echo "$gl_cv_func_readlink_works" >&6; }
22257 case "$gl_cv_func_readlink_works" in
22258 *yes)
22259 if test "$gl_cv_decl_readlink_works" != yes; then
22260 REPLACE_READLINK=1
22261 fi
22262 ;;
22263 *)
22264
22265 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
22266
22267 REPLACE_READLINK=1
22268 ;;
22269 esac
22270 fi
22271
22272 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22273
22274
22275
22276
22277
22278
22279
22280
22281 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
22282
22283
22284 :
22285
22286 fi
22287
22288
22289
22290
22291
22292 GNULIB_READLINK=1
22293
22294
22295
22296
22297
22298
22299
22300
22301
22302
22303
22304
22305
22306
22307
22308
22309 if test $gl_cv_have_include_next = yes; then
22310 gl_cv_next_signal_h='<'signal.h'>'
22311 else
22312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22313 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22314 if test "${gl_cv_next_signal_h+set}" = set; then :
22315 $as_echo_n "(cached) " >&6
22316 else
22317
22318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22319 /* end confdefs.h. */
22320 #include <signal.h>
22321
22322 _ACEOF
22323 case "$host_os" in
22324 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22325 *) gl_absname_cpp="$ac_cpp" ;;
22326 esac
22327
22328 case "$host_os" in
22329 mingw*)
22330 gl_dirsep_regex='[/\\]'
22331 ;;
22332 *)
22333 gl_dirsep_regex='\/'
22334 ;;
22335 esac
22336 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22337
22338 gl_header_literal_regex=`echo 'signal.h' \
22339 | sed -e "$gl_make_literal_regex_sed"`
22340 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22341 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22342 s|^/[^/]|//&|
22343 p
22344 q
22345 }'
22346 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22347 sed -n "$gl_absolute_header_sed"`'"'
22348
22349
22350 fi
22351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22352 $as_echo "$gl_cv_next_signal_h" >&6; }
22353 fi
22354 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22355
22356 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22357 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22358 gl_next_as_first_directive='<'signal.h'>'
22359 else
22360 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22361 gl_next_as_first_directive=$gl_cv_next_signal_h
22362 fi
22363 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22364
22365
22366
22367
22368
22369 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22370 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22371 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22372 #include <signal.h>
22373
22374 "
22375 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22376
22377 else
22378 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22379 fi
22380
22381
22382
22383
22384
22385
22386
22387 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22388 #include <signal.h>
22389
22390 "
22391 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22392
22393 else
22394 HAVE_SIGHANDLER_T=0
22395 fi
22396
22397
22398
22399
22400 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22401 /* <sys/types.h> is not needed according to POSIX, but the
22402 <sys/socket.h> in i386-unknown-freebsd4.10 and
22403 powerpc-apple-darwin5.5 required it. */
22404 #include <sys/types.h>
22405 #if HAVE_SYS_SOCKET_H
22406 # include <sys/socket.h>
22407 #elif HAVE_WS2TCPIP_H
22408 # include <ws2tcpip.h>
22409 #endif
22410
22411 "
22412 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22413
22414 else
22415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22416 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22417 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22418 $as_echo_n "(cached) " >&6
22419 else
22420 # Systems have either "struct sockaddr *" or
22421 # "void *" as the second argument to getpeername
22422 gl_cv_socklen_t_equiv=
22423 for arg2 in "struct sockaddr" void; do
22424 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22426 /* end confdefs.h. */
22427 #include <sys/types.h>
22428 #include <sys/socket.h>
22429
22430 int getpeername (int, $arg2 *, $t *);
22431 int
22432 main ()
22433 {
22434 $t len;
22435 getpeername (0, 0, &len);
22436 ;
22437 return 0;
22438 }
22439 _ACEOF
22440 if ac_fn_c_try_compile "$LINENO"; then :
22441 gl_cv_socklen_t_equiv="$t"
22442 fi
22443 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22444 test "$gl_cv_socklen_t_equiv" != "" && break
22445 done
22446 test "$gl_cv_socklen_t_equiv" != "" && break
22447 done
22448
22449 fi
22450
22451 if test "$gl_cv_socklen_t_equiv" = ""; then
22452 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22453 fi
22454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22455 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
22456
22457 cat >>confdefs.h <<_ACEOF
22458 #define socklen_t $gl_cv_socklen_t_equiv
22459 _ACEOF
22460
22461 fi
22462
22463
22464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22465 $as_echo_n "checking for ssize_t... " >&6; }
22466 if test "${gt_cv_ssize_t+set}" = set; then :
22467 $as_echo_n "(cached) " >&6
22468 else
22469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22470 /* end confdefs.h. */
22471 #include <sys/types.h>
22472 int
22473 main ()
22474 {
22475 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22476 return !x;
22477 ;
22478 return 0;
22479 }
22480 _ACEOF
22481 if ac_fn_c_try_compile "$LINENO"; then :
22482 gt_cv_ssize_t=yes
22483 else
22484 gt_cv_ssize_t=no
22485 fi
22486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22487 fi
22488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
22489 $as_echo "$gt_cv_ssize_t" >&6; }
22490 if test $gt_cv_ssize_t = no; then
22491
22492 $as_echo "#define ssize_t int" >>confdefs.h
22493
22494 fi
22495
22496
22497
22498
22499
22500 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>
22501 #include <sys/stat.h>
22502 "
22503 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
22504
22505 cat >>confdefs.h <<_ACEOF
22506 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
22507 _ACEOF
22508
22509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
22510 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
22511 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
22512 $as_echo_n "(cached) " >&6
22513 else
22514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22515 /* end confdefs.h. */
22516
22517 #include <sys/types.h>
22518 #include <sys/stat.h>
22519 #if HAVE_SYS_TIME_H
22520 # include <sys/time.h>
22521 #endif
22522 #include <time.h>
22523 struct timespec ts;
22524 struct stat st;
22525
22526 int
22527 main ()
22528 {
22529
22530 st.st_atim = ts;
22531
22532 ;
22533 return 0;
22534 }
22535 _ACEOF
22536 if ac_fn_c_try_compile "$LINENO"; then :
22537 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
22538 else
22539 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
22540 fi
22541 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22542 fi
22543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
22544 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
22545 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
22546
22547 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
22548
22549 fi
22550 else
22551 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>
22552 #include <sys/stat.h>
22553 "
22554 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
22555
22556 cat >>confdefs.h <<_ACEOF
22557 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
22558 _ACEOF
22559
22560
22561 else
22562 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
22563 #include <sys/stat.h>
22564 "
22565 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
22566
22567 cat >>confdefs.h <<_ACEOF
22568 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
22569 _ACEOF
22570
22571
22572 else
22573 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>
22574 #include <sys/stat.h>
22575 "
22576 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
22577
22578 cat >>confdefs.h <<_ACEOF
22579 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
22580 _ACEOF
22581
22582
22583 fi
22584
22585 fi
22586
22587 fi
22588
22589 fi
22590
22591
22592
22593
22594
22595 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>
22596 #include <sys/stat.h>
22597 "
22598 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
22599
22600 cat >>confdefs.h <<_ACEOF
22601 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
22602 _ACEOF
22603
22604
22605 else
22606 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
22607 #include <sys/stat.h>
22608 "
22609 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
22610
22611 cat >>confdefs.h <<_ACEOF
22612 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
22613 _ACEOF
22614
22615
22616 else
22617 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>
22618 #include <sys/stat.h>
22619 "
22620 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
22621
22622 cat >>confdefs.h <<_ACEOF
22623 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
22624 _ACEOF
22625
22626
22627 fi
22628
22629 fi
22630
22631 fi
22632
22633
22634
22635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
22636 $as_echo_n "checking for working stdalign.h... " >&6; }
22637 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
22638 $as_echo_n "(cached) " >&6
22639 else
22640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22641 /* end confdefs.h. */
22642 #include <stdalign.h>
22643 #include <stddef.h>
22644
22645 /* Test that alignof yields a result consistent with offsetof.
22646 This catches GCC bug 52023
22647 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
22648 #ifdef __cplusplus
22649 template <class t> struct alignof_helper { char a; t b; };
22650 # define ao(type) offsetof (alignof_helper<type>, b)
22651 #else
22652 # define ao(type) offsetof (struct { char a; type b; }, b)
22653 #endif
22654 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
22655 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
22656 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
22657
22658 /* Test _Alignas only on platforms where gnulib can help. */
22659 #if \
22660 (__GNUC__ || __IBMC__ || __IBMCPP__ \
22661 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
22662 int alignas (8) alignas_int = 1;
22663 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
22664 #endif
22665
22666 int
22667 main ()
22668 {
22669
22670 ;
22671 return 0;
22672 }
22673 _ACEOF
22674 if ac_fn_c_try_compile "$LINENO"; then :
22675 gl_cv_header_working_stdalign_h=yes
22676 else
22677 gl_cv_header_working_stdalign_h=no
22678 fi
22679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22680 fi
22681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
22682 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
22683
22684 if test $gl_cv_header_working_stdalign_h = yes; then
22685 STDALIGN_H=''
22686 else
22687 STDALIGN_H='stdalign.h'
22688 fi
22689
22690
22691 if test -n "$STDALIGN_H"; then
22692 GL_GENERATE_STDALIGN_H_TRUE=
22693 GL_GENERATE_STDALIGN_H_FALSE='#'
22694 else
22695 GL_GENERATE_STDALIGN_H_TRUE='#'
22696 GL_GENERATE_STDALIGN_H_FALSE=
22697 fi
22698
22699
22700
22701 STDARG_H=''
22702 NEXT_STDARG_H='<stdarg.h>'
22703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
22704 $as_echo_n "checking for va_copy... " >&6; }
22705 if test "${gl_cv_func_va_copy+set}" = set; then :
22706 $as_echo_n "(cached) " >&6
22707 else
22708
22709 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22710 /* end confdefs.h. */
22711 #include <stdarg.h>
22712 int
22713 main ()
22714 {
22715
22716 #ifndef va_copy
22717 void (*func) (va_list, va_list) = va_copy;
22718 #endif
22719
22720 ;
22721 return 0;
22722 }
22723 _ACEOF
22724 if ac_fn_c_try_compile "$LINENO"; then :
22725 gl_cv_func_va_copy=yes
22726 else
22727 gl_cv_func_va_copy=no
22728 fi
22729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22730 fi
22731
22732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
22733 $as_echo "$gl_cv_func_va_copy" >&6; }
22734 if test $gl_cv_func_va_copy = no; then
22735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22736 /* end confdefs.h. */
22737 #if defined _AIX && !defined __GNUC__
22738 AIX vaccine
22739 #endif
22740
22741 _ACEOF
22742 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22743 $EGREP "vaccine" >/dev/null 2>&1; then :
22744 gl_aixcc=yes
22745 else
22746 gl_aixcc=no
22747 fi
22748 rm -f conftest*
22749
22750 if test $gl_aixcc = yes; then
22751 STDARG_H=stdarg.h
22752
22753
22754
22755
22756
22757
22758
22759
22760 if test $gl_cv_have_include_next = yes; then
22761 gl_cv_next_stdarg_h='<'stdarg.h'>'
22762 else
22763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22764 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22765 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22766 $as_echo_n "(cached) " >&6
22767 else
22768
22769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22770 /* end confdefs.h. */
22771 #include <stdarg.h>
22772
22773 _ACEOF
22774 case "$host_os" in
22775 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22776 *) gl_absname_cpp="$ac_cpp" ;;
22777 esac
22778
22779 case "$host_os" in
22780 mingw*)
22781 gl_dirsep_regex='[/\\]'
22782 ;;
22783 *)
22784 gl_dirsep_regex='\/'
22785 ;;
22786 esac
22787 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22788
22789 gl_header_literal_regex=`echo 'stdarg.h' \
22790 | sed -e "$gl_make_literal_regex_sed"`
22791 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22792 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22793 s|^/[^/]|//&|
22794 p
22795 q
22796 }'
22797 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22798 sed -n "$gl_absolute_header_sed"`'"'
22799
22800
22801 fi
22802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22803 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22804 fi
22805 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22806
22807 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22808 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22809 gl_next_as_first_directive='<'stdarg.h'>'
22810 else
22811 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22812 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22813 fi
22814 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22815
22816
22817
22818
22819 if test "$gl_cv_next_stdarg_h" = '""'; then
22820 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22821 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22822 fi
22823 else
22824
22825 saved_as_echo_n="$as_echo_n"
22826 as_echo_n=':'
22827 if test "${gl_cv_func___va_copy+set}" = set; then :
22828 $as_echo_n "(cached) " >&6
22829 else
22830
22831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22832 /* end confdefs.h. */
22833 #include <stdarg.h>
22834 int
22835 main ()
22836 {
22837
22838 #ifndef __va_copy
22839 error, bail out
22840 #endif
22841
22842 ;
22843 return 0;
22844 }
22845 _ACEOF
22846 if ac_fn_c_try_compile "$LINENO"; then :
22847 gl_cv_func___va_copy=yes
22848 else
22849 gl_cv_func___va_copy=no
22850 fi
22851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22852 fi
22853
22854 as_echo_n="$saved_as_echo_n"
22855
22856 if test $gl_cv_func___va_copy = yes; then
22857
22858 $as_echo "#define va_copy __va_copy" >>confdefs.h
22859
22860 else
22861
22862
22863 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22864
22865 fi
22866 fi
22867 fi
22868
22869 if test -n "$STDARG_H"; then
22870 GL_GENERATE_STDARG_H_TRUE=
22871 GL_GENERATE_STDARG_H_FALSE='#'
22872 else
22873 GL_GENERATE_STDARG_H_TRUE='#'
22874 GL_GENERATE_STDARG_H_FALSE=
22875 fi
22876
22877
22878
22879
22880
22881
22882 # Define two additional variables used in the Makefile substitution.
22883
22884 if test "$ac_cv_header_stdbool_h" = yes; then
22885 STDBOOL_H=''
22886 else
22887 STDBOOL_H='stdbool.h'
22888 fi
22889
22890 if test -n "$STDBOOL_H"; then
22891 GL_GENERATE_STDBOOL_H_TRUE=
22892 GL_GENERATE_STDBOOL_H_FALSE='#'
22893 else
22894 GL_GENERATE_STDBOOL_H_TRUE='#'
22895 GL_GENERATE_STDBOOL_H_FALSE=
22896 fi
22897
22898
22899 if test "$ac_cv_type__Bool" = yes; then
22900 HAVE__BOOL=1
22901 else
22902 HAVE__BOOL=0
22903 fi
22904
22905
22906
22907
22908
22909 STDDEF_H=
22910 if test $gt_cv_c_wchar_t = no; then
22911 HAVE_WCHAR_T=0
22912 STDDEF_H=stddef.h
22913 fi
22914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22915 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22916 if test "${gl_cv_decl_null_works+set}" = set; then :
22917 $as_echo_n "(cached) " >&6
22918 else
22919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22920 /* end confdefs.h. */
22921 #include <stddef.h>
22922 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22923
22924 int
22925 main ()
22926 {
22927
22928 ;
22929 return 0;
22930 }
22931 _ACEOF
22932 if ac_fn_c_try_compile "$LINENO"; then :
22933 gl_cv_decl_null_works=yes
22934 else
22935 gl_cv_decl_null_works=no
22936 fi
22937 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22938 fi
22939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22940 $as_echo "$gl_cv_decl_null_works" >&6; }
22941 if test $gl_cv_decl_null_works = no; then
22942 REPLACE_NULL=1
22943 STDDEF_H=stddef.h
22944 fi
22945
22946 if test -n "$STDDEF_H"; then
22947 GL_GENERATE_STDDEF_H_TRUE=
22948 GL_GENERATE_STDDEF_H_FALSE='#'
22949 else
22950 GL_GENERATE_STDDEF_H_TRUE='#'
22951 GL_GENERATE_STDDEF_H_FALSE=
22952 fi
22953
22954 if test -n "$STDDEF_H"; then
22955
22956
22957
22958
22959
22960
22961
22962
22963 if test $gl_cv_have_include_next = yes; then
22964 gl_cv_next_stddef_h='<'stddef.h'>'
22965 else
22966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22967 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22968 if test "${gl_cv_next_stddef_h+set}" = set; then :
22969 $as_echo_n "(cached) " >&6
22970 else
22971
22972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22973 /* end confdefs.h. */
22974 #include <stddef.h>
22975
22976 _ACEOF
22977 case "$host_os" in
22978 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22979 *) gl_absname_cpp="$ac_cpp" ;;
22980 esac
22981
22982 case "$host_os" in
22983 mingw*)
22984 gl_dirsep_regex='[/\\]'
22985 ;;
22986 *)
22987 gl_dirsep_regex='\/'
22988 ;;
22989 esac
22990 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22991
22992 gl_header_literal_regex=`echo 'stddef.h' \
22993 | sed -e "$gl_make_literal_regex_sed"`
22994 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22995 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22996 s|^/[^/]|//&|
22997 p
22998 q
22999 }'
23000 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23001 sed -n "$gl_absolute_header_sed"`'"'
23002
23003
23004 fi
23005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
23006 $as_echo "$gl_cv_next_stddef_h" >&6; }
23007 fi
23008 NEXT_STDDEF_H=$gl_cv_next_stddef_h
23009
23010 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23011 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23012 gl_next_as_first_directive='<'stddef.h'>'
23013 else
23014 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23015 gl_next_as_first_directive=$gl_cv_next_stddef_h
23016 fi
23017 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
23018
23019
23020
23021
23022 fi
23023
23024
23025
23026
23027
23028
23029
23030
23031
23032
23033
23034
23035
23036 if test $gl_cv_have_include_next = yes; then
23037 gl_cv_next_stdio_h='<'stdio.h'>'
23038 else
23039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
23040 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
23041 if test "${gl_cv_next_stdio_h+set}" = set; then :
23042 $as_echo_n "(cached) " >&6
23043 else
23044
23045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23046 /* end confdefs.h. */
23047 #include <stdio.h>
23048
23049 _ACEOF
23050 case "$host_os" in
23051 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23052 *) gl_absname_cpp="$ac_cpp" ;;
23053 esac
23054
23055 case "$host_os" in
23056 mingw*)
23057 gl_dirsep_regex='[/\\]'
23058 ;;
23059 *)
23060 gl_dirsep_regex='\/'
23061 ;;
23062 esac
23063 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23064
23065 gl_header_literal_regex=`echo 'stdio.h' \
23066 | sed -e "$gl_make_literal_regex_sed"`
23067 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23068 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23069 s|^/[^/]|//&|
23070 p
23071 q
23072 }'
23073 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23074 sed -n "$gl_absolute_header_sed"`'"'
23075
23076
23077 fi
23078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
23079 $as_echo "$gl_cv_next_stdio_h" >&6; }
23080 fi
23081 NEXT_STDIO_H=$gl_cv_next_stdio_h
23082
23083 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23084 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23085 gl_next_as_first_directive='<'stdio.h'>'
23086 else
23087 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23088 gl_next_as_first_directive=$gl_cv_next_stdio_h
23089 fi
23090 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
23091
23092
23093
23094
23095
23096 GNULIB_FSCANF=1
23097
23098
23099 cat >>confdefs.h <<_ACEOF
23100 #define GNULIB_FSCANF 1
23101 _ACEOF
23102
23103
23104 GNULIB_SCANF=1
23105
23106
23107 cat >>confdefs.h <<_ACEOF
23108 #define GNULIB_SCANF 1
23109 _ACEOF
23110
23111
23112 GNULIB_FGETC=1
23113 GNULIB_GETC=1
23114 GNULIB_GETCHAR=1
23115 GNULIB_FGETS=1
23116 GNULIB_FREAD=1
23117
23118
23119 GNULIB_FPRINTF=1
23120 GNULIB_PRINTF=1
23121 GNULIB_VFPRINTF=1
23122 GNULIB_VPRINTF=1
23123 GNULIB_FPUTC=1
23124 GNULIB_PUTC=1
23125 GNULIB_PUTCHAR=1
23126 GNULIB_FPUTS=1
23127 GNULIB_PUTS=1
23128 GNULIB_FWRITE=1
23129
23130
23131
23132
23133
23134
23135
23136
23137
23138
23139
23140
23141
23142
23143
23144 if test $gl_cv_have_include_next = yes; then
23145 gl_cv_next_stdlib_h='<'stdlib.h'>'
23146 else
23147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
23148 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
23149 if test "${gl_cv_next_stdlib_h+set}" = set; then :
23150 $as_echo_n "(cached) " >&6
23151 else
23152
23153 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23154 /* end confdefs.h. */
23155 #include <stdlib.h>
23156
23157 _ACEOF
23158 case "$host_os" in
23159 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23160 *) gl_absname_cpp="$ac_cpp" ;;
23161 esac
23162
23163 case "$host_os" in
23164 mingw*)
23165 gl_dirsep_regex='[/\\]'
23166 ;;
23167 *)
23168 gl_dirsep_regex='\/'
23169 ;;
23170 esac
23171 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23172
23173 gl_header_literal_regex=`echo 'stdlib.h' \
23174 | sed -e "$gl_make_literal_regex_sed"`
23175 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23176 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23177 s|^/[^/]|//&|
23178 p
23179 q
23180 }'
23181 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23182 sed -n "$gl_absolute_header_sed"`'"'
23183
23184
23185 fi
23186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
23187 $as_echo "$gl_cv_next_stdlib_h" >&6; }
23188 fi
23189 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
23190
23191 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23192 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23193 gl_next_as_first_directive='<'stdlib.h'>'
23194 else
23195 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23196 gl_next_as_first_directive=$gl_cv_next_stdlib_h
23197 fi
23198 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
23199
23200
23201
23202
23203
23204
23205
23206
23207
23208 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
23209
23210
23211
23212
23213
23214
23215
23216 $as_echo "#define my_strftime nstrftime" >>confdefs.h
23217
23218
23219
23220
23221
23222
23223
23224
23225 if test "$ac_cv_have_decl_strtoimax" != yes; then
23226 HAVE_DECL_STRTOIMAX=0
23227 fi
23228
23229 if test $ac_cv_func_strtoimax = yes; then
23230 HAVE_STRTOIMAX=1
23231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
23232 $as_echo_n "checking whether strtoimax works... " >&6; }
23233 if test "${gl_cv_func_strtoimax+set}" = set; then :
23234 $as_echo_n "(cached) " >&6
23235 else
23236 if test "$cross_compiling" = yes; then :
23237 case "$host_os" in
23238 # Guess no on AIX 5.
23239 aix5*) gl_cv_func_strtoimax="guessing no" ;;
23240 # Guess yes otherwise.
23241 *) gl_cv_func_strtoimax="guessing yes" ;;
23242 esac
23243
23244 else
23245 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23246 /* end confdefs.h. */
23247
23248 #include <errno.h>
23249 #include <string.h>
23250 #include <inttypes.h>
23251 int main ()
23252 {
23253 if (sizeof (intmax_t) > sizeof (int))
23254 {
23255 const char *s = "4294967295";
23256 char *p;
23257 intmax_t res;
23258 errno = 0;
23259 res = strtoimax (s, &p, 10);
23260 if (p != s + strlen (s))
23261 return 1;
23262 if (errno != 0)
23263 return 2;
23264 if (res != (intmax_t) 65535 * (intmax_t) 65537)
23265 return 3;
23266 }
23267 else
23268 {
23269 const char *s = "2147483647";
23270 char *p;
23271 intmax_t res;
23272 errno = 0;
23273 res = strtoimax (s, &p, 10);
23274 if (p != s + strlen (s))
23275 return 1;
23276 if (errno != 0)
23277 return 2;
23278 if (res != 2147483647)
23279 return 3;
23280 }
23281 return 0;
23282 }
23283
23284 _ACEOF
23285 if ac_fn_c_try_run "$LINENO"; then :
23286 gl_cv_func_strtoimax=yes
23287 else
23288 gl_cv_func_strtoimax=no
23289 fi
23290 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23291 conftest.$ac_objext conftest.beam conftest.$ac_ext
23292 fi
23293
23294
23295 fi
23296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
23297 $as_echo "$gl_cv_func_strtoimax" >&6; }
23298 case "$gl_cv_func_strtoimax" in
23299 *no) REPLACE_STRTOIMAX=1 ;;
23300 esac
23301 else
23302 HAVE_STRTOIMAX=0
23303 fi
23304
23305 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23306
23307
23308
23309
23310
23311
23312
23313
23314 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
23315
23316
23317 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23318 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
23319 ac_have_decl=1
23320 else
23321 ac_have_decl=0
23322 fi
23323
23324 cat >>confdefs.h <<_ACEOF
23325 #define HAVE_DECL_STRTOLL $ac_have_decl
23326 _ACEOF
23327
23328
23329
23330 fi
23331
23332
23333
23334
23335
23336 GNULIB_STRTOIMAX=1
23337
23338
23339
23340
23341
23342
23343
23344
23345
23346 if test "$ac_cv_have_decl_strtoumax" != yes; then
23347 HAVE_DECL_STRTOUMAX=0
23348 fi
23349
23350 if test $ac_cv_func_strtoumax = no; then
23351
23352
23353
23354
23355
23356
23357
23358
23359 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
23360
23361
23362 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23363 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
23364 ac_have_decl=1
23365 else
23366 ac_have_decl=0
23367 fi
23368
23369 cat >>confdefs.h <<_ACEOF
23370 #define HAVE_DECL_STRTOULL $ac_have_decl
23371 _ACEOF
23372
23373
23374
23375 fi
23376
23377
23378
23379
23380
23381 GNULIB_STRTOUMAX=1
23382
23383
23384
23385
23386
23387
23388
23389 if test $ac_cv_func_symlink = no; then
23390 HAVE_SYMLINK=0
23391 else
23392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23393 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23394 if test "${gl_cv_func_symlink_works+set}" = set; then :
23395 $as_echo_n "(cached) " >&6
23396 else
23397 if test "$cross_compiling" = yes; then :
23398 case "$host_os" in
23399 # Guess yes on glibc systems.
23400 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23401 # If we don't know, assume the worst.
23402 *) gl_cv_func_symlink_works="guessing no" ;;
23403 esac
23404
23405 else
23406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23407 /* end confdefs.h. */
23408 #include <unistd.h>
23409
23410 int
23411 main ()
23412 {
23413 int result = 0;
23414 if (!symlink ("a", "conftest.link/"))
23415 result |= 1;
23416 if (symlink ("conftest.f", "conftest.lnk2"))
23417 result |= 2;
23418 else if (!symlink ("a", "conftest.lnk2/"))
23419 result |= 4;
23420 return result;
23421
23422 ;
23423 return 0;
23424 }
23425 _ACEOF
23426 if ac_fn_c_try_run "$LINENO"; then :
23427 gl_cv_func_symlink_works=yes
23428 else
23429 gl_cv_func_symlink_works=no
23430 fi
23431 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23432 conftest.$ac_objext conftest.beam conftest.$ac_ext
23433 fi
23434
23435 rm -f conftest.f conftest.link conftest.lnk2
23436 fi
23437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23438 $as_echo "$gl_cv_func_symlink_works" >&6; }
23439 case "$gl_cv_func_symlink_works" in
23440 *yes) ;;
23441 *)
23442 REPLACE_SYMLINK=1
23443 ;;
23444 esac
23445 fi
23446
23447 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23448
23449
23450
23451
23452
23453
23454
23455
23456 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
23457
23458 fi
23459
23460
23461
23462
23463
23464 GNULIB_SYMLINK=1
23465
23466
23467
23468
23469
23470
23471
23472
23473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
23474 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
23475 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
23476 $as_echo_n "(cached) " >&6
23477 else
23478
23479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23480 /* end confdefs.h. */
23481 #include <sys/select.h>
23482 int
23483 main ()
23484 {
23485 struct timeval b;
23486 ;
23487 return 0;
23488 }
23489 _ACEOF
23490 if ac_fn_c_try_compile "$LINENO"; then :
23491 gl_cv_header_sys_select_h_selfcontained=yes
23492 else
23493 gl_cv_header_sys_select_h_selfcontained=no
23494 fi
23495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23496 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
23497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23498 /* end confdefs.h. */
23499 #include <sys/select.h>
23500 int
23501 main ()
23502 {
23503 int memset; int bzero;
23504 ;
23505 return 0;
23506 }
23507
23508 _ACEOF
23509 if ac_fn_c_try_compile "$LINENO"; then :
23510 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23511 /* end confdefs.h. */
23512 #include <sys/select.h>
23513 int
23514 main ()
23515 {
23516
23517 #undef memset
23518 #define memset nonexistent_memset
23519 extern
23520 #ifdef __cplusplus
23521 "C"
23522 #endif
23523 void *memset (void *, int, unsigned long);
23524 #undef bzero
23525 #define bzero nonexistent_bzero
23526 extern
23527 #ifdef __cplusplus
23528 "C"
23529 #endif
23530 void bzero (void *, unsigned long);
23531 fd_set fds;
23532 FD_ZERO (&fds);
23533
23534 ;
23535 return 0;
23536 }
23537
23538 _ACEOF
23539 if ac_fn_c_try_link "$LINENO"; then :
23540
23541 else
23542 gl_cv_header_sys_select_h_selfcontained=no
23543 fi
23544 rm -f core conftest.err conftest.$ac_objext \
23545 conftest$ac_exeext conftest.$ac_ext
23546
23547 fi
23548 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23549 fi
23550
23551 fi
23552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
23553 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
23554
23555
23556
23557
23558
23559
23560
23561
23562
23563 if test $gl_cv_have_include_next = yes; then
23564 gl_cv_next_sys_select_h='<'sys/select.h'>'
23565 else
23566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
23567 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
23568 if test "${gl_cv_next_sys_select_h+set}" = set; then :
23569 $as_echo_n "(cached) " >&6
23570 else
23571
23572 if test $ac_cv_header_sys_select_h = yes; then
23573
23574
23575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23576 /* end confdefs.h. */
23577 #include <sys/select.h>
23578
23579 _ACEOF
23580 case "$host_os" in
23581 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23582 *) gl_absname_cpp="$ac_cpp" ;;
23583 esac
23584
23585 case "$host_os" in
23586 mingw*)
23587 gl_dirsep_regex='[/\\]'
23588 ;;
23589 *)
23590 gl_dirsep_regex='\/'
23591 ;;
23592 esac
23593 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23594
23595 gl_header_literal_regex=`echo 'sys/select.h' \
23596 | sed -e "$gl_make_literal_regex_sed"`
23597 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23598 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23599 s|^/[^/]|//&|
23600 p
23601 q
23602 }'
23603 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23604 sed -n "$gl_absolute_header_sed"`'"'
23605 else
23606 gl_cv_next_sys_select_h='<'sys/select.h'>'
23607 fi
23608
23609
23610 fi
23611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
23612 $as_echo "$gl_cv_next_sys_select_h" >&6; }
23613 fi
23614 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
23615
23616 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23617 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23618 gl_next_as_first_directive='<'sys/select.h'>'
23619 else
23620 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23621 gl_next_as_first_directive=$gl_cv_next_sys_select_h
23622 fi
23623 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
23624
23625
23626
23627
23628 if test $ac_cv_header_sys_select_h = yes; then
23629 HAVE_SYS_SELECT_H=1
23630 else
23631 HAVE_SYS_SELECT_H=0
23632 fi
23633
23634
23635
23636
23637
23638 if test $ac_cv_header_sys_socket_h != yes; then
23639 for ac_header in winsock2.h
23640 do :
23641 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23642 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
23643 cat >>confdefs.h <<_ACEOF
23644 #define HAVE_WINSOCK2_H 1
23645 _ACEOF
23646
23647 fi
23648
23649 done
23650
23651 fi
23652 if test "$ac_cv_header_winsock2_h" = yes; then
23653 HAVE_WINSOCK2_H=1
23654 UNISTD_H_HAVE_WINSOCK2_H=1
23655 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23656 else
23657 HAVE_WINSOCK2_H=0
23658 fi
23659
23660
23661
23662
23663
23664
23665
23666
23667
23668
23669
23670
23671
23672
23673
23674
23675
23676
23677
23678
23679
23680
23681 if test $gl_cv_have_include_next = yes; then
23682 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23683 else
23684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23685 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23686 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
23687 $as_echo_n "(cached) " >&6
23688 else
23689
23690 if test $ac_cv_header_sys_stat_h = yes; then
23691
23692
23693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23694 /* end confdefs.h. */
23695 #include <sys/stat.h>
23696
23697 _ACEOF
23698 case "$host_os" in
23699 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23700 *) gl_absname_cpp="$ac_cpp" ;;
23701 esac
23702
23703 case "$host_os" in
23704 mingw*)
23705 gl_dirsep_regex='[/\\]'
23706 ;;
23707 *)
23708 gl_dirsep_regex='\/'
23709 ;;
23710 esac
23711 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23712
23713 gl_header_literal_regex=`echo 'sys/stat.h' \
23714 | sed -e "$gl_make_literal_regex_sed"`
23715 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23716 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23717 s|^/[^/]|//&|
23718 p
23719 q
23720 }'
23721 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23722 sed -n "$gl_absolute_header_sed"`'"'
23723 else
23724 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23725 fi
23726
23727
23728 fi
23729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23730 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23731 fi
23732 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23733
23734 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23735 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23736 gl_next_as_first_directive='<'sys/stat.h'>'
23737 else
23738 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23739 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23740 fi
23741 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23742
23743
23744
23745
23746
23747
23748
23749
23750
23751
23752
23753 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23754
23755 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23756
23757 fi
23758
23759 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23760 #include <sys/stat.h>
23761 "
23762 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23763
23764 else
23765
23766 $as_echo "#define nlink_t int" >>confdefs.h
23767
23768 fi
23769
23770
23771
23772
23773
23774
23775
23776
23777
23778
23779
23780
23781
23782
23783
23784
23785
23786
23787 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23788 "
23789 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23790 ac_have_decl=1
23791 else
23792 ac_have_decl=0
23793 fi
23794
23795 cat >>confdefs.h <<_ACEOF
23796 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23797 _ACEOF
23798
23799 if test $ac_cv_have_decl_localtime_r = no; then
23800 HAVE_DECL_LOCALTIME_R=0
23801 fi
23802
23803
23804 if test $ac_cv_func_localtime_r = yes; then
23805 HAVE_LOCALTIME_R=1
23806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23807 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23808 if test "${gl_cv_time_r_posix+set}" = set; then :
23809 $as_echo_n "(cached) " >&6
23810 else
23811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23812 /* end confdefs.h. */
23813 #include <time.h>
23814 int
23815 main ()
23816 {
23817 /* We don't need to append 'restrict's to the argument types,
23818 even though the POSIX signature has the 'restrict's,
23819 since C99 says they can't affect type compatibility. */
23820 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23821 if (ptr) return 0;
23822 /* Check the return type is a pointer.
23823 On HP-UX 10 it is 'int'. */
23824 *localtime_r (0, 0);
23825 ;
23826 return 0;
23827 }
23828
23829 _ACEOF
23830 if ac_fn_c_try_compile "$LINENO"; then :
23831 gl_cv_time_r_posix=yes
23832 else
23833 gl_cv_time_r_posix=no
23834 fi
23835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23836
23837 fi
23838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23839 $as_echo "$gl_cv_time_r_posix" >&6; }
23840 if test $gl_cv_time_r_posix = yes; then
23841 REPLACE_LOCALTIME_R=0
23842 else
23843 REPLACE_LOCALTIME_R=1
23844 fi
23845 else
23846 HAVE_LOCALTIME_R=0
23847 fi
23848
23849 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23850
23851
23852
23853
23854
23855
23856
23857
23858 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23859
23860
23861 :
23862
23863 fi
23864
23865
23866
23867
23868
23869 GNULIB_TIME_R=1
23870
23871
23872
23873
23874
23875
23876
23877
23878
23879
23880 LIB_TIMER_TIME=
23881
23882 gl_saved_libs=$LIBS
23883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
23884 $as_echo_n "checking for library containing timer_settime... " >&6; }
23885 if test "${ac_cv_search_timer_settime+set}" = set; then :
23886 $as_echo_n "(cached) " >&6
23887 else
23888 ac_func_search_save_LIBS=$LIBS
23889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23890 /* end confdefs.h. */
23891
23892 /* Override any GCC internal prototype to avoid an error.
23893 Use char because int might match the return type of a GCC
23894 builtin and then its argument prototype would still apply. */
23895 #ifdef __cplusplus
23896 extern "C"
23897 #endif
23898 char timer_settime ();
23899 int
23900 main ()
23901 {
23902 return timer_settime ();
23903 ;
23904 return 0;
23905 }
23906 _ACEOF
23907 for ac_lib in '' rt posix4; do
23908 if test -z "$ac_lib"; then
23909 ac_res="none required"
23910 else
23911 ac_res=-l$ac_lib
23912 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23913 fi
23914 if ac_fn_c_try_link "$LINENO"; then :
23915 ac_cv_search_timer_settime=$ac_res
23916 fi
23917 rm -f core conftest.err conftest.$ac_objext \
23918 conftest$ac_exeext
23919 if test "${ac_cv_search_timer_settime+set}" = set; then :
23920 break
23921 fi
23922 done
23923 if test "${ac_cv_search_timer_settime+set}" = set; then :
23924
23925 else
23926 ac_cv_search_timer_settime=no
23927 fi
23928 rm conftest.$ac_ext
23929 LIBS=$ac_func_search_save_LIBS
23930 fi
23931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
23932 $as_echo "$ac_cv_search_timer_settime" >&6; }
23933 ac_res=$ac_cv_search_timer_settime
23934 if test "$ac_res" != no; then :
23935 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23936 test "$ac_cv_search_timer_settime" = "none required" ||
23937 LIB_TIMER_TIME=$ac_cv_search_timer_settime
23938 fi
23939
23940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23941 /* end confdefs.h. */
23942
23943 #include <features.h>
23944 #ifdef __GNU_LIBRARY__
23945 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
23946 && !defined __UCLIBC__
23947 Thread emulation available
23948 #endif
23949 #endif
23950
23951 _ACEOF
23952 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23953 $EGREP "Thread" >/dev/null 2>&1; then :
23954 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
23955 fi
23956 rm -f conftest*
23957
23958 for ac_func in timer_settime
23959 do :
23960 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
23961 if test "x$ac_cv_func_timer_settime" = x""yes; then :
23962 cat >>confdefs.h <<_ACEOF
23963 #define HAVE_TIMER_SETTIME 1
23964 _ACEOF
23965
23966 fi
23967 done
23968
23969 LIBS=$gl_saved_libs
23970
23971 :
23972
23973
23974
23975
23976
23977
23978
23979
23980
23981
23982
23983
23984
23985 if test $gl_cv_have_include_next = yes; then
23986 gl_cv_next_unistd_h='<'unistd.h'>'
23987 else
23988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23989 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23990 if test "${gl_cv_next_unistd_h+set}" = set; then :
23991 $as_echo_n "(cached) " >&6
23992 else
23993
23994 if test $ac_cv_header_unistd_h = yes; then
23995
23996
23997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23998 /* end confdefs.h. */
23999 #include <unistd.h>
24000
24001 _ACEOF
24002 case "$host_os" in
24003 aix*) gl_absname_cpp="$ac_cpp -C" ;;
24004 *) gl_absname_cpp="$ac_cpp" ;;
24005 esac
24006
24007 case "$host_os" in
24008 mingw*)
24009 gl_dirsep_regex='[/\\]'
24010 ;;
24011 *)
24012 gl_dirsep_regex='\/'
24013 ;;
24014 esac
24015 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
24016
24017 gl_header_literal_regex=`echo 'unistd.h' \
24018 | sed -e "$gl_make_literal_regex_sed"`
24019 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
24020 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
24021 s|^/[^/]|//&|
24022 p
24023 q
24024 }'
24025 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
24026 sed -n "$gl_absolute_header_sed"`'"'
24027 else
24028 gl_cv_next_unistd_h='<'unistd.h'>'
24029 fi
24030
24031
24032 fi
24033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
24034 $as_echo "$gl_cv_next_unistd_h" >&6; }
24035 fi
24036 NEXT_UNISTD_H=$gl_cv_next_unistd_h
24037
24038 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
24039 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
24040 gl_next_as_first_directive='<'unistd.h'>'
24041 else
24042 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
24043 gl_next_as_first_directive=$gl_cv_next_unistd_h
24044 fi
24045 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
24046
24047
24048
24049
24050 if test $ac_cv_header_unistd_h = yes; then
24051 HAVE_UNISTD_H=1
24052 else
24053 HAVE_UNISTD_H=0
24054 fi
24055
24056
24057
24058
24059
24060
24061
24062
24063
24064
24065
24066
24067
24068
24069 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
24070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
24071 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
24072 if test "${gl_cv_func_futimesat_works+set}" = set; then :
24073 $as_echo_n "(cached) " >&6
24074 else
24075 touch conftest.file
24076 if test "$cross_compiling" = yes; then :
24077 case "$host_os" in
24078 # Guess yes on glibc systems.
24079 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
24080 # If we don't know, assume the worst.
24081 *) gl_cv_func_futimesat_works="guessing no" ;;
24082 esac
24083
24084 else
24085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24086 /* end confdefs.h. */
24087
24088 #include <stddef.h>
24089 #include <sys/times.h>
24090 #include <fcntl.h>
24091
24092 int
24093 main ()
24094 {
24095 int fd = open ("conftest.file", O_RDWR);
24096 if (fd < 0) return 1;
24097 if (futimesat (fd, NULL, NULL)) return 2;
24098
24099 ;
24100 return 0;
24101 }
24102 _ACEOF
24103 if ac_fn_c_try_run "$LINENO"; then :
24104 gl_cv_func_futimesat_works=yes
24105 else
24106 gl_cv_func_futimesat_works=no
24107 fi
24108 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24109 conftest.$ac_objext conftest.beam conftest.$ac_ext
24110 fi
24111
24112 rm -f conftest.file
24113 fi
24114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
24115 $as_echo "$gl_cv_func_futimesat_works" >&6; }
24116 case "$gl_cv_func_futimesat_works" in
24117 *yes) ;;
24118 *)
24119
24120 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
24121
24122 ;;
24123 esac
24124 fi
24125
24126 gl_gnulib_enabled_dosname=false
24127 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
24128 gl_gnulib_enabled_pathmax=false
24129 gl_gnulib_enabled_stat=false
24130 gl_gnulib_enabled_strtoll=false
24131 gl_gnulib_enabled_strtoull=false
24132 gl_gnulib_enabled_verify=false
24133 func_gl_gnulib_m4code_dosname ()
24134 {
24135 if ! $gl_gnulib_enabled_dosname; then
24136 gl_gnulib_enabled_dosname=true
24137 fi
24138 }
24139 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
24140 {
24141 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
24142
24143
24144 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
24145 fi
24146 }
24147 func_gl_gnulib_m4code_pathmax ()
24148 {
24149 if ! $gl_gnulib_enabled_pathmax; then
24150
24151
24152
24153 gl_gnulib_enabled_pathmax=true
24154 fi
24155 }
24156 func_gl_gnulib_m4code_stat ()
24157 {
24158 if ! $gl_gnulib_enabled_stat; then
24159
24160
24161
24162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
24163 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
24164 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
24165 $as_echo_n "(cached) " >&6
24166 else
24167 if test "$cross_compiling" = yes; then :
24168 case $host_os in
24169 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
24170 *) gl_cv_func_stat_dir_slash="guessing yes";;
24171 esac
24172 else
24173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24174 /* end confdefs.h. */
24175 #include <sys/stat.h>
24176
24177 int
24178 main ()
24179 {
24180 struct stat st; return stat (".", &st) != stat ("./", &st);
24181 ;
24182 return 0;
24183 }
24184 _ACEOF
24185 if ac_fn_c_try_run "$LINENO"; then :
24186 gl_cv_func_stat_dir_slash=yes
24187 else
24188 gl_cv_func_stat_dir_slash=no
24189 fi
24190 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24191 conftest.$ac_objext conftest.beam conftest.$ac_ext
24192 fi
24193
24194 fi
24195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
24196 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
24197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
24198 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
24199 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
24200 $as_echo_n "(cached) " >&6
24201 else
24202 touch conftest.tmp
24203 # Assume that if we have lstat, we can also check symlinks.
24204 if test $ac_cv_func_lstat = yes; then
24205 ln -s conftest.tmp conftest.lnk
24206 fi
24207 if test "$cross_compiling" = yes; then :
24208 case "$host_os" in
24209 # Guess yes on glibc systems.
24210 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
24211 # If we don't know, assume the worst.
24212 *) gl_cv_func_stat_file_slash="guessing no" ;;
24213 esac
24214
24215 else
24216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24217 /* end confdefs.h. */
24218 #include <sys/stat.h>
24219
24220 int
24221 main ()
24222 {
24223 int result = 0;
24224 struct stat st;
24225 if (!stat ("conftest.tmp/", &st))
24226 result |= 1;
24227 #if HAVE_LSTAT
24228 if (!stat ("conftest.lnk/", &st))
24229 result |= 2;
24230 #endif
24231 return result;
24232
24233 ;
24234 return 0;
24235 }
24236 _ACEOF
24237 if ac_fn_c_try_run "$LINENO"; then :
24238 gl_cv_func_stat_file_slash=yes
24239 else
24240 gl_cv_func_stat_file_slash=no
24241 fi
24242 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24243 conftest.$ac_objext conftest.beam conftest.$ac_ext
24244 fi
24245
24246 rm -f conftest.tmp conftest.lnk
24247 fi
24248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
24249 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
24250 case $gl_cv_func_stat_dir_slash in
24251 *no) REPLACE_STAT=1
24252
24253 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
24254 ;;
24255 esac
24256 case $gl_cv_func_stat_file_slash in
24257 *no) REPLACE_STAT=1
24258
24259 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
24260 ;;
24261 esac
24262
24263 if test $REPLACE_STAT = 1; then
24264
24265
24266
24267
24268
24269
24270
24271
24272 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
24273
24274
24275
24276 :
24277
24278 fi
24279
24280
24281
24282
24283
24284 GNULIB_STAT=1
24285
24286
24287
24288
24289
24290 gl_gnulib_enabled_stat=true
24291 if test $REPLACE_STAT = 1; then
24292 func_gl_gnulib_m4code_dosname
24293 fi
24294 if test $REPLACE_STAT = 1; then
24295 func_gl_gnulib_m4code_pathmax
24296 fi
24297 if test $REPLACE_STAT = 1; then
24298 func_gl_gnulib_m4code_verify
24299 fi
24300 fi
24301 }
24302 func_gl_gnulib_m4code_strtoll ()
24303 {
24304 if ! $gl_gnulib_enabled_strtoll; then
24305
24306
24307
24308 if test "$ac_cv_type_long_long_int" = yes; then
24309 for ac_func in strtoll
24310 do :
24311 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
24312 if test "x$ac_cv_func_strtoll" = x""yes; then :
24313 cat >>confdefs.h <<_ACEOF
24314 #define HAVE_STRTOLL 1
24315 _ACEOF
24316
24317 fi
24318 done
24319
24320 if test $ac_cv_func_strtoll = no; then
24321 HAVE_STRTOLL=0
24322 fi
24323 fi
24324
24325 if test $HAVE_STRTOLL = 0; then
24326
24327
24328
24329
24330
24331
24332
24333
24334 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
24335
24336
24337 :
24338
24339 fi
24340
24341
24342
24343
24344
24345 GNULIB_STRTOLL=1
24346
24347
24348
24349
24350
24351 gl_gnulib_enabled_strtoll=true
24352 fi
24353 }
24354 func_gl_gnulib_m4code_strtoull ()
24355 {
24356 if ! $gl_gnulib_enabled_strtoull; then
24357
24358
24359
24360 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
24361 for ac_func in strtoull
24362 do :
24363 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
24364 if test "x$ac_cv_func_strtoull" = x""yes; then :
24365 cat >>confdefs.h <<_ACEOF
24366 #define HAVE_STRTOULL 1
24367 _ACEOF
24368
24369 fi
24370 done
24371
24372 if test $ac_cv_func_strtoull = no; then
24373 HAVE_STRTOULL=0
24374 fi
24375 fi
24376
24377 if test $HAVE_STRTOULL = 0; then
24378
24379
24380
24381
24382
24383
24384
24385
24386 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
24387
24388
24389 :
24390
24391 fi
24392
24393
24394
24395
24396
24397 GNULIB_STRTOULL=1
24398
24399
24400
24401
24402
24403 gl_gnulib_enabled_strtoull=true
24404 fi
24405 }
24406 func_gl_gnulib_m4code_verify ()
24407 {
24408 if ! $gl_gnulib_enabled_verify; then
24409 gl_gnulib_enabled_verify=true
24410 fi
24411 }
24412 if test $REPLACE_GETOPT = 1; then
24413 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
24414 fi
24415 if test $REPLACE_LSTAT = 1; then
24416 func_gl_gnulib_m4code_dosname
24417 fi
24418 if test $REPLACE_LSTAT = 1; then
24419 func_gl_gnulib_m4code_stat
24420 fi
24421 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
24422 func_gl_gnulib_m4code_stat
24423 fi
24424 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
24425 func_gl_gnulib_m4code_strtoll
24426 fi
24427 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
24428 func_gl_gnulib_m4code_verify
24429 fi
24430 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
24431 func_gl_gnulib_m4code_strtoull
24432 fi
24433 if test $ac_cv_func_strtoumax = no; then
24434 func_gl_gnulib_m4code_verify
24435 fi
24436
24437 if $gl_gnulib_enabled_dosname; then
24438 gl_GNULIB_ENABLED_dosname_TRUE=
24439 gl_GNULIB_ENABLED_dosname_FALSE='#'
24440 else
24441 gl_GNULIB_ENABLED_dosname_TRUE='#'
24442 gl_GNULIB_ENABLED_dosname_FALSE=
24443 fi
24444
24445 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
24446 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
24447 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
24448 else
24449 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
24450 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
24451 fi
24452
24453 if $gl_gnulib_enabled_pathmax; then
24454 gl_GNULIB_ENABLED_pathmax_TRUE=
24455 gl_GNULIB_ENABLED_pathmax_FALSE='#'
24456 else
24457 gl_GNULIB_ENABLED_pathmax_TRUE='#'
24458 gl_GNULIB_ENABLED_pathmax_FALSE=
24459 fi
24460
24461 if $gl_gnulib_enabled_stat; then
24462 gl_GNULIB_ENABLED_stat_TRUE=
24463 gl_GNULIB_ENABLED_stat_FALSE='#'
24464 else
24465 gl_GNULIB_ENABLED_stat_TRUE='#'
24466 gl_GNULIB_ENABLED_stat_FALSE=
24467 fi
24468
24469 if $gl_gnulib_enabled_strtoll; then
24470 gl_GNULIB_ENABLED_strtoll_TRUE=
24471 gl_GNULIB_ENABLED_strtoll_FALSE='#'
24472 else
24473 gl_GNULIB_ENABLED_strtoll_TRUE='#'
24474 gl_GNULIB_ENABLED_strtoll_FALSE=
24475 fi
24476
24477 if $gl_gnulib_enabled_strtoull; then
24478 gl_GNULIB_ENABLED_strtoull_TRUE=
24479 gl_GNULIB_ENABLED_strtoull_FALSE='#'
24480 else
24481 gl_GNULIB_ENABLED_strtoull_TRUE='#'
24482 gl_GNULIB_ENABLED_strtoull_FALSE=
24483 fi
24484
24485 if $gl_gnulib_enabled_verify; then
24486 gl_GNULIB_ENABLED_verify_TRUE=
24487 gl_GNULIB_ENABLED_verify_FALSE='#'
24488 else
24489 gl_GNULIB_ENABLED_verify_TRUE='#'
24490 gl_GNULIB_ENABLED_verify_FALSE=
24491 fi
24492
24493 # End of code from modules
24494
24495
24496
24497
24498
24499
24500
24501
24502
24503 gltests_libdeps=
24504 gltests_ltlibdeps=
24505
24506
24507
24508
24509
24510
24511
24512
24513
24514 gl_source_base='tests'
24515 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
24516
24517 gl_module_indicator_condition=$gltests_WITNESS
24518
24519
24520
24521
24522
24523
24524
24525
24526
24527
24528 LIBGNU_LIBDEPS="$gl_libdeps"
24529
24530 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
24531
24532
24533 CFLAGS=$SAVE_CFLAGS
24534 LIBS=$SAVE_LIBS
24535
24536 case "$opsys" in
24537 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
24538
24539 darwin)
24540 ## The -headerpad option tells ld (see man page) to leave room at the
24541 ## end of the header for adding load commands. Needed for dumping.
24542 ## 0x690 is the total size of 30 segment load commands (at 56
24543 ## each); under Cocoa 31 commands are required.
24544 if test "$HAVE_NS" = "yes"; then
24545 libs_nsgui="-framework AppKit"
24546 headerpad_extra=6C8
24547 else
24548 libs_nsgui=
24549 headerpad_extra=690
24550 fi
24551 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
24552
24553 ## This is here because src/Makefile.in did some extra fiddling around
24554 ## with LD_SWITCH_SYSTEM. The cpp logic was:
24555 ## #ifndef LD_SWITCH_SYSTEM
24556 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
24557 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
24558 ## not using gcc, darwin.
24559 ## Because this was done in src/Makefile.in, the resulting part of
24560 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
24561 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
24562 ## rather than LD_SWITCH_SYSTEM.
24563 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
24564 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
24565 ;;
24566
24567 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
24568 ## find X at run-time.
24569 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
24570 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
24571 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
24572 ## had different values in configure (in ac_link) and src/Makefile.in.
24573 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
24574 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
24575
24576 *) LD_SWITCH_SYSTEM_TEMACS= ;;
24577 esac
24578
24579 if test "$NS_IMPL_GNUSTEP" = "yes"; then
24580 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
24581 fi
24582
24583
24584
24585
24586 LD_FIRSTFLAG=
24587 ORDINARY_LINK=
24588 case "$opsys" in
24589 ## gnu: GNU needs its own crt0.
24590 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
24591
24592 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
24593 ## library search parth, i.e. it won't search /usr/lib for libc and
24594 ## friends. Using -nostartfiles instead avoids this problem, and
24595 ## will also work on earlier NetBSD releases.
24596 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
24597
24598 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
24599 ## MkLinux/LinuxPPC needs this.
24600 ## s390x-* only supports opsys = gnu-linux so it can be added here.
24601 gnu-*)
24602 case "$canonical" in
24603 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
24604 esac
24605 ;;
24606 esac
24607
24608
24609 if test "x$ORDINARY_LINK" = "xyes"; then
24610
24611 LD_FIRSTFLAG=""
24612
24613 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
24614
24615
24616 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
24617 ## freebsd, gnu-* not on powerpc*|s390x*.
24618 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
24619
24620 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
24621 ## places that are difficult to figure out at make time. Fortunately,
24622 ## these same versions allow you to pass arbitrary flags on to the
24623 ## linker, so there is no reason not to use it as a linker.
24624 ##
24625 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
24626 ## searching for libraries in its internal directories, so we have to
24627 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
24628 LD_FIRSTFLAG="-nostdlib"
24629 fi
24630
24631 ## FIXME? What setting of EDIT_LDFLAGS should this have?
24632 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
24633
24634
24635
24636
24637 ## FIXME? The logic here is not precisely the same as that above.
24638 ## There is no check here for a pre-defined LD_FIRSTFLAG.
24639 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
24640 LIB_GCC=
24641 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
24642
24643 case "$opsys" in
24644 freebsd|netbsd|openbsd) LIB_GCC= ;;
24645
24646 gnu-*)
24647 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
24648 ## build on ARM EABI under GNU/Linux. (Bug#5518)
24649 case $host_cpu in
24650 arm*)
24651 LIB_GCC="-lgcc_s"
24652 ;;
24653 *)
24654 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
24655 ## immediately undefine it again and redefine it to empty.
24656 ## Was the C_SWITCH_X_SITE part really necessary?
24657 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
24658 LIB_GCC=
24659 ;;
24660 esac
24661 ;;
24662
24663 ## Ask GCC where to find libgcc.a.
24664 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
24665 esac
24666 fi
24667
24668 ## Common for all window systems
24669 if test "$window_system" != "none"; then
24670
24671 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
24672
24673
24674 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
24675
24676 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
24677 fi
24678
24679
24680
24681
24682
24683 #### Report on what we decided to do.
24684 #### Report GTK as a toolkit, even if it doesn't use Xt.
24685 #### It makes printing result more understandable as using GTK sets
24686 #### toolkit_scroll_bars to yes by default.
24687 if test "${HAVE_GTK}" = "yes"; then
24688 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
24689 fi
24690
24691 echo "
24692 Configured for \`${canonical}'.
24693
24694 Where should the build process find the source code? ${srcdir}
24695 What compiler should emacs be built with? ${CC} ${CFLAGS}
24696 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
24697 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
24698 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
24699 What window system should Emacs use? ${window_system}
24700 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
24701
24702 if test -n "${x_includes}"; then
24703 echo " Where do we find X Windows header files? ${x_includes}"
24704 else
24705 echo " Where do we find X Windows header files? Standard dirs"
24706 fi
24707 if test -n "${x_libraries}"; then
24708 echo " Where do we find X Windows libraries? ${x_libraries}"
24709 else
24710 echo " Where do we find X Windows libraries? Standard dirs"
24711 fi
24712
24713 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
24714 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
24715 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
24716 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
24717 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
24718 echo " Does Emacs use -lpng? ${HAVE_PNG}"
24719 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
24720 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
24721
24722 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
24723 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
24724 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
24725 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
24726 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
24727 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
24728 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
24729
24730 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
24731 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
24732 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
24733 echo " Does Emacs use -lxft? ${HAVE_XFT}"
24734
24735 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
24736 echo
24737
24738 if test -n "${EMACSDATA}"; then
24739 echo " Environment variable EMACSDATA set to: $EMACSDATA"
24740 fi
24741 if test -n "${EMACSDOC}"; then
24742 echo " Environment variable EMACSDOC set to: $EMACSDOC"
24743 fi
24744
24745 echo
24746
24747 if test "$HAVE_NS" = "yes"; then
24748 echo
24749 echo "You must run \"${MAKE-make} install\" in order to test the built application.
24750 The installed application will go to nextstep/Emacs.app and can be
24751 run or moved from there."
24752 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
24753 echo "The application will be fully self-contained."
24754 else
24755 echo "The lisp resources for the application will be installed under ${prefix}.
24756 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
24757 to run if these resources are not installed."
24758 fi
24759 echo
24760 fi
24761
24762 if test "${opsys}" = "cygwin"; then
24763 case `uname -r` in
24764 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
24765 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
24766 echo
24767 ;;
24768 esac
24769 fi
24770
24771 # Remove any trailing slashes in these variables.
24772 test "${prefix}" != NONE &&
24773 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
24774 test "${exec_prefix}" != NONE &&
24775 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
24776
24777 if test "$HAVE_NS" = "yes"; then
24778 if test "$NS_IMPL_GNUSTEP" = yes; then
24779 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"
24780
24781 else
24782 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"
24783
24784 fi
24785 fi
24786
24787 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"
24788
24789 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"
24790
24791
24792 opt_makefile=test/automated/Makefile
24793
24794 if test -f $srcdir/${opt_makefile}.in; then
24795 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24796 ac_config_files="$ac_config_files test/automated/Makefile"
24797
24798 fi
24799
24800
24801 opt_makefile=admin/unidata/Makefile
24802
24803 if test -f $srcdir/${opt_makefile}.in; then
24804 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24805 ac_config_files="$ac_config_files admin/unidata/Makefile"
24806
24807 fi
24808
24809
24810 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
24811
24812
24813
24814 ac_config_commands="$ac_config_commands mkdirs"
24815
24816
24817 ac_config_commands="$ac_config_commands epaths"
24818
24819
24820 ac_config_commands="$ac_config_commands gdbinit"
24821
24822
24823 cat >confcache <<\_ACEOF
24824 # This file is a shell script that caches the results of configure
24825 # tests run on this system so they can be shared between configure
24826 # scripts and configure runs, see configure's option --config-cache.
24827 # It is not useful on other systems. If it contains results you don't
24828 # want to keep, you may remove or edit it.
24829 #
24830 # config.status only pays attention to the cache file if you give it
24831 # the --recheck option to rerun configure.
24832 #
24833 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24834 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24835 # following values.
24836
24837 _ACEOF
24838
24839 # The following way of writing the cache mishandles newlines in values,
24840 # but we know of no workaround that is simple, portable, and efficient.
24841 # So, we kill variables containing newlines.
24842 # Ultrix sh set writes to stderr and can't be redirected directly,
24843 # and sets the high bit in the cache file unless we assign to the vars.
24844 (
24845 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24846 eval ac_val=\$$ac_var
24847 case $ac_val in #(
24848 *${as_nl}*)
24849 case $ac_var in #(
24850 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24851 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24852 esac
24853 case $ac_var in #(
24854 _ | IFS | as_nl) ;; #(
24855 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24856 *) { eval $ac_var=; unset $ac_var;} ;;
24857 esac ;;
24858 esac
24859 done
24860
24861 (set) 2>&1 |
24862 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24863 *${as_nl}ac_space=\ *)
24864 # `set' does not quote correctly, so add quotes: double-quote
24865 # substitution turns \\\\ into \\, and sed turns \\ into \.
24866 sed -n \
24867 "s/'/'\\\\''/g;
24868 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24869 ;; #(
24870 *)
24871 # `set' quotes correctly as required by POSIX, so do not add quotes.
24872 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24873 ;;
24874 esac |
24875 sort
24876 ) |
24877 sed '
24878 /^ac_cv_env_/b end
24879 t clear
24880 :clear
24881 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24882 t end
24883 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24884 :end' >>confcache
24885 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24886 if test -w "$cache_file"; then
24887 test "x$cache_file" != "x/dev/null" &&
24888 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24889 $as_echo "$as_me: updating cache $cache_file" >&6;}
24890 cat confcache >$cache_file
24891 else
24892 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24893 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24894 fi
24895 fi
24896 rm -f confcache
24897
24898 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24899 # Let make expand exec_prefix.
24900 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24901
24902 DEFS=-DHAVE_CONFIG_H
24903
24904 ac_libobjs=
24905 ac_ltlibobjs=
24906 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24907 # 1. Remove the extension, and $U if already installed.
24908 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24909 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24910 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24911 # will be set to the directory where LIBOBJS objects are built.
24912 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24913 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24914 done
24915 LIBOBJS=$ac_libobjs
24916
24917 LTLIBOBJS=$ac_ltlibobjs
24918
24919
24920 if test -n "$EXEEXT"; then
24921 am__EXEEXT_TRUE=
24922 am__EXEEXT_FALSE='#'
24923 else
24924 am__EXEEXT_TRUE='#'
24925 am__EXEEXT_FALSE=
24926 fi
24927
24928 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24929 as_fn_error "conditional \"AMDEP\" was never defined.
24930 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24931 fi
24932 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24933 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24934 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24935 fi
24936 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24937 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24938 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24939 fi
24940 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24941 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24942 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24943 fi
24944
24945 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
24946 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
24947 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24948 fi
24949 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24950 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24951 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24952 fi
24953 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
24954 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
24955 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24956 fi
24957 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
24958 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
24959 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24960 fi
24961 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24962 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24963 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24964 fi
24965 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24966 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24967 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24968 fi
24969 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
24970 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
24971 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24972 fi
24973 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
24974 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
24975 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24976 fi
24977 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
24978 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
24979 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24980 fi
24981 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
24982 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
24983 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24984 fi
24985 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
24986 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
24987 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24988 fi
24989 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
24990 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
24991 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24992 fi
24993 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
24994 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
24995 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24996 fi
24997
24998 gl_libobjs=
24999 gl_ltlibobjs=
25000 if test -n "$gl_LIBOBJS"; then
25001 # Remove the extension.
25002 sed_drop_objext='s/\.o$//;s/\.obj$//'
25003 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25004 gl_libobjs="$gl_libobjs $i.$ac_objext"
25005 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
25006 done
25007 fi
25008 gl_LIBOBJS=$gl_libobjs
25009
25010 gl_LTLIBOBJS=$gl_ltlibobjs
25011
25012
25013
25014 gltests_libobjs=
25015 gltests_ltlibobjs=
25016 if test -n "$gltests_LIBOBJS"; then
25017 # Remove the extension.
25018 sed_drop_objext='s/\.o$//;s/\.obj$//'
25019 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
25020 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
25021 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
25022 done
25023 fi
25024 gltests_LIBOBJS=$gltests_libobjs
25025
25026 gltests_LTLIBOBJS=$gltests_ltlibobjs
25027
25028
25029
25030 : ${CONFIG_STATUS=./config.status}
25031 ac_write_fail=0
25032 ac_clean_files_save=$ac_clean_files
25033 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
25034 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
25035 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
25036 as_write_fail=0
25037 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
25038 #! $SHELL
25039 # Generated by $as_me.
25040 # Run this file to recreate the current configuration.
25041 # Compiler output produced by configure, useful for debugging
25042 # configure, is in config.log if it exists.
25043
25044 debug=false
25045 ac_cs_recheck=false
25046 ac_cs_silent=false
25047
25048 SHELL=\${CONFIG_SHELL-$SHELL}
25049 export SHELL
25050 _ASEOF
25051 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
25052 ## -------------------- ##
25053 ## M4sh Initialization. ##
25054 ## -------------------- ##
25055
25056 # Be more Bourne compatible
25057 DUALCASE=1; export DUALCASE # for MKS sh
25058 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
25059 emulate sh
25060 NULLCMD=:
25061 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25062 # is contrary to our usage. Disable this feature.
25063 alias -g '${1+"$@"}'='"$@"'
25064 setopt NO_GLOB_SUBST
25065 else
25066 case `(set -o) 2>/dev/null` in #(
25067 *posix*) :
25068 set -o posix ;; #(
25069 *) :
25070 ;;
25071 esac
25072 fi
25073
25074
25075 as_nl='
25076 '
25077 export as_nl
25078 # Printing a long string crashes Solaris 7 /usr/bin/printf.
25079 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
25080 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
25081 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
25082 # Prefer a ksh shell builtin over an external printf program on Solaris,
25083 # but without wasting forks for bash or zsh.
25084 if test -z "$BASH_VERSION$ZSH_VERSION" \
25085 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
25086 as_echo='print -r --'
25087 as_echo_n='print -rn --'
25088 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
25089 as_echo='printf %s\n'
25090 as_echo_n='printf %s'
25091 else
25092 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
25093 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
25094 as_echo_n='/usr/ucb/echo -n'
25095 else
25096 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
25097 as_echo_n_body='eval
25098 arg=$1;
25099 case $arg in #(
25100 *"$as_nl"*)
25101 expr "X$arg" : "X\\(.*\\)$as_nl";
25102 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
25103 esac;
25104 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
25105 '
25106 export as_echo_n_body
25107 as_echo_n='sh -c $as_echo_n_body as_echo'
25108 fi
25109 export as_echo_body
25110 as_echo='sh -c $as_echo_body as_echo'
25111 fi
25112
25113 # The user is always right.
25114 if test "${PATH_SEPARATOR+set}" != set; then
25115 PATH_SEPARATOR=:
25116 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
25117 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
25118 PATH_SEPARATOR=';'
25119 }
25120 fi
25121
25122
25123 # IFS
25124 # We need space, tab and new line, in precisely that order. Quoting is
25125 # there to prevent editors from complaining about space-tab.
25126 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
25127 # splitting by setting IFS to empty value.)
25128 IFS=" "" $as_nl"
25129
25130 # Find who we are. Look in the path if we contain no directory separator.
25131 case $0 in #((
25132 *[\\/]* ) as_myself=$0 ;;
25133 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25134 for as_dir in $PATH
25135 do
25136 IFS=$as_save_IFS
25137 test -z "$as_dir" && as_dir=.
25138 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
25139 done
25140 IFS=$as_save_IFS
25141
25142 ;;
25143 esac
25144 # We did not find ourselves, most probably we were run as `sh COMMAND'
25145 # in which case we are not to be found in the path.
25146 if test "x$as_myself" = x; then
25147 as_myself=$0
25148 fi
25149 if test ! -f "$as_myself"; then
25150 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
25151 exit 1
25152 fi
25153
25154 # Unset variables that we do not need and which cause bugs (e.g. in
25155 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
25156 # suppresses any "Segmentation fault" message there. '((' could
25157 # trigger a bug in pdksh 5.2.14.
25158 for as_var in BASH_ENV ENV MAIL MAILPATH
25159 do eval test x\${$as_var+set} = xset \
25160 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
25161 done
25162 PS1='$ '
25163 PS2='> '
25164 PS4='+ '
25165
25166 # NLS nuisances.
25167 LC_ALL=C
25168 export LC_ALL
25169 LANGUAGE=C
25170 export LANGUAGE
25171
25172 # CDPATH.
25173 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
25174
25175
25176 # as_fn_error ERROR [LINENO LOG_FD]
25177 # ---------------------------------
25178 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
25179 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
25180 # script with status $?, using 1 if that was 0.
25181 as_fn_error ()
25182 {
25183 as_status=$?; test $as_status -eq 0 && as_status=1
25184 if test "$3"; then
25185 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
25186 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
25187 fi
25188 $as_echo "$as_me: error: $1" >&2
25189 as_fn_exit $as_status
25190 } # as_fn_error
25191
25192
25193 # as_fn_set_status STATUS
25194 # -----------------------
25195 # Set $? to STATUS, without forking.
25196 as_fn_set_status ()
25197 {
25198 return $1
25199 } # as_fn_set_status
25200
25201 # as_fn_exit STATUS
25202 # -----------------
25203 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
25204 as_fn_exit ()
25205 {
25206 set +e
25207 as_fn_set_status $1
25208 exit $1
25209 } # as_fn_exit
25210
25211 # as_fn_unset VAR
25212 # ---------------
25213 # Portably unset VAR.
25214 as_fn_unset ()
25215 {
25216 { eval $1=; unset $1;}
25217 }
25218 as_unset=as_fn_unset
25219 # as_fn_append VAR VALUE
25220 # ----------------------
25221 # Append the text in VALUE to the end of the definition contained in VAR. Take
25222 # advantage of any shell optimizations that allow amortized linear growth over
25223 # repeated appends, instead of the typical quadratic growth present in naive
25224 # implementations.
25225 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
25226 eval 'as_fn_append ()
25227 {
25228 eval $1+=\$2
25229 }'
25230 else
25231 as_fn_append ()
25232 {
25233 eval $1=\$$1\$2
25234 }
25235 fi # as_fn_append
25236
25237 # as_fn_arith ARG...
25238 # ------------------
25239 # Perform arithmetic evaluation on the ARGs, and store the result in the
25240 # global $as_val. Take advantage of shells that can avoid forks. The arguments
25241 # must be portable across $(()) and expr.
25242 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
25243 eval 'as_fn_arith ()
25244 {
25245 as_val=$(( $* ))
25246 }'
25247 else
25248 as_fn_arith ()
25249 {
25250 as_val=`expr "$@" || test $? -eq 1`
25251 }
25252 fi # as_fn_arith
25253
25254
25255 if expr a : '\(a\)' >/dev/null 2>&1 &&
25256 test "X`expr 00001 : '.*\(...\)'`" = X001; then
25257 as_expr=expr
25258 else
25259 as_expr=false
25260 fi
25261
25262 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
25263 as_basename=basename
25264 else
25265 as_basename=false
25266 fi
25267
25268 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
25269 as_dirname=dirname
25270 else
25271 as_dirname=false
25272 fi
25273
25274 as_me=`$as_basename -- "$0" ||
25275 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
25276 X"$0" : 'X\(//\)$' \| \
25277 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
25278 $as_echo X/"$0" |
25279 sed '/^.*\/\([^/][^/]*\)\/*$/{
25280 s//\1/
25281 q
25282 }
25283 /^X\/\(\/\/\)$/{
25284 s//\1/
25285 q
25286 }
25287 /^X\/\(\/\).*/{
25288 s//\1/
25289 q
25290 }
25291 s/.*/./; q'`
25292
25293 # Avoid depending upon Character Ranges.
25294 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25295 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25296 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25297 as_cr_digits='0123456789'
25298 as_cr_alnum=$as_cr_Letters$as_cr_digits
25299
25300 ECHO_C= ECHO_N= ECHO_T=
25301 case `echo -n x` in #(((((
25302 -n*)
25303 case `echo 'xy\c'` in
25304 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
25305 xy) ECHO_C='\c';;
25306 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
25307 ECHO_T=' ';;
25308 esac;;
25309 *)
25310 ECHO_N='-n';;
25311 esac
25312
25313 rm -f conf$$ conf$$.exe conf$$.file
25314 if test -d conf$$.dir; then
25315 rm -f conf$$.dir/conf$$.file
25316 else
25317 rm -f conf$$.dir
25318 mkdir conf$$.dir 2>/dev/null
25319 fi
25320 if (echo >conf$$.file) 2>/dev/null; then
25321 if ln -s conf$$.file conf$$ 2>/dev/null; then
25322 as_ln_s='ln -s'
25323 # ... but there are two gotchas:
25324 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
25325 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
25326 # In both cases, we have to default to `cp -p'.
25327 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
25328 as_ln_s='cp -p'
25329 elif ln conf$$.file conf$$ 2>/dev/null; then
25330 as_ln_s=ln
25331 else
25332 as_ln_s='cp -p'
25333 fi
25334 else
25335 as_ln_s='cp -p'
25336 fi
25337 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
25338 rmdir conf$$.dir 2>/dev/null
25339
25340
25341 # as_fn_mkdir_p
25342 # -------------
25343 # Create "$as_dir" as a directory, including parents if necessary.
25344 as_fn_mkdir_p ()
25345 {
25346
25347 case $as_dir in #(
25348 -*) as_dir=./$as_dir;;
25349 esac
25350 test -d "$as_dir" || eval $as_mkdir_p || {
25351 as_dirs=
25352 while :; do
25353 case $as_dir in #(
25354 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
25355 *) as_qdir=$as_dir;;
25356 esac
25357 as_dirs="'$as_qdir' $as_dirs"
25358 as_dir=`$as_dirname -- "$as_dir" ||
25359 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25360 X"$as_dir" : 'X\(//\)[^/]' \| \
25361 X"$as_dir" : 'X\(//\)$' \| \
25362 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
25363 $as_echo X"$as_dir" |
25364 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25365 s//\1/
25366 q
25367 }
25368 /^X\(\/\/\)[^/].*/{
25369 s//\1/
25370 q
25371 }
25372 /^X\(\/\/\)$/{
25373 s//\1/
25374 q
25375 }
25376 /^X\(\/\).*/{
25377 s//\1/
25378 q
25379 }
25380 s/.*/./; q'`
25381 test -d "$as_dir" && break
25382 done
25383 test -z "$as_dirs" || eval "mkdir $as_dirs"
25384 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
25385
25386
25387 } # as_fn_mkdir_p
25388 if mkdir -p . 2>/dev/null; then
25389 as_mkdir_p='mkdir -p "$as_dir"'
25390 else
25391 test -d ./-p && rmdir ./-p
25392 as_mkdir_p=false
25393 fi
25394
25395 if test -x / >/dev/null 2>&1; then
25396 as_test_x='test -x'
25397 else
25398 if ls -dL / >/dev/null 2>&1; then
25399 as_ls_L_option=L
25400 else
25401 as_ls_L_option=
25402 fi
25403 as_test_x='
25404 eval sh -c '\''
25405 if test -d "$1"; then
25406 test -d "$1/.";
25407 else
25408 case $1 in #(
25409 -*)set "./$1";;
25410 esac;
25411 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
25412 ???[sx]*):;;*)false;;esac;fi
25413 '\'' sh
25414 '
25415 fi
25416 as_executable_p=$as_test_x
25417
25418 # Sed expression to map a string onto a valid CPP name.
25419 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
25420
25421 # Sed expression to map a string onto a valid variable name.
25422 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
25423
25424
25425 exec 6>&1
25426 ## ----------------------------------- ##
25427 ## Main body of $CONFIG_STATUS script. ##
25428 ## ----------------------------------- ##
25429 _ASEOF
25430 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
25431
25432 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25433 # Save the log message, to keep $0 and so on meaningful, and to
25434 # report actual input values of CONFIG_FILES etc. instead of their
25435 # values after options handling.
25436 ac_log="
25437 This file was extended by emacs $as_me 24.3.50, which was
25438 generated by GNU Autoconf 2.65. Invocation command line was
25439
25440 CONFIG_FILES = $CONFIG_FILES
25441 CONFIG_HEADERS = $CONFIG_HEADERS
25442 CONFIG_LINKS = $CONFIG_LINKS
25443 CONFIG_COMMANDS = $CONFIG_COMMANDS
25444 $ $0 $@
25445
25446 on `(hostname || uname -n) 2>/dev/null | sed 1q`
25447 "
25448
25449 _ACEOF
25450
25451 case $ac_config_files in *"
25452 "*) set x $ac_config_files; shift; ac_config_files=$*;;
25453 esac
25454
25455 case $ac_config_headers in *"
25456 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
25457 esac
25458
25459
25460 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25461 # Files that config.status was made for.
25462 config_files="$ac_config_files"
25463 config_headers="$ac_config_headers"
25464 config_commands="$ac_config_commands"
25465
25466 _ACEOF
25467
25468 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25469 ac_cs_usage="\
25470 \`$as_me' instantiates files and other configuration actions
25471 from templates according to the current configuration. Unless the files
25472 and actions are specified as TAGs, all are instantiated by default.
25473
25474 Usage: $0 [OPTION]... [TAG]...
25475
25476 -h, --help print this help, then exit
25477 -V, --version print version number and configuration settings, then exit
25478 --config print configuration, then exit
25479 -q, --quiet, --silent
25480 do not print progress messages
25481 -d, --debug don't remove temporary files
25482 --recheck update $as_me by reconfiguring in the same conditions
25483 --file=FILE[:TEMPLATE]
25484 instantiate the configuration file FILE
25485 --header=FILE[:TEMPLATE]
25486 instantiate the configuration header FILE
25487
25488 Configuration files:
25489 $config_files
25490
25491 Configuration headers:
25492 $config_headers
25493
25494 Configuration commands:
25495 $config_commands
25496
25497 Report bugs to the package provider."
25498
25499 _ACEOF
25500 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25501 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
25502 ac_cs_version="\\
25503 emacs config.status 24.3.50
25504 configured by $0, generated by GNU Autoconf 2.65,
25505 with options \\"\$ac_cs_config\\"
25506
25507 Copyright (C) 2009 Free Software Foundation, Inc.
25508 This config.status script is free software; the Free Software Foundation
25509 gives unlimited permission to copy, distribute and modify it."
25510
25511 ac_pwd='$ac_pwd'
25512 srcdir='$srcdir'
25513 INSTALL='$INSTALL'
25514 MKDIR_P='$MKDIR_P'
25515 AWK='$AWK'
25516 test -n "\$AWK" || AWK=awk
25517 _ACEOF
25518
25519 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25520 # The default lists apply if the user does not specify any file.
25521 ac_need_defaults=:
25522 while test $# != 0
25523 do
25524 case $1 in
25525 --*=*)
25526 ac_option=`expr "X$1" : 'X\([^=]*\)='`
25527 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
25528 ac_shift=:
25529 ;;
25530 *)
25531 ac_option=$1
25532 ac_optarg=$2
25533 ac_shift=shift
25534 ;;
25535 esac
25536
25537 case $ac_option in
25538 # Handling of the options.
25539 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25540 ac_cs_recheck=: ;;
25541 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
25542 $as_echo "$ac_cs_version"; exit ;;
25543 --config | --confi | --conf | --con | --co | --c )
25544 $as_echo "$ac_cs_config"; exit ;;
25545 --debug | --debu | --deb | --de | --d | -d )
25546 debug=: ;;
25547 --file | --fil | --fi | --f )
25548 $ac_shift
25549 case $ac_optarg in
25550 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25551 esac
25552 as_fn_append CONFIG_FILES " '$ac_optarg'"
25553 ac_need_defaults=false;;
25554 --header | --heade | --head | --hea )
25555 $ac_shift
25556 case $ac_optarg in
25557 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25558 esac
25559 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
25560 ac_need_defaults=false;;
25561 --he | --h)
25562 # Conflict between --help and --header
25563 as_fn_error "ambiguous option: \`$1'
25564 Try \`$0 --help' for more information.";;
25565 --help | --hel | -h )
25566 $as_echo "$ac_cs_usage"; exit ;;
25567 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25568 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25569 ac_cs_silent=: ;;
25570
25571 # This is an error.
25572 -*) as_fn_error "unrecognized option: \`$1'
25573 Try \`$0 --help' for more information." ;;
25574
25575 *) as_fn_append ac_config_targets " $1"
25576 ac_need_defaults=false ;;
25577
25578 esac
25579 shift
25580 done
25581
25582 ac_configure_extra_args=
25583
25584 if $ac_cs_silent; then
25585 exec 6>/dev/null
25586 ac_configure_extra_args="$ac_configure_extra_args --silent"
25587 fi
25588
25589 _ACEOF
25590 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25591 if \$ac_cs_recheck; then
25592 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
25593 shift
25594 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
25595 CONFIG_SHELL='$SHELL'
25596 export CONFIG_SHELL
25597 exec "\$@"
25598 fi
25599
25600 _ACEOF
25601 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25602 exec 5>>config.log
25603 {
25604 echo
25605 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25606 ## Running $as_me. ##
25607 _ASBOX
25608 $as_echo "$ac_log"
25609 } >&5
25610
25611 _ACEOF
25612 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25613 #
25614 # INIT-COMMANDS
25615 #
25616 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
25617 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
25618
25619 _ACEOF
25620
25621 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25622
25623 # Handling of arguments.
25624 for ac_config_target in $ac_config_targets
25625 do
25626 case $ac_config_target in
25627 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
25628 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25629 "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" ;;
25630 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
25631 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
25632 "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" ;;
25633 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25634 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
25635 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
25636 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
25637 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
25638 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
25639 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
25640 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
25641 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
25642 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
25643 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
25644 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
25645 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
25646 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
25647 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
25648 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
25649 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
25650 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
25651
25652 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25653 esac
25654 done
25655
25656
25657 # If the user did not use the arguments to specify the items to instantiate,
25658 # then the envvar interface is used. Set only those that are not.
25659 # We use the long form for the default assignment because of an extremely
25660 # bizarre bug on SunOS 4.1.3.
25661 if $ac_need_defaults; then
25662 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25663 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25664 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25665 fi
25666
25667 # Have a temporary directory for convenience. Make it in the build tree
25668 # simply because there is no reason against having it here, and in addition,
25669 # creating and moving files from /tmp can sometimes cause problems.
25670 # Hook for its removal unless debugging.
25671 # Note that there is a small window in which the directory will not be cleaned:
25672 # after its creation but before its name has been assigned to `$tmp'.
25673 $debug ||
25674 {
25675 tmp=
25676 trap 'exit_status=$?
25677 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25678 ' 0
25679 trap 'as_fn_exit 1' 1 2 13 15
25680 }
25681 # Create a (secure) tmp directory for tmp files.
25682
25683 {
25684 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25685 test -n "$tmp" && test -d "$tmp"
25686 } ||
25687 {
25688 tmp=./conf$$-$RANDOM
25689 (umask 077 && mkdir "$tmp")
25690 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25691
25692 # Set up the scripts for CONFIG_FILES section.
25693 # No need to generate them if there are no CONFIG_FILES.
25694 # This happens for instance with `./config.status config.h'.
25695 if test -n "$CONFIG_FILES"; then
25696
25697 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
25698 ac_cs_awk_getline=:
25699 ac_cs_awk_pipe_init=
25700 ac_cs_awk_read_file='
25701 while ((getline aline < (F[key])) > 0)
25702 print(aline)
25703 close(F[key])'
25704 ac_cs_awk_pipe_fini=
25705 else
25706 ac_cs_awk_getline=false
25707 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
25708 ac_cs_awk_read_file='
25709 print "|#_!!_#|"
25710 print "cat " F[key] " &&"
25711 '$ac_cs_awk_pipe_init
25712 # The final `:' finishes the AND list.
25713 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
25714 fi
25715 ac_cr=`echo X | tr X '\015'`
25716 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25717 # But we know of no other shell where ac_cr would be empty at this
25718 # point, so we can use a bashism as a fallback.
25719 if test "x$ac_cr" = x; then
25720 eval ac_cr=\$\'\\r\'
25721 fi
25722 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25723 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25724 ac_cs_awk_cr='\r'
25725 else
25726 ac_cs_awk_cr=$ac_cr
25727 fi
25728
25729 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25730 _ACEOF
25731
25732 # Create commands to substitute file output variables.
25733 {
25734 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
25735 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
25736 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
25737 echo "_ACAWK" &&
25738 echo "_ACEOF"
25739 } >conf$$files.sh &&
25740 . ./conf$$files.sh ||
25741 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25742 rm -f conf$$files.sh
25743
25744 {
25745 echo "cat >conf$$subs.awk <<_ACEOF" &&
25746 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25747 echo "_ACEOF"
25748 } >conf$$subs.sh ||
25749 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25750 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25751 ac_delim='%!_!# '
25752 for ac_last_try in false false false false false :; do
25753 . ./conf$$subs.sh ||
25754 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25755
25756 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25757 if test $ac_delim_n = $ac_delim_num; then
25758 break
25759 elif $ac_last_try; then
25760 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25761 else
25762 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25763 fi
25764 done
25765 rm -f conf$$subs.sh
25766
25767 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25768 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25769 _ACEOF
25770 sed -n '
25771 h
25772 s/^/S["/; s/!.*/"]=/
25773 p
25774 g
25775 s/^[^!]*!//
25776 :repl
25777 t repl
25778 s/'"$ac_delim"'$//
25779 t delim
25780 :nl
25781 h
25782 s/\(.\{148\}\)..*/\1/
25783 t more1
25784 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25785 p
25786 n
25787 b repl
25788 :more1
25789 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25790 p
25791 g
25792 s/.\{148\}//
25793 t nl
25794 :delim
25795 h
25796 s/\(.\{148\}\)..*/\1/
25797 t more2
25798 s/["\\]/\\&/g; s/^/"/; s/$/"/
25799 p
25800 b
25801 :more2
25802 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25803 p
25804 g
25805 s/.\{148\}//
25806 t delim
25807 ' <conf$$subs.awk | sed '
25808 /^[^""]/{
25809 N
25810 s/\n//
25811 }
25812 ' >>$CONFIG_STATUS || ac_write_fail=1
25813 rm -f conf$$subs.awk
25814 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25815 _ACAWK
25816 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25817 for (key in S) S_is_set[key] = 1
25818 FS = "\a"
25819 \$ac_cs_awk_pipe_init
25820 }
25821 {
25822 line = $ 0
25823 nfields = split(line, field, "@")
25824 substed = 0
25825 len = length(field[1])
25826 for (i = 2; i < nfields; i++) {
25827 key = field[i]
25828 keylen = length(key)
25829 if (S_is_set[key]) {
25830 value = S[key]
25831 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25832 len += length(value) + length(field[++i])
25833 substed = 1
25834 } else
25835 len += 1 + keylen
25836 }
25837 if (nfields == 3 && !substed) {
25838 key = field[2]
25839 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
25840 \$ac_cs_awk_read_file
25841 next
25842 }
25843 }
25844 print line
25845 }
25846 \$ac_cs_awk_pipe_fini
25847 _ACAWK
25848 _ACEOF
25849 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25850 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25851 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25852 else
25853 cat
25854 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25855 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25856 _ACEOF
25857
25858 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25859 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25860 # trailing colons and then remove the whole line if VPATH becomes empty
25861 # (actually we leave an empty line to preserve line numbers).
25862 if test "x$srcdir" = x.; then
25863 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25864 s/:*\$(srcdir):*/:/
25865 s/:*\${srcdir}:*/:/
25866 s/:*@srcdir@:*/:/
25867 s/^\([^=]*=[ ]*\):*/\1/
25868 s/:*$//
25869 s/^[^=]*=[ ]*$//
25870 }'
25871 fi
25872
25873 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25874 fi # test -n "$CONFIG_FILES"
25875
25876 # Set up the scripts for CONFIG_HEADERS section.
25877 # No need to generate them if there are no CONFIG_HEADERS.
25878 # This happens for instance with `./config.status Makefile'.
25879 if test -n "$CONFIG_HEADERS"; then
25880 cat >"$tmp/defines.awk" <<\_ACAWK ||
25881 BEGIN {
25882 _ACEOF
25883
25884 # Transform confdefs.h into an awk script `defines.awk', embedded as
25885 # here-document in config.status, that substitutes the proper values into
25886 # config.h.in to produce config.h.
25887
25888 # Create a delimiter string that does not exist in confdefs.h, to ease
25889 # handling of long lines.
25890 ac_delim='%!_!# '
25891 for ac_last_try in false false :; do
25892 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25893 if test -z "$ac_t"; then
25894 break
25895 elif $ac_last_try; then
25896 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25897 else
25898 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25899 fi
25900 done
25901
25902 # For the awk script, D is an array of macro values keyed by name,
25903 # likewise P contains macro parameters if any. Preserve backslash
25904 # newline sequences.
25905
25906 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25907 sed -n '
25908 s/.\{148\}/&'"$ac_delim"'/g
25909 t rset
25910 :rset
25911 s/^[ ]*#[ ]*define[ ][ ]*/ /
25912 t def
25913 d
25914 :def
25915 s/\\$//
25916 t bsnl
25917 s/["\\]/\\&/g
25918 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25919 D["\1"]=" \3"/p
25920 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25921 d
25922 :bsnl
25923 s/["\\]/\\&/g
25924 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25925 D["\1"]=" \3\\\\\\n"\\/p
25926 t cont
25927 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25928 t cont
25929 d
25930 :cont
25931 n
25932 s/.\{148\}/&'"$ac_delim"'/g
25933 t clear
25934 :clear
25935 s/\\$//
25936 t bsnlc
25937 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25938 d
25939 :bsnlc
25940 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25941 b cont
25942 ' <confdefs.h | sed '
25943 s/'"$ac_delim"'/"\\\
25944 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25945
25946 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25947 for (key in D) D_is_set[key] = 1
25948 FS = "\a"
25949 }
25950 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25951 line = \$ 0
25952 split(line, arg, " ")
25953 if (arg[1] == "#") {
25954 defundef = arg[2]
25955 mac1 = arg[3]
25956 } else {
25957 defundef = substr(arg[1], 2)
25958 mac1 = arg[2]
25959 }
25960 split(mac1, mac2, "(") #)
25961 macro = mac2[1]
25962 prefix = substr(line, 1, index(line, defundef) - 1)
25963 if (D_is_set[macro]) {
25964 # Preserve the white space surrounding the "#".
25965 print prefix "define", macro P[macro] D[macro]
25966 next
25967 } else {
25968 # Replace #undef with comments. This is necessary, for example,
25969 # in the case of _POSIX_SOURCE, which is predefined and required
25970 # on some systems where configure will not decide to define it.
25971 if (defundef == "undef") {
25972 print "/*", prefix defundef, macro, "*/"
25973 next
25974 }
25975 }
25976 }
25977 { print }
25978 _ACAWK
25979 _ACEOF
25980 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25981 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25982 fi # test -n "$CONFIG_HEADERS"
25983
25984
25985 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25986 shift
25987 for ac_tag
25988 do
25989 case $ac_tag in
25990 :[FHLC]) ac_mode=$ac_tag; continue;;
25991 esac
25992 case $ac_mode$ac_tag in
25993 :[FHL]*:*);;
25994 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25995 :[FH]-) ac_tag=-:-;;
25996 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25997 esac
25998 ac_save_IFS=$IFS
25999 IFS=:
26000 set x $ac_tag
26001 IFS=$ac_save_IFS
26002 shift
26003 ac_file=$1
26004 shift
26005
26006 case $ac_mode in
26007 :L) ac_source=$1;;
26008 :[FH])
26009 ac_file_inputs=
26010 for ac_f
26011 do
26012 case $ac_f in
26013 -) ac_f="$tmp/stdin";;
26014 *) # Look for the file first in the build tree, then in the source tree
26015 # (if the path is not absolute). The absolute path cannot be DOS-style,
26016 # because $ac_f cannot contain `:'.
26017 test -f "$ac_f" ||
26018 case $ac_f in
26019 [\\/$]*) false;;
26020 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26021 esac ||
26022 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
26023 esac
26024 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
26025 as_fn_append ac_file_inputs " '$ac_f'"
26026 done
26027
26028 # Let's still pretend it is `configure' which instantiates (i.e., don't
26029 # use $as_me), people would be surprised to read:
26030 # /* config.h. Generated by config.status. */
26031 configure_input='Generated from '`
26032 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
26033 `' by configure.'
26034 if test x"$ac_file" != x-; then
26035 configure_input="$ac_file. $configure_input"
26036 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
26037 $as_echo "$as_me: creating $ac_file" >&6;}
26038 fi
26039 # Neutralize special characters interpreted by sed in replacement strings.
26040 case $configure_input in #(
26041 *\&* | *\|* | *\\* )
26042 ac_sed_conf_input=`$as_echo "$configure_input" |
26043 sed 's/[\\\\&|]/\\\\&/g'`;; #(
26044 *) ac_sed_conf_input=$configure_input;;
26045 esac
26046
26047 case $ac_tag in
26048 *:-:* | *:-) cat >"$tmp/stdin" \
26049 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
26050 esac
26051 ;;
26052 esac
26053
26054 ac_dir=`$as_dirname -- "$ac_file" ||
26055 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26056 X"$ac_file" : 'X\(//\)[^/]' \| \
26057 X"$ac_file" : 'X\(//\)$' \| \
26058 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
26059 $as_echo X"$ac_file" |
26060 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26061 s//\1/
26062 q
26063 }
26064 /^X\(\/\/\)[^/].*/{
26065 s//\1/
26066 q
26067 }
26068 /^X\(\/\/\)$/{
26069 s//\1/
26070 q
26071 }
26072 /^X\(\/\).*/{
26073 s//\1/
26074 q
26075 }
26076 s/.*/./; q'`
26077 as_dir="$ac_dir"; as_fn_mkdir_p
26078 ac_builddir=.
26079
26080 case "$ac_dir" in
26081 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26082 *)
26083 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
26084 # A ".." for each directory in $ac_dir_suffix.
26085 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
26086 case $ac_top_builddir_sub in
26087 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26088 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26089 esac ;;
26090 esac
26091 ac_abs_top_builddir=$ac_pwd
26092 ac_abs_builddir=$ac_pwd$ac_dir_suffix
26093 # for backward compatibility:
26094 ac_top_builddir=$ac_top_build_prefix
26095
26096 case $srcdir in
26097 .) # We are building in place.
26098 ac_srcdir=.
26099 ac_top_srcdir=$ac_top_builddir_sub
26100 ac_abs_top_srcdir=$ac_pwd ;;
26101 [\\/]* | ?:[\\/]* ) # Absolute name.
26102 ac_srcdir=$srcdir$ac_dir_suffix;
26103 ac_top_srcdir=$srcdir
26104 ac_abs_top_srcdir=$srcdir ;;
26105 *) # Relative name.
26106 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26107 ac_top_srcdir=$ac_top_build_prefix$srcdir
26108 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
26109 esac
26110 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
26111
26112
26113 case $ac_mode in
26114 :F)
26115 #
26116 # CONFIG_FILE
26117 #
26118
26119 case $INSTALL in
26120 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
26121 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
26122 esac
26123 ac_MKDIR_P=$MKDIR_P
26124 case $MKDIR_P in
26125 [\\/$]* | ?:[\\/]* ) ;;
26126 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
26127 esac
26128 _ACEOF
26129
26130 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26131 # If the template does not know about datarootdir, expand it.
26132 # FIXME: This hack should be removed a few years after 2.60.
26133 ac_datarootdir_hack=; ac_datarootdir_seen=
26134 ac_sed_dataroot='
26135 /datarootdir/ {
26136 p
26137 q
26138 }
26139 /@datadir@/p
26140 /@docdir@/p
26141 /@infodir@/p
26142 /@localedir@/p
26143 /@mandir@/p'
26144 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
26145 *datarootdir*) ac_datarootdir_seen=yes;;
26146 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
26147 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26148 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
26149 _ACEOF
26150 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26151 ac_datarootdir_hack='
26152 s&@datadir@&$datadir&g
26153 s&@docdir@&$docdir&g
26154 s&@infodir@&$infodir&g
26155 s&@localedir@&$localedir&g
26156 s&@mandir@&$mandir&g
26157 s&\\\${datarootdir}&$datarootdir&g' ;;
26158 esac
26159 _ACEOF
26160
26161 # Neutralize VPATH when `$srcdir' = `.'.
26162 # Shell code in configure.ac might set extrasub.
26163 # FIXME: do we really want to maintain this feature?
26164 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26165 ac_sed_extra="$ac_vpsub
26166 $extrasub
26167 _ACEOF
26168 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26169 :t
26170 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
26171 s|@configure_input@|$ac_sed_conf_input|;t t
26172 s&@top_builddir@&$ac_top_builddir_sub&;t t
26173 s&@top_build_prefix@&$ac_top_build_prefix&;t t
26174 s&@srcdir@&$ac_srcdir&;t t
26175 s&@abs_srcdir@&$ac_abs_srcdir&;t t
26176 s&@top_srcdir@&$ac_top_srcdir&;t t
26177 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
26178 s&@builddir@&$ac_builddir&;t t
26179 s&@abs_builddir@&$ac_abs_builddir&;t t
26180 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
26181 s&@INSTALL@&$ac_INSTALL&;t t
26182 s&@MKDIR_P@&$ac_MKDIR_P&;t t
26183 $ac_datarootdir_hack
26184 "
26185 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
26186 if $ac_cs_awk_getline; then
26187 $AWK -f "$tmp/subs.awk"
26188 else
26189 $AWK -f "$tmp/subs.awk" | $SHELL
26190 fi >$tmp/out \
26191 || as_fn_error "could not create $ac_file" "$LINENO" 5
26192
26193 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
26194 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
26195 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
26196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26197 which seems to be undefined. Please make sure it is defined." >&5
26198 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
26199 which seems to be undefined. Please make sure it is defined." >&2;}
26200
26201 rm -f "$tmp/stdin"
26202 case $ac_file in
26203 -) cat "$tmp/out" && rm -f "$tmp/out";;
26204 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
26205 esac \
26206 || as_fn_error "could not create $ac_file" "$LINENO" 5
26207 ;;
26208 :H)
26209 #
26210 # CONFIG_HEADER
26211 #
26212 if test x"$ac_file" != x-; then
26213 {
26214 $as_echo "/* $configure_input */" \
26215 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
26216 } >"$tmp/config.h" \
26217 || as_fn_error "could not create $ac_file" "$LINENO" 5
26218 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
26219 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
26220 $as_echo "$as_me: $ac_file is unchanged" >&6;}
26221 else
26222 rm -f "$ac_file"
26223 mv "$tmp/config.h" "$ac_file" \
26224 || as_fn_error "could not create $ac_file" "$LINENO" 5
26225 fi
26226 else
26227 $as_echo "/* $configure_input */" \
26228 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
26229 || as_fn_error "could not create -" "$LINENO" 5
26230 fi
26231 # Compute "$ac_file"'s index in $config_headers.
26232 _am_arg="$ac_file"
26233 _am_stamp_count=1
26234 for _am_header in $config_headers :; do
26235 case $_am_header in
26236 $_am_arg | $_am_arg:* )
26237 break ;;
26238 * )
26239 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
26240 esac
26241 done
26242 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
26243 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26244 X"$_am_arg" : 'X\(//\)[^/]' \| \
26245 X"$_am_arg" : 'X\(//\)$' \| \
26246 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
26247 $as_echo X"$_am_arg" |
26248 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26249 s//\1/
26250 q
26251 }
26252 /^X\(\/\/\)[^/].*/{
26253 s//\1/
26254 q
26255 }
26256 /^X\(\/\/\)$/{
26257 s//\1/
26258 q
26259 }
26260 /^X\(\/\).*/{
26261 s//\1/
26262 q
26263 }
26264 s/.*/./; q'`/stamp-h$_am_stamp_count
26265 ;;
26266
26267 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
26268 $as_echo "$as_me: executing $ac_file commands" >&6;}
26269 ;;
26270 esac
26271
26272
26273 case $ac_file$ac_mode in
26274 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
26275 # Autoconf 2.62 quotes --file arguments for eval, but not when files
26276 # are listed without --file. Let's play safe and only enable the eval
26277 # if we detect the quoting.
26278 case $CONFIG_FILES in
26279 *\'*) eval set x "$CONFIG_FILES" ;;
26280 *) set x $CONFIG_FILES ;;
26281 esac
26282 shift
26283 for mf
26284 do
26285 # Strip MF so we end up with the name of the file.
26286 mf=`echo "$mf" | sed -e 's/:.*$//'`
26287 # Check whether this is an Automake generated Makefile or not.
26288 # We used to match only the files named `Makefile.in', but
26289 # some people rename them; so instead we look at the file content.
26290 # Grep'ing the first line is not enough: some people post-process
26291 # each Makefile.in and add a new line on top of each file to say so.
26292 # Grep'ing the whole file is not good either: AIX grep has a line
26293 # limit of 2048, but all sed's we know have understand at least 4000.
26294 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
26295 dirpart=`$as_dirname -- "$mf" ||
26296 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26297 X"$mf" : 'X\(//\)[^/]' \| \
26298 X"$mf" : 'X\(//\)$' \| \
26299 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
26300 $as_echo X"$mf" |
26301 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26302 s//\1/
26303 q
26304 }
26305 /^X\(\/\/\)[^/].*/{
26306 s//\1/
26307 q
26308 }
26309 /^X\(\/\/\)$/{
26310 s//\1/
26311 q
26312 }
26313 /^X\(\/\).*/{
26314 s//\1/
26315 q
26316 }
26317 s/.*/./; q'`
26318 else
26319 continue
26320 fi
26321 # Extract the definition of DEPDIR, am__include, and am__quote
26322 # from the Makefile without running `make'.
26323 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
26324 test -z "$DEPDIR" && continue
26325 am__include=`sed -n 's/^am__include = //p' < "$mf"`
26326 test -z "am__include" && continue
26327 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
26328 # When using ansi2knr, U may be empty or an underscore; expand it
26329 U=`sed -n 's/^U = //p' < "$mf"`
26330 # Find all dependency output files, they are included files with
26331 # $(DEPDIR) in their names. We invoke sed twice because it is the
26332 # simplest approach to changing $(DEPDIR) to its actual value in the
26333 # expansion.
26334 for file in `sed -n "
26335 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
26336 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
26337 # Make sure the directory exists.
26338 test -f "$dirpart/$file" && continue
26339 fdir=`$as_dirname -- "$file" ||
26340 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
26341 X"$file" : 'X\(//\)[^/]' \| \
26342 X"$file" : 'X\(//\)$' \| \
26343 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
26344 $as_echo X"$file" |
26345 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26346 s//\1/
26347 q
26348 }
26349 /^X\(\/\/\)[^/].*/{
26350 s//\1/
26351 q
26352 }
26353 /^X\(\/\/\)$/{
26354 s//\1/
26355 q
26356 }
26357 /^X\(\/\).*/{
26358 s//\1/
26359 q
26360 }
26361 s/.*/./; q'`
26362 as_dir=$dirpart/$fdir; as_fn_mkdir_p
26363 # echo "creating $dirpart/$file"
26364 echo '# dummy' > "$dirpart/$file"
26365 done
26366 done
26367 }
26368 ;;
26369 "mkdirs":C)
26370 for dir in etc lisp ; do
26371 test -d ${dir} || mkdir ${dir}
26372 done
26373 ;;
26374 "epaths":C)
26375 echo creating src/epaths.h
26376 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
26377 ;;
26378 "gdbinit":C)
26379 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
26380 echo creating src/.gdbinit
26381 echo source $srcdir/src/.gdbinit > src/.gdbinit
26382 fi
26383 ;;
26384
26385 esac
26386 done # for ac_tag
26387
26388
26389 as_fn_exit 0
26390 _ACEOF
26391 ac_clean_files=$ac_clean_files_save
26392
26393 test $ac_write_fail = 0 ||
26394 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
26395
26396
26397 # configure is writing to config.log, and then calls config.status.
26398 # config.status does its own redirection, appending to config.log.
26399 # Unfortunately, on DOS this fails, as config.log is still kept open
26400 # by configure, so config.status won't be able to write to it; its
26401 # output is simply discarded. So we exec the FD to /dev/null,
26402 # effectively closing config.log, so it can be properly (re)opened and
26403 # appended to by config.status. When coming back to configure, we
26404 # need to make the FD available again.
26405 if test "$no_create" != yes; then
26406 ac_cs_success=:
26407 ac_config_status_args=
26408 test "$silent" = yes &&
26409 ac_config_status_args="$ac_config_status_args --quiet"
26410 exec 5>/dev/null
26411 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
26412 exec 5>>config.log
26413 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26414 # would make configure fail if this is the last instruction.
26415 $ac_cs_success || as_fn_exit $?
26416 fi
26417 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
26418 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
26419 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
26420 fi
26421