]> code.delx.au - gnu-emacs/blob - autogen/configure
Auto-commit of generated files.
[gnu-emacs] / autogen / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.2.50.
4 #
5 #
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
9 #
10 #
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
90
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
96 do
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
102
103 ;;
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
109 fi
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
113 fi
114
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
126
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
132
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
149 ;;
150 esac
151 fi
152 "
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
158
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
165
166 else
167 exitcode=1; echo positional parameters were not saved.
168 fi
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
179 fi
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
186 do
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
191 /*)
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
200 fi
201 fi
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
211
212
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
222 fi
223
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
235 fi
236 exit 1
237 fi
238 fi
239 fi
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
245
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
253 {
254 { eval $1=; unset $1;}
255 }
256 as_unset=as_fn_unset
257
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
262 {
263 return $1
264 } # as_fn_set_status
265
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
270 {
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
275
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
280 {
281
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
301 q
302 }
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
305 q
306 }
307 /^X\(\/\/\)$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\).*/{
312 s//\1/
313 q
314 }
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
320
321
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
331 {
332 eval $1+=\$2
333 }'
334 else
335 as_fn_append ()
336 {
337 eval $1=\$$1\$2
338 }
339 fi # as_fn_append
340
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
348 {
349 as_val=$(( $* ))
350 }'
351 else
352 as_fn_arith ()
353 {
354 as_val=`expr "$@" || test $? -eq 1`
355 }
356 fi # as_fn_arith
357
358
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
365 {
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
370 fi
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
374
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
380 fi
381
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
386 fi
387
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
392 fi
393
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
401 q
402 }
403 /^X\/\(\/\/\)$/{
404 s//\1/
405 q
406 }
407 /^X\/\(\/\).*/{
408 s//\1/
409 q
410 }
411 s/.*/./; q'`
412
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
419
420
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
427 p
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
433 b
434 :lineno
435 N
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
443
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
450 }
451
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
461 *)
462 ECHO_N='-n';;
463 esac
464
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
471 fi
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
485 fi
486 else
487 as_ln_s='cp -p'
488 fi
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
491
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
497 fi
498
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
506 fi
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
518 '
519 fi
520 as_executable_p=$as_test_x
521
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
531
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
536
537 #
538 # Initializations.
539 #
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
548
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.2.50'
553 PACKAGE_STRING='emacs 24.2.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
556
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
593
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 WINDOW_SYSTEM_OBJ
608 LIB_GCC
609 LD_FIRSTFLAG
610 LD_SWITCH_SYSTEM_TEMACS
611 LIBGNU_LTLIBDEPS
612 LIBGNU_LIBDEPS
613 gltests_WITNESS
614 gl_GNULIB_ENABLED_verify_FALSE
615 gl_GNULIB_ENABLED_verify_TRUE
616 gl_GNULIB_ENABLED_strtoull_FALSE
617 gl_GNULIB_ENABLED_strtoull_TRUE
618 gl_GNULIB_ENABLED_strtoll_FALSE
619 gl_GNULIB_ENABLED_strtoll_TRUE
620 gl_GNULIB_ENABLED_stat_FALSE
621 gl_GNULIB_ENABLED_stat_TRUE
622 gl_GNULIB_ENABLED_pathmax_FALSE
623 gl_GNULIB_ENABLED_pathmax_TRUE
624 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
625 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
626 gl_GNULIB_ENABLED_dosname_FALSE
627 gl_GNULIB_ENABLED_dosname_TRUE
628 LTLIBINTL
629 LIBINTL
630 WINDOWS_64_BIT_OFF_T
631 HAVE_UNISTD_H
632 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
633 NEXT_UNISTD_H
634 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
635 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
636 TIME_H_DEFINES_STRUCT_TIMESPEC
637 NEXT_AS_FIRST_DIRECTIVE_TIME_H
638 NEXT_TIME_H
639 WINDOWS_64_BIT_ST_SIZE
640 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
641 NEXT_SYS_STAT_H
642 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
643 NEXT_STDLIB_H
644 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
645 NEXT_STDIO_H
646 REPLACE_VSPRINTF
647 REPLACE_VSNPRINTF
648 REPLACE_VPRINTF
649 REPLACE_VFPRINTF
650 REPLACE_VDPRINTF
651 REPLACE_VASPRINTF
652 REPLACE_TMPFILE
653 REPLACE_STDIO_WRITE_FUNCS
654 REPLACE_STDIO_READ_FUNCS
655 REPLACE_SPRINTF
656 REPLACE_SNPRINTF
657 REPLACE_RENAMEAT
658 REPLACE_RENAME
659 REPLACE_REMOVE
660 REPLACE_PRINTF
661 REPLACE_POPEN
662 REPLACE_PERROR
663 REPLACE_OBSTACK_PRINTF
664 REPLACE_GETLINE
665 REPLACE_GETDELIM
666 REPLACE_FTELLO
667 REPLACE_FTELL
668 REPLACE_FSEEKO
669 REPLACE_FSEEK
670 REPLACE_FREOPEN
671 REPLACE_FPURGE
672 REPLACE_FPRINTF
673 REPLACE_FOPEN
674 REPLACE_FFLUSH
675 REPLACE_FDOPEN
676 REPLACE_FCLOSE
677 REPLACE_DPRINTF
678 HAVE_VDPRINTF
679 HAVE_VASPRINTF
680 HAVE_RENAMEAT
681 HAVE_POPEN
682 HAVE_PCLOSE
683 HAVE_FTELLO
684 HAVE_FSEEKO
685 HAVE_DPRINTF
686 HAVE_DECL_VSNPRINTF
687 HAVE_DECL_SNPRINTF
688 HAVE_DECL_OBSTACK_PRINTF
689 HAVE_DECL_GETLINE
690 HAVE_DECL_GETDELIM
691 HAVE_DECL_FTELLO
692 HAVE_DECL_FSEEKO
693 HAVE_DECL_FPURGE
694 GNULIB_VSPRINTF_POSIX
695 GNULIB_VSNPRINTF
696 GNULIB_VPRINTF_POSIX
697 GNULIB_VPRINTF
698 GNULIB_VFPRINTF_POSIX
699 GNULIB_VFPRINTF
700 GNULIB_VDPRINTF
701 GNULIB_VSCANF
702 GNULIB_VFSCANF
703 GNULIB_VASPRINTF
704 GNULIB_TMPFILE
705 GNULIB_STDIO_H_SIGPIPE
706 GNULIB_STDIO_H_NONBLOCKING
707 GNULIB_SPRINTF_POSIX
708 GNULIB_SNPRINTF
709 GNULIB_SCANF
710 GNULIB_RENAMEAT
711 GNULIB_RENAME
712 GNULIB_REMOVE
713 GNULIB_PUTS
714 GNULIB_PUTCHAR
715 GNULIB_PUTC
716 GNULIB_PRINTF_POSIX
717 GNULIB_PRINTF
718 GNULIB_POPEN
719 GNULIB_PERROR
720 GNULIB_PCLOSE
721 GNULIB_OBSTACK_PRINTF_POSIX
722 GNULIB_OBSTACK_PRINTF
723 GNULIB_GETLINE
724 GNULIB_GETDELIM
725 GNULIB_GETCHAR
726 GNULIB_GETC
727 GNULIB_FWRITE
728 GNULIB_FTELLO
729 GNULIB_FTELL
730 GNULIB_FSEEKO
731 GNULIB_FSEEK
732 GNULIB_FSCANF
733 GNULIB_FREOPEN
734 GNULIB_FREAD
735 GNULIB_FPUTS
736 GNULIB_FPUTC
737 GNULIB_FPURGE
738 GNULIB_FPRINTF_POSIX
739 GNULIB_FPRINTF
740 GNULIB_FOPEN
741 GNULIB_FGETS
742 GNULIB_FGETC
743 GNULIB_FFLUSH
744 GNULIB_FDOPEN
745 GNULIB_FCLOSE
746 GNULIB_DPRINTF
747 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
748 NEXT_STDDEF_H
749 GL_GENERATE_STDDEF_H_FALSE
750 GL_GENERATE_STDDEF_H_TRUE
751 STDDEF_H
752 HAVE_WCHAR_T
753 REPLACE_NULL
754 HAVE__BOOL
755 GL_GENERATE_STDBOOL_H_FALSE
756 GL_GENERATE_STDBOOL_H_TRUE
757 STDBOOL_H
758 GL_GENERATE_STDARG_H_FALSE
759 GL_GENERATE_STDARG_H_TRUE
760 STDARG_H
761 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
762 NEXT_STDARG_H
763 GL_GENERATE_STDALIGN_H_FALSE
764 GL_GENERATE_STDALIGN_H_TRUE
765 STDALIGN_H
766 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
767 NEXT_SIGNAL_H
768 LIB_PTHREAD_SIGMASK
769 REPLACE_RAISE
770 REPLACE_PTHREAD_SIGMASK
771 HAVE_SIGHANDLER_T
772 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
773 HAVE_STRUCT_SIGACTION_SA_SIGACTION
774 HAVE_SIGACTION
775 HAVE_SIGINFO_T
776 HAVE_SIGSET_T
777 HAVE_RAISE
778 HAVE_PTHREAD_SIGMASK
779 HAVE_POSIX_SIGNALBLOCKING
780 GNULIB_SIGACTION
781 GNULIB_SIGPROCMASK
782 GNULIB_SIGNAL_H_SIGPIPE
783 GNULIB_RAISE
784 GNULIB_PTHREAD_SIGMASK
785 HAVE_SYS_SELECT_H
786 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
787 NEXT_SYS_SELECT_H
788 REPLACE_SELECT
789 REPLACE_PSELECT
790 HAVE_PSELECT
791 GNULIB_SELECT
792 GNULIB_PSELECT
793 REPLACE_TIMEGM
794 REPLACE_NANOSLEEP
795 REPLACE_MKTIME
796 REPLACE_LOCALTIME_R
797 HAVE_TIMEGM
798 HAVE_STRPTIME
799 HAVE_NANOSLEEP
800 HAVE_DECL_LOCALTIME_R
801 GNULIB_TIME_R
802 GNULIB_TIMEGM
803 GNULIB_STRPTIME
804 GNULIB_NANOSLEEP
805 GNULIB_MKTIME
806 REPLACE_UTIMENSAT
807 REPLACE_STAT
808 REPLACE_MKNOD
809 REPLACE_MKFIFO
810 REPLACE_MKDIR
811 REPLACE_LSTAT
812 REPLACE_FUTIMENS
813 REPLACE_FSTATAT
814 REPLACE_FSTAT
815 HAVE_UTIMENSAT
816 HAVE_MKNODAT
817 HAVE_MKNOD
818 HAVE_MKFIFOAT
819 HAVE_MKFIFO
820 HAVE_MKDIRAT
821 HAVE_LSTAT
822 HAVE_LCHMOD
823 HAVE_FUTIMENS
824 HAVE_FSTATAT
825 HAVE_FCHMODAT
826 GNULIB_UTIMENSAT
827 GNULIB_STAT
828 GNULIB_MKNODAT
829 GNULIB_MKNOD
830 GNULIB_MKFIFOAT
831 GNULIB_MKFIFO
832 GNULIB_MKDIRAT
833 GNULIB_LSTAT
834 GNULIB_LCHMOD
835 GNULIB_FUTIMENS
836 GNULIB_FSTATAT
837 GNULIB_FSTAT
838 GNULIB_FCHMODAT
839 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
840 NEXT_INTTYPES_H
841 UINT64_MAX_EQ_ULONG_MAX
842 UINT32_MAX_LT_UINTMAX_MAX
843 PRIPTR_PREFIX
844 PRI_MACROS_BROKEN
845 INT64_MAX_EQ_LONG_MAX
846 INT32_MAX_LT_INTMAX_MAX
847 REPLACE_STRTOIMAX
848 HAVE_DECL_STRTOUMAX
849 HAVE_DECL_STRTOIMAX
850 HAVE_DECL_IMAXDIV
851 HAVE_DECL_IMAXABS
852 GNULIB_STRTOUMAX
853 GNULIB_STRTOIMAX
854 GNULIB_IMAXDIV
855 GNULIB_IMAXABS
856 GL_GENERATE_STDINT_H_FALSE
857 GL_GENERATE_STDINT_H_TRUE
858 STDINT_H
859 WINT_T_SUFFIX
860 WCHAR_T_SUFFIX
861 SIG_ATOMIC_T_SUFFIX
862 SIZE_T_SUFFIX
863 PTRDIFF_T_SUFFIX
864 HAVE_SIGNED_WINT_T
865 HAVE_SIGNED_WCHAR_T
866 HAVE_SIGNED_SIG_ATOMIC_T
867 BITSIZEOF_WINT_T
868 BITSIZEOF_WCHAR_T
869 BITSIZEOF_SIG_ATOMIC_T
870 BITSIZEOF_SIZE_T
871 BITSIZEOF_PTRDIFF_T
872 APPLE_UNIVERSAL_BUILD
873 HAVE_SYS_BITYPES_H
874 HAVE_SYS_INTTYPES_H
875 HAVE_STDINT_H
876 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
877 NEXT_STDINT_H
878 HAVE_SYS_TYPES_H
879 HAVE_INTTYPES_H
880 HAVE_WCHAR_H
881 HAVE_UNSIGNED_LONG_LONG_INT
882 HAVE_LONG_LONG_INT
883 HAVE_WINSOCK2_H
884 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
885 NEXT_SYS_TIME_H
886 REPLACE_STRUCT_TIMEVAL
887 REPLACE_GETTIMEOFDAY
888 HAVE_SYS_TIME_H
889 HAVE_STRUCT_TIMEVAL
890 HAVE_GETTIMEOFDAY
891 GNULIB_GETTIMEOFDAY
892 GNULIB_GL_UNISTD_H_GETOPT
893 GETOPT_H
894 HAVE_GETOPT_H
895 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
896 NEXT_GETOPT_H
897 PRAGMA_COLUMNS
898 PRAGMA_SYSTEM_HEADER
899 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
900 INCLUDE_NEXT
901 GETLOADAVG_LIBS
902 REPLACE_WCTOMB
903 REPLACE_UNSETENV
904 REPLACE_STRTOD
905 REPLACE_SETENV
906 REPLACE_REALPATH
907 REPLACE_REALLOC
908 REPLACE_RANDOM_R
909 REPLACE_PUTENV
910 REPLACE_PTSNAME_R
911 REPLACE_MKSTEMP
912 REPLACE_MBTOWC
913 REPLACE_MALLOC
914 REPLACE_CANONICALIZE_FILE_NAME
915 REPLACE_CALLOC
916 HAVE_DECL_UNSETENV
917 HAVE_UNLOCKPT
918 HAVE_SYS_LOADAVG_H
919 HAVE_STRUCT_RANDOM_DATA
920 HAVE_STRTOULL
921 HAVE_STRTOLL
922 HAVE_STRTOD
923 HAVE_DECL_SETENV
924 HAVE_SETENV
925 HAVE_RPMATCH
926 HAVE_REALPATH
927 HAVE_RANDOM_R
928 HAVE_RANDOM_H
929 HAVE_RANDOM
930 HAVE_PTSNAME_R
931 HAVE_PTSNAME
932 HAVE_POSIX_OPENPT
933 HAVE_MKSTEMPS
934 HAVE_MKSTEMP
935 HAVE_MKOSTEMPS
936 HAVE_MKOSTEMP
937 HAVE_MKDTEMP
938 HAVE_GRANTPT
939 HAVE_GETSUBOPT
940 HAVE_DECL_GETLOADAVG
941 HAVE_CANONICALIZE_FILE_NAME
942 HAVE_ATOLL
943 HAVE__EXIT
944 GNULIB_WCTOMB
945 GNULIB_UNSETENV
946 GNULIB_UNLOCKPT
947 GNULIB_SYSTEM_POSIX
948 GNULIB_STRTOULL
949 GNULIB_STRTOLL
950 GNULIB_STRTOD
951 GNULIB_SETENV
952 GNULIB_RPMATCH
953 GNULIB_REALPATH
954 GNULIB_REALLOC_POSIX
955 GNULIB_RANDOM_R
956 GNULIB_RANDOM
957 GNULIB_PUTENV
958 GNULIB_PTSNAME_R
959 GNULIB_PTSNAME
960 GNULIB_POSIX_OPENPT
961 GNULIB_MKSTEMPS
962 GNULIB_MKSTEMP
963 GNULIB_MKOSTEMPS
964 GNULIB_MKOSTEMP
965 GNULIB_MKDTEMP
966 GNULIB_MBTOWC
967 GNULIB_MALLOC_POSIX
968 GNULIB_GRANTPT
969 GNULIB_GETSUBOPT
970 GNULIB_GETLOADAVG
971 GNULIB_CANONICALIZE_FILE_NAME
972 GNULIB_CALLOC_POSIX
973 GNULIB_ATOLL
974 GNULIB__EXIT
975 GL_GENERATE_EXECINFO_H_FALSE
976 GL_GENERATE_EXECINFO_H_TRUE
977 LIB_EXECINFO
978 EXECINFO_H
979 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
980 UNISTD_H_HAVE_WINSOCK2_H
981 REPLACE_WRITE
982 REPLACE_USLEEP
983 REPLACE_UNLINKAT
984 REPLACE_UNLINK
985 REPLACE_TTYNAME_R
986 REPLACE_SYMLINK
987 REPLACE_SLEEP
988 REPLACE_RMDIR
989 REPLACE_READLINK
990 REPLACE_READ
991 REPLACE_PWRITE
992 REPLACE_PREAD
993 REPLACE_LSEEK
994 REPLACE_LINKAT
995 REPLACE_LINK
996 REPLACE_LCHOWN
997 REPLACE_ISATTY
998 REPLACE_GETPAGESIZE
999 REPLACE_GETGROUPS
1000 REPLACE_GETLOGIN_R
1001 REPLACE_GETDOMAINNAME
1002 REPLACE_GETCWD
1003 REPLACE_FTRUNCATE
1004 REPLACE_FCHOWNAT
1005 REPLACE_DUP2
1006 REPLACE_DUP
1007 REPLACE_CLOSE
1008 REPLACE_CHOWN
1009 HAVE_SYS_PARAM_H
1010 HAVE_OS_H
1011 HAVE_DECL_TTYNAME_R
1012 HAVE_DECL_SETHOSTNAME
1013 HAVE_DECL_GETUSERSHELL
1014 HAVE_DECL_GETPAGESIZE
1015 HAVE_DECL_GETLOGIN_R
1016 HAVE_DECL_GETDOMAINNAME
1017 HAVE_DECL_FDATASYNC
1018 HAVE_DECL_FCHDIR
1019 HAVE_DECL_ENVIRON
1020 HAVE_USLEEP
1021 HAVE_UNLINKAT
1022 HAVE_SYMLINKAT
1023 HAVE_SYMLINK
1024 HAVE_SLEEP
1025 HAVE_SETHOSTNAME
1026 HAVE_READLINKAT
1027 HAVE_READLINK
1028 HAVE_PWRITE
1029 HAVE_PREAD
1030 HAVE_PIPE2
1031 HAVE_PIPE
1032 HAVE_LINKAT
1033 HAVE_LINK
1034 HAVE_LCHOWN
1035 HAVE_GROUP_MEMBER
1036 HAVE_GETPAGESIZE
1037 HAVE_GETLOGIN
1038 HAVE_GETHOSTNAME
1039 HAVE_GETGROUPS
1040 HAVE_GETDTABLESIZE
1041 HAVE_FTRUNCATE
1042 HAVE_FSYNC
1043 HAVE_FDATASYNC
1044 HAVE_FCHOWNAT
1045 HAVE_FCHDIR
1046 HAVE_FACCESSAT
1047 HAVE_EUIDACCESS
1048 HAVE_DUP3
1049 HAVE_DUP2
1050 HAVE_CHOWN
1051 GNULIB_WRITE
1052 GNULIB_USLEEP
1053 GNULIB_UNLINKAT
1054 GNULIB_UNLINK
1055 GNULIB_UNISTD_H_SIGPIPE
1056 GNULIB_UNISTD_H_NONBLOCKING
1057 GNULIB_TTYNAME_R
1058 GNULIB_SYMLINKAT
1059 GNULIB_SYMLINK
1060 GNULIB_SLEEP
1061 GNULIB_SETHOSTNAME
1062 GNULIB_RMDIR
1063 GNULIB_READLINKAT
1064 GNULIB_READLINK
1065 GNULIB_READ
1066 GNULIB_PWRITE
1067 GNULIB_PREAD
1068 GNULIB_PIPE2
1069 GNULIB_PIPE
1070 GNULIB_LSEEK
1071 GNULIB_LINKAT
1072 GNULIB_LINK
1073 GNULIB_LCHOWN
1074 GNULIB_ISATTY
1075 GNULIB_GROUP_MEMBER
1076 GNULIB_GETUSERSHELL
1077 GNULIB_GETPAGESIZE
1078 GNULIB_GETLOGIN_R
1079 GNULIB_GETLOGIN
1080 GNULIB_GETHOSTNAME
1081 GNULIB_GETGROUPS
1082 GNULIB_GETDTABLESIZE
1083 GNULIB_GETDOMAINNAME
1084 GNULIB_GETCWD
1085 GNULIB_FTRUNCATE
1086 GNULIB_FSYNC
1087 GNULIB_FDATASYNC
1088 GNULIB_FCHOWNAT
1089 GNULIB_FCHDIR
1090 GNULIB_FACCESSAT
1091 GNULIB_EUIDACCESS
1092 GNULIB_ENVIRON
1093 GNULIB_DUP3
1094 GNULIB_DUP2
1095 GNULIB_DUP
1096 GNULIB_CLOSE
1097 GNULIB_CHOWN
1098 GNULIB_CHDIR
1099 LIB_CLOCK_GETTIME
1100 GL_GENERATE_ALLOCA_H_FALSE
1101 GL_GENERATE_ALLOCA_H_TRUE
1102 ALLOCA_H
1103 ALLOCA
1104 GL_COND_LIBTOOL_FALSE
1105 GL_COND_LIBTOOL_TRUE
1106 POST_ALLOC_OBJ
1107 PRE_ALLOC_OBJ
1108 CYGWIN_OBJ
1109 RALLOC_OBJ
1110 OLDXMENU_DEPS
1111 LIBX_OTHER
1112 LIBXMENU
1113 OLDXMENU
1114 OLDXMENU_TARGET
1115 LIBXT_OTHER
1116 TOOLKIT_LIBW
1117 WIDGET_OBJ
1118 XOBJ
1119 XMENU_OBJ
1120 FONT_OBJ
1121 OTHER_FILES
1122 GNU_OBJC_CFLAGS
1123 ns_appsrc
1124 ns_appresdir
1125 ns_appbindir
1126 ns_appdir
1127 X_TOOLKIT_TYPE
1128 GNUSTEP_CFLAGS
1129 C_SWITCH_X_SITE
1130 LD_SWITCH_X_SITE
1131 gameuser
1132 gamedir
1133 bitmapdir
1134 archlibdir
1135 etcdir
1136 x_default_search_path
1137 lisppath
1138 locallisppath
1139 standardlisppath
1140 leimdir
1141 lispdir
1142 srcdir
1143 canonical
1144 configuration
1145 version
1146 KRB4LIB
1147 DESLIB
1148 KRB5LIB
1149 CRYPTOLIB
1150 COM_ERRLIB
1151 LIBRESOLV
1152 LIBHESIOD
1153 TERMCAP_OBJ
1154 LIBS_TERMCAP
1155 BLESSMAIL_TARGET
1156 LIBS_MAIL
1157 liblockfile
1158 LIBXML2_LIBS
1159 LIBXML2_CFLAGS
1160 LIBXSM
1161 LIBGPM
1162 LIBGIF
1163 LIBTIFF
1164 LIBPNG
1165 LIBJPEG
1166 LIBXPM
1167 M17N_FLT_LIBS
1168 M17N_FLT_CFLAGS
1169 LIBOTF_LIBS
1170 LIBOTF_CFLAGS
1171 FREETYPE_LIBS
1172 FREETYPE_CFLAGS
1173 XFT_LIBS
1174 XFT_CFLAGS
1175 FONTCONFIG_LIBS
1176 FONTCONFIG_CFLAGS
1177 LIBXMU
1178 LIBXTR6
1179 LIBGNUTLS_LIBS
1180 LIBGNUTLS_CFLAGS
1181 LIBSELINUX_LIBS
1182 SETTINGS_LIBS
1183 SETTINGS_CFLAGS
1184 GOBJECT_LIBS
1185 GOBJECT_CFLAGS
1186 GCONF_LIBS
1187 GCONF_CFLAGS
1188 GSETTINGS_LIBS
1189 GSETTINGS_CFLAGS
1190 DBUS_OBJ
1191 DBUS_LIBS
1192 DBUS_CFLAGS
1193 GTK_OBJ
1194 GTK_LIBS
1195 GTK_CFLAGS
1196 IMAGEMAGICK_LIBS
1197 IMAGEMAGICK_CFLAGS
1198 RSVG_LIBS
1199 RSVG_CFLAGS
1200 LIB_PTHREAD
1201 VMLIMIT_OBJ
1202 GMALLOC_OBJ
1203 HAVE_XSERVER
1204 LIB_STANDARD
1205 NS_OBJC_OBJ
1206 NS_OBJ
1207 ns_self_contained
1208 INSTALL_ARCH_INDEP_EXTRA
1209 TEMACS_LDFLAGS2
1210 LD_SWITCH_X_SITE_RPATH
1211 XMKMF
1212 DEPFLAGS
1213 MKDEPDIR
1214 CFLAGS_SOUND
1215 ALSA_LIBS
1216 ALSA_CFLAGS
1217 LIBSOUND
1218 PKG_CONFIG
1219 CRT_DIR
1220 START_FILES
1221 LIB_MATH
1222 LIBS_SYSTEM
1223 C_SWITCH_SYSTEM
1224 UNEXEC_OBJ
1225 C_SWITCH_MACHINE
1226 LD_SWITCH_SYSTEM
1227 CANNOT_DUMP
1228 INFO_OPTS
1229 INFO_EXT
1230 HAVE_MAKEINFO
1231 PAXCTL
1232 GZIP_PROG
1233 INSTALL_INFO
1234 LN_S
1235 GNULIB_WARN_CFLAGS
1236 WARN_CFLAGS
1237 WERROR_CFLAGS
1238 RANLIB
1239 ARFLAGS
1240 AR
1241 EGREP
1242 GREP
1243 CPP
1244 am__fastdepCC_FALSE
1245 am__fastdepCC_TRUE
1246 CCDEPMODE
1247 AMDEPBACKSLASH
1248 AMDEP_FALSE
1249 AMDEP_TRUE
1250 am__quote
1251 am__include
1252 DEPDIR
1253 OBJEXT
1254 EXEEXT
1255 ac_ct_CC
1256 CPPFLAGS
1257 LDFLAGS
1258 CFLAGS
1259 CC
1260 host_os
1261 host_vendor
1262 host_cpu
1263 host
1264 build_os
1265 build_vendor
1266 build_cpu
1267 build
1268 PROFILING_CFLAGS
1269 GZIP_INFO
1270 cache_file
1271 am__untar
1272 am__tar
1273 AMTAR
1274 am__leading_dot
1275 SET_MAKE
1276 AWK
1277 mkdir_p
1278 MKDIR_P
1279 INSTALL_STRIP_PROGRAM
1280 STRIP
1281 install_sh
1282 MAKEINFO
1283 AUTOHEADER
1284 AUTOMAKE
1285 AUTOCONF
1286 ACLOCAL
1287 VERSION
1288 PACKAGE
1289 CYGPATH_W
1290 am__isrc
1291 INSTALL_DATA
1292 INSTALL_SCRIPT
1293 INSTALL_PROGRAM
1294 target_alias
1295 host_alias
1296 build_alias
1297 LIBS
1298 ECHO_T
1299 ECHO_N
1300 ECHO_C
1301 DEFS
1302 mandir
1303 localedir
1304 libdir
1305 psdir
1306 pdfdir
1307 dvidir
1308 htmldir
1309 infodir
1310 docdir
1311 oldincludedir
1312 includedir
1313 localstatedir
1314 sharedstatedir
1315 sysconfdir
1316 datadir
1317 datarootdir
1318 libexecdir
1319 sbindir
1320 bindir
1321 program_transform_name
1322 prefix
1323 exec_prefix
1324 PACKAGE_URL
1325 PACKAGE_BUGREPORT
1326 PACKAGE_STRING
1327 PACKAGE_VERSION
1328 PACKAGE_TARNAME
1329 PACKAGE_NAME
1330 PATH_SEPARATOR
1331 SHELL'
1332 ac_subst_files='deps_frag
1333 lisp_frag
1334 ns_frag'
1335 ac_user_opts='
1336 enable_option_checking
1337 with_all
1338 with_pop
1339 with_kerberos
1340 with_kerberos5
1341 with_hesiod
1342 with_mmdf
1343 with_mail_unlink
1344 with_mailhost
1345 with_sound
1346 with_sync_input
1347 with_x_toolkit
1348 with_wide_int
1349 with_xpm
1350 with_jpeg
1351 with_tiff
1352 with_gif
1353 with_png
1354 with_rsvg
1355 with_xml2
1356 with_imagemagick
1357 with_xft
1358 with_libotf
1359 with_m17n_flt
1360 with_toolkit_scroll_bars
1361 with_xaw3d
1362 with_xim
1363 with_ns
1364 with_gpm
1365 with_dbus
1366 with_gconf
1367 with_gsettings
1368 with_selinux
1369 with_gnutls
1370 with_makeinfo
1371 with_compress_info
1372 with_pkg_config_prog
1373 with_crt_dir
1374 with_gameuser
1375 with_gnustep_conf
1376 enable_ns_self_contained
1377 enable_locallisppath
1378 enable_checking
1379 enable_check_lisp_object_type
1380 enable_profiling
1381 enable_autodepend
1382 enable_dependency_tracking
1383 enable_largefile
1384 enable_gcc_warnings
1385 enable_link_time_optimization
1386 with_x
1387 '
1388 ac_precious_vars='build_alias
1389 host_alias
1390 target_alias
1391 CC
1392 CFLAGS
1393 LDFLAGS
1394 LIBS
1395 CPPFLAGS
1396 CPP
1397 XMKMF'
1398
1399
1400 # Initialize some variables set by options.
1401 ac_init_help=
1402 ac_init_version=false
1403 ac_unrecognized_opts=
1404 ac_unrecognized_sep=
1405 # The variables have the same names as the options, with
1406 # dashes changed to underlines.
1407 cache_file=/dev/null
1408 exec_prefix=NONE
1409 no_create=
1410 no_recursion=
1411 prefix=NONE
1412 program_prefix=NONE
1413 program_suffix=NONE
1414 program_transform_name=s,x,x,
1415 silent=
1416 site=
1417 srcdir=
1418 verbose=
1419 x_includes=NONE
1420 x_libraries=NONE
1421
1422 # Installation directory options.
1423 # These are left unexpanded so users can "make install exec_prefix=/foo"
1424 # and all the variables that are supposed to be based on exec_prefix
1425 # by default will actually change.
1426 # Use braces instead of parens because sh, perl, etc. also accept them.
1427 # (The list follows the same order as the GNU Coding Standards.)
1428 bindir='${exec_prefix}/bin'
1429 sbindir='${exec_prefix}/sbin'
1430 libexecdir='${exec_prefix}/libexec'
1431 datarootdir='${prefix}/share'
1432 datadir='${datarootdir}'
1433 sysconfdir='${prefix}/etc'
1434 sharedstatedir='${prefix}/com'
1435 localstatedir='${prefix}/var'
1436 includedir='${prefix}/include'
1437 oldincludedir='/usr/include'
1438 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1439 infodir='${datarootdir}/info'
1440 htmldir='${docdir}'
1441 dvidir='${docdir}'
1442 pdfdir='${docdir}'
1443 psdir='${docdir}'
1444 libdir='${exec_prefix}/lib'
1445 localedir='${datarootdir}/locale'
1446 mandir='${datarootdir}/man'
1447
1448 ac_prev=
1449 ac_dashdash=
1450 for ac_option
1451 do
1452 # If the previous option needs an argument, assign it.
1453 if test -n "$ac_prev"; then
1454 eval $ac_prev=\$ac_option
1455 ac_prev=
1456 continue
1457 fi
1458
1459 case $ac_option in
1460 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1461 *) ac_optarg=yes ;;
1462 esac
1463
1464 # Accept the important Cygnus configure options, so we can diagnose typos.
1465
1466 case $ac_dashdash$ac_option in
1467 --)
1468 ac_dashdash=yes ;;
1469
1470 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1471 ac_prev=bindir ;;
1472 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1473 bindir=$ac_optarg ;;
1474
1475 -build | --build | --buil | --bui | --bu)
1476 ac_prev=build_alias ;;
1477 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1478 build_alias=$ac_optarg ;;
1479
1480 -cache-file | --cache-file | --cache-fil | --cache-fi \
1481 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1482 ac_prev=cache_file ;;
1483 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1484 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1485 cache_file=$ac_optarg ;;
1486
1487 --config-cache | -C)
1488 cache_file=config.cache ;;
1489
1490 -datadir | --datadir | --datadi | --datad)
1491 ac_prev=datadir ;;
1492 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1493 datadir=$ac_optarg ;;
1494
1495 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1496 | --dataroo | --dataro | --datar)
1497 ac_prev=datarootdir ;;
1498 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1499 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1500 datarootdir=$ac_optarg ;;
1501
1502 -disable-* | --disable-*)
1503 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1504 # Reject names that are not valid shell variable names.
1505 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1506 as_fn_error "invalid feature name: $ac_useropt"
1507 ac_useropt_orig=$ac_useropt
1508 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1509 case $ac_user_opts in
1510 *"
1511 "enable_$ac_useropt"
1512 "*) ;;
1513 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1514 ac_unrecognized_sep=', ';;
1515 esac
1516 eval enable_$ac_useropt=no ;;
1517
1518 -docdir | --docdir | --docdi | --doc | --do)
1519 ac_prev=docdir ;;
1520 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1521 docdir=$ac_optarg ;;
1522
1523 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1524 ac_prev=dvidir ;;
1525 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1526 dvidir=$ac_optarg ;;
1527
1528 -enable-* | --enable-*)
1529 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1530 # Reject names that are not valid shell variable names.
1531 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1532 as_fn_error "invalid feature name: $ac_useropt"
1533 ac_useropt_orig=$ac_useropt
1534 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1535 case $ac_user_opts in
1536 *"
1537 "enable_$ac_useropt"
1538 "*) ;;
1539 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1540 ac_unrecognized_sep=', ';;
1541 esac
1542 eval enable_$ac_useropt=\$ac_optarg ;;
1543
1544 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1545 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1546 | --exec | --exe | --ex)
1547 ac_prev=exec_prefix ;;
1548 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1549 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1550 | --exec=* | --exe=* | --ex=*)
1551 exec_prefix=$ac_optarg ;;
1552
1553 -gas | --gas | --ga | --g)
1554 # Obsolete; use --with-gas.
1555 with_gas=yes ;;
1556
1557 -help | --help | --hel | --he | -h)
1558 ac_init_help=long ;;
1559 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1560 ac_init_help=recursive ;;
1561 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1562 ac_init_help=short ;;
1563
1564 -host | --host | --hos | --ho)
1565 ac_prev=host_alias ;;
1566 -host=* | --host=* | --hos=* | --ho=*)
1567 host_alias=$ac_optarg ;;
1568
1569 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1570 ac_prev=htmldir ;;
1571 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1572 | --ht=*)
1573 htmldir=$ac_optarg ;;
1574
1575 -includedir | --includedir | --includedi | --included | --include \
1576 | --includ | --inclu | --incl | --inc)
1577 ac_prev=includedir ;;
1578 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1579 | --includ=* | --inclu=* | --incl=* | --inc=*)
1580 includedir=$ac_optarg ;;
1581
1582 -infodir | --infodir | --infodi | --infod | --info | --inf)
1583 ac_prev=infodir ;;
1584 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1585 infodir=$ac_optarg ;;
1586
1587 -libdir | --libdir | --libdi | --libd)
1588 ac_prev=libdir ;;
1589 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1590 libdir=$ac_optarg ;;
1591
1592 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1593 | --libexe | --libex | --libe)
1594 ac_prev=libexecdir ;;
1595 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1596 | --libexe=* | --libex=* | --libe=*)
1597 libexecdir=$ac_optarg ;;
1598
1599 -localedir | --localedir | --localedi | --localed | --locale)
1600 ac_prev=localedir ;;
1601 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1602 localedir=$ac_optarg ;;
1603
1604 -localstatedir | --localstatedir | --localstatedi | --localstated \
1605 | --localstate | --localstat | --localsta | --localst | --locals)
1606 ac_prev=localstatedir ;;
1607 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1608 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1609 localstatedir=$ac_optarg ;;
1610
1611 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1612 ac_prev=mandir ;;
1613 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1614 mandir=$ac_optarg ;;
1615
1616 -nfp | --nfp | --nf)
1617 # Obsolete; use --without-fp.
1618 with_fp=no ;;
1619
1620 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1621 | --no-cr | --no-c | -n)
1622 no_create=yes ;;
1623
1624 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1625 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1626 no_recursion=yes ;;
1627
1628 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1629 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1630 | --oldin | --oldi | --old | --ol | --o)
1631 ac_prev=oldincludedir ;;
1632 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1633 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1634 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1635 oldincludedir=$ac_optarg ;;
1636
1637 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1638 ac_prev=prefix ;;
1639 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1640 prefix=$ac_optarg ;;
1641
1642 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1643 | --program-pre | --program-pr | --program-p)
1644 ac_prev=program_prefix ;;
1645 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1646 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1647 program_prefix=$ac_optarg ;;
1648
1649 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1650 | --program-suf | --program-su | --program-s)
1651 ac_prev=program_suffix ;;
1652 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1653 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1654 program_suffix=$ac_optarg ;;
1655
1656 -program-transform-name | --program-transform-name \
1657 | --program-transform-nam | --program-transform-na \
1658 | --program-transform-n | --program-transform- \
1659 | --program-transform | --program-transfor \
1660 | --program-transfo | --program-transf \
1661 | --program-trans | --program-tran \
1662 | --progr-tra | --program-tr | --program-t)
1663 ac_prev=program_transform_name ;;
1664 -program-transform-name=* | --program-transform-name=* \
1665 | --program-transform-nam=* | --program-transform-na=* \
1666 | --program-transform-n=* | --program-transform-=* \
1667 | --program-transform=* | --program-transfor=* \
1668 | --program-transfo=* | --program-transf=* \
1669 | --program-trans=* | --program-tran=* \
1670 | --progr-tra=* | --program-tr=* | --program-t=*)
1671 program_transform_name=$ac_optarg ;;
1672
1673 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1674 ac_prev=pdfdir ;;
1675 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1676 pdfdir=$ac_optarg ;;
1677
1678 -psdir | --psdir | --psdi | --psd | --ps)
1679 ac_prev=psdir ;;
1680 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1681 psdir=$ac_optarg ;;
1682
1683 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1684 | -silent | --silent | --silen | --sile | --sil)
1685 silent=yes ;;
1686
1687 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1688 ac_prev=sbindir ;;
1689 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1690 | --sbi=* | --sb=*)
1691 sbindir=$ac_optarg ;;
1692
1693 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1694 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1695 | --sharedst | --shareds | --shared | --share | --shar \
1696 | --sha | --sh)
1697 ac_prev=sharedstatedir ;;
1698 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1699 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1700 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1701 | --sha=* | --sh=*)
1702 sharedstatedir=$ac_optarg ;;
1703
1704 -site | --site | --sit)
1705 ac_prev=site ;;
1706 -site=* | --site=* | --sit=*)
1707 site=$ac_optarg ;;
1708
1709 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1710 ac_prev=srcdir ;;
1711 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1712 srcdir=$ac_optarg ;;
1713
1714 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1715 | --syscon | --sysco | --sysc | --sys | --sy)
1716 ac_prev=sysconfdir ;;
1717 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1718 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1719 sysconfdir=$ac_optarg ;;
1720
1721 -target | --target | --targe | --targ | --tar | --ta | --t)
1722 ac_prev=target_alias ;;
1723 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1724 target_alias=$ac_optarg ;;
1725
1726 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1727 verbose=yes ;;
1728
1729 -version | --version | --versio | --versi | --vers | -V)
1730 ac_init_version=: ;;
1731
1732 -with-* | --with-*)
1733 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1734 # Reject names that are not valid shell variable names.
1735 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1736 as_fn_error "invalid package name: $ac_useropt"
1737 ac_useropt_orig=$ac_useropt
1738 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1739 case $ac_user_opts in
1740 *"
1741 "with_$ac_useropt"
1742 "*) ;;
1743 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1744 ac_unrecognized_sep=', ';;
1745 esac
1746 eval with_$ac_useropt=\$ac_optarg ;;
1747
1748 -without-* | --without-*)
1749 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1750 # Reject names that are not valid shell variable names.
1751 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1752 as_fn_error "invalid package name: $ac_useropt"
1753 ac_useropt_orig=$ac_useropt
1754 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1755 case $ac_user_opts in
1756 *"
1757 "with_$ac_useropt"
1758 "*) ;;
1759 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1760 ac_unrecognized_sep=', ';;
1761 esac
1762 eval with_$ac_useropt=no ;;
1763
1764 --x)
1765 # Obsolete; use --with-x.
1766 with_x=yes ;;
1767
1768 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1769 | --x-incl | --x-inc | --x-in | --x-i)
1770 ac_prev=x_includes ;;
1771 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1772 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1773 x_includes=$ac_optarg ;;
1774
1775 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1776 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1777 ac_prev=x_libraries ;;
1778 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1779 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1780 x_libraries=$ac_optarg ;;
1781
1782 -*) as_fn_error "unrecognized option: \`$ac_option'
1783 Try \`$0 --help' for more information."
1784 ;;
1785
1786 *=*)
1787 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1788 # Reject names that are not valid shell variable names.
1789 case $ac_envvar in #(
1790 '' | [0-9]* | *[!_$as_cr_alnum]* )
1791 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1792 esac
1793 eval $ac_envvar=\$ac_optarg
1794 export $ac_envvar ;;
1795
1796 *)
1797 # FIXME: should be removed in autoconf 3.0.
1798 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1799 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1800 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1801 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1802 ;;
1803
1804 esac
1805 done
1806
1807 if test -n "$ac_prev"; then
1808 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1809 as_fn_error "missing argument to $ac_option"
1810 fi
1811
1812 if test -n "$ac_unrecognized_opts"; then
1813 case $enable_option_checking in
1814 no) ;;
1815 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1816 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1817 esac
1818 fi
1819
1820 # Check all directory arguments for consistency.
1821 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1822 datadir sysconfdir sharedstatedir localstatedir includedir \
1823 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1824 libdir localedir mandir
1825 do
1826 eval ac_val=\$$ac_var
1827 # Remove trailing slashes.
1828 case $ac_val in
1829 */ )
1830 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1831 eval $ac_var=\$ac_val;;
1832 esac
1833 # Be sure to have absolute directory names.
1834 case $ac_val in
1835 [\\/$]* | ?:[\\/]* ) continue;;
1836 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1837 esac
1838 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1839 done
1840
1841 # There might be people who depend on the old broken behavior: `$host'
1842 # used to hold the argument of --host etc.
1843 # FIXME: To remove some day.
1844 build=$build_alias
1845 host=$host_alias
1846 target=$target_alias
1847
1848 # FIXME: To remove some day.
1849 if test "x$host_alias" != x; then
1850 if test "x$build_alias" = x; then
1851 cross_compiling=maybe
1852 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1853 If a cross compiler is detected then cross compile mode will be used." >&2
1854 elif test "x$build_alias" != "x$host_alias"; then
1855 cross_compiling=yes
1856 fi
1857 fi
1858
1859 ac_tool_prefix=
1860 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1861
1862 test "$silent" = yes && exec 6>/dev/null
1863
1864
1865 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1866 ac_ls_di=`ls -di .` &&
1867 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1868 as_fn_error "working directory cannot be determined"
1869 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1870 as_fn_error "pwd does not report name of working directory"
1871
1872
1873 # Find the source files, if location was not specified.
1874 if test -z "$srcdir"; then
1875 ac_srcdir_defaulted=yes
1876 # Try the directory containing this script, then the parent directory.
1877 ac_confdir=`$as_dirname -- "$as_myself" ||
1878 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1879 X"$as_myself" : 'X\(//\)[^/]' \| \
1880 X"$as_myself" : 'X\(//\)$' \| \
1881 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1882 $as_echo X"$as_myself" |
1883 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1884 s//\1/
1885 q
1886 }
1887 /^X\(\/\/\)[^/].*/{
1888 s//\1/
1889 q
1890 }
1891 /^X\(\/\/\)$/{
1892 s//\1/
1893 q
1894 }
1895 /^X\(\/\).*/{
1896 s//\1/
1897 q
1898 }
1899 s/.*/./; q'`
1900 srcdir=$ac_confdir
1901 if test ! -r "$srcdir/$ac_unique_file"; then
1902 srcdir=..
1903 fi
1904 else
1905 ac_srcdir_defaulted=no
1906 fi
1907 if test ! -r "$srcdir/$ac_unique_file"; then
1908 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1909 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1910 fi
1911 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1912 ac_abs_confdir=`(
1913 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1914 pwd)`
1915 # When building in place, set srcdir=.
1916 if test "$ac_abs_confdir" = "$ac_pwd"; then
1917 srcdir=.
1918 fi
1919 # Remove unnecessary trailing slashes from srcdir.
1920 # Double slashes in file names in object file debugging info
1921 # mess up M-x gdb in Emacs.
1922 case $srcdir in
1923 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1924 esac
1925 for ac_var in $ac_precious_vars; do
1926 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1927 eval ac_env_${ac_var}_value=\$${ac_var}
1928 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1929 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1930 done
1931
1932 #
1933 # Report the --help message.
1934 #
1935 if test "$ac_init_help" = "long"; then
1936 # Omit some internal or obsolete options to make the list less imposing.
1937 # This message is too long to be a string in the A/UX 3.1 sh.
1938 cat <<_ACEOF
1939 \`configure' configures emacs 24.2.50 to adapt to many kinds of systems.
1940
1941 Usage: $0 [OPTION]... [VAR=VALUE]...
1942
1943 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1944 VAR=VALUE. See below for descriptions of some of the useful variables.
1945
1946 Defaults for the options are specified in brackets.
1947
1948 Configuration:
1949 -h, --help display this help and exit
1950 --help=short display options specific to this package
1951 --help=recursive display the short help of all the included packages
1952 -V, --version display version information and exit
1953 -q, --quiet, --silent do not print \`checking...' messages
1954 --cache-file=FILE cache test results in FILE [disabled]
1955 -C, --config-cache alias for \`--cache-file=config.cache'
1956 -n, --no-create do not create output files
1957 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1958
1959 Installation directories:
1960 --prefix=PREFIX install architecture-independent files in PREFIX
1961 [$ac_default_prefix]
1962 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1963 [PREFIX]
1964
1965 By default, \`make install' will install all the files in
1966 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1967 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1968 for instance \`--prefix=\$HOME'.
1969
1970 For better control, use the options below.
1971
1972 Fine tuning of the installation directories:
1973 --bindir=DIR user executables [EPREFIX/bin]
1974 --sbindir=DIR system admin executables [EPREFIX/sbin]
1975 --libexecdir=DIR program executables [EPREFIX/libexec]
1976 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1977 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1978 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1979 --libdir=DIR object code libraries [EPREFIX/lib]
1980 --includedir=DIR C header files [PREFIX/include]
1981 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1982 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1983 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1984 --infodir=DIR info documentation [DATAROOTDIR/info]
1985 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1986 --mandir=DIR man documentation [DATAROOTDIR/man]
1987 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1988 --htmldir=DIR html documentation [DOCDIR]
1989 --dvidir=DIR dvi documentation [DOCDIR]
1990 --pdfdir=DIR pdf documentation [DOCDIR]
1991 --psdir=DIR ps documentation [DOCDIR]
1992 _ACEOF
1993
1994 cat <<\_ACEOF
1995
1996 Program names:
1997 --program-prefix=PREFIX prepend PREFIX to installed program names
1998 --program-suffix=SUFFIX append SUFFIX to installed program names
1999 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2000
2001 X features:
2002 --x-includes=DIR X include files are in DIR
2003 --x-libraries=DIR X library files are in DIR
2004
2005 System types:
2006 --build=BUILD configure for building on BUILD [guessed]
2007 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2008 _ACEOF
2009 fi
2010
2011 if test -n "$ac_init_help"; then
2012 case $ac_init_help in
2013 short | recursive ) echo "Configuration of emacs 24.2.50:";;
2014 esac
2015 cat <<\_ACEOF
2016
2017 Optional Features:
2018 --disable-option-checking ignore unrecognized --enable/--with options
2019 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2020 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2021 --disable-ns-self-contained
2022 disable self contained build under NeXTstep
2023 --enable-locallisppath=PATH
2024 directories Emacs should search for lisp files
2025 specific to this site
2026 --enable-checking[=LIST]
2027 enable expensive run-time checks. With LIST, enable
2028 only specific categories of checks. Categories are:
2029 all,yes,no. Flags are: stringbytes, stringoverrun,
2030 stringfreelist, xmallocoverrun, conslist, glyphs
2031 --enable-check-lisp-object-type
2032 enable compile time checks for the Lisp_Object data
2033 type. This is useful for development for catching
2034 certain types of bugs.
2035 --enable-profiling build emacs with profiling support. This might not
2036 work on all platforms
2037 --enable-autodepend automatically generate dependencies to .h-files.
2038 Requires GNU Make and Gcc. Enabled if GNU Make and
2039 Gcc is found
2040 --disable-dependency-tracking speeds up one-time build
2041 --enable-dependency-tracking do not reject slow dependency extractors
2042 --disable-largefile omit support for large files
2043 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2044 developers, and may generate false alarms when used
2045 with older or non-GNU development tools.
2046 --enable-link-time-optimization
2047 build emacs with link-time optimization. This is
2048 supported only for GCC since 4.5.0.
2049
2050 Optional Packages:
2051 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2052 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2053 --without-all omit almost all features and build small executable
2054 with minimal dependencies
2055 --without-pop don't support POP mail retrieval with movemail
2056 --with-kerberos support Kerberos-authenticated POP
2057 --with-kerberos5 support Kerberos version 5 authenticated POP
2058 --with-hesiod support Hesiod to get the POP server host
2059 --with-mmdf support MMDF mailboxes
2060 --with-mail-unlink unlink, rather than empty, mail spool after reading
2061 --with-mailhost=HOSTNAME
2062 string giving default POP mail host
2063 --without-sound don't compile with sound support
2064 --without-sync-input process async input synchronously
2065 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
2066 lucid or athena, motif, no)
2067 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2068 --without-xpm don't compile with XPM image support
2069 --without-jpeg don't compile with JPEG image support
2070 --without-tiff don't compile with TIFF image support
2071 --without-gif don't compile with GIF image support
2072 --without-png don't compile with PNG image support
2073 --without-rsvg don't compile with SVG image support
2074 --without-xml2 don't compile with XML parsing support
2075 --without-imagemagick don't compile with ImageMagick image support
2076 --without-xft don't use XFT for anti aliased fonts
2077 --without-libotf don't use libotf for OpenType font support
2078 --without-m17n-flt don't use m17n-flt for text shaping
2079 --without-toolkit-scroll-bars
2080 don't use Motif or Xaw3d scroll bars
2081 --without-xaw3d don't use Xaw3d
2082 --without-xim don't use X11 XIM
2083 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2084 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2085 console
2086 --without-dbus don't compile with D-Bus support
2087 --without-gconf don't compile with GConf support
2088 --without-gsettings don't compile with GSettings support
2089 --without-selinux don't compile with SELinux support
2090 --without-gnutls don't use -lgnutls for SSL/TLS support
2091 --without-makeinfo don't require makeinfo for building manuals
2092 --without-compress-info don't compress the installed Info pages
2093 --with-pkg-config-prog=PATH
2094 path to pkg-config for finding GTK and librsvg
2095 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2096 /usr/lib, or /usr/lib64 on some platforms.
2097 --with-gameuser=USER user for shared game score files
2098 --with-gnustep-conf=PATH
2099 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2100 or /etc/GNUstep/GNUstep.conf
2101 --with-x use the X Window System
2102
2103 Some influential environment variables:
2104 CC C compiler command
2105 CFLAGS C compiler flags
2106 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2107 nonstandard directory <lib dir>
2108 LIBS libraries to pass to the linker, e.g. -l<library>
2109 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2110 you have headers in a nonstandard directory <include dir>
2111 CPP C preprocessor
2112 XMKMF Path to xmkmf, Makefile generator for X Window System
2113
2114 Use these variables to override the choices made by `configure' or to help
2115 it to find libraries and programs with nonstandard names/locations.
2116
2117 Report bugs to the package provider.
2118 _ACEOF
2119 ac_status=$?
2120 fi
2121
2122 if test "$ac_init_help" = "recursive"; then
2123 # If there are subdirs, report their specific --help.
2124 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2125 test -d "$ac_dir" ||
2126 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2127 continue
2128 ac_builddir=.
2129
2130 case "$ac_dir" in
2131 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2132 *)
2133 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2134 # A ".." for each directory in $ac_dir_suffix.
2135 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2136 case $ac_top_builddir_sub in
2137 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2138 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2139 esac ;;
2140 esac
2141 ac_abs_top_builddir=$ac_pwd
2142 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2143 # for backward compatibility:
2144 ac_top_builddir=$ac_top_build_prefix
2145
2146 case $srcdir in
2147 .) # We are building in place.
2148 ac_srcdir=.
2149 ac_top_srcdir=$ac_top_builddir_sub
2150 ac_abs_top_srcdir=$ac_pwd ;;
2151 [\\/]* | ?:[\\/]* ) # Absolute name.
2152 ac_srcdir=$srcdir$ac_dir_suffix;
2153 ac_top_srcdir=$srcdir
2154 ac_abs_top_srcdir=$srcdir ;;
2155 *) # Relative name.
2156 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2157 ac_top_srcdir=$ac_top_build_prefix$srcdir
2158 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2159 esac
2160 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2161
2162 cd "$ac_dir" || { ac_status=$?; continue; }
2163 # Check for guested configure.
2164 if test -f "$ac_srcdir/configure.gnu"; then
2165 echo &&
2166 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2167 elif test -f "$ac_srcdir/configure"; then
2168 echo &&
2169 $SHELL "$ac_srcdir/configure" --help=recursive
2170 else
2171 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2172 fi || ac_status=$?
2173 cd "$ac_pwd" || { ac_status=$?; break; }
2174 done
2175 fi
2176
2177 test -n "$ac_init_help" && exit $ac_status
2178 if $ac_init_version; then
2179 cat <<\_ACEOF
2180 emacs configure 24.2.50
2181 generated by GNU Autoconf 2.65
2182
2183 Copyright (C) 2009 Free Software Foundation, Inc.
2184 This configure script is free software; the Free Software Foundation
2185 gives unlimited permission to copy, distribute and modify it.
2186 _ACEOF
2187 exit
2188 fi
2189
2190 ## ------------------------ ##
2191 ## Autoconf initialization. ##
2192 ## ------------------------ ##
2193
2194 # ac_fn_c_try_compile LINENO
2195 # --------------------------
2196 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2197 ac_fn_c_try_compile ()
2198 {
2199 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2200 rm -f conftest.$ac_objext
2201 if { { ac_try="$ac_compile"
2202 case "(($ac_try" in
2203 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2204 *) ac_try_echo=$ac_try;;
2205 esac
2206 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2207 $as_echo "$ac_try_echo"; } >&5
2208 (eval "$ac_compile") 2>conftest.err
2209 ac_status=$?
2210 if test -s conftest.err; then
2211 grep -v '^ *+' conftest.err >conftest.er1
2212 cat conftest.er1 >&5
2213 mv -f conftest.er1 conftest.err
2214 fi
2215 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2216 test $ac_status = 0; } && {
2217 test -z "$ac_c_werror_flag" ||
2218 test ! -s conftest.err
2219 } && test -s conftest.$ac_objext; then :
2220 ac_retval=0
2221 else
2222 $as_echo "$as_me: failed program was:" >&5
2223 sed 's/^/| /' conftest.$ac_ext >&5
2224
2225 ac_retval=1
2226 fi
2227 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2228 as_fn_set_status $ac_retval
2229
2230 } # ac_fn_c_try_compile
2231
2232 # ac_fn_c_try_cpp LINENO
2233 # ----------------------
2234 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2235 ac_fn_c_try_cpp ()
2236 {
2237 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2238 if { { ac_try="$ac_cpp conftest.$ac_ext"
2239 case "(($ac_try" in
2240 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2241 *) ac_try_echo=$ac_try;;
2242 esac
2243 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2244 $as_echo "$ac_try_echo"; } >&5
2245 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2246 ac_status=$?
2247 if test -s conftest.err; then
2248 grep -v '^ *+' conftest.err >conftest.er1
2249 cat conftest.er1 >&5
2250 mv -f conftest.er1 conftest.err
2251 fi
2252 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2253 test $ac_status = 0; } >/dev/null && {
2254 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2255 test ! -s conftest.err
2256 }; then :
2257 ac_retval=0
2258 else
2259 $as_echo "$as_me: failed program was:" >&5
2260 sed 's/^/| /' conftest.$ac_ext >&5
2261
2262 ac_retval=1
2263 fi
2264 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2265 as_fn_set_status $ac_retval
2266
2267 } # ac_fn_c_try_cpp
2268
2269 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2270 # -------------------------------------------------------
2271 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2272 # the include files in INCLUDES and setting the cache variable VAR
2273 # accordingly.
2274 ac_fn_c_check_header_mongrel ()
2275 {
2276 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2277 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2279 $as_echo_n "checking for $2... " >&6; }
2280 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2281 $as_echo_n "(cached) " >&6
2282 fi
2283 eval ac_res=\$$3
2284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2285 $as_echo "$ac_res" >&6; }
2286 else
2287 # Is the header compilable?
2288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2289 $as_echo_n "checking $2 usability... " >&6; }
2290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2291 /* end confdefs.h. */
2292 $4
2293 #include <$2>
2294 _ACEOF
2295 if ac_fn_c_try_compile "$LINENO"; then :
2296 ac_header_compiler=yes
2297 else
2298 ac_header_compiler=no
2299 fi
2300 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2302 $as_echo "$ac_header_compiler" >&6; }
2303
2304 # Is the header present?
2305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2306 $as_echo_n "checking $2 presence... " >&6; }
2307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2308 /* end confdefs.h. */
2309 #include <$2>
2310 _ACEOF
2311 if ac_fn_c_try_cpp "$LINENO"; then :
2312 ac_header_preproc=yes
2313 else
2314 ac_header_preproc=no
2315 fi
2316 rm -f conftest.err conftest.$ac_ext
2317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2318 $as_echo "$ac_header_preproc" >&6; }
2319
2320 # So? What about this header?
2321 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2322 yes:no: )
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2324 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2325 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2326 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2327 ;;
2328 no:yes:* )
2329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2330 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2331 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2332 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2333 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2334 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2335 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2336 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2337 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2338 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2339 ;;
2340 esac
2341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2342 $as_echo_n "checking for $2... " >&6; }
2343 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2344 $as_echo_n "(cached) " >&6
2345 else
2346 eval "$3=\$ac_header_compiler"
2347 fi
2348 eval ac_res=\$$3
2349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2350 $as_echo "$ac_res" >&6; }
2351 fi
2352 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2353
2354 } # ac_fn_c_check_header_mongrel
2355
2356 # ac_fn_c_try_run LINENO
2357 # ----------------------
2358 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2359 # that executables *can* be run.
2360 ac_fn_c_try_run ()
2361 {
2362 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2363 if { { ac_try="$ac_link"
2364 case "(($ac_try" in
2365 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2366 *) ac_try_echo=$ac_try;;
2367 esac
2368 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2369 $as_echo "$ac_try_echo"; } >&5
2370 (eval "$ac_link") 2>&5
2371 ac_status=$?
2372 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2373 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2374 { { case "(($ac_try" in
2375 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2376 *) ac_try_echo=$ac_try;;
2377 esac
2378 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2379 $as_echo "$ac_try_echo"; } >&5
2380 (eval "$ac_try") 2>&5
2381 ac_status=$?
2382 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2383 test $ac_status = 0; }; }; then :
2384 ac_retval=0
2385 else
2386 $as_echo "$as_me: program exited with status $ac_status" >&5
2387 $as_echo "$as_me: failed program was:" >&5
2388 sed 's/^/| /' conftest.$ac_ext >&5
2389
2390 ac_retval=$ac_status
2391 fi
2392 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2393 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2394 as_fn_set_status $ac_retval
2395
2396 } # ac_fn_c_try_run
2397
2398 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2399 # -------------------------------------------------------
2400 # Tests whether HEADER exists and can be compiled using the include files in
2401 # INCLUDES, setting the cache variable VAR accordingly.
2402 ac_fn_c_check_header_compile ()
2403 {
2404 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2406 $as_echo_n "checking for $2... " >&6; }
2407 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2408 $as_echo_n "(cached) " >&6
2409 else
2410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2411 /* end confdefs.h. */
2412 $4
2413 #include <$2>
2414 _ACEOF
2415 if ac_fn_c_try_compile "$LINENO"; then :
2416 eval "$3=yes"
2417 else
2418 eval "$3=no"
2419 fi
2420 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2421 fi
2422 eval ac_res=\$$3
2423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2424 $as_echo "$ac_res" >&6; }
2425 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2426
2427 } # ac_fn_c_check_header_compile
2428
2429 # ac_fn_c_try_link LINENO
2430 # -----------------------
2431 # Try to link conftest.$ac_ext, and return whether this succeeded.
2432 ac_fn_c_try_link ()
2433 {
2434 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2435 rm -f conftest.$ac_objext conftest$ac_exeext
2436 if { { ac_try="$ac_link"
2437 case "(($ac_try" in
2438 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2439 *) ac_try_echo=$ac_try;;
2440 esac
2441 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2442 $as_echo "$ac_try_echo"; } >&5
2443 (eval "$ac_link") 2>conftest.err
2444 ac_status=$?
2445 if test -s conftest.err; then
2446 grep -v '^ *+' conftest.err >conftest.er1
2447 cat conftest.er1 >&5
2448 mv -f conftest.er1 conftest.err
2449 fi
2450 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2451 test $ac_status = 0; } && {
2452 test -z "$ac_c_werror_flag" ||
2453 test ! -s conftest.err
2454 } && test -s conftest$ac_exeext && {
2455 test "$cross_compiling" = yes ||
2456 $as_test_x conftest$ac_exeext
2457 }; then :
2458 ac_retval=0
2459 else
2460 $as_echo "$as_me: failed program was:" >&5
2461 sed 's/^/| /' conftest.$ac_ext >&5
2462
2463 ac_retval=1
2464 fi
2465 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2466 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2467 # interfere with the next link command; also delete a directory that is
2468 # left behind by Apple's compiler. We do this before executing the actions.
2469 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2470 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2471 as_fn_set_status $ac_retval
2472
2473 } # ac_fn_c_try_link
2474
2475 # ac_fn_c_check_decl LINENO SYMBOL VAR
2476 # ------------------------------------
2477 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2478 ac_fn_c_check_decl ()
2479 {
2480 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2482 $as_echo_n "checking whether $2 is declared... " >&6; }
2483 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2484 $as_echo_n "(cached) " >&6
2485 else
2486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2487 /* end confdefs.h. */
2488 $4
2489 int
2490 main ()
2491 {
2492 #ifndef $2
2493 (void) $2;
2494 #endif
2495
2496 ;
2497 return 0;
2498 }
2499 _ACEOF
2500 if ac_fn_c_try_compile "$LINENO"; then :
2501 eval "$3=yes"
2502 else
2503 eval "$3=no"
2504 fi
2505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2506 fi
2507 eval ac_res=\$$3
2508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2509 $as_echo "$ac_res" >&6; }
2510 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2511
2512 } # ac_fn_c_check_decl
2513
2514 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2515 # ----------------------------------------------
2516 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2517 ac_fn_c_check_header_preproc ()
2518 {
2519 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2521 $as_echo_n "checking for $2... " >&6; }
2522 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2523 $as_echo_n "(cached) " >&6
2524 else
2525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2526 /* end confdefs.h. */
2527 #include <$2>
2528 _ACEOF
2529 if ac_fn_c_try_cpp "$LINENO"; then :
2530 eval "$3=yes"
2531 else
2532 eval "$3=no"
2533 fi
2534 rm -f conftest.err conftest.$ac_ext
2535 fi
2536 eval ac_res=\$$3
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2538 $as_echo "$ac_res" >&6; }
2539 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2540
2541 } # ac_fn_c_check_header_preproc
2542
2543 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2544 # ----------------------------------------------------
2545 # Tries to find if the field MEMBER exists in type AGGR, after including
2546 # INCLUDES, setting cache variable VAR accordingly.
2547 ac_fn_c_check_member ()
2548 {
2549 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2551 $as_echo_n "checking for $2.$3... " >&6; }
2552 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2553 $as_echo_n "(cached) " >&6
2554 else
2555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2556 /* end confdefs.h. */
2557 $5
2558 int
2559 main ()
2560 {
2561 static $2 ac_aggr;
2562 if (ac_aggr.$3)
2563 return 0;
2564 ;
2565 return 0;
2566 }
2567 _ACEOF
2568 if ac_fn_c_try_compile "$LINENO"; then :
2569 eval "$4=yes"
2570 else
2571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2572 /* end confdefs.h. */
2573 $5
2574 int
2575 main ()
2576 {
2577 static $2 ac_aggr;
2578 if (sizeof ac_aggr.$3)
2579 return 0;
2580 ;
2581 return 0;
2582 }
2583 _ACEOF
2584 if ac_fn_c_try_compile "$LINENO"; then :
2585 eval "$4=yes"
2586 else
2587 eval "$4=no"
2588 fi
2589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2590 fi
2591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2592 fi
2593 eval ac_res=\$$4
2594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2595 $as_echo "$ac_res" >&6; }
2596 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2597
2598 } # ac_fn_c_check_member
2599
2600 # ac_fn_c_check_func LINENO FUNC VAR
2601 # ----------------------------------
2602 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2603 ac_fn_c_check_func ()
2604 {
2605 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2607 $as_echo_n "checking for $2... " >&6; }
2608 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2609 $as_echo_n "(cached) " >&6
2610 else
2611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2612 /* end confdefs.h. */
2613 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2614 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2615 #define $2 innocuous_$2
2616
2617 /* System header to define __stub macros and hopefully few prototypes,
2618 which can conflict with char $2 (); below.
2619 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2620 <limits.h> exists even on freestanding compilers. */
2621
2622 #ifdef __STDC__
2623 # include <limits.h>
2624 #else
2625 # include <assert.h>
2626 #endif
2627
2628 #undef $2
2629
2630 /* Override any GCC internal prototype to avoid an error.
2631 Use char because int might match the return type of a GCC
2632 builtin and then its argument prototype would still apply. */
2633 #ifdef __cplusplus
2634 extern "C"
2635 #endif
2636 char $2 ();
2637 /* The GNU C library defines this for functions which it implements
2638 to always fail with ENOSYS. Some functions are actually named
2639 something starting with __ and the normal name is an alias. */
2640 #if defined __stub_$2 || defined __stub___$2
2641 choke me
2642 #endif
2643
2644 int
2645 main ()
2646 {
2647 return $2 ();
2648 ;
2649 return 0;
2650 }
2651 _ACEOF
2652 if ac_fn_c_try_link "$LINENO"; then :
2653 eval "$3=yes"
2654 else
2655 eval "$3=no"
2656 fi
2657 rm -f core conftest.err conftest.$ac_objext \
2658 conftest$ac_exeext conftest.$ac_ext
2659 fi
2660 eval ac_res=\$$3
2661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2662 $as_echo "$ac_res" >&6; }
2663 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2664
2665 } # ac_fn_c_check_func
2666
2667 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2668 # -------------------------------------------
2669 # Tests whether TYPE exists after having included INCLUDES, setting cache
2670 # variable VAR accordingly.
2671 ac_fn_c_check_type ()
2672 {
2673 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2675 $as_echo_n "checking for $2... " >&6; }
2676 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2677 $as_echo_n "(cached) " >&6
2678 else
2679 eval "$3=no"
2680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2681 /* end confdefs.h. */
2682 $4
2683 int
2684 main ()
2685 {
2686 if (sizeof ($2))
2687 return 0;
2688 ;
2689 return 0;
2690 }
2691 _ACEOF
2692 if ac_fn_c_try_compile "$LINENO"; then :
2693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2694 /* end confdefs.h. */
2695 $4
2696 int
2697 main ()
2698 {
2699 if (sizeof (($2)))
2700 return 0;
2701 ;
2702 return 0;
2703 }
2704 _ACEOF
2705 if ac_fn_c_try_compile "$LINENO"; then :
2706
2707 else
2708 eval "$3=yes"
2709 fi
2710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2711 fi
2712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2713 fi
2714 eval ac_res=\$$3
2715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2716 $as_echo "$ac_res" >&6; }
2717 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2718
2719 } # ac_fn_c_check_type
2720
2721 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2722 # --------------------------------------------
2723 # Tries to find the compile-time value of EXPR in a program that includes
2724 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2725 # computed
2726 ac_fn_c_compute_int ()
2727 {
2728 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2729 if test "$cross_compiling" = yes; then
2730 # Depending upon the size, compute the lo and hi bounds.
2731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2732 /* end confdefs.h. */
2733 $4
2734 int
2735 main ()
2736 {
2737 static int test_array [1 - 2 * !(($2) >= 0)];
2738 test_array [0] = 0
2739
2740 ;
2741 return 0;
2742 }
2743 _ACEOF
2744 if ac_fn_c_try_compile "$LINENO"; then :
2745 ac_lo=0 ac_mid=0
2746 while :; do
2747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2748 /* end confdefs.h. */
2749 $4
2750 int
2751 main ()
2752 {
2753 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2754 test_array [0] = 0
2755
2756 ;
2757 return 0;
2758 }
2759 _ACEOF
2760 if ac_fn_c_try_compile "$LINENO"; then :
2761 ac_hi=$ac_mid; break
2762 else
2763 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2764 if test $ac_lo -le $ac_mid; then
2765 ac_lo= ac_hi=
2766 break
2767 fi
2768 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2769 fi
2770 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2771 done
2772 else
2773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2774 /* end confdefs.h. */
2775 $4
2776 int
2777 main ()
2778 {
2779 static int test_array [1 - 2 * !(($2) < 0)];
2780 test_array [0] = 0
2781
2782 ;
2783 return 0;
2784 }
2785 _ACEOF
2786 if ac_fn_c_try_compile "$LINENO"; then :
2787 ac_hi=-1 ac_mid=-1
2788 while :; do
2789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2790 /* end confdefs.h. */
2791 $4
2792 int
2793 main ()
2794 {
2795 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2796 test_array [0] = 0
2797
2798 ;
2799 return 0;
2800 }
2801 _ACEOF
2802 if ac_fn_c_try_compile "$LINENO"; then :
2803 ac_lo=$ac_mid; break
2804 else
2805 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2806 if test $ac_mid -le $ac_hi; then
2807 ac_lo= ac_hi=
2808 break
2809 fi
2810 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2811 fi
2812 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2813 done
2814 else
2815 ac_lo= ac_hi=
2816 fi
2817 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2818 fi
2819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2820 # Binary search between lo and hi bounds.
2821 while test "x$ac_lo" != "x$ac_hi"; do
2822 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2824 /* end confdefs.h. */
2825 $4
2826 int
2827 main ()
2828 {
2829 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2830 test_array [0] = 0
2831
2832 ;
2833 return 0;
2834 }
2835 _ACEOF
2836 if ac_fn_c_try_compile "$LINENO"; then :
2837 ac_hi=$ac_mid
2838 else
2839 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2840 fi
2841 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2842 done
2843 case $ac_lo in #((
2844 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2845 '') ac_retval=1 ;;
2846 esac
2847 else
2848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2849 /* end confdefs.h. */
2850 $4
2851 static long int longval () { return $2; }
2852 static unsigned long int ulongval () { return $2; }
2853 #include <stdio.h>
2854 #include <stdlib.h>
2855 int
2856 main ()
2857 {
2858
2859 FILE *f = fopen ("conftest.val", "w");
2860 if (! f)
2861 return 1;
2862 if (($2) < 0)
2863 {
2864 long int i = longval ();
2865 if (i != ($2))
2866 return 1;
2867 fprintf (f, "%ld", i);
2868 }
2869 else
2870 {
2871 unsigned long int i = ulongval ();
2872 if (i != ($2))
2873 return 1;
2874 fprintf (f, "%lu", i);
2875 }
2876 /* Do not output a trailing newline, as this causes \r\n confusion
2877 on some platforms. */
2878 return ferror (f) || fclose (f) != 0;
2879
2880 ;
2881 return 0;
2882 }
2883 _ACEOF
2884 if ac_fn_c_try_run "$LINENO"; then :
2885 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2886 else
2887 ac_retval=1
2888 fi
2889 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2890 conftest.$ac_objext conftest.beam conftest.$ac_ext
2891 rm -f conftest.val
2892
2893 fi
2894 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2895 as_fn_set_status $ac_retval
2896
2897 } # ac_fn_c_compute_int
2898 cat >config.log <<_ACEOF
2899 This file contains any messages produced by compilers while
2900 running configure, to aid debugging if configure makes a mistake.
2901
2902 It was created by emacs $as_me 24.2.50, which was
2903 generated by GNU Autoconf 2.65. Invocation command line was
2904
2905 $ $0 $@
2906
2907 _ACEOF
2908 exec 5>>config.log
2909 {
2910 cat <<_ASUNAME
2911 ## --------- ##
2912 ## Platform. ##
2913 ## --------- ##
2914
2915 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2916 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2917 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2918 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2919 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2920
2921 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2922 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2923
2924 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2925 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2926 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2927 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2928 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2929 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2930 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2931
2932 _ASUNAME
2933
2934 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2935 for as_dir in $PATH
2936 do
2937 IFS=$as_save_IFS
2938 test -z "$as_dir" && as_dir=.
2939 $as_echo "PATH: $as_dir"
2940 done
2941 IFS=$as_save_IFS
2942
2943 } >&5
2944
2945 cat >&5 <<_ACEOF
2946
2947
2948 ## ----------- ##
2949 ## Core tests. ##
2950 ## ----------- ##
2951
2952 _ACEOF
2953
2954
2955 # Keep a trace of the command line.
2956 # Strip out --no-create and --no-recursion so they do not pile up.
2957 # Strip out --silent because we don't want to record it for future runs.
2958 # Also quote any args containing shell meta-characters.
2959 # Make two passes to allow for proper duplicate-argument suppression.
2960 ac_configure_args=
2961 ac_configure_args0=
2962 ac_configure_args1=
2963 ac_must_keep_next=false
2964 for ac_pass in 1 2
2965 do
2966 for ac_arg
2967 do
2968 case $ac_arg in
2969 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2970 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2971 | -silent | --silent | --silen | --sile | --sil)
2972 continue ;;
2973 *\'*)
2974 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2975 esac
2976 case $ac_pass in
2977 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2978 2)
2979 as_fn_append ac_configure_args1 " '$ac_arg'"
2980 if test $ac_must_keep_next = true; then
2981 ac_must_keep_next=false # Got value, back to normal.
2982 else
2983 case $ac_arg in
2984 *=* | --config-cache | -C | -disable-* | --disable-* \
2985 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2986 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2987 | -with-* | --with-* | -without-* | --without-* | --x)
2988 case "$ac_configure_args0 " in
2989 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2990 esac
2991 ;;
2992 -* ) ac_must_keep_next=true ;;
2993 esac
2994 fi
2995 as_fn_append ac_configure_args " '$ac_arg'"
2996 ;;
2997 esac
2998 done
2999 done
3000 { ac_configure_args0=; unset ac_configure_args0;}
3001 { ac_configure_args1=; unset ac_configure_args1;}
3002
3003 # When interrupted or exit'd, cleanup temporary files, and complete
3004 # config.log. We remove comments because anyway the quotes in there
3005 # would cause problems or look ugly.
3006 # WARNING: Use '\'' to represent an apostrophe within the trap.
3007 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3008 trap 'exit_status=$?
3009 # Save into config.log some information that might help in debugging.
3010 {
3011 echo
3012
3013 cat <<\_ASBOX
3014 ## ---------------- ##
3015 ## Cache variables. ##
3016 ## ---------------- ##
3017 _ASBOX
3018 echo
3019 # The following way of writing the cache mishandles newlines in values,
3020 (
3021 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3022 eval ac_val=\$$ac_var
3023 case $ac_val in #(
3024 *${as_nl}*)
3025 case $ac_var in #(
3026 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3027 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3028 esac
3029 case $ac_var in #(
3030 _ | IFS | as_nl) ;; #(
3031 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3032 *) { eval $ac_var=; unset $ac_var;} ;;
3033 esac ;;
3034 esac
3035 done
3036 (set) 2>&1 |
3037 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3038 *${as_nl}ac_space=\ *)
3039 sed -n \
3040 "s/'\''/'\''\\\\'\'''\''/g;
3041 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3042 ;; #(
3043 *)
3044 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3045 ;;
3046 esac |
3047 sort
3048 )
3049 echo
3050
3051 cat <<\_ASBOX
3052 ## ----------------- ##
3053 ## Output variables. ##
3054 ## ----------------- ##
3055 _ASBOX
3056 echo
3057 for ac_var in $ac_subst_vars
3058 do
3059 eval ac_val=\$$ac_var
3060 case $ac_val in
3061 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3062 esac
3063 $as_echo "$ac_var='\''$ac_val'\''"
3064 done | sort
3065 echo
3066
3067 if test -n "$ac_subst_files"; then
3068 cat <<\_ASBOX
3069 ## ------------------- ##
3070 ## File substitutions. ##
3071 ## ------------------- ##
3072 _ASBOX
3073 echo
3074 for ac_var in $ac_subst_files
3075 do
3076 eval ac_val=\$$ac_var
3077 case $ac_val in
3078 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3079 esac
3080 $as_echo "$ac_var='\''$ac_val'\''"
3081 done | sort
3082 echo
3083 fi
3084
3085 if test -s confdefs.h; then
3086 cat <<\_ASBOX
3087 ## ----------- ##
3088 ## confdefs.h. ##
3089 ## ----------- ##
3090 _ASBOX
3091 echo
3092 cat confdefs.h
3093 echo
3094 fi
3095 test "$ac_signal" != 0 &&
3096 $as_echo "$as_me: caught signal $ac_signal"
3097 $as_echo "$as_me: exit $exit_status"
3098 } >&5
3099 rm -f core *.core core.conftest.* &&
3100 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3101 exit $exit_status
3102 ' 0
3103 for ac_signal in 1 2 13 15; do
3104 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3105 done
3106 ac_signal=0
3107
3108 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3109 rm -f -r conftest* confdefs.h
3110
3111 $as_echo "/* confdefs.h */" > confdefs.h
3112
3113 # Predefined preprocessor variables.
3114
3115 cat >>confdefs.h <<_ACEOF
3116 #define PACKAGE_NAME "$PACKAGE_NAME"
3117 _ACEOF
3118
3119 cat >>confdefs.h <<_ACEOF
3120 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3121 _ACEOF
3122
3123 cat >>confdefs.h <<_ACEOF
3124 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3125 _ACEOF
3126
3127 cat >>confdefs.h <<_ACEOF
3128 #define PACKAGE_STRING "$PACKAGE_STRING"
3129 _ACEOF
3130
3131 cat >>confdefs.h <<_ACEOF
3132 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3133 _ACEOF
3134
3135 cat >>confdefs.h <<_ACEOF
3136 #define PACKAGE_URL "$PACKAGE_URL"
3137 _ACEOF
3138
3139
3140 # Let the site file select an alternate cache file if it wants to.
3141 # Prefer an explicitly selected file to automatically selected ones.
3142 ac_site_file1=NONE
3143 ac_site_file2=NONE
3144 if test -n "$CONFIG_SITE"; then
3145 ac_site_file1=$CONFIG_SITE
3146 elif test "x$prefix" != xNONE; then
3147 ac_site_file1=$prefix/share/config.site
3148 ac_site_file2=$prefix/etc/config.site
3149 else
3150 ac_site_file1=$ac_default_prefix/share/config.site
3151 ac_site_file2=$ac_default_prefix/etc/config.site
3152 fi
3153 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3154 do
3155 test "x$ac_site_file" = xNONE && continue
3156 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3157 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3158 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3159 sed 's/^/| /' "$ac_site_file" >&5
3160 . "$ac_site_file"
3161 fi
3162 done
3163
3164 if test -r "$cache_file"; then
3165 # Some versions of bash will fail to source /dev/null (special files
3166 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3167 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3168 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3169 $as_echo "$as_me: loading cache $cache_file" >&6;}
3170 case $cache_file in
3171 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3172 *) . "./$cache_file";;
3173 esac
3174 fi
3175 else
3176 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3177 $as_echo "$as_me: creating cache $cache_file" >&6;}
3178 >$cache_file
3179 fi
3180
3181 as_fn_append ac_header_list " linux/version.h"
3182 as_fn_append ac_header_list " sys/systeminfo.h"
3183 as_fn_append ac_header_list " stdio_ext.h"
3184 as_fn_append ac_header_list " fcntl.h"
3185 as_fn_append ac_header_list " coff.h"
3186 as_fn_append ac_header_list " pty.h"
3187 as_fn_append ac_header_list " sys/vlimit.h"
3188 as_fn_append ac_header_list " sys/resource.h"
3189 as_fn_append ac_header_list " sys/utsname.h"
3190 as_fn_append ac_header_list " pwd.h"
3191 as_fn_append ac_header_list " utmp.h"
3192 as_fn_append ac_header_list " dirent.h"
3193 as_fn_append ac_header_list " util.h"
3194 as_fn_append ac_header_list " sys/socket.h"
3195 as_fn_append ac_header_list " stdlib.h"
3196 as_fn_append ac_header_list " unistd.h"
3197 as_fn_append ac_header_list " sys/param.h"
3198 as_fn_append ac_header_list " pthread.h"
3199 as_fn_append ac_header_list " malloc/malloc.h"
3200 as_fn_append ac_header_list " maillock.h"
3201 as_fn_append ac_header_list " sys/un.h"
3202 as_fn_append ac_func_list " tzset"
3203 as_fn_append ac_func_list " readlinkat"
3204 as_fn_append ac_header_list " execinfo.h"
3205 gl_getopt_required=GNU
3206 as_fn_append ac_header_list " getopt.h"
3207 as_fn_append ac_func_list " gettimeofday"
3208 as_fn_append ac_func_list " nanotime"
3209 as_fn_append ac_header_list " sys/time.h"
3210 as_fn_append ac_header_list " wchar.h"
3211 as_fn_append ac_header_list " stdint.h"
3212 as_fn_append ac_header_list " inttypes.h"
3213 as_fn_append ac_func_list " lstat"
3214 as_fn_append ac_func_list " alarm"
3215 as_fn_append ac_header_list " sys/select.h"
3216 as_fn_append ac_func_list " pselect"
3217 as_fn_append ac_func_list " pthread_sigmask"
3218 as_fn_append ac_func_list " readlink"
3219 as_fn_append ac_func_list " strtoimax"
3220 as_fn_append ac_func_list " strtoumax"
3221 as_fn_append ac_func_list " symlink"
3222 as_fn_append ac_header_list " sys/stat.h"
3223 as_fn_append ac_func_list " localtime_r"
3224 as_fn_append ac_header_list " utime.h"
3225 as_fn_append ac_func_list " futimes"
3226 as_fn_append ac_func_list " futimesat"
3227 as_fn_append ac_func_list " futimens"
3228 as_fn_append ac_func_list " utimensat"
3229 as_fn_append ac_func_list " lutimes"
3230 # Check that the precious variables saved in the cache have kept the same
3231 # value.
3232 ac_cache_corrupted=false
3233 for ac_var in $ac_precious_vars; do
3234 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3235 eval ac_new_set=\$ac_env_${ac_var}_set
3236 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3237 eval ac_new_val=\$ac_env_${ac_var}_value
3238 case $ac_old_set,$ac_new_set in
3239 set,)
3240 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3241 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3242 ac_cache_corrupted=: ;;
3243 ,set)
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3245 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3246 ac_cache_corrupted=: ;;
3247 ,);;
3248 *)
3249 if test "x$ac_old_val" != "x$ac_new_val"; then
3250 # differences in whitespace do not lead to failure.
3251 ac_old_val_w=`echo x $ac_old_val`
3252 ac_new_val_w=`echo x $ac_new_val`
3253 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3254 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3255 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3256 ac_cache_corrupted=:
3257 else
3258 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3259 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3260 eval $ac_var=\$ac_old_val
3261 fi
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3263 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3264 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3265 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3266 fi;;
3267 esac
3268 # Pass precious variables to config.status.
3269 if test "$ac_new_set" = set; then
3270 case $ac_new_val in
3271 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3272 *) ac_arg=$ac_var=$ac_new_val ;;
3273 esac
3274 case " $ac_configure_args " in
3275 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3276 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3277 esac
3278 fi
3279 done
3280 if $ac_cache_corrupted; then
3281 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3282 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3283 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3284 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3285 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3286 fi
3287 ## -------------------- ##
3288 ## Main body of script. ##
3289 ## -------------------- ##
3290
3291 ac_ext=c
3292 ac_cpp='$CPP $CPPFLAGS'
3293 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3294 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3295 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3296
3297
3298 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3299
3300
3301 ac_aux_dir=
3302 for ac_dir in build-aux "$srcdir"/build-aux; do
3303 for ac_t in install-sh install.sh shtool; do
3304 if test -f "$ac_dir/$ac_t"; then
3305 ac_aux_dir=$ac_dir
3306 ac_install_sh="$ac_aux_dir/$ac_t -c"
3307 break 2
3308 fi
3309 done
3310 done
3311 if test -z "$ac_aux_dir"; then
3312 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3313 fi
3314
3315 # These three variables are undocumented and unsupported,
3316 # and are intended to be withdrawn in a future Autoconf release.
3317 # They can cause serious problems if a builder's source tree is in a directory
3318 # whose full name contains unusual characters.
3319 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3320 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3321 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3322
3323
3324 am__api_version='1.11'
3325
3326 # Find a good install program. We prefer a C program (faster),
3327 # so one script is as good as another. But avoid the broken or
3328 # incompatible versions:
3329 # SysV /etc/install, /usr/sbin/install
3330 # SunOS /usr/etc/install
3331 # IRIX /sbin/install
3332 # AIX /bin/install
3333 # AmigaOS /C/install, which installs bootblocks on floppy discs
3334 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3335 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3336 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3337 # OS/2's system install, which has a completely different semantic
3338 # ./install, which can be erroneously created by make from ./install.sh.
3339 # Reject install programs that cannot install multiple files.
3340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3341 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3342 if test -z "$INSTALL"; then
3343 if test "${ac_cv_path_install+set}" = set; then :
3344 $as_echo_n "(cached) " >&6
3345 else
3346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3347 for as_dir in $PATH
3348 do
3349 IFS=$as_save_IFS
3350 test -z "$as_dir" && as_dir=.
3351 # Account for people who put trailing slashes in PATH elements.
3352 case $as_dir/ in #((
3353 ./ | .// | /[cC]/* | \
3354 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3355 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3356 /usr/ucb/* ) ;;
3357 *)
3358 # OSF1 and SCO ODT 3.0 have their own names for install.
3359 # Don't use installbsd from OSF since it installs stuff as root
3360 # by default.
3361 for ac_prog in ginstall scoinst install; do
3362 for ac_exec_ext in '' $ac_executable_extensions; do
3363 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3364 if test $ac_prog = install &&
3365 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3366 # AIX install. It has an incompatible calling convention.
3367 :
3368 elif test $ac_prog = install &&
3369 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3370 # program-specific install script used by HP pwplus--don't use.
3371 :
3372 else
3373 rm -rf conftest.one conftest.two conftest.dir
3374 echo one > conftest.one
3375 echo two > conftest.two
3376 mkdir conftest.dir
3377 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3378 test -s conftest.one && test -s conftest.two &&
3379 test -s conftest.dir/conftest.one &&
3380 test -s conftest.dir/conftest.two
3381 then
3382 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3383 break 3
3384 fi
3385 fi
3386 fi
3387 done
3388 done
3389 ;;
3390 esac
3391
3392 done
3393 IFS=$as_save_IFS
3394
3395 rm -rf conftest.one conftest.two conftest.dir
3396
3397 fi
3398 if test "${ac_cv_path_install+set}" = set; then
3399 INSTALL=$ac_cv_path_install
3400 else
3401 # As a last resort, use the slow shell script. Don't cache a
3402 # value for INSTALL within a source directory, because that will
3403 # break other packages using the cache if that directory is
3404 # removed, or if the value is a relative name.
3405 INSTALL=$ac_install_sh
3406 fi
3407 fi
3408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3409 $as_echo "$INSTALL" >&6; }
3410
3411 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3412 # It thinks the first close brace ends the variable substitution.
3413 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3414
3415 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3416
3417 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3418
3419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3420 $as_echo_n "checking whether build environment is sane... " >&6; }
3421 # Just in case
3422 sleep 1
3423 echo timestamp > conftest.file
3424 # Reject unsafe characters in $srcdir or the absolute working directory
3425 # name. Accept space and tab only in the latter.
3426 am_lf='
3427 '
3428 case `pwd` in
3429 *[\\\"\#\$\&\'\`$am_lf]*)
3430 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3431 esac
3432 case $srcdir in
3433 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3434 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3435 esac
3436
3437 # Do `set' in a subshell so we don't clobber the current shell's
3438 # arguments. Must try -L first in case configure is actually a
3439 # symlink; some systems play weird games with the mod time of symlinks
3440 # (eg FreeBSD returns the mod time of the symlink's containing
3441 # directory).
3442 if (
3443 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3444 if test "$*" = "X"; then
3445 # -L didn't work.
3446 set X `ls -t "$srcdir/configure" conftest.file`
3447 fi
3448 rm -f conftest.file
3449 if test "$*" != "X $srcdir/configure conftest.file" \
3450 && test "$*" != "X conftest.file $srcdir/configure"; then
3451
3452 # If neither matched, then we have a broken ls. This can happen
3453 # if, for instance, CONFIG_SHELL is bash and it inherits a
3454 # broken ls alias from the environment. This has actually
3455 # happened. Such a system could not be considered "sane".
3456 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3457 alias in your environment" "$LINENO" 5
3458 fi
3459
3460 test "$2" = conftest.file
3461 )
3462 then
3463 # Ok.
3464 :
3465 else
3466 as_fn_error "newly created file is older than distributed files!
3467 Check your system clock" "$LINENO" 5
3468 fi
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3470 $as_echo "yes" >&6; }
3471 test "$program_prefix" != NONE &&
3472 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3473 # Use a double $ so make ignores it.
3474 test "$program_suffix" != NONE &&
3475 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3476 # Double any \ or $.
3477 # By default was `s,x,x', remove it if useless.
3478 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3479 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3480
3481 # expand $ac_aux_dir to an absolute path
3482 am_aux_dir=`cd $ac_aux_dir && pwd`
3483
3484 if test x"${MISSING+set}" != xset; then
3485 case $am_aux_dir in
3486 *\ * | *\ *)
3487 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3488 *)
3489 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3490 esac
3491 fi
3492 # Use eval to expand $SHELL
3493 if eval "$MISSING --run true"; then
3494 am_missing_run="$MISSING --run "
3495 else
3496 am_missing_run=
3497 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3498 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3499 fi
3500
3501 if test x"${install_sh}" != xset; then
3502 case $am_aux_dir in
3503 *\ * | *\ *)
3504 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3505 *)
3506 install_sh="\${SHELL} $am_aux_dir/install-sh"
3507 esac
3508 fi
3509
3510 # Installed binaries are usually stripped using `strip' when the user
3511 # run `make install-strip'. However `strip' might not be the right
3512 # tool to use in cross-compilation environments, therefore Automake
3513 # will honor the `STRIP' environment variable to overrule this program.
3514 if test "$cross_compiling" != no; then
3515 if test -n "$ac_tool_prefix"; then
3516 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3517 set dummy ${ac_tool_prefix}strip; ac_word=$2
3518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3519 $as_echo_n "checking for $ac_word... " >&6; }
3520 if test "${ac_cv_prog_STRIP+set}" = set; then :
3521 $as_echo_n "(cached) " >&6
3522 else
3523 if test -n "$STRIP"; then
3524 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3525 else
3526 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3527 for as_dir in $PATH
3528 do
3529 IFS=$as_save_IFS
3530 test -z "$as_dir" && as_dir=.
3531 for ac_exec_ext in '' $ac_executable_extensions; do
3532 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3533 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3534 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3535 break 2
3536 fi
3537 done
3538 done
3539 IFS=$as_save_IFS
3540
3541 fi
3542 fi
3543 STRIP=$ac_cv_prog_STRIP
3544 if test -n "$STRIP"; then
3545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3546 $as_echo "$STRIP" >&6; }
3547 else
3548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3549 $as_echo "no" >&6; }
3550 fi
3551
3552
3553 fi
3554 if test -z "$ac_cv_prog_STRIP"; then
3555 ac_ct_STRIP=$STRIP
3556 # Extract the first word of "strip", so it can be a program name with args.
3557 set dummy strip; ac_word=$2
3558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3559 $as_echo_n "checking for $ac_word... " >&6; }
3560 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3561 $as_echo_n "(cached) " >&6
3562 else
3563 if test -n "$ac_ct_STRIP"; then
3564 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3565 else
3566 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3567 for as_dir in $PATH
3568 do
3569 IFS=$as_save_IFS
3570 test -z "$as_dir" && as_dir=.
3571 for ac_exec_ext in '' $ac_executable_extensions; do
3572 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3573 ac_cv_prog_ac_ct_STRIP="strip"
3574 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3575 break 2
3576 fi
3577 done
3578 done
3579 IFS=$as_save_IFS
3580
3581 fi
3582 fi
3583 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3584 if test -n "$ac_ct_STRIP"; then
3585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3586 $as_echo "$ac_ct_STRIP" >&6; }
3587 else
3588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3589 $as_echo "no" >&6; }
3590 fi
3591
3592 if test "x$ac_ct_STRIP" = x; then
3593 STRIP=":"
3594 else
3595 case $cross_compiling:$ac_tool_warned in
3596 yes:)
3597 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3598 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3599 ac_tool_warned=yes ;;
3600 esac
3601 STRIP=$ac_ct_STRIP
3602 fi
3603 else
3604 STRIP="$ac_cv_prog_STRIP"
3605 fi
3606
3607 fi
3608 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3609
3610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3611 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3612 if test -z "$MKDIR_P"; then
3613 if test "${ac_cv_path_mkdir+set}" = set; then :
3614 $as_echo_n "(cached) " >&6
3615 else
3616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3617 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3618 do
3619 IFS=$as_save_IFS
3620 test -z "$as_dir" && as_dir=.
3621 for ac_prog in mkdir gmkdir; do
3622 for ac_exec_ext in '' $ac_executable_extensions; do
3623 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3624 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3625 'mkdir (GNU coreutils) '* | \
3626 'mkdir (coreutils) '* | \
3627 'mkdir (fileutils) '4.1*)
3628 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3629 break 3;;
3630 esac
3631 done
3632 done
3633 done
3634 IFS=$as_save_IFS
3635
3636 fi
3637
3638 test -d ./--version && rmdir ./--version
3639 if test "${ac_cv_path_mkdir+set}" = set; then
3640 MKDIR_P="$ac_cv_path_mkdir -p"
3641 else
3642 # As a last resort, use the slow shell script. Don't cache a
3643 # value for MKDIR_P within a source directory, because that will
3644 # break other packages using the cache if that directory is
3645 # removed, or if the value is a relative name.
3646 MKDIR_P="$ac_install_sh -d"
3647 fi
3648 fi
3649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3650 $as_echo "$MKDIR_P" >&6; }
3651
3652
3653 mkdir_p="$MKDIR_P"
3654 case $mkdir_p in
3655 [\\/$]* | ?:[\\/]*) ;;
3656 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3657 esac
3658
3659 for ac_prog in gawk mawk nawk awk
3660 do
3661 # Extract the first word of "$ac_prog", so it can be a program name with args.
3662 set dummy $ac_prog; ac_word=$2
3663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3664 $as_echo_n "checking for $ac_word... " >&6; }
3665 if test "${ac_cv_prog_AWK+set}" = set; then :
3666 $as_echo_n "(cached) " >&6
3667 else
3668 if test -n "$AWK"; then
3669 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3670 else
3671 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3672 for as_dir in $PATH
3673 do
3674 IFS=$as_save_IFS
3675 test -z "$as_dir" && as_dir=.
3676 for ac_exec_ext in '' $ac_executable_extensions; do
3677 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3678 ac_cv_prog_AWK="$ac_prog"
3679 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3680 break 2
3681 fi
3682 done
3683 done
3684 IFS=$as_save_IFS
3685
3686 fi
3687 fi
3688 AWK=$ac_cv_prog_AWK
3689 if test -n "$AWK"; then
3690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3691 $as_echo "$AWK" >&6; }
3692 else
3693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3694 $as_echo "no" >&6; }
3695 fi
3696
3697
3698 test -n "$AWK" && break
3699 done
3700
3701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3702 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3703 set x ${MAKE-make}
3704 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3705 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3706 $as_echo_n "(cached) " >&6
3707 else
3708 cat >conftest.make <<\_ACEOF
3709 SHELL = /bin/sh
3710 all:
3711 @echo '@@@%%%=$(MAKE)=@@@%%%'
3712 _ACEOF
3713 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3714 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3715 *@@@%%%=?*=@@@%%%*)
3716 eval ac_cv_prog_make_${ac_make}_set=yes;;
3717 *)
3718 eval ac_cv_prog_make_${ac_make}_set=no;;
3719 esac
3720 rm -f conftest.make
3721 fi
3722 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3724 $as_echo "yes" >&6; }
3725 SET_MAKE=
3726 else
3727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3728 $as_echo "no" >&6; }
3729 SET_MAKE="MAKE=${MAKE-make}"
3730 fi
3731
3732 rm -rf .tst 2>/dev/null
3733 mkdir .tst 2>/dev/null
3734 if test -d .tst; then
3735 am__leading_dot=.
3736 else
3737 am__leading_dot=_
3738 fi
3739 rmdir .tst 2>/dev/null
3740
3741 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3742 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3743 # is not polluted with repeated "-I."
3744 am__isrc=' -I$(srcdir)'
3745 # test to see if srcdir already configured
3746 if test -f $srcdir/config.status; then
3747 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3748 fi
3749 fi
3750
3751 # test whether we have cygpath
3752 if test -z "$CYGPATH_W"; then
3753 if (cygpath --version) >/dev/null 2>/dev/null; then
3754 CYGPATH_W='cygpath -w'
3755 else
3756 CYGPATH_W=echo
3757 fi
3758 fi
3759
3760
3761 # Define the identity of the package.
3762 PACKAGE='emacs'
3763 VERSION='24.2.50'
3764
3765
3766 cat >>confdefs.h <<_ACEOF
3767 #define PACKAGE "$PACKAGE"
3768 _ACEOF
3769
3770
3771 cat >>confdefs.h <<_ACEOF
3772 #define VERSION "$VERSION"
3773 _ACEOF
3774
3775 # Some tools Automake needs.
3776
3777 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3778
3779
3780 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3781
3782
3783 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3784
3785
3786 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3787
3788
3789 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3790
3791 # We need awk for the "check" target. The system "awk" is bad on
3792 # some platforms.
3793 # Always define AMTAR for backward compatibility.
3794
3795 AMTAR=${AMTAR-"${am_missing_run}tar"}
3796
3797 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3798
3799
3800
3801
3802
3803
3804
3805
3806 lispdir='${datadir}/emacs/${version}/lisp'
3807 leimdir='${datadir}/emacs/${version}/leim'
3808 standardlisppath='${lispdir}:${leimdir}'
3809 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3810 '${datadir}/emacs/site-lisp'
3811 lisppath='${locallisppath}:${standardlisppath}'
3812 etcdir='${datadir}/emacs/${version}/etc'
3813 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3814 docdir='${datadir}/emacs/${version}/etc'
3815 gamedir='${localstatedir}/games/emacs'
3816
3817
3818 # Check whether --with-all was given.
3819 if test "${with_all+set}" = set; then :
3820 withval=$with_all; with_features=$withval
3821 else
3822 with_features=yes
3823 fi
3824
3825
3826
3827
3828
3829 # Check whether --with-pop was given.
3830 if test "${with_pop+set}" = set; then :
3831 withval=$with_pop;
3832 else
3833 with_pop=$with_features
3834 fi
3835
3836 if test "$with_pop" = yes; then
3837 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3838
3839 fi
3840
3841
3842 # Check whether --with-kerberos was given.
3843 if test "${with_kerberos+set}" = set; then :
3844 withval=$with_kerberos;
3845 else
3846 with_kerberos=no
3847 fi
3848
3849 if test "$with_kerberos" != no; then
3850 $as_echo "#define KERBEROS 1" >>confdefs.h
3851
3852 fi
3853
3854
3855 # Check whether --with-kerberos5 was given.
3856 if test "${with_kerberos5+set}" = set; then :
3857 withval=$with_kerberos5;
3858 else
3859 with_kerberos5=no
3860 fi
3861
3862 if test "${with_kerberos5}" != no; then
3863 if test "${with_kerberos}" = no; then
3864 with_kerberos=yes
3865 $as_echo "#define KERBEROS 1" >>confdefs.h
3866
3867 fi
3868
3869 $as_echo "#define KERBEROS5 1" >>confdefs.h
3870
3871 fi
3872
3873
3874 # Check whether --with-hesiod was given.
3875 if test "${with_hesiod+set}" = set; then :
3876 withval=$with_hesiod;
3877 else
3878 with_hesiod=no
3879 fi
3880
3881 if test "$with_hesiod" != no; then
3882
3883 $as_echo "#define HESIOD 1" >>confdefs.h
3884
3885 fi
3886
3887
3888 # Check whether --with-mmdf was given.
3889 if test "${with_mmdf+set}" = set; then :
3890 withval=$with_mmdf;
3891 else
3892 with_mmdf=no
3893 fi
3894
3895 if test "$with_mmdf" != no; then
3896
3897 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3898
3899 fi
3900
3901
3902 # Check whether --with-mail-unlink was given.
3903 if test "${with_mail_unlink+set}" = set; then :
3904 withval=$with_mail_unlink;
3905 else
3906 with_mail_unlink=no
3907 fi
3908
3909 if test "$with_mail_unlink" != no; then
3910
3911 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3912
3913 fi
3914
3915
3916 # Check whether --with-mailhost was given.
3917 if test "${with_mailhost+set}" = set; then :
3918 withval=$with_mailhost;
3919 cat >>confdefs.h <<_ACEOF
3920 #define MAILHOST "$withval"
3921 _ACEOF
3922
3923 fi
3924
3925
3926
3927 # Check whether --with-sound was given.
3928 if test "${with_sound+set}" = set; then :
3929 withval=$with_sound;
3930 else
3931 with_sound=$with_features
3932 fi
3933
3934
3935
3936 # Check whether --with-sync-input was given.
3937 if test "${with_sync_input+set}" = set; then :
3938 withval=$with_sync_input;
3939 else
3940 with_sync_input=$with_features
3941 fi
3942
3943 if test "$with_sync_input" = yes; then
3944
3945 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
3946
3947 fi
3948
3949
3950 # Check whether --with-x-toolkit was given.
3951 if test "${with_x_toolkit+set}" = set; then :
3952 withval=$with_x_toolkit; case "${withval}" in
3953 y | ye | yes ) val=gtk ;;
3954 n | no ) val=no ;;
3955 l | lu | luc | luci | lucid ) val=lucid ;;
3956 a | at | ath | athe | athen | athena ) val=athena ;;
3957 m | mo | mot | moti | motif ) val=motif ;;
3958 g | gt | gtk ) val=gtk ;;
3959 gtk3 ) val=gtk3 ;;
3960 * )
3961 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3962 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3963 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3964 ;;
3965 esac
3966 with_x_toolkit=$val
3967
3968 fi
3969
3970
3971
3972 # Check whether --with-wide-int was given.
3973 if test "${with_wide_int+set}" = set; then :
3974 withval=$with_wide_int;
3975 else
3976 with_wide_int=no
3977 fi
3978
3979 if test "$with_wide_int" = yes; then
3980
3981 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3982
3983 fi
3984
3985
3986 # Check whether --with-xpm was given.
3987 if test "${with_xpm+set}" = set; then :
3988 withval=$with_xpm;
3989 else
3990 with_xpm=$with_features
3991 fi
3992
3993
3994 # Check whether --with-jpeg was given.
3995 if test "${with_jpeg+set}" = set; then :
3996 withval=$with_jpeg;
3997 else
3998 with_jpeg=$with_features
3999 fi
4000
4001
4002 # Check whether --with-tiff was given.
4003 if test "${with_tiff+set}" = set; then :
4004 withval=$with_tiff;
4005 else
4006 with_tiff=$with_features
4007 fi
4008
4009
4010 # Check whether --with-gif was given.
4011 if test "${with_gif+set}" = set; then :
4012 withval=$with_gif;
4013 else
4014 with_gif=$with_features
4015 fi
4016
4017
4018 # Check whether --with-png was given.
4019 if test "${with_png+set}" = set; then :
4020 withval=$with_png;
4021 else
4022 with_png=$with_features
4023 fi
4024
4025
4026 # Check whether --with-rsvg was given.
4027 if test "${with_rsvg+set}" = set; then :
4028 withval=$with_rsvg;
4029 else
4030 with_rsvg=$with_features
4031 fi
4032
4033
4034 # Check whether --with-xml2 was given.
4035 if test "${with_xml2+set}" = set; then :
4036 withval=$with_xml2;
4037 else
4038 with_xml2=$with_features
4039 fi
4040
4041
4042 # Check whether --with-imagemagick was given.
4043 if test "${with_imagemagick+set}" = set; then :
4044 withval=$with_imagemagick;
4045 else
4046 with_imagemagick=$with_features
4047 fi
4048
4049
4050
4051 # Check whether --with-xft was given.
4052 if test "${with_xft+set}" = set; then :
4053 withval=$with_xft;
4054 else
4055 with_xft=$with_features
4056 fi
4057
4058
4059 # Check whether --with-libotf was given.
4060 if test "${with_libotf+set}" = set; then :
4061 withval=$with_libotf;
4062 else
4063 with_libotf=$with_features
4064 fi
4065
4066
4067 # Check whether --with-m17n-flt was given.
4068 if test "${with_m17n_flt+set}" = set; then :
4069 withval=$with_m17n_flt;
4070 else
4071 with_m17n_flt=$with_features
4072 fi
4073
4074
4075
4076 # Check whether --with-toolkit-scroll-bars was given.
4077 if test "${with_toolkit_scroll_bars+set}" = set; then :
4078 withval=$with_toolkit_scroll_bars;
4079 else
4080 with_toolkit_scroll_bars=$with_features
4081 fi
4082
4083
4084 # Check whether --with-xaw3d was given.
4085 if test "${with_xaw3d+set}" = set; then :
4086 withval=$with_xaw3d;
4087 else
4088 with_xaw3d=$with_features
4089 fi
4090
4091
4092 # Check whether --with-xim was given.
4093 if test "${with_xim+set}" = set; then :
4094 withval=$with_xim;
4095 else
4096 with_xim=$with_features
4097 fi
4098
4099
4100 # Check whether --with-ns was given.
4101 if test "${with_ns+set}" = set; then :
4102 withval=$with_ns;
4103 else
4104 with_ns=no
4105 fi
4106
4107
4108
4109 # Check whether --with-gpm was given.
4110 if test "${with_gpm+set}" = set; then :
4111 withval=$with_gpm;
4112 else
4113 with_gpm=$with_features
4114 fi
4115
4116
4117 # Check whether --with-dbus was given.
4118 if test "${with_dbus+set}" = set; then :
4119 withval=$with_dbus;
4120 else
4121 with_dbus=$with_features
4122 fi
4123
4124
4125 # Check whether --with-gconf was given.
4126 if test "${with_gconf+set}" = set; then :
4127 withval=$with_gconf;
4128 else
4129 with_gconf=$with_features
4130 fi
4131
4132
4133 # Check whether --with-gsettings was given.
4134 if test "${with_gsettings+set}" = set; then :
4135 withval=$with_gsettings;
4136 else
4137 with_gsettings=$with_features
4138 fi
4139
4140
4141 # Check whether --with-selinux was given.
4142 if test "${with_selinux+set}" = set; then :
4143 withval=$with_selinux;
4144 else
4145 with_selinux=$with_features
4146 fi
4147
4148
4149 # Check whether --with-gnutls was given.
4150 if test "${with_gnutls+set}" = set; then :
4151 withval=$with_gnutls;
4152 else
4153 with_gnutls=$with_features
4154 fi
4155
4156
4157 ## For the times when you want to build Emacs but don't have
4158 ## a suitable makeinfo, and can live without the manuals.
4159
4160 # Check whether --with-makeinfo was given.
4161 if test "${with_makeinfo+set}" = set; then :
4162 withval=$with_makeinfo;
4163 else
4164 with_makeinfo=$with_features
4165 fi
4166
4167
4168 ## Makefile.in needs the cache file name.
4169
4170
4171 ## This is an option because I do not know if all info/man support
4172 ## compressed files, nor how to test if they do so.
4173
4174 # Check whether --with-compress-info was given.
4175 if test "${with_compress_info+set}" = set; then :
4176 withval=$with_compress_info;
4177 else
4178 with_compress_info=$with_features
4179 fi
4180
4181 if test $with_compress_info = yes; then
4182 GZIP_INFO=yes
4183 else
4184 GZIP_INFO=
4185 fi
4186
4187
4188
4189 # Check whether --with-pkg-config-prog was given.
4190 if test "${with_pkg_config_prog+set}" = set; then :
4191 withval=$with_pkg_config_prog;
4192 fi
4193
4194 if test "X${with_pkg_config_prog}" != X; then
4195 if test "${with_pkg_config_prog}" != yes; then
4196 PKG_CONFIG="${with_pkg_config_prog}"
4197 fi
4198 fi
4199
4200 CRT_DIR=
4201
4202 # Check whether --with-crt-dir was given.
4203 if test "${with_crt_dir+set}" = set; then :
4204 withval=$with_crt_dir;
4205 fi
4206
4207 CRT_DIR="${with_crt_dir}"
4208
4209
4210 # Check whether --with-gameuser was given.
4211 if test "${with_gameuser+set}" = set; then :
4212 withval=$with_gameuser;
4213 fi
4214
4215 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4216 && gameuser="${with_gameuser}"
4217 test "X$gameuser" = X && gameuser=games
4218
4219
4220 # Check whether --with-gnustep-conf was given.
4221 if test "${with_gnustep_conf+set}" = set; then :
4222 withval=$with_gnustep_conf;
4223 fi
4224
4225 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4226 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4227 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4228 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4229
4230 # Check whether --enable-ns-self-contained was given.
4231 if test "${enable_ns_self_contained+set}" = set; then :
4232 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4233 else
4234 EN_NS_SELF_CONTAINED=yes
4235 fi
4236
4237
4238 # Check whether --enable-locallisppath was given.
4239 if test "${enable_locallisppath+set}" = set; then :
4240 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4241 locallisppath=
4242 elif test "${enableval}" != "yes"; then
4243 locallisppath=${enableval}
4244 fi
4245 fi
4246
4247
4248 # Check whether --enable-checking was given.
4249 if test "${enable_checking+set}" = set; then :
4250 enableval=$enable_checking; ac_checking_flags="${enableval}"
4251 fi
4252
4253 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4254 for check in $ac_checking_flags
4255 do
4256 case $check in
4257 # these set all the flags to specific states
4258 yes) ac_enable_checking=1 ;;
4259 no) ac_enable_checking= ;
4260 ac_gc_check_stringbytes= ;
4261 ac_gc_check_string_overrun= ;
4262 ac_gc_check_string_free_list= ;
4263 ac_xmalloc_overrun= ;
4264 ac_gc_check_cons_list= ;
4265 ac_glyphs_debug= ;;
4266 all) ac_enable_checking=1 ;
4267 ac_gc_check_stringbytes=1 ;
4268 ac_gc_check_string_overrun=1 ;
4269 ac_gc_check_string_free_list=1 ;
4270 ac_xmalloc_overrun=1 ;
4271 ac_gc_check_cons_list=1 ;
4272 ac_glyphs_debug=1 ;;
4273 # these enable particular checks
4274 stringbytes) ac_gc_check_stringbytes=1 ;;
4275 stringoverrun) ac_gc_check_string_overrun=1 ;;
4276 stringfreelist) ac_gc_check_string_free_list=1 ;;
4277 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4278 conslist) ac_gc_check_cons_list=1 ;;
4279 glyphs) ac_glyphs_debug=1 ;;
4280 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4281 esac
4282 done
4283 IFS="$ac_save_IFS"
4284
4285 if test x$ac_enable_checking != x ; then
4286
4287 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4288
4289 fi
4290 if test x$ac_gc_check_stringbytes != x ; then
4291
4292 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4293
4294 fi
4295 if test x$ac_gc_check_string_overrun != x ; then
4296
4297 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4298
4299 fi
4300 if test x$ac_gc_check_string_free_list != x ; then
4301
4302 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4303
4304 fi
4305 if test x$ac_xmalloc_overrun != x ; then
4306
4307 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4308
4309 fi
4310 if test x$ac_gc_check_cons_list != x ; then
4311
4312 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4313
4314 fi
4315 if test x$ac_glyphs_debug != x ; then
4316
4317 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4318
4319 fi
4320
4321 # Check whether --enable-check-lisp-object-type was given.
4322 if test "${enable_check_lisp_object_type+set}" = set; then :
4323 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4324
4325 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4326
4327 fi
4328 fi
4329
4330
4331
4332 # Check whether --enable-profiling was given.
4333 if test "${enable_profiling+set}" = set; then :
4334 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4335 fi
4336
4337 if test x$ac_enable_profiling != x ; then
4338 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4339 else
4340 PROFILING_CFLAGS=
4341 fi
4342
4343
4344 # Check whether --enable-autodepend was given.
4345 if test "${enable_autodepend+set}" = set; then :
4346 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4347 else
4348 ac_enable_autodepend=yes
4349 fi
4350
4351
4352 #### Make srcdir absolute, if it isn't already. It's important to
4353 #### avoid running the path through pwd unnecessarily, since pwd can
4354 #### give you automounter prefixes, which can go away. We do all this
4355 #### so Emacs can find its files when run uninstalled.
4356 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4357 unset CDPATH
4358 case "${srcdir}" in
4359 /* ) ;;
4360 . )
4361 ## We may be able to use the $PWD environment variable to make this
4362 ## absolute. But sometimes PWD is inaccurate.
4363 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4364 ## but that tested only for a well-formed and valid PWD,
4365 ## it did not object when PWD was well-formed and valid but just wrong.
4366 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4367 then
4368 srcdir="$PWD"
4369 else
4370 srcdir="`(cd ${srcdir}; pwd)`"
4371 fi
4372 ;;
4373 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4374 esac
4375
4376 ### Canonicalize the configuration name.
4377
4378 # Make sure we can run config.sub.
4379 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4380 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4381
4382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4383 $as_echo_n "checking build system type... " >&6; }
4384 if test "${ac_cv_build+set}" = set; then :
4385 $as_echo_n "(cached) " >&6
4386 else
4387 ac_build_alias=$build_alias
4388 test "x$ac_build_alias" = x &&
4389 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4390 test "x$ac_build_alias" = x &&
4391 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4392 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4393 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4394
4395 fi
4396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4397 $as_echo "$ac_cv_build" >&6; }
4398 case $ac_cv_build in
4399 *-*-*) ;;
4400 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4401 esac
4402 build=$ac_cv_build
4403 ac_save_IFS=$IFS; IFS='-'
4404 set x $ac_cv_build
4405 shift
4406 build_cpu=$1
4407 build_vendor=$2
4408 shift; shift
4409 # Remember, the first character of IFS is used to create $*,
4410 # except with old shells:
4411 build_os=$*
4412 IFS=$ac_save_IFS
4413 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4414
4415
4416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4417 $as_echo_n "checking host system type... " >&6; }
4418 if test "${ac_cv_host+set}" = set; then :
4419 $as_echo_n "(cached) " >&6
4420 else
4421 if test "x$host_alias" = x; then
4422 ac_cv_host=$ac_cv_build
4423 else
4424 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4425 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4426 fi
4427
4428 fi
4429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4430 $as_echo "$ac_cv_host" >&6; }
4431 case $ac_cv_host in
4432 *-*-*) ;;
4433 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4434 esac
4435 host=$ac_cv_host
4436 ac_save_IFS=$IFS; IFS='-'
4437 set x $ac_cv_host
4438 shift
4439 host_cpu=$1
4440 host_vendor=$2
4441 shift; shift
4442 # Remember, the first character of IFS is used to create $*,
4443 # except with old shells:
4444 host_os=$*
4445 IFS=$ac_save_IFS
4446 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4447
4448
4449 canonical=$host
4450 configuration=${host_alias-${build_alias-$host}}
4451
4452
4453
4454 ### If you add support for a new configuration, add code to this
4455 ### switch statement to recognize your configuration name and select
4456 ### the appropriate operating system file.
4457
4458 ### You would hope that you could choose an s/*.h
4459 ### file based on the operating system portion. However, it turns out
4460 ### that each s/*.h file is pretty manufacturer-specific.
4461 ### So we basically have to have a special case for each
4462 ### configuration name.
4463 ###
4464 ### As far as handling version numbers on operating systems is
4465 ### concerned, make sure things will fail in a fixable way. If
4466 ### /etc/MACHINES doesn't say anything about version numbers, be
4467 ### prepared to handle anything reasonably. If version numbers
4468 ### matter, be sure /etc/MACHINES says something about it.
4469
4470 opsys='' unported=no
4471 case "${canonical}" in
4472
4473 ## GNU/Linux and similar ports
4474 *-*-linux* )
4475 opsys=gnu-linux
4476 ;;
4477
4478 ## FreeBSD ports
4479 *-*-freebsd* )
4480 opsys=freebsd
4481 ;;
4482
4483 ## FreeBSD kernel + glibc based userland
4484 *-*-kfreebsd*gnu* )
4485 opsys=gnu-kfreebsd
4486 ;;
4487
4488 ## NetBSD ports
4489 *-*-netbsd* )
4490 opsys=netbsd
4491 ;;
4492
4493 ## OpenBSD ports
4494 *-*-openbsd* )
4495 opsys=openbsd
4496 ;;
4497
4498 ## Apple Darwin / Mac OS X
4499 *-apple-darwin* )
4500 case "${canonical}" in
4501 i[3456]86-* ) ;;
4502 powerpc-* ) ;;
4503 x86_64-* ) ;;
4504 * ) unported=yes ;;
4505 esac
4506 opsys=darwin
4507 ## Use fink packages if available.
4508 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4509 ## if test -d /sw/include && test -d /sw/lib; then
4510 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4511 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4512 ## fi
4513 ;;
4514
4515 ## HP 9000 series 700 and 800, running HP/UX
4516 hppa*-hp-hpux10.2* )
4517 opsys=hpux10-20
4518 ;;
4519 hppa*-hp-hpux1[1-9]* )
4520 opsys=hpux11
4521 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4522 ;;
4523
4524 ## IBM machines
4525 rs6000-ibm-aix4.[23]* )
4526 opsys=aix4-2
4527 ;;
4528 powerpc-ibm-aix4.[23]* )
4529 opsys=aix4-2
4530 ;;
4531 rs6000-ibm-aix[56]* )
4532 opsys=aix4-2
4533 ;;
4534 powerpc-ibm-aix[56]* )
4535 opsys=aix4-2
4536 ;;
4537
4538 ## Silicon Graphics machines
4539 ## Iris 4D
4540 mips-sgi-irix6.5 )
4541 opsys=irix6-5
4542 # Without defining _LANGUAGE_C, things get masked out in the headers
4543 # so that, for instance, grepping for `free' in stdlib.h fails and
4544 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4545 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4546 ;;
4547
4548 ## Suns
4549 *-sun-solaris* \
4550 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4551 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4552 case "${canonical}" in
4553 i[3456]86-*-* ) ;;
4554 amd64-*-*|x86_64-*-*) ;;
4555 sparc* ) ;;
4556 * ) unported=yes ;;
4557 esac
4558 case "${canonical}" in
4559 *-sunos5.6* | *-solaris2.6* )
4560 opsys=sol2-6
4561 RANLIB="ar -ts"
4562 ;;
4563 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4564 opsys=sol2-6
4565 emacs_check_sunpro_c=yes
4566 ;;
4567 *-sunos5* | *-solaris* )
4568 opsys=sol2-10
4569 emacs_check_sunpro_c=yes
4570 ;;
4571 esac
4572 ## Watch out for a compiler that we know will not work.
4573 case "${canonical}" in
4574 *-solaris* | *-sunos5* )
4575 if [ "x$CC" = x/usr/ucb/cc ]; then
4576 ## /usr/ucb/cc doesn't work;
4577 ## we should find some other compiler that does work.
4578 unset CC
4579 fi
4580 ;;
4581 *) ;;
4582 esac
4583 ;;
4584
4585 ## Intel 386 machines where we don't care about the manufacturer.
4586 i[3456]86-*-* )
4587 case "${canonical}" in
4588 *-cygwin ) opsys=cygwin ;;
4589 *-darwin* ) opsys=darwin ;;
4590 *-sysv4.2uw* ) opsys=unixware ;;
4591 *-sysv5uw* ) opsys=unixware ;;
4592 *-sysv5OpenUNIX* ) opsys=unixware ;;
4593 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4594 esac
4595 ;;
4596
4597 * )
4598 unported=yes
4599 ;;
4600 esac
4601
4602 ### If the code above didn't choose an operating system, just choose
4603 ### an operating system based on the configuration name. You really
4604 ### only want to use this when you have no idea what the right
4605 ### operating system is; if you know what operating systems a machine
4606 ### runs, it's cleaner to make it explicit in the case statement
4607 ### above.
4608 if test x"${opsys}" = x; then
4609 case "${canonical}" in
4610 *-gnu* ) opsys=gnu ;;
4611 * )
4612 unported=yes
4613 ;;
4614 esac
4615 fi
4616
4617
4618
4619 if test $unported = yes; then
4620 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4621 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4622 fi
4623
4624
4625 #### Choose a compiler.
4626
4627 ac_ext=c
4628 ac_cpp='$CPP $CPPFLAGS'
4629 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4630 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4631 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4632 if test -n "$ac_tool_prefix"; then
4633 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4634 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4636 $as_echo_n "checking for $ac_word... " >&6; }
4637 if test "${ac_cv_prog_CC+set}" = set; then :
4638 $as_echo_n "(cached) " >&6
4639 else
4640 if test -n "$CC"; then
4641 ac_cv_prog_CC="$CC" # Let the user override the test.
4642 else
4643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4644 for as_dir in $PATH
4645 do
4646 IFS=$as_save_IFS
4647 test -z "$as_dir" && as_dir=.
4648 for ac_exec_ext in '' $ac_executable_extensions; do
4649 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4650 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4652 break 2
4653 fi
4654 done
4655 done
4656 IFS=$as_save_IFS
4657
4658 fi
4659 fi
4660 CC=$ac_cv_prog_CC
4661 if test -n "$CC"; then
4662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4663 $as_echo "$CC" >&6; }
4664 else
4665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4666 $as_echo "no" >&6; }
4667 fi
4668
4669
4670 fi
4671 if test -z "$ac_cv_prog_CC"; then
4672 ac_ct_CC=$CC
4673 # Extract the first word of "gcc", so it can be a program name with args.
4674 set dummy gcc; ac_word=$2
4675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4676 $as_echo_n "checking for $ac_word... " >&6; }
4677 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4678 $as_echo_n "(cached) " >&6
4679 else
4680 if test -n "$ac_ct_CC"; then
4681 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4682 else
4683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4684 for as_dir in $PATH
4685 do
4686 IFS=$as_save_IFS
4687 test -z "$as_dir" && as_dir=.
4688 for ac_exec_ext in '' $ac_executable_extensions; do
4689 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4690 ac_cv_prog_ac_ct_CC="gcc"
4691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4692 break 2
4693 fi
4694 done
4695 done
4696 IFS=$as_save_IFS
4697
4698 fi
4699 fi
4700 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4701 if test -n "$ac_ct_CC"; then
4702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4703 $as_echo "$ac_ct_CC" >&6; }
4704 else
4705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4706 $as_echo "no" >&6; }
4707 fi
4708
4709 if test "x$ac_ct_CC" = x; then
4710 CC=""
4711 else
4712 case $cross_compiling:$ac_tool_warned in
4713 yes:)
4714 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4715 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4716 ac_tool_warned=yes ;;
4717 esac
4718 CC=$ac_ct_CC
4719 fi
4720 else
4721 CC="$ac_cv_prog_CC"
4722 fi
4723
4724 if test -z "$CC"; then
4725 if test -n "$ac_tool_prefix"; then
4726 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4727 set dummy ${ac_tool_prefix}cc; ac_word=$2
4728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4729 $as_echo_n "checking for $ac_word... " >&6; }
4730 if test "${ac_cv_prog_CC+set}" = set; then :
4731 $as_echo_n "(cached) " >&6
4732 else
4733 if test -n "$CC"; then
4734 ac_cv_prog_CC="$CC" # Let the user override the test.
4735 else
4736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4737 for as_dir in $PATH
4738 do
4739 IFS=$as_save_IFS
4740 test -z "$as_dir" && as_dir=.
4741 for ac_exec_ext in '' $ac_executable_extensions; do
4742 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4743 ac_cv_prog_CC="${ac_tool_prefix}cc"
4744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4745 break 2
4746 fi
4747 done
4748 done
4749 IFS=$as_save_IFS
4750
4751 fi
4752 fi
4753 CC=$ac_cv_prog_CC
4754 if test -n "$CC"; then
4755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4756 $as_echo "$CC" >&6; }
4757 else
4758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4759 $as_echo "no" >&6; }
4760 fi
4761
4762
4763 fi
4764 fi
4765 if test -z "$CC"; then
4766 # Extract the first word of "cc", so it can be a program name with args.
4767 set dummy cc; ac_word=$2
4768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4769 $as_echo_n "checking for $ac_word... " >&6; }
4770 if test "${ac_cv_prog_CC+set}" = set; then :
4771 $as_echo_n "(cached) " >&6
4772 else
4773 if test -n "$CC"; then
4774 ac_cv_prog_CC="$CC" # Let the user override the test.
4775 else
4776 ac_prog_rejected=no
4777 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4778 for as_dir in $PATH
4779 do
4780 IFS=$as_save_IFS
4781 test -z "$as_dir" && as_dir=.
4782 for ac_exec_ext in '' $ac_executable_extensions; do
4783 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4784 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4785 ac_prog_rejected=yes
4786 continue
4787 fi
4788 ac_cv_prog_CC="cc"
4789 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4790 break 2
4791 fi
4792 done
4793 done
4794 IFS=$as_save_IFS
4795
4796 if test $ac_prog_rejected = yes; then
4797 # We found a bogon in the path, so make sure we never use it.
4798 set dummy $ac_cv_prog_CC
4799 shift
4800 if test $# != 0; then
4801 # We chose a different compiler from the bogus one.
4802 # However, it has the same basename, so the bogon will be chosen
4803 # first if we set CC to just the basename; use the full file name.
4804 shift
4805 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4806 fi
4807 fi
4808 fi
4809 fi
4810 CC=$ac_cv_prog_CC
4811 if test -n "$CC"; then
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4813 $as_echo "$CC" >&6; }
4814 else
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4816 $as_echo "no" >&6; }
4817 fi
4818
4819
4820 fi
4821 if test -z "$CC"; then
4822 if test -n "$ac_tool_prefix"; then
4823 for ac_prog in cl.exe
4824 do
4825 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4826 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4828 $as_echo_n "checking for $ac_word... " >&6; }
4829 if test "${ac_cv_prog_CC+set}" = set; then :
4830 $as_echo_n "(cached) " >&6
4831 else
4832 if test -n "$CC"; then
4833 ac_cv_prog_CC="$CC" # Let the user override the test.
4834 else
4835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4836 for as_dir in $PATH
4837 do
4838 IFS=$as_save_IFS
4839 test -z "$as_dir" && as_dir=.
4840 for ac_exec_ext in '' $ac_executable_extensions; do
4841 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4842 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4844 break 2
4845 fi
4846 done
4847 done
4848 IFS=$as_save_IFS
4849
4850 fi
4851 fi
4852 CC=$ac_cv_prog_CC
4853 if test -n "$CC"; then
4854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4855 $as_echo "$CC" >&6; }
4856 else
4857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4858 $as_echo "no" >&6; }
4859 fi
4860
4861
4862 test -n "$CC" && break
4863 done
4864 fi
4865 if test -z "$CC"; then
4866 ac_ct_CC=$CC
4867 for ac_prog in cl.exe
4868 do
4869 # Extract the first word of "$ac_prog", so it can be a program name with args.
4870 set dummy $ac_prog; ac_word=$2
4871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4872 $as_echo_n "checking for $ac_word... " >&6; }
4873 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4874 $as_echo_n "(cached) " >&6
4875 else
4876 if test -n "$ac_ct_CC"; then
4877 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4878 else
4879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4880 for as_dir in $PATH
4881 do
4882 IFS=$as_save_IFS
4883 test -z "$as_dir" && as_dir=.
4884 for ac_exec_ext in '' $ac_executable_extensions; do
4885 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4886 ac_cv_prog_ac_ct_CC="$ac_prog"
4887 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4888 break 2
4889 fi
4890 done
4891 done
4892 IFS=$as_save_IFS
4893
4894 fi
4895 fi
4896 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4897 if test -n "$ac_ct_CC"; then
4898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4899 $as_echo "$ac_ct_CC" >&6; }
4900 else
4901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4902 $as_echo "no" >&6; }
4903 fi
4904
4905
4906 test -n "$ac_ct_CC" && break
4907 done
4908
4909 if test "x$ac_ct_CC" = x; then
4910 CC=""
4911 else
4912 case $cross_compiling:$ac_tool_warned in
4913 yes:)
4914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4915 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4916 ac_tool_warned=yes ;;
4917 esac
4918 CC=$ac_ct_CC
4919 fi
4920 fi
4921
4922 fi
4923
4924
4925 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4926 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4927 as_fn_error "no acceptable C compiler found in \$PATH
4928 See \`config.log' for more details." "$LINENO" 5; }
4929
4930 # Provide some information about the compiler.
4931 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4932 set X $ac_compile
4933 ac_compiler=$2
4934 for ac_option in --version -v -V -qversion; do
4935 { { ac_try="$ac_compiler $ac_option >&5"
4936 case "(($ac_try" in
4937 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4938 *) ac_try_echo=$ac_try;;
4939 esac
4940 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4941 $as_echo "$ac_try_echo"; } >&5
4942 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4943 ac_status=$?
4944 if test -s conftest.err; then
4945 sed '10a\
4946 ... rest of stderr output deleted ...
4947 10q' conftest.err >conftest.er1
4948 cat conftest.er1 >&5
4949 fi
4950 rm -f conftest.er1 conftest.err
4951 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4952 test $ac_status = 0; }
4953 done
4954
4955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4956 /* end confdefs.h. */
4957
4958 int
4959 main ()
4960 {
4961
4962 ;
4963 return 0;
4964 }
4965 _ACEOF
4966 ac_clean_files_save=$ac_clean_files
4967 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4968 # Try to create an executable without -o first, disregard a.out.
4969 # It will help us diagnose broken compilers, and finding out an intuition
4970 # of exeext.
4971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4972 $as_echo_n "checking whether the C compiler works... " >&6; }
4973 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4974
4975 # The possible output files:
4976 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4977
4978 ac_rmfiles=
4979 for ac_file in $ac_files
4980 do
4981 case $ac_file in
4982 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4983 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4984 esac
4985 done
4986 rm -f $ac_rmfiles
4987
4988 if { { ac_try="$ac_link_default"
4989 case "(($ac_try" in
4990 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4991 *) ac_try_echo=$ac_try;;
4992 esac
4993 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4994 $as_echo "$ac_try_echo"; } >&5
4995 (eval "$ac_link_default") 2>&5
4996 ac_status=$?
4997 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4998 test $ac_status = 0; }; then :
4999 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5000 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5001 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5002 # so that the user can short-circuit this test for compilers unknown to
5003 # Autoconf.
5004 for ac_file in $ac_files ''
5005 do
5006 test -f "$ac_file" || continue
5007 case $ac_file in
5008 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5009 ;;
5010 [ab].out )
5011 # We found the default executable, but exeext='' is most
5012 # certainly right.
5013 break;;
5014 *.* )
5015 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5016 then :; else
5017 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5018 fi
5019 # We set ac_cv_exeext here because the later test for it is not
5020 # safe: cross compilers may not add the suffix if given an `-o'
5021 # argument, so we may need to know it at that point already.
5022 # Even if this section looks crufty: it has the advantage of
5023 # actually working.
5024 break;;
5025 * )
5026 break;;
5027 esac
5028 done
5029 test "$ac_cv_exeext" = no && ac_cv_exeext=
5030
5031 else
5032 ac_file=''
5033 fi
5034 if test -z "$ac_file"; then :
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5036 $as_echo "no" >&6; }
5037 $as_echo "$as_me: failed program was:" >&5
5038 sed 's/^/| /' conftest.$ac_ext >&5
5039
5040 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5041 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5042 { as_fn_set_status 77
5043 as_fn_error "C compiler cannot create executables
5044 See \`config.log' for more details." "$LINENO" 5; }; }
5045 else
5046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5047 $as_echo "yes" >&6; }
5048 fi
5049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5050 $as_echo_n "checking for C compiler default output file name... " >&6; }
5051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5052 $as_echo "$ac_file" >&6; }
5053 ac_exeext=$ac_cv_exeext
5054
5055 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5056 ac_clean_files=$ac_clean_files_save
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5058 $as_echo_n "checking for suffix of executables... " >&6; }
5059 if { { ac_try="$ac_link"
5060 case "(($ac_try" in
5061 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5062 *) ac_try_echo=$ac_try;;
5063 esac
5064 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5065 $as_echo "$ac_try_echo"; } >&5
5066 (eval "$ac_link") 2>&5
5067 ac_status=$?
5068 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5069 test $ac_status = 0; }; then :
5070 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5071 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5072 # work properly (i.e., refer to `conftest.exe'), while it won't with
5073 # `rm'.
5074 for ac_file in conftest.exe conftest conftest.*; do
5075 test -f "$ac_file" || continue
5076 case $ac_file in
5077 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5078 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5079 break;;
5080 * ) break;;
5081 esac
5082 done
5083 else
5084 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5085 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5086 as_fn_error "cannot compute suffix of executables: cannot compile and link
5087 See \`config.log' for more details." "$LINENO" 5; }
5088 fi
5089 rm -f conftest conftest$ac_cv_exeext
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5091 $as_echo "$ac_cv_exeext" >&6; }
5092
5093 rm -f conftest.$ac_ext
5094 EXEEXT=$ac_cv_exeext
5095 ac_exeext=$EXEEXT
5096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5097 /* end confdefs.h. */
5098 #include <stdio.h>
5099 int
5100 main ()
5101 {
5102 FILE *f = fopen ("conftest.out", "w");
5103 return ferror (f) || fclose (f) != 0;
5104
5105 ;
5106 return 0;
5107 }
5108 _ACEOF
5109 ac_clean_files="$ac_clean_files conftest.out"
5110 # Check that the compiler produces executables we can run. If not, either
5111 # the compiler is broken, or we cross compile.
5112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5113 $as_echo_n "checking whether we are cross compiling... " >&6; }
5114 if test "$cross_compiling" != yes; then
5115 { { ac_try="$ac_link"
5116 case "(($ac_try" in
5117 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5118 *) ac_try_echo=$ac_try;;
5119 esac
5120 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5121 $as_echo "$ac_try_echo"; } >&5
5122 (eval "$ac_link") 2>&5
5123 ac_status=$?
5124 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5125 test $ac_status = 0; }
5126 if { ac_try='./conftest$ac_cv_exeext'
5127 { { case "(($ac_try" in
5128 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5129 *) ac_try_echo=$ac_try;;
5130 esac
5131 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5132 $as_echo "$ac_try_echo"; } >&5
5133 (eval "$ac_try") 2>&5
5134 ac_status=$?
5135 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5136 test $ac_status = 0; }; }; then
5137 cross_compiling=no
5138 else
5139 if test "$cross_compiling" = maybe; then
5140 cross_compiling=yes
5141 else
5142 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5143 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5144 as_fn_error "cannot run C compiled programs.
5145 If you meant to cross compile, use \`--host'.
5146 See \`config.log' for more details." "$LINENO" 5; }
5147 fi
5148 fi
5149 fi
5150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5151 $as_echo "$cross_compiling" >&6; }
5152
5153 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5154 ac_clean_files=$ac_clean_files_save
5155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5156 $as_echo_n "checking for suffix of object files... " >&6; }
5157 if test "${ac_cv_objext+set}" = set; then :
5158 $as_echo_n "(cached) " >&6
5159 else
5160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5161 /* end confdefs.h. */
5162
5163 int
5164 main ()
5165 {
5166
5167 ;
5168 return 0;
5169 }
5170 _ACEOF
5171 rm -f conftest.o conftest.obj
5172 if { { ac_try="$ac_compile"
5173 case "(($ac_try" in
5174 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5175 *) ac_try_echo=$ac_try;;
5176 esac
5177 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5178 $as_echo "$ac_try_echo"; } >&5
5179 (eval "$ac_compile") 2>&5
5180 ac_status=$?
5181 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5182 test $ac_status = 0; }; then :
5183 for ac_file in conftest.o conftest.obj conftest.*; do
5184 test -f "$ac_file" || continue;
5185 case $ac_file in
5186 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5187 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5188 break;;
5189 esac
5190 done
5191 else
5192 $as_echo "$as_me: failed program was:" >&5
5193 sed 's/^/| /' conftest.$ac_ext >&5
5194
5195 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5196 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5197 as_fn_error "cannot compute suffix of object files: cannot compile
5198 See \`config.log' for more details." "$LINENO" 5; }
5199 fi
5200 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5201 fi
5202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5203 $as_echo "$ac_cv_objext" >&6; }
5204 OBJEXT=$ac_cv_objext
5205 ac_objext=$OBJEXT
5206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5207 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5208 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5209 $as_echo_n "(cached) " >&6
5210 else
5211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5212 /* end confdefs.h. */
5213
5214 int
5215 main ()
5216 {
5217 #ifndef __GNUC__
5218 choke me
5219 #endif
5220
5221 ;
5222 return 0;
5223 }
5224 _ACEOF
5225 if ac_fn_c_try_compile "$LINENO"; then :
5226 ac_compiler_gnu=yes
5227 else
5228 ac_compiler_gnu=no
5229 fi
5230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5231 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5232
5233 fi
5234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5235 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5236 if test $ac_compiler_gnu = yes; then
5237 GCC=yes
5238 else
5239 GCC=
5240 fi
5241 ac_test_CFLAGS=${CFLAGS+set}
5242 ac_save_CFLAGS=$CFLAGS
5243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5244 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5245 if test "${ac_cv_prog_cc_g+set}" = set; then :
5246 $as_echo_n "(cached) " >&6
5247 else
5248 ac_save_c_werror_flag=$ac_c_werror_flag
5249 ac_c_werror_flag=yes
5250 ac_cv_prog_cc_g=no
5251 CFLAGS="-g"
5252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5253 /* end confdefs.h. */
5254
5255 int
5256 main ()
5257 {
5258
5259 ;
5260 return 0;
5261 }
5262 _ACEOF
5263 if ac_fn_c_try_compile "$LINENO"; then :
5264 ac_cv_prog_cc_g=yes
5265 else
5266 CFLAGS=""
5267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5268 /* end confdefs.h. */
5269
5270 int
5271 main ()
5272 {
5273
5274 ;
5275 return 0;
5276 }
5277 _ACEOF
5278 if ac_fn_c_try_compile "$LINENO"; then :
5279
5280 else
5281 ac_c_werror_flag=$ac_save_c_werror_flag
5282 CFLAGS="-g"
5283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5284 /* end confdefs.h. */
5285
5286 int
5287 main ()
5288 {
5289
5290 ;
5291 return 0;
5292 }
5293 _ACEOF
5294 if ac_fn_c_try_compile "$LINENO"; then :
5295 ac_cv_prog_cc_g=yes
5296 fi
5297 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5298 fi
5299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5300 fi
5301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5302 ac_c_werror_flag=$ac_save_c_werror_flag
5303 fi
5304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5305 $as_echo "$ac_cv_prog_cc_g" >&6; }
5306 if test "$ac_test_CFLAGS" = set; then
5307 CFLAGS=$ac_save_CFLAGS
5308 elif test $ac_cv_prog_cc_g = yes; then
5309 if test "$GCC" = yes; then
5310 CFLAGS="-g -O2"
5311 else
5312 CFLAGS="-g"
5313 fi
5314 else
5315 if test "$GCC" = yes; then
5316 CFLAGS="-O2"
5317 else
5318 CFLAGS=
5319 fi
5320 fi
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5322 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5323 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5324 $as_echo_n "(cached) " >&6
5325 else
5326 ac_cv_prog_cc_c89=no
5327 ac_save_CC=$CC
5328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5329 /* end confdefs.h. */
5330 #include <stdarg.h>
5331 #include <stdio.h>
5332 #include <sys/types.h>
5333 #include <sys/stat.h>
5334 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5335 struct buf { int x; };
5336 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5337 static char *e (p, i)
5338 char **p;
5339 int i;
5340 {
5341 return p[i];
5342 }
5343 static char *f (char * (*g) (char **, int), char **p, ...)
5344 {
5345 char *s;
5346 va_list v;
5347 va_start (v,p);
5348 s = g (p, va_arg (v,int));
5349 va_end (v);
5350 return s;
5351 }
5352
5353 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5354 function prototypes and stuff, but not '\xHH' hex character constants.
5355 These don't provoke an error unfortunately, instead are silently treated
5356 as 'x'. The following induces an error, until -std is added to get
5357 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5358 array size at least. It's necessary to write '\x00'==0 to get something
5359 that's true only with -std. */
5360 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5361
5362 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5363 inside strings and character constants. */
5364 #define FOO(x) 'x'
5365 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5366
5367 int test (int i, double x);
5368 struct s1 {int (*f) (int a);};
5369 struct s2 {int (*f) (double a);};
5370 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5371 int argc;
5372 char **argv;
5373 int
5374 main ()
5375 {
5376 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5377 ;
5378 return 0;
5379 }
5380 _ACEOF
5381 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5382 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5383 do
5384 CC="$ac_save_CC $ac_arg"
5385 if ac_fn_c_try_compile "$LINENO"; then :
5386 ac_cv_prog_cc_c89=$ac_arg
5387 fi
5388 rm -f core conftest.err conftest.$ac_objext
5389 test "x$ac_cv_prog_cc_c89" != "xno" && break
5390 done
5391 rm -f conftest.$ac_ext
5392 CC=$ac_save_CC
5393
5394 fi
5395 # AC_CACHE_VAL
5396 case "x$ac_cv_prog_cc_c89" in
5397 x)
5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5399 $as_echo "none needed" >&6; } ;;
5400 xno)
5401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5402 $as_echo "unsupported" >&6; } ;;
5403 *)
5404 CC="$CC $ac_cv_prog_cc_c89"
5405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5406 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5407 esac
5408 if test "x$ac_cv_prog_cc_c89" != xno; then :
5409
5410 fi
5411
5412 ac_ext=c
5413 ac_cpp='$CPP $CPPFLAGS'
5414 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5415 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5416 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5417 DEPDIR="${am__leading_dot}deps"
5418
5419 ac_config_commands="$ac_config_commands depfiles"
5420
5421
5422 am_make=${MAKE-make}
5423 cat > confinc << 'END'
5424 am__doit:
5425 @echo this is the am__doit target
5426 .PHONY: am__doit
5427 END
5428 # If we don't find an include directive, just comment out the code.
5429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5430 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5431 am__include="#"
5432 am__quote=
5433 _am_result=none
5434 # First try GNU make style include.
5435 echo "include confinc" > confmf
5436 # Ignore all kinds of additional output from `make'.
5437 case `$am_make -s -f confmf 2> /dev/null` in #(
5438 *the\ am__doit\ target*)
5439 am__include=include
5440 am__quote=
5441 _am_result=GNU
5442 ;;
5443 esac
5444 # Now try BSD make style include.
5445 if test "$am__include" = "#"; then
5446 echo '.include "confinc"' > confmf
5447 case `$am_make -s -f confmf 2> /dev/null` in #(
5448 *the\ am__doit\ target*)
5449 am__include=.include
5450 am__quote="\""
5451 _am_result=BSD
5452 ;;
5453 esac
5454 fi
5455
5456
5457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5458 $as_echo "$_am_result" >&6; }
5459 rm -f confinc confmf
5460
5461 # Check whether --enable-dependency-tracking was given.
5462 if test "${enable_dependency_tracking+set}" = set; then :
5463 enableval=$enable_dependency_tracking;
5464 fi
5465
5466 if test "x$enable_dependency_tracking" != xno; then
5467 am_depcomp="$ac_aux_dir/depcomp"
5468 AMDEPBACKSLASH='\'
5469 fi
5470 if test "x$enable_dependency_tracking" != xno; then
5471 AMDEP_TRUE=
5472 AMDEP_FALSE='#'
5473 else
5474 AMDEP_TRUE='#'
5475 AMDEP_FALSE=
5476 fi
5477
5478
5479
5480 depcc="$CC" am_compiler_list=
5481
5482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5483 $as_echo_n "checking dependency style of $depcc... " >&6; }
5484 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5485 $as_echo_n "(cached) " >&6
5486 else
5487 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5488 # We make a subdir and do the tests there. Otherwise we can end up
5489 # making bogus files that we don't know about and never remove. For
5490 # instance it was reported that on HP-UX the gcc test will end up
5491 # making a dummy file named `D' -- because `-MD' means `put the output
5492 # in D'.
5493 mkdir conftest.dir
5494 # Copy depcomp to subdir because otherwise we won't find it if we're
5495 # using a relative directory.
5496 cp "$am_depcomp" conftest.dir
5497 cd conftest.dir
5498 # We will build objects and dependencies in a subdirectory because
5499 # it helps to detect inapplicable dependency modes. For instance
5500 # both Tru64's cc and ICC support -MD to output dependencies as a
5501 # side effect of compilation, but ICC will put the dependencies in
5502 # the current directory while Tru64 will put them in the object
5503 # directory.
5504 mkdir sub
5505
5506 am_cv_CC_dependencies_compiler_type=none
5507 if test "$am_compiler_list" = ""; then
5508 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5509 fi
5510 am__universal=false
5511 case " $depcc " in #(
5512 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5513 esac
5514
5515 for depmode in $am_compiler_list; do
5516 # Setup a source with many dependencies, because some compilers
5517 # like to wrap large dependency lists on column 80 (with \), and
5518 # we should not choose a depcomp mode which is confused by this.
5519 #
5520 # We need to recreate these files for each test, as the compiler may
5521 # overwrite some of them when testing with obscure command lines.
5522 # This happens at least with the AIX C compiler.
5523 : > sub/conftest.c
5524 for i in 1 2 3 4 5 6; do
5525 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5526 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5527 # Solaris 8's {/usr,}/bin/sh.
5528 touch sub/conftst$i.h
5529 done
5530 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5531
5532 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5533 # mode. It turns out that the SunPro C++ compiler does not properly
5534 # handle `-M -o', and we need to detect this. Also, some Intel
5535 # versions had trouble with output in subdirs
5536 am__obj=sub/conftest.${OBJEXT-o}
5537 am__minus_obj="-o $am__obj"
5538 case $depmode in
5539 gcc)
5540 # This depmode causes a compiler race in universal mode.
5541 test "$am__universal" = false || continue
5542 ;;
5543 nosideeffect)
5544 # after this tag, mechanisms are not by side-effect, so they'll
5545 # only be used when explicitly requested
5546 if test "x$enable_dependency_tracking" = xyes; then
5547 continue
5548 else
5549 break
5550 fi
5551 ;;
5552 msvisualcpp | msvcmsys)
5553 # This compiler won't grok `-c -o', but also, the minuso test has
5554 # not run yet. These depmodes are late enough in the game, and
5555 # so weak that their functioning should not be impacted.
5556 am__obj=conftest.${OBJEXT-o}
5557 am__minus_obj=
5558 ;;
5559 none) break ;;
5560 esac
5561 if depmode=$depmode \
5562 source=sub/conftest.c object=$am__obj \
5563 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5564 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5565 >/dev/null 2>conftest.err &&
5566 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5567 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5568 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5569 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5570 # icc doesn't choke on unknown options, it will just issue warnings
5571 # or remarks (even with -Werror). So we grep stderr for any message
5572 # that says an option was ignored or not supported.
5573 # When given -MP, icc 7.0 and 7.1 complain thusly:
5574 # icc: Command line warning: ignoring option '-M'; no argument required
5575 # The diagnosis changed in icc 8.0:
5576 # icc: Command line remark: option '-MP' not supported
5577 if (grep 'ignoring option' conftest.err ||
5578 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5579 am_cv_CC_dependencies_compiler_type=$depmode
5580 break
5581 fi
5582 fi
5583 done
5584
5585 cd ..
5586 rm -rf conftest.dir
5587 else
5588 am_cv_CC_dependencies_compiler_type=none
5589 fi
5590
5591 fi
5592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5593 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5594 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5595
5596 if
5597 test "x$enable_dependency_tracking" != xno \
5598 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5599 am__fastdepCC_TRUE=
5600 am__fastdepCC_FALSE='#'
5601 else
5602 am__fastdepCC_TRUE='#'
5603 am__fastdepCC_FALSE=
5604 fi
5605
5606
5607 if test "x$CC" != xcc; then
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5609 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5610 else
5611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5612 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5613 fi
5614 set dummy $CC; ac_cc=`$as_echo "$2" |
5615 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5616 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5617 $as_echo_n "(cached) " >&6
5618 else
5619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5620 /* end confdefs.h. */
5621
5622 int
5623 main ()
5624 {
5625
5626 ;
5627 return 0;
5628 }
5629 _ACEOF
5630 # Make sure it works both with $CC and with simple cc.
5631 # We do the test twice because some compilers refuse to overwrite an
5632 # existing .o file with -o, though they will create one.
5633 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5634 rm -f conftest2.*
5635 if { { case "(($ac_try" in
5636 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5637 *) ac_try_echo=$ac_try;;
5638 esac
5639 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5640 $as_echo "$ac_try_echo"; } >&5
5641 (eval "$ac_try") 2>&5
5642 ac_status=$?
5643 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5644 test $ac_status = 0; } &&
5645 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5646 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5647 *) ac_try_echo=$ac_try;;
5648 esac
5649 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5650 $as_echo "$ac_try_echo"; } >&5
5651 (eval "$ac_try") 2>&5
5652 ac_status=$?
5653 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5654 test $ac_status = 0; };
5655 then
5656 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5657 if test "x$CC" != xcc; then
5658 # Test first that cc exists at all.
5659 if { ac_try='cc -c conftest.$ac_ext >&5'
5660 { { case "(($ac_try" in
5661 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5662 *) ac_try_echo=$ac_try;;
5663 esac
5664 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5665 $as_echo "$ac_try_echo"; } >&5
5666 (eval "$ac_try") 2>&5
5667 ac_status=$?
5668 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5669 test $ac_status = 0; }; }; then
5670 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5671 rm -f conftest2.*
5672 if { { case "(($ac_try" in
5673 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5674 *) ac_try_echo=$ac_try;;
5675 esac
5676 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5677 $as_echo "$ac_try_echo"; } >&5
5678 (eval "$ac_try") 2>&5
5679 ac_status=$?
5680 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5681 test $ac_status = 0; } &&
5682 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5683 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5684 *) ac_try_echo=$ac_try;;
5685 esac
5686 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5687 $as_echo "$ac_try_echo"; } >&5
5688 (eval "$ac_try") 2>&5
5689 ac_status=$?
5690 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5691 test $ac_status = 0; };
5692 then
5693 # cc works too.
5694 :
5695 else
5696 # cc exists but doesn't like -o.
5697 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5698 fi
5699 fi
5700 fi
5701 else
5702 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5703 fi
5704 rm -f core conftest*
5705
5706 fi
5707 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5709 $as_echo "yes" >&6; }
5710 else
5711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5712 $as_echo "no" >&6; }
5713
5714 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5715
5716 fi
5717
5718 # FIXME: we rely on the cache variable name because
5719 # there is no other way.
5720 set dummy $CC
5721 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5722 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5723 if test "$am_t" != yes; then
5724 # Losing compiler, so override with the script.
5725 # FIXME: It is wrong to rewrite CC.
5726 # But if we don't then we get into trouble of one sort or another.
5727 # A longer-term fix would be to have automake use am__CC in this case,
5728 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5729 CC="$am_aux_dir/compile $CC"
5730 fi
5731
5732
5733
5734 if test x$GCC = xyes; then
5735 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5736 else
5737 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5738 fi
5739
5740 # Initialize gnulib right after choosing the compiler.
5741
5742 ac_ext=c
5743 ac_cpp='$CPP $CPPFLAGS'
5744 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5745 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5746 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5748 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5749 # On Suns, sometimes $CPP names a directory.
5750 if test -n "$CPP" && test -d "$CPP"; then
5751 CPP=
5752 fi
5753 if test -z "$CPP"; then
5754 if test "${ac_cv_prog_CPP+set}" = set; then :
5755 $as_echo_n "(cached) " >&6
5756 else
5757 # Double quotes because CPP needs to be expanded
5758 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5759 do
5760 ac_preproc_ok=false
5761 for ac_c_preproc_warn_flag in '' yes
5762 do
5763 # Use a header file that comes with gcc, so configuring glibc
5764 # with a fresh cross-compiler works.
5765 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5766 # <limits.h> exists even on freestanding compilers.
5767 # On the NeXT, cc -E runs the code through the compiler's parser,
5768 # not just through cpp. "Syntax error" is here to catch this case.
5769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5770 /* end confdefs.h. */
5771 #ifdef __STDC__
5772 # include <limits.h>
5773 #else
5774 # include <assert.h>
5775 #endif
5776 Syntax error
5777 _ACEOF
5778 if ac_fn_c_try_cpp "$LINENO"; then :
5779
5780 else
5781 # Broken: fails on valid input.
5782 continue
5783 fi
5784 rm -f conftest.err conftest.$ac_ext
5785
5786 # OK, works on sane cases. Now check whether nonexistent headers
5787 # can be detected and how.
5788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5789 /* end confdefs.h. */
5790 #include <ac_nonexistent.h>
5791 _ACEOF
5792 if ac_fn_c_try_cpp "$LINENO"; then :
5793 # Broken: success on invalid input.
5794 continue
5795 else
5796 # Passes both tests.
5797 ac_preproc_ok=:
5798 break
5799 fi
5800 rm -f conftest.err conftest.$ac_ext
5801
5802 done
5803 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5804 rm -f conftest.err conftest.$ac_ext
5805 if $ac_preproc_ok; then :
5806 break
5807 fi
5808
5809 done
5810 ac_cv_prog_CPP=$CPP
5811
5812 fi
5813 CPP=$ac_cv_prog_CPP
5814 else
5815 ac_cv_prog_CPP=$CPP
5816 fi
5817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5818 $as_echo "$CPP" >&6; }
5819 ac_preproc_ok=false
5820 for ac_c_preproc_warn_flag in '' yes
5821 do
5822 # Use a header file that comes with gcc, so configuring glibc
5823 # with a fresh cross-compiler works.
5824 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5825 # <limits.h> exists even on freestanding compilers.
5826 # On the NeXT, cc -E runs the code through the compiler's parser,
5827 # not just through cpp. "Syntax error" is here to catch this case.
5828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5829 /* end confdefs.h. */
5830 #ifdef __STDC__
5831 # include <limits.h>
5832 #else
5833 # include <assert.h>
5834 #endif
5835 Syntax error
5836 _ACEOF
5837 if ac_fn_c_try_cpp "$LINENO"; then :
5838
5839 else
5840 # Broken: fails on valid input.
5841 continue
5842 fi
5843 rm -f conftest.err conftest.$ac_ext
5844
5845 # OK, works on sane cases. Now check whether nonexistent headers
5846 # can be detected and how.
5847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5848 /* end confdefs.h. */
5849 #include <ac_nonexistent.h>
5850 _ACEOF
5851 if ac_fn_c_try_cpp "$LINENO"; then :
5852 # Broken: success on invalid input.
5853 continue
5854 else
5855 # Passes both tests.
5856 ac_preproc_ok=:
5857 break
5858 fi
5859 rm -f conftest.err conftest.$ac_ext
5860
5861 done
5862 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5863 rm -f conftest.err conftest.$ac_ext
5864 if $ac_preproc_ok; then :
5865
5866 else
5867 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5868 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5869 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5870 See \`config.log' for more details." "$LINENO" 5; }
5871 fi
5872
5873 ac_ext=c
5874 ac_cpp='$CPP $CPPFLAGS'
5875 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5876 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5877 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5878
5879
5880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5881 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5882 if test "${ac_cv_path_GREP+set}" = set; then :
5883 $as_echo_n "(cached) " >&6
5884 else
5885 if test -z "$GREP"; then
5886 ac_path_GREP_found=false
5887 # Loop through the user's path and test for each of PROGNAME-LIST
5888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5889 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5890 do
5891 IFS=$as_save_IFS
5892 test -z "$as_dir" && as_dir=.
5893 for ac_prog in grep ggrep; do
5894 for ac_exec_ext in '' $ac_executable_extensions; do
5895 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5896 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5897 # Check for GNU ac_path_GREP and select it if it is found.
5898 # Check for GNU $ac_path_GREP
5899 case `"$ac_path_GREP" --version 2>&1` in
5900 *GNU*)
5901 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5902 *)
5903 ac_count=0
5904 $as_echo_n 0123456789 >"conftest.in"
5905 while :
5906 do
5907 cat "conftest.in" "conftest.in" >"conftest.tmp"
5908 mv "conftest.tmp" "conftest.in"
5909 cp "conftest.in" "conftest.nl"
5910 $as_echo 'GREP' >> "conftest.nl"
5911 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5912 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5913 as_fn_arith $ac_count + 1 && ac_count=$as_val
5914 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5915 # Best one so far, save it but keep looking for a better one
5916 ac_cv_path_GREP="$ac_path_GREP"
5917 ac_path_GREP_max=$ac_count
5918 fi
5919 # 10*(2^10) chars as input seems more than enough
5920 test $ac_count -gt 10 && break
5921 done
5922 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5923 esac
5924
5925 $ac_path_GREP_found && break 3
5926 done
5927 done
5928 done
5929 IFS=$as_save_IFS
5930 if test -z "$ac_cv_path_GREP"; then
5931 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5932 fi
5933 else
5934 ac_cv_path_GREP=$GREP
5935 fi
5936
5937 fi
5938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5939 $as_echo "$ac_cv_path_GREP" >&6; }
5940 GREP="$ac_cv_path_GREP"
5941
5942
5943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5944 $as_echo_n "checking for egrep... " >&6; }
5945 if test "${ac_cv_path_EGREP+set}" = set; then :
5946 $as_echo_n "(cached) " >&6
5947 else
5948 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5949 then ac_cv_path_EGREP="$GREP -E"
5950 else
5951 if test -z "$EGREP"; then
5952 ac_path_EGREP_found=false
5953 # Loop through the user's path and test for each of PROGNAME-LIST
5954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5955 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5956 do
5957 IFS=$as_save_IFS
5958 test -z "$as_dir" && as_dir=.
5959 for ac_prog in egrep; do
5960 for ac_exec_ext in '' $ac_executable_extensions; do
5961 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5962 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5963 # Check for GNU ac_path_EGREP and select it if it is found.
5964 # Check for GNU $ac_path_EGREP
5965 case `"$ac_path_EGREP" --version 2>&1` in
5966 *GNU*)
5967 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5968 *)
5969 ac_count=0
5970 $as_echo_n 0123456789 >"conftest.in"
5971 while :
5972 do
5973 cat "conftest.in" "conftest.in" >"conftest.tmp"
5974 mv "conftest.tmp" "conftest.in"
5975 cp "conftest.in" "conftest.nl"
5976 $as_echo 'EGREP' >> "conftest.nl"
5977 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5978 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5979 as_fn_arith $ac_count + 1 && ac_count=$as_val
5980 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5981 # Best one so far, save it but keep looking for a better one
5982 ac_cv_path_EGREP="$ac_path_EGREP"
5983 ac_path_EGREP_max=$ac_count
5984 fi
5985 # 10*(2^10) chars as input seems more than enough
5986 test $ac_count -gt 10 && break
5987 done
5988 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5989 esac
5990
5991 $ac_path_EGREP_found && break 3
5992 done
5993 done
5994 done
5995 IFS=$as_save_IFS
5996 if test -z "$ac_cv_path_EGREP"; then
5997 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5998 fi
5999 else
6000 ac_cv_path_EGREP=$EGREP
6001 fi
6002
6003 fi
6004 fi
6005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6006 $as_echo "$ac_cv_path_EGREP" >&6; }
6007 EGREP="$ac_cv_path_EGREP"
6008
6009
6010
6011
6012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6013 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6014 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6015 $as_echo_n "(cached) " >&6
6016 else
6017
6018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6019 /* end confdefs.h. */
6020
6021 #ifdef __ACK__
6022 Amsterdam
6023 #endif
6024
6025 _ACEOF
6026 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6027 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6028 gl_cv_c_amsterdam_compiler=yes
6029 else
6030 gl_cv_c_amsterdam_compiler=no
6031 fi
6032 rm -f conftest*
6033
6034
6035 fi
6036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6037 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6038 if test -z "$AR"; then
6039 if test $gl_cv_c_amsterdam_compiler = yes; then
6040 AR='cc -c.a'
6041 if test -z "$ARFLAGS"; then
6042 ARFLAGS='-o'
6043 fi
6044 else
6045 if test -n "$ac_tool_prefix"; then
6046 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6047 set dummy ${ac_tool_prefix}ar; ac_word=$2
6048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6049 $as_echo_n "checking for $ac_word... " >&6; }
6050 if test "${ac_cv_prog_AR+set}" = set; then :
6051 $as_echo_n "(cached) " >&6
6052 else
6053 if test -n "$AR"; then
6054 ac_cv_prog_AR="$AR" # Let the user override the test.
6055 else
6056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6057 for as_dir in $PATH
6058 do
6059 IFS=$as_save_IFS
6060 test -z "$as_dir" && as_dir=.
6061 for ac_exec_ext in '' $ac_executable_extensions; do
6062 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6063 ac_cv_prog_AR="${ac_tool_prefix}ar"
6064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6065 break 2
6066 fi
6067 done
6068 done
6069 IFS=$as_save_IFS
6070
6071 fi
6072 fi
6073 AR=$ac_cv_prog_AR
6074 if test -n "$AR"; then
6075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6076 $as_echo "$AR" >&6; }
6077 else
6078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6079 $as_echo "no" >&6; }
6080 fi
6081
6082
6083 fi
6084 if test -z "$ac_cv_prog_AR"; then
6085 ac_ct_AR=$AR
6086 # Extract the first word of "ar", so it can be a program name with args.
6087 set dummy ar; ac_word=$2
6088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6089 $as_echo_n "checking for $ac_word... " >&6; }
6090 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6091 $as_echo_n "(cached) " >&6
6092 else
6093 if test -n "$ac_ct_AR"; then
6094 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6095 else
6096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6097 for as_dir in $PATH
6098 do
6099 IFS=$as_save_IFS
6100 test -z "$as_dir" && as_dir=.
6101 for ac_exec_ext in '' $ac_executable_extensions; do
6102 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6103 ac_cv_prog_ac_ct_AR="ar"
6104 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6105 break 2
6106 fi
6107 done
6108 done
6109 IFS=$as_save_IFS
6110
6111 fi
6112 fi
6113 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6114 if test -n "$ac_ct_AR"; then
6115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6116 $as_echo "$ac_ct_AR" >&6; }
6117 else
6118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6119 $as_echo "no" >&6; }
6120 fi
6121
6122 if test "x$ac_ct_AR" = x; then
6123 AR="ar"
6124 else
6125 case $cross_compiling:$ac_tool_warned in
6126 yes:)
6127 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6128 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6129 ac_tool_warned=yes ;;
6130 esac
6131 AR=$ac_ct_AR
6132 fi
6133 else
6134 AR="$ac_cv_prog_AR"
6135 fi
6136
6137 if test -z "$ARFLAGS"; then
6138 ARFLAGS='cru'
6139 fi
6140 fi
6141 else
6142 if test -z "$ARFLAGS"; then
6143 ARFLAGS='cru'
6144 fi
6145 fi
6146
6147
6148 if test -z "$RANLIB"; then
6149 if test $gl_cv_c_amsterdam_compiler = yes; then
6150 RANLIB=':'
6151 else
6152 if test -n "$ac_tool_prefix"; then
6153 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6154 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6156 $as_echo_n "checking for $ac_word... " >&6; }
6157 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6158 $as_echo_n "(cached) " >&6
6159 else
6160 if test -n "$RANLIB"; then
6161 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6162 else
6163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6164 for as_dir in $PATH
6165 do
6166 IFS=$as_save_IFS
6167 test -z "$as_dir" && as_dir=.
6168 for ac_exec_ext in '' $ac_executable_extensions; do
6169 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6170 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6171 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6172 break 2
6173 fi
6174 done
6175 done
6176 IFS=$as_save_IFS
6177
6178 fi
6179 fi
6180 RANLIB=$ac_cv_prog_RANLIB
6181 if test -n "$RANLIB"; then
6182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6183 $as_echo "$RANLIB" >&6; }
6184 else
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6186 $as_echo "no" >&6; }
6187 fi
6188
6189
6190 fi
6191 if test -z "$ac_cv_prog_RANLIB"; then
6192 ac_ct_RANLIB=$RANLIB
6193 # Extract the first word of "ranlib", so it can be a program name with args.
6194 set dummy ranlib; ac_word=$2
6195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6196 $as_echo_n "checking for $ac_word... " >&6; }
6197 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6198 $as_echo_n "(cached) " >&6
6199 else
6200 if test -n "$ac_ct_RANLIB"; then
6201 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6202 else
6203 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6204 for as_dir in $PATH
6205 do
6206 IFS=$as_save_IFS
6207 test -z "$as_dir" && as_dir=.
6208 for ac_exec_ext in '' $ac_executable_extensions; do
6209 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6210 ac_cv_prog_ac_ct_RANLIB="ranlib"
6211 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6212 break 2
6213 fi
6214 done
6215 done
6216 IFS=$as_save_IFS
6217
6218 fi
6219 fi
6220 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6221 if test -n "$ac_ct_RANLIB"; then
6222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6223 $as_echo "$ac_ct_RANLIB" >&6; }
6224 else
6225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6226 $as_echo "no" >&6; }
6227 fi
6228
6229 if test "x$ac_ct_RANLIB" = x; then
6230 RANLIB=":"
6231 else
6232 case $cross_compiling:$ac_tool_warned in
6233 yes:)
6234 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6235 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6236 ac_tool_warned=yes ;;
6237 esac
6238 RANLIB=$ac_ct_RANLIB
6239 fi
6240 else
6241 RANLIB="$ac_cv_prog_RANLIB"
6242 fi
6243
6244 fi
6245 fi
6246
6247
6248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6249 $as_echo_n "checking for ANSI C header files... " >&6; }
6250 if test "${ac_cv_header_stdc+set}" = set; then :
6251 $as_echo_n "(cached) " >&6
6252 else
6253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6254 /* end confdefs.h. */
6255 #include <stdlib.h>
6256 #include <stdarg.h>
6257 #include <string.h>
6258 #include <float.h>
6259
6260 int
6261 main ()
6262 {
6263
6264 ;
6265 return 0;
6266 }
6267 _ACEOF
6268 if ac_fn_c_try_compile "$LINENO"; then :
6269 ac_cv_header_stdc=yes
6270 else
6271 ac_cv_header_stdc=no
6272 fi
6273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6274
6275 if test $ac_cv_header_stdc = yes; then
6276 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6278 /* end confdefs.h. */
6279 #include <string.h>
6280
6281 _ACEOF
6282 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6283 $EGREP "memchr" >/dev/null 2>&1; then :
6284
6285 else
6286 ac_cv_header_stdc=no
6287 fi
6288 rm -f conftest*
6289
6290 fi
6291
6292 if test $ac_cv_header_stdc = yes; then
6293 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6295 /* end confdefs.h. */
6296 #include <stdlib.h>
6297
6298 _ACEOF
6299 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6300 $EGREP "free" >/dev/null 2>&1; then :
6301
6302 else
6303 ac_cv_header_stdc=no
6304 fi
6305 rm -f conftest*
6306
6307 fi
6308
6309 if test $ac_cv_header_stdc = yes; then
6310 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6311 if test "$cross_compiling" = yes; then :
6312 :
6313 else
6314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6315 /* end confdefs.h. */
6316 #include <ctype.h>
6317 #include <stdlib.h>
6318 #if ((' ' & 0x0FF) == 0x020)
6319 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6320 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6321 #else
6322 # define ISLOWER(c) \
6323 (('a' <= (c) && (c) <= 'i') \
6324 || ('j' <= (c) && (c) <= 'r') \
6325 || ('s' <= (c) && (c) <= 'z'))
6326 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6327 #endif
6328
6329 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6330 int
6331 main ()
6332 {
6333 int i;
6334 for (i = 0; i < 256; i++)
6335 if (XOR (islower (i), ISLOWER (i))
6336 || toupper (i) != TOUPPER (i))
6337 return 2;
6338 return 0;
6339 }
6340 _ACEOF
6341 if ac_fn_c_try_run "$LINENO"; then :
6342
6343 else
6344 ac_cv_header_stdc=no
6345 fi
6346 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6347 conftest.$ac_objext conftest.beam conftest.$ac_ext
6348 fi
6349
6350 fi
6351 fi
6352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6353 $as_echo "$ac_cv_header_stdc" >&6; }
6354 if test $ac_cv_header_stdc = yes; then
6355
6356 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6357
6358 fi
6359
6360 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6361 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6362 inttypes.h stdint.h unistd.h
6363 do :
6364 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6365 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6366 "
6367 eval as_val=\$$as_ac_Header
6368 if test "x$as_val" = x""yes; then :
6369 cat >>confdefs.h <<_ACEOF
6370 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6371 _ACEOF
6372
6373 fi
6374
6375 done
6376
6377
6378
6379
6380
6381 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6382 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6383 MINIX=yes
6384 else
6385 MINIX=
6386 fi
6387
6388
6389 if test "$MINIX" = yes; then
6390
6391 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6392
6393
6394 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6395
6396
6397 $as_echo "#define _MINIX 1" >>confdefs.h
6398
6399 fi
6400
6401 case "$host_os" in
6402 hpux*)
6403
6404 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6405
6406 ;;
6407 esac
6408
6409
6410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6411 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6412 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6413 $as_echo_n "(cached) " >&6
6414 else
6415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6416 /* end confdefs.h. */
6417
6418 # define __EXTENSIONS__ 1
6419 $ac_includes_default
6420 int
6421 main ()
6422 {
6423
6424 ;
6425 return 0;
6426 }
6427 _ACEOF
6428 if ac_fn_c_try_compile "$LINENO"; then :
6429 ac_cv_safe_to_define___extensions__=yes
6430 else
6431 ac_cv_safe_to_define___extensions__=no
6432 fi
6433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6434 fi
6435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6436 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6437 test $ac_cv_safe_to_define___extensions__ = yes &&
6438 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6439
6440 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6441
6442 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6443
6444 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6445
6446 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6447
6448 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6449
6450
6451
6452
6453
6454
6455
6456
6457 # Check whether --enable-largefile was given.
6458 if test "${enable_largefile+set}" = set; then :
6459 enableval=$enable_largefile;
6460 fi
6461
6462 if test "$enable_largefile" != no; then
6463
6464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6465 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6466 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6467 $as_echo_n "(cached) " >&6
6468 else
6469 ac_cv_sys_largefile_CC=no
6470 if test "$GCC" != yes; then
6471 ac_save_CC=$CC
6472 while :; do
6473 # IRIX 6.2 and later do not support large files by default,
6474 # so use the C compiler's -n32 option if that helps.
6475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6476 /* end confdefs.h. */
6477 #include <sys/types.h>
6478 /* Check that off_t can represent 2**63 - 1 correctly.
6479 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6480 since some C++ compilers masquerading as C compilers
6481 incorrectly reject 9223372036854775807. */
6482 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6483 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6484 && LARGE_OFF_T % 2147483647 == 1)
6485 ? 1 : -1];
6486 int
6487 main ()
6488 {
6489
6490 ;
6491 return 0;
6492 }
6493 _ACEOF
6494 if ac_fn_c_try_compile "$LINENO"; then :
6495 break
6496 fi
6497 rm -f core conftest.err conftest.$ac_objext
6498 CC="$CC -n32"
6499 if ac_fn_c_try_compile "$LINENO"; then :
6500 ac_cv_sys_largefile_CC=' -n32'; break
6501 fi
6502 rm -f core conftest.err conftest.$ac_objext
6503 break
6504 done
6505 CC=$ac_save_CC
6506 rm -f conftest.$ac_ext
6507 fi
6508 fi
6509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6510 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6511 if test "$ac_cv_sys_largefile_CC" != no; then
6512 CC=$CC$ac_cv_sys_largefile_CC
6513 fi
6514
6515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6516 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6517 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6518 $as_echo_n "(cached) " >&6
6519 else
6520 while :; do
6521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6522 /* end confdefs.h. */
6523 #include <sys/types.h>
6524 /* Check that off_t can represent 2**63 - 1 correctly.
6525 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6526 since some C++ compilers masquerading as C compilers
6527 incorrectly reject 9223372036854775807. */
6528 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6529 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6530 && LARGE_OFF_T % 2147483647 == 1)
6531 ? 1 : -1];
6532 int
6533 main ()
6534 {
6535
6536 ;
6537 return 0;
6538 }
6539 _ACEOF
6540 if ac_fn_c_try_compile "$LINENO"; then :
6541 ac_cv_sys_file_offset_bits=no; break
6542 fi
6543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6545 /* end confdefs.h. */
6546 #define _FILE_OFFSET_BITS 64
6547 #include <sys/types.h>
6548 /* Check that off_t can represent 2**63 - 1 correctly.
6549 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6550 since some C++ compilers masquerading as C compilers
6551 incorrectly reject 9223372036854775807. */
6552 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6553 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6554 && LARGE_OFF_T % 2147483647 == 1)
6555 ? 1 : -1];
6556 int
6557 main ()
6558 {
6559
6560 ;
6561 return 0;
6562 }
6563 _ACEOF
6564 if ac_fn_c_try_compile "$LINENO"; then :
6565 ac_cv_sys_file_offset_bits=64; break
6566 fi
6567 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6568 ac_cv_sys_file_offset_bits=unknown
6569 break
6570 done
6571 fi
6572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6573 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6574 case $ac_cv_sys_file_offset_bits in #(
6575 no | unknown) ;;
6576 *)
6577 cat >>confdefs.h <<_ACEOF
6578 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6579 _ACEOF
6580 ;;
6581 esac
6582 rm -rf conftest*
6583 if test $ac_cv_sys_file_offset_bits = unknown; then
6584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6585 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6586 if test "${ac_cv_sys_large_files+set}" = set; then :
6587 $as_echo_n "(cached) " >&6
6588 else
6589 while :; do
6590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6591 /* end confdefs.h. */
6592 #include <sys/types.h>
6593 /* Check that off_t can represent 2**63 - 1 correctly.
6594 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6595 since some C++ compilers masquerading as C compilers
6596 incorrectly reject 9223372036854775807. */
6597 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6598 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6599 && LARGE_OFF_T % 2147483647 == 1)
6600 ? 1 : -1];
6601 int
6602 main ()
6603 {
6604
6605 ;
6606 return 0;
6607 }
6608 _ACEOF
6609 if ac_fn_c_try_compile "$LINENO"; then :
6610 ac_cv_sys_large_files=no; break
6611 fi
6612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6614 /* end confdefs.h. */
6615 #define _LARGE_FILES 1
6616 #include <sys/types.h>
6617 /* Check that off_t can represent 2**63 - 1 correctly.
6618 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6619 since some C++ compilers masquerading as C compilers
6620 incorrectly reject 9223372036854775807. */
6621 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6622 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6623 && LARGE_OFF_T % 2147483647 == 1)
6624 ? 1 : -1];
6625 int
6626 main ()
6627 {
6628
6629 ;
6630 return 0;
6631 }
6632 _ACEOF
6633 if ac_fn_c_try_compile "$LINENO"; then :
6634 ac_cv_sys_large_files=1; break
6635 fi
6636 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6637 ac_cv_sys_large_files=unknown
6638 break
6639 done
6640 fi
6641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6642 $as_echo "$ac_cv_sys_large_files" >&6; }
6643 case $ac_cv_sys_large_files in #(
6644 no | unknown) ;;
6645 *)
6646 cat >>confdefs.h <<_ACEOF
6647 #define _LARGE_FILES $ac_cv_sys_large_files
6648 _ACEOF
6649 ;;
6650 esac
6651 rm -rf conftest*
6652 fi
6653
6654
6655 fi
6656
6657 case $ac_cv_prog_cc_stdc in #(
6658 no) :
6659 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6660 *) :
6661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6662 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6663 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6664 $as_echo_n "(cached) " >&6
6665 else
6666 ac_cv_prog_cc_c99=no
6667 ac_save_CC=$CC
6668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6669 /* end confdefs.h. */
6670 #include <stdarg.h>
6671 #include <stdbool.h>
6672 #include <stdlib.h>
6673 #include <wchar.h>
6674 #include <stdio.h>
6675
6676 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6677 #define debug(...) fprintf (stderr, __VA_ARGS__)
6678 #define showlist(...) puts (#__VA_ARGS__)
6679 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6680 static void
6681 test_varargs_macros (void)
6682 {
6683 int x = 1234;
6684 int y = 5678;
6685 debug ("Flag");
6686 debug ("X = %d\n", x);
6687 showlist (The first, second, and third items.);
6688 report (x>y, "x is %d but y is %d", x, y);
6689 }
6690
6691 // Check long long types.
6692 #define BIG64 18446744073709551615ull
6693 #define BIG32 4294967295ul
6694 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6695 #if !BIG_OK
6696 your preprocessor is broken;
6697 #endif
6698 #if BIG_OK
6699 #else
6700 your preprocessor is broken;
6701 #endif
6702 static long long int bignum = -9223372036854775807LL;
6703 static unsigned long long int ubignum = BIG64;
6704
6705 struct incomplete_array
6706 {
6707 int datasize;
6708 double data[];
6709 };
6710
6711 struct named_init {
6712 int number;
6713 const wchar_t *name;
6714 double average;
6715 };
6716
6717 typedef const char *ccp;
6718
6719 static inline int
6720 test_restrict (ccp restrict text)
6721 {
6722 // See if C++-style comments work.
6723 // Iterate through items via the restricted pointer.
6724 // Also check for declarations in for loops.
6725 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6726 continue;
6727 return 0;
6728 }
6729
6730 // Check varargs and va_copy.
6731 static void
6732 test_varargs (const char *format, ...)
6733 {
6734 va_list args;
6735 va_start (args, format);
6736 va_list args_copy;
6737 va_copy (args_copy, args);
6738
6739 const char *str;
6740 int number;
6741 float fnumber;
6742
6743 while (*format)
6744 {
6745 switch (*format++)
6746 {
6747 case 's': // string
6748 str = va_arg (args_copy, const char *);
6749 break;
6750 case 'd': // int
6751 number = va_arg (args_copy, int);
6752 break;
6753 case 'f': // float
6754 fnumber = va_arg (args_copy, double);
6755 break;
6756 default:
6757 break;
6758 }
6759 }
6760 va_end (args_copy);
6761 va_end (args);
6762 }
6763
6764 int
6765 main ()
6766 {
6767
6768 // Check bool.
6769 _Bool success = false;
6770
6771 // Check restrict.
6772 if (test_restrict ("String literal") == 0)
6773 success = true;
6774 char *restrict newvar = "Another string";
6775
6776 // Check varargs.
6777 test_varargs ("s, d' f .", "string", 65, 34.234);
6778 test_varargs_macros ();
6779
6780 // Check flexible array members.
6781 struct incomplete_array *ia =
6782 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6783 ia->datasize = 10;
6784 for (int i = 0; i < ia->datasize; ++i)
6785 ia->data[i] = i * 1.234;
6786
6787 // Check named initializers.
6788 struct named_init ni = {
6789 .number = 34,
6790 .name = L"Test wide string",
6791 .average = 543.34343,
6792 };
6793
6794 ni.number = 58;
6795
6796 int dynamic_array[ni.number];
6797 dynamic_array[ni.number - 1] = 543;
6798
6799 // work around unused variable warnings
6800 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6801 || dynamic_array[ni.number - 1] != 543);
6802
6803 ;
6804 return 0;
6805 }
6806 _ACEOF
6807 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6808 do
6809 CC="$ac_save_CC $ac_arg"
6810 if ac_fn_c_try_compile "$LINENO"; then :
6811 ac_cv_prog_cc_c99=$ac_arg
6812 fi
6813 rm -f core conftest.err conftest.$ac_objext
6814 test "x$ac_cv_prog_cc_c99" != "xno" && break
6815 done
6816 rm -f conftest.$ac_ext
6817 CC=$ac_save_CC
6818
6819 fi
6820 # AC_CACHE_VAL
6821 case "x$ac_cv_prog_cc_c99" in
6822 x)
6823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6824 $as_echo "none needed" >&6; } ;;
6825 xno)
6826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6827 $as_echo "unsupported" >&6; } ;;
6828 *)
6829 CC="$CC $ac_cv_prog_cc_c99"
6830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6831 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6832 esac
6833 if test "x$ac_cv_prog_cc_c99" != xno; then :
6834 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6835 else
6836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6837 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6838 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6839 $as_echo_n "(cached) " >&6
6840 else
6841 ac_cv_prog_cc_c89=no
6842 ac_save_CC=$CC
6843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6844 /* end confdefs.h. */
6845 #include <stdarg.h>
6846 #include <stdio.h>
6847 #include <sys/types.h>
6848 #include <sys/stat.h>
6849 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6850 struct buf { int x; };
6851 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6852 static char *e (p, i)
6853 char **p;
6854 int i;
6855 {
6856 return p[i];
6857 }
6858 static char *f (char * (*g) (char **, int), char **p, ...)
6859 {
6860 char *s;
6861 va_list v;
6862 va_start (v,p);
6863 s = g (p, va_arg (v,int));
6864 va_end (v);
6865 return s;
6866 }
6867
6868 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6869 function prototypes and stuff, but not '\xHH' hex character constants.
6870 These don't provoke an error unfortunately, instead are silently treated
6871 as 'x'. The following induces an error, until -std is added to get
6872 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6873 array size at least. It's necessary to write '\x00'==0 to get something
6874 that's true only with -std. */
6875 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6876
6877 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6878 inside strings and character constants. */
6879 #define FOO(x) 'x'
6880 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6881
6882 int test (int i, double x);
6883 struct s1 {int (*f) (int a);};
6884 struct s2 {int (*f) (double a);};
6885 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6886 int argc;
6887 char **argv;
6888 int
6889 main ()
6890 {
6891 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6892 ;
6893 return 0;
6894 }
6895 _ACEOF
6896 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6897 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6898 do
6899 CC="$ac_save_CC $ac_arg"
6900 if ac_fn_c_try_compile "$LINENO"; then :
6901 ac_cv_prog_cc_c89=$ac_arg
6902 fi
6903 rm -f core conftest.err conftest.$ac_objext
6904 test "x$ac_cv_prog_cc_c89" != "xno" && break
6905 done
6906 rm -f conftest.$ac_ext
6907 CC=$ac_save_CC
6908
6909 fi
6910 # AC_CACHE_VAL
6911 case "x$ac_cv_prog_cc_c89" in
6912 x)
6913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6914 $as_echo "none needed" >&6; } ;;
6915 xno)
6916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6917 $as_echo "unsupported" >&6; } ;;
6918 *)
6919 CC="$CC $ac_cv_prog_cc_c89"
6920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6921 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6922 esac
6923 if test "x$ac_cv_prog_cc_c89" != xno; then :
6924 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6925 else
6926 ac_cv_prog_cc_stdc=no
6927 fi
6928
6929 fi
6930 ;;
6931 esac
6932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6933 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6934 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6935 $as_echo_n "(cached) " >&6
6936 fi
6937
6938 case $ac_cv_prog_cc_stdc in #(
6939 no) :
6940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6941 $as_echo "unsupported" >&6; } ;; #(
6942 '') :
6943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6944 $as_echo "none needed" >&6; } ;; #(
6945 *) :
6946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6947 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6948 esac
6949
6950
6951
6952 # Code from module alloca-opt:
6953 # Code from module allocator:
6954 # Code from module c-ctype:
6955 # Code from module c-strcase:
6956 # Code from module careadlinkat:
6957 # Code from module clock-time:
6958 # Code from module crypto/md5:
6959 # Code from module crypto/sha1:
6960 # Code from module crypto/sha256:
6961 # Code from module crypto/sha512:
6962 # Code from module dosname:
6963 # Code from module dtoastr:
6964 # Code from module dtotimespec:
6965 # Code from module dup2:
6966 # Code from module environ:
6967 # Code from module execinfo:
6968 # Code from module extensions:
6969
6970 # Code from module extern-inline:
6971 # Code from module filemode:
6972 # Code from module getloadavg:
6973 # Code from module getopt-gnu:
6974 # Code from module getopt-posix:
6975 # Code from module gettext-h:
6976 # Code from module gettime:
6977 # Code from module gettimeofday:
6978 # Code from module ignore-value:
6979 # Code from module include_next:
6980 # Code from module intprops:
6981 # Code from module inttypes-incomplete:
6982 # Code from module largefile:
6983
6984 # Code from module lstat:
6985 # Code from module manywarnings:
6986 # Code from module mktime:
6987 # Code from module multiarch:
6988 # Code from module nocrash:
6989 # Code from module pathmax:
6990 # Code from module pselect:
6991 # Code from module pthread_sigmask:
6992 # Code from module readlink:
6993 # Code from module signal-h:
6994 # Code from module snippet/_Noreturn:
6995 # Code from module snippet/arg-nonnull:
6996 # Code from module snippet/c++defs:
6997 # Code from module snippet/warn-on-use:
6998 # Code from module socklen:
6999 # Code from module ssize_t:
7000 # Code from module stat:
7001 # Code from module stat-time:
7002 # Code from module stdalign:
7003 # Code from module stdarg:
7004
7005
7006
7007 # Code from module stdbool:
7008 # Code from module stddef:
7009 # Code from module stdint:
7010 # Code from module stdio:
7011 # Code from module stdlib:
7012 # Code from module strftime:
7013 # Code from module strtoimax:
7014 # Code from module strtoll:
7015 # Code from module strtoull:
7016 # Code from module strtoumax:
7017 # Code from module symlink:
7018 # Code from module sys_select:
7019 # Code from module sys_stat:
7020 # Code from module sys_time:
7021 # Code from module time:
7022 # Code from module time_r:
7023 # Code from module timespec:
7024 # Code from module timespec-add:
7025 # Code from module timespec-sub:
7026 # Code from module u64:
7027 # Code from module unistd:
7028 # Code from module utimens:
7029 # Code from module verify:
7030 # Code from module warnings:
7031
7032
7033 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7034 # if -g3 works and the user does not specify CFLAGS.
7035 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7036 if test "$ac_test_CFLAGS" != set; then
7037 case $CFLAGS in
7038 '-g')
7039 emacs_g3_CFLAGS='-g3';;
7040 '-g -O2')
7041 emacs_g3_CFLAGS='-g3 -O2';;
7042 *)
7043 emacs_g3_CFLAGS='';;
7044 esac
7045 if test -n "$emacs_g3_CFLAGS"; then
7046 emacs_save_CFLAGS=$CFLAGS
7047 CFLAGS=$emacs_g3_CFLAGS
7048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7049 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7050 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7051 $as_echo_n "(cached) " >&6
7052 else
7053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7054 /* end confdefs.h. */
7055
7056 int
7057 main ()
7058 {
7059
7060 ;
7061 return 0;
7062 }
7063 _ACEOF
7064 if ac_fn_c_try_link "$LINENO"; then :
7065 emacs_cv_prog_cc_g3=yes
7066 else
7067 emacs_cv_prog_cc_g3=no
7068 fi
7069 rm -f core conftest.err conftest.$ac_objext \
7070 conftest$ac_exeext conftest.$ac_ext
7071 fi
7072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7073 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7074 if test $emacs_cv_prog_cc_g3 = yes; then
7075 CFLAGS=$emacs_g3_CFLAGS
7076 else
7077 CFLAGS=$emacs_save_CFLAGS
7078 fi
7079 fi
7080 fi
7081
7082 # Check whether --enable-gcc-warnings was given.
7083 if test "${enable_gcc_warnings+set}" = set; then :
7084 enableval=$enable_gcc_warnings; case $enableval in
7085 yes|no) ;;
7086 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7087 esac
7088 gl_gcc_warnings=$enableval
7089 else
7090 gl_gcc_warnings=no
7091
7092 fi
7093
7094
7095 # Check whether --enable-link-time-optimization was given.
7096 if test "${enable_link_time_optimization+set}" = set; then :
7097 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7099 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7100 ac_lto_supported=no
7101 if test x$GCC = xyes; then
7102 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7103 if test x$CPUS != x; then
7104 LTO="-flto=$CPUS"
7105 else
7106 LTO="-flto"
7107 fi
7108 old_CFLAGS=$CFLAGS
7109 CFLAGS="$CFLAGS $LTO"
7110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7111 /* end confdefs.h. */
7112
7113 int
7114 main ()
7115 {
7116
7117 ;
7118 return 0;
7119 }
7120 _ACEOF
7121 if ac_fn_c_try_compile "$LINENO"; then :
7122 ac_lto_supported=yes
7123 else
7124 ac_lto_supported=no
7125 fi
7126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7127 CFLAGS="$old_CFLAGS"
7128 fi
7129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7130 $as_echo "$ac_lto_supported" >&6; }
7131 if test "$ac_lto_supported" = "yes"; then
7132 CFLAGS="$CFLAGS $LTO"
7133 fi
7134 fi
7135 fi
7136
7137
7138 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7139 # ------------------------------------------------
7140 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7141 # Otherwise, run RUN-IF-NOT-FOUND.
7142
7143
7144 # When compiling with GCC, prefer -isystem to -I when including system
7145 # include files, to avoid generating useless diagnostics for the files.
7146 if test "$gl_gcc_warnings" != yes; then
7147 isystem='-I'
7148 else
7149 isystem='-isystem '
7150
7151 # This, $nw, is the list of warnings we disable.
7152 nw=
7153
7154 case $with_x_toolkit in
7155 lucid | athena | motif)
7156 # Old toolkits mishandle 'const'.
7157 nw="$nw -Wwrite-strings"
7158 ;;
7159 *)
7160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7161 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7162 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7163 $as_echo_n "(cached) " >&6
7164 else
7165
7166 gl_save_compiler_FLAGS="$CFLAGS"
7167 as_fn_append CFLAGS " -Werror"
7168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7169 /* end confdefs.h. */
7170
7171 int
7172 main ()
7173 {
7174
7175 ;
7176 return 0;
7177 }
7178 _ACEOF
7179 if ac_fn_c_try_compile "$LINENO"; then :
7180 gl_cv_warn_c__Werror=yes
7181 else
7182 gl_cv_warn_c__Werror=no
7183 fi
7184 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7185 CFLAGS="$gl_save_compiler_FLAGS"
7186
7187 fi
7188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7189 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7190 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7191 as_fn_append WERROR_CFLAGS " -Werror"
7192 fi
7193
7194
7195 ;;
7196 esac
7197
7198
7199 nw="$nw -Waggregate-return" # anachronistic
7200 nw="$nw -Wlong-long" # C90 is anachronistic
7201 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7202 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7203 nw="$nw -Wtraditional" # Warns on #elif which we use often
7204 nw="$nw -Wcast-qual" # Too many warnings for now
7205 nw="$nw -Wconversion" # Too many warnings for now
7206 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7207 nw="$nw -Wsign-conversion" # Too many warnings for now
7208 nw="$nw -Woverlength-strings" # Not a problem these days
7209 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7210 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7211 nw="$nw -Wpadded" # Our structs are not padded
7212 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7213 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7214 nw="$nw -Wformat-nonliteral" # we do this a lot
7215 nw="$nw -Wvla" # warnings in gettext.h
7216 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7217 nw="$nw -Wswitch-enum" # Too many warnings for now
7218 nw="$nw -Wswitch-default" # Too many warnings for now
7219 nw="$nw -Wfloat-equal" # warns about high-quality code
7220 nw="$nw -Winline" # OK to ignore 'inline'
7221 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7222 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7223 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7224
7225 # Emacs doesn't care about shadowing; see
7226 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7227 nw="$nw -Wshadow"
7228
7229 # The following lines should be removable at some point.
7230 nw="$nw -Wstack-protector"
7231 nw="$nw -Wstrict-overflow"
7232 nw="$nw -Wsuggest-attribute=pure"
7233
7234
7235
7236 if test -n "$GCC"; then
7237
7238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7239 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7240 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7241 $as_echo_n "(cached) " >&6
7242 else
7243
7244 gl_save_CFLAGS="$CFLAGS"
7245 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7247 /* end confdefs.h. */
7248
7249 int
7250 main ()
7251 {
7252
7253 ;
7254 return 0;
7255 }
7256 _ACEOF
7257 if ac_fn_c_try_compile "$LINENO"; then :
7258 gl_cv_cc_nomfi_supported=yes
7259 else
7260 gl_cv_cc_nomfi_supported=no
7261 fi
7262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7263 CFLAGS="$gl_save_CFLAGS"
7264 fi
7265
7266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7267 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7268
7269 if test "$gl_cv_cc_nomfi_supported" = yes; then
7270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7271 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7272 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7273 $as_echo_n "(cached) " >&6
7274 else
7275
7276 gl_save_CFLAGS="$CFLAGS"
7277 CFLAGS="$CFLAGS -W -Werror"
7278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7279 /* end confdefs.h. */
7280 void f (void)
7281 {
7282 typedef struct { int a; int b; } s_t;
7283 s_t s1 = { 0, };
7284 }
7285
7286 int
7287 main ()
7288 {
7289
7290 ;
7291 return 0;
7292 }
7293 _ACEOF
7294 if ac_fn_c_try_compile "$LINENO"; then :
7295 gl_cv_cc_nomfi_needed=no
7296 else
7297 gl_cv_cc_nomfi_needed=yes
7298 fi
7299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7300 CFLAGS="$gl_save_CFLAGS"
7301
7302 fi
7303
7304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7305 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7306 fi
7307 fi
7308
7309 gl_manywarn_set=
7310 for gl_manywarn_item in \
7311 -W \
7312 -Wabi \
7313 -Waddress \
7314 -Wall \
7315 -Warray-bounds \
7316 -Wattributes \
7317 -Wbad-function-cast \
7318 -Wbuiltin-macro-redefined \
7319 -Wcast-align \
7320 -Wchar-subscripts \
7321 -Wclobbered \
7322 -Wcomment \
7323 -Wcomments \
7324 -Wcoverage-mismatch \
7325 -Wcpp \
7326 -Wdeprecated \
7327 -Wdeprecated-declarations \
7328 -Wdisabled-optimization \
7329 -Wdiv-by-zero \
7330 -Wdouble-promotion \
7331 -Wempty-body \
7332 -Wendif-labels \
7333 -Wenum-compare \
7334 -Wextra \
7335 -Wformat-contains-nul \
7336 -Wformat-extra-args \
7337 -Wformat-nonliteral \
7338 -Wformat-security \
7339 -Wformat-y2k \
7340 -Wformat-zero-length \
7341 -Wformat=2 \
7342 -Wfree-nonheap-object \
7343 -Wignored-qualifiers \
7344 -Wimplicit \
7345 -Wimplicit-function-declaration \
7346 -Wimplicit-int \
7347 -Winit-self \
7348 -Winline \
7349 -Wint-to-pointer-cast \
7350 -Winvalid-memory-model \
7351 -Winvalid-pch \
7352 -Wjump-misses-init \
7353 -Wlogical-op \
7354 -Wmain \
7355 -Wmaybe-uninitialized \
7356 -Wmissing-braces \
7357 -Wmissing-declarations \
7358 -Wmissing-field-initializers \
7359 -Wmissing-format-attribute \
7360 -Wmissing-include-dirs \
7361 -Wmissing-noreturn \
7362 -Wmissing-parameter-type \
7363 -Wmissing-prototypes \
7364 -Wmudflap \
7365 -Wmultichar \
7366 -Wnarrowing \
7367 -Wnested-externs \
7368 -Wnonnull \
7369 -Wnormalized=nfc \
7370 -Wold-style-declaration \
7371 -Wold-style-definition \
7372 -Woverflow \
7373 -Woverlength-strings \
7374 -Woverride-init \
7375 -Wpacked \
7376 -Wpacked-bitfield-compat \
7377 -Wparentheses \
7378 -Wpointer-arith \
7379 -Wpointer-sign \
7380 -Wpointer-to-int-cast \
7381 -Wpragmas \
7382 -Wreturn-type \
7383 -Wsequence-point \
7384 -Wshadow \
7385 -Wsizeof-pointer-memaccess \
7386 -Wstack-protector \
7387 -Wstrict-aliasing \
7388 -Wstrict-overflow \
7389 -Wstrict-prototypes \
7390 -Wsuggest-attribute=const \
7391 -Wsuggest-attribute=format \
7392 -Wsuggest-attribute=noreturn \
7393 -Wsuggest-attribute=pure \
7394 -Wswitch \
7395 -Wswitch-default \
7396 -Wsync-nand \
7397 -Wsystem-headers \
7398 -Wtrampolines \
7399 -Wtrigraphs \
7400 -Wtype-limits \
7401 -Wuninitialized \
7402 -Wunknown-pragmas \
7403 -Wunreachable-code \
7404 -Wunsafe-loop-optimizations \
7405 -Wunused \
7406 -Wunused-but-set-parameter \
7407 -Wunused-but-set-variable \
7408 -Wunused-function \
7409 -Wunused-label \
7410 -Wunused-local-typedefs \
7411 -Wunused-macros \
7412 -Wunused-parameter \
7413 -Wunused-result \
7414 -Wunused-value \
7415 -Wunused-variable \
7416 -Wvarargs \
7417 -Wvariadic-macros \
7418 -Wvector-operation-performance \
7419 -Wvla \
7420 -Wvolatile-register-var \
7421 -Wwrite-strings \
7422 \
7423 ; do
7424 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7425 done
7426
7427 # Disable the missing-field-initializers warning if needed
7428 if test "$gl_cv_cc_nomfi_needed" = yes; then
7429 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7430 fi
7431
7432 ws=$gl_manywarn_set
7433
7434
7435 gl_warn_set=
7436 set x $ws; shift
7437 for gl_warn_item
7438 do
7439 case " $nw " in
7440 *" $gl_warn_item "*)
7441 ;;
7442 *)
7443 gl_warn_set="$gl_warn_set $gl_warn_item"
7444 ;;
7445 esac
7446 done
7447 ws=$gl_warn_set
7448
7449 for w in $ws; do
7450 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7452 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7453 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7454 $as_echo_n "(cached) " >&6
7455 else
7456
7457 gl_save_compiler_FLAGS="$CFLAGS"
7458 as_fn_append CFLAGS " $w"
7459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7460 /* end confdefs.h. */
7461
7462 int
7463 main ()
7464 {
7465
7466 ;
7467 return 0;
7468 }
7469 _ACEOF
7470 if ac_fn_c_try_compile "$LINENO"; then :
7471 eval "$as_gl_Warn=yes"
7472 else
7473 eval "$as_gl_Warn=no"
7474 fi
7475 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7476 CFLAGS="$gl_save_compiler_FLAGS"
7477
7478 fi
7479 eval ac_res=\$$as_gl_Warn
7480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7481 $as_echo "$ac_res" >&6; }
7482 eval as_val=\$$as_gl_Warn
7483 if test "x$as_val" = x""yes; then :
7484 as_fn_append WARN_CFLAGS " $w"
7485 fi
7486
7487
7488 done
7489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7490 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7491 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7492 $as_echo_n "(cached) " >&6
7493 else
7494
7495 gl_save_compiler_FLAGS="$CFLAGS"
7496 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7498 /* end confdefs.h. */
7499
7500 int
7501 main ()
7502 {
7503
7504 ;
7505 return 0;
7506 }
7507 _ACEOF
7508 if ac_fn_c_try_compile "$LINENO"; then :
7509 gl_cv_warn_c__Wno_missing_field_initializers=yes
7510 else
7511 gl_cv_warn_c__Wno_missing_field_initializers=no
7512 fi
7513 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7514 CFLAGS="$gl_save_compiler_FLAGS"
7515
7516 fi
7517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7518 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7519 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7520 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7521 fi
7522
7523 # We need this one
7524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7525 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7526 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7527 $as_echo_n "(cached) " >&6
7528 else
7529
7530 gl_save_compiler_FLAGS="$CFLAGS"
7531 as_fn_append CFLAGS " -Wno-sign-compare"
7532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7533 /* end confdefs.h. */
7534
7535 int
7536 main ()
7537 {
7538
7539 ;
7540 return 0;
7541 }
7542 _ACEOF
7543 if ac_fn_c_try_compile "$LINENO"; then :
7544 gl_cv_warn_c__Wno_sign_compare=yes
7545 else
7546 gl_cv_warn_c__Wno_sign_compare=no
7547 fi
7548 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7549 CFLAGS="$gl_save_compiler_FLAGS"
7550
7551 fi
7552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7553 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7554 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7555 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7556 fi
7557
7558 # Too many warnings for now
7559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7560 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7561 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7562 $as_echo_n "(cached) " >&6
7563 else
7564
7565 gl_save_compiler_FLAGS="$CFLAGS"
7566 as_fn_append CFLAGS " -Wno-type-limits"
7567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7568 /* end confdefs.h. */
7569
7570 int
7571 main ()
7572 {
7573
7574 ;
7575 return 0;
7576 }
7577 _ACEOF
7578 if ac_fn_c_try_compile "$LINENO"; then :
7579 gl_cv_warn_c__Wno_type_limits=yes
7580 else
7581 gl_cv_warn_c__Wno_type_limits=no
7582 fi
7583 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7584 CFLAGS="$gl_save_compiler_FLAGS"
7585
7586 fi
7587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7588 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7589 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7590 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7591 fi
7592
7593 # Too many warnings for now
7594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7595 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7596 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7597 $as_echo_n "(cached) " >&6
7598 else
7599
7600 gl_save_compiler_FLAGS="$CFLAGS"
7601 as_fn_append CFLAGS " -Wno-switch"
7602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7603 /* end confdefs.h. */
7604
7605 int
7606 main ()
7607 {
7608
7609 ;
7610 return 0;
7611 }
7612 _ACEOF
7613 if ac_fn_c_try_compile "$LINENO"; then :
7614 gl_cv_warn_c__Wno_switch=yes
7615 else
7616 gl_cv_warn_c__Wno_switch=no
7617 fi
7618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7619 CFLAGS="$gl_save_compiler_FLAGS"
7620
7621 fi
7622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7623 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7624 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7625 as_fn_append WARN_CFLAGS " -Wno-switch"
7626 fi
7627
7628 # Too many warnings for now
7629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7630 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7631 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7632 $as_echo_n "(cached) " >&6
7633 else
7634
7635 gl_save_compiler_FLAGS="$CFLAGS"
7636 as_fn_append CFLAGS " -Wno-unused-parameter"
7637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7638 /* end confdefs.h. */
7639
7640 int
7641 main ()
7642 {
7643
7644 ;
7645 return 0;
7646 }
7647 _ACEOF
7648 if ac_fn_c_try_compile "$LINENO"; then :
7649 gl_cv_warn_c__Wno_unused_parameter=yes
7650 else
7651 gl_cv_warn_c__Wno_unused_parameter=no
7652 fi
7653 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7654 CFLAGS="$gl_save_compiler_FLAGS"
7655
7656 fi
7657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7658 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7659 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7660 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7661 fi
7662
7663 # Too many warnings for now
7664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7665 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7666 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7667 $as_echo_n "(cached) " >&6
7668 else
7669
7670 gl_save_compiler_FLAGS="$CFLAGS"
7671 as_fn_append CFLAGS " -Wno-format-nonliteral"
7672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7673 /* end confdefs.h. */
7674
7675 int
7676 main ()
7677 {
7678
7679 ;
7680 return 0;
7681 }
7682 _ACEOF
7683 if ac_fn_c_try_compile "$LINENO"; then :
7684 gl_cv_warn_c__Wno_format_nonliteral=yes
7685 else
7686 gl_cv_warn_c__Wno_format_nonliteral=no
7687 fi
7688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7689 CFLAGS="$gl_save_compiler_FLAGS"
7690
7691 fi
7692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7693 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7694 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7695 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7696 fi
7697
7698
7699
7700 # In spite of excluding -Wlogical-op above, it is enabled, as of
7701 # gcc 4.5.0 20090517.
7702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7703 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7704 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7705 $as_echo_n "(cached) " >&6
7706 else
7707
7708 gl_save_compiler_FLAGS="$CFLAGS"
7709 as_fn_append CFLAGS " -Wno-logical-op"
7710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7711 /* end confdefs.h. */
7712
7713 int
7714 main ()
7715 {
7716
7717 ;
7718 return 0;
7719 }
7720 _ACEOF
7721 if ac_fn_c_try_compile "$LINENO"; then :
7722 gl_cv_warn_c__Wno_logical_op=yes
7723 else
7724 gl_cv_warn_c__Wno_logical_op=no
7725 fi
7726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7727 CFLAGS="$gl_save_compiler_FLAGS"
7728
7729 fi
7730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7731 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7732 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7733 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7734 fi
7735
7736
7737
7738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7739 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7740 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7741 $as_echo_n "(cached) " >&6
7742 else
7743
7744 gl_save_compiler_FLAGS="$CFLAGS"
7745 as_fn_append CFLAGS " -fdiagnostics-show-option"
7746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7747 /* end confdefs.h. */
7748
7749 int
7750 main ()
7751 {
7752
7753 ;
7754 return 0;
7755 }
7756 _ACEOF
7757 if ac_fn_c_try_compile "$LINENO"; then :
7758 gl_cv_warn_c__fdiagnostics_show_option=yes
7759 else
7760 gl_cv_warn_c__fdiagnostics_show_option=no
7761 fi
7762 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7763 CFLAGS="$gl_save_compiler_FLAGS"
7764
7765 fi
7766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7767 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7768 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7769 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7770 fi
7771
7772
7773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7774 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7775 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7776 $as_echo_n "(cached) " >&6
7777 else
7778
7779 gl_save_compiler_FLAGS="$CFLAGS"
7780 as_fn_append CFLAGS " -funit-at-a-time"
7781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7782 /* end confdefs.h. */
7783
7784 int
7785 main ()
7786 {
7787
7788 ;
7789 return 0;
7790 }
7791 _ACEOF
7792 if ac_fn_c_try_compile "$LINENO"; then :
7793 gl_cv_warn_c__funit_at_a_time=yes
7794 else
7795 gl_cv_warn_c__funit_at_a_time=no
7796 fi
7797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7798 CFLAGS="$gl_save_compiler_FLAGS"
7799
7800 fi
7801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7802 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7803 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7804 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7805 fi
7806
7807
7808
7809
7810 $as_echo "#define lint 1" >>confdefs.h
7811
7812
7813
7814 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7815
7816
7817 # We use a slightly smaller set of warning options for lib/.
7818 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7819 nw=
7820 nw="$nw -Wunused-macros"
7821
7822
7823 gl_warn_set=
7824 set x $WARN_CFLAGS; shift
7825 for gl_warn_item
7826 do
7827 case " $nw " in
7828 *" $gl_warn_item "*)
7829 ;;
7830 *)
7831 gl_warn_set="$gl_warn_set $gl_warn_item"
7832 ;;
7833 esac
7834 done
7835 GNULIB_WARN_CFLAGS=$gl_warn_set
7836
7837
7838 fi
7839
7840
7841
7842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7843 $as_echo_n "checking whether ln -s works... " >&6; }
7844 LN_S=$as_ln_s
7845 if test "$LN_S" = "ln -s"; then
7846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7847 $as_echo "yes" >&6; }
7848 else
7849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7850 $as_echo "no, using $LN_S" >&6; }
7851 fi
7852
7853
7854 # Extract the first word of "install-info", so it can be a program name with args.
7855 set dummy install-info; ac_word=$2
7856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7857 $as_echo_n "checking for $ac_word... " >&6; }
7858 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7859 $as_echo_n "(cached) " >&6
7860 else
7861 case $INSTALL_INFO in
7862 [\\/]* | ?:[\\/]*)
7863 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7864 ;;
7865 *)
7866 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7867 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7868 do
7869 IFS=$as_save_IFS
7870 test -z "$as_dir" && as_dir=.
7871 for ac_exec_ext in '' $ac_executable_extensions; do
7872 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7873 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7874 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7875 break 2
7876 fi
7877 done
7878 done
7879 IFS=$as_save_IFS
7880
7881 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7882 ;;
7883 esac
7884 fi
7885 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7886 if test -n "$INSTALL_INFO"; then
7887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7888 $as_echo "$INSTALL_INFO" >&6; }
7889 else
7890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7891 $as_echo "no" >&6; }
7892 fi
7893
7894
7895 # Extract the first word of "gzip", so it can be a program name with args.
7896 set dummy gzip; ac_word=$2
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7898 $as_echo_n "checking for $ac_word... " >&6; }
7899 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7900 $as_echo_n "(cached) " >&6
7901 else
7902 case $GZIP_PROG in
7903 [\\/]* | ?:[\\/]*)
7904 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7905 ;;
7906 *)
7907 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7908 for as_dir in $PATH
7909 do
7910 IFS=$as_save_IFS
7911 test -z "$as_dir" && as_dir=.
7912 for ac_exec_ext in '' $ac_executable_extensions; do
7913 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7914 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7915 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7916 break 2
7917 fi
7918 done
7919 done
7920 IFS=$as_save_IFS
7921
7922 ;;
7923 esac
7924 fi
7925 GZIP_PROG=$ac_cv_path_GZIP_PROG
7926 if test -n "$GZIP_PROG"; then
7927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7928 $as_echo "$GZIP_PROG" >&6; }
7929 else
7930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7931 $as_echo "no" >&6; }
7932 fi
7933
7934
7935
7936 if test $opsys = gnu-linux; then
7937 # Extract the first word of "paxctl", so it can be a program name with args.
7938 set dummy paxctl; ac_word=$2
7939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7940 $as_echo_n "checking for $ac_word... " >&6; }
7941 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7942 $as_echo_n "(cached) " >&6
7943 else
7944 case $PAXCTL in
7945 [\\/]* | ?:[\\/]*)
7946 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7947 ;;
7948 *)
7949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7950 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7951 do
7952 IFS=$as_save_IFS
7953 test -z "$as_dir" && as_dir=.
7954 for ac_exec_ext in '' $ac_executable_extensions; do
7955 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7956 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
7957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7958 break 2
7959 fi
7960 done
7961 done
7962 IFS=$as_save_IFS
7963
7964 ;;
7965 esac
7966 fi
7967 PAXCTL=$ac_cv_path_PAXCTL
7968 if test -n "$PAXCTL"; then
7969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
7970 $as_echo "$PAXCTL" >&6; }
7971 else
7972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7973 $as_echo "no" >&6; }
7974 fi
7975
7976
7977 if test "X$PAXCTL" != X; then
7978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
7979 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
7980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7981 /* end confdefs.h. */
7982
7983 int
7984 main ()
7985 {
7986
7987 ;
7988 return 0;
7989 }
7990 _ACEOF
7991 if ac_fn_c_try_link "$LINENO"; then :
7992 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7993 $as_echo "yes" >&6; }
7994 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7995 $as_echo "no" >&6; }; PAXCTL=""; fi
7996 fi
7997 rm -f core conftest.err conftest.$ac_objext \
7998 conftest$ac_exeext conftest.$ac_ext
7999 fi
8000 fi
8001
8002 ## Need makeinfo >= 4.7 (?) to build the manuals.
8003 # Extract the first word of "makeinfo", so it can be a program name with args.
8004 set dummy makeinfo; ac_word=$2
8005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8006 $as_echo_n "checking for $ac_word... " >&6; }
8007 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8008 $as_echo_n "(cached) " >&6
8009 else
8010 case $MAKEINFO in
8011 [\\/]* | ?:[\\/]*)
8012 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8013 ;;
8014 *)
8015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8016 for as_dir in $PATH
8017 do
8018 IFS=$as_save_IFS
8019 test -z "$as_dir" && as_dir=.
8020 for ac_exec_ext in '' $ac_executable_extensions; do
8021 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8022 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8023 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8024 break 2
8025 fi
8026 done
8027 done
8028 IFS=$as_save_IFS
8029
8030 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8031 ;;
8032 esac
8033 fi
8034 MAKEINFO=$ac_cv_path_MAKEINFO
8035 if test -n "$MAKEINFO"; then
8036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8037 $as_echo "$MAKEINFO" >&6; }
8038 else
8039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8040 $as_echo "no" >&6; }
8041 fi
8042
8043
8044 if test "$MAKEINFO" != "no" && \
8045 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
8046 MAKEINFO=no
8047 fi
8048
8049 ## Makeinfo is unusual. For a released Emacs, the manuals are
8050 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8051 ## therefore in the category of "special tools" not normally required, which
8052 ## configure does not have to check for (eg autoconf itself).
8053 ## In a Bazaar checkout on the other hand, the manuals are not included.
8054 ## So makeinfo is a requirement to build from Bazaar, and configure
8055 ## should test for it as it does for any other build requirement.
8056 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8057 ## with pre-built manuals, from a Bazaar checkout.
8058 HAVE_MAKEINFO=yes
8059
8060 if test "$MAKEINFO" = "no"; then
8061 MAKEINFO=makeinfo
8062 if test "x${with_makeinfo}" = "xno"; then
8063 HAVE_MAKEINFO=no
8064 elif test ! -e $srcdir/info/emacs; then
8065 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8066 source tree does not seem to have pre-built manuals in the \`info' directory.
8067 Either install a suitable version of makeinfo, or re-run configure
8068 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8069 fi
8070 fi
8071
8072
8073 INFO_EXT=.info
8074 INFO_OPTS=--no-split
8075
8076
8077
8078
8079 if test x$GCC = xyes; then
8080 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8081 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8082 else
8083 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8084 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8085 fi
8086
8087
8088 late_LDFLAGS=$LDFLAGS
8089 if test x$GCC = xyes; then
8090 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8091 else
8092 LDFLAGS="$LDFLAGS -znocombreloc"
8093 fi
8094
8095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8096 $as_echo_n "checking for -znocombreloc... " >&6; }
8097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8098 /* end confdefs.h. */
8099
8100 int
8101 main ()
8102 {
8103
8104 ;
8105 return 0;
8106 }
8107 _ACEOF
8108 if ac_fn_c_try_link "$LINENO"; then :
8109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8110 $as_echo "yes" >&6; }
8111 else
8112 LDFLAGS=$late_LDFLAGS
8113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8114 $as_echo "no" >&6; }
8115 fi
8116 rm -f core conftest.err conftest.$ac_objext \
8117 conftest$ac_exeext conftest.$ac_ext
8118
8119
8120 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8121 case "$opsys" in
8122 your-opsys-here) CANNOT_DUMP=yes ;;
8123 esac
8124
8125 test "$CANNOT_DUMP" = "yes" && \
8126
8127 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8128
8129
8130
8131
8132
8133 UNEXEC_OBJ=unexelf.o
8134 case "$opsys" in
8135 # MSDOS uses unexcoff.o
8136 # MSWindows uses unexw32.o
8137 aix4-2)
8138 UNEXEC_OBJ=unexaix.o
8139 ;;
8140 cygwin)
8141 UNEXEC_OBJ=unexcw.o
8142 ;;
8143 darwin)
8144 UNEXEC_OBJ=unexmacosx.o
8145 ;;
8146 hpux10-20 | hpux11)
8147 UNEXEC_OBJ=unexhp9k800.o
8148 ;;
8149 sol2-10)
8150 # Use the Solaris dldump() function, called from unexsol.c, to dump
8151 # emacs, instead of the generic ELF dump code found in unexelf.c.
8152 # The resulting binary has a complete symbol table, and is better
8153 # for debugging and other observability tools (debuggers, pstack, etc).
8154 #
8155 # If you encounter a problem using dldump(), please consider sending
8156 # a message to the OpenSolaris tools-linking mailing list:
8157 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8158 #
8159 # It is likely that dldump() works with older Solaris too, but this has
8160 # not been tested, so for now this change is for Solaris 10 or newer.
8161 UNEXEC_OBJ=unexsol.o
8162 ;;
8163 esac
8164
8165 LD_SWITCH_SYSTEM=
8166 case "$opsys" in
8167 freebsd)
8168 ## Let `ld' find image libs and similar things in /usr/local/lib.
8169 ## The system compiler, GCC, has apparently been modified to not
8170 ## look there, contrary to what a stock GCC would do.
8171 ### It's not our place to do this. See bug#10313#17.
8172 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8173 :
8174 ;;
8175
8176 gnu-linux)
8177 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8178 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8179 ;;
8180
8181 netbsd)
8182 ### It's not our place to do this. See bug#10313#17.
8183 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8184 :
8185 ;;
8186
8187 openbsd)
8188 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8189 ## otherwise Emacs dumps core on elf systems.
8190 LD_SWITCH_SYSTEM="-Z"
8191 ;;
8192 esac
8193
8194
8195 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8196
8197 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8198 ## which has not been defined yet. When this was handled with cpp,
8199 ## it was expanded to null when configure sourced the s/*.h file.
8200 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8201 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8202 ## (or somesuch), but because it is supposed to go at the _front_
8203 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8204 ## Compare with the gnu-linux case below, which added to the end
8205 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8206 ## LD_SWITCH_SYSTEM_TEMACS.
8207 case "$opsys" in
8208 netbsd|openbsd)
8209 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8210 esac
8211
8212
8213 C_SWITCH_MACHINE=
8214 case $canonical in
8215 alpha*)
8216 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8217 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8218
8219 fi
8220
8221 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8222 ## With ELF, make sure that all common symbols get allocated to in the
8223 ## data section. Otherwise, the dump of temacs may miss variables in
8224 ## the shared library that have been initialized. For example, with
8225 ## GNU libc, __malloc_initialized would normally be resolved to the
8226 ## shared library's .bss section, which is fatal.
8227 if test "x$GCC" = "xyes"; then
8228 C_SWITCH_MACHINE="-fno-common"
8229 else
8230 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8231 fi
8232 else
8233 UNEXEC_OBJ=unexalpha.o
8234 fi
8235 ;;
8236 esac
8237
8238
8239
8240
8241 C_SWITCH_SYSTEM=
8242 ## Some programs in src produce warnings saying certain subprograms
8243 ## are too complex and need a MAXMEM value greater than 2000 for
8244 ## additional optimization. --nils@exp-math.uni-essen.de
8245 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8246 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8247 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8248 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8249
8250
8251
8252 LIBS_SYSTEM=
8253 case "$opsys" in
8254 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8255 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8256
8257 freebsd) LIBS_SYSTEM="-lutil" ;;
8258
8259 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8260
8261 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8262
8263 ## Motif needs -lgen.
8264 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8265 esac
8266
8267
8268
8269 ### Make sure subsequent tests use flags consistent with the build flags.
8270
8271 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8272 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8273 else
8274 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8275 fi
8276
8277 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8278
8279 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8280
8281
8282
8283 LIB_MATH=-lm
8284 LIB_STANDARD=
8285 START_FILES=
8286 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8287
8288 case $opsys in
8289 cygwin )
8290 LIB_MATH=
8291 START_FILES='pre-crt0.o'
8292 ;;
8293 darwin )
8294 ## Adding -lm confuses the dynamic linker, so omit it.
8295 LIB_MATH=
8296 START_FILES='pre-crt0.o'
8297 ;;
8298 freebsd )
8299 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8300 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8301 SYSTEM_TYPE=berkeley-unix
8302 ;;
8303 gnu-linux | gnu-kfreebsd )
8304 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8305 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8306 ;;
8307 hpux10-20 | hpux11 )
8308 LIB_STANDARD=-lc
8309 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8310 ;;
8311 netbsd | openbsd )
8312 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8313 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8314 SYSTEM_TYPE=berkeley-unix
8315 ;;
8316
8317 sol2* | unixware )
8318 SYSTEM_TYPE=usg-unix-v
8319 ;;
8320
8321 esac
8322
8323
8324
8325
8326 cat >>confdefs.h <<_ACEOF
8327 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8328 _ACEOF
8329
8330
8331 crt_files=
8332
8333 for file in x $LIB_STANDARD $START_FILES; do
8334 case "$file" in
8335 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8336 esac
8337 done
8338
8339 if test "x$crt_files" != x; then
8340
8341 ## If user specified a crt-dir, use that unconditionally.
8342 crt_gcc=no
8343
8344 if test "X$CRT_DIR" = "X"; then
8345
8346 CRT_DIR=/usr/lib # default
8347
8348 case "$canonical" in
8349 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8350 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8351 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8352 ## For anything else (eg /usr/lib32), it is up the user to specify
8353 ## the location (bug#5655).
8354 ## Test for crtn.o, not just the directory, because sometimes the
8355 ## directory exists but does not have the relevant files (bug#1287).
8356 ## FIXME better to test for binary compatibility somehow.
8357 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8358 ;;
8359
8360 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8361 esac
8362
8363 case "$opsys" in
8364 hpux10-20) CRT_DIR=/lib ;;
8365 esac
8366
8367 test "x${GCC}" = xyes && crt_gcc=yes
8368
8369 fi # CRT_DIR = ""
8370
8371 crt_missing=
8372
8373 for file in $crt_files; do
8374
8375 ## If we're using gcc, try to determine it automatically by asking
8376 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8377 ## system-dependent default from above.]
8378 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8379
8380 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8381 case "$crt_file" in
8382 */*)
8383 CRT_DIR=`$as_dirname -- "$crt_file" ||
8384 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8385 X"$crt_file" : 'X\(//\)[^/]' \| \
8386 X"$crt_file" : 'X\(//\)$' \| \
8387 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8388 $as_echo X"$crt_file" |
8389 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8390 s//\1/
8391 q
8392 }
8393 /^X\(\/\/\)[^/].*/{
8394 s//\1/
8395 q
8396 }
8397 /^X\(\/\/\)$/{
8398 s//\1/
8399 q
8400 }
8401 /^X\(\/\).*/{
8402 s//\1/
8403 q
8404 }
8405 s/.*/./; q'`
8406 ;;
8407 esac
8408 fi
8409
8410 crt_gcc=no
8411
8412 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8413 done # $crt_files
8414
8415 test "x$crt_missing" = x || \
8416 as_fn_error "Required file(s) not found:$crt_missing
8417 Try using the --with-crt-dir option." "$LINENO" 5
8418
8419 fi # crt_files != ""
8420
8421
8422
8423 case $opsys in
8424 netbsd | openbsd )
8425 if test -f $CRT_DIR/crti.o; then
8426
8427 test -f $CRT_DIR/crtn.o || \
8428 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8429
8430 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8431 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8432 fi
8433 ;;
8434 esac
8435
8436
8437 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8438 pre_PKG_CONFIG_LIBS=$LIBS
8439
8440 # Extract the first word of "pkg-config", so it can be a program name with args.
8441 set dummy pkg-config; ac_word=$2
8442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8443 $as_echo_n "checking for $ac_word... " >&6; }
8444 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8445 $as_echo_n "(cached) " >&6
8446 else
8447 case $PKG_CONFIG in
8448 [\\/]* | ?:[\\/]*)
8449 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8450 ;;
8451 *)
8452 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8453 for as_dir in $PATH
8454 do
8455 IFS=$as_save_IFS
8456 test -z "$as_dir" && as_dir=.
8457 for ac_exec_ext in '' $ac_executable_extensions; do
8458 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8459 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8460 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8461 break 2
8462 fi
8463 done
8464 done
8465 IFS=$as_save_IFS
8466
8467 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8468 ;;
8469 esac
8470 fi
8471 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8472 if test -n "$PKG_CONFIG"; then
8473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8474 $as_echo "$PKG_CONFIG" >&6; }
8475 else
8476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8477 $as_echo "no" >&6; }
8478 fi
8479
8480
8481
8482
8483
8484
8485 if test "${with_sound}" != "no"; then
8486 # Sound support for GNU/Linux and the free BSDs.
8487 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8488 do :
8489 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8490 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8491 eval as_val=\$$as_ac_Header
8492 if test "x$as_val" = x""yes; then :
8493 cat >>confdefs.h <<_ACEOF
8494 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8495 _ACEOF
8496 have_sound_header=yes
8497 fi
8498
8499 done
8500
8501 # Emulation library used on NetBSD.
8502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8503 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8504 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8505 $as_echo_n "(cached) " >&6
8506 else
8507 ac_check_lib_save_LIBS=$LIBS
8508 LIBS="-lossaudio $LIBS"
8509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8510 /* end confdefs.h. */
8511
8512 /* Override any GCC internal prototype to avoid an error.
8513 Use char because int might match the return type of a GCC
8514 builtin and then its argument prototype would still apply. */
8515 #ifdef __cplusplus
8516 extern "C"
8517 #endif
8518 char _oss_ioctl ();
8519 int
8520 main ()
8521 {
8522 return _oss_ioctl ();
8523 ;
8524 return 0;
8525 }
8526 _ACEOF
8527 if ac_fn_c_try_link "$LINENO"; then :
8528 ac_cv_lib_ossaudio__oss_ioctl=yes
8529 else
8530 ac_cv_lib_ossaudio__oss_ioctl=no
8531 fi
8532 rm -f core conftest.err conftest.$ac_objext \
8533 conftest$ac_exeext conftest.$ac_ext
8534 LIBS=$ac_check_lib_save_LIBS
8535 fi
8536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8537 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8538 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8539 LIBSOUND=-lossaudio
8540 else
8541 LIBSOUND=
8542 fi
8543
8544
8545
8546 ALSA_REQUIRED=1.0.0
8547 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8548
8549 succeeded=no
8550
8551 if test "$PKG_CONFIG" = "no" ; then
8552 HAVE_ALSA=no
8553 else
8554 PKG_CONFIG_MIN_VERSION=0.9.0
8555 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8557 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8558
8559 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8560 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8561 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8562 edit_cflags="
8563 s,///*,/,g
8564 s/^/ /
8565 s/ -I/ $isystem/g
8566 s/^ //
8567 "
8568 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8569 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8571 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8572 succeeded=yes
8573 else
8574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8575 $as_echo "no" >&6; }
8576 ALSA_CFLAGS=""
8577 ALSA_LIBS=""
8578 ## If we have a custom action on failure, don't print errors, but
8579 ## do set a variable so people can do so.
8580 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
8581
8582 fi
8583
8584
8585
8586 else
8587 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8588 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8589 fi
8590 fi
8591
8592 if test $succeeded = yes; then
8593 HAVE_ALSA=yes
8594 else
8595 HAVE_ALSA=no
8596 fi
8597
8598 if test $HAVE_ALSA = yes; then
8599 SAVE_CFLAGS="$CFLAGS"
8600 SAVE_LIBS="$LIBS"
8601 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8602 LIBS="$ALSA_LIBS $LIBS"
8603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8604 /* end confdefs.h. */
8605 #include <asoundlib.h>
8606 int
8607 main ()
8608 {
8609 snd_lib_error_set_handler (0);
8610 ;
8611 return 0;
8612 }
8613 _ACEOF
8614 if ac_fn_c_try_compile "$LINENO"; then :
8615 emacs_alsa_normal=yes
8616 else
8617 emacs_alsa_normal=no
8618 fi
8619 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8620 if test "$emacs_alsa_normal" != yes; then
8621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8622 /* end confdefs.h. */
8623 #include <alsa/asoundlib.h>
8624 int
8625 main ()
8626 {
8627 snd_lib_error_set_handler (0);
8628 ;
8629 return 0;
8630 }
8631 _ACEOF
8632 if ac_fn_c_try_compile "$LINENO"; then :
8633 emacs_alsa_subdir=yes
8634 else
8635 emacs_alsa_subdir=no
8636 fi
8637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8638 if test "$emacs_alsa_subdir" != yes; then
8639 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8640 fi
8641 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8642 fi
8643
8644 CFLAGS="$SAVE_CFLAGS"
8645 LIBS="$SAVE_LIBS"
8646 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8647 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8648
8649 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8650
8651 fi
8652
8653 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8654 case "$opsys" in
8655 gnu-linux|freebsd|netbsd)
8656
8657 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8658
8659 ;;
8660 esac
8661 fi
8662
8663
8664 fi
8665
8666
8667
8668
8669 for ac_header in $ac_header_list
8670 do :
8671 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8672 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8673 "
8674 eval as_val=\$$as_ac_Header
8675 if test "x$as_val" = x""yes; then :
8676 cat >>confdefs.h <<_ACEOF
8677 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8678 _ACEOF
8679
8680 fi
8681
8682 done
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695
8696
8697
8698
8699
8700
8701
8702
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8713 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8715 /* end confdefs.h. */
8716 #include <sys/personality.h>
8717 int
8718 main ()
8719 {
8720 personality (PER_LINUX32)
8721 ;
8722 return 0;
8723 }
8724 _ACEOF
8725 if ac_fn_c_try_compile "$LINENO"; then :
8726 emacs_cv_personality_linux32=yes
8727 else
8728 emacs_cv_personality_linux32=no
8729 fi
8730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8732 $as_echo "$emacs_cv_personality_linux32" >&6; }
8733
8734 if test $emacs_cv_personality_linux32 = yes; then
8735
8736 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8737
8738 fi
8739
8740 for ac_header in term.h
8741 do :
8742 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8743 if test "x$ac_cv_header_term_h" = x""yes; then :
8744 cat >>confdefs.h <<_ACEOF
8745 #define HAVE_TERM_H 1
8746 _ACEOF
8747
8748 fi
8749
8750 done
8751
8752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8753 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8754 if test "${ac_cv_header_time+set}" = set; then :
8755 $as_echo_n "(cached) " >&6
8756 else
8757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8758 /* end confdefs.h. */
8759 #include <sys/types.h>
8760 #include <sys/time.h>
8761 #include <time.h>
8762
8763 int
8764 main ()
8765 {
8766 if ((struct tm *) 0)
8767 return 0;
8768 ;
8769 return 0;
8770 }
8771 _ACEOF
8772 if ac_fn_c_try_compile "$LINENO"; then :
8773 ac_cv_header_time=yes
8774 else
8775 ac_cv_header_time=no
8776 fi
8777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8778 fi
8779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8780 $as_echo "$ac_cv_header_time" >&6; }
8781 if test $ac_cv_header_time = yes; then
8782
8783 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8784
8785 fi
8786
8787 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8788 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8789 ac_have_decl=1
8790 else
8791 ac_have_decl=0
8792 fi
8793
8794 cat >>confdefs.h <<_ACEOF
8795 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8796 _ACEOF
8797
8798 if test $ac_cv_have_decl_sys_siglist != yes; then
8799 # For Tru64, at least:
8800 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8801 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8802 ac_have_decl=1
8803 else
8804 ac_have_decl=0
8805 fi
8806
8807 cat >>confdefs.h <<_ACEOF
8808 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8809 _ACEOF
8810
8811 if test $ac_cv_have_decl___sys_siglist = yes; then
8812
8813 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8814
8815 fi
8816 fi
8817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8818 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8819 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8820 $as_echo_n "(cached) " >&6
8821 else
8822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8823 /* end confdefs.h. */
8824 #include <sys/types.h>
8825 #include <sys/wait.h>
8826 #ifndef WEXITSTATUS
8827 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8828 #endif
8829 #ifndef WIFEXITED
8830 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8831 #endif
8832
8833 int
8834 main ()
8835 {
8836 int s;
8837 wait (&s);
8838 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8839 ;
8840 return 0;
8841 }
8842 _ACEOF
8843 if ac_fn_c_try_compile "$LINENO"; then :
8844 ac_cv_header_sys_wait_h=yes
8845 else
8846 ac_cv_header_sys_wait_h=no
8847 fi
8848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8849 fi
8850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8851 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8852 if test $ac_cv_header_sys_wait_h = yes; then
8853
8854 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8855
8856 fi
8857
8858
8859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8860 $as_echo_n "checking for speed_t... " >&6; }
8861 if test "${emacs_cv_speed_t+set}" = set; then :
8862 $as_echo_n "(cached) " >&6
8863 else
8864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8865 /* end confdefs.h. */
8866 #include <termios.h>
8867 int
8868 main ()
8869 {
8870 speed_t x = 1;
8871 ;
8872 return 0;
8873 }
8874 _ACEOF
8875 if ac_fn_c_try_compile "$LINENO"; then :
8876 emacs_cv_speed_t=yes
8877 else
8878 emacs_cv_speed_t=no
8879 fi
8880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8881 fi
8882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8883 $as_echo "$emacs_cv_speed_t" >&6; }
8884 if test $emacs_cv_speed_t = yes; then
8885
8886 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8887
8888 fi
8889
8890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8891 $as_echo_n "checking for struct exception... " >&6; }
8892 if test "${emacs_cv_struct_exception+set}" = set; then :
8893 $as_echo_n "(cached) " >&6
8894 else
8895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8896 /* end confdefs.h. */
8897 #include <math.h>
8898 int
8899 main ()
8900 {
8901 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8902 ;
8903 return 0;
8904 }
8905 _ACEOF
8906 if ac_fn_c_try_compile "$LINENO"; then :
8907 emacs_cv_struct_exception=yes
8908 else
8909 emacs_cv_struct_exception=no
8910 fi
8911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8912 fi
8913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8914 $as_echo "$emacs_cv_struct_exception" >&6; }
8915 HAVE_EXCEPTION=$emacs_cv_struct_exception
8916 if test $emacs_cv_struct_exception != yes || test $opsys = darwin; then
8917
8918 $as_echo "#define NO_MATHERR 1" >>confdefs.h
8919
8920 fi
8921
8922
8923
8924
8925 for ac_header in net/if.h
8926 do :
8927 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8928 #if HAVE_SYS_SOCKET_H
8929 #include <sys/socket.h>
8930 #endif
8931 "
8932 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8933 cat >>confdefs.h <<_ACEOF
8934 #define HAVE_NET_IF_H 1
8935 _ACEOF
8936
8937 fi
8938
8939 done
8940
8941 for ac_header in ifaddrs.h
8942 do :
8943 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8944 #if HAVE_SYS_SOCKET_H
8945 #include <sys/socket.h>
8946 #endif
8947 "
8948 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8949 cat >>confdefs.h <<_ACEOF
8950 #define HAVE_IFADDRS_H 1
8951 _ACEOF
8952
8953 fi
8954
8955 done
8956
8957 for ac_header in net/if_dl.h
8958 do :
8959 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8960 #if HAVE_SYS_SOCKET_H
8961 #include <sys/socket.h>
8962 #endif
8963 "
8964 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8965 cat >>confdefs.h <<_ACEOF
8966 #define HAVE_NET_IF_DL_H 1
8967 _ACEOF
8968
8969 fi
8970
8971 done
8972
8973
8974 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8975 #if HAVE_SYS_SOCKET_H
8976 #include <sys/socket.h>
8977 #endif
8978 #if HAVE_NET_IF_H
8979 #include <net/if.h>
8980 #endif
8981 "
8982 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8983
8984 cat >>confdefs.h <<_ACEOF
8985 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8986 _ACEOF
8987
8988
8989 fi
8990 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8991 #if HAVE_SYS_SOCKET_H
8992 #include <sys/socket.h>
8993 #endif
8994 #if HAVE_NET_IF_H
8995 #include <net/if.h>
8996 #endif
8997 "
8998 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8999
9000 cat >>confdefs.h <<_ACEOF
9001 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9002 _ACEOF
9003
9004
9005 fi
9006 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9007 #if HAVE_SYS_SOCKET_H
9008 #include <sys/socket.h>
9009 #endif
9010 #if HAVE_NET_IF_H
9011 #include <net/if.h>
9012 #endif
9013 "
9014 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9015
9016 cat >>confdefs.h <<_ACEOF
9017 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9018 _ACEOF
9019
9020
9021 fi
9022 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9023 #if HAVE_SYS_SOCKET_H
9024 #include <sys/socket.h>
9025 #endif
9026 #if HAVE_NET_IF_H
9027 #include <net/if.h>
9028 #endif
9029 "
9030 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9031
9032 cat >>confdefs.h <<_ACEOF
9033 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9034 _ACEOF
9035
9036
9037 fi
9038 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9039 #if HAVE_SYS_SOCKET_H
9040 #include <sys/socket.h>
9041 #endif
9042 #if HAVE_NET_IF_H
9043 #include <net/if.h>
9044 #endif
9045 "
9046 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9047
9048 cat >>confdefs.h <<_ACEOF
9049 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9050 _ACEOF
9051
9052
9053 fi
9054 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9055 #if HAVE_SYS_SOCKET_H
9056 #include <sys/socket.h>
9057 #endif
9058 #if HAVE_NET_IF_H
9059 #include <net/if.h>
9060 #endif
9061 "
9062 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9063
9064 cat >>confdefs.h <<_ACEOF
9065 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9066 _ACEOF
9067
9068
9069 fi
9070
9071
9072
9073
9074 DEPFLAGS=
9075 MKDEPDIR=":"
9076 deps_frag=deps.mk
9077 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9079 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9080 HAVE_GNU_MAKE=no
9081 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9082 if test "x$testval" != x; then
9083 HAVE_GNU_MAKE=yes
9084 else
9085 ac_enable_autodepend=no
9086 fi
9087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9088 $as_echo "$HAVE_GNU_MAKE" >&6; }
9089 if test $HAVE_GNU_MAKE = yes; then
9090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9091 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9092 SAVE_CFLAGS="$CFLAGS"
9093 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9095 /* end confdefs.h. */
9096
9097 int
9098 main ()
9099 {
9100
9101 ;
9102 return 0;
9103 }
9104 _ACEOF
9105 if ac_fn_c_try_compile "$LINENO"; then :
9106
9107 else
9108 ac_enable_autodepend=no
9109 fi
9110 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9111 CFLAGS="$SAVE_CFLAGS"
9112 test -f deps.d || ac_enable_autodepend=no
9113 rm -rf deps.d
9114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9115 $as_echo "$ac_enable_autodepend" >&6; }
9116 fi
9117 if test $ac_enable_autodepend = yes; then
9118 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9119 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9120 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9121 deps_frag=autodeps.mk
9122 fi
9123 fi
9124 deps_frag=$srcdir/src/$deps_frag
9125
9126
9127
9128
9129
9130 lisp_frag=$srcdir/src/lisp.mk
9131
9132
9133
9134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9135 $as_echo_n "checking for long file names... " >&6; }
9136 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9137 $as_echo_n "(cached) " >&6
9138 else
9139 ac_cv_sys_long_file_names=yes
9140 # Test for long file names in all the places we know might matter:
9141 # . the current directory, where building will happen
9142 # $prefix/lib where we will be installing things
9143 # $exec_prefix/lib likewise
9144 # $TMPDIR if set, where it might want to write temporary files
9145 # /tmp where it might want to write temporary files
9146 # /var/tmp likewise
9147 # /usr/tmp likewise
9148 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9149 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9150 # in the usual case where exec_prefix is '${prefix}'.
9151 case $ac_dir in #(
9152 . | /* | ?:[\\/]*) ;; #(
9153 *) continue;;
9154 esac
9155 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9156 ac_xdir=$ac_dir/cf$$
9157 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9158 ac_tf1=$ac_xdir/conftest9012345
9159 ac_tf2=$ac_xdir/conftest9012346
9160 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9161 ac_cv_sys_long_file_names=no
9162 rm -f -r "$ac_xdir" 2>/dev/null
9163 test $ac_cv_sys_long_file_names = no && break
9164 done
9165 fi
9166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9167 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9168 if test $ac_cv_sys_long_file_names = yes; then
9169
9170 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9171
9172 fi
9173
9174
9175 #### Choose a window system.
9176
9177 ## We leave window_system equal to none if
9178 ## we end up building without one. Any new window system should
9179 ## set window_system to an appropriate value and add objects to
9180 ## window-system-specific substs.
9181
9182 window_system=none
9183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9184 $as_echo_n "checking for X... " >&6; }
9185
9186
9187 # Check whether --with-x was given.
9188 if test "${with_x+set}" = set; then :
9189 withval=$with_x;
9190 fi
9191
9192 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9193 if test "x$with_x" = xno; then
9194 # The user explicitly disabled X.
9195 have_x=disabled
9196 else
9197 case $x_includes,$x_libraries in #(
9198 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9199 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9200 $as_echo_n "(cached) " >&6
9201 else
9202 # One or both of the vars are not set, and there is no cached value.
9203 ac_x_includes=no ac_x_libraries=no
9204 rm -f -r conftest.dir
9205 if mkdir conftest.dir; then
9206 cd conftest.dir
9207 cat >Imakefile <<'_ACEOF'
9208 incroot:
9209 @echo incroot='${INCROOT}'
9210 usrlibdir:
9211 @echo usrlibdir='${USRLIBDIR}'
9212 libdir:
9213 @echo libdir='${LIBDIR}'
9214 _ACEOF
9215 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9216 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9217 for ac_var in incroot usrlibdir libdir; do
9218 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9219 done
9220 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9221 for ac_extension in a so sl dylib la dll; do
9222 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9223 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9224 ac_im_usrlibdir=$ac_im_libdir; break
9225 fi
9226 done
9227 # Screen out bogus values from the imake configuration. They are
9228 # bogus both because they are the default anyway, and because
9229 # using them would break gcc on systems where it needs fixed includes.
9230 case $ac_im_incroot in
9231 /usr/include) ac_x_includes= ;;
9232 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9233 esac
9234 case $ac_im_usrlibdir in
9235 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9236 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9237 esac
9238 fi
9239 cd ..
9240 rm -f -r conftest.dir
9241 fi
9242
9243 # Standard set of common directories for X headers.
9244 # Check X11 before X11Rn because it is often a symlink to the current release.
9245 ac_x_header_dirs='
9246 /usr/X11/include
9247 /usr/X11R7/include
9248 /usr/X11R6/include
9249 /usr/X11R5/include
9250 /usr/X11R4/include
9251
9252 /usr/include/X11
9253 /usr/include/X11R7
9254 /usr/include/X11R6
9255 /usr/include/X11R5
9256 /usr/include/X11R4
9257
9258 /usr/local/X11/include
9259 /usr/local/X11R7/include
9260 /usr/local/X11R6/include
9261 /usr/local/X11R5/include
9262 /usr/local/X11R4/include
9263
9264 /usr/local/include/X11
9265 /usr/local/include/X11R7
9266 /usr/local/include/X11R6
9267 /usr/local/include/X11R5
9268 /usr/local/include/X11R4
9269
9270 /usr/X386/include
9271 /usr/x386/include
9272 /usr/XFree86/include/X11
9273
9274 /usr/include
9275 /usr/local/include
9276 /usr/unsupported/include
9277 /usr/athena/include
9278 /usr/local/x11r5/include
9279 /usr/lpp/Xamples/include
9280
9281 /usr/openwin/include
9282 /usr/openwin/share/include'
9283
9284 if test "$ac_x_includes" = no; then
9285 # Guess where to find include files, by looking for Xlib.h.
9286 # First, try using that file with no special directory specified.
9287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9288 /* end confdefs.h. */
9289 #include <X11/Xlib.h>
9290 _ACEOF
9291 if ac_fn_c_try_cpp "$LINENO"; then :
9292 # We can compile using X headers with no special include directory.
9293 ac_x_includes=
9294 else
9295 for ac_dir in $ac_x_header_dirs; do
9296 if test -r "$ac_dir/X11/Xlib.h"; then
9297 ac_x_includes=$ac_dir
9298 break
9299 fi
9300 done
9301 fi
9302 rm -f conftest.err conftest.$ac_ext
9303 fi # $ac_x_includes = no
9304
9305 if test "$ac_x_libraries" = no; then
9306 # Check for the libraries.
9307 # See if we find them without any special options.
9308 # Don't add to $LIBS permanently.
9309 ac_save_LIBS=$LIBS
9310 LIBS="-lX11 $LIBS"
9311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9312 /* end confdefs.h. */
9313 #include <X11/Xlib.h>
9314 int
9315 main ()
9316 {
9317 XrmInitialize ()
9318 ;
9319 return 0;
9320 }
9321 _ACEOF
9322 if ac_fn_c_try_link "$LINENO"; then :
9323 LIBS=$ac_save_LIBS
9324 # We can link X programs with no special library path.
9325 ac_x_libraries=
9326 else
9327 LIBS=$ac_save_LIBS
9328 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9329 do
9330 # Don't even attempt the hair of trying to link an X program!
9331 for ac_extension in a so sl dylib la dll; do
9332 if test -r "$ac_dir/libX11.$ac_extension"; then
9333 ac_x_libraries=$ac_dir
9334 break 2
9335 fi
9336 done
9337 done
9338 fi
9339 rm -f core conftest.err conftest.$ac_objext \
9340 conftest$ac_exeext conftest.$ac_ext
9341 fi # $ac_x_libraries = no
9342
9343 case $ac_x_includes,$ac_x_libraries in #(
9344 no,* | *,no | *\'*)
9345 # Didn't find X, or a directory has "'" in its name.
9346 ac_cv_have_x="have_x=no";; #(
9347 *)
9348 # Record where we found X for the cache.
9349 ac_cv_have_x="have_x=yes\
9350 ac_x_includes='$ac_x_includes'\
9351 ac_x_libraries='$ac_x_libraries'"
9352 esac
9353 fi
9354 ;; #(
9355 *) have_x=yes;;
9356 esac
9357 eval "$ac_cv_have_x"
9358 fi # $with_x != no
9359
9360 if test "$have_x" != yes; then
9361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9362 $as_echo "$have_x" >&6; }
9363 no_x=yes
9364 else
9365 # If each of the values was on the command line, it overrides each guess.
9366 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9367 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9368 # Update the cache value to reflect the command line values.
9369 ac_cv_have_x="have_x=yes\
9370 ac_x_includes='$x_includes'\
9371 ac_x_libraries='$x_libraries'"
9372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9373 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9374 fi
9375
9376 if test "$no_x" != yes; then
9377 window_system=x11
9378 fi
9379
9380 LD_SWITCH_X_SITE_RPATH=
9381 if test "${x_libraries}" != NONE; then
9382 if test -n "${x_libraries}"; then
9383 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9384 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9385 fi
9386 x_default_search_path=""
9387 x_search_path=${x_libraries}
9388 if test -z "${x_search_path}"; then
9389 x_search_path=/usr/lib
9390 fi
9391 for x_library in `echo ${x_search_path}: | \
9392 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9393 x_search_path="\
9394 ${x_library}/X11/%L/%T/%N%C%S:\
9395 ${x_library}/X11/%l/%T/%N%C%S:\
9396 ${x_library}/X11/%T/%N%C%S:\
9397 ${x_library}/X11/%L/%T/%N%S:\
9398 ${x_library}/X11/%l/%T/%N%S:\
9399 ${x_library}/X11/%T/%N%S"
9400 if test x"${x_default_search_path}" = x; then
9401 x_default_search_path=${x_search_path}
9402 else
9403 x_default_search_path="${x_search_path}:${x_default_search_path}"
9404 fi
9405 done
9406 fi
9407
9408
9409 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9410 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9411 fi
9412
9413 if test x"${x_includes}" = x; then
9414 bitmapdir=/usr/include/X11/bitmaps
9415 else
9416 # accumulate include directories that have X11 bitmap subdirectories
9417 bmd_acc="dummyval"
9418 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9419 if test -d "${bmd}/X11/bitmaps"; then
9420 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9421 fi
9422 if test -d "${bmd}/bitmaps"; then
9423 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9424 fi
9425 done
9426 if test ${bmd_acc} != "dummyval"; then
9427 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9428 fi
9429 fi
9430
9431 HAVE_NS=no
9432 NS_IMPL_COCOA=no
9433 NS_IMPL_GNUSTEP=no
9434 tmp_CPPFLAGS="$CPPFLAGS"
9435 tmp_CFLAGS="$CFLAGS"
9436 CPPFLAGS="$CPPFLAGS -x objective-c"
9437 CFLAGS="$CFLAGS -x objective-c"
9438 TEMACS_LDFLAGS2="\${LDFLAGS}"
9439 GNU_OBJC_CFLAGS=
9440 if test "${with_ns}" != no; then
9441 if test "${opsys}" = darwin; then
9442 NS_IMPL_COCOA=yes
9443 ns_appdir=`pwd`/nextstep/Emacs.app
9444 ns_appbindir=${ns_appdir}/Contents/MacOS
9445 ns_appresdir=${ns_appdir}/Contents/Resources
9446 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9447 elif test -f $GNUSTEP_CONFIG_FILE; then
9448 NS_IMPL_GNUSTEP=yes
9449 ns_appdir=`pwd`/nextstep/Emacs.app
9450 ns_appbindir=${ns_appdir}
9451 ns_appresdir=${ns_appdir}/Resources
9452 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9453 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9454 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9455 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9456 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9457 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9458 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9459 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9460 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9461 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9462 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9463 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9464 LIB_STANDARD=
9465 START_FILES=
9466 TEMACS_LDFLAGS2=
9467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9468 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9469 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9470 $as_echo_n "(cached) " >&6
9471 else
9472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9473 /* end confdefs.h. */
9474 #include <GNUstepBase/GSConfig.h>
9475 int
9476 main ()
9477 {
9478 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9479 1;
9480 #else
9481 fail;
9482 #endif
9483 ;
9484 return 0;
9485 }
9486 _ACEOF
9487 if ac_fn_c_try_compile "$LINENO"; then :
9488 emacs_cv_objc_exceptions=yes
9489 else
9490 emacs_cv_objc_exceptions=no
9491 fi
9492 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9493 fi
9494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9495 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9496 if test $emacs_cv_objc_exceptions = yes; then
9497
9498 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9499
9500 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9501 fi
9502 fi
9503
9504 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9505
9506 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9507 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9508 HAVE_NS=yes
9509 else
9510 as_fn_error "\`--with-ns' was specified, but the include
9511 files are missing or cannot be compiled." "$LINENO" 5
9512 fi
9513
9514
9515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9516 /* end confdefs.h. */
9517 #include <Foundation/NSObjCRuntime.h>
9518 int
9519 main ()
9520 {
9521 NSInteger i;
9522 ;
9523 return 0;
9524 }
9525 _ACEOF
9526 if ac_fn_c_try_compile "$LINENO"; then :
9527 ns_have_nsinteger=yes
9528 else
9529 ns_have_nsinteger=no
9530 fi
9531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9532 if test $ns_have_nsinteger = yes; then
9533
9534 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9535
9536 fi
9537 fi
9538
9539
9540 INSTALL_ARCH_INDEP_EXTRA=install-etc
9541 ns_self_contained=no
9542 ns_frag=/dev/null
9543 NS_OBJ=
9544 NS_OBJC_OBJ=
9545 if test "${HAVE_NS}" = yes; then
9546 if test "$with_toolkit_scroll_bars" = "no"; then
9547 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9548 fi
9549
9550 window_system=nextstep
9551 # set up packaging dirs
9552 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9553 ns_self_contained=yes
9554 prefix=${ns_appresdir}
9555 exec_prefix=${ns_appbindir}
9556 libexecdir="\${ns_appbindir}/libexec"
9557 archlibdir="\${ns_appbindir}/libexec"
9558 docdir="\${ns_appresdir}/etc"
9559 etcdir="\${ns_appresdir}/etc"
9560 infodir="\${ns_appresdir}/info"
9561 mandir="\${ns_appresdir}/man"
9562 lispdir="\${ns_appresdir}/lisp"
9563 leimdir="\${ns_appresdir}/leim"
9564 INSTALL_ARCH_INDEP_EXTRA=
9565 fi
9566 ns_frag=$srcdir/src/ns.mk
9567 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9568 fi
9569 CFLAGS="$tmp_CFLAGS"
9570 CPPFLAGS="$tmp_CPPFLAGS"
9571
9572
9573
9574
9575
9576
9577
9578 ## $window_system is now set to the window system we will
9579 ## ultimately use.
9580
9581 term_header=
9582 HAVE_X_WINDOWS=no
9583 HAVE_X11=no
9584 USE_X_TOOLKIT=none
9585
9586 case "${window_system}" in
9587 x11 )
9588 HAVE_X_WINDOWS=yes
9589 HAVE_X11=yes
9590 term_header=xterm.h
9591 case "${with_x_toolkit}" in
9592 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9593 motif ) USE_X_TOOLKIT=MOTIF ;;
9594 gtk ) with_gtk=yes
9595 term_header=gtkutil.h
9596 USE_X_TOOLKIT=none ;;
9597 gtk3 ) with_gtk3=yes
9598 term_header=gtkutil.h
9599 USE_X_TOOLKIT=none ;;
9600 no ) USE_X_TOOLKIT=none ;;
9601 * ) USE_X_TOOLKIT=maybe ;;
9602 esac
9603 ;;
9604 nextstep )
9605 term_header=nsterm.h
9606 ;;
9607 esac
9608
9609 if test -n "${term_header}"; then
9610
9611 cat >>confdefs.h <<_ACEOF
9612 #define TERM_HEADER "${term_header}"
9613 _ACEOF
9614
9615 fi
9616
9617 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9618 # Extract the first word of "X", so it can be a program name with args.
9619 set dummy X; ac_word=$2
9620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9621 $as_echo_n "checking for $ac_word... " >&6; }
9622 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9623 $as_echo_n "(cached) " >&6
9624 else
9625 if test -n "$HAVE_XSERVER"; then
9626 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9627 else
9628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9629 for as_dir in $PATH
9630 do
9631 IFS=$as_save_IFS
9632 test -z "$as_dir" && as_dir=.
9633 for ac_exec_ext in '' $ac_executable_extensions; do
9634 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9635 ac_cv_prog_HAVE_XSERVER="true"
9636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9637 break 2
9638 fi
9639 done
9640 done
9641 IFS=$as_save_IFS
9642
9643 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9644 fi
9645 fi
9646 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9647 if test -n "$HAVE_XSERVER"; then
9648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9649 $as_echo "$HAVE_XSERVER" >&6; }
9650 else
9651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9652 $as_echo "no" >&6; }
9653 fi
9654
9655
9656 if test "$HAVE_XSERVER" = true ||
9657 test -n "$DISPLAY" ||
9658 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9659 as_fn_error "You seem to be running X, but no X development libraries
9660 were found. You should install the relevant development files for X
9661 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9662 sure you have development files for image handling, i.e.
9663 tiff, gif, jpeg, png and xpm.
9664 If you are sure you want Emacs compiled without X window support, pass
9665 --without-x
9666 to configure." "$LINENO" 5
9667 fi
9668 fi
9669
9670 ### If we're using X11, we should use the X menu package.
9671 HAVE_MENUS=no
9672 case ${HAVE_X11} in
9673 yes ) HAVE_MENUS=yes ;;
9674 esac
9675
9676 # Does the opsystem file prohibit the use of the GNU malloc?
9677 # Assume not, until told otherwise.
9678 GNU_MALLOC=yes
9679
9680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9681 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9682 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9683 $as_echo_n "(cached) " >&6
9684 else
9685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9686 /* end confdefs.h. */
9687 #include <malloc.h>
9688 static void hook (void) {}
9689 int
9690 main ()
9691 {
9692 malloc_set_state (malloc_get_state ());
9693 __after_morecore_hook = hook;
9694 __malloc_initialize_hook = hook;
9695 ;
9696 return 0;
9697 }
9698 _ACEOF
9699 if ac_fn_c_try_link "$LINENO"; then :
9700 emacs_cv_var_doug_lea_malloc=yes
9701 else
9702 emacs_cv_var_doug_lea_malloc=no
9703 fi
9704 rm -f core conftest.err conftest.$ac_objext \
9705 conftest$ac_exeext conftest.$ac_ext
9706 fi
9707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9708 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9709 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9710
9711
9712 system_malloc=no
9713 case "$opsys" in
9714 ## darwin ld insists on the use of malloc routines in the System framework.
9715 darwin|sol2-10) system_malloc=yes ;;
9716 esac
9717
9718 if test "${system_malloc}" = "yes"; then
9719
9720 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9721
9722 GNU_MALLOC=no
9723 GNU_MALLOC_reason="
9724 (The GNU allocators don't work with this system configuration.)"
9725 GMALLOC_OBJ=
9726 VMLIMIT_OBJ=
9727 else
9728 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9729 VMLIMIT_OBJ=vm-limit.o
9730 fi
9731
9732
9733
9734 if test "$doug_lea_malloc" = "yes" ; then
9735 if test "$GNU_MALLOC" = yes ; then
9736 GNU_MALLOC_reason="
9737 (Using Doug Lea's new malloc from the GNU C Library.)"
9738 fi
9739
9740 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9741
9742
9743 ## Use mmap directly for allocating larger buffers.
9744 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9745 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9746 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9747 case "$opsys" in
9748 gnu*) REL_ALLOC=no ;;
9749 esac
9750 fi
9751
9752 if test x"${REL_ALLOC}" = x; then
9753 REL_ALLOC=${GNU_MALLOC}
9754 fi
9755
9756 use_mmap_for_buffers=no
9757 case "$opsys" in
9758 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9759 esac
9760
9761
9762
9763
9764
9765
9766
9767
9768 for ac_func in getpagesize
9769 do :
9770 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9771 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9772 cat >>confdefs.h <<_ACEOF
9773 #define HAVE_GETPAGESIZE 1
9774 _ACEOF
9775
9776 fi
9777 done
9778
9779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9780 $as_echo_n "checking for working mmap... " >&6; }
9781 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9782 $as_echo_n "(cached) " >&6
9783 else
9784 if test "$cross_compiling" = yes; then :
9785 ac_cv_func_mmap_fixed_mapped=no
9786 else
9787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9788 /* end confdefs.h. */
9789 $ac_includes_default
9790 /* malloc might have been renamed as rpl_malloc. */
9791 #undef malloc
9792
9793 /* Thanks to Mike Haertel and Jim Avera for this test.
9794 Here is a matrix of mmap possibilities:
9795 mmap private not fixed
9796 mmap private fixed at somewhere currently unmapped
9797 mmap private fixed at somewhere already mapped
9798 mmap shared not fixed
9799 mmap shared fixed at somewhere currently unmapped
9800 mmap shared fixed at somewhere already mapped
9801 For private mappings, we should verify that changes cannot be read()
9802 back from the file, nor mmap's back from the file at a different
9803 address. (There have been systems where private was not correctly
9804 implemented like the infamous i386 svr4.0, and systems where the
9805 VM page cache was not coherent with the file system buffer cache
9806 like early versions of FreeBSD and possibly contemporary NetBSD.)
9807 For shared mappings, we should conversely verify that changes get
9808 propagated back to all the places they're supposed to be.
9809
9810 Grep wants private fixed already mapped.
9811 The main things grep needs to know about mmap are:
9812 * does it exist and is it safe to write into the mmap'd area
9813 * how to use it (BSD variants) */
9814
9815 #include <fcntl.h>
9816 #include <sys/mman.h>
9817
9818 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9819 char *malloc ();
9820 #endif
9821
9822 /* This mess was copied from the GNU getpagesize.h. */
9823 #ifndef HAVE_GETPAGESIZE
9824 # ifdef _SC_PAGESIZE
9825 # define getpagesize() sysconf(_SC_PAGESIZE)
9826 # else /* no _SC_PAGESIZE */
9827 # ifdef HAVE_SYS_PARAM_H
9828 # include <sys/param.h>
9829 # ifdef EXEC_PAGESIZE
9830 # define getpagesize() EXEC_PAGESIZE
9831 # else /* no EXEC_PAGESIZE */
9832 # ifdef NBPG
9833 # define getpagesize() NBPG * CLSIZE
9834 # ifndef CLSIZE
9835 # define CLSIZE 1
9836 # endif /* no CLSIZE */
9837 # else /* no NBPG */
9838 # ifdef NBPC
9839 # define getpagesize() NBPC
9840 # else /* no NBPC */
9841 # ifdef PAGESIZE
9842 # define getpagesize() PAGESIZE
9843 # endif /* PAGESIZE */
9844 # endif /* no NBPC */
9845 # endif /* no NBPG */
9846 # endif /* no EXEC_PAGESIZE */
9847 # else /* no HAVE_SYS_PARAM_H */
9848 # define getpagesize() 8192 /* punt totally */
9849 # endif /* no HAVE_SYS_PARAM_H */
9850 # endif /* no _SC_PAGESIZE */
9851
9852 #endif /* no HAVE_GETPAGESIZE */
9853
9854 int
9855 main ()
9856 {
9857 char *data, *data2, *data3;
9858 const char *cdata2;
9859 int i, pagesize;
9860 int fd, fd2;
9861
9862 pagesize = getpagesize ();
9863
9864 /* First, make a file with some known garbage in it. */
9865 data = (char *) malloc (pagesize);
9866 if (!data)
9867 return 1;
9868 for (i = 0; i < pagesize; ++i)
9869 *(data + i) = rand ();
9870 umask (0);
9871 fd = creat ("conftest.mmap", 0600);
9872 if (fd < 0)
9873 return 2;
9874 if (write (fd, data, pagesize) != pagesize)
9875 return 3;
9876 close (fd);
9877
9878 /* Next, check that the tail of a page is zero-filled. File must have
9879 non-zero length, otherwise we risk SIGBUS for entire page. */
9880 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9881 if (fd2 < 0)
9882 return 4;
9883 cdata2 = "";
9884 if (write (fd2, cdata2, 1) != 1)
9885 return 5;
9886 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9887 if (data2 == MAP_FAILED)
9888 return 6;
9889 for (i = 0; i < pagesize; ++i)
9890 if (*(data2 + i))
9891 return 7;
9892 close (fd2);
9893 if (munmap (data2, pagesize))
9894 return 8;
9895
9896 /* Next, try to mmap the file at a fixed address which already has
9897 something else allocated at it. If we can, also make sure that
9898 we see the same garbage. */
9899 fd = open ("conftest.mmap", O_RDWR);
9900 if (fd < 0)
9901 return 9;
9902 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9903 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9904 return 10;
9905 for (i = 0; i < pagesize; ++i)
9906 if (*(data + i) != *(data2 + i))
9907 return 11;
9908
9909 /* Finally, make sure that changes to the mapped area do not
9910 percolate back to the file as seen by read(). (This is a bug on
9911 some variants of i386 svr4.0.) */
9912 for (i = 0; i < pagesize; ++i)
9913 *(data2 + i) = *(data2 + i) + 1;
9914 data3 = (char *) malloc (pagesize);
9915 if (!data3)
9916 return 12;
9917 if (read (fd, data3, pagesize) != pagesize)
9918 return 13;
9919 for (i = 0; i < pagesize; ++i)
9920 if (*(data + i) != *(data3 + i))
9921 return 14;
9922 close (fd);
9923 return 0;
9924 }
9925 _ACEOF
9926 if ac_fn_c_try_run "$LINENO"; then :
9927 ac_cv_func_mmap_fixed_mapped=yes
9928 else
9929 ac_cv_func_mmap_fixed_mapped=no
9930 fi
9931 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9932 conftest.$ac_objext conftest.beam conftest.$ac_ext
9933 fi
9934
9935 fi
9936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9937 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9938 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9939
9940 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9941
9942 fi
9943 rm -f conftest.mmap conftest.txt
9944
9945 if test $use_mmap_for_buffers = yes; then
9946
9947 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9948
9949 REL_ALLOC=no
9950 fi
9951
9952 LIBS="$LIBS_SYSTEM $LIBS"
9953
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9955 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
9956 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
9957 $as_echo_n "(cached) " >&6
9958 else
9959 ac_check_lib_save_LIBS=$LIBS
9960 LIBS="-ldnet $LIBS"
9961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9962 /* end confdefs.h. */
9963
9964 /* Override any GCC internal prototype to avoid an error.
9965 Use char because int might match the return type of a GCC
9966 builtin and then its argument prototype would still apply. */
9967 #ifdef __cplusplus
9968 extern "C"
9969 #endif
9970 char dnet_ntoa ();
9971 int
9972 main ()
9973 {
9974 return dnet_ntoa ();
9975 ;
9976 return 0;
9977 }
9978 _ACEOF
9979 if ac_fn_c_try_link "$LINENO"; then :
9980 ac_cv_lib_dnet_dnet_ntoa=yes
9981 else
9982 ac_cv_lib_dnet_dnet_ntoa=no
9983 fi
9984 rm -f core conftest.err conftest.$ac_objext \
9985 conftest$ac_exeext conftest.$ac_ext
9986 LIBS=$ac_check_lib_save_LIBS
9987 fi
9988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9989 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
9990 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
9991 cat >>confdefs.h <<_ACEOF
9992 #define HAVE_LIBDNET 1
9993 _ACEOF
9994
9995 LIBS="-ldnet $LIBS"
9996
9997 fi
9998
9999
10000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10001 $as_echo_n "checking for main in -lXbsd... " >&6; }
10002 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10003 $as_echo_n "(cached) " >&6
10004 else
10005 ac_check_lib_save_LIBS=$LIBS
10006 LIBS="-lXbsd $LIBS"
10007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10008 /* end confdefs.h. */
10009
10010
10011 int
10012 main ()
10013 {
10014 return main ();
10015 ;
10016 return 0;
10017 }
10018 _ACEOF
10019 if ac_fn_c_try_link "$LINENO"; then :
10020 ac_cv_lib_Xbsd_main=yes
10021 else
10022 ac_cv_lib_Xbsd_main=no
10023 fi
10024 rm -f core conftest.err conftest.$ac_objext \
10025 conftest$ac_exeext conftest.$ac_ext
10026 LIBS=$ac_check_lib_save_LIBS
10027 fi
10028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10029 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10030 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10031 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10032 fi
10033
10034
10035 LIB_PTHREAD=
10036
10037
10038
10039 if test "$ac_cv_header_pthread_h"; then
10040 if test "$GMALLOC_OBJ" = gmalloc.o; then
10041 emacs_pthread_function=pthread_atfork
10042 else
10043 emacs_pthread_function=pthread_self
10044 fi
10045 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10047 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10048 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10049 $as_echo_n "(cached) " >&6
10050 else
10051 ac_check_lib_save_LIBS=$LIBS
10052 LIBS="-lpthread $LIBS"
10053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10054 /* end confdefs.h. */
10055
10056 /* Override any GCC internal prototype to avoid an error.
10057 Use char because int might match the return type of a GCC
10058 builtin and then its argument prototype would still apply. */
10059 #ifdef __cplusplus
10060 extern "C"
10061 #endif
10062 char $emacs_pthread_function ();
10063 int
10064 main ()
10065 {
10066 return $emacs_pthread_function ();
10067 ;
10068 return 0;
10069 }
10070 _ACEOF
10071 if ac_fn_c_try_link "$LINENO"; then :
10072 eval "$as_ac_Lib=yes"
10073 else
10074 eval "$as_ac_Lib=no"
10075 fi
10076 rm -f core conftest.err conftest.$ac_objext \
10077 conftest$ac_exeext conftest.$ac_ext
10078 LIBS=$ac_check_lib_save_LIBS
10079 fi
10080 eval ac_res=\$$as_ac_Lib
10081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10082 $as_echo "$ac_res" >&6; }
10083 eval as_val=\$$as_ac_Lib
10084 if test "x$as_val" = x""yes; then :
10085 HAVE_PTHREAD=yes
10086 fi
10087
10088 fi
10089 if test "$HAVE_PTHREAD" = yes; then
10090 case "${canonical}" in
10091 *-hpux*) ;;
10092 *) LIB_PTHREAD="-lpthread"
10093 LIBS="$LIB_PTHREAD $LIBS" ;;
10094 esac
10095
10096 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10097
10098 fi
10099
10100
10101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10102 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10103 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10104 $as_echo_n "(cached) " >&6
10105 else
10106 ac_check_lib_save_LIBS=$LIBS
10107 LIBS="-lpthreads $LIBS"
10108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10109 /* end confdefs.h. */
10110
10111 /* Override any GCC internal prototype to avoid an error.
10112 Use char because int might match the return type of a GCC
10113 builtin and then its argument prototype would still apply. */
10114 #ifdef __cplusplus
10115 extern "C"
10116 #endif
10117 char cma_open ();
10118 int
10119 main ()
10120 {
10121 return cma_open ();
10122 ;
10123 return 0;
10124 }
10125 _ACEOF
10126 if ac_fn_c_try_link "$LINENO"; then :
10127 ac_cv_lib_pthreads_cma_open=yes
10128 else
10129 ac_cv_lib_pthreads_cma_open=no
10130 fi
10131 rm -f core conftest.err conftest.$ac_objext \
10132 conftest$ac_exeext conftest.$ac_ext
10133 LIBS=$ac_check_lib_save_LIBS
10134 fi
10135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10136 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10137 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10138 cat >>confdefs.h <<_ACEOF
10139 #define HAVE_LIBPTHREADS 1
10140 _ACEOF
10141
10142 LIBS="-lpthreads $LIBS"
10143
10144 fi
10145
10146
10147 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10148 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10149 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10150 ## added to LIBS in configure would never contain the pthreads part,
10151 ## but the value used in Makefiles might. FIXME?
10152 ##
10153 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10154 ## be harmless on older versions of X where it happens to exist.
10155 test "$opsys" = "aix4-2" && \
10156 test $ac_cv_lib_pthreads_cma_open = yes && \
10157 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10158
10159
10160 case ${host_os} in
10161 aix*)
10162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10163 $as_echo_n "checking for -bbigtoc option... " >&6; }
10164 if test "${gdb_cv_bigtoc+set}" = set; then :
10165 $as_echo_n "(cached) " >&6
10166 else
10167
10168 case $GCC in
10169 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10170 *) gdb_cv_bigtoc=-bbigtoc ;;
10171 esac
10172
10173 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10175 /* end confdefs.h. */
10176
10177 int
10178 main ()
10179 {
10180 int i;
10181 ;
10182 return 0;
10183 }
10184 _ACEOF
10185 if ac_fn_c_try_link "$LINENO"; then :
10186
10187 else
10188 gdb_cv_bigtoc=
10189 fi
10190 rm -f core conftest.err conftest.$ac_objext \
10191 conftest$ac_exeext conftest.$ac_ext
10192
10193 fi
10194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10195 $as_echo "$gdb_cv_bigtoc" >&6; }
10196 ;;
10197 esac
10198
10199 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10200 # used for the tests that follow. We set them back to REAL_CFLAGS and
10201 # REAL_CPPFLAGS later on.
10202
10203 REAL_CFLAGS="$CFLAGS"
10204 REAL_CPPFLAGS="$CPPFLAGS"
10205
10206 if test "${HAVE_X11}" = "yes"; then
10207 DEFS="$C_SWITCH_X_SITE $DEFS"
10208 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10209 LIBS="-lX11 $LIBS"
10210 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10211 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10212
10213 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10214 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10215 # but it's more convenient here to set LD_RUN_PATH since this
10216 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10217 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10218 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10219 export LD_RUN_PATH
10220 fi
10221
10222 if test "${opsys}" = "gnu-linux"; then
10223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10224 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10226 /* end confdefs.h. */
10227
10228 int
10229 main ()
10230 {
10231 XOpenDisplay ("foo");
10232 ;
10233 return 0;
10234 }
10235 _ACEOF
10236 if ac_fn_c_try_link "$LINENO"; then :
10237 xgnu_linux_first_failure=no
10238 else
10239 xgnu_linux_first_failure=yes
10240 fi
10241 rm -f core conftest.err conftest.$ac_objext \
10242 conftest$ac_exeext conftest.$ac_ext
10243 if test "${xgnu_linux_first_failure}" = "yes"; then
10244 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10245 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10246 OLD_CPPFLAGS="$CPPFLAGS"
10247 OLD_LIBS="$LIBS"
10248 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10249 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10250 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10251 LIBS="$LIBS -b i486-linuxaout"
10252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10253 /* end confdefs.h. */
10254
10255 int
10256 main ()
10257 {
10258 XOpenDisplay ("foo");
10259 ;
10260 return 0;
10261 }
10262 _ACEOF
10263 if ac_fn_c_try_link "$LINENO"; then :
10264 xgnu_linux_second_failure=no
10265 else
10266 xgnu_linux_second_failure=yes
10267 fi
10268 rm -f core conftest.err conftest.$ac_objext \
10269 conftest$ac_exeext conftest.$ac_ext
10270 if test "${xgnu_linux_second_failure}" = "yes"; then
10271 # If we get the same failure with -b, there is no use adding -b.
10272 # So take it out. This plays safe.
10273 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10274 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10275 CPPFLAGS="$OLD_CPPFLAGS"
10276 LIBS="$OLD_LIBS"
10277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10278 $as_echo "no" >&6; }
10279 else
10280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10281 $as_echo "yes" >&6; }
10282 fi
10283 else
10284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10285 $as_echo "no" >&6; }
10286 fi
10287 fi
10288
10289 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10290 # header files included from there.
10291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10292 $as_echo_n "checking for Xkb... " >&6; }
10293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10294 /* end confdefs.h. */
10295 #include <X11/Xlib.h>
10296 #include <X11/XKBlib.h>
10297 int
10298 main ()
10299 {
10300 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10301 ;
10302 return 0;
10303 }
10304 _ACEOF
10305 if ac_fn_c_try_link "$LINENO"; then :
10306 emacs_xkb=yes
10307 else
10308 emacs_xkb=no
10309 fi
10310 rm -f core conftest.err conftest.$ac_objext \
10311 conftest$ac_exeext conftest.$ac_ext
10312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10313 $as_echo "$emacs_xkb" >&6; }
10314 if test $emacs_xkb = yes; then
10315
10316 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10317
10318 fi
10319
10320 for ac_func in XrmSetDatabase XScreenResourceString \
10321 XScreenNumberOfScreen
10322 do :
10323 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10324 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10325 eval as_val=\$$as_ac_var
10326 if test "x$as_val" = x""yes; then :
10327 cat >>confdefs.h <<_ACEOF
10328 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10329 _ACEOF
10330
10331 fi
10332 done
10333
10334 fi
10335
10336 if test "${window_system}" = "x11"; then
10337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10338 $as_echo_n "checking X11 version 6... " >&6; }
10339 if test "${emacs_cv_x11_version_6+set}" = set; then :
10340 $as_echo_n "(cached) " >&6
10341 else
10342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10343 /* end confdefs.h. */
10344 #include <X11/Xlib.h>
10345 int
10346 main ()
10347 {
10348 #if XlibSpecificationRelease < 6
10349 fail;
10350 #endif
10351
10352 ;
10353 return 0;
10354 }
10355 _ACEOF
10356 if ac_fn_c_try_link "$LINENO"; then :
10357 emacs_cv_x11_version_6=yes
10358 else
10359 emacs_cv_x11_version_6=no
10360 fi
10361 rm -f core conftest.err conftest.$ac_objext \
10362 conftest$ac_exeext conftest.$ac_ext
10363 fi
10364
10365 if test $emacs_cv_x11_version_6 = yes; then
10366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10367 $as_echo "6 or newer" >&6; }
10368
10369 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10370
10371
10372 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10373
10374 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10375 ## XIM support.
10376 case "$opsys" in
10377 sol2-*) : ;;
10378 *)
10379 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10380
10381 ;;
10382 esac
10383 else
10384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10385 $as_echo "before 6" >&6; }
10386 fi
10387 fi
10388
10389
10390 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10391 HAVE_RSVG=no
10392 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10393 if test "${with_rsvg}" != "no"; then
10394 RSVG_REQUIRED=2.11.0
10395 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10396
10397
10398 succeeded=no
10399
10400 if test "$PKG_CONFIG" = "no" ; then
10401 :
10402 else
10403 PKG_CONFIG_MIN_VERSION=0.9.0
10404 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10406 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10407
10408 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10409 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10410 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10411 edit_cflags="
10412 s,///*,/,g
10413 s/^/ /
10414 s/ -I/ $isystem/g
10415 s/^ //
10416 "
10417 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10418 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10420 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10421 succeeded=yes
10422 else
10423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10424 $as_echo "no" >&6; }
10425 RSVG_CFLAGS=""
10426 RSVG_LIBS=""
10427 ## If we have a custom action on failure, don't print errors, but
10428 ## do set a variable so people can do so.
10429 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10430
10431 fi
10432
10433
10434
10435 else
10436 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10437 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10438 fi
10439 fi
10440
10441 if test $succeeded = yes; then
10442 HAVE_RSVG=yes
10443 else
10444 :
10445 fi
10446
10447
10448
10449
10450 if test $HAVE_RSVG = yes; then
10451
10452 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10453
10454 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10455 LIBS="$RSVG_LIBS $LIBS"
10456 fi
10457 fi
10458 fi
10459
10460 HAVE_IMAGEMAGICK=no
10461 if test "${HAVE_X11}" = "yes"; then
10462 if test "${with_imagemagick}" != "no"; then
10463 ## 6.2.8 is the earliest version known to work, but earlier versions
10464 ## might work - let us know if you find one.
10465 ## 6.0.7 does not work. See bug#7955.
10466 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10467
10468 succeeded=no
10469
10470 if test "$PKG_CONFIG" = "no" ; then
10471 :
10472 else
10473 PKG_CONFIG_MIN_VERSION=0.9.0
10474 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10476 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10477
10478 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10479 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10480 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10481 edit_cflags="
10482 s,///*,/,g
10483 s/^/ /
10484 s/ -I/ $isystem/g
10485 s/^ //
10486 "
10487 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10488 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10490 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10491 succeeded=yes
10492 else
10493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10494 $as_echo "no" >&6; }
10495 IMAGEMAGICK_CFLAGS=""
10496 IMAGEMAGICK_LIBS=""
10497 ## If we have a custom action on failure, don't print errors, but
10498 ## do set a variable so people can do so.
10499 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10500
10501 fi
10502
10503
10504
10505 else
10506 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10507 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10508 fi
10509 fi
10510
10511 if test $succeeded = yes; then
10512 HAVE_IMAGEMAGICK=yes
10513 else
10514 :
10515 fi
10516
10517
10518
10519
10520 if test $HAVE_IMAGEMAGICK = yes; then
10521
10522 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10523
10524 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10525 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10526 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10527 do :
10528 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10529 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10530 eval as_val=\$$as_ac_var
10531 if test "x$as_val" = x""yes; then :
10532 cat >>confdefs.h <<_ACEOF
10533 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10534 _ACEOF
10535
10536 fi
10537 done
10538
10539 fi
10540 fi
10541 fi
10542
10543
10544 HAVE_GTK=no
10545 GTK_OBJ=
10546 if test "${with_gtk3}" = "yes"; then
10547 GLIB_REQUIRED=2.28
10548 GTK_REQUIRED=3.0
10549 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10550
10551
10552 succeeded=no
10553
10554 if test "$PKG_CONFIG" = "no" ; then
10555 pkg_check_gtk=no
10556 else
10557 PKG_CONFIG_MIN_VERSION=0.9.0
10558 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10560 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10561
10562 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10563 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10564 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10565 edit_cflags="
10566 s,///*,/,g
10567 s/^/ /
10568 s/ -I/ $isystem/g
10569 s/^ //
10570 "
10571 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10572 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10574 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10575 succeeded=yes
10576 else
10577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10578 $as_echo "no" >&6; }
10579 GTK_CFLAGS=""
10580 GTK_LIBS=""
10581 ## If we have a custom action on failure, don't print errors, but
10582 ## do set a variable so people can do so.
10583 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10584
10585 fi
10586
10587
10588
10589 else
10590 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10591 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10592 fi
10593 fi
10594
10595 if test $succeeded = yes; then
10596 pkg_check_gtk=yes
10597 else
10598 pkg_check_gtk=no
10599 fi
10600
10601 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10602 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10603 fi
10604
10605 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10606
10607 GTK_OBJ=emacsgtkfixed.o
10608 term_header=gtkutil.h
10609 fi
10610
10611 if test "$pkg_check_gtk" != "yes"; then
10612 HAVE_GTK=no
10613 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10614 GLIB_REQUIRED=2.10
10615 GTK_REQUIRED=2.10
10616 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10617
10618
10619 succeeded=no
10620
10621 if test "$PKG_CONFIG" = "no" ; then
10622 pkg_check_gtk=no
10623 else
10624 PKG_CONFIG_MIN_VERSION=0.9.0
10625 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10627 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10628
10629 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10630 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10631 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10632 edit_cflags="
10633 s,///*,/,g
10634 s/^/ /
10635 s/ -I/ $isystem/g
10636 s/^ //
10637 "
10638 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10639 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10641 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10642 succeeded=yes
10643 else
10644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10645 $as_echo "no" >&6; }
10646 GTK_CFLAGS=""
10647 GTK_LIBS=""
10648 ## If we have a custom action on failure, don't print errors, but
10649 ## do set a variable so people can do so.
10650 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10651
10652 fi
10653
10654
10655
10656 else
10657 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10658 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10659 fi
10660 fi
10661
10662 if test $succeeded = yes; then
10663 pkg_check_gtk=yes
10664 else
10665 pkg_check_gtk=no
10666 fi
10667
10668 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10669 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10670 fi
10671 fi
10672 fi
10673
10674 if test x"$pkg_check_gtk" = xyes; then
10675
10676
10677
10678 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10679 CFLAGS="$CFLAGS $GTK_CFLAGS"
10680 LIBS="$GTK_LIBS $LIBS"
10681 GTK_COMPILES=no
10682 for ac_func in gtk_main
10683 do :
10684 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10685 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10686 cat >>confdefs.h <<_ACEOF
10687 #define HAVE_GTK_MAIN 1
10688 _ACEOF
10689 GTK_COMPILES=yes
10690 fi
10691 done
10692
10693 if test "${GTK_COMPILES}" != "yes"; then
10694 if test "$USE_X_TOOLKIT" != "maybe"; then
10695 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10696 fi
10697 else
10698 HAVE_GTK=yes
10699
10700 $as_echo "#define USE_GTK 1" >>confdefs.h
10701
10702 GTK_OBJ="gtkutil.o $GTK_OBJ"
10703 USE_X_TOOLKIT=none
10704 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10705 :
10706 else
10707 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10708 closing open displays. This is no problem if you just use
10709 one display, but if you use more than one and close one of them
10710 Emacs may crash." >&5
10711 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10712 closing open displays. This is no problem if you just use
10713 one display, but if you use more than one and close one of them
10714 Emacs may crash." >&2;}
10715 sleep 3
10716 fi
10717 fi
10718
10719 fi
10720
10721
10722
10723 if test "${HAVE_GTK}" = "yes"; then
10724
10725 if test "$with_toolkit_scroll_bars" != no; then
10726 with_toolkit_scroll_bars=yes
10727 fi
10728
10729 HAVE_GTK_FILE_SELECTION=no
10730 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10731 #include <gtk/gtk.h>
10732 "
10733 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10734 HAVE_GTK_FILE_SELECTION=yes
10735 else
10736 HAVE_GTK_FILE_SELECTION=no
10737 fi
10738
10739 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10740 for ac_func in gtk_file_selection_new
10741 do :
10742 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10743 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10744 cat >>confdefs.h <<_ACEOF
10745 #define HAVE_GTK_FILE_SELECTION_NEW 1
10746 _ACEOF
10747
10748 fi
10749 done
10750
10751 fi
10752
10753
10754 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10755 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10756 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10757 gtk_orientable_set_orientation \
10758 gtk_window_set_has_resize_grip
10759 do :
10760 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10761 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10762 eval as_val=\$$as_ac_var
10763 if test "x$as_val" = x""yes; then :
10764 cat >>confdefs.h <<_ACEOF
10765 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10766 _ACEOF
10767
10768 fi
10769 done
10770
10771
10772 term_header=gtkutil.h
10773 fi
10774
10775 HAVE_DBUS=no
10776 DBUS_OBJ=
10777 if test "${with_dbus}" = "yes"; then
10778
10779 succeeded=no
10780
10781 if test "$PKG_CONFIG" = "no" ; then
10782 HAVE_DBUS=no
10783 else
10784 PKG_CONFIG_MIN_VERSION=0.9.0
10785 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10787 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10788
10789 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10790 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10791 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10792 edit_cflags="
10793 s,///*,/,g
10794 s/^/ /
10795 s/ -I/ $isystem/g
10796 s/^ //
10797 "
10798 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10799 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10801 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10802 succeeded=yes
10803 else
10804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10805 $as_echo "no" >&6; }
10806 DBUS_CFLAGS=""
10807 DBUS_LIBS=""
10808 ## If we have a custom action on failure, don't print errors, but
10809 ## do set a variable so people can do so.
10810 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
10811
10812 fi
10813
10814
10815
10816 else
10817 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10818 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10819 fi
10820 fi
10821
10822 if test $succeeded = yes; then
10823 HAVE_DBUS=yes
10824 else
10825 HAVE_DBUS=no
10826 fi
10827
10828 if test "$HAVE_DBUS" = yes; then
10829 LIBS="$LIBS $DBUS_LIBS"
10830
10831 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10832
10833 for ac_func in dbus_watch_get_unix_fd \
10834 dbus_type_is_valid \
10835 dbus_validate_bus_name \
10836 dbus_validate_path \
10837 dbus_validate_interface \
10838 dbus_validate_member
10839 do :
10840 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10841 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10842 eval as_val=\$$as_ac_var
10843 if test "x$as_val" = x""yes; then :
10844 cat >>confdefs.h <<_ACEOF
10845 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10846 _ACEOF
10847
10848 fi
10849 done
10850
10851 DBUS_OBJ=dbusbind.o
10852 fi
10853 fi
10854
10855
10856 HAVE_GSETTINGS=no
10857 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10858
10859 succeeded=no
10860
10861 if test "$PKG_CONFIG" = "no" ; then
10862 HAVE_GSETTINGS=no
10863 else
10864 PKG_CONFIG_MIN_VERSION=0.9.0
10865 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10867 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10868
10869 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10870 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10871 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10872 edit_cflags="
10873 s,///*,/,g
10874 s/^/ /
10875 s/ -I/ $isystem/g
10876 s/^ //
10877 "
10878 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10879 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10881 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10882 succeeded=yes
10883 else
10884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10885 $as_echo "no" >&6; }
10886 GSETTINGS_CFLAGS=""
10887 GSETTINGS_LIBS=""
10888 ## If we have a custom action on failure, don't print errors, but
10889 ## do set a variable so people can do so.
10890 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gio-2.0 >= 2.26"`
10891
10892 fi
10893
10894
10895
10896 else
10897 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10898 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10899 fi
10900 fi
10901
10902 if test $succeeded = yes; then
10903 HAVE_GSETTINGS=yes
10904 else
10905 HAVE_GSETTINGS=no
10906 fi
10907
10908 if test "$HAVE_GSETTINGS" = "yes"; then
10909
10910 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
10911
10912 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
10913 SETTINGS_LIBS="$GSETTINGS_LIBS"
10914 fi
10915 fi
10916
10917 HAVE_GCONF=no
10918 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
10919
10920 succeeded=no
10921
10922 if test "$PKG_CONFIG" = "no" ; then
10923 HAVE_GCONF=no
10924 else
10925 PKG_CONFIG_MIN_VERSION=0.9.0
10926 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
10928 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
10929
10930 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
10931 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
10932 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
10933 edit_cflags="
10934 s,///*,/,g
10935 s/^/ /
10936 s/ -I/ $isystem/g
10937 s/^ //
10938 "
10939 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
10940 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
10941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
10942 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
10943 succeeded=yes
10944 else
10945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10946 $as_echo "no" >&6; }
10947 GCONF_CFLAGS=""
10948 GCONF_LIBS=""
10949 ## If we have a custom action on failure, don't print errors, but
10950 ## do set a variable so people can do so.
10951 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
10952
10953 fi
10954
10955
10956
10957 else
10958 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10959 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10960 fi
10961 fi
10962
10963 if test $succeeded = yes; then
10964 HAVE_GCONF=yes
10965 else
10966 HAVE_GCONF=no
10967 fi
10968
10969 if test "$HAVE_GCONF" = yes; then
10970
10971 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
10972
10973 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
10974 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
10975 fi
10976 fi
10977
10978 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
10979
10980 succeeded=no
10981
10982 if test "$PKG_CONFIG" = "no" ; then
10983 HAVE_GOBJECT=no
10984 else
10985 PKG_CONFIG_MIN_VERSION=0.9.0
10986 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
10988 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
10989
10990 if $PKG_CONFIG --exists "gobject-2.0 >= 2.0" 2>&5 &&
10991 GOBJECT_CFLAGS=`$PKG_CONFIG --cflags "gobject-2.0 >= 2.0" 2>&5` &&
10992 GOBJECT_LIBS=`$PKG_CONFIG --libs "gobject-2.0 >= 2.0" 2>&5`; then
10993 edit_cflags="
10994 s,///*,/,g
10995 s/^/ /
10996 s/ -I/ $isystem/g
10997 s/^ //
10998 "
10999 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11000 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11002 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11003 succeeded=yes
11004 else
11005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11006 $as_echo "no" >&6; }
11007 GOBJECT_CFLAGS=""
11008 GOBJECT_LIBS=""
11009 ## If we have a custom action on failure, don't print errors, but
11010 ## do set a variable so people can do so.
11011 GOBJECT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gobject-2.0 >= 2.0"`
11012
11013 fi
11014
11015
11016
11017 else
11018 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11019 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11020 fi
11021 fi
11022
11023 if test $succeeded = yes; then
11024 HAVE_GOBJECT=yes
11025 else
11026 HAVE_GOBJECT=no
11027 fi
11028
11029 if test "$HAVE_GOBJECT" = "yes"; then
11030 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11031 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11032 fi
11033 SAVE_CFLAGS="$CFLAGS"
11034 SAVE_LIBS="$LIBS"
11035 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11036 LIBS="$SETTINGS_LIBS $LIBS"
11037 for ac_func in g_type_init
11038 do :
11039 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11040 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11041 cat >>confdefs.h <<_ACEOF
11042 #define HAVE_G_TYPE_INIT 1
11043 _ACEOF
11044
11045 fi
11046 done
11047
11048 CFLAGS="$SAVE_CFLAGS"
11049 LIBS="$SAVE_LIBS"
11050 fi
11051
11052
11053
11054
11055 HAVE_LIBSELINUX=no
11056 LIBSELINUX_LIBS=
11057 if test "${with_selinux}" = "yes"; then
11058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11059 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11060 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11061 $as_echo_n "(cached) " >&6
11062 else
11063 ac_check_lib_save_LIBS=$LIBS
11064 LIBS="-lselinux $LIBS"
11065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11066 /* end confdefs.h. */
11067
11068 /* Override any GCC internal prototype to avoid an error.
11069 Use char because int might match the return type of a GCC
11070 builtin and then its argument prototype would still apply. */
11071 #ifdef __cplusplus
11072 extern "C"
11073 #endif
11074 char lgetfilecon ();
11075 int
11076 main ()
11077 {
11078 return lgetfilecon ();
11079 ;
11080 return 0;
11081 }
11082 _ACEOF
11083 if ac_fn_c_try_link "$LINENO"; then :
11084 ac_cv_lib_selinux_lgetfilecon=yes
11085 else
11086 ac_cv_lib_selinux_lgetfilecon=no
11087 fi
11088 rm -f core conftest.err conftest.$ac_objext \
11089 conftest$ac_exeext conftest.$ac_ext
11090 LIBS=$ac_check_lib_save_LIBS
11091 fi
11092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11093 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11094 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11095 HAVE_LIBSELINUX=yes
11096 else
11097 HAVE_LIBSELINUX=no
11098 fi
11099
11100 if test "$HAVE_LIBSELINUX" = yes; then
11101
11102 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11103
11104 LIBSELINUX_LIBS=-lselinux
11105 fi
11106 fi
11107
11108
11109 HAVE_GNUTLS=no
11110 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11111 if test "${with_gnutls}" = "yes" ; then
11112
11113 succeeded=no
11114
11115 if test "$PKG_CONFIG" = "no" ; then
11116 HAVE_GNUTLS=no
11117 else
11118 PKG_CONFIG_MIN_VERSION=0.9.0
11119 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11121 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11122
11123 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11124 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11125 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11126 edit_cflags="
11127 s,///*,/,g
11128 s/^/ /
11129 s/ -I/ $isystem/g
11130 s/^ //
11131 "
11132 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11133 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11135 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11136 succeeded=yes
11137 else
11138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11139 $as_echo "no" >&6; }
11140 LIBGNUTLS_CFLAGS=""
11141 LIBGNUTLS_LIBS=""
11142 ## If we have a custom action on failure, don't print errors, but
11143 ## do set a variable so people can do so.
11144 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.6"`
11145
11146 fi
11147
11148
11149
11150 else
11151 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11152 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11153 fi
11154 fi
11155
11156 if test $succeeded = yes; then
11157 HAVE_GNUTLS=yes
11158 else
11159 HAVE_GNUTLS=no
11160 fi
11161
11162 if test "${HAVE_GNUTLS}" = "yes"; then
11163
11164 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11165
11166 fi
11167
11168 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11169 LIBS="$LIBGNUTLS_LIBS $LIBS"
11170 for ac_func in gnutls_certificate_set_verify_function
11171 do :
11172 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11173 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11174 cat >>confdefs.h <<_ACEOF
11175 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11176 _ACEOF
11177 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11178 fi
11179 done
11180
11181
11182 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11183
11184 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11185
11186 fi
11187 fi
11188
11189
11190
11191
11192 HAVE_XAW3D=no
11193 LUCID_LIBW=
11194 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11195 if test "$with_xaw3d" != no; then
11196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11197 $as_echo_n "checking for xaw3d... " >&6; }
11198 if test "${emacs_cv_xaw3d+set}" = set; then :
11199 $as_echo_n "(cached) " >&6
11200 else
11201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11202 /* end confdefs.h. */
11203
11204 #include <X11/Intrinsic.h>
11205 #include <X11/Xaw3d/Simple.h>
11206 int
11207 main ()
11208 {
11209
11210 ;
11211 return 0;
11212 }
11213 _ACEOF
11214 if ac_fn_c_try_link "$LINENO"; then :
11215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11216 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11217 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11218 $as_echo_n "(cached) " >&6
11219 else
11220 ac_check_lib_save_LIBS=$LIBS
11221 LIBS="-lXaw3d $LIBS"
11222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11223 /* end confdefs.h. */
11224
11225 /* Override any GCC internal prototype to avoid an error.
11226 Use char because int might match the return type of a GCC
11227 builtin and then its argument prototype would still apply. */
11228 #ifdef __cplusplus
11229 extern "C"
11230 #endif
11231 char XawScrollbarSetThumb ();
11232 int
11233 main ()
11234 {
11235 return XawScrollbarSetThumb ();
11236 ;
11237 return 0;
11238 }
11239 _ACEOF
11240 if ac_fn_c_try_link "$LINENO"; then :
11241 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11242 else
11243 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11244 fi
11245 rm -f core conftest.err conftest.$ac_objext \
11246 conftest$ac_exeext conftest.$ac_ext
11247 LIBS=$ac_check_lib_save_LIBS
11248 fi
11249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11250 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11251 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11252 emacs_cv_xaw3d=yes
11253 else
11254 emacs_cv_xaw3d=no
11255 fi
11256
11257 else
11258 emacs_cv_xaw3d=no
11259 fi
11260 rm -f core conftest.err conftest.$ac_objext \
11261 conftest$ac_exeext conftest.$ac_ext
11262 fi
11263
11264 else
11265 emacs_cv_xaw3d=no
11266 fi
11267 if test $emacs_cv_xaw3d = yes; then
11268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11269 $as_echo "yes; using Lucid toolkit" >&6; }
11270 USE_X_TOOLKIT=LUCID
11271 HAVE_XAW3D=yes
11272 LUCID_LIBW=-lXaw3d
11273
11274 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11275
11276 else
11277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11278 $as_echo "no" >&6; }
11279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11280 $as_echo_n "checking for libXaw... " >&6; }
11281 if test "${emacs_cv_xaw+set}" = set; then :
11282 $as_echo_n "(cached) " >&6
11283 else
11284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11285 /* end confdefs.h. */
11286
11287 #include <X11/Intrinsic.h>
11288 #include <X11/Xaw/Simple.h>
11289 int
11290 main ()
11291 {
11292
11293 ;
11294 return 0;
11295 }
11296 _ACEOF
11297 if ac_fn_c_try_link "$LINENO"; then :
11298 emacs_cv_xaw=yes
11299 else
11300 emacs_cv_xaw=no
11301 fi
11302 rm -f core conftest.err conftest.$ac_objext \
11303 conftest$ac_exeext conftest.$ac_ext
11304 fi
11305
11306 if test $emacs_cv_xaw = yes; then
11307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11308 $as_echo "yes; using Lucid toolkit" >&6; }
11309 USE_X_TOOLKIT=LUCID
11310 LUCID_LIBW=-lXaw
11311 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11312 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11313 else
11314 as_fn_error "No X toolkit could be found.
11315 If you are sure you want Emacs compiled without an X toolkit, pass
11316 --with-x-toolkit=no
11317 to configure. Otherwise, install the development libraries for the toolkit
11318 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11319 fi
11320 fi
11321 fi
11322
11323 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11324
11325 LIBXTR6=
11326 if test "${USE_X_TOOLKIT}" != "none"; then
11327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11328 $as_echo_n "checking X11 toolkit version... " >&6; }
11329 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11330 $as_echo_n "(cached) " >&6
11331 else
11332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11333 /* end confdefs.h. */
11334 #include <X11/Intrinsic.h>
11335 int
11336 main ()
11337 {
11338 #if XtSpecificationRelease < 6
11339 fail;
11340 #endif
11341
11342 ;
11343 return 0;
11344 }
11345 _ACEOF
11346 if ac_fn_c_try_link "$LINENO"; then :
11347 emacs_cv_x11_toolkit_version_6=yes
11348 else
11349 emacs_cv_x11_toolkit_version_6=no
11350 fi
11351 rm -f core conftest.err conftest.$ac_objext \
11352 conftest$ac_exeext conftest.$ac_ext
11353 fi
11354
11355 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11356 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11358 $as_echo "6 or newer" >&6; }
11359
11360 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11361
11362 LIBXTR6="-lSM -lICE"
11363 case "$opsys" in
11364 ## Use libw.a along with X11R6 Xt.
11365 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11366 esac
11367 else
11368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11369 $as_echo "before 6" >&6; }
11370 fi
11371
11372 OLDLIBS="$LIBS"
11373 if test x$HAVE_X11XTR6 = xyes; then
11374 LIBS="-lXt -lSM -lICE $LIBS"
11375 else
11376 LIBS="-lXt $LIBS"
11377 fi
11378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11379 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11380 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11381 $as_echo_n "(cached) " >&6
11382 else
11383 ac_check_lib_save_LIBS=$LIBS
11384 LIBS="-lXmu $LIBS"
11385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11386 /* end confdefs.h. */
11387
11388 /* Override any GCC internal prototype to avoid an error.
11389 Use char because int might match the return type of a GCC
11390 builtin and then its argument prototype would still apply. */
11391 #ifdef __cplusplus
11392 extern "C"
11393 #endif
11394 char XmuConvertStandardSelection ();
11395 int
11396 main ()
11397 {
11398 return XmuConvertStandardSelection ();
11399 ;
11400 return 0;
11401 }
11402 _ACEOF
11403 if ac_fn_c_try_link "$LINENO"; then :
11404 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11405 else
11406 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11407 fi
11408 rm -f core conftest.err conftest.$ac_objext \
11409 conftest$ac_exeext conftest.$ac_ext
11410 LIBS=$ac_check_lib_save_LIBS
11411 fi
11412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11413 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11414 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11415 cat >>confdefs.h <<_ACEOF
11416 #define HAVE_LIBXMU 1
11417 _ACEOF
11418
11419 LIBS="-lXmu $LIBS"
11420
11421 fi
11422
11423 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11424 fi
11425
11426
11427 LIBXMU=-lXmu
11428 case $opsys in
11429 ## These systems don't supply Xmu.
11430 hpux* | aix4-2 )
11431 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11432 ;;
11433 esac
11434
11435
11436 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11437 if test "${HAVE_X11}" = "yes"; then
11438 if test "${USE_X_TOOLKIT}" != "none"; then
11439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11440 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11441 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11442 $as_echo_n "(cached) " >&6
11443 else
11444 ac_check_lib_save_LIBS=$LIBS
11445 LIBS="-lXext $LIBS"
11446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11447 /* end confdefs.h. */
11448
11449 /* Override any GCC internal prototype to avoid an error.
11450 Use char because int might match the return type of a GCC
11451 builtin and then its argument prototype would still apply. */
11452 #ifdef __cplusplus
11453 extern "C"
11454 #endif
11455 char XShapeQueryExtension ();
11456 int
11457 main ()
11458 {
11459 return XShapeQueryExtension ();
11460 ;
11461 return 0;
11462 }
11463 _ACEOF
11464 if ac_fn_c_try_link "$LINENO"; then :
11465 ac_cv_lib_Xext_XShapeQueryExtension=yes
11466 else
11467 ac_cv_lib_Xext_XShapeQueryExtension=no
11468 fi
11469 rm -f core conftest.err conftest.$ac_objext \
11470 conftest$ac_exeext conftest.$ac_ext
11471 LIBS=$ac_check_lib_save_LIBS
11472 fi
11473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11474 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11475 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11476 cat >>confdefs.h <<_ACEOF
11477 #define HAVE_LIBXEXT 1
11478 _ACEOF
11479
11480 LIBS="-lXext $LIBS"
11481
11482 fi
11483
11484 fi
11485 fi
11486
11487 LIBXP=
11488 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11489 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11490 if test -d /usr/include/openmotif; then
11491 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11492 emacs_cv_openmotif=yes
11493 case "$canonical" in
11494 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11495 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11496 ;;
11497 *)
11498 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11499 esac
11500 else
11501 emacs_cv_openmotif=no
11502 fi
11503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11504 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11505 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11506 $as_echo_n "(cached) " >&6
11507 else
11508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11509 /* end confdefs.h. */
11510 #include <Xm/Xm.h>
11511 int
11512 main ()
11513 {
11514 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11515 int x = 5;
11516 #else
11517 Motif version prior to 2.1.
11518 #endif
11519 ;
11520 return 0;
11521 }
11522 _ACEOF
11523 if ac_fn_c_try_compile "$LINENO"; then :
11524 emacs_cv_motif_version_2_1=yes
11525 else
11526 emacs_cv_motif_version_2_1=no
11527 fi
11528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11529 fi
11530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11531 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11532 if test $emacs_cv_motif_version_2_1 = yes; then
11533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11534 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11535 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11536 $as_echo_n "(cached) " >&6
11537 else
11538 ac_check_lib_save_LIBS=$LIBS
11539 LIBS="-lXp $LIBS"
11540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11541 /* end confdefs.h. */
11542
11543 /* Override any GCC internal prototype to avoid an error.
11544 Use char because int might match the return type of a GCC
11545 builtin and then its argument prototype would still apply. */
11546 #ifdef __cplusplus
11547 extern "C"
11548 #endif
11549 char XpCreateContext ();
11550 int
11551 main ()
11552 {
11553 return XpCreateContext ();
11554 ;
11555 return 0;
11556 }
11557 _ACEOF
11558 if ac_fn_c_try_link "$LINENO"; then :
11559 ac_cv_lib_Xp_XpCreateContext=yes
11560 else
11561 ac_cv_lib_Xp_XpCreateContext=no
11562 fi
11563 rm -f core conftest.err conftest.$ac_objext \
11564 conftest$ac_exeext conftest.$ac_ext
11565 LIBS=$ac_check_lib_save_LIBS
11566 fi
11567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11568 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11569 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11570 LIBXP=-lXp
11571 fi
11572
11573 if test x$emacs_cv_openmotif = xyes; then
11574 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11575 fi
11576 else
11577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11578 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11579 if test "${emacs_cv_lesstif+set}" = set; then :
11580 $as_echo_n "(cached) " >&6
11581 else
11582 # We put this in CFLAGS temporarily to precede other -I options
11583 # that might be in CFLAGS temporarily.
11584 # We put this in CPPFLAGS where it precedes the other -I options.
11585 OLD_CPPFLAGS=$CPPFLAGS
11586 OLD_CFLAGS=$CFLAGS
11587 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11588 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11590 /* end confdefs.h. */
11591 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11592 int
11593 main ()
11594 {
11595 int x = 5;
11596 ;
11597 return 0;
11598 }
11599 _ACEOF
11600 if ac_fn_c_try_compile "$LINENO"; then :
11601 emacs_cv_lesstif=yes
11602 else
11603 emacs_cv_lesstif=no
11604 fi
11605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11606 fi
11607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11608 $as_echo "$emacs_cv_lesstif" >&6; }
11609 if test $emacs_cv_lesstif = yes; then
11610 # Make sure this -I option remains in CPPFLAGS after it is set
11611 # back to REAL_CPPFLAGS.
11612 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11613 # have those other -I options anyway. Ultimately, having this
11614 # directory ultimately in CPPFLAGS will be enough.
11615 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11616 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11617 else
11618 CFLAGS=$OLD_CFLAGS
11619 CPPFLAGS=$OLD_CPPFLAGS
11620 fi
11621 fi
11622 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11623 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11624
11625 else
11626 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11627 fi
11628
11629
11630 fi
11631
11632
11633 USE_TOOLKIT_SCROLL_BARS=no
11634 if test "${with_toolkit_scroll_bars}" != "no"; then
11635 if test "${USE_X_TOOLKIT}" != "none"; then
11636 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11637 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11638
11639 HAVE_XAW3D=no
11640 USE_TOOLKIT_SCROLL_BARS=yes
11641 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11642 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11643
11644 USE_TOOLKIT_SCROLL_BARS=yes
11645 fi
11646 elif test "${HAVE_GTK}" = "yes"; then
11647 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11648
11649 USE_TOOLKIT_SCROLL_BARS=yes
11650 elif test "${HAVE_NS}" = "yes"; then
11651 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11652
11653 USE_TOOLKIT_SCROLL_BARS=yes
11654 fi
11655 fi
11656
11657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11658 /* end confdefs.h. */
11659
11660 #include <X11/Xlib.h>
11661 #include <X11/Xresource.h>
11662 int
11663 main ()
11664 {
11665 XIMProc callback;
11666 ;
11667 return 0;
11668 }
11669 _ACEOF
11670 if ac_fn_c_try_compile "$LINENO"; then :
11671 HAVE_XIM=yes
11672
11673 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11674
11675 else
11676 HAVE_XIM=no
11677 fi
11678 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11679
11680
11681 if test "${with_xim}" != "no"; then
11682
11683 $as_echo "#define USE_XIM 1" >>confdefs.h
11684
11685 fi
11686
11687
11688 if test "${HAVE_XIM}" != "no"; then
11689 late_CFLAGS=$CFLAGS
11690 if test "$GCC" = yes; then
11691 CFLAGS="$CFLAGS --pedantic-errors"
11692 fi
11693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11694 /* end confdefs.h. */
11695
11696 #include <X11/Xlib.h>
11697 #include <X11/Xresource.h>
11698 int
11699 main ()
11700 {
11701 Display *display;
11702 XrmDatabase db;
11703 char *res_name;
11704 char *res_class;
11705 XIMProc callback;
11706 XPointer *client_data;
11707 #ifndef __GNUC__
11708 /* If we're not using GCC, it's probably not XFree86, and this is
11709 probably right, but we can't use something like --pedantic-errors. */
11710 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11711 char*, XIMProc, XPointer*);
11712 #endif
11713 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11714 client_data);
11715 ;
11716 return 0;
11717 }
11718 _ACEOF
11719 if ac_fn_c_try_compile "$LINENO"; then :
11720 emacs_cv_arg6_star=yes
11721 fi
11722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11723 if test "$emacs_cv_arg6_star" = yes; then
11724 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11725
11726 else
11727 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11728
11729 fi
11730 CFLAGS=$late_CFLAGS
11731 fi
11732
11733 ### Start of font-backend (under any platform) section.
11734 # (nothing here yet -- this is a placeholder)
11735 ### End of font-backend (under any platform) section.
11736
11737 ### Start of font-backend (under X11) section.
11738 if test "${HAVE_X11}" = "yes"; then
11739
11740 succeeded=no
11741
11742 if test "$PKG_CONFIG" = "no" ; then
11743 HAVE_FC=no
11744 else
11745 PKG_CONFIG_MIN_VERSION=0.9.0
11746 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11748 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11749
11750 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11751 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11752 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11753 edit_cflags="
11754 s,///*,/,g
11755 s/^/ /
11756 s/ -I/ $isystem/g
11757 s/^ //
11758 "
11759 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11760 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11762 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11763 succeeded=yes
11764 else
11765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11766 $as_echo "no" >&6; }
11767 FONTCONFIG_CFLAGS=""
11768 FONTCONFIG_LIBS=""
11769 ## If we have a custom action on failure, don't print errors, but
11770 ## do set a variable so people can do so.
11771 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
11772
11773 fi
11774
11775
11776
11777 else
11778 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11779 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11780 fi
11781 fi
11782
11783 if test $succeeded = yes; then
11784 HAVE_FC=yes
11785 else
11786 HAVE_FC=no
11787 fi
11788
11789
11790 ## Use -lXft if available, unless `--with-xft=no'.
11791 HAVE_XFT=maybe
11792 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11793 with_xft="no";
11794 fi
11795 if test "x${with_xft}" != "xno"; then
11796
11797
11798 succeeded=no
11799
11800 if test "$PKG_CONFIG" = "no" ; then
11801 HAVE_XFT=no
11802 else
11803 PKG_CONFIG_MIN_VERSION=0.9.0
11804 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11806 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11807
11808 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11809 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11810 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11811 edit_cflags="
11812 s,///*,/,g
11813 s/^/ /
11814 s/ -I/ $isystem/g
11815 s/^ //
11816 "
11817 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11818 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11820 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11821 succeeded=yes
11822 else
11823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11824 $as_echo "no" >&6; }
11825 XFT_CFLAGS=""
11826 XFT_LIBS=""
11827 ## If we have a custom action on failure, don't print errors, but
11828 ## do set a variable so people can do so.
11829 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
11830
11831 fi
11832
11833
11834
11835 else
11836 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11837 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11838 fi
11839 fi
11840
11841 if test $succeeded = yes; then
11842 :
11843 else
11844 HAVE_XFT=no
11845 fi
11846
11847 ## Because xftfont.c uses XRenderQueryExtension, we also
11848 ## need to link to -lXrender.
11849 HAVE_XRENDER=no
11850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11851 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11852 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11853 $as_echo_n "(cached) " >&6
11854 else
11855 ac_check_lib_save_LIBS=$LIBS
11856 LIBS="-lXrender $LIBS"
11857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11858 /* end confdefs.h. */
11859
11860 /* Override any GCC internal prototype to avoid an error.
11861 Use char because int might match the return type of a GCC
11862 builtin and then its argument prototype would still apply. */
11863 #ifdef __cplusplus
11864 extern "C"
11865 #endif
11866 char XRenderQueryExtension ();
11867 int
11868 main ()
11869 {
11870 return XRenderQueryExtension ();
11871 ;
11872 return 0;
11873 }
11874 _ACEOF
11875 if ac_fn_c_try_link "$LINENO"; then :
11876 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11877 else
11878 ac_cv_lib_Xrender_XRenderQueryExtension=no
11879 fi
11880 rm -f core conftest.err conftest.$ac_objext \
11881 conftest$ac_exeext conftest.$ac_ext
11882 LIBS=$ac_check_lib_save_LIBS
11883 fi
11884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11885 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11886 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11887 HAVE_XRENDER=yes
11888 fi
11889
11890 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11891 OLD_CPPFLAGS="$CPPFLAGS"
11892 OLD_CFLAGS="$CFLAGS"
11893 OLD_LIBS="$LIBS"
11894 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11895 CFLAGS="$CFLAGS $XFT_CFLAGS"
11896 XFT_LIBS="-lXrender $XFT_LIBS"
11897 LIBS="$XFT_LIBS $LIBS"
11898 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
11899 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
11900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
11901 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
11902 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
11903 $as_echo_n "(cached) " >&6
11904 else
11905 ac_check_lib_save_LIBS=$LIBS
11906 LIBS="-lXft $XFT_LIBS $LIBS"
11907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11908 /* end confdefs.h. */
11909
11910 /* Override any GCC internal prototype to avoid an error.
11911 Use char because int might match the return type of a GCC
11912 builtin and then its argument prototype would still apply. */
11913 #ifdef __cplusplus
11914 extern "C"
11915 #endif
11916 char XftFontOpen ();
11917 int
11918 main ()
11919 {
11920 return XftFontOpen ();
11921 ;
11922 return 0;
11923 }
11924 _ACEOF
11925 if ac_fn_c_try_link "$LINENO"; then :
11926 ac_cv_lib_Xft_XftFontOpen=yes
11927 else
11928 ac_cv_lib_Xft_XftFontOpen=no
11929 fi
11930 rm -f core conftest.err conftest.$ac_objext \
11931 conftest$ac_exeext conftest.$ac_ext
11932 LIBS=$ac_check_lib_save_LIBS
11933 fi
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11935 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
11936 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
11937 HAVE_XFT=yes
11938 fi
11939
11940 fi
11941
11942
11943
11944 if test "${HAVE_XFT}" = "yes"; then
11945
11946 $as_echo "#define HAVE_XFT 1" >>confdefs.h
11947
11948
11949 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
11950 else
11951 CPPFLAGS="$OLD_CPPFLAGS"
11952 CFLAGS="$OLD_CFLAGS"
11953 LIBS="$OLD_LIBS"
11954 fi # "${HAVE_XFT}" = "yes"
11955 fi # "$HAVE_XFT" != no
11956 fi # "x${with_xft}" != "xno"
11957
11958 ## We used to allow building with FreeType and without Xft.
11959 ## However, the ftx font backend driver is not in good shape.
11960 if test "$HAVE_XFT" != "yes"; then
11961 HAVE_XFT=no
11962 HAVE_FREETYPE=no
11963 else
11964
11965 succeeded=no
11966
11967 if test "$PKG_CONFIG" = "no" ; then
11968 HAVE_FREETYPE=no
11969 else
11970 PKG_CONFIG_MIN_VERSION=0.9.0
11971 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
11973 $as_echo_n "checking for freetype2... " >&6; }
11974
11975 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
11976 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
11977 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
11978 edit_cflags="
11979 s,///*,/,g
11980 s/^/ /
11981 s/ -I/ $isystem/g
11982 s/^ //
11983 "
11984 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
11985 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
11986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
11987 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
11988 succeeded=yes
11989 else
11990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11991 $as_echo "no" >&6; }
11992 FREETYPE_CFLAGS=""
11993 FREETYPE_LIBS=""
11994 ## If we have a custom action on failure, don't print errors, but
11995 ## do set a variable so people can do so.
11996 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
11997
11998 fi
11999
12000
12001
12002 else
12003 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12004 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12005 fi
12006 fi
12007
12008 if test $succeeded = yes; then
12009 HAVE_FREETYPE=yes
12010 else
12011 HAVE_FREETYPE=no
12012 fi
12013
12014
12015 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12016 fi
12017
12018 HAVE_LIBOTF=no
12019 if test "${HAVE_FREETYPE}" = "yes"; then
12020
12021 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12022
12023 if test "${with_libotf}" != "no"; then
12024
12025 succeeded=no
12026
12027 if test "$PKG_CONFIG" = "no" ; then
12028 HAVE_LIBOTF=no
12029 else
12030 PKG_CONFIG_MIN_VERSION=0.9.0
12031 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12033 $as_echo_n "checking for libotf... " >&6; }
12034
12035 if $PKG_CONFIG --exists "libotf" 2>&5 &&
12036 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
12037 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
12038 edit_cflags="
12039 s,///*,/,g
12040 s/^/ /
12041 s/ -I/ $isystem/g
12042 s/^ //
12043 "
12044 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12045 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12047 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12048 succeeded=yes
12049 else
12050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12051 $as_echo "no" >&6; }
12052 LIBOTF_CFLAGS=""
12053 LIBOTF_LIBS=""
12054 ## If we have a custom action on failure, don't print errors, but
12055 ## do set a variable so people can do so.
12056 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
12057
12058 fi
12059
12060
12061
12062 else
12063 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12064 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12065 fi
12066 fi
12067
12068 if test $succeeded = yes; then
12069 HAVE_LIBOTF=yes
12070 else
12071 HAVE_LIBOTF=no
12072 fi
12073
12074 if test "$HAVE_LIBOTF" = "yes"; then
12075
12076 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12077
12078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12079 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12080 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12081 $as_echo_n "(cached) " >&6
12082 else
12083 ac_check_lib_save_LIBS=$LIBS
12084 LIBS="-lotf $LIBS"
12085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12086 /* end confdefs.h. */
12087
12088 /* Override any GCC internal prototype to avoid an error.
12089 Use char because int might match the return type of a GCC
12090 builtin and then its argument prototype would still apply. */
12091 #ifdef __cplusplus
12092 extern "C"
12093 #endif
12094 char OTF_get_variation_glyphs ();
12095 int
12096 main ()
12097 {
12098 return OTF_get_variation_glyphs ();
12099 ;
12100 return 0;
12101 }
12102 _ACEOF
12103 if ac_fn_c_try_link "$LINENO"; then :
12104 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12105 else
12106 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12107 fi
12108 rm -f core conftest.err conftest.$ac_objext \
12109 conftest$ac_exeext conftest.$ac_ext
12110 LIBS=$ac_check_lib_save_LIBS
12111 fi
12112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12113 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12114 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12115 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12116 else
12117 HAVE_OTF_GET_VARIATION_GLYPHS=no
12118 fi
12119
12120 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12121
12122 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12123
12124 fi
12125 fi
12126 fi
12127 fi
12128
12129 HAVE_M17N_FLT=no
12130 if test "${HAVE_LIBOTF}" = yes; then
12131 if test "${with_m17n_flt}" != "no"; then
12132
12133 succeeded=no
12134
12135 if test "$PKG_CONFIG" = "no" ; then
12136 HAVE_M17N_FLT=no
12137 else
12138 PKG_CONFIG_MIN_VERSION=0.9.0
12139 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12141 $as_echo_n "checking for m17n-flt... " >&6; }
12142
12143 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12144 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12145 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12146 edit_cflags="
12147 s,///*,/,g
12148 s/^/ /
12149 s/ -I/ $isystem/g
12150 s/^ //
12151 "
12152 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12153 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12155 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12156 succeeded=yes
12157 else
12158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12159 $as_echo "no" >&6; }
12160 M17N_FLT_CFLAGS=""
12161 M17N_FLT_LIBS=""
12162 ## If we have a custom action on failure, don't print errors, but
12163 ## do set a variable so people can do so.
12164 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
12165
12166 fi
12167
12168
12169
12170 else
12171 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12172 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12173 fi
12174 fi
12175
12176 if test $succeeded = yes; then
12177 HAVE_M17N_FLT=yes
12178 else
12179 HAVE_M17N_FLT=no
12180 fi
12181
12182 if test "$HAVE_M17N_FLT" = "yes"; then
12183
12184 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12185
12186 fi
12187 fi
12188 fi
12189 else
12190 HAVE_XFT=no
12191 HAVE_FREETYPE=no
12192 HAVE_LIBOTF=no
12193 HAVE_M17N_FLT=no
12194 fi
12195
12196 ### End of font-backend (under X11) section.
12197
12198
12199
12200
12201
12202
12203
12204
12205
12206
12207 ### Use -lXpm if available, unless `--with-xpm=no'.
12208 HAVE_XPM=no
12209 LIBXPM=
12210 if test "${HAVE_X11}" = "yes"; then
12211 if test "${with_xpm}" != "no"; then
12212 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12213 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12215 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12216 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12217 $as_echo_n "(cached) " >&6
12218 else
12219 ac_check_lib_save_LIBS=$LIBS
12220 LIBS="-lXpm -lX11 $LIBS"
12221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12222 /* end confdefs.h. */
12223
12224 /* Override any GCC internal prototype to avoid an error.
12225 Use char because int might match the return type of a GCC
12226 builtin and then its argument prototype would still apply. */
12227 #ifdef __cplusplus
12228 extern "C"
12229 #endif
12230 char XpmReadFileToPixmap ();
12231 int
12232 main ()
12233 {
12234 return XpmReadFileToPixmap ();
12235 ;
12236 return 0;
12237 }
12238 _ACEOF
12239 if ac_fn_c_try_link "$LINENO"; then :
12240 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12241 else
12242 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12243 fi
12244 rm -f core conftest.err conftest.$ac_objext \
12245 conftest$ac_exeext conftest.$ac_ext
12246 LIBS=$ac_check_lib_save_LIBS
12247 fi
12248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12249 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12250 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12251 HAVE_XPM=yes
12252 fi
12253
12254 fi
12255
12256
12257 if test "${HAVE_XPM}" = "yes"; then
12258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12259 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12261 /* end confdefs.h. */
12262 #include "X11/xpm.h"
12263 #ifndef XpmReturnAllocPixels
12264 no_return_alloc_pixels
12265 #endif
12266
12267 _ACEOF
12268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12269 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12270 HAVE_XPM=no
12271 else
12272 HAVE_XPM=yes
12273 fi
12274 rm -f conftest*
12275
12276
12277 if test "${HAVE_XPM}" = "yes"; then
12278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12279 $as_echo "yes" >&6; }
12280 else
12281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12282 $as_echo "no" >&6; }
12283 fi
12284 fi
12285 fi
12286
12287 if test "${HAVE_XPM}" = "yes"; then
12288
12289 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12290
12291 LIBXPM=-lXpm
12292 fi
12293 fi
12294
12295
12296 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12297 HAVE_JPEG=no
12298 LIBJPEG=
12299 if test "${HAVE_X11}" = "yes"; then
12300 if test "${with_jpeg}" != "no"; then
12301 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12302 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12304 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12305 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12306 $as_echo_n "(cached) " >&6
12307 else
12308 ac_check_lib_save_LIBS=$LIBS
12309 LIBS="-ljpeg $LIBS"
12310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12311 /* end confdefs.h. */
12312
12313 /* Override any GCC internal prototype to avoid an error.
12314 Use char because int might match the return type of a GCC
12315 builtin and then its argument prototype would still apply. */
12316 #ifdef __cplusplus
12317 extern "C"
12318 #endif
12319 char jpeg_destroy_compress ();
12320 int
12321 main ()
12322 {
12323 return jpeg_destroy_compress ();
12324 ;
12325 return 0;
12326 }
12327 _ACEOF
12328 if ac_fn_c_try_link "$LINENO"; then :
12329 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12330 else
12331 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12332 fi
12333 rm -f core conftest.err conftest.$ac_objext \
12334 conftest$ac_exeext conftest.$ac_ext
12335 LIBS=$ac_check_lib_save_LIBS
12336 fi
12337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12338 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12339 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12340 HAVE_JPEG=yes
12341 fi
12342
12343 fi
12344
12345
12346 fi
12347
12348 if test "${HAVE_JPEG}" = "yes"; then
12349 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12350
12351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12352 /* end confdefs.h. */
12353 #include <jpeglib.h>
12354 version=JPEG_LIB_VERSION
12355
12356 _ACEOF
12357 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12358 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12359 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12360
12361 else
12362 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12363 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12364 HAVE_JPEG=no
12365 fi
12366 rm -f conftest*
12367
12368 fi
12369 if test "${HAVE_JPEG}" = "yes"; then
12370 LIBJPEG=-ljpeg
12371 fi
12372 fi
12373
12374
12375 ### Use -lpng if available, unless `--with-png=no'.
12376 HAVE_PNG=no
12377 LIBPNG=
12378 if test "${HAVE_X11}" = "yes"; then
12379 if test "${with_png}" != "no"; then
12380 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12381 # in /usr/include/libpng.
12382 for ac_header in png.h libpng/png.h
12383 do :
12384 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12385 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12386 eval as_val=\$$as_ac_Header
12387 if test "x$as_val" = x""yes; then :
12388 cat >>confdefs.h <<_ACEOF
12389 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12390 _ACEOF
12391 break
12392 fi
12393
12394 done
12395
12396 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12398 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12399 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12400 $as_echo_n "(cached) " >&6
12401 else
12402 ac_check_lib_save_LIBS=$LIBS
12403 LIBS="-lpng -lz -lm $LIBS"
12404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12405 /* end confdefs.h. */
12406
12407 /* Override any GCC internal prototype to avoid an error.
12408 Use char because int might match the return type of a GCC
12409 builtin and then its argument prototype would still apply. */
12410 #ifdef __cplusplus
12411 extern "C"
12412 #endif
12413 char png_get_channels ();
12414 int
12415 main ()
12416 {
12417 return png_get_channels ();
12418 ;
12419 return 0;
12420 }
12421 _ACEOF
12422 if ac_fn_c_try_link "$LINENO"; then :
12423 ac_cv_lib_png_png_get_channels=yes
12424 else
12425 ac_cv_lib_png_png_get_channels=no
12426 fi
12427 rm -f core conftest.err conftest.$ac_objext \
12428 conftest$ac_exeext conftest.$ac_ext
12429 LIBS=$ac_check_lib_save_LIBS
12430 fi
12431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12432 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12433 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12434 HAVE_PNG=yes
12435 fi
12436
12437 fi
12438 fi
12439
12440 if test "${HAVE_PNG}" = "yes"; then
12441
12442 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12443
12444 LIBPNG="-lpng -lz -lm"
12445
12446 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12447 # include <libpng/png.h>
12448 #else
12449 # include <png.h>
12450 #endif
12451
12452 "
12453 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12454
12455 else
12456
12457 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12458
12459 fi
12460
12461 fi
12462 fi
12463
12464
12465 ### Use -ltiff if available, unless `--with-tiff=no'.
12466 HAVE_TIFF=no
12467 LIBTIFF=
12468 if test "${HAVE_X11}" = "yes"; then
12469 if test "${with_tiff}" != "no"; then
12470 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12471 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12472 tifflibs="-lz -lm"
12473 # At least one tiff package requires the jpeg library.
12474 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12476 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12477 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12478 $as_echo_n "(cached) " >&6
12479 else
12480 ac_check_lib_save_LIBS=$LIBS
12481 LIBS="-ltiff $tifflibs $LIBS"
12482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12483 /* end confdefs.h. */
12484
12485 /* Override any GCC internal prototype to avoid an error.
12486 Use char because int might match the return type of a GCC
12487 builtin and then its argument prototype would still apply. */
12488 #ifdef __cplusplus
12489 extern "C"
12490 #endif
12491 char TIFFGetVersion ();
12492 int
12493 main ()
12494 {
12495 return TIFFGetVersion ();
12496 ;
12497 return 0;
12498 }
12499 _ACEOF
12500 if ac_fn_c_try_link "$LINENO"; then :
12501 ac_cv_lib_tiff_TIFFGetVersion=yes
12502 else
12503 ac_cv_lib_tiff_TIFFGetVersion=no
12504 fi
12505 rm -f core conftest.err conftest.$ac_objext \
12506 conftest$ac_exeext conftest.$ac_ext
12507 LIBS=$ac_check_lib_save_LIBS
12508 fi
12509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12510 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12511 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12512 HAVE_TIFF=yes
12513 fi
12514
12515 fi
12516
12517
12518 fi
12519
12520 if test "${HAVE_TIFF}" = "yes"; then
12521
12522 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12523
12524 LIBTIFF=-ltiff
12525 fi
12526 fi
12527
12528
12529 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12530 HAVE_GIF=no
12531 LIBGIF=
12532 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12533 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12534 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12535 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12536 # Earlier versions can crash Emacs.
12537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12538 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12539 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12540 $as_echo_n "(cached) " >&6
12541 else
12542 ac_check_lib_save_LIBS=$LIBS
12543 LIBS="-lgif $LIBS"
12544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12545 /* end confdefs.h. */
12546
12547 /* Override any GCC internal prototype to avoid an error.
12548 Use char because int might match the return type of a GCC
12549 builtin and then its argument prototype would still apply. */
12550 #ifdef __cplusplus
12551 extern "C"
12552 #endif
12553 char EGifPutExtensionLast ();
12554 int
12555 main ()
12556 {
12557 return EGifPutExtensionLast ();
12558 ;
12559 return 0;
12560 }
12561 _ACEOF
12562 if ac_fn_c_try_link "$LINENO"; then :
12563 ac_cv_lib_gif_EGifPutExtensionLast=yes
12564 else
12565 ac_cv_lib_gif_EGifPutExtensionLast=no
12566 fi
12567 rm -f core conftest.err conftest.$ac_objext \
12568 conftest$ac_exeext conftest.$ac_ext
12569 LIBS=$ac_check_lib_save_LIBS
12570 fi
12571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12572 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12573 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12574 HAVE_GIF=yes
12575 else
12576 HAVE_GIF=maybe
12577 fi
12578
12579 fi
12580
12581
12582
12583 if test "$HAVE_GIF" = yes; then
12584 LIBGIF=-lgif
12585 elif test "$HAVE_GIF" = maybe; then
12586 # If gif_lib.h but no libgif, try libungif.
12587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12588 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12589 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12590 $as_echo_n "(cached) " >&6
12591 else
12592 ac_check_lib_save_LIBS=$LIBS
12593 LIBS="-lungif $LIBS"
12594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12595 /* end confdefs.h. */
12596
12597 /* Override any GCC internal prototype to avoid an error.
12598 Use char because int might match the return type of a GCC
12599 builtin and then its argument prototype would still apply. */
12600 #ifdef __cplusplus
12601 extern "C"
12602 #endif
12603 char EGifPutExtensionLast ();
12604 int
12605 main ()
12606 {
12607 return EGifPutExtensionLast ();
12608 ;
12609 return 0;
12610 }
12611 _ACEOF
12612 if ac_fn_c_try_link "$LINENO"; then :
12613 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12614 else
12615 ac_cv_lib_ungif_EGifPutExtensionLast=no
12616 fi
12617 rm -f core conftest.err conftest.$ac_objext \
12618 conftest$ac_exeext conftest.$ac_ext
12619 LIBS=$ac_check_lib_save_LIBS
12620 fi
12621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12622 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12623 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12624 HAVE_GIF=yes
12625 else
12626 HAVE_GIF=no
12627 fi
12628
12629 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12630 fi
12631
12632 if test "${HAVE_GIF}" = "yes"; then
12633
12634 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12635
12636 fi
12637 fi
12638
12639
12640 if test "${HAVE_X11}" = "yes"; then
12641 MISSING=""
12642 WITH_NO=""
12643 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12644 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12645 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12646 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12647 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12648 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12649 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12650 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12651 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12652 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12653
12654 if test "X${MISSING}" != X; then
12655 as_fn_error "The following required libraries were not found:
12656 $MISSING
12657 Maybe some development libraries/packages are missing?
12658 If you don't want to link with them give
12659 $WITH_NO
12660 as options to configure" "$LINENO" 5
12661 fi
12662 fi
12663
12664 ### Use -lgpm if available, unless `--with-gpm=no'.
12665 HAVE_GPM=no
12666 LIBGPM=
12667 if test "${with_gpm}" != "no"; then
12668 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12669 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12671 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12672 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12673 $as_echo_n "(cached) " >&6
12674 else
12675 ac_check_lib_save_LIBS=$LIBS
12676 LIBS="-lgpm $LIBS"
12677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12678 /* end confdefs.h. */
12679
12680 /* Override any GCC internal prototype to avoid an error.
12681 Use char because int might match the return type of a GCC
12682 builtin and then its argument prototype would still apply. */
12683 #ifdef __cplusplus
12684 extern "C"
12685 #endif
12686 char Gpm_Open ();
12687 int
12688 main ()
12689 {
12690 return Gpm_Open ();
12691 ;
12692 return 0;
12693 }
12694 _ACEOF
12695 if ac_fn_c_try_link "$LINENO"; then :
12696 ac_cv_lib_gpm_Gpm_Open=yes
12697 else
12698 ac_cv_lib_gpm_Gpm_Open=no
12699 fi
12700 rm -f core conftest.err conftest.$ac_objext \
12701 conftest$ac_exeext conftest.$ac_ext
12702 LIBS=$ac_check_lib_save_LIBS
12703 fi
12704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12705 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12706 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12707 HAVE_GPM=yes
12708 fi
12709
12710 fi
12711
12712
12713
12714 if test "${HAVE_GPM}" = "yes"; then
12715
12716 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12717
12718 LIBGPM=-lgpm
12719 fi
12720 fi
12721
12722
12723
12724
12725
12726
12727 GNUSTEP_CFLAGS=
12728 ### Use NeXTstep API to implement GUI.
12729 if test "${HAVE_NS}" = "yes"; then
12730
12731 $as_echo "#define HAVE_NS 1" >>confdefs.h
12732
12733 if test "${NS_IMPL_COCOA}" = "yes"; then
12734
12735 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12736
12737 fi
12738 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12739
12740 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12741
12742 # See also .m.o rule in Makefile.in */
12743 # FIXME: are all these flags really needed? Document here why. */
12744 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12745 ## Extra CFLAGS applied to src/*.m files.
12746 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"
12747 fi
12748 # We also have mouse menus.
12749 HAVE_MENUS=yes
12750 OTHER_FILES=ns-app
12751 fi
12752
12753
12754 ### Use session management (-lSM -lICE) if available
12755 HAVE_X_SM=no
12756 LIBXSM=
12757 if test "${HAVE_X11}" = "yes"; then
12758 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12759 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12761 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12762 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12763 $as_echo_n "(cached) " >&6
12764 else
12765 ac_check_lib_save_LIBS=$LIBS
12766 LIBS="-lSM -lICE $LIBS"
12767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12768 /* end confdefs.h. */
12769
12770 /* Override any GCC internal prototype to avoid an error.
12771 Use char because int might match the return type of a GCC
12772 builtin and then its argument prototype would still apply. */
12773 #ifdef __cplusplus
12774 extern "C"
12775 #endif
12776 char SmcOpenConnection ();
12777 int
12778 main ()
12779 {
12780 return SmcOpenConnection ();
12781 ;
12782 return 0;
12783 }
12784 _ACEOF
12785 if ac_fn_c_try_link "$LINENO"; then :
12786 ac_cv_lib_SM_SmcOpenConnection=yes
12787 else
12788 ac_cv_lib_SM_SmcOpenConnection=no
12789 fi
12790 rm -f core conftest.err conftest.$ac_objext \
12791 conftest$ac_exeext conftest.$ac_ext
12792 LIBS=$ac_check_lib_save_LIBS
12793 fi
12794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
12795 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
12796 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
12797 HAVE_X_SM=yes
12798 fi
12799
12800 fi
12801
12802
12803
12804 if test "${HAVE_X_SM}" = "yes"; then
12805
12806 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
12807
12808 LIBXSM="-lSM -lICE"
12809 case "$LIBS" in
12810 *-lSM*) ;;
12811 *) LIBS="$LIBXSM $LIBS" ;;
12812 esac
12813 fi
12814 fi
12815
12816
12817 ### Use libxml (-lxml2) if available
12818 HAVE_LIBXML2=no
12819 if test "${with_xml2}" != "no"; then
12820 ### I'm not sure what the version number should be, so I just guessed.
12821
12822 succeeded=no
12823
12824 if test "$PKG_CONFIG" = "no" ; then
12825 HAVE_LIBXML2=no
12826 else
12827 PKG_CONFIG_MIN_VERSION=0.9.0
12828 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
12830 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
12831
12832 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
12833 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
12834 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
12835 edit_cflags="
12836 s,///*,/,g
12837 s/^/ /
12838 s/ -I/ $isystem/g
12839 s/^ //
12840 "
12841 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
12842 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
12843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
12844 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
12845 succeeded=yes
12846 else
12847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12848 $as_echo "no" >&6; }
12849 LIBXML2_CFLAGS=""
12850 LIBXML2_LIBS=""
12851 ## If we have a custom action on failure, don't print errors, but
12852 ## do set a variable so people can do so.
12853 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
12854
12855 fi
12856
12857
12858
12859 else
12860 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12861 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12862 fi
12863 fi
12864
12865 if test $succeeded = yes; then
12866 HAVE_LIBXML2=yes
12867 else
12868 HAVE_LIBXML2=no
12869 fi
12870
12871 if test "${HAVE_LIBXML2}" = "yes"; then
12872 LIBS="$LIBXML2_LIBS $LIBS"
12873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
12874 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
12875 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
12876 $as_echo_n "(cached) " >&6
12877 else
12878 ac_check_lib_save_LIBS=$LIBS
12879 LIBS="-lxml2 $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 htmlReadMemory ();
12890 int
12891 main ()
12892 {
12893 return htmlReadMemory ();
12894 ;
12895 return 0;
12896 }
12897 _ACEOF
12898 if ac_fn_c_try_link "$LINENO"; then :
12899 ac_cv_lib_xml2_htmlReadMemory=yes
12900 else
12901 ac_cv_lib_xml2_htmlReadMemory=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_xml2_htmlReadMemory" >&5
12908 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
12909 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
12910 HAVE_LIBXML2=yes
12911 else
12912 HAVE_LIBXML2=no
12913 fi
12914
12915 if test "${HAVE_LIBXML2}" = "yes"; then
12916
12917 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
12918
12919 else
12920 LIBXML2_LIBS=""
12921 LIBXML2_CFLAGS=""
12922 fi
12923 fi
12924 fi
12925
12926
12927
12928 # If netdb.h doesn't declare h_errno, we must declare it by hand.
12929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
12930 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
12931 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
12932 $as_echo_n "(cached) " >&6
12933 else
12934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12935 /* end confdefs.h. */
12936 #include <netdb.h>
12937 int
12938 main ()
12939 {
12940 return h_errno;
12941 ;
12942 return 0;
12943 }
12944 _ACEOF
12945 if ac_fn_c_try_link "$LINENO"; then :
12946 emacs_cv_netdb_declares_h_errno=yes
12947 else
12948 emacs_cv_netdb_declares_h_errno=no
12949 fi
12950 rm -f core conftest.err conftest.$ac_objext \
12951 conftest$ac_exeext conftest.$ac_ext
12952 fi
12953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
12954 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
12955 if test $emacs_cv_netdb_declares_h_errno = yes; then
12956
12957 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
12958
12959 fi
12960
12961 # fmod, logb, and frexp are found in -lm on most systems.
12962 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
12964 $as_echo_n "checking for sqrt in -lm... " >&6; }
12965 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
12966 $as_echo_n "(cached) " >&6
12967 else
12968 ac_check_lib_save_LIBS=$LIBS
12969 LIBS="-lm $LIBS"
12970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12971 /* end confdefs.h. */
12972
12973 /* Override any GCC internal prototype to avoid an error.
12974 Use char because int might match the return type of a GCC
12975 builtin and then its argument prototype would still apply. */
12976 #ifdef __cplusplus
12977 extern "C"
12978 #endif
12979 char sqrt ();
12980 int
12981 main ()
12982 {
12983 return sqrt ();
12984 ;
12985 return 0;
12986 }
12987 _ACEOF
12988 if ac_fn_c_try_link "$LINENO"; then :
12989 ac_cv_lib_m_sqrt=yes
12990 else
12991 ac_cv_lib_m_sqrt=no
12992 fi
12993 rm -f core conftest.err conftest.$ac_objext \
12994 conftest$ac_exeext conftest.$ac_ext
12995 LIBS=$ac_check_lib_save_LIBS
12996 fi
12997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
12998 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
12999 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13000 cat >>confdefs.h <<_ACEOF
13001 #define HAVE_LIBM 1
13002 _ACEOF
13003
13004 LIBS="-lm $LIBS"
13005
13006 fi
13007
13008
13009 # Check for mail-locking functions in a "mail" library. Probably this should
13010 # have the same check as for liblockfile below.
13011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13012 $as_echo_n "checking for maillock in -lmail... " >&6; }
13013 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13014 $as_echo_n "(cached) " >&6
13015 else
13016 ac_check_lib_save_LIBS=$LIBS
13017 LIBS="-lmail $LIBS"
13018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13019 /* end confdefs.h. */
13020
13021 /* Override any GCC internal prototype to avoid an error.
13022 Use char because int might match the return type of a GCC
13023 builtin and then its argument prototype would still apply. */
13024 #ifdef __cplusplus
13025 extern "C"
13026 #endif
13027 char maillock ();
13028 int
13029 main ()
13030 {
13031 return maillock ();
13032 ;
13033 return 0;
13034 }
13035 _ACEOF
13036 if ac_fn_c_try_link "$LINENO"; then :
13037 ac_cv_lib_mail_maillock=yes
13038 else
13039 ac_cv_lib_mail_maillock=no
13040 fi
13041 rm -f core conftest.err conftest.$ac_objext \
13042 conftest$ac_exeext conftest.$ac_ext
13043 LIBS=$ac_check_lib_save_LIBS
13044 fi
13045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13046 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13047 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13048 have_mail=yes
13049 else
13050 have_mail=no
13051 fi
13052
13053 if test $have_mail = yes; then
13054 LIBS_MAIL=-lmail
13055 LIBS="$LIBS_MAIL $LIBS"
13056
13057 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13058
13059 else
13060 LIBS_MAIL=
13061 fi
13062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13063 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13064 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13065 $as_echo_n "(cached) " >&6
13066 else
13067 ac_check_lib_save_LIBS=$LIBS
13068 LIBS="-llockfile $LIBS"
13069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13070 /* end confdefs.h. */
13071
13072 /* Override any GCC internal prototype to avoid an error.
13073 Use char because int might match the return type of a GCC
13074 builtin and then its argument prototype would still apply. */
13075 #ifdef __cplusplus
13076 extern "C"
13077 #endif
13078 char maillock ();
13079 int
13080 main ()
13081 {
13082 return maillock ();
13083 ;
13084 return 0;
13085 }
13086 _ACEOF
13087 if ac_fn_c_try_link "$LINENO"; then :
13088 ac_cv_lib_lockfile_maillock=yes
13089 else
13090 ac_cv_lib_lockfile_maillock=no
13091 fi
13092 rm -f core conftest.err conftest.$ac_objext \
13093 conftest$ac_exeext conftest.$ac_ext
13094 LIBS=$ac_check_lib_save_LIBS
13095 fi
13096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13097 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13098 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13099 have_lockfile=yes
13100 else
13101 have_lockfile=no
13102 fi
13103
13104 if test $have_lockfile = yes; then
13105 LIBS_MAIL=-llockfile
13106 LIBS="$LIBS_MAIL $LIBS"
13107
13108 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13109
13110 else
13111 # If we have the shared liblockfile, assume we must use it for mail
13112 # locking (e.g. Debian). If we couldn't link against liblockfile
13113 # (no liblockfile.a installed), ensure that we don't need to.
13114 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13115 set dummy liblockfile.so; ac_word=$2
13116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13117 $as_echo_n "checking for $ac_word... " >&6; }
13118 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13119 $as_echo_n "(cached) " >&6
13120 else
13121 if test -n "$liblockfile"; then
13122 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13123 else
13124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13125 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13126 for as_dir in $as_dummy
13127 do
13128 IFS=$as_save_IFS
13129 test -z "$as_dir" && as_dir=.
13130 for ac_exec_ext in '' $ac_executable_extensions; do
13131 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13132 ac_cv_prog_liblockfile="yes"
13133 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13134 break 2
13135 fi
13136 done
13137 done
13138 IFS=$as_save_IFS
13139
13140 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13141 fi
13142 fi
13143 liblockfile=$ac_cv_prog_liblockfile
13144 if test -n "$liblockfile"; then
13145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13146 $as_echo "$liblockfile" >&6; }
13147 else
13148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13149 $as_echo "no" >&6; }
13150 fi
13151
13152
13153 if test $ac_cv_prog_liblockfile = yes; then
13154 as_fn_error "Shared liblockfile found but can't link against it.
13155 This probably means that movemail could lose mail.
13156 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13157 fi
13158 fi
13159
13160
13161
13162
13163
13164 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13165 ## interlock access to the mail spool. The alternative is a lock file named
13166 ## /usr/spool/mail/$USER.lock.
13167 mail_lock=no
13168 case "$opsys" in
13169 aix4-2) mail_lock="lockf" ;;
13170
13171 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13172
13173 ## On GNU/Linux systems, both methods are used by various mail programs.
13174 ## I assume most people are using newer mailers that have heard of flock.
13175 ## Change this if you need to.
13176 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13177 ## configure gets the right answers, and that means *NOT* using flock.
13178 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13179 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13180 ## Debian maintainer hasn't provided a clean fix for Emacs.
13181 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13182 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13183 ## correct logic. -- fx
13184 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13185 ## liblockfile is a Free Software replacement for libmail, used on
13186 ## Debian systems and elsewhere. -rfr.
13187 gnu-*)
13188 mail_lock="flock"
13189 if test $have_mail = yes || test $have_lockfile = yes; then
13190 test $ac_cv_header_maillock_h = yes && mail_lock=no
13191 fi
13192 ;;
13193 esac
13194
13195 BLESSMAIL_TARGET=
13196 case "$mail_lock" in
13197 flock)
13198 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13199 ;;
13200
13201 lockf)
13202 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13203 ;;
13204
13205 *) BLESSMAIL_TARGET="need-blessmail" ;;
13206 esac
13207
13208
13209
13210 for ac_func in gethostname \
13211 closedir getrusage get_current_dir_name \
13212 lrand48 logb frexp fmod cbrt setsid \
13213 fpathconf select euidaccess getpagesize setlocale \
13214 utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
13215 __fpending strsignal setitimer \
13216 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13217 gai_strerror mkstemp getline getdelim fsync sync \
13218 difftime posix_memalign \
13219 getpwent endpwent getgrent endgrent \
13220 touchlock \
13221 cfmakeraw cfsetspeed copysign __executable_start
13222 do :
13223 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13224 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13225 eval as_val=\$$as_ac_var
13226 if test "x$as_val" = x""yes; then :
13227 cat >>confdefs.h <<_ACEOF
13228 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13229 _ACEOF
13230
13231 fi
13232 done
13233
13234
13235 if test $opsys = unixware; then
13236
13237 $as_echo "#define BROKEN_GETWD 1" >>confdefs.h
13238
13239 else
13240 for ac_func in getwd
13241 do :
13242 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13243 if test "x$ac_cv_func_getwd" = x""yes; then :
13244 cat >>confdefs.h <<_ACEOF
13245 #define HAVE_GETWD 1
13246 _ACEOF
13247
13248 fi
13249 done
13250
13251 fi
13252
13253 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13254 ## has a broken `rint' in some library versions including math library
13255 ## version number A.09.05.
13256 ## You can fix the math library by installing patch number PHSS_4630.
13257 ## But we can fix it more reliably for Emacs by just not using rint.
13258 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13259 case $opsys in
13260 hpux*) : ;;
13261 *) for ac_func in random rint
13262 do :
13263 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13264 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13265 eval as_val=\$$as_ac_var
13266 if test "x$as_val" = x""yes; then :
13267 cat >>confdefs.h <<_ACEOF
13268 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13269 _ACEOF
13270
13271 fi
13272 done
13273 ;;
13274 esac
13275
13276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13277 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13278 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13279 $as_echo_n "(cached) " >&6
13280 else
13281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13282 /* end confdefs.h. */
13283
13284 int
13285 main ()
13286 {
13287 __builtin_unwind_init ();
13288 ;
13289 return 0;
13290 }
13291 _ACEOF
13292 if ac_fn_c_try_link "$LINENO"; then :
13293 emacs_cv_func___builtin_unwind_init=yes
13294 else
13295 emacs_cv_func___builtin_unwind_init=no
13296 fi
13297 rm -f core conftest.err conftest.$ac_objext \
13298 conftest$ac_exeext conftest.$ac_ext
13299 fi
13300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13301 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13302 if test $emacs_cv_func___builtin_unwind_init = yes; then
13303
13304 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13305
13306 fi
13307
13308
13309
13310
13311
13312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13313 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13314 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13315 $as_echo_n "(cached) " >&6
13316 else
13317 while :; do
13318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13319 /* end confdefs.h. */
13320 #include <sys/types.h> /* for off_t */
13321 #include <stdio.h>
13322 int
13323 main ()
13324 {
13325 int (*fp) (FILE *, off_t, int) = fseeko;
13326 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13327 ;
13328 return 0;
13329 }
13330 _ACEOF
13331 if ac_fn_c_try_link "$LINENO"; then :
13332 ac_cv_sys_largefile_source=no; break
13333 fi
13334 rm -f core conftest.err conftest.$ac_objext \
13335 conftest$ac_exeext conftest.$ac_ext
13336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13337 /* end confdefs.h. */
13338 #define _LARGEFILE_SOURCE 1
13339 #include <sys/types.h> /* for off_t */
13340 #include <stdio.h>
13341 int
13342 main ()
13343 {
13344 int (*fp) (FILE *, off_t, int) = fseeko;
13345 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13346 ;
13347 return 0;
13348 }
13349 _ACEOF
13350 if ac_fn_c_try_link "$LINENO"; then :
13351 ac_cv_sys_largefile_source=1; break
13352 fi
13353 rm -f core conftest.err conftest.$ac_objext \
13354 conftest$ac_exeext conftest.$ac_ext
13355 ac_cv_sys_largefile_source=unknown
13356 break
13357 done
13358 fi
13359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13360 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13361 case $ac_cv_sys_largefile_source in #(
13362 no | unknown) ;;
13363 *)
13364 cat >>confdefs.h <<_ACEOF
13365 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13366 _ACEOF
13367 ;;
13368 esac
13369 rm -rf conftest*
13370
13371 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13372 # in glibc 2.1.3, but that breaks too many other things.
13373 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13374 if test $ac_cv_sys_largefile_source != unknown; then
13375
13376 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13377
13378 fi
13379
13380
13381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13382 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13383 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13384 $as_echo_n "(cached) " >&6
13385 else
13386 # Use it with a single arg.
13387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13388 /* end confdefs.h. */
13389 $ac_includes_default
13390 int
13391 main ()
13392 {
13393 getpgrp (0);
13394 ;
13395 return 0;
13396 }
13397 _ACEOF
13398 if ac_fn_c_try_compile "$LINENO"; then :
13399 ac_cv_func_getpgrp_void=no
13400 else
13401 ac_cv_func_getpgrp_void=yes
13402 fi
13403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13404
13405 fi
13406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13407 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13408 if test $ac_cv_func_getpgrp_void = yes; then
13409
13410 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13411
13412 fi
13413
13414
13415 # UNIX98 PTYs.
13416 for ac_func in grantpt
13417 do :
13418 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13419 if test "x$ac_cv_func_grantpt" = x""yes; then :
13420 cat >>confdefs.h <<_ACEOF
13421 #define HAVE_GRANTPT 1
13422 _ACEOF
13423
13424 fi
13425 done
13426
13427
13428 # PTY-related GNU extensions.
13429 for ac_func in getpt posix_openpt
13430 do :
13431 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13432 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13433 eval as_val=\$$as_ac_var
13434 if test "x$as_val" = x""yes; then :
13435 cat >>confdefs.h <<_ACEOF
13436 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13437 _ACEOF
13438
13439 fi
13440 done
13441
13442
13443 # Check this now, so that we will NOT find the above functions in ncurses.
13444 # That is because we have not set up to link ncurses in lib-src.
13445 # It's better to believe a function is not available
13446 # than to expect to find it in ncurses.
13447 # Also we need tputs and friends to be able to build at all.
13448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13449 $as_echo_n "checking for library containing tputs... " >&6; }
13450 # Run a test program that contains a call to tputs, a call that is
13451 # never executed. This tests whether a pre-'main' dynamic linker
13452 # works with the library. It's too much trouble to actually call
13453 # tputs in the test program, due to portability hassles. When
13454 # cross-compiling, assume the test program will run if it links.
13455
13456 # Maybe curses should be tried earlier?
13457 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13458 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13459 OLIBS=$LIBS
13460 if test -z "$tputs_library"; then
13461 LIBS_TERMCAP=
13462 msg='none required'
13463 else
13464 LIBS_TERMCAP=-l$tputs_library
13465 msg=$LIBS_TERMCAP
13466 LIBS="$LIBS_TERMCAP $LIBS"
13467 fi
13468 if test "$cross_compiling" = yes; then :
13469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13470 /* end confdefs.h. */
13471
13472 extern void tputs (const char *, int, int (*)(int));
13473 int main (int argc, char **argv)
13474 {
13475 if (argc == 10000)
13476 tputs (argv[0], 0, 0);
13477 return 0;
13478 }
13479
13480 _ACEOF
13481 if ac_fn_c_try_link "$LINENO"; then :
13482
13483 else
13484 msg=no
13485 fi
13486 rm -f core conftest.err conftest.$ac_objext \
13487 conftest$ac_exeext conftest.$ac_ext
13488 else
13489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13490 /* end confdefs.h. */
13491
13492 extern void tputs (const char *, int, int (*)(int));
13493 int main (int argc, char **argv)
13494 {
13495 if (argc == 10000)
13496 tputs (argv[0], 0, 0);
13497 return 0;
13498 }
13499
13500 _ACEOF
13501 if ac_fn_c_try_run "$LINENO"; then :
13502
13503 else
13504 msg=no
13505 fi
13506 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13507 conftest.$ac_objext conftest.beam conftest.$ac_ext
13508 fi
13509
13510 LIBS=$OLIBS
13511 if test "X$msg" != Xno; then
13512 break
13513 fi
13514 done
13515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13516 $as_echo "$msg" >&6; }
13517 if test "X$msg" = Xno; then
13518 as_fn_error "The required function \`tputs' was not found in any library.
13519 The following libraries were tried (in order):
13520 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13521 Please try installing whichever of these libraries is most appropriate
13522 for your system, together with its header files.
13523 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13524 fi
13525
13526 ## Use termcap instead of terminfo?
13527 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13528 TERMINFO=yes
13529 ## FIXME? In the cases below where we unconditionally set
13530 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13531 ## if that was found above to have tputs.
13532 ## Should we use the gnu* logic everywhere?
13533 case "$opsys" in
13534 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13535 ## The ncurses library has been moved out of the System framework in
13536 ## Mac OS X 10.2. So if configure detects it, set the command-line
13537 ## option to use it.
13538 darwin) LIBS_TERMCAP="-lncurses" ;;
13539
13540 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13541
13542 freebsd)
13543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13544 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13545 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13546 $as_echo_n "(cached) " >&6
13547 else
13548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13549 /* end confdefs.h. */
13550 #include <osreldate.h>
13551 int
13552 main ()
13553 {
13554 #if __FreeBSD_version < 400000
13555 fail;
13556 #endif
13557
13558 ;
13559 return 0;
13560 }
13561 _ACEOF
13562 if ac_fn_c_try_link "$LINENO"; then :
13563 emacs_cv_freebsd_terminfo=yes
13564 else
13565 emacs_cv_freebsd_terminfo=no
13566 fi
13567 rm -f core conftest.err conftest.$ac_objext \
13568 conftest$ac_exeext conftest.$ac_ext
13569 fi
13570
13571
13572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13573 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13574
13575 if test $emacs_cv_freebsd_terminfo = yes; then
13576 LIBS_TERMCAP="-lncurses"
13577 else
13578 TERMINFO=no
13579 LIBS_TERMCAP="-ltermcap"
13580 fi
13581 ;;
13582
13583 netbsd)
13584 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13585 TERMINFO=no
13586 LIBS_TERMCAP="-ltermcap"
13587 fi
13588 ;;
13589
13590 openbsd) LIBS_TERMCAP="-lncurses" ;;
13591
13592 ## hpux: Make sure we get select from libc rather than from libcurses
13593 ## because libcurses on HPUX 10.10 has a broken version of select.
13594 ## We used to use -lc -lcurses, but this may be cleaner.
13595 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13596 # set that way, now it uses the default). Isn't this a contradiction?
13597 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13598
13599 esac
13600
13601 TERMCAP_OBJ=tparam.o
13602 if test $TERMINFO = yes; then
13603
13604 $as_echo "#define TERMINFO 1" >>confdefs.h
13605
13606 TERMCAP_OBJ=terminfo.o
13607 fi
13608
13609
13610
13611
13612 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13613 # On Darwin, res_init appears not to be useful: see bug#562 and
13614 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13615 resolv=no
13616
13617 if test $opsys != darwin; then
13618
13619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13620 /* end confdefs.h. */
13621 #include <netinet/in.h>
13622 #include <arpa/nameser.h>
13623 #include <resolv.h>
13624 int
13625 main ()
13626 {
13627 return res_init();
13628 ;
13629 return 0;
13630 }
13631 _ACEOF
13632 if ac_fn_c_try_link "$LINENO"; then :
13633 have_res_init=yes
13634 else
13635 have_res_init=no
13636 fi
13637 rm -f core conftest.err conftest.$ac_objext \
13638 conftest$ac_exeext conftest.$ac_ext
13639 if test "$have_res_init" = no; then
13640 OLIBS="$LIBS"
13641 LIBS="$LIBS -lresolv"
13642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13643 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13645 /* end confdefs.h. */
13646 #include <netinet/in.h>
13647 #include <arpa/nameser.h>
13648 #include <resolv.h>
13649 int
13650 main ()
13651 {
13652 return res_init();
13653 ;
13654 return 0;
13655 }
13656 _ACEOF
13657 if ac_fn_c_try_link "$LINENO"; then :
13658 have_res_init=yes
13659 else
13660 have_res_init=no
13661 fi
13662 rm -f core conftest.err conftest.$ac_objext \
13663 conftest$ac_exeext conftest.$ac_ext
13664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13665 $as_echo "$have_res_init" >&6; }
13666 if test "$have_res_init" = yes ; then
13667 resolv=yes
13668 fi
13669 LIBS="$OLIBS"
13670 fi
13671
13672 if test "$have_res_init" = yes; then
13673
13674 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13675
13676 fi
13677 fi
13678 # Do we need the Hesiod library to provide the support routines?
13679 LIBHESIOD=
13680 if test "$with_hesiod" != no ; then
13681 # Don't set $LIBS here -- see comments above. FIXME which comments?
13682 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13683 if test "x$ac_cv_func_res_send" = x""yes; then :
13684
13685 else
13686 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13687 if test "x$ac_cv_func___res_send" = x""yes; then :
13688
13689 else
13690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13691 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13692 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13693 $as_echo_n "(cached) " >&6
13694 else
13695 ac_check_lib_save_LIBS=$LIBS
13696 LIBS="-lresolv $LIBS"
13697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13698 /* end confdefs.h. */
13699
13700 /* Override any GCC internal prototype to avoid an error.
13701 Use char because int might match the return type of a GCC
13702 builtin and then its argument prototype would still apply. */
13703 #ifdef __cplusplus
13704 extern "C"
13705 #endif
13706 char res_send ();
13707 int
13708 main ()
13709 {
13710 return res_send ();
13711 ;
13712 return 0;
13713 }
13714 _ACEOF
13715 if ac_fn_c_try_link "$LINENO"; then :
13716 ac_cv_lib_resolv_res_send=yes
13717 else
13718 ac_cv_lib_resolv_res_send=no
13719 fi
13720 rm -f core conftest.err conftest.$ac_objext \
13721 conftest$ac_exeext conftest.$ac_ext
13722 LIBS=$ac_check_lib_save_LIBS
13723 fi
13724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13725 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13726 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13727 resolv=yes
13728 else
13729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13730 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13731 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13732 $as_echo_n "(cached) " >&6
13733 else
13734 ac_check_lib_save_LIBS=$LIBS
13735 LIBS="-lresolv $LIBS"
13736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13737 /* end confdefs.h. */
13738
13739 /* Override any GCC internal prototype to avoid an error.
13740 Use char because int might match the return type of a GCC
13741 builtin and then its argument prototype would still apply. */
13742 #ifdef __cplusplus
13743 extern "C"
13744 #endif
13745 char __res_send ();
13746 int
13747 main ()
13748 {
13749 return __res_send ();
13750 ;
13751 return 0;
13752 }
13753 _ACEOF
13754 if ac_fn_c_try_link "$LINENO"; then :
13755 ac_cv_lib_resolv___res_send=yes
13756 else
13757 ac_cv_lib_resolv___res_send=no
13758 fi
13759 rm -f core conftest.err conftest.$ac_objext \
13760 conftest$ac_exeext conftest.$ac_ext
13761 LIBS=$ac_check_lib_save_LIBS
13762 fi
13763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13764 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13765 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13766 resolv=yes
13767 fi
13768
13769 fi
13770
13771 fi
13772
13773 fi
13774
13775 if test "$resolv" = yes ; then
13776 RESOLVLIB=-lresolv
13777 else
13778 RESOLVLIB=
13779 fi
13780 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13781 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13782
13783 else
13784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13785 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13786 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13787 $as_echo_n "(cached) " >&6
13788 else
13789 ac_check_lib_save_LIBS=$LIBS
13790 LIBS="-lhesiod $RESOLVLIB $LIBS"
13791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13792 /* end confdefs.h. */
13793
13794 /* Override any GCC internal prototype to avoid an error.
13795 Use char because int might match the return type of a GCC
13796 builtin and then its argument prototype would still apply. */
13797 #ifdef __cplusplus
13798 extern "C"
13799 #endif
13800 char hes_getmailhost ();
13801 int
13802 main ()
13803 {
13804 return hes_getmailhost ();
13805 ;
13806 return 0;
13807 }
13808 _ACEOF
13809 if ac_fn_c_try_link "$LINENO"; then :
13810 ac_cv_lib_hesiod_hes_getmailhost=yes
13811 else
13812 ac_cv_lib_hesiod_hes_getmailhost=no
13813 fi
13814 rm -f core conftest.err conftest.$ac_objext \
13815 conftest$ac_exeext conftest.$ac_ext
13816 LIBS=$ac_check_lib_save_LIBS
13817 fi
13818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
13819 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
13820 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
13821 hesiod=yes
13822 else
13823 :
13824 fi
13825
13826 fi
13827
13828
13829 if test x"$hesiod" = xyes; then
13830
13831 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
13832
13833 LIBHESIOD=-lhesiod
13834 fi
13835 fi
13836
13837
13838 # Do we need libresolv (due to res_init or Hesiod)?
13839 if test "$resolv" = yes && test $opsys != darwin; then
13840
13841 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
13842
13843 LIBRESOLV=-lresolv
13844 else
13845 LIBRESOLV=
13846 fi
13847
13848
13849 # These tell us which Kerberos-related libraries to use.
13850 COM_ERRLIB=
13851 CRYPTOLIB=
13852 KRB5LIB=
13853 DESLIB=
13854 KRB4LIB=
13855
13856 if test "${with_kerberos}" != no; then
13857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
13858 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
13859 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
13860 $as_echo_n "(cached) " >&6
13861 else
13862 ac_check_lib_save_LIBS=$LIBS
13863 LIBS="-lcom_err $LIBS"
13864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13865 /* end confdefs.h. */
13866
13867 /* Override any GCC internal prototype to avoid an error.
13868 Use char because int might match the return type of a GCC
13869 builtin and then its argument prototype would still apply. */
13870 #ifdef __cplusplus
13871 extern "C"
13872 #endif
13873 char com_err ();
13874 int
13875 main ()
13876 {
13877 return com_err ();
13878 ;
13879 return 0;
13880 }
13881 _ACEOF
13882 if ac_fn_c_try_link "$LINENO"; then :
13883 ac_cv_lib_com_err_com_err=yes
13884 else
13885 ac_cv_lib_com_err_com_err=no
13886 fi
13887 rm -f core conftest.err conftest.$ac_objext \
13888 conftest$ac_exeext conftest.$ac_ext
13889 LIBS=$ac_check_lib_save_LIBS
13890 fi
13891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
13892 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
13893 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
13894 have_com_err=yes
13895 else
13896 have_com_err=no
13897 fi
13898
13899 if test $have_com_err = yes; then
13900 COM_ERRLIB=-lcom_err
13901 LIBS="$COM_ERRLIB $LIBS"
13902
13903 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
13904
13905 fi
13906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
13907 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
13908 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
13909 $as_echo_n "(cached) " >&6
13910 else
13911 ac_check_lib_save_LIBS=$LIBS
13912 LIBS="-lcrypto $LIBS"
13913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13914 /* end confdefs.h. */
13915
13916 /* Override any GCC internal prototype to avoid an error.
13917 Use char because int might match the return type of a GCC
13918 builtin and then its argument prototype would still apply. */
13919 #ifdef __cplusplus
13920 extern "C"
13921 #endif
13922 char mit_des_cbc_encrypt ();
13923 int
13924 main ()
13925 {
13926 return mit_des_cbc_encrypt ();
13927 ;
13928 return 0;
13929 }
13930 _ACEOF
13931 if ac_fn_c_try_link "$LINENO"; then :
13932 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
13933 else
13934 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
13935 fi
13936 rm -f core conftest.err conftest.$ac_objext \
13937 conftest$ac_exeext conftest.$ac_ext
13938 LIBS=$ac_check_lib_save_LIBS
13939 fi
13940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
13941 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
13942 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
13943 have_crypto=yes
13944 else
13945 have_crypto=no
13946 fi
13947
13948 if test $have_crypto = yes; then
13949 CRYPTOLIB=-lcrypto
13950 LIBS="$CRYPTOLIB $LIBS"
13951
13952 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
13953
13954 fi
13955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
13956 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
13957 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
13958 $as_echo_n "(cached) " >&6
13959 else
13960 ac_check_lib_save_LIBS=$LIBS
13961 LIBS="-lk5crypto $LIBS"
13962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13963 /* end confdefs.h. */
13964
13965 /* Override any GCC internal prototype to avoid an error.
13966 Use char because int might match the return type of a GCC
13967 builtin and then its argument prototype would still apply. */
13968 #ifdef __cplusplus
13969 extern "C"
13970 #endif
13971 char mit_des_cbc_encrypt ();
13972 int
13973 main ()
13974 {
13975 return mit_des_cbc_encrypt ();
13976 ;
13977 return 0;
13978 }
13979 _ACEOF
13980 if ac_fn_c_try_link "$LINENO"; then :
13981 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
13982 else
13983 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
13984 fi
13985 rm -f core conftest.err conftest.$ac_objext \
13986 conftest$ac_exeext conftest.$ac_ext
13987 LIBS=$ac_check_lib_save_LIBS
13988 fi
13989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
13990 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
13991 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
13992 have_k5crypto=yes
13993 else
13994 have_k5crypto=no
13995 fi
13996
13997 if test $have_k5crypto = yes; then
13998 CRYPTOLIB=-lk5crypto
13999 LIBS="$CRYPTOLIB $LIBS"
14000
14001 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14002
14003 fi
14004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14005 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14006 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14007 $as_echo_n "(cached) " >&6
14008 else
14009 ac_check_lib_save_LIBS=$LIBS
14010 LIBS="-lkrb5 $LIBS"
14011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14012 /* end confdefs.h. */
14013
14014 /* Override any GCC internal prototype to avoid an error.
14015 Use char because int might match the return type of a GCC
14016 builtin and then its argument prototype would still apply. */
14017 #ifdef __cplusplus
14018 extern "C"
14019 #endif
14020 char krb5_init_context ();
14021 int
14022 main ()
14023 {
14024 return krb5_init_context ();
14025 ;
14026 return 0;
14027 }
14028 _ACEOF
14029 if ac_fn_c_try_link "$LINENO"; then :
14030 ac_cv_lib_krb5_krb5_init_context=yes
14031 else
14032 ac_cv_lib_krb5_krb5_init_context=no
14033 fi
14034 rm -f core conftest.err conftest.$ac_objext \
14035 conftest$ac_exeext conftest.$ac_ext
14036 LIBS=$ac_check_lib_save_LIBS
14037 fi
14038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14039 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14040 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14041 have_krb5=yes
14042 else
14043 have_krb5=no
14044 fi
14045
14046 if test $have_krb5=yes; then
14047 KRB5LIB=-lkrb5
14048 LIBS="$KRB5LIB $LIBS"
14049
14050 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14051
14052 fi
14053 if test "${with_kerberos5}" = no; then
14054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14055 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14056 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14057 $as_echo_n "(cached) " >&6
14058 else
14059 ac_check_lib_save_LIBS=$LIBS
14060 LIBS="-ldes425 $LIBS"
14061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14062 /* end confdefs.h. */
14063
14064 /* Override any GCC internal prototype to avoid an error.
14065 Use char because int might match the return type of a GCC
14066 builtin and then its argument prototype would still apply. */
14067 #ifdef __cplusplus
14068 extern "C"
14069 #endif
14070 char des_cbc_encrypt ();
14071 int
14072 main ()
14073 {
14074 return des_cbc_encrypt ();
14075 ;
14076 return 0;
14077 }
14078 _ACEOF
14079 if ac_fn_c_try_link "$LINENO"; then :
14080 ac_cv_lib_des425_des_cbc_encrypt=yes
14081 else
14082 ac_cv_lib_des425_des_cbc_encrypt=no
14083 fi
14084 rm -f core conftest.err conftest.$ac_objext \
14085 conftest$ac_exeext conftest.$ac_ext
14086 LIBS=$ac_check_lib_save_LIBS
14087 fi
14088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14089 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14090 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14091 have_des425=yes
14092 else
14093 have_des425=no
14094 fi
14095
14096 if test $have_des425 = yes; then
14097 DESLIB=-ldes425
14098 LIBS="$DESLIB $LIBS"
14099
14100 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14101
14102 else
14103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14104 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14105 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14106 $as_echo_n "(cached) " >&6
14107 else
14108 ac_check_lib_save_LIBS=$LIBS
14109 LIBS="-ldes $LIBS"
14110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14111 /* end confdefs.h. */
14112
14113 /* Override any GCC internal prototype to avoid an error.
14114 Use char because int might match the return type of a GCC
14115 builtin and then its argument prototype would still apply. */
14116 #ifdef __cplusplus
14117 extern "C"
14118 #endif
14119 char des_cbc_encrypt ();
14120 int
14121 main ()
14122 {
14123 return des_cbc_encrypt ();
14124 ;
14125 return 0;
14126 }
14127 _ACEOF
14128 if ac_fn_c_try_link "$LINENO"; then :
14129 ac_cv_lib_des_des_cbc_encrypt=yes
14130 else
14131 ac_cv_lib_des_des_cbc_encrypt=no
14132 fi
14133 rm -f core conftest.err conftest.$ac_objext \
14134 conftest$ac_exeext conftest.$ac_ext
14135 LIBS=$ac_check_lib_save_LIBS
14136 fi
14137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14138 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14139 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14140 have_des=yes
14141 else
14142 have_des=no
14143 fi
14144
14145 if test $have_des = yes; then
14146 DESLIB=-ldes
14147 LIBS="$DESLIB $LIBS"
14148
14149 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14150
14151 fi
14152 fi
14153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14154 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14155 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14156 $as_echo_n "(cached) " >&6
14157 else
14158 ac_check_lib_save_LIBS=$LIBS
14159 LIBS="-lkrb4 $LIBS"
14160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14161 /* end confdefs.h. */
14162
14163 /* Override any GCC internal prototype to avoid an error.
14164 Use char because int might match the return type of a GCC
14165 builtin and then its argument prototype would still apply. */
14166 #ifdef __cplusplus
14167 extern "C"
14168 #endif
14169 char krb_get_cred ();
14170 int
14171 main ()
14172 {
14173 return krb_get_cred ();
14174 ;
14175 return 0;
14176 }
14177 _ACEOF
14178 if ac_fn_c_try_link "$LINENO"; then :
14179 ac_cv_lib_krb4_krb_get_cred=yes
14180 else
14181 ac_cv_lib_krb4_krb_get_cred=no
14182 fi
14183 rm -f core conftest.err conftest.$ac_objext \
14184 conftest$ac_exeext conftest.$ac_ext
14185 LIBS=$ac_check_lib_save_LIBS
14186 fi
14187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14188 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14189 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14190 have_krb4=yes
14191 else
14192 have_krb4=no
14193 fi
14194
14195 if test $have_krb4 = yes; then
14196 KRB4LIB=-lkrb4
14197 LIBS="$KRB4LIB $LIBS"
14198
14199 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14200
14201 else
14202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14203 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14204 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14205 $as_echo_n "(cached) " >&6
14206 else
14207 ac_check_lib_save_LIBS=$LIBS
14208 LIBS="-lkrb $LIBS"
14209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14210 /* end confdefs.h. */
14211
14212 /* Override any GCC internal prototype to avoid an error.
14213 Use char because int might match the return type of a GCC
14214 builtin and then its argument prototype would still apply. */
14215 #ifdef __cplusplus
14216 extern "C"
14217 #endif
14218 char krb_get_cred ();
14219 int
14220 main ()
14221 {
14222 return krb_get_cred ();
14223 ;
14224 return 0;
14225 }
14226 _ACEOF
14227 if ac_fn_c_try_link "$LINENO"; then :
14228 ac_cv_lib_krb_krb_get_cred=yes
14229 else
14230 ac_cv_lib_krb_krb_get_cred=no
14231 fi
14232 rm -f core conftest.err conftest.$ac_objext \
14233 conftest$ac_exeext conftest.$ac_ext
14234 LIBS=$ac_check_lib_save_LIBS
14235 fi
14236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14237 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14238 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14239 have_krb=yes
14240 else
14241 have_krb=no
14242 fi
14243
14244 if test $have_krb = yes; then
14245 KRB4LIB=-lkrb
14246 LIBS="$KRB4LIB $LIBS"
14247
14248 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14249
14250 fi
14251 fi
14252 fi
14253
14254 if test "${with_kerberos5}" != no; then
14255 for ac_header in krb5.h
14256 do :
14257 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14258 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14259 cat >>confdefs.h <<_ACEOF
14260 #define HAVE_KRB5_H 1
14261 _ACEOF
14262 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14263 "
14264 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14265
14266 cat >>confdefs.h <<_ACEOF
14267 #define HAVE_KRB5_ERROR_TEXT 1
14268 _ACEOF
14269
14270
14271 fi
14272 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14273 "
14274 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14275
14276 cat >>confdefs.h <<_ACEOF
14277 #define HAVE_KRB5_ERROR_E_TEXT 1
14278 _ACEOF
14279
14280
14281 fi
14282
14283 fi
14284
14285 done
14286
14287 else
14288 for ac_header in des.h
14289 do :
14290 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14291 if test "x$ac_cv_header_des_h" = x""yes; then :
14292 cat >>confdefs.h <<_ACEOF
14293 #define HAVE_DES_H 1
14294 _ACEOF
14295
14296 else
14297 for ac_header in kerberosIV/des.h
14298 do :
14299 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14300 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14301 cat >>confdefs.h <<_ACEOF
14302 #define HAVE_KERBEROSIV_DES_H 1
14303 _ACEOF
14304
14305 else
14306 for ac_header in kerberos/des.h
14307 do :
14308 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14309 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14310 cat >>confdefs.h <<_ACEOF
14311 #define HAVE_KERBEROS_DES_H 1
14312 _ACEOF
14313
14314 fi
14315
14316 done
14317
14318 fi
14319
14320 done
14321
14322 fi
14323
14324 done
14325
14326 for ac_header in krb.h
14327 do :
14328 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14329 if test "x$ac_cv_header_krb_h" = x""yes; then :
14330 cat >>confdefs.h <<_ACEOF
14331 #define HAVE_KRB_H 1
14332 _ACEOF
14333
14334 else
14335 for ac_header in kerberosIV/krb.h
14336 do :
14337 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14338 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14339 cat >>confdefs.h <<_ACEOF
14340 #define HAVE_KERBEROSIV_KRB_H 1
14341 _ACEOF
14342
14343 else
14344 for ac_header in kerberos/krb.h
14345 do :
14346 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14347 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14348 cat >>confdefs.h <<_ACEOF
14349 #define HAVE_KERBEROS_KRB_H 1
14350 _ACEOF
14351
14352 fi
14353
14354 done
14355
14356 fi
14357
14358 done
14359
14360 fi
14361
14362 done
14363
14364 fi
14365 for ac_header in com_err.h
14366 do :
14367 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14368 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14369 cat >>confdefs.h <<_ACEOF
14370 #define HAVE_COM_ERR_H 1
14371 _ACEOF
14372
14373 fi
14374
14375 done
14376
14377 fi
14378
14379
14380
14381
14382
14383
14384
14385
14386
14387
14388 for ac_func in $ac_func_list
14389 do :
14390 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14391 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14392 eval as_val=\$$as_ac_var
14393 if test "x$as_val" = x""yes; then :
14394 cat >>confdefs.h <<_ACEOF
14395 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14396 _ACEOF
14397
14398 fi
14399 done
14400
14401
14402
14403
14404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14405 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14406 if test "${emacs_cv_localtime_cache+set}" = set; then :
14407 $as_echo_n "(cached) " >&6
14408 else
14409 if test x$ac_cv_func_tzset = xyes; then
14410 if test "$cross_compiling" = yes; then :
14411 # If we have tzset, assume the worst when cross-compiling.
14412 emacs_cv_localtime_cache=yes
14413 else
14414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14415 /* end confdefs.h. */
14416 #include <time.h>
14417 char TZ_GMT0[] = "TZ=GMT0";
14418 char TZ_PST8[] = "TZ=PST8";
14419 main()
14420 {
14421 time_t now = time ((time_t *) 0);
14422 int hour_GMT0, hour_unset;
14423 if (putenv (TZ_GMT0) != 0)
14424 exit (1);
14425 hour_GMT0 = localtime (&now)->tm_hour;
14426 unsetenv("TZ");
14427 hour_unset = localtime (&now)->tm_hour;
14428 if (putenv (TZ_PST8) != 0)
14429 exit (1);
14430 if (localtime (&now)->tm_hour == hour_GMT0)
14431 exit (1);
14432 unsetenv("TZ");
14433 if (localtime (&now)->tm_hour != hour_unset)
14434 exit (1);
14435 exit (0);
14436 }
14437 _ACEOF
14438 if ac_fn_c_try_run "$LINENO"; then :
14439 emacs_cv_localtime_cache=no
14440 else
14441 emacs_cv_localtime_cache=yes
14442 fi
14443 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14444 conftest.$ac_objext conftest.beam conftest.$ac_ext
14445 fi
14446
14447 else
14448 # If we lack tzset, report that localtime does not cache TZ,
14449 # since we can't invalidate the cache if we don't have tzset.
14450 emacs_cv_localtime_cache=no
14451 fi
14452 fi
14453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14454 $as_echo "$emacs_cv_localtime_cache" >&6; }
14455 if test $emacs_cv_localtime_cache = yes; then
14456
14457 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14458
14459 fi
14460
14461 ok_so_far=yes
14462 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14463 if test "x$ac_cv_func_socket" = x""yes; then :
14464
14465 else
14466 ok_so_far=no
14467 fi
14468
14469 if test $ok_so_far = yes; then
14470 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14471 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14472
14473 else
14474 ok_so_far=no
14475 fi
14476
14477
14478 fi
14479 if test $ok_so_far = yes; then
14480 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14481 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14482
14483 else
14484 ok_so_far=no
14485 fi
14486
14487
14488 fi
14489 if test $ok_so_far = yes; then
14490
14491 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14492
14493 fi
14494
14495 if test -f /usr/lpp/X11/bin/smt.exp; then
14496
14497 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14498
14499 fi
14500
14501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14502 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14503 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14505 $as_echo "yes" >&6; }
14506
14507 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14508
14509 else
14510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14511 $as_echo "no" >&6; }
14512 fi
14513
14514 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14515 if test "x$ac_cv_type_pid_t" = x""yes; then :
14516
14517 else
14518
14519 cat >>confdefs.h <<_ACEOF
14520 #define pid_t int
14521 _ACEOF
14522
14523 fi
14524
14525 for ac_header in vfork.h
14526 do :
14527 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14528 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14529 cat >>confdefs.h <<_ACEOF
14530 #define HAVE_VFORK_H 1
14531 _ACEOF
14532
14533 fi
14534
14535 done
14536
14537 for ac_func in fork vfork
14538 do :
14539 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14540 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14541 eval as_val=\$$as_ac_var
14542 if test "x$as_val" = x""yes; then :
14543 cat >>confdefs.h <<_ACEOF
14544 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14545 _ACEOF
14546
14547 fi
14548 done
14549
14550 if test "x$ac_cv_func_fork" = xyes; then
14551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14552 $as_echo_n "checking for working fork... " >&6; }
14553 if test "${ac_cv_func_fork_works+set}" = set; then :
14554 $as_echo_n "(cached) " >&6
14555 else
14556 if test "$cross_compiling" = yes; then :
14557 ac_cv_func_fork_works=cross
14558 else
14559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14560 /* end confdefs.h. */
14561 $ac_includes_default
14562 int
14563 main ()
14564 {
14565
14566 /* By Ruediger Kuhlmann. */
14567 return fork () < 0;
14568
14569 ;
14570 return 0;
14571 }
14572 _ACEOF
14573 if ac_fn_c_try_run "$LINENO"; then :
14574 ac_cv_func_fork_works=yes
14575 else
14576 ac_cv_func_fork_works=no
14577 fi
14578 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14579 conftest.$ac_objext conftest.beam conftest.$ac_ext
14580 fi
14581
14582 fi
14583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14584 $as_echo "$ac_cv_func_fork_works" >&6; }
14585
14586 else
14587 ac_cv_func_fork_works=$ac_cv_func_fork
14588 fi
14589 if test "x$ac_cv_func_fork_works" = xcross; then
14590 case $host in
14591 *-*-amigaos* | *-*-msdosdjgpp*)
14592 # Override, as these systems have only a dummy fork() stub
14593 ac_cv_func_fork_works=no
14594 ;;
14595 *)
14596 ac_cv_func_fork_works=yes
14597 ;;
14598 esac
14599 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14600 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14601 fi
14602 ac_cv_func_vfork_works=$ac_cv_func_vfork
14603 if test "x$ac_cv_func_vfork" = xyes; then
14604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14605 $as_echo_n "checking for working vfork... " >&6; }
14606 if test "${ac_cv_func_vfork_works+set}" = set; then :
14607 $as_echo_n "(cached) " >&6
14608 else
14609 if test "$cross_compiling" = yes; then :
14610 ac_cv_func_vfork_works=cross
14611 else
14612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14613 /* end confdefs.h. */
14614 /* Thanks to Paul Eggert for this test. */
14615 $ac_includes_default
14616 #include <sys/wait.h>
14617 #ifdef HAVE_VFORK_H
14618 # include <vfork.h>
14619 #endif
14620 /* On some sparc systems, changes by the child to local and incoming
14621 argument registers are propagated back to the parent. The compiler
14622 is told about this with #include <vfork.h>, but some compilers
14623 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14624 static variable whose address is put into a register that is
14625 clobbered by the vfork. */
14626 static void
14627 #ifdef __cplusplus
14628 sparc_address_test (int arg)
14629 # else
14630 sparc_address_test (arg) int arg;
14631 #endif
14632 {
14633 static pid_t child;
14634 if (!child) {
14635 child = vfork ();
14636 if (child < 0) {
14637 perror ("vfork");
14638 _exit(2);
14639 }
14640 if (!child) {
14641 arg = getpid();
14642 write(-1, "", 0);
14643 _exit (arg);
14644 }
14645 }
14646 }
14647
14648 int
14649 main ()
14650 {
14651 pid_t parent = getpid ();
14652 pid_t child;
14653
14654 sparc_address_test (0);
14655
14656 child = vfork ();
14657
14658 if (child == 0) {
14659 /* Here is another test for sparc vfork register problems. This
14660 test uses lots of local variables, at least as many local
14661 variables as main has allocated so far including compiler
14662 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14663 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14664 reuse the register of parent for one of the local variables,
14665 since it will think that parent can't possibly be used any more
14666 in this routine. Assigning to the local variable will thus
14667 munge parent in the parent process. */
14668 pid_t
14669 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14670 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14671 /* Convince the compiler that p..p7 are live; otherwise, it might
14672 use the same hardware register for all 8 local variables. */
14673 if (p != p1 || p != p2 || p != p3 || p != p4
14674 || p != p5 || p != p6 || p != p7)
14675 _exit(1);
14676
14677 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14678 from child file descriptors. If the child closes a descriptor
14679 before it execs or exits, this munges the parent's descriptor
14680 as well. Test for this by closing stdout in the child. */
14681 _exit(close(fileno(stdout)) != 0);
14682 } else {
14683 int status;
14684 struct stat st;
14685
14686 while (wait(&status) != child)
14687 ;
14688 return (
14689 /* Was there some problem with vforking? */
14690 child < 0
14691
14692 /* Did the child fail? (This shouldn't happen.) */
14693 || status
14694
14695 /* Did the vfork/compiler bug occur? */
14696 || parent != getpid()
14697
14698 /* Did the file descriptor bug occur? */
14699 || fstat(fileno(stdout), &st) != 0
14700 );
14701 }
14702 }
14703 _ACEOF
14704 if ac_fn_c_try_run "$LINENO"; then :
14705 ac_cv_func_vfork_works=yes
14706 else
14707 ac_cv_func_vfork_works=no
14708 fi
14709 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14710 conftest.$ac_objext conftest.beam conftest.$ac_ext
14711 fi
14712
14713 fi
14714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14715 $as_echo "$ac_cv_func_vfork_works" >&6; }
14716
14717 fi;
14718 if test "x$ac_cv_func_fork_works" = xcross; then
14719 ac_cv_func_vfork_works=$ac_cv_func_vfork
14720 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14721 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14722 fi
14723
14724 if test "x$ac_cv_func_vfork_works" = xyes; then
14725
14726 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14727
14728 else
14729
14730 $as_echo "#define vfork fork" >>confdefs.h
14731
14732 fi
14733 if test "x$ac_cv_func_fork_works" = xyes; then
14734
14735 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14736
14737 fi
14738
14739
14740 for ac_func in snprintf
14741 do :
14742 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14743 if test "x$ac_cv_func_snprintf" = x""yes; then :
14744 cat >>confdefs.h <<_ACEOF
14745 #define HAVE_SNPRINTF 1
14746 _ACEOF
14747
14748 fi
14749 done
14750
14751
14752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14753 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14754 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14755 $as_echo_n "(cached) " >&6
14756 else
14757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14758 /* end confdefs.h. */
14759 #include <langinfo.h>
14760 int
14761 main ()
14762 {
14763 char* cs = nl_langinfo(CODESET);
14764 ;
14765 return 0;
14766 }
14767 _ACEOF
14768 if ac_fn_c_try_link "$LINENO"; then :
14769 emacs_cv_langinfo_codeset=yes
14770 else
14771 emacs_cv_langinfo_codeset=no
14772 fi
14773 rm -f core conftest.err conftest.$ac_objext \
14774 conftest$ac_exeext conftest.$ac_ext
14775
14776 fi
14777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14778 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14779 if test $emacs_cv_langinfo_codeset = yes; then
14780
14781 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14782
14783 fi
14784
14785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14786 $as_echo_n "checking for mbstate_t... " >&6; }
14787 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14788 $as_echo_n "(cached) " >&6
14789 else
14790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14791 /* end confdefs.h. */
14792 $ac_includes_default
14793 # include <wchar.h>
14794 int
14795 main ()
14796 {
14797 mbstate_t x; return sizeof x;
14798 ;
14799 return 0;
14800 }
14801 _ACEOF
14802 if ac_fn_c_try_compile "$LINENO"; then :
14803 ac_cv_type_mbstate_t=yes
14804 else
14805 ac_cv_type_mbstate_t=no
14806 fi
14807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14808 fi
14809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
14810 $as_echo "$ac_cv_type_mbstate_t" >&6; }
14811 if test $ac_cv_type_mbstate_t = yes; then
14812
14813 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
14814
14815 else
14816
14817 $as_echo "#define mbstate_t int" >>confdefs.h
14818
14819 fi
14820
14821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
14822 $as_echo_n "checking for C restricted array declarations... " >&6; }
14823 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
14824 $as_echo_n "(cached) " >&6
14825 else
14826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14827 /* end confdefs.h. */
14828 void fred (int x[__restrict]);
14829 int
14830 main ()
14831 {
14832
14833 ;
14834 return 0;
14835 }
14836 _ACEOF
14837 if ac_fn_c_try_compile "$LINENO"; then :
14838 emacs_cv_c_restrict_arr=yes
14839 else
14840 emacs_cv_c_restrict_arr=no
14841 fi
14842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14843 fi
14844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
14845 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
14846 if test "$emacs_cv_c_restrict_arr" = yes; then
14847
14848 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
14849
14850 fi
14851
14852
14853
14854 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
14855
14856
14857
14858 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
14859
14860
14861
14862
14863
14864
14865 ## Note: PTYs are broken on darwin <6. Use at your own risk.
14866
14867 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
14868
14869
14870
14871 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
14872
14873
14874
14875
14876
14877 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
14878
14879
14880
14881 $as_echo "#define SEPCHAR ':'" >>confdefs.h
14882
14883
14884
14885 $as_echo "#define subprocesses 1" >>confdefs.h
14886
14887
14888
14889 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
14890
14891
14892
14893
14894 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
14895
14896
14897
14898
14899
14900 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
14901
14902
14903
14904 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
14905
14906
14907
14908 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
14909
14910
14911
14912
14913
14914 case $opsys in
14915 aix4-2)
14916 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
14917 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14918
14919 fi
14920 ;;
14921
14922 hpux*)
14923 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14924
14925 ;;
14926 esac
14927
14928
14929 case $opsys in
14930 darwin | gnu | hpux* | *bsd )
14931
14932 $as_echo "#define NO_TERMIO 1" >>confdefs.h
14933
14934 ;;
14935
14936 irix6-5 | sol2* | unixware )
14937
14938 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
14939
14940 ;;
14941 esac
14942
14943
14944 case $opsys in
14945 hpux* | irix6-5 | openbsd | sol2* | unixware )
14946
14947 $as_echo "#define BROKEN_SIGIO 1" >>confdefs.h
14948
14949 ;;
14950
14951 aix4-2)
14952
14953 $as_echo "#define BROKEN_FIONREAD 1" >>confdefs.h
14954
14955
14956 $as_echo "#define BROKEN_SIGAIO 1" >>confdefs.h
14957
14958
14959 $as_echo "#define BROKEN_SIGPOLL 1" >>confdefs.h
14960
14961
14962 $as_echo "#define BROKEN_SIGPTY 1" >>confdefs.h
14963
14964
14965
14966 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
14967
14968 ;;
14969
14970 freebsd)
14971
14972 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
14973
14974 ;;
14975 esac
14976
14977 case $opsys in
14978 gnu-* | sol2-10 )
14979
14980 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
14981
14982 ;;
14983 esac
14984
14985 case $opsys in
14986 darwin | freebsd | netbsd | openbsd )
14987
14988 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
14989
14990 ;;
14991 esac
14992
14993 case $opsys in
14994 netbsd | openbsd) sound_device="/dev/audio" ;;
14995 *) sound_device="/dev/dsp" ;;
14996 esac
14997
14998
14999 cat >>confdefs.h <<_ACEOF
15000 #define DEFAULT_SOUND_DEVICE "$sound_device"
15001 _ACEOF
15002
15003
15004
15005 case $opsys in
15006 darwin | gnu-linux | gnu-kfreebsd )
15007
15008 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
15009
15010 ;;
15011 esac
15012
15013
15014 case $opsys in
15015 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
15016
15017 $as_echo "#define NARROWPROTO 1" >>confdefs.h
15018
15019 ;;
15020 esac
15021
15022
15023
15024
15025
15026
15027
15028
15029 case $opsys in
15030 aix4-2 )
15031 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
15032
15033 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
15034
15035 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
15036
15037 ;;
15038
15039 cygwin )
15040 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15041
15042 $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
15043
15044 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15045
15046 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15047
15048 ;;
15049
15050 darwin )
15051 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15052
15053 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15054
15055 $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
15056
15057 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15058
15059 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15060
15061 ;;
15062
15063 gnu | openbsd )
15064 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15065
15066 ;;
15067
15068 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15069 if test "x$ac_cv_func_grantpt" = xyes; then
15070
15071 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15072
15073 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15074
15075 $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
15076
15077 if test "x$ac_cv_func_posix_openpt" = xyes; then
15078 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15079
15080 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15081
15082 elif test "x$ac_cv_func_getpt" = xyes; then
15083 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15084
15085 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15086
15087 else
15088 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15089
15090 fi
15091 else
15092 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15093
15094 fi
15095 ;;
15096
15097 hpux*)
15098 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15099
15100 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15101
15102 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15103
15104 ;;
15105
15106 irix6-5 )
15107 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15108
15109 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15110
15111 $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
15112
15113 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15114
15115 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15116
15117 ;;
15118
15119 sol2* )
15120 $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
15121
15122 ;;
15123
15124 unixware )
15125 $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
15126
15127 ;;
15128 esac
15129
15130
15131 case $opsys in
15132 sol2* | unixware )
15133 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15134
15135 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15136
15137
15138 $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
15139
15140 ;;
15141 esac
15142
15143
15144
15145
15146 case $opsys in
15147 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15148 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15149
15150 ;;
15151
15152 gnu-linux | gnu-kfreebsd )
15153
15154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15155 $as_echo_n "checking for signals via characters... " >&6; }
15156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15157 /* end confdefs.h. */
15158
15159 #include <linux/version.h>
15160 #if LINUX_VERSION_CODE < 0x20400
15161 # error "Linux version too old"
15162 #endif
15163
15164 int
15165 main ()
15166 {
15167
15168 ;
15169 return 0;
15170 }
15171 _ACEOF
15172 if ac_fn_c_try_cpp "$LINENO"; then :
15173 emacs_signals_via_chars=yes
15174 else
15175 emacs_signals_via_chars=no
15176 fi
15177 rm -f conftest.err conftest.$ac_ext
15178
15179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15180 $as_echo "$emacs_signals_via_chars" >&6; }
15181 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15182
15183 ;;
15184 esac
15185
15186
15187
15188
15189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C library" >&5
15190 $as_echo_n "checking whether we are using the GNU C library... " >&6; }
15191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15192 /* end confdefs.h. */
15193
15194 #include <features.h>
15195 #ifndef __GNU_LIBRARY__
15196 # error "this is not the GNU C library"
15197 #endif
15198
15199 int
15200 main ()
15201 {
15202
15203 ;
15204 return 0;
15205 }
15206 _ACEOF
15207 if ac_fn_c_try_cpp "$LINENO"; then :
15208 emacs_glibc=yes
15209 else
15210 emacs_glibc=no
15211 fi
15212 rm -f conftest.err conftest.$ac_ext
15213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_glibc" >&5
15214 $as_echo "$emacs_glibc" >&6; }
15215
15216 if test $emacs_glibc = yes; then
15217
15218 emacs_pending_output=unknown
15219
15220 case $opsys in
15221 gnu | gnu-linux | gnu-kfreebsd )
15222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of pending output formalism" >&5
15223 $as_echo_n "checking for style of pending output formalism... " >&6; }
15224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15225 /* end confdefs.h. */
15226
15227 #include <stdio.h>
15228 #if !defined (_IO_STDIO_H) && !defined (_STDIO_USES_IOSTREAM)
15229 # error "stdio definitions not found"
15230 #endif
15231
15232 int
15233 main ()
15234 {
15235
15236 ;
15237 return 0;
15238 }
15239 _ACEOF
15240 if ac_fn_c_try_cpp "$LINENO"; then :
15241 emacs_pending_output=new
15242 fi
15243 rm -f conftest.err conftest.$ac_ext
15244
15245 if test $emacs_pending_output = unknown; then
15246 case $opsys in
15247 gnu-linux | gnu-kfreebsd)
15248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15249 /* end confdefs.h. */
15250
15251 #include <stdio.h>
15252 #ifndef __UCLIBC__
15253 # error "not using uclibc"
15254 #endif
15255
15256 int
15257 main ()
15258 {
15259
15260 ;
15261 return 0;
15262 }
15263 _ACEOF
15264 if ac_fn_c_try_cpp "$LINENO"; then :
15265 emacs_pending_output=uclibc
15266 else
15267 emacs_pending_output=old
15268 fi
15269 rm -f conftest.err conftest.$ac_ext
15270 ;;
15271 esac
15272 fi
15273
15274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_pending_output" >&5
15275 $as_echo "$emacs_pending_output" >&6; }
15276
15277 case $emacs_pending_output in
15278 new)
15279 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_IO_write_ptr - (FILE)->_IO_write_base)" >>confdefs.h
15280
15281 ;;
15282 uclibc)
15283 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufpos - (FILE)->__bufstart)" >>confdefs.h
15284
15285 ;;
15286 old)
15287 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_pptr - (FILE)->_pbase)" >>confdefs.h
15288
15289 ;;
15290 esac
15291 ;;
15292 esac
15293 if test $emacs_pending_output = unknown; then
15294 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufp - (FILE)->__buffer)" >>confdefs.h
15295
15296 fi
15297
15298 else
15299 case $opsys in
15300 cygwin | darwin | freebsd | netbsd | openbsd )
15301 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)" >>confdefs.h
15302
15303 ;;
15304
15305 unixware)
15306 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__ptr - (FILE)->__base)" >>confdefs.h
15307
15308 ;;
15309
15310 *)
15311 if test x$ac_cv_header_stdio_ext_h = xyes && \
15312 test x$ac_cv_func___fpending = xyes; then
15313 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) __fpending (FILE)" >>confdefs.h
15314
15315
15316 $as_echo "#define DISPNEW_NEEDS_STDIO_EXT 1" >>confdefs.h
15317
15318 else
15319 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_ptr - (FILE)->_base)" >>confdefs.h
15320
15321 fi
15322 ;;
15323 esac
15324 fi
15325
15326
15327
15328
15329 case $opsys in
15330 gnu)
15331 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15332
15333 ;;
15334
15335 hpux*)
15336 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15337
15338 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15339
15340 ;;
15341 irix6-5)
15342 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15343
15344 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15345
15346 ;;
15347 esac
15348
15349
15350
15351
15352
15353 case $opsys in
15354 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15355 ;;
15356
15357 gnu | freebsd | netbsd | openbsd )
15358
15359 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15360
15361 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15362
15363 ;;
15364
15365 gnu-linux | gnu-kfreebsd )
15366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15367 /* end confdefs.h. */
15368
15369 #ifndef __i386__
15370 # error "not i386"
15371 #endif
15372
15373 int
15374 main ()
15375 {
15376
15377 ;
15378 return 0;
15379 }
15380 _ACEOF
15381 if ac_fn_c_try_cpp "$LINENO"; then :
15382 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15383
15384 fi
15385 rm -f conftest.err conftest.$ac_ext
15386
15387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15388 /* end confdefs.h. */
15389
15390 #ifndef __ia64__
15391 # error "not ia64"
15392 #endif
15393
15394 int
15395 main ()
15396 {
15397
15398 ;
15399 return 0;
15400 }
15401 _ACEOF
15402 if ac_fn_c_try_cpp "$LINENO"; then :
15403
15404 $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
15405
15406 fi
15407 rm -f conftest.err conftest.$ac_ext
15408 ;;
15409
15410 hpux*)
15411
15412 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15413
15414 ;;
15415
15416 irix6-5)
15417 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15418
15419 ;;
15420 esac
15421
15422
15423
15424
15425
15426
15427
15428 case $opsys in
15429 aix4-2 | hpux* | unixware)
15430 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15431
15432 ;;
15433
15434 gnu-linux | gnu-kfreebsd )
15435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15436 /* end confdefs.h. */
15437
15438 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15439 || defined __alpha__ || defined __mips__ || defined __s390__ \
15440 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15441 || defined __ia64__ || defined __sh__
15442 /* ok */
15443 #else
15444 # error "setjmp not known to work on this arch"
15445 #endif
15446
15447 int
15448 main ()
15449 {
15450
15451 ;
15452 return 0;
15453 }
15454 _ACEOF
15455 if ac_fn_c_try_cpp "$LINENO"; then :
15456 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15457
15458 else
15459 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15460
15461 fi
15462 rm -f conftest.err conftest.$ac_ext
15463 ;;
15464 esac
15465
15466
15467 if test x$GCC = xyes; then
15468 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15469
15470 else
15471 case $opsys in
15472 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15473 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15474
15475 ;;
15476 esac
15477 fi
15478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15479 $as_echo_n "checking for _setjmp... " >&6; }
15480 if test "${emacs_cv_func__setjmp+set}" = set; then :
15481 $as_echo_n "(cached) " >&6
15482 else
15483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15484 /* end confdefs.h. */
15485 #include <setjmp.h>
15486
15487 int
15488 main ()
15489 {
15490 jmp_buf j;
15491 if (! _setjmp (j))
15492 _longjmp (j, 1);
15493 ;
15494 return 0;
15495 }
15496 _ACEOF
15497 if ac_fn_c_try_link "$LINENO"; then :
15498 emacs_cv_func__setjmp=yes
15499 else
15500 emacs_cv_func__setjmp=no
15501 fi
15502 rm -f core conftest.err conftest.$ac_objext \
15503 conftest$ac_exeext conftest.$ac_ext
15504 fi
15505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15506 $as_echo "$emacs_cv_func__setjmp" >&6; }
15507 if test $emacs_cv_func__setjmp = no; then
15508
15509 $as_echo "#define _setjmp setjmp" >>confdefs.h
15510
15511
15512 $as_echo "#define _longjmp longjmp" >>confdefs.h
15513
15514 fi
15515
15516 case $opsys in
15517 sol2* | unixware )
15518
15519 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15520
15521 ;;
15522 esac
15523
15524
15525 case $opsys in
15526 hpux* | sol2* )
15527
15528 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15529
15530 ;;
15531 esac
15532
15533
15534
15535
15536
15537
15538
15539
15540
15541
15542 case $opsys in
15543 aix4-2)
15544 $as_echo "#define USG /**/" >>confdefs.h
15545
15546 $as_echo "#define USG5 /**/" >>confdefs.h
15547
15548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15549 /* end confdefs.h. */
15550
15551 #ifndef _AIX
15552 # error "_AIX not defined"
15553 #endif
15554
15555 int
15556 main ()
15557 {
15558
15559 ;
15560 return 0;
15561 }
15562 _ACEOF
15563 if ac_fn_c_try_cpp "$LINENO"; then :
15564
15565 else
15566
15567 $as_echo "#define _AIX /**/" >>confdefs.h
15568
15569 fi
15570 rm -f conftest.err conftest.$ac_ext
15571 ;;
15572
15573 cygwin)
15574
15575 $as_echo "#define CYGWIN 1" >>confdefs.h
15576
15577 ;;
15578
15579 darwin)
15580 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15581
15582 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15583
15584
15585 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15586
15587 ;;
15588
15589 freebsd)
15590 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15591
15592
15593 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15594
15595 ;;
15596
15597 gnu | netbsd | openbsd )
15598 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15599
15600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15601 /* end confdefs.h. */
15602
15603 #ifndef BSD_SYSTEM
15604 # error "BSD_SYSTEM not defined"
15605 #endif
15606
15607 int
15608 main ()
15609 {
15610
15611 ;
15612 return 0;
15613 }
15614 _ACEOF
15615 if ac_fn_c_try_cpp "$LINENO"; then :
15616
15617 else
15618 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15619
15620 fi
15621 rm -f conftest.err conftest.$ac_ext
15622 ;;
15623
15624 gnu-linux | gnu-kfreebsd )
15625 $as_echo "#define USG /**/" >>confdefs.h
15626
15627
15628 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15629
15630 ;;
15631
15632 hpux*)
15633 $as_echo "#define USG /**/" >>confdefs.h
15634
15635 $as_echo "#define USG5 /**/" >>confdefs.h
15636
15637
15638 $as_echo "#define HPUX /**/" >>confdefs.h
15639
15640 ;;
15641
15642 irix6-5)
15643 $as_echo "#define USG /**/" >>confdefs.h
15644
15645 $as_echo "#define USG5 /**/" >>confdefs.h
15646
15647 $as_echo "#define USG5_4 /**/" >>confdefs.h
15648
15649
15650 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15651
15652 ;;
15653
15654 sol2*)
15655 $as_echo "#define USG /**/" >>confdefs.h
15656
15657 $as_echo "#define USG5 /**/" >>confdefs.h
15658
15659 $as_echo "#define USG5_4 /**/" >>confdefs.h
15660
15661
15662 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15663
15664 ;;
15665
15666 unixware)
15667 $as_echo "#define USG /**/" >>confdefs.h
15668
15669 $as_echo "#define USG5 /**/" >>confdefs.h
15670
15671 $as_echo "#define USG5_4 /**/" >>confdefs.h
15672
15673 ;;
15674 esac
15675
15676
15677 case $opsys in
15678 cygwin)
15679
15680 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15681
15682 ;;
15683
15684 hpux11)
15685
15686 $as_echo "#define BROKEN_SA_RESTART 1" >>confdefs.h
15687
15688
15689 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15690
15691 ;;
15692
15693 irix6-5)
15694
15695 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15696
15697
15698 $as_echo "#define SETPGRP_RELEASES_CTTY 1" >>confdefs.h
15699
15700 ;;
15701
15702 sol2-10)
15703
15704 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15705
15706 ;;
15707 esac
15708
15709 # Set up the CFLAGS for real compilation, so we can substitute it.
15710 CFLAGS="$REAL_CFLAGS"
15711 CPPFLAGS="$REAL_CPPFLAGS"
15712
15713 ## Hack to detect a buggy GCC version.
15714 if test "x$GCC" = xyes \
15715 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15716 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15717 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15718 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15719 fi
15720
15721 version=$PACKAGE_VERSION
15722
15723 ### Specify what sort of things we'll be editing into Makefile and config.h.
15724 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15725
15726
15727 ## Unused?
15728
15729
15730
15731
15732
15733
15734
15735
15736
15737
15738
15739
15740
15741
15742
15743
15744
15745
15746
15747
15748
15749
15750 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15751 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15752 ## end of LIBX_BASE, but nothing ever set it.
15753
15754
15755
15756
15757 ## Used in lwlib/Makefile.in.
15758
15759
15760
15761
15762
15763
15764
15765
15766 if test -n "${term_header}"; then
15767
15768 cat >>confdefs.h <<_ACEOF
15769 #define TERM_HEADER "${term_header}"
15770 _ACEOF
15771
15772 fi
15773
15774
15775 cat >>confdefs.h <<_ACEOF
15776 #define EMACS_CONFIGURATION "${canonical}"
15777 _ACEOF
15778
15779
15780 cat >>confdefs.h <<_ACEOF
15781 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15782 _ACEOF
15783
15784
15785
15786 XMENU_OBJ=
15787 XOBJ=
15788 FONT_OBJ=
15789 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15790
15791 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15792
15793 XMENU_OBJ=xmenu.o
15794 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
15795 FONT_OBJ=xfont.o
15796 if test "$HAVE_XFT" = "yes"; then
15797 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15798 elif test "$HAVE_FREETYPE" = "yes"; then
15799 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15800 fi
15801
15802 fi
15803
15804
15805
15806
15807 WIDGET_OBJ=
15808 MOTIF_LIBW=
15809 if test "${USE_X_TOOLKIT}" != "none" ; then
15810 WIDGET_OBJ=widget.o
15811
15812 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15813
15814 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15815
15816 $as_echo "#define USE_LUCID 1" >>confdefs.h
15817
15818 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15819
15820 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15821
15822 MOTIF_LIBW=-lXm
15823 case "$opsys" in
15824 gnu-linux)
15825 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15826 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15827 ;;
15828
15829 unixware)
15830 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15831 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15832 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15833 ;;
15834
15835 aix4-2)
15836 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15837 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15838 ;;
15839 esac
15840 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15841 fi
15842 fi
15843
15844
15845 TOOLKIT_LIBW=
15846 case "$USE_X_TOOLKIT" in
15847 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15848 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15849 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15850 esac
15851
15852
15853 if test "$USE_X_TOOLKIT" = "none"; then
15854 LIBXT_OTHER="\$(LIBXSM)"
15855 OLDXMENU_TARGET="really-oldXMenu"
15856 else
15857 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15858 OLDXMENU_TARGET="really-lwlib"
15859 fi
15860
15861
15862 ## The X Menu stuff is present in the X10 distribution, but missing
15863 ## from X11. If we have X10, just use the installed library;
15864 ## otherwise, use our own copy.
15865 if test "${HAVE_X11}" = "yes" ; then
15866
15867 $as_echo "#define HAVE_X11 1" >>confdefs.h
15868
15869
15870 if test "$USE_X_TOOLKIT" = "none"; then
15871 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15872 else
15873 OLDXMENU="\${lwlibdir}/liblw.a"
15874 fi
15875 LIBXMENU="\$(OLDXMENU)"
15876 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15877 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
15878 else
15879 ## For a syntactically valid Makefile; not actually used for anything.
15880 ## See comments in src/Makefile.in.
15881 OLDXMENU=nothing
15882 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15883 if test "${HAVE_X_WINDOWS}" = "yes"; then
15884 LIBXMENU="-lXMenu"
15885 else
15886 LIBXMENU=
15887 fi
15888 LIBX_OTHER=
15889 OLDXMENU_DEPS=
15890 fi
15891
15892 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15893 OLDXMENU_TARGET=
15894 OLDXMENU=nothing
15895 LIBXMENU=
15896 OLDXMENU_DEPS=
15897 fi
15898
15899
15900
15901
15902
15903
15904
15905 if test "${HAVE_MENUS}" = "yes" ; then
15906
15907 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
15908
15909 fi
15910
15911 if test "${GNU_MALLOC}" = "yes" ; then
15912
15913 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
15914
15915 fi
15916
15917 RALLOC_OBJ=
15918 if test "${REL_ALLOC}" = "yes" ; then
15919
15920 $as_echo "#define REL_ALLOC 1" >>confdefs.h
15921
15922
15923 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
15924 fi
15925
15926
15927 if test "$opsys" = "cygwin"; then
15928 CYGWIN_OBJ="sheap.o"
15929 ## Cygwin differs because of its unexec().
15930 PRE_ALLOC_OBJ=
15931 POST_ALLOC_OBJ=lastfile.o
15932 else
15933 CYGWIN_OBJ=
15934 PRE_ALLOC_OBJ=lastfile.o
15935 POST_ALLOC_OBJ=
15936 fi
15937
15938
15939
15940
15941 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
15942 # it temporarily reverts them to their pre-pkg-config values,
15943 # because gnulib needs to work with both src (which uses the
15944 # pkg-config stuff) and lib-src (which does not). For example, gnulib
15945 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
15946 # and it therefore needs to run in an environment where LIBS does not
15947 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
15948 # for some package unrelated to lib-src.
15949 SAVE_CFLAGS=$CFLAGS
15950 SAVE_LIBS=$LIBS
15951 CFLAGS=$pre_PKG_CONFIG_CFLAGS
15952 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
15953
15954
15955
15956
15957
15958
15959
15960
15961
15962
15963
15964 LIBC_FATAL_STDERR_=1
15965 export LIBC_FATAL_STDERR_
15966
15967 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15968 # for constant arguments. Useless!
15969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15970 $as_echo_n "checking for working alloca.h... " >&6; }
15971 if test "${ac_cv_working_alloca_h+set}" = set; then :
15972 $as_echo_n "(cached) " >&6
15973 else
15974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15975 /* end confdefs.h. */
15976 #include <alloca.h>
15977 int
15978 main ()
15979 {
15980 char *p = (char *) alloca (2 * sizeof (int));
15981 if (p) return 0;
15982 ;
15983 return 0;
15984 }
15985 _ACEOF
15986 if ac_fn_c_try_link "$LINENO"; then :
15987 ac_cv_working_alloca_h=yes
15988 else
15989 ac_cv_working_alloca_h=no
15990 fi
15991 rm -f core conftest.err conftest.$ac_objext \
15992 conftest$ac_exeext conftest.$ac_ext
15993 fi
15994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
15995 $as_echo "$ac_cv_working_alloca_h" >&6; }
15996 if test $ac_cv_working_alloca_h = yes; then
15997
15998 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
15999
16000 fi
16001
16002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16003 $as_echo_n "checking for alloca... " >&6; }
16004 if test "${ac_cv_func_alloca_works+set}" = set; then :
16005 $as_echo_n "(cached) " >&6
16006 else
16007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16008 /* end confdefs.h. */
16009 #ifdef __GNUC__
16010 # define alloca __builtin_alloca
16011 #else
16012 # ifdef _MSC_VER
16013 # include <malloc.h>
16014 # define alloca _alloca
16015 # else
16016 # ifdef HAVE_ALLOCA_H
16017 # include <alloca.h>
16018 # else
16019 # ifdef _AIX
16020 #pragma alloca
16021 # else
16022 # ifndef alloca /* predefined by HP cc +Olibcalls */
16023 char *alloca ();
16024 # endif
16025 # endif
16026 # endif
16027 # endif
16028 #endif
16029
16030 int
16031 main ()
16032 {
16033 char *p = (char *) alloca (1);
16034 if (p) return 0;
16035 ;
16036 return 0;
16037 }
16038 _ACEOF
16039 if ac_fn_c_try_link "$LINENO"; then :
16040 ac_cv_func_alloca_works=yes
16041 else
16042 ac_cv_func_alloca_works=no
16043 fi
16044 rm -f core conftest.err conftest.$ac_objext \
16045 conftest$ac_exeext conftest.$ac_ext
16046 fi
16047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16048 $as_echo "$ac_cv_func_alloca_works" >&6; }
16049
16050 if test $ac_cv_func_alloca_works = yes; then
16051
16052 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16053
16054 else
16055 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16056 # that cause trouble. Some versions do not even contain alloca or
16057 # contain a buggy version. If you still want to use their alloca,
16058 # use ar to extract alloca.o from them instead of compiling alloca.c.
16059
16060
16061
16062
16063
16064 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16065
16066 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16067
16068
16069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16070 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16071 if test "${ac_cv_os_cray+set}" = set; then :
16072 $as_echo_n "(cached) " >&6
16073 else
16074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16075 /* end confdefs.h. */
16076 #if defined CRAY && ! defined CRAY2
16077 webecray
16078 #else
16079 wenotbecray
16080 #endif
16081
16082 _ACEOF
16083 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16084 $EGREP "webecray" >/dev/null 2>&1; then :
16085 ac_cv_os_cray=yes
16086 else
16087 ac_cv_os_cray=no
16088 fi
16089 rm -f conftest*
16090
16091 fi
16092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16093 $as_echo "$ac_cv_os_cray" >&6; }
16094 if test $ac_cv_os_cray = yes; then
16095 for ac_func in _getb67 GETB67 getb67; do
16096 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16097 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16098 eval as_val=\$$as_ac_var
16099 if test "x$as_val" = x""yes; then :
16100
16101 cat >>confdefs.h <<_ACEOF
16102 #define CRAY_STACKSEG_END $ac_func
16103 _ACEOF
16104
16105 break
16106 fi
16107
16108 done
16109 fi
16110
16111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16112 $as_echo_n "checking stack direction for C alloca... " >&6; }
16113 if test "${ac_cv_c_stack_direction+set}" = set; then :
16114 $as_echo_n "(cached) " >&6
16115 else
16116 if test "$cross_compiling" = yes; then :
16117 ac_cv_c_stack_direction=0
16118 else
16119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16120 /* end confdefs.h. */
16121 $ac_includes_default
16122 int
16123 find_stack_direction (int *addr, int depth)
16124 {
16125 int dir, dummy = 0;
16126 if (! addr)
16127 addr = &dummy;
16128 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16129 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16130 return dir + dummy;
16131 }
16132
16133 int
16134 main (int argc, char **argv)
16135 {
16136 return find_stack_direction (0, argc + !argv + 20) < 0;
16137 }
16138 _ACEOF
16139 if ac_fn_c_try_run "$LINENO"; then :
16140 ac_cv_c_stack_direction=1
16141 else
16142 ac_cv_c_stack_direction=-1
16143 fi
16144 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16145 conftest.$ac_objext conftest.beam conftest.$ac_ext
16146 fi
16147
16148 fi
16149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16150 $as_echo "$ac_cv_c_stack_direction" >&6; }
16151 cat >>confdefs.h <<_ACEOF
16152 #define STACK_DIRECTION $ac_cv_c_stack_direction
16153 _ACEOF
16154
16155
16156 fi
16157
16158
16159
16160
16161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16162 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16163 if test "${ac_cv_c_bigendian+set}" = set; then :
16164 $as_echo_n "(cached) " >&6
16165 else
16166 ac_cv_c_bigendian=unknown
16167 # See if we're dealing with a universal compiler.
16168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16169 /* end confdefs.h. */
16170 #ifndef __APPLE_CC__
16171 not a universal capable compiler
16172 #endif
16173 typedef int dummy;
16174
16175 _ACEOF
16176 if ac_fn_c_try_compile "$LINENO"; then :
16177
16178 # Check for potential -arch flags. It is not universal unless
16179 # there are at least two -arch flags with different values.
16180 ac_arch=
16181 ac_prev=
16182 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16183 if test -n "$ac_prev"; then
16184 case $ac_word in
16185 i?86 | x86_64 | ppc | ppc64)
16186 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16187 ac_arch=$ac_word
16188 else
16189 ac_cv_c_bigendian=universal
16190 break
16191 fi
16192 ;;
16193 esac
16194 ac_prev=
16195 elif test "x$ac_word" = "x-arch"; then
16196 ac_prev=arch
16197 fi
16198 done
16199 fi
16200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16201 if test $ac_cv_c_bigendian = unknown; then
16202 # See if sys/param.h defines the BYTE_ORDER macro.
16203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16204 /* end confdefs.h. */
16205 #include <sys/types.h>
16206 #include <sys/param.h>
16207
16208 int
16209 main ()
16210 {
16211 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16212 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16213 && LITTLE_ENDIAN)
16214 bogus endian macros
16215 #endif
16216
16217 ;
16218 return 0;
16219 }
16220 _ACEOF
16221 if ac_fn_c_try_compile "$LINENO"; then :
16222 # It does; now see whether it defined to BIG_ENDIAN or not.
16223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16224 /* end confdefs.h. */
16225 #include <sys/types.h>
16226 #include <sys/param.h>
16227
16228 int
16229 main ()
16230 {
16231 #if BYTE_ORDER != BIG_ENDIAN
16232 not big endian
16233 #endif
16234
16235 ;
16236 return 0;
16237 }
16238 _ACEOF
16239 if ac_fn_c_try_compile "$LINENO"; then :
16240 ac_cv_c_bigendian=yes
16241 else
16242 ac_cv_c_bigendian=no
16243 fi
16244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16245 fi
16246 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16247 fi
16248 if test $ac_cv_c_bigendian = unknown; then
16249 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16251 /* end confdefs.h. */
16252 #include <limits.h>
16253
16254 int
16255 main ()
16256 {
16257 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16258 bogus endian macros
16259 #endif
16260
16261 ;
16262 return 0;
16263 }
16264 _ACEOF
16265 if ac_fn_c_try_compile "$LINENO"; then :
16266 # It does; now see whether it defined to _BIG_ENDIAN or not.
16267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16268 /* end confdefs.h. */
16269 #include <limits.h>
16270
16271 int
16272 main ()
16273 {
16274 #ifndef _BIG_ENDIAN
16275 not big endian
16276 #endif
16277
16278 ;
16279 return 0;
16280 }
16281 _ACEOF
16282 if ac_fn_c_try_compile "$LINENO"; then :
16283 ac_cv_c_bigendian=yes
16284 else
16285 ac_cv_c_bigendian=no
16286 fi
16287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16288 fi
16289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16290 fi
16291 if test $ac_cv_c_bigendian = unknown; then
16292 # Compile a test program.
16293 if test "$cross_compiling" = yes; then :
16294 # Try to guess by grepping values from an object file.
16295 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16296 /* end confdefs.h. */
16297 short int ascii_mm[] =
16298 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16299 short int ascii_ii[] =
16300 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16301 int use_ascii (int i) {
16302 return ascii_mm[i] + ascii_ii[i];
16303 }
16304 short int ebcdic_ii[] =
16305 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16306 short int ebcdic_mm[] =
16307 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16308 int use_ebcdic (int i) {
16309 return ebcdic_mm[i] + ebcdic_ii[i];
16310 }
16311 extern int foo;
16312
16313 int
16314 main ()
16315 {
16316 return use_ascii (foo) == use_ebcdic (foo);
16317 ;
16318 return 0;
16319 }
16320 _ACEOF
16321 if ac_fn_c_try_compile "$LINENO"; then :
16322 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16323 ac_cv_c_bigendian=yes
16324 fi
16325 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16326 if test "$ac_cv_c_bigendian" = unknown; then
16327 ac_cv_c_bigendian=no
16328 else
16329 # finding both strings is unlikely to happen, but who knows?
16330 ac_cv_c_bigendian=unknown
16331 fi
16332 fi
16333 fi
16334 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16335 else
16336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16337 /* end confdefs.h. */
16338 $ac_includes_default
16339 int
16340 main ()
16341 {
16342
16343 /* Are we little or big endian? From Harbison&Steele. */
16344 union
16345 {
16346 long int l;
16347 char c[sizeof (long int)];
16348 } u;
16349 u.l = 1;
16350 return u.c[sizeof (long int) - 1] == 1;
16351
16352 ;
16353 return 0;
16354 }
16355 _ACEOF
16356 if ac_fn_c_try_run "$LINENO"; then :
16357 ac_cv_c_bigendian=no
16358 else
16359 ac_cv_c_bigendian=yes
16360 fi
16361 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16362 conftest.$ac_objext conftest.beam conftest.$ac_ext
16363 fi
16364
16365 fi
16366 fi
16367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16368 $as_echo "$ac_cv_c_bigendian" >&6; }
16369 case $ac_cv_c_bigendian in #(
16370 yes)
16371 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16372 ;; #(
16373 no)
16374 ;; #(
16375 universal)
16376
16377 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16378
16379 ;; #(
16380 *)
16381 as_fn_error "unknown endianness
16382 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16383 esac
16384
16385
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16387 $as_echo_n "checking for inline... " >&6; }
16388 if test "${ac_cv_c_inline+set}" = set; then :
16389 $as_echo_n "(cached) " >&6
16390 else
16391 ac_cv_c_inline=no
16392 for ac_kw in inline __inline__ __inline; do
16393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16394 /* end confdefs.h. */
16395 #ifndef __cplusplus
16396 typedef int foo_t;
16397 static $ac_kw foo_t static_foo () {return 0; }
16398 $ac_kw foo_t foo () {return 0; }
16399 #endif
16400
16401 _ACEOF
16402 if ac_fn_c_try_compile "$LINENO"; then :
16403 ac_cv_c_inline=$ac_kw
16404 fi
16405 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16406 test "$ac_cv_c_inline" != no && break
16407 done
16408
16409 fi
16410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16411 $as_echo "$ac_cv_c_inline" >&6; }
16412
16413 case $ac_cv_c_inline in
16414 inline | yes) ;;
16415 *)
16416 case $ac_cv_c_inline in
16417 no) ac_val=;;
16418 *) ac_val=$ac_cv_c_inline;;
16419 esac
16420 cat >>confdefs.h <<_ACEOF
16421 #ifndef __cplusplus
16422 #define inline $ac_val
16423 #endif
16424 _ACEOF
16425 ;;
16426 esac
16427
16428
16429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16430 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16431 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16432 $as_echo_n "(cached) " >&6
16433 else
16434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16435 /* end confdefs.h. */
16436 /* On HP-UX before 11.23, strtold returns a struct instead of
16437 long double. Reject implementations like that, by requiring
16438 compatibility with the C99 prototype. */
16439 #include <stdlib.h>
16440 static long double (*p) (char const *, char **) = strtold;
16441 static long double
16442 test (char const *nptr, char **endptr)
16443 {
16444 long double r;
16445 r = strtold (nptr, endptr);
16446 return r;
16447 }
16448 int
16449 main ()
16450 {
16451 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16452 ;
16453 return 0;
16454 }
16455 _ACEOF
16456 if ac_fn_c_try_link "$LINENO"; then :
16457 gl_cv_func_c99_strtold=yes
16458 else
16459 gl_cv_func_c99_strtold=no
16460 fi
16461 rm -f core conftest.err conftest.$ac_objext \
16462 conftest$ac_exeext conftest.$ac_ext
16463 fi
16464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16465 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16466 if test $gl_cv_func_c99_strtold = yes; then
16467
16468 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16469
16470 fi
16471
16472
16473 GNULIB_CHDIR=0;
16474 GNULIB_CHOWN=0;
16475 GNULIB_CLOSE=0;
16476 GNULIB_DUP=0;
16477 GNULIB_DUP2=0;
16478 GNULIB_DUP3=0;
16479 GNULIB_ENVIRON=0;
16480 GNULIB_EUIDACCESS=0;
16481 GNULIB_FACCESSAT=0;
16482 GNULIB_FCHDIR=0;
16483 GNULIB_FCHOWNAT=0;
16484 GNULIB_FDATASYNC=0;
16485 GNULIB_FSYNC=0;
16486 GNULIB_FTRUNCATE=0;
16487 GNULIB_GETCWD=0;
16488 GNULIB_GETDOMAINNAME=0;
16489 GNULIB_GETDTABLESIZE=0;
16490 GNULIB_GETGROUPS=0;
16491 GNULIB_GETHOSTNAME=0;
16492 GNULIB_GETLOGIN=0;
16493 GNULIB_GETLOGIN_R=0;
16494 GNULIB_GETPAGESIZE=0;
16495 GNULIB_GETUSERSHELL=0;
16496 GNULIB_GROUP_MEMBER=0;
16497 GNULIB_ISATTY=0;
16498 GNULIB_LCHOWN=0;
16499 GNULIB_LINK=0;
16500 GNULIB_LINKAT=0;
16501 GNULIB_LSEEK=0;
16502 GNULIB_PIPE=0;
16503 GNULIB_PIPE2=0;
16504 GNULIB_PREAD=0;
16505 GNULIB_PWRITE=0;
16506 GNULIB_READ=0;
16507 GNULIB_READLINK=0;
16508 GNULIB_READLINKAT=0;
16509 GNULIB_RMDIR=0;
16510 GNULIB_SETHOSTNAME=0;
16511 GNULIB_SLEEP=0;
16512 GNULIB_SYMLINK=0;
16513 GNULIB_SYMLINKAT=0;
16514 GNULIB_TTYNAME_R=0;
16515 GNULIB_UNISTD_H_NONBLOCKING=0;
16516 GNULIB_UNISTD_H_SIGPIPE=0;
16517 GNULIB_UNLINK=0;
16518 GNULIB_UNLINKAT=0;
16519 GNULIB_USLEEP=0;
16520 GNULIB_WRITE=0;
16521 HAVE_CHOWN=1;
16522 HAVE_DUP2=1;
16523 HAVE_DUP3=1;
16524 HAVE_EUIDACCESS=1;
16525 HAVE_FACCESSAT=1;
16526 HAVE_FCHDIR=1;
16527 HAVE_FCHOWNAT=1;
16528 HAVE_FDATASYNC=1;
16529 HAVE_FSYNC=1;
16530 HAVE_FTRUNCATE=1;
16531 HAVE_GETDTABLESIZE=1;
16532 HAVE_GETGROUPS=1;
16533 HAVE_GETHOSTNAME=1;
16534 HAVE_GETLOGIN=1;
16535 HAVE_GETPAGESIZE=1;
16536 HAVE_GROUP_MEMBER=1;
16537 HAVE_LCHOWN=1;
16538 HAVE_LINK=1;
16539 HAVE_LINKAT=1;
16540 HAVE_PIPE=1;
16541 HAVE_PIPE2=1;
16542 HAVE_PREAD=1;
16543 HAVE_PWRITE=1;
16544 HAVE_READLINK=1;
16545 HAVE_READLINKAT=1;
16546 HAVE_SETHOSTNAME=1;
16547 HAVE_SLEEP=1;
16548 HAVE_SYMLINK=1;
16549 HAVE_SYMLINKAT=1;
16550 HAVE_UNLINKAT=1;
16551 HAVE_USLEEP=1;
16552 HAVE_DECL_ENVIRON=1;
16553 HAVE_DECL_FCHDIR=1;
16554 HAVE_DECL_FDATASYNC=1;
16555 HAVE_DECL_GETDOMAINNAME=1;
16556 HAVE_DECL_GETLOGIN_R=1;
16557 HAVE_DECL_GETPAGESIZE=1;
16558 HAVE_DECL_GETUSERSHELL=1;
16559 HAVE_DECL_SETHOSTNAME=1;
16560 HAVE_DECL_TTYNAME_R=1;
16561 HAVE_OS_H=0;
16562 HAVE_SYS_PARAM_H=0;
16563 REPLACE_CHOWN=0;
16564 REPLACE_CLOSE=0;
16565 REPLACE_DUP=0;
16566 REPLACE_DUP2=0;
16567 REPLACE_FCHOWNAT=0;
16568 REPLACE_FTRUNCATE=0;
16569 REPLACE_GETCWD=0;
16570 REPLACE_GETDOMAINNAME=0;
16571 REPLACE_GETLOGIN_R=0;
16572 REPLACE_GETGROUPS=0;
16573 REPLACE_GETPAGESIZE=0;
16574 REPLACE_ISATTY=0;
16575 REPLACE_LCHOWN=0;
16576 REPLACE_LINK=0;
16577 REPLACE_LINKAT=0;
16578 REPLACE_LSEEK=0;
16579 REPLACE_PREAD=0;
16580 REPLACE_PWRITE=0;
16581 REPLACE_READ=0;
16582 REPLACE_READLINK=0;
16583 REPLACE_RMDIR=0;
16584 REPLACE_SLEEP=0;
16585 REPLACE_SYMLINK=0;
16586 REPLACE_TTYNAME_R=0;
16587 REPLACE_UNLINK=0;
16588 REPLACE_UNLINKAT=0;
16589 REPLACE_USLEEP=0;
16590 REPLACE_WRITE=0;
16591 UNISTD_H_HAVE_WINSOCK2_H=0;
16592 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16593
16594
16595
16596
16597
16598
16599
16600
16601
16602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16603 $as_echo_n "checking if environ is properly declared... " >&6; }
16604 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16605 $as_echo_n "(cached) " >&6
16606 else
16607
16608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16609 /* end confdefs.h. */
16610 #if HAVE_UNISTD_H
16611 #include <unistd.h>
16612 #endif
16613 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16614 #include <stdlib.h>
16615
16616 extern struct { int foo; } environ;
16617 int
16618 main ()
16619 {
16620 environ.foo = 1;
16621 ;
16622 return 0;
16623 }
16624 _ACEOF
16625 if ac_fn_c_try_compile "$LINENO"; then :
16626 gt_cv_var_environ_declaration=no
16627 else
16628 gt_cv_var_environ_declaration=yes
16629 fi
16630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16631 fi
16632
16633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16634 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16635 if test $gt_cv_var_environ_declaration = yes; then
16636
16637 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16638
16639 fi
16640
16641
16642 if test $gt_cv_var_environ_declaration != yes; then
16643 HAVE_DECL_ENVIRON=0
16644 fi
16645
16646
16647
16648
16649
16650
16651
16652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16653 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16654 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16655 $as_echo_n "(cached) " >&6
16656 else
16657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16658 /* end confdefs.h. */
16659
16660 #include <sys/types.h>
16661 #include <sys/stat.h>
16662 int
16663 main ()
16664 {
16665 struct stat s; s.st_dm_mode;
16666 ;
16667 return 0;
16668 }
16669 _ACEOF
16670 if ac_fn_c_try_compile "$LINENO"; then :
16671 ac_cv_struct_st_dm_mode=yes
16672 else
16673 ac_cv_struct_st_dm_mode=no
16674 fi
16675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16676 fi
16677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16678 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16679
16680 if test $ac_cv_struct_st_dm_mode = yes; then
16681
16682 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16683
16684 fi
16685
16686
16687 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16688 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16689 ac_have_decl=1
16690 else
16691 ac_have_decl=0
16692 fi
16693
16694 cat >>confdefs.h <<_ACEOF
16695 #define HAVE_DECL_STRMODE $ac_have_decl
16696 _ACEOF
16697
16698
16699 GNULIB__EXIT=0;
16700 GNULIB_ATOLL=0;
16701 GNULIB_CALLOC_POSIX=0;
16702 GNULIB_CANONICALIZE_FILE_NAME=0;
16703 GNULIB_GETLOADAVG=0;
16704 GNULIB_GETSUBOPT=0;
16705 GNULIB_GRANTPT=0;
16706 GNULIB_MALLOC_POSIX=0;
16707 GNULIB_MBTOWC=0;
16708 GNULIB_MKDTEMP=0;
16709 GNULIB_MKOSTEMP=0;
16710 GNULIB_MKOSTEMPS=0;
16711 GNULIB_MKSTEMP=0;
16712 GNULIB_MKSTEMPS=0;
16713 GNULIB_POSIX_OPENPT=0;
16714 GNULIB_PTSNAME=0;
16715 GNULIB_PTSNAME_R=0;
16716 GNULIB_PUTENV=0;
16717 GNULIB_RANDOM=0;
16718 GNULIB_RANDOM_R=0;
16719 GNULIB_REALLOC_POSIX=0;
16720 GNULIB_REALPATH=0;
16721 GNULIB_RPMATCH=0;
16722 GNULIB_SETENV=0;
16723 GNULIB_STRTOD=0;
16724 GNULIB_STRTOLL=0;
16725 GNULIB_STRTOULL=0;
16726 GNULIB_SYSTEM_POSIX=0;
16727 GNULIB_UNLOCKPT=0;
16728 GNULIB_UNSETENV=0;
16729 GNULIB_WCTOMB=0;
16730 HAVE__EXIT=1;
16731 HAVE_ATOLL=1;
16732 HAVE_CANONICALIZE_FILE_NAME=1;
16733 HAVE_DECL_GETLOADAVG=1;
16734 HAVE_GETSUBOPT=1;
16735 HAVE_GRANTPT=1;
16736 HAVE_MKDTEMP=1;
16737 HAVE_MKOSTEMP=1;
16738 HAVE_MKOSTEMPS=1;
16739 HAVE_MKSTEMP=1;
16740 HAVE_MKSTEMPS=1;
16741 HAVE_POSIX_OPENPT=1;
16742 HAVE_PTSNAME=1;
16743 HAVE_PTSNAME_R=1;
16744 HAVE_RANDOM=1;
16745 HAVE_RANDOM_H=1;
16746 HAVE_RANDOM_R=1;
16747 HAVE_REALPATH=1;
16748 HAVE_RPMATCH=1;
16749 HAVE_SETENV=1;
16750 HAVE_DECL_SETENV=1;
16751 HAVE_STRTOD=1;
16752 HAVE_STRTOLL=1;
16753 HAVE_STRTOULL=1;
16754 HAVE_STRUCT_RANDOM_DATA=1;
16755 HAVE_SYS_LOADAVG_H=0;
16756 HAVE_UNLOCKPT=1;
16757 HAVE_DECL_UNSETENV=1;
16758 REPLACE_CALLOC=0;
16759 REPLACE_CANONICALIZE_FILE_NAME=0;
16760 REPLACE_MALLOC=0;
16761 REPLACE_MBTOWC=0;
16762 REPLACE_MKSTEMP=0;
16763 REPLACE_PTSNAME_R=0;
16764 REPLACE_PUTENV=0;
16765 REPLACE_RANDOM_R=0;
16766 REPLACE_REALLOC=0;
16767 REPLACE_REALPATH=0;
16768 REPLACE_SETENV=0;
16769 REPLACE_STRTOD=0;
16770 REPLACE_UNSETENV=0;
16771 REPLACE_WCTOMB=0;
16772
16773
16774
16775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16776 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16777 if test "${gl_cv_have_include_next+set}" = set; then :
16778 $as_echo_n "(cached) " >&6
16779 else
16780 rm -rf conftestd1a conftestd1b conftestd2
16781 mkdir conftestd1a conftestd1b conftestd2
16782 cat <<EOF > conftestd1a/conftest.h
16783 #define DEFINED_IN_CONFTESTD1
16784 #include_next <conftest.h>
16785 #ifdef DEFINED_IN_CONFTESTD2
16786 int foo;
16787 #else
16788 #error "include_next doesn't work"
16789 #endif
16790 EOF
16791 cat <<EOF > conftestd1b/conftest.h
16792 #define DEFINED_IN_CONFTESTD1
16793 #include <stdio.h>
16794 #include_next <conftest.h>
16795 #ifdef DEFINED_IN_CONFTESTD2
16796 int foo;
16797 #else
16798 #error "include_next doesn't work"
16799 #endif
16800 EOF
16801 cat <<EOF > conftestd2/conftest.h
16802 #ifndef DEFINED_IN_CONFTESTD1
16803 #error "include_next test doesn't work"
16804 #endif
16805 #define DEFINED_IN_CONFTESTD2
16806 EOF
16807 gl_save_CPPFLAGS="$CPPFLAGS"
16808 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16810 /* end confdefs.h. */
16811 #include <conftest.h>
16812 _ACEOF
16813 if ac_fn_c_try_compile "$LINENO"; then :
16814 gl_cv_have_include_next=yes
16815 else
16816 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16818 /* end confdefs.h. */
16819 #include <conftest.h>
16820 _ACEOF
16821 if ac_fn_c_try_compile "$LINENO"; then :
16822 gl_cv_have_include_next=buggy
16823 else
16824 gl_cv_have_include_next=no
16825 fi
16826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16827
16828 fi
16829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16830 CPPFLAGS="$gl_save_CPPFLAGS"
16831 rm -rf conftestd1a conftestd1b conftestd2
16832
16833 fi
16834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16835 $as_echo "$gl_cv_have_include_next" >&6; }
16836 PRAGMA_SYSTEM_HEADER=
16837 if test $gl_cv_have_include_next = yes; then
16838 INCLUDE_NEXT=include_next
16839 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16840 if test -n "$GCC"; then
16841 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16842 fi
16843 else
16844 if test $gl_cv_have_include_next = buggy; then
16845 INCLUDE_NEXT=include
16846 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16847 else
16848 INCLUDE_NEXT=include
16849 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16850 fi
16851 fi
16852
16853
16854
16855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16856 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16857 if test "${gl_cv_pragma_columns+set}" = set; then :
16858 $as_echo_n "(cached) " >&6
16859 else
16860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16861 /* end confdefs.h. */
16862
16863 #ifdef __TANDEM
16864 choke me
16865 #endif
16866
16867 _ACEOF
16868 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16869 $EGREP "choke me" >/dev/null 2>&1; then :
16870 gl_cv_pragma_columns=yes
16871 else
16872 gl_cv_pragma_columns=no
16873 fi
16874 rm -f conftest*
16875
16876
16877 fi
16878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16879 $as_echo "$gl_cv_pragma_columns" >&6; }
16880 if test $gl_cv_pragma_columns = yes; then
16881 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16882 else
16883 PRAGMA_COLUMNS=
16884 fi
16885
16886
16887
16888
16889
16890
16891
16892
16893
16894
16895
16896
16897
16898
16899
16900
16901
16902 if test $gl_cv_have_include_next = yes; then
16903 gl_cv_next_getopt_h='<'getopt.h'>'
16904 else
16905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16906 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
16907 if test "${gl_cv_next_getopt_h+set}" = set; then :
16908 $as_echo_n "(cached) " >&6
16909 else
16910
16911 if test $ac_cv_header_getopt_h = yes; then
16912
16913
16914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16915 /* end confdefs.h. */
16916 #include <getopt.h>
16917
16918 _ACEOF
16919 case "$host_os" in
16920 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16921 *) gl_absname_cpp="$ac_cpp" ;;
16922 esac
16923
16924 case "$host_os" in
16925 mingw*)
16926 gl_dirsep_regex='[/\\]'
16927 ;;
16928 *)
16929 gl_dirsep_regex='\/'
16930 ;;
16931 esac
16932 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16933
16934 gl_header_literal_regex=`echo 'getopt.h' \
16935 | sed -e "$gl_make_literal_regex_sed"`
16936 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16937 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16938 s|^/[^/]|//&|
16939 p
16940 q
16941 }'
16942 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16943 sed -n "$gl_absolute_header_sed"`'"'
16944 else
16945 gl_cv_next_getopt_h='<'getopt.h'>'
16946 fi
16947
16948
16949 fi
16950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
16951 $as_echo "$gl_cv_next_getopt_h" >&6; }
16952 fi
16953 NEXT_GETOPT_H=$gl_cv_next_getopt_h
16954
16955 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16956 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16957 gl_next_as_first_directive='<'getopt.h'>'
16958 else
16959 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16960 gl_next_as_first_directive=$gl_cv_next_getopt_h
16961 fi
16962 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
16963
16964
16965
16966
16967 if test $ac_cv_header_getopt_h = yes; then
16968 HAVE_GETOPT_H=1
16969 else
16970 HAVE_GETOPT_H=0
16971 fi
16972
16973
16974 gl_replace_getopt=
16975
16976 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16977 for ac_header in getopt.h
16978 do :
16979 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
16980 if test "x$ac_cv_header_getopt_h" = x""yes; then :
16981 cat >>confdefs.h <<_ACEOF
16982 #define HAVE_GETOPT_H 1
16983 _ACEOF
16984
16985 else
16986 gl_replace_getopt=yes
16987 fi
16988
16989 done
16990
16991 fi
16992
16993 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16994 for ac_func in getopt_long_only
16995 do :
16996 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
16997 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
16998 cat >>confdefs.h <<_ACEOF
16999 #define HAVE_GETOPT_LONG_ONLY 1
17000 _ACEOF
17001
17002 else
17003 gl_replace_getopt=yes
17004 fi
17005 done
17006
17007 fi
17008
17009 if test -z "$gl_replace_getopt"; then
17010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17011 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17012 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17013 $as_echo_n "(cached) " >&6
17014 else
17015
17016 if test $cross_compiling = no; then
17017 if test "$cross_compiling" = yes; then :
17018 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17019 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17020 as_fn_error "cannot run test program while cross compiling
17021 See \`config.log' for more details." "$LINENO" 5; }
17022 else
17023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17024 /* end confdefs.h. */
17025
17026 #include <unistd.h>
17027 #include <stdlib.h>
17028 #include <string.h>
17029
17030 int
17031 main ()
17032 {
17033 static char program[] = "program";
17034 static char a[] = "-a";
17035 static char foo[] = "foo";
17036 static char bar[] = "bar";
17037 char *argv[] = { program, a, foo, bar, NULL };
17038 int c;
17039
17040 c = getopt (4, argv, "ab");
17041 if (!(c == 'a'))
17042 return 1;
17043 c = getopt (4, argv, "ab");
17044 if (!(c == -1))
17045 return 2;
17046 if (!(optind == 2))
17047 return 3;
17048 return 0;
17049 }
17050
17051 _ACEOF
17052 if ac_fn_c_try_run "$LINENO"; then :
17053 gl_cv_func_getopt_posix=maybe
17054 else
17055 gl_cv_func_getopt_posix=no
17056 fi
17057 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17058 conftest.$ac_objext conftest.beam conftest.$ac_ext
17059 fi
17060
17061 if test $gl_cv_func_getopt_posix = maybe; then
17062 if test "$cross_compiling" = yes; then :
17063 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17064 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17065 as_fn_error "cannot run test program while cross compiling
17066 See \`config.log' for more details." "$LINENO" 5; }
17067 else
17068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17069 /* end confdefs.h. */
17070
17071 #include <unistd.h>
17072 #include <stdlib.h>
17073 #include <string.h>
17074
17075 int
17076 main ()
17077 {
17078 static char program[] = "program";
17079 static char donald[] = "donald";
17080 static char p[] = "-p";
17081 static char billy[] = "billy";
17082 static char duck[] = "duck";
17083 static char a[] = "-a";
17084 static char bar[] = "bar";
17085 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17086 int c;
17087
17088 c = getopt (7, argv, "+abp:q:");
17089 if (!(c == -1))
17090 return 4;
17091 if (!(strcmp (argv[0], "program") == 0))
17092 return 5;
17093 if (!(strcmp (argv[1], "donald") == 0))
17094 return 6;
17095 if (!(strcmp (argv[2], "-p") == 0))
17096 return 7;
17097 if (!(strcmp (argv[3], "billy") == 0))
17098 return 8;
17099 if (!(strcmp (argv[4], "duck") == 0))
17100 return 9;
17101 if (!(strcmp (argv[5], "-a") == 0))
17102 return 10;
17103 if (!(strcmp (argv[6], "bar") == 0))
17104 return 11;
17105 if (!(optind == 1))
17106 return 12;
17107 return 0;
17108 }
17109
17110 _ACEOF
17111 if ac_fn_c_try_run "$LINENO"; then :
17112 gl_cv_func_getopt_posix=maybe
17113 else
17114 gl_cv_func_getopt_posix=no
17115 fi
17116 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17117 conftest.$ac_objext conftest.beam conftest.$ac_ext
17118 fi
17119
17120 fi
17121 if test $gl_cv_func_getopt_posix = maybe; then
17122 if test "$cross_compiling" = yes; then :
17123 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17124 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17125 as_fn_error "cannot run test program while cross compiling
17126 See \`config.log' for more details." "$LINENO" 5; }
17127 else
17128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17129 /* end confdefs.h. */
17130
17131 #include <unistd.h>
17132 #include <stdlib.h>
17133 #include <string.h>
17134
17135 int
17136 main ()
17137 {
17138 static char program[] = "program";
17139 static char ab[] = "-ab";
17140 char *argv[3] = { program, ab, NULL };
17141 if (getopt (2, argv, "ab:") != 'a')
17142 return 13;
17143 if (getopt (2, argv, "ab:") != '?')
17144 return 14;
17145 if (optopt != 'b')
17146 return 15;
17147 if (optind != 2)
17148 return 16;
17149 return 0;
17150 }
17151
17152 _ACEOF
17153 if ac_fn_c_try_run "$LINENO"; then :
17154 gl_cv_func_getopt_posix=yes
17155 else
17156 gl_cv_func_getopt_posix=no
17157 fi
17158 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17159 conftest.$ac_objext conftest.beam conftest.$ac_ext
17160 fi
17161
17162 fi
17163 else
17164 case "$host_os" in
17165 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17166 *) gl_cv_func_getopt_posix="guessing yes";;
17167 esac
17168 fi
17169
17170 fi
17171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17172 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17173 case "$gl_cv_func_getopt_posix" in
17174 *no) gl_replace_getopt=yes ;;
17175 esac
17176 fi
17177
17178 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17180 $as_echo_n "checking for working GNU getopt function... " >&6; }
17181 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17182 $as_echo_n "(cached) " >&6
17183 else
17184 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17185 # optstring is necessary for programs like m4 that have POSIX-mandated
17186 # semantics for supporting options interspersed with files.
17187 # Also, since getopt_long is a GNU extension, we require optind=0.
17188 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17189 # so take care to revert to the correct (non-)export state.
17190 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17191 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17192 xx) gl_had_POSIXLY_CORRECT=exported ;;
17193 x) gl_had_POSIXLY_CORRECT=yes ;;
17194 *) gl_had_POSIXLY_CORRECT= ;;
17195 esac
17196 POSIXLY_CORRECT=1
17197 export POSIXLY_CORRECT
17198 if test "$cross_compiling" = yes; then :
17199 gl_cv_func_getopt_gnu="guessing no"
17200
17201 else
17202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17203 /* end confdefs.h. */
17204 #include <getopt.h>
17205 #include <stddef.h>
17206 #include <string.h>
17207
17208 #include <stdlib.h>
17209 #if defined __MACH__ && defined __APPLE__
17210 /* Avoid a crash on Mac OS X. */
17211 #include <mach/mach.h>
17212 #include <mach/mach_error.h>
17213 #include <mach/thread_status.h>
17214 #include <mach/exception.h>
17215 #include <mach/task.h>
17216 #include <pthread.h>
17217 /* The exception port on which our thread listens. */
17218 static mach_port_t our_exception_port;
17219 /* The main function of the thread listening for exceptions of type
17220 EXC_BAD_ACCESS. */
17221 static void *
17222 mach_exception_thread (void *arg)
17223 {
17224 /* Buffer for a message to be received. */
17225 struct {
17226 mach_msg_header_t head;
17227 mach_msg_body_t msgh_body;
17228 char data[1024];
17229 } msg;
17230 mach_msg_return_t retval;
17231 /* Wait for a message on the exception port. */
17232 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17233 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17234 if (retval != MACH_MSG_SUCCESS)
17235 abort ();
17236 exit (1);
17237 }
17238 static void
17239 nocrash_init (void)
17240 {
17241 mach_port_t self = mach_task_self ();
17242 /* Allocate a port on which the thread shall listen for exceptions. */
17243 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17244 == KERN_SUCCESS) {
17245 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17246 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17247 MACH_MSG_TYPE_MAKE_SEND)
17248 == KERN_SUCCESS) {
17249 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17250 for us. */
17251 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17252 /* Create the thread listening on the exception port. */
17253 pthread_attr_t attr;
17254 pthread_t thread;
17255 if (pthread_attr_init (&attr) == 0
17256 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17257 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17258 pthread_attr_destroy (&attr);
17259 /* Replace the exception port info for these exceptions with our own.
17260 Note that we replace the exception port for the entire task, not only
17261 for a particular thread. This has the effect that when our exception
17262 port gets the message, the thread specific exception port has already
17263 been asked, and we don't need to bother about it.
17264 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17265 task_set_exception_ports (self, mask, our_exception_port,
17266 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17267 }
17268 }
17269 }
17270 }
17271 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17272 /* Avoid a crash on native Windows. */
17273 #define WIN32_LEAN_AND_MEAN
17274 #include <windows.h>
17275 #include <winerror.h>
17276 static LONG WINAPI
17277 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17278 {
17279 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17280 {
17281 case EXCEPTION_ACCESS_VIOLATION:
17282 case EXCEPTION_IN_PAGE_ERROR:
17283 case EXCEPTION_STACK_OVERFLOW:
17284 case EXCEPTION_GUARD_PAGE:
17285 case EXCEPTION_PRIV_INSTRUCTION:
17286 case EXCEPTION_ILLEGAL_INSTRUCTION:
17287 case EXCEPTION_DATATYPE_MISALIGNMENT:
17288 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17289 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17290 exit (1);
17291 }
17292 return EXCEPTION_CONTINUE_SEARCH;
17293 }
17294 static void
17295 nocrash_init (void)
17296 {
17297 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17298 }
17299 #else
17300 /* Avoid a crash on POSIX systems. */
17301 #include <signal.h>
17302 /* A POSIX signal handler. */
17303 static void
17304 exception_handler (int sig)
17305 {
17306 exit (1);
17307 }
17308 static void
17309 nocrash_init (void)
17310 {
17311 #ifdef SIGSEGV
17312 signal (SIGSEGV, exception_handler);
17313 #endif
17314 #ifdef SIGBUS
17315 signal (SIGBUS, exception_handler);
17316 #endif
17317 }
17318 #endif
17319
17320
17321 int
17322 main ()
17323 {
17324
17325 int result = 0;
17326
17327 nocrash_init();
17328
17329 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17330 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17331 OSF/1 5.1, Solaris 10. */
17332 {
17333 static char conftest[] = "conftest";
17334 static char plus[] = "-+";
17335 char *argv[3] = { conftest, plus, NULL };
17336 opterr = 0;
17337 if (getopt (2, argv, "+a") != '?')
17338 result |= 1;
17339 }
17340 /* This code succeeds on glibc 2.8, mingw,
17341 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17342 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17343 {
17344 static char program[] = "program";
17345 static char p[] = "-p";
17346 static char foo[] = "foo";
17347 static char bar[] = "bar";
17348 char *argv[] = { program, p, foo, bar, NULL };
17349
17350 optind = 1;
17351 if (getopt (4, argv, "p::") != 'p')
17352 result |= 2;
17353 else if (optarg != NULL)
17354 result |= 4;
17355 else if (getopt (4, argv, "p::") != -1)
17356 result |= 6;
17357 else if (optind != 2)
17358 result |= 8;
17359 }
17360 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17361 {
17362 static char program[] = "program";
17363 static char foo[] = "foo";
17364 static char p[] = "-p";
17365 char *argv[] = { program, foo, p, NULL };
17366 optind = 0;
17367 if (getopt (3, argv, "-p") != 1)
17368 result |= 16;
17369 else if (getopt (3, argv, "-p") != 'p')
17370 result |= 16;
17371 }
17372 /* This code fails on glibc 2.11. */
17373 {
17374 static char program[] = "program";
17375 static char b[] = "-b";
17376 static char a[] = "-a";
17377 char *argv[] = { program, b, a, NULL };
17378 optind = opterr = 0;
17379 if (getopt (3, argv, "+:a:b") != 'b')
17380 result |= 32;
17381 else if (getopt (3, argv, "+:a:b") != ':')
17382 result |= 32;
17383 }
17384 /* This code dumps core on glibc 2.14. */
17385 {
17386 static char program[] = "program";
17387 static char w[] = "-W";
17388 static char dummy[] = "dummy";
17389 char *argv[] = { program, w, dummy, NULL };
17390 optind = opterr = 1;
17391 if (getopt (3, argv, "W;") != 'W')
17392 result |= 64;
17393 }
17394 return result;
17395
17396 ;
17397 return 0;
17398 }
17399 _ACEOF
17400 if ac_fn_c_try_run "$LINENO"; then :
17401 gl_cv_func_getopt_gnu=yes
17402 else
17403 gl_cv_func_getopt_gnu=no
17404 fi
17405 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17406 conftest.$ac_objext conftest.beam conftest.$ac_ext
17407 fi
17408
17409 case $gl_had_POSIXLY_CORRECT in
17410 exported) ;;
17411 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17412 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17413 esac
17414
17415 fi
17416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17417 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17418 if test "$gl_cv_func_getopt_gnu" != yes; then
17419 gl_replace_getopt=yes
17420 else
17421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17422 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17423 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17424 $as_echo_n "(cached) " >&6
17425 else
17426 if test "$cross_compiling" = yes; then :
17427 case "$host_os" in
17428 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17429 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17430 esac
17431
17432 else
17433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17434 /* end confdefs.h. */
17435 #include <getopt.h>
17436 #include <stddef.h>
17437 #include <string.h>
17438
17439 int
17440 main ()
17441 {
17442 static const struct option long_options[] =
17443 {
17444 { "xtremely-",no_argument, NULL, 1003 },
17445 { "xtra", no_argument, NULL, 1001 },
17446 { "xtreme", no_argument, NULL, 1002 },
17447 { "xtremely", no_argument, NULL, 1003 },
17448 { NULL, 0, NULL, 0 }
17449 };
17450 /* This code fails on OpenBSD 5.0. */
17451 {
17452 static char program[] = "program";
17453 static char xtremel[] = "--xtremel";
17454 char *argv[] = { program, xtremel, NULL };
17455 int option_index;
17456 optind = 1; opterr = 0;
17457 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17458 return 1;
17459 }
17460 return 0;
17461
17462 ;
17463 return 0;
17464 }
17465 _ACEOF
17466 if ac_fn_c_try_run "$LINENO"; then :
17467 gl_cv_func_getopt_long_gnu=yes
17468 else
17469 gl_cv_func_getopt_long_gnu=no
17470 fi
17471 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17472 conftest.$ac_objext conftest.beam conftest.$ac_ext
17473 fi
17474
17475
17476 fi
17477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17478 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17479 case "$gl_cv_func_getopt_long_gnu" in
17480 *yes) ;;
17481 *) gl_replace_getopt=yes ;;
17482 esac
17483 fi
17484 fi
17485
17486
17487
17488
17489
17490
17491 REPLACE_GETOPT=0
17492 if test -n "$gl_replace_getopt"; then
17493 REPLACE_GETOPT=1
17494 fi
17495
17496 if test $REPLACE_GETOPT = 1; then
17497
17498 GETOPT_H=getopt.h
17499
17500 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17501
17502
17503
17504 fi
17505
17506 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17507 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17508 ac_have_decl=1
17509 else
17510 ac_have_decl=0
17511 fi
17512
17513 cat >>confdefs.h <<_ACEOF
17514 #define HAVE_DECL_GETENV $ac_have_decl
17515 _ACEOF
17516
17517 :
17518
17519
17520
17521
17522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17523 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17524 if test "${ac_cv_c_restrict+set}" = set; then :
17525 $as_echo_n "(cached) " >&6
17526 else
17527 ac_cv_c_restrict=no
17528 # The order here caters to the fact that C++ does not require restrict.
17529 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17531 /* end confdefs.h. */
17532 typedef int * int_ptr;
17533 int foo (int_ptr $ac_kw ip) {
17534 return ip[0];
17535 }
17536 int
17537 main ()
17538 {
17539 int s[1];
17540 int * $ac_kw t = s;
17541 t[0] = 0;
17542 return foo(t)
17543 ;
17544 return 0;
17545 }
17546 _ACEOF
17547 if ac_fn_c_try_compile "$LINENO"; then :
17548 ac_cv_c_restrict=$ac_kw
17549 fi
17550 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17551 test "$ac_cv_c_restrict" != no && break
17552 done
17553
17554 fi
17555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17556 $as_echo "$ac_cv_c_restrict" >&6; }
17557
17558 case $ac_cv_c_restrict in
17559 restrict) ;;
17560 no) $as_echo "#define restrict /**/" >>confdefs.h
17561 ;;
17562 *) cat >>confdefs.h <<_ACEOF
17563 #define restrict $ac_cv_c_restrict
17564 _ACEOF
17565 ;;
17566 esac
17567
17568
17569 GNULIB_GETTIMEOFDAY=0;
17570 HAVE_GETTIMEOFDAY=1;
17571 HAVE_STRUCT_TIMEVAL=1;
17572 HAVE_SYS_TIME_H=1;
17573 REPLACE_GETTIMEOFDAY=0;
17574 REPLACE_STRUCT_TIMEVAL=0;
17575
17576
17577
17578
17579
17580
17581
17582
17583
17584
17585
17586
17587
17588
17589
17590
17591 if test $gl_cv_have_include_next = yes; then
17592 gl_cv_next_sys_time_h='<'sys/time.h'>'
17593 else
17594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17595 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17596 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17597 $as_echo_n "(cached) " >&6
17598 else
17599
17600 if test $ac_cv_header_sys_time_h = yes; then
17601
17602
17603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17604 /* end confdefs.h. */
17605 #include <sys/time.h>
17606
17607 _ACEOF
17608 case "$host_os" in
17609 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17610 *) gl_absname_cpp="$ac_cpp" ;;
17611 esac
17612
17613 case "$host_os" in
17614 mingw*)
17615 gl_dirsep_regex='[/\\]'
17616 ;;
17617 *)
17618 gl_dirsep_regex='\/'
17619 ;;
17620 esac
17621 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17622
17623 gl_header_literal_regex=`echo 'sys/time.h' \
17624 | sed -e "$gl_make_literal_regex_sed"`
17625 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17626 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17627 s|^/[^/]|//&|
17628 p
17629 q
17630 }'
17631 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17632 sed -n "$gl_absolute_header_sed"`'"'
17633 else
17634 gl_cv_next_sys_time_h='<'sys/time.h'>'
17635 fi
17636
17637
17638 fi
17639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17640 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17641 fi
17642 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17643
17644 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17645 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17646 gl_next_as_first_directive='<'sys/time.h'>'
17647 else
17648 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17649 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17650 fi
17651 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17652
17653
17654
17655
17656
17657 if test $ac_cv_header_sys_time_h != yes; then
17658 HAVE_SYS_TIME_H=0
17659 fi
17660
17661
17662
17663
17664
17665 if test $ac_cv_header_sys_socket_h != yes; then
17666 for ac_header in winsock2.h
17667 do :
17668 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17669 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17670 cat >>confdefs.h <<_ACEOF
17671 #define HAVE_WINSOCK2_H 1
17672 _ACEOF
17673
17674 fi
17675
17676 done
17677
17678 fi
17679 if test "$ac_cv_header_winsock2_h" = yes; then
17680 HAVE_WINSOCK2_H=1
17681 UNISTD_H_HAVE_WINSOCK2_H=1
17682 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17683 else
17684 HAVE_WINSOCK2_H=0
17685 fi
17686
17687
17688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17689 $as_echo_n "checking for struct timeval... " >&6; }
17690 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17691 $as_echo_n "(cached) " >&6
17692 else
17693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17694 /* end confdefs.h. */
17695 #if HAVE_SYS_TIME_H
17696 #include <sys/time.h>
17697 #endif
17698 #include <time.h>
17699 #if HAVE_WINSOCK2_H
17700 # include <winsock2.h>
17701 #endif
17702
17703 int
17704 main ()
17705 {
17706 static struct timeval x; x.tv_sec = x.tv_usec;
17707 ;
17708 return 0;
17709 }
17710 _ACEOF
17711 if ac_fn_c_try_compile "$LINENO"; then :
17712 gl_cv_sys_struct_timeval=yes
17713 else
17714 gl_cv_sys_struct_timeval=no
17715 fi
17716 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17717
17718 fi
17719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
17720 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
17721 if test $gl_cv_sys_struct_timeval != yes; then
17722 HAVE_STRUCT_TIMEVAL=0
17723 else
17724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
17725 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
17726 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
17727 $as_echo_n "(cached) " >&6
17728 else
17729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17730 /* end confdefs.h. */
17731 #if HAVE_SYS_TIME_H
17732 #include <sys/time.h>
17733 #endif
17734 #include <time.h>
17735 #if HAVE_WINSOCK2_H
17736 # include <winsock2.h>
17737 #endif
17738
17739 int
17740 main ()
17741 {
17742 static struct timeval x;
17743 typedef int verify_tv_sec_type[
17744 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
17745 ];
17746
17747 ;
17748 return 0;
17749 }
17750 _ACEOF
17751 if ac_fn_c_try_compile "$LINENO"; then :
17752 gl_cv_sys_struct_timeval_tv_sec=yes
17753 else
17754 gl_cv_sys_struct_timeval_tv_sec=no
17755 fi
17756 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17757
17758 fi
17759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
17760 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
17761 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
17762 REPLACE_STRUCT_TIMEVAL=1
17763 fi
17764 fi
17765
17766
17767
17768
17769
17770
17771
17772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17773 $as_echo_n "checking for unsigned long long int... " >&6; }
17774 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17775 $as_echo_n "(cached) " >&6
17776 else
17777 ac_cv_type_unsigned_long_long_int=yes
17778 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17780 /* end confdefs.h. */
17781
17782 /* For now, do not test the preprocessor; as of 2007 there are too many
17783 implementations with broken preprocessors. Perhaps this can
17784 be revisited in 2012. In the meantime, code should not expect
17785 #if to work with literals wider than 32 bits. */
17786 /* Test literals. */
17787 long long int ll = 9223372036854775807ll;
17788 long long int nll = -9223372036854775807LL;
17789 unsigned long long int ull = 18446744073709551615ULL;
17790 /* Test constant expressions. */
17791 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17792 ? 1 : -1)];
17793 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17794 ? 1 : -1)];
17795 int i = 63;
17796 int
17797 main ()
17798 {
17799 /* Test availability of runtime routines for shift and division. */
17800 long long int llmax = 9223372036854775807ll;
17801 unsigned long long int ullmax = 18446744073709551615ull;
17802 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17803 | (llmax / ll) | (llmax % ll)
17804 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17805 | (ullmax / ull) | (ullmax % ull));
17806 ;
17807 return 0;
17808 }
17809
17810 _ACEOF
17811 if ac_fn_c_try_link "$LINENO"; then :
17812
17813 else
17814 ac_cv_type_unsigned_long_long_int=no
17815 fi
17816 rm -f core conftest.err conftest.$ac_objext \
17817 conftest$ac_exeext conftest.$ac_ext
17818 fi
17819 fi
17820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17821 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17822 if test $ac_cv_type_unsigned_long_long_int = yes; then
17823
17824 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17825
17826 fi
17827
17828
17829
17830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17831 $as_echo_n "checking for long long int... " >&6; }
17832 if test "${ac_cv_type_long_long_int+set}" = set; then :
17833 $as_echo_n "(cached) " >&6
17834 else
17835 ac_cv_type_long_long_int=yes
17836 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17837 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17838 if test $ac_cv_type_long_long_int = yes; then
17839 if test "$cross_compiling" = yes; then :
17840 :
17841 else
17842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17843 /* end confdefs.h. */
17844 #include <limits.h>
17845 #ifndef LLONG_MAX
17846 # define HALF \
17847 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17848 # define LLONG_MAX (HALF - 1 + HALF)
17849 #endif
17850 int
17851 main ()
17852 {
17853 long long int n = 1;
17854 int i;
17855 for (i = 0; ; i++)
17856 {
17857 long long int m = n << i;
17858 if (m >> i != n)
17859 return 1;
17860 if (LLONG_MAX / 2 < m)
17861 break;
17862 }
17863 return 0;
17864 ;
17865 return 0;
17866 }
17867 _ACEOF
17868 if ac_fn_c_try_run "$LINENO"; then :
17869
17870 else
17871 ac_cv_type_long_long_int=no
17872 fi
17873 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17874 conftest.$ac_objext conftest.beam conftest.$ac_ext
17875 fi
17876
17877 fi
17878 fi
17879 fi
17880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17881 $as_echo "$ac_cv_type_long_long_int" >&6; }
17882 if test $ac_cv_type_long_long_int = yes; then
17883
17884 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
17885
17886 fi
17887
17888
17889
17890
17891
17892
17893 gl_cv_c_multiarch=no
17894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17895 /* end confdefs.h. */
17896 #ifndef __APPLE_CC__
17897 not a universal capable compiler
17898 #endif
17899 typedef int dummy;
17900
17901 _ACEOF
17902 if ac_fn_c_try_compile "$LINENO"; then :
17903
17904 arch=
17905 prev=
17906 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17907 if test -n "$prev"; then
17908 case $word in
17909 i?86 | x86_64 | ppc | ppc64)
17910 if test -z "$arch" || test "$arch" = "$word"; then
17911 arch="$word"
17912 else
17913 gl_cv_c_multiarch=yes
17914 fi
17915 ;;
17916 esac
17917 prev=
17918 else
17919 if test "x$word" = "x-arch"; then
17920 prev=arch
17921 fi
17922 fi
17923 done
17924
17925 fi
17926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17927 if test $gl_cv_c_multiarch = yes; then
17928 APPLE_UNIVERSAL_BUILD=1
17929 else
17930 APPLE_UNIVERSAL_BUILD=0
17931 fi
17932
17933
17934
17935
17936
17937 if test $ac_cv_type_long_long_int = yes; then
17938 HAVE_LONG_LONG_INT=1
17939 else
17940 HAVE_LONG_LONG_INT=0
17941 fi
17942
17943
17944 if test $ac_cv_type_unsigned_long_long_int = yes; then
17945 HAVE_UNSIGNED_LONG_LONG_INT=1
17946 else
17947 HAVE_UNSIGNED_LONG_LONG_INT=0
17948 fi
17949
17950
17951
17952 if test $ac_cv_header_wchar_h = yes; then
17953 HAVE_WCHAR_H=1
17954 else
17955 HAVE_WCHAR_H=0
17956 fi
17957
17958
17959 if test $ac_cv_header_inttypes_h = yes; then
17960 HAVE_INTTYPES_H=1
17961 else
17962 HAVE_INTTYPES_H=0
17963 fi
17964
17965
17966 if test $ac_cv_header_sys_types_h = yes; then
17967 HAVE_SYS_TYPES_H=1
17968 else
17969 HAVE_SYS_TYPES_H=0
17970 fi
17971
17972
17973
17974
17975
17976
17977
17978
17979
17980
17981
17982 if test $gl_cv_have_include_next = yes; then
17983 gl_cv_next_stdint_h='<'stdint.h'>'
17984 else
17985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17986 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
17987 if test "${gl_cv_next_stdint_h+set}" = set; then :
17988 $as_echo_n "(cached) " >&6
17989 else
17990
17991 if test $ac_cv_header_stdint_h = yes; then
17992
17993
17994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17995 /* end confdefs.h. */
17996 #include <stdint.h>
17997
17998 _ACEOF
17999 case "$host_os" in
18000 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18001 *) gl_absname_cpp="$ac_cpp" ;;
18002 esac
18003
18004 case "$host_os" in
18005 mingw*)
18006 gl_dirsep_regex='[/\\]'
18007 ;;
18008 *)
18009 gl_dirsep_regex='\/'
18010 ;;
18011 esac
18012 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18013
18014 gl_header_literal_regex=`echo 'stdint.h' \
18015 | sed -e "$gl_make_literal_regex_sed"`
18016 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18017 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18018 s|^/[^/]|//&|
18019 p
18020 q
18021 }'
18022 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18023 sed -n "$gl_absolute_header_sed"`'"'
18024 else
18025 gl_cv_next_stdint_h='<'stdint.h'>'
18026 fi
18027
18028
18029 fi
18030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18031 $as_echo "$gl_cv_next_stdint_h" >&6; }
18032 fi
18033 NEXT_STDINT_H=$gl_cv_next_stdint_h
18034
18035 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18036 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18037 gl_next_as_first_directive='<'stdint.h'>'
18038 else
18039 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18040 gl_next_as_first_directive=$gl_cv_next_stdint_h
18041 fi
18042 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18043
18044
18045
18046
18047 if test $ac_cv_header_stdint_h = yes; then
18048 HAVE_STDINT_H=1
18049 else
18050 HAVE_STDINT_H=0
18051 fi
18052
18053
18054 if test $ac_cv_header_stdint_h = yes; then
18055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18056 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18057 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18058 $as_echo_n "(cached) " >&6
18059 else
18060 gl_cv_header_working_stdint_h=no
18061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18062 /* end confdefs.h. */
18063
18064
18065 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18066 #include <stdint.h>
18067 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18068 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18069 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18070 #endif
18071
18072
18073 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18074 included before <wchar.h>. */
18075 #include <stddef.h>
18076 #include <signal.h>
18077 #if HAVE_WCHAR_H
18078 # include <stdio.h>
18079 # include <time.h>
18080 # include <wchar.h>
18081 #endif
18082
18083
18084 #ifdef INT8_MAX
18085 int8_t a1 = INT8_MAX;
18086 int8_t a1min = INT8_MIN;
18087 #endif
18088 #ifdef INT16_MAX
18089 int16_t a2 = INT16_MAX;
18090 int16_t a2min = INT16_MIN;
18091 #endif
18092 #ifdef INT32_MAX
18093 int32_t a3 = INT32_MAX;
18094 int32_t a3min = INT32_MIN;
18095 #endif
18096 #ifdef INT64_MAX
18097 int64_t a4 = INT64_MAX;
18098 int64_t a4min = INT64_MIN;
18099 #endif
18100 #ifdef UINT8_MAX
18101 uint8_t b1 = UINT8_MAX;
18102 #else
18103 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18104 #endif
18105 #ifdef UINT16_MAX
18106 uint16_t b2 = UINT16_MAX;
18107 #endif
18108 #ifdef UINT32_MAX
18109 uint32_t b3 = UINT32_MAX;
18110 #endif
18111 #ifdef UINT64_MAX
18112 uint64_t b4 = UINT64_MAX;
18113 #endif
18114 int_least8_t c1 = INT8_C (0x7f);
18115 int_least8_t c1max = INT_LEAST8_MAX;
18116 int_least8_t c1min = INT_LEAST8_MIN;
18117 int_least16_t c2 = INT16_C (0x7fff);
18118 int_least16_t c2max = INT_LEAST16_MAX;
18119 int_least16_t c2min = INT_LEAST16_MIN;
18120 int_least32_t c3 = INT32_C (0x7fffffff);
18121 int_least32_t c3max = INT_LEAST32_MAX;
18122 int_least32_t c3min = INT_LEAST32_MIN;
18123 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18124 int_least64_t c4max = INT_LEAST64_MAX;
18125 int_least64_t c4min = INT_LEAST64_MIN;
18126 uint_least8_t d1 = UINT8_C (0xff);
18127 uint_least8_t d1max = UINT_LEAST8_MAX;
18128 uint_least16_t d2 = UINT16_C (0xffff);
18129 uint_least16_t d2max = UINT_LEAST16_MAX;
18130 uint_least32_t d3 = UINT32_C (0xffffffff);
18131 uint_least32_t d3max = UINT_LEAST32_MAX;
18132 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18133 uint_least64_t d4max = UINT_LEAST64_MAX;
18134 int_fast8_t e1 = INT_FAST8_MAX;
18135 int_fast8_t e1min = INT_FAST8_MIN;
18136 int_fast16_t e2 = INT_FAST16_MAX;
18137 int_fast16_t e2min = INT_FAST16_MIN;
18138 int_fast32_t e3 = INT_FAST32_MAX;
18139 int_fast32_t e3min = INT_FAST32_MIN;
18140 int_fast64_t e4 = INT_FAST64_MAX;
18141 int_fast64_t e4min = INT_FAST64_MIN;
18142 uint_fast8_t f1 = UINT_FAST8_MAX;
18143 uint_fast16_t f2 = UINT_FAST16_MAX;
18144 uint_fast32_t f3 = UINT_FAST32_MAX;
18145 uint_fast64_t f4 = UINT_FAST64_MAX;
18146 #ifdef INTPTR_MAX
18147 intptr_t g = INTPTR_MAX;
18148 intptr_t gmin = INTPTR_MIN;
18149 #endif
18150 #ifdef UINTPTR_MAX
18151 uintptr_t h = UINTPTR_MAX;
18152 #endif
18153 intmax_t i = INTMAX_MAX;
18154 uintmax_t j = UINTMAX_MAX;
18155
18156 #include <limits.h> /* for CHAR_BIT */
18157 #define TYPE_MINIMUM(t) \
18158 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18159 #define TYPE_MAXIMUM(t) \
18160 ((t) ((t) 0 < (t) -1 \
18161 ? (t) -1 \
18162 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18163 struct s {
18164 int check_PTRDIFF:
18165 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18166 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18167 ? 1 : -1;
18168 /* Detect bug in FreeBSD 6.0 / ia64. */
18169 int check_SIG_ATOMIC:
18170 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18171 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18172 ? 1 : -1;
18173 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18174 int check_WCHAR:
18175 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18176 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18177 ? 1 : -1;
18178 /* Detect bug in mingw. */
18179 int check_WINT:
18180 WINT_MIN == TYPE_MINIMUM (wint_t)
18181 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18182 ? 1 : -1;
18183
18184 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18185 int check_UINT8_C:
18186 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18187 int check_UINT16_C:
18188 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18189
18190 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18191 #ifdef UINT8_MAX
18192 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18193 #endif
18194 #ifdef UINT16_MAX
18195 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18196 #endif
18197 #ifdef UINT32_MAX
18198 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18199 #endif
18200 #ifdef UINT64_MAX
18201 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18202 #endif
18203 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18204 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18205 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18206 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18207 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18208 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18209 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18210 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18211 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18212 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18213 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18214 };
18215
18216 int
18217 main ()
18218 {
18219
18220 ;
18221 return 0;
18222 }
18223 _ACEOF
18224 if ac_fn_c_try_compile "$LINENO"; then :
18225 if test "$cross_compiling" = yes; then :
18226 gl_cv_header_working_stdint_h=yes
18227
18228 else
18229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18230 /* end confdefs.h. */
18231
18232
18233 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18234 #include <stdint.h>
18235
18236
18237 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18238 included before <wchar.h>. */
18239 #include <stddef.h>
18240 #include <signal.h>
18241 #if HAVE_WCHAR_H
18242 # include <stdio.h>
18243 # include <time.h>
18244 # include <wchar.h>
18245 #endif
18246
18247
18248 #include <stdio.h>
18249 #include <string.h>
18250 #define MVAL(macro) MVAL1(macro)
18251 #define MVAL1(expression) #expression
18252 static const char *macro_values[] =
18253 {
18254 #ifdef INT8_MAX
18255 MVAL (INT8_MAX),
18256 #endif
18257 #ifdef INT16_MAX
18258 MVAL (INT16_MAX),
18259 #endif
18260 #ifdef INT32_MAX
18261 MVAL (INT32_MAX),
18262 #endif
18263 #ifdef INT64_MAX
18264 MVAL (INT64_MAX),
18265 #endif
18266 #ifdef UINT8_MAX
18267 MVAL (UINT8_MAX),
18268 #endif
18269 #ifdef UINT16_MAX
18270 MVAL (UINT16_MAX),
18271 #endif
18272 #ifdef UINT32_MAX
18273 MVAL (UINT32_MAX),
18274 #endif
18275 #ifdef UINT64_MAX
18276 MVAL (UINT64_MAX),
18277 #endif
18278 NULL
18279 };
18280
18281 int
18282 main ()
18283 {
18284
18285 const char **mv;
18286 for (mv = macro_values; *mv != NULL; mv++)
18287 {
18288 const char *value = *mv;
18289 /* Test whether it looks like a cast expression. */
18290 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18291 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18292 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18293 || strncmp (value, "((int)"/*)*/, 6) == 0
18294 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18295 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18296 return mv - macro_values + 1;
18297 }
18298 return 0;
18299
18300 ;
18301 return 0;
18302 }
18303 _ACEOF
18304 if ac_fn_c_try_run "$LINENO"; then :
18305 gl_cv_header_working_stdint_h=yes
18306 fi
18307 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18308 conftest.$ac_objext conftest.beam conftest.$ac_ext
18309 fi
18310
18311
18312 fi
18313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18314
18315 fi
18316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18317 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18318 fi
18319 if test "$gl_cv_header_working_stdint_h" = yes; then
18320 STDINT_H=
18321 else
18322 for ac_header in sys/inttypes.h sys/bitypes.h
18323 do :
18324 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18325 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18326 eval as_val=\$$as_ac_Header
18327 if test "x$as_val" = x""yes; then :
18328 cat >>confdefs.h <<_ACEOF
18329 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18330 _ACEOF
18331
18332 fi
18333
18334 done
18335
18336 if test $ac_cv_header_sys_inttypes_h = yes; then
18337 HAVE_SYS_INTTYPES_H=1
18338 else
18339 HAVE_SYS_INTTYPES_H=0
18340 fi
18341
18342 if test $ac_cv_header_sys_bitypes_h = yes; then
18343 HAVE_SYS_BITYPES_H=1
18344 else
18345 HAVE_SYS_BITYPES_H=0
18346 fi
18347
18348
18349
18350
18351 if test $APPLE_UNIVERSAL_BUILD = 0; then
18352
18353
18354 for gltype in ptrdiff_t size_t ; do
18355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18356 $as_echo_n "checking for bit size of $gltype... " >&6; }
18357 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18358 $as_echo_n "(cached) " >&6
18359 else
18360 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18361 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18362 included before <wchar.h>. */
18363 #include <stddef.h>
18364 #include <signal.h>
18365 #if HAVE_WCHAR_H
18366 # include <stdio.h>
18367 # include <time.h>
18368 # include <wchar.h>
18369 #endif
18370
18371 #include <limits.h>"; then :
18372
18373 else
18374 result=unknown
18375 fi
18376
18377 eval gl_cv_bitsizeof_${gltype}=\$result
18378
18379 fi
18380 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18382 $as_echo "$ac_res" >&6; }
18383 eval result=\$gl_cv_bitsizeof_${gltype}
18384 if test $result = unknown; then
18385 result=0
18386 fi
18387 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18388 cat >>confdefs.h <<_ACEOF
18389 #define BITSIZEOF_${GLTYPE} $result
18390 _ACEOF
18391
18392 eval BITSIZEOF_${GLTYPE}=\$result
18393 done
18394
18395
18396 fi
18397
18398
18399 for gltype in sig_atomic_t wchar_t wint_t ; do
18400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18401 $as_echo_n "checking for bit size of $gltype... " >&6; }
18402 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18403 $as_echo_n "(cached) " >&6
18404 else
18405 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18406 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18407 included before <wchar.h>. */
18408 #include <stddef.h>
18409 #include <signal.h>
18410 #if HAVE_WCHAR_H
18411 # include <stdio.h>
18412 # include <time.h>
18413 # include <wchar.h>
18414 #endif
18415
18416 #include <limits.h>"; then :
18417
18418 else
18419 result=unknown
18420 fi
18421
18422 eval gl_cv_bitsizeof_${gltype}=\$result
18423
18424 fi
18425 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18427 $as_echo "$ac_res" >&6; }
18428 eval result=\$gl_cv_bitsizeof_${gltype}
18429 if test $result = unknown; then
18430 result=0
18431 fi
18432 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18433 cat >>confdefs.h <<_ACEOF
18434 #define BITSIZEOF_${GLTYPE} $result
18435 _ACEOF
18436
18437 eval BITSIZEOF_${GLTYPE}=\$result
18438 done
18439
18440
18441
18442
18443 for gltype in sig_atomic_t wchar_t wint_t ; do
18444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18445 $as_echo_n "checking whether $gltype is signed... " >&6; }
18446 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18447 $as_echo_n "(cached) " >&6
18448 else
18449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18450 /* end confdefs.h. */
18451
18452 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18453 included before <wchar.h>. */
18454 #include <stddef.h>
18455 #include <signal.h>
18456 #if HAVE_WCHAR_H
18457 # include <stdio.h>
18458 # include <time.h>
18459 # include <wchar.h>
18460 #endif
18461
18462 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18463 int
18464 main ()
18465 {
18466
18467 ;
18468 return 0;
18469 }
18470 _ACEOF
18471 if ac_fn_c_try_compile "$LINENO"; then :
18472 result=yes
18473 else
18474 result=no
18475 fi
18476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18477 eval gl_cv_type_${gltype}_signed=\$result
18478
18479 fi
18480 eval ac_res=\$gl_cv_type_${gltype}_signed
18481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18482 $as_echo "$ac_res" >&6; }
18483 eval result=\$gl_cv_type_${gltype}_signed
18484 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18485 if test "$result" = yes; then
18486 cat >>confdefs.h <<_ACEOF
18487 #define HAVE_SIGNED_${GLTYPE} 1
18488 _ACEOF
18489
18490 eval HAVE_SIGNED_${GLTYPE}=1
18491 else
18492 eval HAVE_SIGNED_${GLTYPE}=0
18493 fi
18494 done
18495
18496
18497 gl_cv_type_ptrdiff_t_signed=yes
18498 gl_cv_type_size_t_signed=no
18499 if test $APPLE_UNIVERSAL_BUILD = 0; then
18500
18501
18502 for gltype in ptrdiff_t size_t ; do
18503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18504 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18505 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18506 $as_echo_n "(cached) " >&6
18507 else
18508 eval gl_cv_type_${gltype}_suffix=no
18509 eval result=\$gl_cv_type_${gltype}_signed
18510 if test "$result" = yes; then
18511 glsufu=
18512 else
18513 glsufu=u
18514 fi
18515 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18516 case $glsuf in
18517 '') gltype1='int';;
18518 l) gltype1='long int';;
18519 ll) gltype1='long long int';;
18520 i64) gltype1='__int64';;
18521 u) gltype1='unsigned int';;
18522 ul) gltype1='unsigned long int';;
18523 ull) gltype1='unsigned long long int';;
18524 ui64)gltype1='unsigned __int64';;
18525 esac
18526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18527 /* end confdefs.h. */
18528
18529 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18530 included before <wchar.h>. */
18531 #include <stddef.h>
18532 #include <signal.h>
18533 #if HAVE_WCHAR_H
18534 # include <stdio.h>
18535 # include <time.h>
18536 # include <wchar.h>
18537 #endif
18538
18539 extern $gltype foo;
18540 extern $gltype1 foo;
18541 int
18542 main ()
18543 {
18544
18545 ;
18546 return 0;
18547 }
18548 _ACEOF
18549 if ac_fn_c_try_compile "$LINENO"; then :
18550 eval gl_cv_type_${gltype}_suffix=\$glsuf
18551 fi
18552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18553 eval result=\$gl_cv_type_${gltype}_suffix
18554 test "$result" != no && break
18555 done
18556 fi
18557 eval ac_res=\$gl_cv_type_${gltype}_suffix
18558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18559 $as_echo "$ac_res" >&6; }
18560 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18561 eval result=\$gl_cv_type_${gltype}_suffix
18562 test "$result" = no && result=
18563 eval ${GLTYPE}_SUFFIX=\$result
18564 cat >>confdefs.h <<_ACEOF
18565 #define ${GLTYPE}_SUFFIX $result
18566 _ACEOF
18567
18568 done
18569
18570
18571 fi
18572
18573
18574 for gltype in sig_atomic_t wchar_t wint_t ; do
18575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18576 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18577 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18578 $as_echo_n "(cached) " >&6
18579 else
18580 eval gl_cv_type_${gltype}_suffix=no
18581 eval result=\$gl_cv_type_${gltype}_signed
18582 if test "$result" = yes; then
18583 glsufu=
18584 else
18585 glsufu=u
18586 fi
18587 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18588 case $glsuf in
18589 '') gltype1='int';;
18590 l) gltype1='long int';;
18591 ll) gltype1='long long int';;
18592 i64) gltype1='__int64';;
18593 u) gltype1='unsigned int';;
18594 ul) gltype1='unsigned long int';;
18595 ull) gltype1='unsigned long long int';;
18596 ui64)gltype1='unsigned __int64';;
18597 esac
18598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18599 /* end confdefs.h. */
18600
18601 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18602 included before <wchar.h>. */
18603 #include <stddef.h>
18604 #include <signal.h>
18605 #if HAVE_WCHAR_H
18606 # include <stdio.h>
18607 # include <time.h>
18608 # include <wchar.h>
18609 #endif
18610
18611 extern $gltype foo;
18612 extern $gltype1 foo;
18613 int
18614 main ()
18615 {
18616
18617 ;
18618 return 0;
18619 }
18620 _ACEOF
18621 if ac_fn_c_try_compile "$LINENO"; then :
18622 eval gl_cv_type_${gltype}_suffix=\$glsuf
18623 fi
18624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18625 eval result=\$gl_cv_type_${gltype}_suffix
18626 test "$result" != no && break
18627 done
18628 fi
18629 eval ac_res=\$gl_cv_type_${gltype}_suffix
18630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18631 $as_echo "$ac_res" >&6; }
18632 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18633 eval result=\$gl_cv_type_${gltype}_suffix
18634 test "$result" = no && result=
18635 eval ${GLTYPE}_SUFFIX=\$result
18636 cat >>confdefs.h <<_ACEOF
18637 #define ${GLTYPE}_SUFFIX $result
18638 _ACEOF
18639
18640 done
18641
18642
18643
18644 if test $BITSIZEOF_WINT_T -lt 32; then
18645 BITSIZEOF_WINT_T=32
18646 fi
18647
18648 STDINT_H=stdint.h
18649 fi
18650
18651 if test -n "$STDINT_H"; then
18652 GL_GENERATE_STDINT_H_TRUE=
18653 GL_GENERATE_STDINT_H_FALSE='#'
18654 else
18655 GL_GENERATE_STDINT_H_TRUE='#'
18656 GL_GENERATE_STDINT_H_FALSE=
18657 fi
18658
18659
18660
18661
18662
18663 GNULIB_IMAXABS=0;
18664 GNULIB_IMAXDIV=0;
18665 GNULIB_STRTOIMAX=0;
18666 GNULIB_STRTOUMAX=0;
18667 HAVE_DECL_IMAXABS=1;
18668 HAVE_DECL_IMAXDIV=1;
18669 HAVE_DECL_STRTOIMAX=1;
18670 HAVE_DECL_STRTOUMAX=1;
18671 REPLACE_STRTOIMAX=0;
18672 INT32_MAX_LT_INTMAX_MAX=1;
18673 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18674 PRI_MACROS_BROKEN=0;
18675 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18676 UINT32_MAX_LT_UINTMAX_MAX=1;
18677 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18678
18679
18680
18681
18682
18683
18684
18685
18686
18687
18688
18689
18690
18691
18692
18693 if test $gl_cv_have_include_next = yes; then
18694 gl_cv_next_inttypes_h='<'inttypes.h'>'
18695 else
18696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18697 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18698 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18699 $as_echo_n "(cached) " >&6
18700 else
18701
18702 if test $ac_cv_header_inttypes_h = yes; then
18703
18704
18705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18706 /* end confdefs.h. */
18707 #include <inttypes.h>
18708
18709 _ACEOF
18710 case "$host_os" in
18711 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18712 *) gl_absname_cpp="$ac_cpp" ;;
18713 esac
18714
18715 case "$host_os" in
18716 mingw*)
18717 gl_dirsep_regex='[/\\]'
18718 ;;
18719 *)
18720 gl_dirsep_regex='\/'
18721 ;;
18722 esac
18723 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18724
18725 gl_header_literal_regex=`echo 'inttypes.h' \
18726 | sed -e "$gl_make_literal_regex_sed"`
18727 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18728 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18729 s|^/[^/]|//&|
18730 p
18731 q
18732 }'
18733 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18734 sed -n "$gl_absolute_header_sed"`'"'
18735 else
18736 gl_cv_next_inttypes_h='<'inttypes.h'>'
18737 fi
18738
18739
18740 fi
18741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18742 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18743 fi
18744 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18745
18746 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18747 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18748 gl_next_as_first_directive='<'inttypes.h'>'
18749 else
18750 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18751 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18752 fi
18753 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18754
18755
18756
18757
18758
18759
18760
18761
18762
18763
18764
18765 case "$host_os" in
18766 mingw*)
18767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
18768 $as_echo_n "checking for 64-bit off_t... " >&6; }
18769 if test "${gl_cv_type_off_t_64+set}" = set; then :
18770 $as_echo_n "(cached) " >&6
18771 else
18772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18773 /* end confdefs.h. */
18774 #include <sys/types.h>
18775 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
18776
18777 int
18778 main ()
18779 {
18780
18781 ;
18782 return 0;
18783 }
18784 _ACEOF
18785 if ac_fn_c_try_compile "$LINENO"; then :
18786 gl_cv_type_off_t_64=yes
18787 else
18788 gl_cv_type_off_t_64=no
18789 fi
18790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18791
18792 fi
18793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
18794 $as_echo "$gl_cv_type_off_t_64" >&6; }
18795 if test $gl_cv_type_off_t_64 = no; then
18796 WINDOWS_64_BIT_OFF_T=1
18797 else
18798 WINDOWS_64_BIT_OFF_T=0
18799 fi
18800 WINDOWS_64_BIT_ST_SIZE=1
18801 ;;
18802 *)
18803 WINDOWS_64_BIT_OFF_T=0
18804 WINDOWS_64_BIT_ST_SIZE=0
18805 ;;
18806 esac
18807
18808
18809 GNULIB_FCHMODAT=0;
18810 GNULIB_FSTAT=0;
18811 GNULIB_FSTATAT=0;
18812 GNULIB_FUTIMENS=0;
18813 GNULIB_LCHMOD=0;
18814 GNULIB_LSTAT=0;
18815 GNULIB_MKDIRAT=0;
18816 GNULIB_MKFIFO=0;
18817 GNULIB_MKFIFOAT=0;
18818 GNULIB_MKNOD=0;
18819 GNULIB_MKNODAT=0;
18820 GNULIB_STAT=0;
18821 GNULIB_UTIMENSAT=0;
18822 HAVE_FCHMODAT=1;
18823 HAVE_FSTATAT=1;
18824 HAVE_FUTIMENS=1;
18825 HAVE_LCHMOD=1;
18826 HAVE_LSTAT=1;
18827 HAVE_MKDIRAT=1;
18828 HAVE_MKFIFO=1;
18829 HAVE_MKFIFOAT=1;
18830 HAVE_MKNOD=1;
18831 HAVE_MKNODAT=1;
18832 HAVE_UTIMENSAT=1;
18833 REPLACE_FSTAT=0;
18834 REPLACE_FSTATAT=0;
18835 REPLACE_FUTIMENS=0;
18836 REPLACE_LSTAT=0;
18837 REPLACE_MKDIR=0;
18838 REPLACE_MKFIFO=0;
18839 REPLACE_MKNOD=0;
18840 REPLACE_STAT=0;
18841 REPLACE_UTIMENSAT=0;
18842
18843
18844
18845
18846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18847 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18848 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18849 $as_echo_n "(cached) " >&6
18850 else
18851 rm -f conftest.sym conftest.file
18852 echo >conftest.file
18853 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18854 if test "$cross_compiling" = yes; then :
18855 case "$host_os" in
18856 # Guess yes on glibc systems.
18857 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18858 # If we don't know, assume the worst.
18859 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18860 esac
18861
18862 else
18863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18864 /* end confdefs.h. */
18865 $ac_includes_default
18866 int
18867 main ()
18868 {
18869 struct stat sbuf;
18870 /* Linux will dereference the symlink and fail, as required by
18871 POSIX. That is better in the sense that it means we will not
18872 have to compile and use the lstat wrapper. */
18873 return lstat ("conftest.sym/", &sbuf) == 0;
18874
18875 ;
18876 return 0;
18877 }
18878 _ACEOF
18879 if ac_fn_c_try_run "$LINENO"; then :
18880 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18881 else
18882 gl_cv_func_lstat_dereferences_slashed_symlink=no
18883 fi
18884 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18885 conftest.$ac_objext conftest.beam conftest.$ac_ext
18886 fi
18887
18888 else
18889 # If the 'ln -s' command failed, then we probably don't even
18890 # have an lstat function.
18891 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18892 fi
18893 rm -f conftest.sym conftest.file
18894
18895 fi
18896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18897 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18898 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18899 *yes)
18900
18901 cat >>confdefs.h <<_ACEOF
18902 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18903 _ACEOF
18904
18905 ;;
18906 esac
18907
18908
18909 GNULIB_MKTIME=0;
18910 GNULIB_NANOSLEEP=0;
18911 GNULIB_STRPTIME=0;
18912 GNULIB_TIMEGM=0;
18913 GNULIB_TIME_R=0;
18914 HAVE_DECL_LOCALTIME_R=1;
18915 HAVE_NANOSLEEP=1;
18916 HAVE_STRPTIME=1;
18917 HAVE_TIMEGM=1;
18918 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18919 REPLACE_MKTIME=GNULIB_PORTCHECK;
18920 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18921 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18922
18923
18924
18925
18926 GNULIB_PSELECT=0;
18927 GNULIB_SELECT=0;
18928 HAVE_PSELECT=1;
18929 REPLACE_PSELECT=0;
18930 REPLACE_SELECT=0;
18931
18932
18933
18934
18935
18936
18937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
18938 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
18939 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
18940 $as_echo_n "(cached) " >&6
18941 else
18942
18943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18944 /* end confdefs.h. */
18945 #include <sys/select.h>
18946 int
18947 main ()
18948 {
18949 struct timeval b;
18950 ;
18951 return 0;
18952 }
18953 _ACEOF
18954 if ac_fn_c_try_compile "$LINENO"; then :
18955 gl_cv_header_sys_select_h_selfcontained=yes
18956 else
18957 gl_cv_header_sys_select_h_selfcontained=no
18958 fi
18959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18960 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
18961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18962 /* end confdefs.h. */
18963 #include <sys/select.h>
18964 int
18965 main ()
18966 {
18967 int memset; int bzero;
18968 ;
18969 return 0;
18970 }
18971
18972 _ACEOF
18973 if ac_fn_c_try_compile "$LINENO"; then :
18974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18975 /* end confdefs.h. */
18976 #include <sys/select.h>
18977 int
18978 main ()
18979 {
18980
18981 #undef memset
18982 #define memset nonexistent_memset
18983 extern
18984 #ifdef __cplusplus
18985 "C"
18986 #endif
18987 void *memset (void *, int, unsigned long);
18988 #undef bzero
18989 #define bzero nonexistent_bzero
18990 extern
18991 #ifdef __cplusplus
18992 "C"
18993 #endif
18994 void bzero (void *, unsigned long);
18995 fd_set fds;
18996 FD_ZERO (&fds);
18997
18998 ;
18999 return 0;
19000 }
19001
19002 _ACEOF
19003 if ac_fn_c_try_link "$LINENO"; then :
19004
19005 else
19006 gl_cv_header_sys_select_h_selfcontained=no
19007 fi
19008 rm -f core conftest.err conftest.$ac_objext \
19009 conftest$ac_exeext conftest.$ac_ext
19010
19011 fi
19012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19013 fi
19014
19015 fi
19016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19017 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19018
19019
19020
19021
19022
19023
19024
19025
19026
19027 if test $gl_cv_have_include_next = yes; then
19028 gl_cv_next_sys_select_h='<'sys/select.h'>'
19029 else
19030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19031 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19032 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19033 $as_echo_n "(cached) " >&6
19034 else
19035
19036 if test $ac_cv_header_sys_select_h = yes; then
19037
19038
19039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19040 /* end confdefs.h. */
19041 #include <sys/select.h>
19042
19043 _ACEOF
19044 case "$host_os" in
19045 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19046 *) gl_absname_cpp="$ac_cpp" ;;
19047 esac
19048
19049 case "$host_os" in
19050 mingw*)
19051 gl_dirsep_regex='[/\\]'
19052 ;;
19053 *)
19054 gl_dirsep_regex='\/'
19055 ;;
19056 esac
19057 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19058
19059 gl_header_literal_regex=`echo 'sys/select.h' \
19060 | sed -e "$gl_make_literal_regex_sed"`
19061 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19062 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19063 s|^/[^/]|//&|
19064 p
19065 q
19066 }'
19067 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19068 sed -n "$gl_absolute_header_sed"`'"'
19069 else
19070 gl_cv_next_sys_select_h='<'sys/select.h'>'
19071 fi
19072
19073
19074 fi
19075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19076 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19077 fi
19078 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19079
19080 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19081 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19082 gl_next_as_first_directive='<'sys/select.h'>'
19083 else
19084 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19085 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19086 fi
19087 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19088
19089
19090
19091
19092 if test $ac_cv_header_sys_select_h = yes; then
19093 HAVE_SYS_SELECT_H=1
19094 else
19095 HAVE_SYS_SELECT_H=0
19096 fi
19097
19098
19099
19100
19101
19102 if test $ac_cv_header_sys_socket_h != yes; then
19103 for ac_header in winsock2.h
19104 do :
19105 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19106 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19107 cat >>confdefs.h <<_ACEOF
19108 #define HAVE_WINSOCK2_H 1
19109 _ACEOF
19110
19111 fi
19112
19113 done
19114
19115 fi
19116 if test "$ac_cv_header_winsock2_h" = yes; then
19117 HAVE_WINSOCK2_H=1
19118 UNISTD_H_HAVE_WINSOCK2_H=1
19119 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19120 else
19121 HAVE_WINSOCK2_H=0
19122 fi
19123
19124
19125
19126
19127
19128
19129
19130
19131 GNULIB_PTHREAD_SIGMASK=0;
19132 GNULIB_RAISE=0;
19133 GNULIB_SIGNAL_H_SIGPIPE=0;
19134 GNULIB_SIGPROCMASK=0;
19135 GNULIB_SIGACTION=0;
19136 HAVE_POSIX_SIGNALBLOCKING=1;
19137 HAVE_PTHREAD_SIGMASK=1;
19138 HAVE_RAISE=1;
19139 HAVE_SIGSET_T=1;
19140 HAVE_SIGINFO_T=1;
19141 HAVE_SIGACTION=1;
19142 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19143
19144 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19145
19146 HAVE_SIGHANDLER_T=1;
19147 REPLACE_PTHREAD_SIGMASK=0;
19148 REPLACE_RAISE=0;
19149
19150
19151
19152
19153
19154
19155 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19156 #include <signal.h>
19157 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19158 #include <sys/types.h>
19159
19160 "
19161 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19162
19163 cat >>confdefs.h <<_ACEOF
19164 #define HAVE_SIGSET_T 1
19165 _ACEOF
19166
19167 gl_cv_type_sigset_t=yes
19168 else
19169 gl_cv_type_sigset_t=no
19170 fi
19171
19172 if test $gl_cv_type_sigset_t != yes; then
19173 HAVE_SIGSET_T=0
19174 fi
19175
19176
19177
19178 if test $ac_cv_header_sys_socket_h = no; then
19179 for ac_header in ws2tcpip.h
19180 do :
19181 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19182 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19183 cat >>confdefs.h <<_ACEOF
19184 #define HAVE_WS2TCPIP_H 1
19185 _ACEOF
19186
19187 fi
19188
19189 done
19190
19191 fi
19192
19193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19194 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19195 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19196 $as_echo_n "(cached) " >&6
19197 else
19198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19199 /* end confdefs.h. */
19200
19201 #include <stdbool.h>
19202 #ifndef bool
19203 "error: bool is not defined"
19204 #endif
19205 #ifndef false
19206 "error: false is not defined"
19207 #endif
19208 #if false
19209 "error: false is not 0"
19210 #endif
19211 #ifndef true
19212 "error: true is not defined"
19213 #endif
19214 #if true != 1
19215 "error: true is not 1"
19216 #endif
19217 #ifndef __bool_true_false_are_defined
19218 "error: __bool_true_false_are_defined is not defined"
19219 #endif
19220
19221 struct s { _Bool s: 1; _Bool t; } s;
19222
19223 char a[true == 1 ? 1 : -1];
19224 char b[false == 0 ? 1 : -1];
19225 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19226 char d[(bool) 0.5 == true ? 1 : -1];
19227 /* See body of main program for 'e'. */
19228 char f[(_Bool) 0.0 == false ? 1 : -1];
19229 char g[true];
19230 char h[sizeof (_Bool)];
19231 char i[sizeof s.t];
19232 enum { j = false, k = true, l = false * true, m = true * 256 };
19233 /* The following fails for
19234 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19235 _Bool n[m];
19236 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19237 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19238 /* Catch a bug in an HP-UX C compiler. See
19239 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19240 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19241 */
19242 _Bool q = true;
19243 _Bool *pq = &q;
19244
19245 int
19246 main ()
19247 {
19248
19249 bool e = &s;
19250 *pq |= q;
19251 *pq |= ! q;
19252 /* Refer to every declared value, to avoid compiler optimizations. */
19253 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19254 + !m + !n + !o + !p + !q + !pq);
19255
19256 ;
19257 return 0;
19258 }
19259 _ACEOF
19260 if ac_fn_c_try_compile "$LINENO"; then :
19261 ac_cv_header_stdbool_h=yes
19262 else
19263 ac_cv_header_stdbool_h=no
19264 fi
19265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19266 fi
19267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19268 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19269 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19270 if test "x$ac_cv_type__Bool" = x""yes; then :
19271
19272 cat >>confdefs.h <<_ACEOF
19273 #define HAVE__BOOL 1
19274 _ACEOF
19275
19276
19277 fi
19278
19279
19280
19281 REPLACE_NULL=0;
19282 HAVE_WCHAR_T=1;
19283
19284
19285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19286 $as_echo_n "checking for wchar_t... " >&6; }
19287 if test "${gt_cv_c_wchar_t+set}" = set; then :
19288 $as_echo_n "(cached) " >&6
19289 else
19290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19291 /* end confdefs.h. */
19292 #include <stddef.h>
19293 wchar_t foo = (wchar_t)'\0';
19294 int
19295 main ()
19296 {
19297
19298 ;
19299 return 0;
19300 }
19301 _ACEOF
19302 if ac_fn_c_try_compile "$LINENO"; then :
19303 gt_cv_c_wchar_t=yes
19304 else
19305 gt_cv_c_wchar_t=no
19306 fi
19307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19308 fi
19309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19310 $as_echo "$gt_cv_c_wchar_t" >&6; }
19311 if test $gt_cv_c_wchar_t = yes; then
19312
19313 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19314
19315 fi
19316
19317
19318 GNULIB_DPRINTF=0;
19319 GNULIB_FCLOSE=0;
19320 GNULIB_FDOPEN=0;
19321 GNULIB_FFLUSH=0;
19322 GNULIB_FGETC=0;
19323 GNULIB_FGETS=0;
19324 GNULIB_FOPEN=0;
19325 GNULIB_FPRINTF=0;
19326 GNULIB_FPRINTF_POSIX=0;
19327 GNULIB_FPURGE=0;
19328 GNULIB_FPUTC=0;
19329 GNULIB_FPUTS=0;
19330 GNULIB_FREAD=0;
19331 GNULIB_FREOPEN=0;
19332 GNULIB_FSCANF=0;
19333 GNULIB_FSEEK=0;
19334 GNULIB_FSEEKO=0;
19335 GNULIB_FTELL=0;
19336 GNULIB_FTELLO=0;
19337 GNULIB_FWRITE=0;
19338 GNULIB_GETC=0;
19339 GNULIB_GETCHAR=0;
19340 GNULIB_GETDELIM=0;
19341 GNULIB_GETLINE=0;
19342 GNULIB_OBSTACK_PRINTF=0;
19343 GNULIB_OBSTACK_PRINTF_POSIX=0;
19344 GNULIB_PCLOSE=0;
19345 GNULIB_PERROR=0;
19346 GNULIB_POPEN=0;
19347 GNULIB_PRINTF=0;
19348 GNULIB_PRINTF_POSIX=0;
19349 GNULIB_PUTC=0;
19350 GNULIB_PUTCHAR=0;
19351 GNULIB_PUTS=0;
19352 GNULIB_REMOVE=0;
19353 GNULIB_RENAME=0;
19354 GNULIB_RENAMEAT=0;
19355 GNULIB_SCANF=0;
19356 GNULIB_SNPRINTF=0;
19357 GNULIB_SPRINTF_POSIX=0;
19358 GNULIB_STDIO_H_NONBLOCKING=0;
19359 GNULIB_STDIO_H_SIGPIPE=0;
19360 GNULIB_TMPFILE=0;
19361 GNULIB_VASPRINTF=0;
19362 GNULIB_VFSCANF=0;
19363 GNULIB_VSCANF=0;
19364 GNULIB_VDPRINTF=0;
19365 GNULIB_VFPRINTF=0;
19366 GNULIB_VFPRINTF_POSIX=0;
19367 GNULIB_VPRINTF=0;
19368 GNULIB_VPRINTF_POSIX=0;
19369 GNULIB_VSNPRINTF=0;
19370 GNULIB_VSPRINTF_POSIX=0;
19371 HAVE_DECL_FPURGE=1;
19372 HAVE_DECL_FSEEKO=1;
19373 HAVE_DECL_FTELLO=1;
19374 HAVE_DECL_GETDELIM=1;
19375 HAVE_DECL_GETLINE=1;
19376 HAVE_DECL_OBSTACK_PRINTF=1;
19377 HAVE_DECL_SNPRINTF=1;
19378 HAVE_DECL_VSNPRINTF=1;
19379 HAVE_DPRINTF=1;
19380 HAVE_FSEEKO=1;
19381 HAVE_FTELLO=1;
19382 HAVE_PCLOSE=1;
19383 HAVE_POPEN=1;
19384 HAVE_RENAMEAT=1;
19385 HAVE_VASPRINTF=1;
19386 HAVE_VDPRINTF=1;
19387 REPLACE_DPRINTF=0;
19388 REPLACE_FCLOSE=0;
19389 REPLACE_FDOPEN=0;
19390 REPLACE_FFLUSH=0;
19391 REPLACE_FOPEN=0;
19392 REPLACE_FPRINTF=0;
19393 REPLACE_FPURGE=0;
19394 REPLACE_FREOPEN=0;
19395 REPLACE_FSEEK=0;
19396 REPLACE_FSEEKO=0;
19397 REPLACE_FTELL=0;
19398 REPLACE_FTELLO=0;
19399 REPLACE_GETDELIM=0;
19400 REPLACE_GETLINE=0;
19401 REPLACE_OBSTACK_PRINTF=0;
19402 REPLACE_PERROR=0;
19403 REPLACE_POPEN=0;
19404 REPLACE_PRINTF=0;
19405 REPLACE_REMOVE=0;
19406 REPLACE_RENAME=0;
19407 REPLACE_RENAMEAT=0;
19408 REPLACE_SNPRINTF=0;
19409 REPLACE_SPRINTF=0;
19410 REPLACE_STDIO_READ_FUNCS=0;
19411 REPLACE_STDIO_WRITE_FUNCS=0;
19412 REPLACE_TMPFILE=0;
19413 REPLACE_VASPRINTF=0;
19414 REPLACE_VDPRINTF=0;
19415 REPLACE_VFPRINTF=0;
19416 REPLACE_VPRINTF=0;
19417 REPLACE_VSNPRINTF=0;
19418 REPLACE_VSPRINTF=0;
19419
19420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19421 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19422 if test "${ac_cv_struct_tm+set}" = set; then :
19423 $as_echo_n "(cached) " >&6
19424 else
19425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19426 /* end confdefs.h. */
19427 #include <sys/types.h>
19428 #include <time.h>
19429
19430 int
19431 main ()
19432 {
19433 struct tm tm;
19434 int *p = &tm.tm_sec;
19435 return !p;
19436 ;
19437 return 0;
19438 }
19439 _ACEOF
19440 if ac_fn_c_try_compile "$LINENO"; then :
19441 ac_cv_struct_tm=time.h
19442 else
19443 ac_cv_struct_tm=sys/time.h
19444 fi
19445 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19446 fi
19447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19448 $as_echo "$ac_cv_struct_tm" >&6; }
19449 if test $ac_cv_struct_tm = sys/time.h; then
19450
19451 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19452
19453 fi
19454
19455 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19456 #include <$ac_cv_struct_tm>
19457
19458 "
19459 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19460
19461 cat >>confdefs.h <<_ACEOF
19462 #define HAVE_STRUCT_TM_TM_ZONE 1
19463 _ACEOF
19464
19465
19466 fi
19467
19468 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19469
19470 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19471
19472 else
19473 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19474 "
19475 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19476 ac_have_decl=1
19477 else
19478 ac_have_decl=0
19479 fi
19480
19481 cat >>confdefs.h <<_ACEOF
19482 #define HAVE_DECL_TZNAME $ac_have_decl
19483 _ACEOF
19484
19485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19486 $as_echo_n "checking for tzname... " >&6; }
19487 if test "${ac_cv_var_tzname+set}" = set; then :
19488 $as_echo_n "(cached) " >&6
19489 else
19490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19491 /* end confdefs.h. */
19492 #include <time.h>
19493 #if !HAVE_DECL_TZNAME
19494 extern char *tzname[];
19495 #endif
19496
19497 int
19498 main ()
19499 {
19500 return tzname[0][0];
19501 ;
19502 return 0;
19503 }
19504 _ACEOF
19505 if ac_fn_c_try_link "$LINENO"; then :
19506 ac_cv_var_tzname=yes
19507 else
19508 ac_cv_var_tzname=no
19509 fi
19510 rm -f core conftest.err conftest.$ac_objext \
19511 conftest$ac_exeext conftest.$ac_ext
19512 fi
19513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19514 $as_echo "$ac_cv_var_tzname" >&6; }
19515 if test $ac_cv_var_tzname = yes; then
19516
19517 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19518
19519 fi
19520 fi
19521
19522
19523 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19524 "
19525 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19526
19527 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19528
19529 fi
19530
19531
19532
19533
19534 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19535 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19536 ac_have_decl=1
19537 else
19538 ac_have_decl=0
19539 fi
19540
19541 cat >>confdefs.h <<_ACEOF
19542 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19543 _ACEOF
19544
19545
19546
19547 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19548 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19549 ac_have_decl=1
19550 else
19551 ac_have_decl=0
19552 fi
19553
19554 cat >>confdefs.h <<_ACEOF
19555 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19556 _ACEOF
19557
19558
19559
19560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19561 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19562 if test "${ac_cv_header_stat_broken+set}" = set; then :
19563 $as_echo_n "(cached) " >&6
19564 else
19565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19566 /* end confdefs.h. */
19567 #include <sys/types.h>
19568 #include <sys/stat.h>
19569
19570 #if defined S_ISBLK && defined S_IFDIR
19571 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19572 #endif
19573
19574 #if defined S_ISBLK && defined S_IFCHR
19575 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19576 #endif
19577
19578 #if defined S_ISLNK && defined S_IFREG
19579 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19580 #endif
19581
19582 #if defined S_ISSOCK && defined S_IFREG
19583 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19584 #endif
19585
19586 _ACEOF
19587 if ac_fn_c_try_compile "$LINENO"; then :
19588 ac_cv_header_stat_broken=no
19589 else
19590 ac_cv_header_stat_broken=yes
19591 fi
19592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19593 fi
19594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19595 $as_echo "$ac_cv_header_stat_broken" >&6; }
19596 if test $ac_cv_header_stat_broken = yes; then
19597
19598 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19599
19600 fi
19601
19602
19603
19604 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19605 if test "x$ac_cv_type_mode_t" = x""yes; then :
19606
19607 else
19608
19609 cat >>confdefs.h <<_ACEOF
19610 #define mode_t int
19611 _ACEOF
19612
19613 fi
19614
19615
19616
19617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19618 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19619 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19620 $as_echo_n "(cached) " >&6
19621 else
19622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19623 /* end confdefs.h. */
19624 #include <time.h>
19625
19626 int
19627 main ()
19628 {
19629 static struct timespec x; x.tv_sec = x.tv_nsec;
19630 ;
19631 return 0;
19632 }
19633 _ACEOF
19634 if ac_fn_c_try_compile "$LINENO"; then :
19635 gl_cv_sys_struct_timespec_in_time_h=yes
19636 else
19637 gl_cv_sys_struct_timespec_in_time_h=no
19638 fi
19639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19640 fi
19641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19642 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19643
19644 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19645 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19646 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19647 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19648 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19649 else
19650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19651 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19652 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19653 $as_echo_n "(cached) " >&6
19654 else
19655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19656 /* end confdefs.h. */
19657 #include <sys/time.h>
19658
19659 int
19660 main ()
19661 {
19662 static struct timespec x; x.tv_sec = x.tv_nsec;
19663 ;
19664 return 0;
19665 }
19666 _ACEOF
19667 if ac_fn_c_try_compile "$LINENO"; then :
19668 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19669 else
19670 gl_cv_sys_struct_timespec_in_sys_time_h=no
19671 fi
19672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19673 fi
19674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19675 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19676 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19677 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19678 else
19679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19680 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19681 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19682 $as_echo_n "(cached) " >&6
19683 else
19684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19685 /* end confdefs.h. */
19686 #include <pthread.h>
19687
19688 int
19689 main ()
19690 {
19691 static struct timespec x; x.tv_sec = x.tv_nsec;
19692 ;
19693 return 0;
19694 }
19695 _ACEOF
19696 if ac_fn_c_try_compile "$LINENO"; then :
19697 gl_cv_sys_struct_timespec_in_pthread_h=yes
19698 else
19699 gl_cv_sys_struct_timespec_in_pthread_h=no
19700 fi
19701 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19702 fi
19703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19704 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19705 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19706 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19707 fi
19708 fi
19709 fi
19710
19711
19712
19713
19714
19715
19716
19717
19718
19719
19720
19721
19722
19723
19724
19725 if test $gl_cv_have_include_next = yes; then
19726 gl_cv_next_time_h='<'time.h'>'
19727 else
19728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19729 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19730 if test "${gl_cv_next_time_h+set}" = set; then :
19731 $as_echo_n "(cached) " >&6
19732 else
19733
19734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19735 /* end confdefs.h. */
19736 #include <time.h>
19737
19738 _ACEOF
19739 case "$host_os" in
19740 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19741 *) gl_absname_cpp="$ac_cpp" ;;
19742 esac
19743
19744 case "$host_os" in
19745 mingw*)
19746 gl_dirsep_regex='[/\\]'
19747 ;;
19748 *)
19749 gl_dirsep_regex='\/'
19750 ;;
19751 esac
19752 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19753
19754 gl_header_literal_regex=`echo 'time.h' \
19755 | sed -e "$gl_make_literal_regex_sed"`
19756 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19757 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19758 s|^/[^/]|//&|
19759 p
19760 q
19761 }'
19762 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19763 sed -n "$gl_absolute_header_sed"`'"'
19764
19765
19766 fi
19767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19768 $as_echo "$gl_cv_next_time_h" >&6; }
19769 fi
19770 NEXT_TIME_H=$gl_cv_next_time_h
19771
19772 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19773 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19774 gl_next_as_first_directive='<'time.h'>'
19775 else
19776 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19777 gl_next_as_first_directive=$gl_cv_next_time_h
19778 fi
19779 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19780
19781
19782
19783
19784
19785
19786
19787
19788
19789
19790
19791
19792
19793
19794
19795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
19796 $as_echo_n "checking whether the utimes function works... " >&6; }
19797 if test "${gl_cv_func_working_utimes+set}" = set; then :
19798 $as_echo_n "(cached) " >&6
19799 else
19800
19801 if test "$cross_compiling" = yes; then :
19802 gl_cv_func_working_utimes=no
19803 else
19804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19805 /* end confdefs.h. */
19806
19807 #include <sys/types.h>
19808 #include <sys/stat.h>
19809 #include <fcntl.h>
19810 #include <sys/time.h>
19811 #include <time.h>
19812 #include <unistd.h>
19813 #include <stdlib.h>
19814 #include <stdio.h>
19815 #include <utime.h>
19816
19817 static int
19818 inorder (time_t a, time_t b, time_t c)
19819 {
19820 return a <= b && b <= c;
19821 }
19822
19823 int
19824 main ()
19825 {
19826 int result = 0;
19827 char const *file = "conftest.utimes";
19828 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
19829
19830 /* Test whether utimes() essentially works. */
19831 {
19832 struct stat sbuf;
19833 FILE *f = fopen (file, "w");
19834 if (f == NULL)
19835 result |= 1;
19836 else if (fclose (f) != 0)
19837 result |= 1;
19838 else if (utimes (file, timeval) != 0)
19839 result |= 2;
19840 else if (lstat (file, &sbuf) != 0)
19841 result |= 1;
19842 else if (!(sbuf.st_atime == timeval[0].tv_sec
19843 && sbuf.st_mtime == timeval[1].tv_sec))
19844 result |= 4;
19845 if (unlink (file) != 0)
19846 result |= 1;
19847 }
19848
19849 /* Test whether utimes() with a NULL argument sets the file's timestamp
19850 to the current time. Use 'fstat' as well as 'time' to
19851 determine the "current" time, to accommodate NFS file systems
19852 if there is a time skew between the host and the NFS server. */
19853 {
19854 int fd = open (file, O_WRONLY|O_CREAT, 0644);
19855 if (fd < 0)
19856 result |= 1;
19857 else
19858 {
19859 time_t t0, t2;
19860 struct stat st0, st1, st2;
19861 if (time (&t0) == (time_t) -1)
19862 result |= 1;
19863 else if (fstat (fd, &st0) != 0)
19864 result |= 1;
19865 else if (utimes (file, timeval) != 0)
19866 result |= 2;
19867 else if (utimes (file, NULL) != 0)
19868 result |= 8;
19869 else if (fstat (fd, &st1) != 0)
19870 result |= 1;
19871 else if (write (fd, "\n", 1) != 1)
19872 result |= 1;
19873 else if (fstat (fd, &st2) != 0)
19874 result |= 1;
19875 else if (time (&t2) == (time_t) -1)
19876 result |= 1;
19877 else
19878 {
19879 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
19880 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
19881 if (! (st1.st_atime == st1.st_mtime))
19882 result |= 16;
19883 if (! (m_ok_POSIX || m_ok_NFS))
19884 result |= 32;
19885 }
19886 if (close (fd) != 0)
19887 result |= 1;
19888 }
19889 if (unlink (file) != 0)
19890 result |= 1;
19891 }
19892
19893 /* Test whether utimes() with a NULL argument works on read-only files. */
19894 {
19895 int fd = open (file, O_WRONLY|O_CREAT, 0444);
19896 if (fd < 0)
19897 result |= 1;
19898 else if (close (fd) != 0)
19899 result |= 1;
19900 else if (utimes (file, NULL) != 0)
19901 result |= 64;
19902 if (unlink (file) != 0)
19903 result |= 1;
19904 }
19905
19906 return result;
19907 }
19908
19909 _ACEOF
19910 if ac_fn_c_try_run "$LINENO"; then :
19911 gl_cv_func_working_utimes=yes
19912 else
19913 gl_cv_func_working_utimes=no
19914 fi
19915 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19916 conftest.$ac_objext conftest.beam conftest.$ac_ext
19917 fi
19918
19919 fi
19920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
19921 $as_echo "$gl_cv_func_working_utimes" >&6; }
19922
19923 if test $gl_cv_func_working_utimes = yes; then
19924
19925 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
19926
19927 fi
19928
19929
19930
19931
19932
19933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
19934 $as_echo_n "checking for struct utimbuf... " >&6; }
19935 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
19936 $as_echo_n "(cached) " >&6
19937 else
19938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19939 /* end confdefs.h. */
19940 #if HAVE_SYS_TIME_H
19941 #include <sys/time.h>
19942 #endif
19943 #include <time.h>
19944 #ifdef HAVE_UTIME_H
19945 #include <utime.h>
19946 #endif
19947
19948 int
19949 main ()
19950 {
19951 static struct utimbuf x; x.actime = x.modtime;
19952 ;
19953 return 0;
19954 }
19955 _ACEOF
19956 if ac_fn_c_try_compile "$LINENO"; then :
19957 gl_cv_sys_struct_utimbuf=yes
19958 else
19959 gl_cv_sys_struct_utimbuf=no
19960 fi
19961 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19962 fi
19963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
19964 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
19965
19966 if test $gl_cv_sys_struct_utimbuf = yes; then
19967
19968 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
19969
19970 fi
19971
19972
19973
19974
19975
19976
19977
19978
19979
19980
19981
19982
19983 if false; then
19984 GL_COND_LIBTOOL_TRUE=
19985 GL_COND_LIBTOOL_FALSE='#'
19986 else
19987 GL_COND_LIBTOOL_TRUE='#'
19988 GL_COND_LIBTOOL_FALSE=
19989 fi
19990
19991 gl_cond_libtool=false
19992 gl_libdeps=
19993 gl_ltlibdeps=
19994 gl_m4_base='m4'
19995
19996
19997
19998
19999
20000
20001
20002
20003
20004 gl_source_base='lib'
20005
20006
20007 if test $ac_cv_func_alloca_works = no; then
20008 :
20009 fi
20010
20011 # Define an additional variable used in the Makefile substitution.
20012 if test $ac_cv_working_alloca_h = yes; then
20013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20014 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20015 if test "${gl_cv_rpl_alloca+set}" = set; then :
20016 $as_echo_n "(cached) " >&6
20017 else
20018
20019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20020 /* end confdefs.h. */
20021
20022 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20023 Need own alloca
20024 #endif
20025
20026 _ACEOF
20027 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20028 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20029 gl_cv_rpl_alloca=yes
20030 else
20031 gl_cv_rpl_alloca=no
20032 fi
20033 rm -f conftest*
20034
20035
20036 fi
20037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20038 $as_echo "$gl_cv_rpl_alloca" >&6; }
20039 if test $gl_cv_rpl_alloca = yes; then
20040
20041 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20042
20043 ALLOCA_H=alloca.h
20044 else
20045 ALLOCA_H=
20046 fi
20047 else
20048 ALLOCA_H=alloca.h
20049 fi
20050
20051 if test -n "$ALLOCA_H"; then
20052 GL_GENERATE_ALLOCA_H_TRUE=
20053 GL_GENERATE_ALLOCA_H_FALSE='#'
20054 else
20055 GL_GENERATE_ALLOCA_H_TRUE='#'
20056 GL_GENERATE_ALLOCA_H_FALSE=
20057 fi
20058
20059
20060
20061
20062
20063
20064 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20065 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20066
20067 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20068 # programs in the package would end up linked with that potentially-shared
20069 # library, inducing unnecessary run-time overhead.
20070 LIB_CLOCK_GETTIME=
20071
20072 gl_saved_libs=$LIBS
20073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20074 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20075 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20076 $as_echo_n "(cached) " >&6
20077 else
20078 ac_func_search_save_LIBS=$LIBS
20079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20080 /* end confdefs.h. */
20081
20082 /* Override any GCC internal prototype to avoid an error.
20083 Use char because int might match the return type of a GCC
20084 builtin and then its argument prototype would still apply. */
20085 #ifdef __cplusplus
20086 extern "C"
20087 #endif
20088 char clock_gettime ();
20089 int
20090 main ()
20091 {
20092 return clock_gettime ();
20093 ;
20094 return 0;
20095 }
20096 _ACEOF
20097 for ac_lib in '' rt posix4; do
20098 if test -z "$ac_lib"; then
20099 ac_res="none required"
20100 else
20101 ac_res=-l$ac_lib
20102 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20103 fi
20104 if ac_fn_c_try_link "$LINENO"; then :
20105 ac_cv_search_clock_gettime=$ac_res
20106 fi
20107 rm -f core conftest.err conftest.$ac_objext \
20108 conftest$ac_exeext
20109 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20110 break
20111 fi
20112 done
20113 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20114
20115 else
20116 ac_cv_search_clock_gettime=no
20117 fi
20118 rm conftest.$ac_ext
20119 LIBS=$ac_func_search_save_LIBS
20120 fi
20121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20122 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20123 ac_res=$ac_cv_search_clock_gettime
20124 if test "$ac_res" != no; then :
20125 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20126 test "$ac_cv_search_clock_gettime" = "none required" ||
20127 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20128 fi
20129
20130 for ac_func in clock_gettime clock_settime
20131 do :
20132 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20133 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20134 eval as_val=\$$as_ac_var
20135 if test "x$as_val" = x""yes; then :
20136 cat >>confdefs.h <<_ACEOF
20137 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20138 _ACEOF
20139
20140 fi
20141 done
20142
20143 LIBS=$gl_saved_libs
20144
20145
20146
20147
20148 :
20149
20150
20151
20152
20153 :
20154
20155
20156
20157
20158
20159
20160
20161
20162
20163
20164
20165
20166
20167
20168
20169 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20170
20171
20172 if test $HAVE_DUP2 = 1; then
20173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20174 $as_echo_n "checking whether dup2 works... " >&6; }
20175 if test "${gl_cv_func_dup2_works+set}" = set; then :
20176 $as_echo_n "(cached) " >&6
20177 else
20178 if test "$cross_compiling" = yes; then :
20179 case "$host_os" in
20180 mingw*) # on this platform, dup2 always returns 0 for success
20181 gl_cv_func_dup2_works="guessing no" ;;
20182 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20183 gl_cv_func_dup2_works="guessing no" ;;
20184 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20185 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20186 gl_cv_func_dup2_works="guessing no" ;;
20187 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20188 gl_cv_func_dup2_works="guessing no" ;;
20189 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20190 gl_cv_func_dup2_works="guessing no" ;;
20191 *) gl_cv_func_dup2_works="guessing yes" ;;
20192 esac
20193 else
20194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20195 /* end confdefs.h. */
20196
20197 #include <unistd.h>
20198 #include <fcntl.h>
20199 #include <errno.h>
20200 int
20201 main ()
20202 {
20203 int result = 0;
20204 #ifdef FD_CLOEXEC
20205 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20206 result |= 1;
20207 #endif
20208 if (dup2 (1, 1) == 0)
20209 result |= 2;
20210 #ifdef FD_CLOEXEC
20211 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20212 result |= 4;
20213 #endif
20214 close (0);
20215 if (dup2 (0, 0) != -1)
20216 result |= 8;
20217 /* Many gnulib modules require POSIX conformance of EBADF. */
20218 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20219 result |= 16;
20220 return result;
20221
20222 ;
20223 return 0;
20224 }
20225
20226 _ACEOF
20227 if ac_fn_c_try_run "$LINENO"; then :
20228 gl_cv_func_dup2_works=yes
20229 else
20230 gl_cv_func_dup2_works=no
20231 fi
20232 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20233 conftest.$ac_objext conftest.beam conftest.$ac_ext
20234 fi
20235
20236
20237 fi
20238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20239 $as_echo "$gl_cv_func_dup2_works" >&6; }
20240 case "$gl_cv_func_dup2_works" in
20241 *yes) ;;
20242 *)
20243 REPLACE_DUP2=1
20244 ;;
20245 esac
20246 fi
20247
20248
20249 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20250
20251
20252
20253
20254
20255
20256
20257
20258 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20259
20260
20261 fi
20262
20263
20264
20265
20266
20267 GNULIB_DUP2=1
20268
20269
20270
20271
20272
20273
20274
20275
20276
20277
20278
20279 GNULIB_ENVIRON=1
20280
20281
20282
20283
20284
20285
20286
20287
20288 LIB_EXECINFO=''
20289 EXECINFO_H='execinfo.h'
20290
20291 if test $ac_cv_header_execinfo_h = yes; then
20292 gl_saved_libs=$LIBS
20293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20294 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20295 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20296 $as_echo_n "(cached) " >&6
20297 else
20298 ac_func_search_save_LIBS=$LIBS
20299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20300 /* end confdefs.h. */
20301
20302 /* Override any GCC internal prototype to avoid an error.
20303 Use char because int might match the return type of a GCC
20304 builtin and then its argument prototype would still apply. */
20305 #ifdef __cplusplus
20306 extern "C"
20307 #endif
20308 char backtrace_symbols_fd ();
20309 int
20310 main ()
20311 {
20312 return backtrace_symbols_fd ();
20313 ;
20314 return 0;
20315 }
20316 _ACEOF
20317 for ac_lib in '' execinfo; do
20318 if test -z "$ac_lib"; then
20319 ac_res="none required"
20320 else
20321 ac_res=-l$ac_lib
20322 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20323 fi
20324 if ac_fn_c_try_link "$LINENO"; then :
20325 ac_cv_search_backtrace_symbols_fd=$ac_res
20326 fi
20327 rm -f core conftest.err conftest.$ac_objext \
20328 conftest$ac_exeext
20329 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20330 break
20331 fi
20332 done
20333 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20334
20335 else
20336 ac_cv_search_backtrace_symbols_fd=no
20337 fi
20338 rm conftest.$ac_ext
20339 LIBS=$ac_func_search_save_LIBS
20340 fi
20341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20342 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20343 ac_res=$ac_cv_search_backtrace_symbols_fd
20344 if test "$ac_res" != no; then :
20345 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20346 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20347 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20348 fi
20349
20350 LIBS=$gl_saved_libs
20351 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20352 fi
20353
20354 if test -n "$EXECINFO_H"; then
20355
20356
20357
20358
20359
20360
20361
20362
20363 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20364
20365 fi
20366
20367
20368
20369 if test -n "$EXECINFO_H"; then
20370 GL_GENERATE_EXECINFO_H_TRUE=
20371 GL_GENERATE_EXECINFO_H_FALSE='#'
20372 else
20373 GL_GENERATE_EXECINFO_H_TRUE='#'
20374 GL_GENERATE_EXECINFO_H_FALSE=
20375 fi
20376
20377
20378
20379
20380
20381
20382
20383
20384
20385 # Persuade glibc <stdlib.h> to declare getloadavg().
20386
20387
20388 gl_save_LIBS=$LIBS
20389
20390 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20391 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20392 HAVE_GETLOADAVG=1
20393 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20394 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20395
20396 else
20397 gl_func_getloadavg_done=no
20398
20399 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20400 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20401 # to get the right answer into the cache.
20402 # For kstat on solaris, we need to test for libelf and libkvm to force the
20403 # definition of SVR4 below.
20404 if test $gl_func_getloadavg_done = no; then
20405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20406 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20407 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20408 $as_echo_n "(cached) " >&6
20409 else
20410 ac_check_lib_save_LIBS=$LIBS
20411 LIBS="-lelf $LIBS"
20412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20413 /* end confdefs.h. */
20414
20415 /* Override any GCC internal prototype to avoid an error.
20416 Use char because int might match the return type of a GCC
20417 builtin and then its argument prototype would still apply. */
20418 #ifdef __cplusplus
20419 extern "C"
20420 #endif
20421 char elf_begin ();
20422 int
20423 main ()
20424 {
20425 return elf_begin ();
20426 ;
20427 return 0;
20428 }
20429 _ACEOF
20430 if ac_fn_c_try_link "$LINENO"; then :
20431 ac_cv_lib_elf_elf_begin=yes
20432 else
20433 ac_cv_lib_elf_elf_begin=no
20434 fi
20435 rm -f core conftest.err conftest.$ac_objext \
20436 conftest$ac_exeext conftest.$ac_ext
20437 LIBS=$ac_check_lib_save_LIBS
20438 fi
20439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20440 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20441 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20442 LIBS="-lelf $LIBS"
20443 fi
20444
20445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20446 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20447 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20448 $as_echo_n "(cached) " >&6
20449 else
20450 ac_check_lib_save_LIBS=$LIBS
20451 LIBS="-lkvm $LIBS"
20452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20453 /* end confdefs.h. */
20454
20455 /* Override any GCC internal prototype to avoid an error.
20456 Use char because int might match the return type of a GCC
20457 builtin and then its argument prototype would still apply. */
20458 #ifdef __cplusplus
20459 extern "C"
20460 #endif
20461 char kvm_open ();
20462 int
20463 main ()
20464 {
20465 return kvm_open ();
20466 ;
20467 return 0;
20468 }
20469 _ACEOF
20470 if ac_fn_c_try_link "$LINENO"; then :
20471 ac_cv_lib_kvm_kvm_open=yes
20472 else
20473 ac_cv_lib_kvm_kvm_open=no
20474 fi
20475 rm -f core conftest.err conftest.$ac_objext \
20476 conftest$ac_exeext conftest.$ac_ext
20477 LIBS=$ac_check_lib_save_LIBS
20478 fi
20479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20480 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20481 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20482 LIBS="-lkvm $LIBS"
20483 fi
20484
20485 # Check for the 4.4BSD definition of getloadavg.
20486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20487 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20488 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20489 $as_echo_n "(cached) " >&6
20490 else
20491 ac_check_lib_save_LIBS=$LIBS
20492 LIBS="-lutil $LIBS"
20493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20494 /* end confdefs.h. */
20495
20496 /* Override any GCC internal prototype to avoid an error.
20497 Use char because int might match the return type of a GCC
20498 builtin and then its argument prototype would still apply. */
20499 #ifdef __cplusplus
20500 extern "C"
20501 #endif
20502 char getloadavg ();
20503 int
20504 main ()
20505 {
20506 return getloadavg ();
20507 ;
20508 return 0;
20509 }
20510 _ACEOF
20511 if ac_fn_c_try_link "$LINENO"; then :
20512 ac_cv_lib_util_getloadavg=yes
20513 else
20514 ac_cv_lib_util_getloadavg=no
20515 fi
20516 rm -f core conftest.err conftest.$ac_objext \
20517 conftest$ac_exeext conftest.$ac_ext
20518 LIBS=$ac_check_lib_save_LIBS
20519 fi
20520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20521 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20522 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20523 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20524 fi
20525
20526 fi
20527
20528 if test $gl_func_getloadavg_done = no; then
20529 # There is a commonly available library for RS/6000 AIX.
20530 # Since it is not a standard part of AIX, it might be installed locally.
20531 gl_getloadavg_LIBS=$LIBS
20532 LIBS="-L/usr/local/lib $LIBS"
20533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20534 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20535 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20536 $as_echo_n "(cached) " >&6
20537 else
20538 ac_check_lib_save_LIBS=$LIBS
20539 LIBS="-lgetloadavg $LIBS"
20540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20541 /* end confdefs.h. */
20542
20543 /* Override any GCC internal prototype to avoid an error.
20544 Use char because int might match the return type of a GCC
20545 builtin and then its argument prototype would still apply. */
20546 #ifdef __cplusplus
20547 extern "C"
20548 #endif
20549 char getloadavg ();
20550 int
20551 main ()
20552 {
20553 return getloadavg ();
20554 ;
20555 return 0;
20556 }
20557 _ACEOF
20558 if ac_fn_c_try_link "$LINENO"; then :
20559 ac_cv_lib_getloadavg_getloadavg=yes
20560 else
20561 ac_cv_lib_getloadavg_getloadavg=no
20562 fi
20563 rm -f core conftest.err conftest.$ac_objext \
20564 conftest$ac_exeext conftest.$ac_ext
20565 LIBS=$ac_check_lib_save_LIBS
20566 fi
20567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
20568 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20569 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20570 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20571 else
20572 LIBS=$gl_getloadavg_LIBS
20573 fi
20574
20575 fi
20576
20577 # Set up the replacement function if necessary.
20578 if test $gl_func_getloadavg_done = no; then
20579 HAVE_GETLOADAVG=0
20580
20581 # Solaris has libkstat which does not require root.
20582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20583 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20584 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20585 $as_echo_n "(cached) " >&6
20586 else
20587 ac_check_lib_save_LIBS=$LIBS
20588 LIBS="-lkstat $LIBS"
20589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20590 /* end confdefs.h. */
20591
20592 /* Override any GCC internal prototype to avoid an error.
20593 Use char because int might match the return type of a GCC
20594 builtin and then its argument prototype would still apply. */
20595 #ifdef __cplusplus
20596 extern "C"
20597 #endif
20598 char kstat_open ();
20599 int
20600 main ()
20601 {
20602 return kstat_open ();
20603 ;
20604 return 0;
20605 }
20606 _ACEOF
20607 if ac_fn_c_try_link "$LINENO"; then :
20608 ac_cv_lib_kstat_kstat_open=yes
20609 else
20610 ac_cv_lib_kstat_kstat_open=no
20611 fi
20612 rm -f core conftest.err conftest.$ac_objext \
20613 conftest$ac_exeext conftest.$ac_ext
20614 LIBS=$ac_check_lib_save_LIBS
20615 fi
20616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20617 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20618 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20619 cat >>confdefs.h <<_ACEOF
20620 #define HAVE_LIBKSTAT 1
20621 _ACEOF
20622
20623 LIBS="-lkstat $LIBS"
20624
20625 fi
20626
20627 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20628
20629 # AIX has libperfstat which does not require root
20630 if test $gl_func_getloadavg_done = no; then
20631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20632 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20633 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20634 $as_echo_n "(cached) " >&6
20635 else
20636 ac_check_lib_save_LIBS=$LIBS
20637 LIBS="-lperfstat $LIBS"
20638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20639 /* end confdefs.h. */
20640
20641 /* Override any GCC internal prototype to avoid an error.
20642 Use char because int might match the return type of a GCC
20643 builtin and then its argument prototype would still apply. */
20644 #ifdef __cplusplus
20645 extern "C"
20646 #endif
20647 char perfstat_cpu_total ();
20648 int
20649 main ()
20650 {
20651 return perfstat_cpu_total ();
20652 ;
20653 return 0;
20654 }
20655 _ACEOF
20656 if ac_fn_c_try_link "$LINENO"; then :
20657 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20658 else
20659 ac_cv_lib_perfstat_perfstat_cpu_total=no
20660 fi
20661 rm -f core conftest.err conftest.$ac_objext \
20662 conftest$ac_exeext conftest.$ac_ext
20663 LIBS=$ac_check_lib_save_LIBS
20664 fi
20665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20666 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20667 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20668 cat >>confdefs.h <<_ACEOF
20669 #define HAVE_LIBPERFSTAT 1
20670 _ACEOF
20671
20672 LIBS="-lperfstat $LIBS"
20673
20674 fi
20675
20676 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20677 fi
20678
20679 if test $gl_func_getloadavg_done = no; then
20680 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20681 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20682 gl_func_getloadavg_done=yes
20683
20684 $as_echo "#define DGUX 1" >>confdefs.h
20685
20686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20687 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20688 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20689 $as_echo_n "(cached) " >&6
20690 else
20691 ac_check_lib_save_LIBS=$LIBS
20692 LIBS="-ldgc $LIBS"
20693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20694 /* end confdefs.h. */
20695
20696 /* Override any GCC internal prototype to avoid an error.
20697 Use char because int might match the return type of a GCC
20698 builtin and then its argument prototype would still apply. */
20699 #ifdef __cplusplus
20700 extern "C"
20701 #endif
20702 char dg_sys_info ();
20703 int
20704 main ()
20705 {
20706 return dg_sys_info ();
20707 ;
20708 return 0;
20709 }
20710 _ACEOF
20711 if ac_fn_c_try_link "$LINENO"; then :
20712 ac_cv_lib_dgc_dg_sys_info=yes
20713 else
20714 ac_cv_lib_dgc_dg_sys_info=no
20715 fi
20716 rm -f core conftest.err conftest.$ac_objext \
20717 conftest$ac_exeext conftest.$ac_ext
20718 LIBS=$ac_check_lib_save_LIBS
20719 fi
20720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
20721 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
20722 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
20723 cat >>confdefs.h <<_ACEOF
20724 #define HAVE_LIBDGC 1
20725 _ACEOF
20726
20727 LIBS="-ldgc $LIBS"
20728
20729 fi
20730
20731 fi
20732
20733
20734 fi
20735 fi
20736 fi
20737
20738
20739 if test "x$gl_save_LIBS" = x; then
20740 GETLOADAVG_LIBS=$LIBS
20741 else
20742 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
20743 fi
20744 LIBS=$gl_save_LIBS
20745
20746
20747 # Test whether the system declares getloadavg. Solaris has the function
20748 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
20749 for ac_header in sys/loadavg.h
20750 do :
20751 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
20752 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
20753 cat >>confdefs.h <<_ACEOF
20754 #define HAVE_SYS_LOADAVG_H 1
20755 _ACEOF
20756
20757 fi
20758
20759 done
20760
20761 if test $ac_cv_header_sys_loadavg_h = yes; then
20762 HAVE_SYS_LOADAVG_H=1
20763 else
20764 HAVE_SYS_LOADAVG_H=0
20765 fi
20766 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
20767 # include <sys/loadavg.h>
20768 #endif
20769 #include <stdlib.h>
20770 "
20771 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
20772
20773 else
20774 HAVE_DECL_GETLOADAVG=0
20775 fi
20776
20777
20778 if test $HAVE_GETLOADAVG = 0; then
20779
20780
20781
20782
20783
20784
20785
20786
20787 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
20788
20789
20790 # Figure out what our getloadavg.c needs.
20791
20792
20793
20794 # On HPUX9, an unprivileged user can get load averages this way.
20795 if test $gl_func_getloadavg_done = no; then
20796 for ac_func in pstat_getdynamic
20797 do :
20798 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
20799 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
20800 cat >>confdefs.h <<_ACEOF
20801 #define HAVE_PSTAT_GETDYNAMIC 1
20802 _ACEOF
20803 gl_func_getloadavg_done=yes
20804 fi
20805 done
20806
20807 fi
20808
20809 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
20810 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
20811 # Irix 4.0.5F has the header but not the library.
20812 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
20813 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
20814 gl_func_getloadavg_done=yes
20815
20816 $as_echo "#define SVR4 1" >>confdefs.h
20817
20818 fi
20819
20820 if test $gl_func_getloadavg_done = no; then
20821 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
20822 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
20823 gl_func_getloadavg_done=yes
20824
20825 $as_echo "#define UMAX 1" >>confdefs.h
20826
20827
20828 $as_echo "#define UMAX4_3 1" >>confdefs.h
20829
20830 fi
20831
20832
20833 fi
20834
20835 if test $gl_func_getloadavg_done = no; then
20836 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
20837 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
20838 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
20839
20840 fi
20841
20842
20843 fi
20844
20845 if test $gl_func_getloadavg_done = no; then
20846 for ac_header in mach/mach.h
20847 do :
20848 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
20849 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
20850 cat >>confdefs.h <<_ACEOF
20851 #define HAVE_MACH_MACH_H 1
20852 _ACEOF
20853
20854 fi
20855
20856 done
20857
20858 fi
20859
20860 for ac_header in nlist.h
20861 do :
20862 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
20863 if test "x$ac_cv_header_nlist_h" = x""yes; then :
20864 cat >>confdefs.h <<_ACEOF
20865 #define HAVE_NLIST_H 1
20866 _ACEOF
20867 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
20868 "
20869 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
20870
20871 cat >>confdefs.h <<_ACEOF
20872 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
20873 _ACEOF
20874
20875
20876 fi
20877
20878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20879 /* end confdefs.h. */
20880 #include <nlist.h>
20881 int
20882 main ()
20883 {
20884 struct nlist x;
20885 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
20886 x.n_un.n_name = "";
20887 #else
20888 x.n_name = "";
20889 #endif
20890 ;
20891 return 0;
20892 }
20893 _ACEOF
20894 if ac_fn_c_try_link "$LINENO"; then :
20895
20896 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
20897
20898 fi
20899 rm -f core conftest.err conftest.$ac_objext \
20900 conftest$ac_exeext conftest.$ac_ext
20901
20902 fi
20903
20904 done
20905
20906 fi
20907
20908
20909
20910
20911
20912 GNULIB_GETLOADAVG=1
20913
20914
20915
20916
20917
20918
20919
20920
20921
20922
20923 if test $REPLACE_GETOPT = 1; then
20924
20925
20926
20927
20928
20929
20930
20931
20932 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20933
20934
20935
20936
20937
20938
20939
20940
20941
20942 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20943
20944
20945
20946
20947 GNULIB_GL_UNISTD_H_GETOPT=1
20948 fi
20949
20950
20951
20952
20953
20954
20955
20956 REPLACE_GETOPT=0
20957 if test -n "$gl_replace_getopt"; then
20958 REPLACE_GETOPT=1
20959 fi
20960
20961 if test $REPLACE_GETOPT = 1; then
20962
20963 GETOPT_H=getopt.h
20964
20965 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
20966
20967
20968
20969 fi
20970
20971 if test $REPLACE_GETOPT = 1; then
20972
20973
20974
20975
20976
20977
20978
20979
20980 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
20981
20982
20983
20984
20985
20986
20987
20988
20989
20990 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20991
20992
20993
20994
20995 GNULIB_GL_UNISTD_H_GETOPT=1
20996 fi
20997
20998
20999
21000
21001
21002
21003
21004
21005
21006
21007
21008
21009 gl_gettimeofday_timezone=void
21010 if test $ac_cv_func_gettimeofday != yes; then
21011 HAVE_GETTIMEOFDAY=0
21012 else
21013
21014
21015
21016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21017 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21018 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21019 $as_echo_n "(cached) " >&6
21020 else
21021 if test "$cross_compiling" = yes; then :
21022 # When cross-compiling:
21023 case "$host_os" in
21024 # Guess all is fine on glibc systems.
21025 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21026 # If we don't know, assume the worst.
21027 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21028 esac
21029
21030 else
21031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21032 /* end confdefs.h. */
21033 #include <string.h>
21034 #include <sys/time.h>
21035 #include <time.h>
21036 #include <stdlib.h>
21037
21038 int
21039 main ()
21040 {
21041
21042 time_t t = 0;
21043 struct tm *lt;
21044 struct tm saved_lt;
21045 struct timeval tv;
21046 lt = localtime (&t);
21047 saved_lt = *lt;
21048 gettimeofday (&tv, NULL);
21049 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21050
21051 ;
21052 return 0;
21053 }
21054 _ACEOF
21055 if ac_fn_c_try_run "$LINENO"; then :
21056 gl_cv_func_gettimeofday_clobber=no
21057 else
21058 gl_cv_func_gettimeofday_clobber=yes
21059 fi
21060 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21061 conftest.$ac_objext conftest.beam conftest.$ac_ext
21062 fi
21063
21064 fi
21065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21066 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21067
21068 case "$gl_cv_func_gettimeofday_clobber" in
21069 *yes)
21070 REPLACE_GETTIMEOFDAY=1
21071
21072
21073 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21074
21075
21076 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21077
21078
21079
21080 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21081
21082 ;;
21083 esac
21084
21085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21086 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21087 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21088 $as_echo_n "(cached) " >&6
21089 else
21090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21091 /* end confdefs.h. */
21092 #include <sys/time.h>
21093 struct timeval c;
21094 int gettimeofday (struct timeval *restrict, void *restrict);
21095
21096 int
21097 main ()
21098 {
21099 /* glibc uses struct timezone * rather than the POSIX void *
21100 if _GNU_SOURCE is defined. However, since the only portable
21101 use of gettimeofday uses NULL as the second parameter, and
21102 since the glibc definition is actually more typesafe, it is
21103 not worth wrapping this to get a compliant signature. */
21104 int (*f) (struct timeval *restrict, void *restrict)
21105 = gettimeofday;
21106 int x = f (&c, 0);
21107 return !(x | c.tv_sec | c.tv_usec);
21108
21109 ;
21110 return 0;
21111 }
21112 _ACEOF
21113 if ac_fn_c_try_compile "$LINENO"; then :
21114 gl_cv_func_gettimeofday_posix_signature=yes
21115 else
21116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21117 /* end confdefs.h. */
21118 #include <sys/time.h>
21119 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21120
21121 int
21122 main ()
21123 {
21124
21125 ;
21126 return 0;
21127 }
21128 _ACEOF
21129 if ac_fn_c_try_compile "$LINENO"; then :
21130 gl_cv_func_gettimeofday_posix_signature=almost
21131 else
21132 gl_cv_func_gettimeofday_posix_signature=no
21133 fi
21134 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21135 fi
21136 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21137 fi
21138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21139 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21140 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21141 gl_gettimeofday_timezone='struct timezone'
21142 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21143 REPLACE_GETTIMEOFDAY=1
21144 fi
21145 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21146 REPLACE_GETTIMEOFDAY=1
21147 fi
21148
21149 fi
21150
21151 cat >>confdefs.h <<_ACEOF
21152 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21153 _ACEOF
21154
21155
21156 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21157
21158
21159
21160
21161
21162
21163
21164
21165 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21166
21167
21168 for ac_header in sys/timeb.h
21169 do :
21170 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21171 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21172 cat >>confdefs.h <<_ACEOF
21173 #define HAVE_SYS_TIMEB_H 1
21174 _ACEOF
21175
21176 fi
21177
21178 done
21179
21180 for ac_func in _ftime
21181 do :
21182 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21183 if test "x$ac_cv_func__ftime" = x""yes; then :
21184 cat >>confdefs.h <<_ACEOF
21185 #define HAVE__FTIME 1
21186 _ACEOF
21187
21188 fi
21189 done
21190
21191
21192 fi
21193
21194
21195
21196
21197
21198 GNULIB_GETTIMEOFDAY=1
21199
21200
21201
21202
21203
21204
21205
21206
21207
21208
21209 if test $ac_cv_func_lstat = yes; then
21210
21211 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21212 *no)
21213 REPLACE_LSTAT=1
21214 ;;
21215 esac
21216 else
21217 HAVE_LSTAT=0
21218 fi
21219
21220 if test $REPLACE_LSTAT = 1; then
21221
21222
21223
21224
21225
21226
21227
21228
21229 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21230
21231
21232
21233 :
21234
21235 fi
21236
21237
21238
21239
21240
21241 GNULIB_LSTAT=1
21242
21243
21244
21245
21246
21247
21248
21249
21250
21251
21252
21253 if test $APPLE_UNIVERSAL_BUILD = 1; then
21254 # A universal build on Apple Mac OS X platforms.
21255 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21256 # But we need a configuration result that is valid in both modes.
21257 gl_cv_func_working_mktime=no
21258 fi
21259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21260 $as_echo_n "checking for working mktime... " >&6; }
21261 if test "${gl_cv_func_working_mktime+set}" = set; then :
21262 $as_echo_n "(cached) " >&6
21263 else
21264 if test "$cross_compiling" = yes; then :
21265 gl_cv_func_working_mktime=no
21266 else
21267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21268 /* end confdefs.h. */
21269 /* Test program from Paul Eggert and Tony Leneis. */
21270 #include <limits.h>
21271 #include <stdlib.h>
21272 #include <time.h>
21273
21274 #ifdef HAVE_UNISTD_H
21275 # include <unistd.h>
21276 #endif
21277
21278 #ifndef HAVE_ALARM
21279 # define alarm(X) /* empty */
21280 #endif
21281
21282 /* Work around redefinition to rpl_putenv by other config tests. */
21283 #undef putenv
21284
21285 static time_t time_t_max;
21286 static time_t time_t_min;
21287
21288 /* Values we'll use to set the TZ environment variable. */
21289 static char *tz_strings[] = {
21290 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21291 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21292 };
21293 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21294
21295 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21296 Based on a problem report from Andreas Jaeger. */
21297 static int
21298 spring_forward_gap ()
21299 {
21300 /* glibc (up to about 1998-10-07) failed this test. */
21301 struct tm tm;
21302
21303 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21304 instead of "TZ=America/Vancouver" in order to detect the bug even
21305 on systems that don't support the Olson extension, or don't have the
21306 full zoneinfo tables installed. */
21307 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21308
21309 tm.tm_year = 98;
21310 tm.tm_mon = 3;
21311 tm.tm_mday = 5;
21312 tm.tm_hour = 2;
21313 tm.tm_min = 0;
21314 tm.tm_sec = 0;
21315 tm.tm_isdst = -1;
21316 return mktime (&tm) != (time_t) -1;
21317 }
21318
21319 static int
21320 mktime_test1 (time_t now)
21321 {
21322 struct tm *lt;
21323 return ! (lt = localtime (&now)) || mktime (lt) == now;
21324 }
21325
21326 static int
21327 mktime_test (time_t now)
21328 {
21329 return (mktime_test1 (now)
21330 && mktime_test1 ((time_t) (time_t_max - now))
21331 && mktime_test1 ((time_t) (time_t_min + now)));
21332 }
21333
21334 static int
21335 irix_6_4_bug ()
21336 {
21337 /* Based on code from Ariel Faigon. */
21338 struct tm tm;
21339 tm.tm_year = 96;
21340 tm.tm_mon = 3;
21341 tm.tm_mday = 0;
21342 tm.tm_hour = 0;
21343 tm.tm_min = 0;
21344 tm.tm_sec = 0;
21345 tm.tm_isdst = -1;
21346 mktime (&tm);
21347 return tm.tm_mon == 2 && tm.tm_mday == 31;
21348 }
21349
21350 static int
21351 bigtime_test (int j)
21352 {
21353 struct tm tm;
21354 time_t now;
21355 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21356 now = mktime (&tm);
21357 if (now != (time_t) -1)
21358 {
21359 struct tm *lt = localtime (&now);
21360 if (! (lt
21361 && lt->tm_year == tm.tm_year
21362 && lt->tm_mon == tm.tm_mon
21363 && lt->tm_mday == tm.tm_mday
21364 && lt->tm_hour == tm.tm_hour
21365 && lt->tm_min == tm.tm_min
21366 && lt->tm_sec == tm.tm_sec
21367 && lt->tm_yday == tm.tm_yday
21368 && lt->tm_wday == tm.tm_wday
21369 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21370 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21371 return 0;
21372 }
21373 return 1;
21374 }
21375
21376 static int
21377 year_2050_test ()
21378 {
21379 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21380 ignoring leap seconds. */
21381 unsigned long int answer = 2527315200UL;
21382
21383 struct tm tm;
21384 time_t t;
21385 tm.tm_year = 2050 - 1900;
21386 tm.tm_mon = 2 - 1;
21387 tm.tm_mday = 1;
21388 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21389 tm.tm_isdst = -1;
21390
21391 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21392 instead of "TZ=America/Vancouver" in order to detect the bug even
21393 on systems that don't support the Olson extension, or don't have the
21394 full zoneinfo tables installed. */
21395 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21396
21397 t = mktime (&tm);
21398
21399 /* Check that the result is either a failure, or close enough
21400 to the correct answer that we can assume the discrepancy is
21401 due to leap seconds. */
21402 return (t == (time_t) -1
21403 || (0 < t && answer - 120 <= t && t <= answer + 120));
21404 }
21405
21406 int
21407 main ()
21408 {
21409 int result = 0;
21410 time_t t, delta;
21411 int i, j;
21412 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21413 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21414
21415 /* This test makes some buggy mktime implementations loop.
21416 Give up after 60 seconds; a mktime slower than that
21417 isn't worth using anyway. */
21418 alarm (60);
21419
21420 time_t_max = (! time_t_signed
21421 ? (time_t) -1
21422 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21423 * 2 + 1));
21424 time_t_min = (! time_t_signed
21425 ? (time_t) 0
21426 : time_t_signed_magnitude
21427 ? ~ (time_t) 0
21428 : ~ time_t_max);
21429
21430 delta = time_t_max / 997; /* a suitable prime number */
21431 for (i = 0; i < N_STRINGS; i++)
21432 {
21433 if (tz_strings[i])
21434 putenv (tz_strings[i]);
21435
21436 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21437 if (! mktime_test (t))
21438 result |= 1;
21439 if ((result & 2) == 0
21440 && ! (mktime_test ((time_t) 1)
21441 && mktime_test ((time_t) (60 * 60))
21442 && mktime_test ((time_t) (60 * 60 * 24))))
21443 result |= 2;
21444
21445 for (j = 1; (result & 4) == 0; j <<= 1)
21446 {
21447 if (! bigtime_test (j))
21448 result |= 4;
21449 if (INT_MAX / 2 < j)
21450 break;
21451 }
21452 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21453 result |= 8;
21454 }
21455 if (! irix_6_4_bug ())
21456 result |= 16;
21457 if (! spring_forward_gap ())
21458 result |= 32;
21459 if (! year_2050_test ())
21460 result |= 64;
21461 return result;
21462 }
21463 _ACEOF
21464 if ac_fn_c_try_run "$LINENO"; then :
21465 gl_cv_func_working_mktime=yes
21466 else
21467 gl_cv_func_working_mktime=no
21468 fi
21469 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21470 conftest.$ac_objext conftest.beam conftest.$ac_ext
21471 fi
21472
21473
21474 fi
21475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21476 $as_echo "$gl_cv_func_working_mktime" >&6; }
21477
21478 if test $gl_cv_func_working_mktime = no; then
21479 REPLACE_MKTIME=1
21480 else
21481 REPLACE_MKTIME=0
21482 fi
21483
21484 if test $REPLACE_MKTIME = 1; then
21485
21486
21487
21488
21489
21490
21491
21492
21493 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21494
21495 :
21496 fi
21497
21498
21499
21500
21501
21502 GNULIB_MKTIME=1
21503
21504
21505
21506
21507
21508
21509
21510
21511
21512
21513
21514 if test $ac_cv_func_pselect = yes; then
21515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21516 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21517 if test "${gl_cv_sig_pselect+set}" = set; then :
21518 $as_echo_n "(cached) " >&6
21519 else
21520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21521 /* end confdefs.h. */
21522 #include <sys/select.h>
21523
21524 int
21525 main ()
21526 {
21527 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21528 struct timespec const *restrict,
21529 sigset_t const *restrict) = pselect;
21530 return !p;
21531 ;
21532 return 0;
21533 }
21534 _ACEOF
21535 if ac_fn_c_try_link "$LINENO"; then :
21536 gl_cv_sig_pselect=yes
21537 else
21538 gl_cv_sig_pselect=no
21539 fi
21540 rm -f core conftest.err conftest.$ac_objext \
21541 conftest$ac_exeext conftest.$ac_ext
21542 fi
21543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21544 $as_echo "$gl_cv_sig_pselect" >&6; }
21545 fi
21546
21547 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21548 REPLACE_PSELECT=1
21549 fi
21550
21551 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21552
21553
21554
21555
21556
21557
21558
21559
21560 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21561
21562 fi
21563
21564
21565
21566
21567
21568 GNULIB_PSELECT=1
21569
21570
21571
21572
21573
21574
21575
21576
21577
21578 LIB_PTHREAD_SIGMASK=
21579
21580
21581 if test $ac_cv_func_pthread_sigmask = yes; then
21582 :
21583 else
21584 HAVE_PTHREAD_SIGMASK=0
21585 REPLACE_PTHREAD_SIGMASK=1
21586 fi
21587
21588
21589
21590
21591 if test $HAVE_PTHREAD_SIGMASK = 1; then
21592
21593
21594 if test -z "$LIB_PTHREAD_SIGMASK"; then
21595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
21596 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
21597 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
21598 $as_echo_n "(cached) " >&6
21599 else
21600
21601 if test "$cross_compiling" = yes; then :
21602
21603 case "$host_os" in
21604 freebsd* | hpux* | solaris | solaris2.[2-9]*)
21605 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
21606 *)
21607 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
21608 esac
21609
21610 else
21611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21612 /* end confdefs.h. */
21613
21614 #include <pthread.h>
21615 #include <signal.h>
21616 #include <stddef.h>
21617 int main ()
21618 {
21619 sigset_t set;
21620 sigemptyset (&set);
21621 return pthread_sigmask (1729, &set, NULL) != 0;
21622 }
21623 _ACEOF
21624 if ac_fn_c_try_run "$LINENO"; then :
21625 gl_cv_func_pthread_sigmask_in_libc_works=no
21626 else
21627 gl_cv_func_pthread_sigmask_in_libc_works=yes
21628 fi
21629 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21630 conftest.$ac_objext conftest.beam conftest.$ac_ext
21631 fi
21632
21633
21634 fi
21635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
21636 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
21637 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
21638 *no)
21639 REPLACE_PTHREAD_SIGMASK=1
21640
21641 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
21642
21643 ;;
21644 esac
21645 fi
21646
21647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
21648 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
21649 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
21650 $as_echo_n "(cached) " >&6
21651 else
21652
21653 gl_save_LIBS="$LIBS"
21654 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
21655 if test "$cross_compiling" = yes; then :
21656 case "$host_os" in
21657 cygwin*)
21658 gl_cv_func_pthread_sigmask_return_works="guessing no";;
21659 *)
21660 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
21661 esac
21662
21663 else
21664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21665 /* end confdefs.h. */
21666
21667 #include <pthread.h>
21668 #include <signal.h>
21669 #include <stddef.h>
21670 int main ()
21671 {
21672 sigset_t set;
21673 sigemptyset (&set);
21674 if (pthread_sigmask (1729, &set, NULL) == -1)
21675 return 1;
21676 return 0;
21677 }
21678 _ACEOF
21679 if ac_fn_c_try_run "$LINENO"; then :
21680 gl_cv_func_pthread_sigmask_return_works=yes
21681 else
21682 gl_cv_func_pthread_sigmask_return_works=no
21683 fi
21684 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21685 conftest.$ac_objext conftest.beam conftest.$ac_ext
21686 fi
21687
21688 LIBS="$gl_save_LIBS"
21689
21690 fi
21691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
21692 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
21693 case "$gl_cv_func_pthread_sigmask_return_works" in
21694 *no)
21695 REPLACE_PTHREAD_SIGMASK=1
21696
21697 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
21698
21699 ;;
21700 esac
21701
21702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
21703 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
21704 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
21705 $as_echo_n "(cached) " >&6
21706 else
21707
21708 case "$host_os" in
21709 irix*)
21710 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
21711 *)
21712 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
21713 esac
21714 gl_save_LIBS="$LIBS"
21715 LIBS="$LIBS $LIBMULTITHREAD"
21716 if test "$cross_compiling" = yes; then :
21717 :
21718 else
21719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21720 /* end confdefs.h. */
21721
21722 #include <pthread.h>
21723 #include <signal.h>
21724 #include <stdio.h>
21725 #include <stdlib.h>
21726 #include <unistd.h>
21727 static volatile int sigint_occurred;
21728 static void
21729 sigint_handler (int sig)
21730 {
21731 sigint_occurred++;
21732 }
21733 int main ()
21734 {
21735 sigset_t set;
21736 int pid = getpid ();
21737 char command[80];
21738 signal (SIGINT, sigint_handler);
21739 sigemptyset (&set);
21740 sigaddset (&set, SIGINT);
21741 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
21742 return 1;
21743 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
21744 if (!(system (command) == 0))
21745 return 2;
21746 sleep (2);
21747 if (!(sigint_occurred == 0))
21748 return 3;
21749 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
21750 return 4;
21751 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
21752 return 5;
21753 return 0;
21754 }
21755 _ACEOF
21756 if ac_fn_c_try_run "$LINENO"; then :
21757 :
21758 else
21759 gl_cv_func_pthread_sigmask_unblock_works=no
21760 fi
21761 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21762 conftest.$ac_objext conftest.beam conftest.$ac_ext
21763 fi
21764
21765 LIBS="$gl_save_LIBS"
21766
21767 fi
21768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
21769 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
21770 case "$gl_cv_func_pthread_sigmask_unblock_works" in
21771 *no)
21772 REPLACE_PTHREAD_SIGMASK=1
21773
21774 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
21775
21776 ;;
21777 esac
21778 fi
21779
21780 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
21781
21782
21783
21784
21785
21786
21787
21788
21789 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
21790
21791
21792 if test $HAVE_PTHREAD_SIGMASK = 1; then
21793
21794 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
21795
21796 fi
21797
21798 fi
21799
21800
21801
21802
21803
21804 GNULIB_PTHREAD_SIGMASK=1
21805
21806
21807
21808
21809
21810
21811
21812
21813 if test $ac_cv_func_readlink = no; then
21814 HAVE_READLINK=0
21815 else
21816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
21817 $as_echo_n "checking whether readlink signature is correct... " >&6; }
21818 if test "${gl_cv_decl_readlink_works+set}" = set; then :
21819 $as_echo_n "(cached) " >&6
21820 else
21821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21822 /* end confdefs.h. */
21823 #include <unistd.h>
21824 /* Cause compilation failure if original declaration has wrong type. */
21825 ssize_t readlink (const char *, char *, size_t);
21826 int
21827 main ()
21828 {
21829
21830 ;
21831 return 0;
21832 }
21833 _ACEOF
21834 if ac_fn_c_try_compile "$LINENO"; then :
21835 gl_cv_decl_readlink_works=yes
21836 else
21837 gl_cv_decl_readlink_works=no
21838 fi
21839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21840 fi
21841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
21842 $as_echo "$gl_cv_decl_readlink_works" >&6; }
21843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
21844 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
21845 if test "${gl_cv_func_readlink_works+set}" = set; then :
21846 $as_echo_n "(cached) " >&6
21847 else
21848 # We have readlink, so assume ln -s works.
21849 ln -s conftest.no-such conftest.link
21850 ln -s conftest.link conftest.lnk2
21851 if test "$cross_compiling" = yes; then :
21852 case "$host_os" in
21853 # Guess yes on glibc systems.
21854 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
21855 # If we don't know, assume the worst.
21856 *) gl_cv_func_readlink_works="guessing no" ;;
21857 esac
21858
21859 else
21860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21861 /* end confdefs.h. */
21862 #include <unistd.h>
21863
21864 int
21865 main ()
21866 {
21867 char buf[20];
21868 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
21869 ;
21870 return 0;
21871 }
21872 _ACEOF
21873 if ac_fn_c_try_run "$LINENO"; then :
21874 gl_cv_func_readlink_works=yes
21875 else
21876 gl_cv_func_readlink_works=no
21877 fi
21878 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21879 conftest.$ac_objext conftest.beam conftest.$ac_ext
21880 fi
21881
21882 rm -f conftest.link conftest.lnk2
21883 fi
21884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
21885 $as_echo "$gl_cv_func_readlink_works" >&6; }
21886 case "$gl_cv_func_readlink_works" in
21887 *yes)
21888 if test "$gl_cv_decl_readlink_works" != yes; then
21889 REPLACE_READLINK=1
21890 fi
21891 ;;
21892 *)
21893
21894 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
21895
21896 REPLACE_READLINK=1
21897 ;;
21898 esac
21899 fi
21900
21901 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
21902
21903
21904
21905
21906
21907
21908
21909
21910 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
21911
21912
21913 :
21914
21915 fi
21916
21917
21918
21919
21920
21921 GNULIB_READLINK=1
21922
21923
21924
21925
21926
21927
21928
21929
21930
21931
21932
21933
21934
21935
21936
21937
21938 if test $gl_cv_have_include_next = yes; then
21939 gl_cv_next_signal_h='<'signal.h'>'
21940 else
21941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
21942 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
21943 if test "${gl_cv_next_signal_h+set}" = set; then :
21944 $as_echo_n "(cached) " >&6
21945 else
21946
21947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21948 /* end confdefs.h. */
21949 #include <signal.h>
21950
21951 _ACEOF
21952 case "$host_os" in
21953 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21954 *) gl_absname_cpp="$ac_cpp" ;;
21955 esac
21956
21957 case "$host_os" in
21958 mingw*)
21959 gl_dirsep_regex='[/\\]'
21960 ;;
21961 *)
21962 gl_dirsep_regex='\/'
21963 ;;
21964 esac
21965 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21966
21967 gl_header_literal_regex=`echo 'signal.h' \
21968 | sed -e "$gl_make_literal_regex_sed"`
21969 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21970 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21971 s|^/[^/]|//&|
21972 p
21973 q
21974 }'
21975 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21976 sed -n "$gl_absolute_header_sed"`'"'
21977
21978
21979 fi
21980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
21981 $as_echo "$gl_cv_next_signal_h" >&6; }
21982 fi
21983 NEXT_SIGNAL_H=$gl_cv_next_signal_h
21984
21985 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21986 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21987 gl_next_as_first_directive='<'signal.h'>'
21988 else
21989 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21990 gl_next_as_first_directive=$gl_cv_next_signal_h
21991 fi
21992 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
21993
21994
21995
21996
21997
21998 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
21999 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22000 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22001 #include <signal.h>
22002
22003 "
22004 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22005
22006 else
22007 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22008 fi
22009
22010
22011
22012
22013
22014
22015
22016 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22017 #include <signal.h>
22018
22019 "
22020 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22021
22022 else
22023 HAVE_SIGHANDLER_T=0
22024 fi
22025
22026
22027
22028
22029 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22030 /* <sys/types.h> is not needed according to POSIX, but the
22031 <sys/socket.h> in i386-unknown-freebsd4.10 and
22032 powerpc-apple-darwin5.5 required it. */
22033 #include <sys/types.h>
22034 #if HAVE_SYS_SOCKET_H
22035 # include <sys/socket.h>
22036 #elif HAVE_WS2TCPIP_H
22037 # include <ws2tcpip.h>
22038 #endif
22039
22040 "
22041 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22042
22043 else
22044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22045 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22046 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22047 $as_echo_n "(cached) " >&6
22048 else
22049 # Systems have either "struct sockaddr *" or
22050 # "void *" as the second argument to getpeername
22051 gl_cv_socklen_t_equiv=
22052 for arg2 in "struct sockaddr" void; do
22053 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22055 /* end confdefs.h. */
22056 #include <sys/types.h>
22057 #include <sys/socket.h>
22058
22059 int getpeername (int, $arg2 *, $t *);
22060 int
22061 main ()
22062 {
22063 $t len;
22064 getpeername (0, 0, &len);
22065 ;
22066 return 0;
22067 }
22068 _ACEOF
22069 if ac_fn_c_try_compile "$LINENO"; then :
22070 gl_cv_socklen_t_equiv="$t"
22071 fi
22072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22073 test "$gl_cv_socklen_t_equiv" != "" && break
22074 done
22075 test "$gl_cv_socklen_t_equiv" != "" && break
22076 done
22077
22078 fi
22079
22080 if test "$gl_cv_socklen_t_equiv" = ""; then
22081 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22082 fi
22083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22084 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
22085
22086 cat >>confdefs.h <<_ACEOF
22087 #define socklen_t $gl_cv_socklen_t_equiv
22088 _ACEOF
22089
22090 fi
22091
22092
22093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22094 $as_echo_n "checking for ssize_t... " >&6; }
22095 if test "${gt_cv_ssize_t+set}" = set; then :
22096 $as_echo_n "(cached) " >&6
22097 else
22098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22099 /* end confdefs.h. */
22100 #include <sys/types.h>
22101 int
22102 main ()
22103 {
22104 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22105 return !x;
22106 ;
22107 return 0;
22108 }
22109 _ACEOF
22110 if ac_fn_c_try_compile "$LINENO"; then :
22111 gt_cv_ssize_t=yes
22112 else
22113 gt_cv_ssize_t=no
22114 fi
22115 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22116 fi
22117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
22118 $as_echo "$gt_cv_ssize_t" >&6; }
22119 if test $gt_cv_ssize_t = no; then
22120
22121 $as_echo "#define ssize_t int" >>confdefs.h
22122
22123 fi
22124
22125
22126
22127
22128
22129 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>
22130 #include <sys/stat.h>
22131 "
22132 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
22133
22134 cat >>confdefs.h <<_ACEOF
22135 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
22136 _ACEOF
22137
22138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
22139 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
22140 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
22141 $as_echo_n "(cached) " >&6
22142 else
22143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22144 /* end confdefs.h. */
22145
22146 #include <sys/types.h>
22147 #include <sys/stat.h>
22148 #if HAVE_SYS_TIME_H
22149 # include <sys/time.h>
22150 #endif
22151 #include <time.h>
22152 struct timespec ts;
22153 struct stat st;
22154
22155 int
22156 main ()
22157 {
22158
22159 st.st_atim = ts;
22160
22161 ;
22162 return 0;
22163 }
22164 _ACEOF
22165 if ac_fn_c_try_compile "$LINENO"; then :
22166 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
22167 else
22168 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
22169 fi
22170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22171 fi
22172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
22173 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
22174 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
22175
22176 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
22177
22178 fi
22179 else
22180 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>
22181 #include <sys/stat.h>
22182 "
22183 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
22184
22185 cat >>confdefs.h <<_ACEOF
22186 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
22187 _ACEOF
22188
22189
22190 else
22191 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
22192 #include <sys/stat.h>
22193 "
22194 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
22195
22196 cat >>confdefs.h <<_ACEOF
22197 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
22198 _ACEOF
22199
22200
22201 else
22202 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>
22203 #include <sys/stat.h>
22204 "
22205 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
22206
22207 cat >>confdefs.h <<_ACEOF
22208 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
22209 _ACEOF
22210
22211
22212 fi
22213
22214 fi
22215
22216 fi
22217
22218 fi
22219
22220
22221
22222
22223
22224 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>
22225 #include <sys/stat.h>
22226 "
22227 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
22228
22229 cat >>confdefs.h <<_ACEOF
22230 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
22231 _ACEOF
22232
22233
22234 else
22235 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
22236 #include <sys/stat.h>
22237 "
22238 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
22239
22240 cat >>confdefs.h <<_ACEOF
22241 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
22242 _ACEOF
22243
22244
22245 else
22246 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>
22247 #include <sys/stat.h>
22248 "
22249 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
22250
22251 cat >>confdefs.h <<_ACEOF
22252 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
22253 _ACEOF
22254
22255
22256 fi
22257
22258 fi
22259
22260 fi
22261
22262
22263
22264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
22265 $as_echo_n "checking for working stdalign.h... " >&6; }
22266 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
22267 $as_echo_n "(cached) " >&6
22268 else
22269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22270 /* end confdefs.h. */
22271 #include <stdalign.h>
22272 #include <stddef.h>
22273
22274 /* Test that alignof yields a result consistent with offsetof.
22275 This catches GCC bug 52023
22276 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
22277 #ifdef __cplusplus
22278 template <class t> struct alignof_helper { char a; t b; };
22279 # define ao(type) offsetof (alignof_helper<type>, b)
22280 #else
22281 # define ao(type) offsetof (struct { char a; type b; }, b)
22282 #endif
22283 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
22284 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
22285 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
22286
22287 /* Test _Alignas only on platforms where gnulib can help. */
22288 #if \
22289 (__GNUC__ || __IBMC__ || __IBMCPP__ \
22290 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
22291 int alignas (8) alignas_int = 1;
22292 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
22293 #endif
22294
22295 int
22296 main ()
22297 {
22298
22299 ;
22300 return 0;
22301 }
22302 _ACEOF
22303 if ac_fn_c_try_compile "$LINENO"; then :
22304 gl_cv_header_working_stdalign_h=yes
22305 else
22306 gl_cv_header_working_stdalign_h=no
22307 fi
22308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22309 fi
22310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
22311 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
22312
22313 if test $gl_cv_header_working_stdalign_h = yes; then
22314 STDALIGN_H=''
22315 else
22316 STDALIGN_H='stdalign.h'
22317 fi
22318
22319
22320 if test -n "$STDALIGN_H"; then
22321 GL_GENERATE_STDALIGN_H_TRUE=
22322 GL_GENERATE_STDALIGN_H_FALSE='#'
22323 else
22324 GL_GENERATE_STDALIGN_H_TRUE='#'
22325 GL_GENERATE_STDALIGN_H_FALSE=
22326 fi
22327
22328
22329
22330 STDARG_H=''
22331 NEXT_STDARG_H='<stdarg.h>'
22332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
22333 $as_echo_n "checking for va_copy... " >&6; }
22334 if test "${gl_cv_func_va_copy+set}" = set; then :
22335 $as_echo_n "(cached) " >&6
22336 else
22337
22338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22339 /* end confdefs.h. */
22340 #include <stdarg.h>
22341 int
22342 main ()
22343 {
22344
22345 #ifndef va_copy
22346 void (*func) (va_list, va_list) = va_copy;
22347 #endif
22348
22349 ;
22350 return 0;
22351 }
22352 _ACEOF
22353 if ac_fn_c_try_compile "$LINENO"; then :
22354 gl_cv_func_va_copy=yes
22355 else
22356 gl_cv_func_va_copy=no
22357 fi
22358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22359 fi
22360
22361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
22362 $as_echo "$gl_cv_func_va_copy" >&6; }
22363 if test $gl_cv_func_va_copy = no; then
22364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22365 /* end confdefs.h. */
22366 #if defined _AIX && !defined __GNUC__
22367 AIX vaccine
22368 #endif
22369
22370 _ACEOF
22371 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22372 $EGREP "vaccine" >/dev/null 2>&1; then :
22373 gl_aixcc=yes
22374 else
22375 gl_aixcc=no
22376 fi
22377 rm -f conftest*
22378
22379 if test $gl_aixcc = yes; then
22380 STDARG_H=stdarg.h
22381
22382
22383
22384
22385
22386
22387
22388
22389 if test $gl_cv_have_include_next = yes; then
22390 gl_cv_next_stdarg_h='<'stdarg.h'>'
22391 else
22392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22393 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22394 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22395 $as_echo_n "(cached) " >&6
22396 else
22397
22398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22399 /* end confdefs.h. */
22400 #include <stdarg.h>
22401
22402 _ACEOF
22403 case "$host_os" in
22404 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22405 *) gl_absname_cpp="$ac_cpp" ;;
22406 esac
22407
22408 case "$host_os" in
22409 mingw*)
22410 gl_dirsep_regex='[/\\]'
22411 ;;
22412 *)
22413 gl_dirsep_regex='\/'
22414 ;;
22415 esac
22416 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22417
22418 gl_header_literal_regex=`echo 'stdarg.h' \
22419 | sed -e "$gl_make_literal_regex_sed"`
22420 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22421 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22422 s|^/[^/]|//&|
22423 p
22424 q
22425 }'
22426 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22427 sed -n "$gl_absolute_header_sed"`'"'
22428
22429
22430 fi
22431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22432 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22433 fi
22434 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22435
22436 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22437 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22438 gl_next_as_first_directive='<'stdarg.h'>'
22439 else
22440 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22441 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22442 fi
22443 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22444
22445
22446
22447
22448 if test "$gl_cv_next_stdarg_h" = '""'; then
22449 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22450 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22451 fi
22452 else
22453
22454 saved_as_echo_n="$as_echo_n"
22455 as_echo_n=':'
22456 if test "${gl_cv_func___va_copy+set}" = set; then :
22457 $as_echo_n "(cached) " >&6
22458 else
22459
22460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22461 /* end confdefs.h. */
22462 #include <stdarg.h>
22463 int
22464 main ()
22465 {
22466
22467 #ifndef __va_copy
22468 error, bail out
22469 #endif
22470
22471 ;
22472 return 0;
22473 }
22474 _ACEOF
22475 if ac_fn_c_try_compile "$LINENO"; then :
22476 gl_cv_func___va_copy=yes
22477 else
22478 gl_cv_func___va_copy=no
22479 fi
22480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22481 fi
22482
22483 as_echo_n="$saved_as_echo_n"
22484
22485 if test $gl_cv_func___va_copy = yes; then
22486
22487 $as_echo "#define va_copy __va_copy" >>confdefs.h
22488
22489 else
22490
22491
22492 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22493
22494 fi
22495 fi
22496 fi
22497
22498 if test -n "$STDARG_H"; then
22499 GL_GENERATE_STDARG_H_TRUE=
22500 GL_GENERATE_STDARG_H_FALSE='#'
22501 else
22502 GL_GENERATE_STDARG_H_TRUE='#'
22503 GL_GENERATE_STDARG_H_FALSE=
22504 fi
22505
22506
22507
22508
22509
22510
22511 # Define two additional variables used in the Makefile substitution.
22512
22513 if test "$ac_cv_header_stdbool_h" = yes; then
22514 STDBOOL_H=''
22515 else
22516 STDBOOL_H='stdbool.h'
22517 fi
22518
22519 if test -n "$STDBOOL_H"; then
22520 GL_GENERATE_STDBOOL_H_TRUE=
22521 GL_GENERATE_STDBOOL_H_FALSE='#'
22522 else
22523 GL_GENERATE_STDBOOL_H_TRUE='#'
22524 GL_GENERATE_STDBOOL_H_FALSE=
22525 fi
22526
22527
22528 if test "$ac_cv_type__Bool" = yes; then
22529 HAVE__BOOL=1
22530 else
22531 HAVE__BOOL=0
22532 fi
22533
22534
22535
22536
22537
22538 STDDEF_H=
22539 if test $gt_cv_c_wchar_t = no; then
22540 HAVE_WCHAR_T=0
22541 STDDEF_H=stddef.h
22542 fi
22543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22544 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22545 if test "${gl_cv_decl_null_works+set}" = set; then :
22546 $as_echo_n "(cached) " >&6
22547 else
22548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22549 /* end confdefs.h. */
22550 #include <stddef.h>
22551 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22552
22553 int
22554 main ()
22555 {
22556
22557 ;
22558 return 0;
22559 }
22560 _ACEOF
22561 if ac_fn_c_try_compile "$LINENO"; then :
22562 gl_cv_decl_null_works=yes
22563 else
22564 gl_cv_decl_null_works=no
22565 fi
22566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22567 fi
22568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22569 $as_echo "$gl_cv_decl_null_works" >&6; }
22570 if test $gl_cv_decl_null_works = no; then
22571 REPLACE_NULL=1
22572 STDDEF_H=stddef.h
22573 fi
22574
22575 if test -n "$STDDEF_H"; then
22576 GL_GENERATE_STDDEF_H_TRUE=
22577 GL_GENERATE_STDDEF_H_FALSE='#'
22578 else
22579 GL_GENERATE_STDDEF_H_TRUE='#'
22580 GL_GENERATE_STDDEF_H_FALSE=
22581 fi
22582
22583 if test -n "$STDDEF_H"; then
22584
22585
22586
22587
22588
22589
22590
22591
22592 if test $gl_cv_have_include_next = yes; then
22593 gl_cv_next_stddef_h='<'stddef.h'>'
22594 else
22595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22596 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22597 if test "${gl_cv_next_stddef_h+set}" = set; then :
22598 $as_echo_n "(cached) " >&6
22599 else
22600
22601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22602 /* end confdefs.h. */
22603 #include <stddef.h>
22604
22605 _ACEOF
22606 case "$host_os" in
22607 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22608 *) gl_absname_cpp="$ac_cpp" ;;
22609 esac
22610
22611 case "$host_os" in
22612 mingw*)
22613 gl_dirsep_regex='[/\\]'
22614 ;;
22615 *)
22616 gl_dirsep_regex='\/'
22617 ;;
22618 esac
22619 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22620
22621 gl_header_literal_regex=`echo 'stddef.h' \
22622 | sed -e "$gl_make_literal_regex_sed"`
22623 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22624 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22625 s|^/[^/]|//&|
22626 p
22627 q
22628 }'
22629 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22630 sed -n "$gl_absolute_header_sed"`'"'
22631
22632
22633 fi
22634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
22635 $as_echo "$gl_cv_next_stddef_h" >&6; }
22636 fi
22637 NEXT_STDDEF_H=$gl_cv_next_stddef_h
22638
22639 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22640 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22641 gl_next_as_first_directive='<'stddef.h'>'
22642 else
22643 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22644 gl_next_as_first_directive=$gl_cv_next_stddef_h
22645 fi
22646 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
22647
22648
22649
22650
22651 fi
22652
22653
22654
22655
22656
22657
22658
22659
22660
22661
22662
22663
22664
22665 if test $gl_cv_have_include_next = yes; then
22666 gl_cv_next_stdio_h='<'stdio.h'>'
22667 else
22668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
22669 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
22670 if test "${gl_cv_next_stdio_h+set}" = set; then :
22671 $as_echo_n "(cached) " >&6
22672 else
22673
22674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22675 /* end confdefs.h. */
22676 #include <stdio.h>
22677
22678 _ACEOF
22679 case "$host_os" in
22680 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22681 *) gl_absname_cpp="$ac_cpp" ;;
22682 esac
22683
22684 case "$host_os" in
22685 mingw*)
22686 gl_dirsep_regex='[/\\]'
22687 ;;
22688 *)
22689 gl_dirsep_regex='\/'
22690 ;;
22691 esac
22692 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22693
22694 gl_header_literal_regex=`echo 'stdio.h' \
22695 | sed -e "$gl_make_literal_regex_sed"`
22696 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22697 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22698 s|^/[^/]|//&|
22699 p
22700 q
22701 }'
22702 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22703 sed -n "$gl_absolute_header_sed"`'"'
22704
22705
22706 fi
22707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
22708 $as_echo "$gl_cv_next_stdio_h" >&6; }
22709 fi
22710 NEXT_STDIO_H=$gl_cv_next_stdio_h
22711
22712 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22713 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22714 gl_next_as_first_directive='<'stdio.h'>'
22715 else
22716 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22717 gl_next_as_first_directive=$gl_cv_next_stdio_h
22718 fi
22719 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
22720
22721
22722
22723
22724
22725 GNULIB_FSCANF=1
22726
22727
22728 cat >>confdefs.h <<_ACEOF
22729 #define GNULIB_FSCANF 1
22730 _ACEOF
22731
22732
22733 GNULIB_SCANF=1
22734
22735
22736 cat >>confdefs.h <<_ACEOF
22737 #define GNULIB_SCANF 1
22738 _ACEOF
22739
22740
22741 GNULIB_FGETC=1
22742 GNULIB_GETC=1
22743 GNULIB_GETCHAR=1
22744 GNULIB_FGETS=1
22745 GNULIB_FREAD=1
22746
22747
22748 GNULIB_FPRINTF=1
22749 GNULIB_PRINTF=1
22750 GNULIB_VFPRINTF=1
22751 GNULIB_VPRINTF=1
22752 GNULIB_FPUTC=1
22753 GNULIB_PUTC=1
22754 GNULIB_PUTCHAR=1
22755 GNULIB_FPUTS=1
22756 GNULIB_PUTS=1
22757 GNULIB_FWRITE=1
22758
22759
22760
22761
22762
22763
22764
22765
22766
22767
22768
22769
22770
22771
22772
22773 if test $gl_cv_have_include_next = yes; then
22774 gl_cv_next_stdlib_h='<'stdlib.h'>'
22775 else
22776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
22777 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
22778 if test "${gl_cv_next_stdlib_h+set}" = set; then :
22779 $as_echo_n "(cached) " >&6
22780 else
22781
22782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22783 /* end confdefs.h. */
22784 #include <stdlib.h>
22785
22786 _ACEOF
22787 case "$host_os" in
22788 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22789 *) gl_absname_cpp="$ac_cpp" ;;
22790 esac
22791
22792 case "$host_os" in
22793 mingw*)
22794 gl_dirsep_regex='[/\\]'
22795 ;;
22796 *)
22797 gl_dirsep_regex='\/'
22798 ;;
22799 esac
22800 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22801
22802 gl_header_literal_regex=`echo 'stdlib.h' \
22803 | sed -e "$gl_make_literal_regex_sed"`
22804 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22805 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22806 s|^/[^/]|//&|
22807 p
22808 q
22809 }'
22810 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22811 sed -n "$gl_absolute_header_sed"`'"'
22812
22813
22814 fi
22815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
22816 $as_echo "$gl_cv_next_stdlib_h" >&6; }
22817 fi
22818 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
22819
22820 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22821 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22822 gl_next_as_first_directive='<'stdlib.h'>'
22823 else
22824 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22825 gl_next_as_first_directive=$gl_cv_next_stdlib_h
22826 fi
22827 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
22828
22829
22830
22831
22832
22833
22834
22835
22836
22837 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
22838
22839
22840
22841
22842
22843
22844
22845 $as_echo "#define my_strftime nstrftime" >>confdefs.h
22846
22847
22848
22849
22850
22851
22852
22853
22854 if test "$ac_cv_have_decl_strtoimax" != yes; then
22855 HAVE_DECL_STRTOIMAX=0
22856 fi
22857
22858 if test $ac_cv_func_strtoimax = yes; then
22859 HAVE_STRTOIMAX=1
22860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
22861 $as_echo_n "checking whether strtoimax works... " >&6; }
22862 if test "${gl_cv_func_strtoimax+set}" = set; then :
22863 $as_echo_n "(cached) " >&6
22864 else
22865 if test "$cross_compiling" = yes; then :
22866 case "$host_os" in
22867 # Guess no on AIX 5.
22868 aix5*) gl_cv_func_strtoimax="guessing no" ;;
22869 # Guess yes otherwise.
22870 *) gl_cv_func_strtoimax="guessing yes" ;;
22871 esac
22872
22873 else
22874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22875 /* end confdefs.h. */
22876
22877 #include <errno.h>
22878 #include <string.h>
22879 #include <inttypes.h>
22880 int main ()
22881 {
22882 if (sizeof (intmax_t) > sizeof (int))
22883 {
22884 const char *s = "4294967295";
22885 char *p;
22886 intmax_t res;
22887 errno = 0;
22888 res = strtoimax (s, &p, 10);
22889 if (p != s + strlen (s))
22890 return 1;
22891 if (errno != 0)
22892 return 2;
22893 if (res != (intmax_t) 65535 * (intmax_t) 65537)
22894 return 3;
22895 }
22896 else
22897 {
22898 const char *s = "2147483647";
22899 char *p;
22900 intmax_t res;
22901 errno = 0;
22902 res = strtoimax (s, &p, 10);
22903 if (p != s + strlen (s))
22904 return 1;
22905 if (errno != 0)
22906 return 2;
22907 if (res != 2147483647)
22908 return 3;
22909 }
22910 return 0;
22911 }
22912
22913 _ACEOF
22914 if ac_fn_c_try_run "$LINENO"; then :
22915 gl_cv_func_strtoimax=yes
22916 else
22917 gl_cv_func_strtoimax=no
22918 fi
22919 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22920 conftest.$ac_objext conftest.beam conftest.$ac_ext
22921 fi
22922
22923
22924 fi
22925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
22926 $as_echo "$gl_cv_func_strtoimax" >&6; }
22927 case "$gl_cv_func_strtoimax" in
22928 *no) REPLACE_STRTOIMAX=1 ;;
22929 esac
22930 else
22931 HAVE_STRTOIMAX=0
22932 fi
22933
22934 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
22935
22936
22937
22938
22939
22940
22941
22942
22943 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
22944
22945
22946 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
22947 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
22948 ac_have_decl=1
22949 else
22950 ac_have_decl=0
22951 fi
22952
22953 cat >>confdefs.h <<_ACEOF
22954 #define HAVE_DECL_STRTOLL $ac_have_decl
22955 _ACEOF
22956
22957
22958
22959 fi
22960
22961
22962
22963
22964
22965 GNULIB_STRTOIMAX=1
22966
22967
22968
22969
22970
22971
22972
22973
22974
22975 if test "$ac_cv_have_decl_strtoumax" != yes; then
22976 HAVE_DECL_STRTOUMAX=0
22977 fi
22978
22979 if test $ac_cv_func_strtoumax = no; then
22980
22981
22982
22983
22984
22985
22986
22987
22988 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
22989
22990
22991 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
22992 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
22993 ac_have_decl=1
22994 else
22995 ac_have_decl=0
22996 fi
22997
22998 cat >>confdefs.h <<_ACEOF
22999 #define HAVE_DECL_STRTOULL $ac_have_decl
23000 _ACEOF
23001
23002
23003
23004 fi
23005
23006
23007
23008
23009
23010 GNULIB_STRTOUMAX=1
23011
23012
23013
23014
23015
23016
23017
23018 if test $ac_cv_func_symlink = no; then
23019 HAVE_SYMLINK=0
23020 else
23021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23022 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23023 if test "${gl_cv_func_symlink_works+set}" = set; then :
23024 $as_echo_n "(cached) " >&6
23025 else
23026 if test "$cross_compiling" = yes; then :
23027 case "$host_os" in
23028 # Guess yes on glibc systems.
23029 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23030 # If we don't know, assume the worst.
23031 *) gl_cv_func_symlink_works="guessing no" ;;
23032 esac
23033
23034 else
23035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23036 /* end confdefs.h. */
23037 #include <unistd.h>
23038
23039 int
23040 main ()
23041 {
23042 int result = 0;
23043 if (!symlink ("a", "conftest.link/"))
23044 result |= 1;
23045 if (symlink ("conftest.f", "conftest.lnk2"))
23046 result |= 2;
23047 else if (!symlink ("a", "conftest.lnk2/"))
23048 result |= 4;
23049 return result;
23050
23051 ;
23052 return 0;
23053 }
23054 _ACEOF
23055 if ac_fn_c_try_run "$LINENO"; then :
23056 gl_cv_func_symlink_works=yes
23057 else
23058 gl_cv_func_symlink_works=no
23059 fi
23060 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23061 conftest.$ac_objext conftest.beam conftest.$ac_ext
23062 fi
23063
23064 rm -f conftest.f conftest.link conftest.lnk2
23065 fi
23066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23067 $as_echo "$gl_cv_func_symlink_works" >&6; }
23068 case "$gl_cv_func_symlink_works" in
23069 *yes) ;;
23070 *)
23071 REPLACE_SYMLINK=1
23072 ;;
23073 esac
23074 fi
23075
23076 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23077
23078
23079
23080
23081
23082
23083
23084
23085 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
23086
23087 fi
23088
23089
23090
23091
23092
23093 GNULIB_SYMLINK=1
23094
23095
23096
23097
23098
23099
23100
23101
23102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
23103 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
23104 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
23105 $as_echo_n "(cached) " >&6
23106 else
23107
23108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23109 /* end confdefs.h. */
23110 #include <sys/select.h>
23111 int
23112 main ()
23113 {
23114 struct timeval b;
23115 ;
23116 return 0;
23117 }
23118 _ACEOF
23119 if ac_fn_c_try_compile "$LINENO"; then :
23120 gl_cv_header_sys_select_h_selfcontained=yes
23121 else
23122 gl_cv_header_sys_select_h_selfcontained=no
23123 fi
23124 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23125 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
23126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23127 /* end confdefs.h. */
23128 #include <sys/select.h>
23129 int
23130 main ()
23131 {
23132 int memset; int bzero;
23133 ;
23134 return 0;
23135 }
23136
23137 _ACEOF
23138 if ac_fn_c_try_compile "$LINENO"; then :
23139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23140 /* end confdefs.h. */
23141 #include <sys/select.h>
23142 int
23143 main ()
23144 {
23145
23146 #undef memset
23147 #define memset nonexistent_memset
23148 extern
23149 #ifdef __cplusplus
23150 "C"
23151 #endif
23152 void *memset (void *, int, unsigned long);
23153 #undef bzero
23154 #define bzero nonexistent_bzero
23155 extern
23156 #ifdef __cplusplus
23157 "C"
23158 #endif
23159 void bzero (void *, unsigned long);
23160 fd_set fds;
23161 FD_ZERO (&fds);
23162
23163 ;
23164 return 0;
23165 }
23166
23167 _ACEOF
23168 if ac_fn_c_try_link "$LINENO"; then :
23169
23170 else
23171 gl_cv_header_sys_select_h_selfcontained=no
23172 fi
23173 rm -f core conftest.err conftest.$ac_objext \
23174 conftest$ac_exeext conftest.$ac_ext
23175
23176 fi
23177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23178 fi
23179
23180 fi
23181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
23182 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
23183
23184
23185
23186
23187
23188
23189
23190
23191
23192 if test $gl_cv_have_include_next = yes; then
23193 gl_cv_next_sys_select_h='<'sys/select.h'>'
23194 else
23195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
23196 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
23197 if test "${gl_cv_next_sys_select_h+set}" = set; then :
23198 $as_echo_n "(cached) " >&6
23199 else
23200
23201 if test $ac_cv_header_sys_select_h = yes; then
23202
23203
23204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23205 /* end confdefs.h. */
23206 #include <sys/select.h>
23207
23208 _ACEOF
23209 case "$host_os" in
23210 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23211 *) gl_absname_cpp="$ac_cpp" ;;
23212 esac
23213
23214 case "$host_os" in
23215 mingw*)
23216 gl_dirsep_regex='[/\\]'
23217 ;;
23218 *)
23219 gl_dirsep_regex='\/'
23220 ;;
23221 esac
23222 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23223
23224 gl_header_literal_regex=`echo 'sys/select.h' \
23225 | sed -e "$gl_make_literal_regex_sed"`
23226 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23227 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23228 s|^/[^/]|//&|
23229 p
23230 q
23231 }'
23232 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23233 sed -n "$gl_absolute_header_sed"`'"'
23234 else
23235 gl_cv_next_sys_select_h='<'sys/select.h'>'
23236 fi
23237
23238
23239 fi
23240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
23241 $as_echo "$gl_cv_next_sys_select_h" >&6; }
23242 fi
23243 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
23244
23245 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23246 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23247 gl_next_as_first_directive='<'sys/select.h'>'
23248 else
23249 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23250 gl_next_as_first_directive=$gl_cv_next_sys_select_h
23251 fi
23252 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
23253
23254
23255
23256
23257 if test $ac_cv_header_sys_select_h = yes; then
23258 HAVE_SYS_SELECT_H=1
23259 else
23260 HAVE_SYS_SELECT_H=0
23261 fi
23262
23263
23264
23265
23266
23267 if test $ac_cv_header_sys_socket_h != yes; then
23268 for ac_header in winsock2.h
23269 do :
23270 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23271 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
23272 cat >>confdefs.h <<_ACEOF
23273 #define HAVE_WINSOCK2_H 1
23274 _ACEOF
23275
23276 fi
23277
23278 done
23279
23280 fi
23281 if test "$ac_cv_header_winsock2_h" = yes; then
23282 HAVE_WINSOCK2_H=1
23283 UNISTD_H_HAVE_WINSOCK2_H=1
23284 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23285 else
23286 HAVE_WINSOCK2_H=0
23287 fi
23288
23289
23290
23291
23292
23293
23294
23295
23296
23297
23298
23299
23300
23301
23302
23303
23304
23305
23306
23307
23308
23309
23310 if test $gl_cv_have_include_next = yes; then
23311 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23312 else
23313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23314 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23315 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
23316 $as_echo_n "(cached) " >&6
23317 else
23318
23319 if test $ac_cv_header_sys_stat_h = yes; then
23320
23321
23322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23323 /* end confdefs.h. */
23324 #include <sys/stat.h>
23325
23326 _ACEOF
23327 case "$host_os" in
23328 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23329 *) gl_absname_cpp="$ac_cpp" ;;
23330 esac
23331
23332 case "$host_os" in
23333 mingw*)
23334 gl_dirsep_regex='[/\\]'
23335 ;;
23336 *)
23337 gl_dirsep_regex='\/'
23338 ;;
23339 esac
23340 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23341
23342 gl_header_literal_regex=`echo 'sys/stat.h' \
23343 | sed -e "$gl_make_literal_regex_sed"`
23344 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23345 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23346 s|^/[^/]|//&|
23347 p
23348 q
23349 }'
23350 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23351 sed -n "$gl_absolute_header_sed"`'"'
23352 else
23353 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23354 fi
23355
23356
23357 fi
23358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23359 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23360 fi
23361 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23362
23363 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23364 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23365 gl_next_as_first_directive='<'sys/stat.h'>'
23366 else
23367 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23368 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23369 fi
23370 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23371
23372
23373
23374
23375
23376
23377
23378
23379
23380
23381
23382 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23383
23384 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23385
23386 fi
23387
23388 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23389 #include <sys/stat.h>
23390 "
23391 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23392
23393 else
23394
23395 $as_echo "#define nlink_t int" >>confdefs.h
23396
23397 fi
23398
23399
23400
23401
23402
23403
23404
23405
23406
23407
23408
23409
23410
23411
23412
23413
23414
23415
23416 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23417 "
23418 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23419 ac_have_decl=1
23420 else
23421 ac_have_decl=0
23422 fi
23423
23424 cat >>confdefs.h <<_ACEOF
23425 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23426 _ACEOF
23427
23428 if test $ac_cv_have_decl_localtime_r = no; then
23429 HAVE_DECL_LOCALTIME_R=0
23430 fi
23431
23432
23433 if test $ac_cv_func_localtime_r = yes; then
23434 HAVE_LOCALTIME_R=1
23435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23436 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23437 if test "${gl_cv_time_r_posix+set}" = set; then :
23438 $as_echo_n "(cached) " >&6
23439 else
23440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23441 /* end confdefs.h. */
23442 #include <time.h>
23443 int
23444 main ()
23445 {
23446 /* We don't need to append 'restrict's to the argument types,
23447 even though the POSIX signature has the 'restrict's,
23448 since C99 says they can't affect type compatibility. */
23449 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23450 if (ptr) return 0;
23451 /* Check the return type is a pointer.
23452 On HP-UX 10 it is 'int'. */
23453 *localtime_r (0, 0);
23454 ;
23455 return 0;
23456 }
23457
23458 _ACEOF
23459 if ac_fn_c_try_compile "$LINENO"; then :
23460 gl_cv_time_r_posix=yes
23461 else
23462 gl_cv_time_r_posix=no
23463 fi
23464 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23465
23466 fi
23467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23468 $as_echo "$gl_cv_time_r_posix" >&6; }
23469 if test $gl_cv_time_r_posix = yes; then
23470 REPLACE_LOCALTIME_R=0
23471 else
23472 REPLACE_LOCALTIME_R=1
23473 fi
23474 else
23475 HAVE_LOCALTIME_R=0
23476 fi
23477
23478 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23479
23480
23481
23482
23483
23484
23485
23486
23487 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23488
23489
23490 :
23491
23492 fi
23493
23494
23495
23496
23497
23498 GNULIB_TIME_R=1
23499
23500
23501
23502
23503
23504 :
23505
23506
23507
23508
23509
23510
23511
23512
23513
23514
23515
23516
23517
23518 if test $gl_cv_have_include_next = yes; then
23519 gl_cv_next_unistd_h='<'unistd.h'>'
23520 else
23521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23522 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23523 if test "${gl_cv_next_unistd_h+set}" = set; then :
23524 $as_echo_n "(cached) " >&6
23525 else
23526
23527 if test $ac_cv_header_unistd_h = yes; then
23528
23529
23530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23531 /* end confdefs.h. */
23532 #include <unistd.h>
23533
23534 _ACEOF
23535 case "$host_os" in
23536 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23537 *) gl_absname_cpp="$ac_cpp" ;;
23538 esac
23539
23540 case "$host_os" in
23541 mingw*)
23542 gl_dirsep_regex='[/\\]'
23543 ;;
23544 *)
23545 gl_dirsep_regex='\/'
23546 ;;
23547 esac
23548 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23549
23550 gl_header_literal_regex=`echo 'unistd.h' \
23551 | sed -e "$gl_make_literal_regex_sed"`
23552 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23553 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23554 s|^/[^/]|//&|
23555 p
23556 q
23557 }'
23558 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23559 sed -n "$gl_absolute_header_sed"`'"'
23560 else
23561 gl_cv_next_unistd_h='<'unistd.h'>'
23562 fi
23563
23564
23565 fi
23566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
23567 $as_echo "$gl_cv_next_unistd_h" >&6; }
23568 fi
23569 NEXT_UNISTD_H=$gl_cv_next_unistd_h
23570
23571 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23572 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23573 gl_next_as_first_directive='<'unistd.h'>'
23574 else
23575 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23576 gl_next_as_first_directive=$gl_cv_next_unistd_h
23577 fi
23578 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
23579
23580
23581
23582
23583 if test $ac_cv_header_unistd_h = yes; then
23584 HAVE_UNISTD_H=1
23585 else
23586 HAVE_UNISTD_H=0
23587 fi
23588
23589
23590
23591
23592
23593
23594
23595
23596
23597
23598
23599
23600
23601
23602 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
23603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
23604 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
23605 if test "${gl_cv_func_futimesat_works+set}" = set; then :
23606 $as_echo_n "(cached) " >&6
23607 else
23608 touch conftest.file
23609 if test "$cross_compiling" = yes; then :
23610 case "$host_os" in
23611 # Guess yes on glibc systems.
23612 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
23613 # If we don't know, assume the worst.
23614 *) gl_cv_func_futimesat_works="guessing no" ;;
23615 esac
23616
23617 else
23618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23619 /* end confdefs.h. */
23620
23621 #include <stddef.h>
23622 #include <sys/times.h>
23623 #include <fcntl.h>
23624
23625 int
23626 main ()
23627 {
23628 int fd = open ("conftest.file", O_RDWR);
23629 if (fd < 0) return 1;
23630 if (futimesat (fd, NULL, NULL)) return 2;
23631
23632 ;
23633 return 0;
23634 }
23635 _ACEOF
23636 if ac_fn_c_try_run "$LINENO"; then :
23637 gl_cv_func_futimesat_works=yes
23638 else
23639 gl_cv_func_futimesat_works=no
23640 fi
23641 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23642 conftest.$ac_objext conftest.beam conftest.$ac_ext
23643 fi
23644
23645 rm -f conftest.file
23646 fi
23647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
23648 $as_echo "$gl_cv_func_futimesat_works" >&6; }
23649 case "$gl_cv_func_futimesat_works" in
23650 *yes) ;;
23651 *)
23652
23653 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
23654
23655 ;;
23656 esac
23657 fi
23658
23659 gl_gnulib_enabled_dosname=false
23660 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
23661 gl_gnulib_enabled_pathmax=false
23662 gl_gnulib_enabled_stat=false
23663 gl_gnulib_enabled_strtoll=false
23664 gl_gnulib_enabled_strtoull=false
23665 gl_gnulib_enabled_verify=false
23666 func_gl_gnulib_m4code_dosname ()
23667 {
23668 if ! $gl_gnulib_enabled_dosname; then
23669 gl_gnulib_enabled_dosname=true
23670 fi
23671 }
23672 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
23673 {
23674 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23675
23676
23677 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
23678 fi
23679 }
23680 func_gl_gnulib_m4code_pathmax ()
23681 {
23682 if ! $gl_gnulib_enabled_pathmax; then
23683
23684
23685
23686 gl_gnulib_enabled_pathmax=true
23687 fi
23688 }
23689 func_gl_gnulib_m4code_stat ()
23690 {
23691 if ! $gl_gnulib_enabled_stat; then
23692
23693
23694
23695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
23696 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
23697 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
23698 $as_echo_n "(cached) " >&6
23699 else
23700 if test "$cross_compiling" = yes; then :
23701 case $host_os in
23702 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
23703 *) gl_cv_func_stat_dir_slash="guessing yes";;
23704 esac
23705 else
23706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23707 /* end confdefs.h. */
23708 #include <sys/stat.h>
23709
23710 int
23711 main ()
23712 {
23713 struct stat st; return stat (".", &st) != stat ("./", &st);
23714 ;
23715 return 0;
23716 }
23717 _ACEOF
23718 if ac_fn_c_try_run "$LINENO"; then :
23719 gl_cv_func_stat_dir_slash=yes
23720 else
23721 gl_cv_func_stat_dir_slash=no
23722 fi
23723 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23724 conftest.$ac_objext conftest.beam conftest.$ac_ext
23725 fi
23726
23727 fi
23728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
23729 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
23730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
23731 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
23732 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
23733 $as_echo_n "(cached) " >&6
23734 else
23735 touch conftest.tmp
23736 # Assume that if we have lstat, we can also check symlinks.
23737 if test $ac_cv_func_lstat = yes; then
23738 ln -s conftest.tmp conftest.lnk
23739 fi
23740 if test "$cross_compiling" = yes; then :
23741 case "$host_os" in
23742 # Guess yes on glibc systems.
23743 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
23744 # If we don't know, assume the worst.
23745 *) gl_cv_func_stat_file_slash="guessing no" ;;
23746 esac
23747
23748 else
23749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23750 /* end confdefs.h. */
23751 #include <sys/stat.h>
23752
23753 int
23754 main ()
23755 {
23756 int result = 0;
23757 struct stat st;
23758 if (!stat ("conftest.tmp/", &st))
23759 result |= 1;
23760 #if HAVE_LSTAT
23761 if (!stat ("conftest.lnk/", &st))
23762 result |= 2;
23763 #endif
23764 return result;
23765
23766 ;
23767 return 0;
23768 }
23769 _ACEOF
23770 if ac_fn_c_try_run "$LINENO"; then :
23771 gl_cv_func_stat_file_slash=yes
23772 else
23773 gl_cv_func_stat_file_slash=no
23774 fi
23775 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23776 conftest.$ac_objext conftest.beam conftest.$ac_ext
23777 fi
23778
23779 rm -f conftest.tmp conftest.lnk
23780 fi
23781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
23782 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
23783 case $gl_cv_func_stat_dir_slash in
23784 *no) REPLACE_STAT=1
23785
23786 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
23787 ;;
23788 esac
23789 case $gl_cv_func_stat_file_slash in
23790 *no) REPLACE_STAT=1
23791
23792 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
23793 ;;
23794 esac
23795
23796 if test $REPLACE_STAT = 1; then
23797
23798
23799
23800
23801
23802
23803
23804
23805 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
23806
23807
23808
23809 :
23810
23811 fi
23812
23813
23814
23815
23816
23817 GNULIB_STAT=1
23818
23819
23820
23821
23822
23823 gl_gnulib_enabled_stat=true
23824 if test $REPLACE_STAT = 1; then
23825 func_gl_gnulib_m4code_dosname
23826 fi
23827 if test $REPLACE_STAT = 1; then
23828 func_gl_gnulib_m4code_pathmax
23829 fi
23830 if test $REPLACE_STAT = 1; then
23831 func_gl_gnulib_m4code_verify
23832 fi
23833 fi
23834 }
23835 func_gl_gnulib_m4code_strtoll ()
23836 {
23837 if ! $gl_gnulib_enabled_strtoll; then
23838
23839
23840
23841 if test "$ac_cv_type_long_long_int" = yes; then
23842 for ac_func in strtoll
23843 do :
23844 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
23845 if test "x$ac_cv_func_strtoll" = x""yes; then :
23846 cat >>confdefs.h <<_ACEOF
23847 #define HAVE_STRTOLL 1
23848 _ACEOF
23849
23850 fi
23851 done
23852
23853 if test $ac_cv_func_strtoll = no; then
23854 HAVE_STRTOLL=0
23855 fi
23856 fi
23857
23858 if test $HAVE_STRTOLL = 0; then
23859
23860
23861
23862
23863
23864
23865
23866
23867 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
23868
23869
23870 :
23871
23872 fi
23873
23874
23875
23876
23877
23878 GNULIB_STRTOLL=1
23879
23880
23881
23882
23883
23884 gl_gnulib_enabled_strtoll=true
23885 fi
23886 }
23887 func_gl_gnulib_m4code_strtoull ()
23888 {
23889 if ! $gl_gnulib_enabled_strtoull; then
23890
23891
23892
23893 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
23894 for ac_func in strtoull
23895 do :
23896 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
23897 if test "x$ac_cv_func_strtoull" = x""yes; then :
23898 cat >>confdefs.h <<_ACEOF
23899 #define HAVE_STRTOULL 1
23900 _ACEOF
23901
23902 fi
23903 done
23904
23905 if test $ac_cv_func_strtoull = no; then
23906 HAVE_STRTOULL=0
23907 fi
23908 fi
23909
23910 if test $HAVE_STRTOULL = 0; then
23911
23912
23913
23914
23915
23916
23917
23918
23919 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
23920
23921
23922 :
23923
23924 fi
23925
23926
23927
23928
23929
23930 GNULIB_STRTOULL=1
23931
23932
23933
23934
23935
23936 gl_gnulib_enabled_strtoull=true
23937 fi
23938 }
23939 func_gl_gnulib_m4code_verify ()
23940 {
23941 if ! $gl_gnulib_enabled_verify; then
23942 gl_gnulib_enabled_verify=true
23943 fi
23944 }
23945 if test $REPLACE_GETOPT = 1; then
23946 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
23947 fi
23948 if test $REPLACE_LSTAT = 1; then
23949 func_gl_gnulib_m4code_dosname
23950 fi
23951 if test $REPLACE_LSTAT = 1; then
23952 func_gl_gnulib_m4code_stat
23953 fi
23954 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
23955 func_gl_gnulib_m4code_stat
23956 fi
23957 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
23958 func_gl_gnulib_m4code_strtoll
23959 fi
23960 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23961 func_gl_gnulib_m4code_verify
23962 fi
23963 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
23964 func_gl_gnulib_m4code_strtoull
23965 fi
23966 if test $ac_cv_func_strtoumax = no; then
23967 func_gl_gnulib_m4code_verify
23968 fi
23969
23970 if $gl_gnulib_enabled_dosname; then
23971 gl_GNULIB_ENABLED_dosname_TRUE=
23972 gl_GNULIB_ENABLED_dosname_FALSE='#'
23973 else
23974 gl_GNULIB_ENABLED_dosname_TRUE='#'
23975 gl_GNULIB_ENABLED_dosname_FALSE=
23976 fi
23977
23978 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23979 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
23980 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
23981 else
23982 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
23983 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
23984 fi
23985
23986 if $gl_gnulib_enabled_pathmax; then
23987 gl_GNULIB_ENABLED_pathmax_TRUE=
23988 gl_GNULIB_ENABLED_pathmax_FALSE='#'
23989 else
23990 gl_GNULIB_ENABLED_pathmax_TRUE='#'
23991 gl_GNULIB_ENABLED_pathmax_FALSE=
23992 fi
23993
23994 if $gl_gnulib_enabled_stat; then
23995 gl_GNULIB_ENABLED_stat_TRUE=
23996 gl_GNULIB_ENABLED_stat_FALSE='#'
23997 else
23998 gl_GNULIB_ENABLED_stat_TRUE='#'
23999 gl_GNULIB_ENABLED_stat_FALSE=
24000 fi
24001
24002 if $gl_gnulib_enabled_strtoll; then
24003 gl_GNULIB_ENABLED_strtoll_TRUE=
24004 gl_GNULIB_ENABLED_strtoll_FALSE='#'
24005 else
24006 gl_GNULIB_ENABLED_strtoll_TRUE='#'
24007 gl_GNULIB_ENABLED_strtoll_FALSE=
24008 fi
24009
24010 if $gl_gnulib_enabled_strtoull; then
24011 gl_GNULIB_ENABLED_strtoull_TRUE=
24012 gl_GNULIB_ENABLED_strtoull_FALSE='#'
24013 else
24014 gl_GNULIB_ENABLED_strtoull_TRUE='#'
24015 gl_GNULIB_ENABLED_strtoull_FALSE=
24016 fi
24017
24018 if $gl_gnulib_enabled_verify; then
24019 gl_GNULIB_ENABLED_verify_TRUE=
24020 gl_GNULIB_ENABLED_verify_FALSE='#'
24021 else
24022 gl_GNULIB_ENABLED_verify_TRUE='#'
24023 gl_GNULIB_ENABLED_verify_FALSE=
24024 fi
24025
24026 # End of code from modules
24027
24028
24029
24030
24031
24032
24033
24034
24035
24036 gltests_libdeps=
24037 gltests_ltlibdeps=
24038
24039
24040
24041
24042
24043
24044
24045
24046
24047 gl_source_base='tests'
24048 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
24049
24050 gl_module_indicator_condition=$gltests_WITNESS
24051
24052
24053
24054
24055
24056
24057
24058
24059
24060
24061 LIBGNU_LIBDEPS="$gl_libdeps"
24062
24063 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
24064
24065
24066 CFLAGS=$SAVE_CFLAGS
24067 LIBS=$SAVE_LIBS
24068
24069 case "$opsys" in
24070 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
24071
24072 darwin)
24073 ## The -headerpad option tells ld (see man page) to leave room at the
24074 ## end of the header for adding load commands. Needed for dumping.
24075 ## 0x690 is the total size of 30 segment load commands (at 56
24076 ## each); under Cocoa 31 commands are required.
24077 if test "$HAVE_NS" = "yes"; then
24078 libs_nsgui="-framework AppKit"
24079 headerpad_extra=6C8
24080 else
24081 libs_nsgui=
24082 headerpad_extra=690
24083 fi
24084 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
24085
24086 ## This is here because src/Makefile.in did some extra fiddling around
24087 ## with LD_SWITCH_SYSTEM. The cpp logic was:
24088 ## #ifndef LD_SWITCH_SYSTEM
24089 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
24090 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
24091 ## not using gcc, darwin.
24092 ## Because this was done in src/Makefile.in, the resulting part of
24093 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
24094 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
24095 ## rather than LD_SWITCH_SYSTEM.
24096 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
24097 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
24098 ;;
24099
24100 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
24101 ## find X at run-time.
24102 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
24103 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
24104 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
24105 ## had different values in configure (in ac_link) and src/Makefile.in.
24106 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
24107 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
24108
24109 *) LD_SWITCH_SYSTEM_TEMACS= ;;
24110 esac
24111
24112 if test "$NS_IMPL_GNUSTEP" = "yes"; then
24113 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
24114 fi
24115
24116
24117
24118
24119 LD_FIRSTFLAG=
24120 ORDINARY_LINK=
24121 case "$opsys" in
24122 ## gnu: GNU needs its own crt0.
24123 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
24124
24125 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
24126 ## library search parth, i.e. it won't search /usr/lib for libc and
24127 ## friends. Using -nostartfiles instead avoids this problem, and
24128 ## will also work on earlier NetBSD releases.
24129 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
24130
24131 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
24132 ## MkLinux/LinuxPPC needs this.
24133 ## s390x-* only supports opsys = gnu-linux so it can be added here.
24134 gnu-*)
24135 case "$canonical" in
24136 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
24137 esac
24138 ;;
24139 esac
24140
24141
24142 if test "x$ORDINARY_LINK" = "xyes"; then
24143
24144 LD_FIRSTFLAG=""
24145
24146 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
24147
24148
24149 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
24150 ## freebsd, gnu-* not on powerpc*|s390x*.
24151 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
24152
24153 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
24154 ## places that are difficult to figure out at make time. Fortunately,
24155 ## these same versions allow you to pass arbitrary flags on to the
24156 ## linker, so there is no reason not to use it as a linker.
24157 ##
24158 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
24159 ## searching for libraries in its internal directories, so we have to
24160 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
24161 LD_FIRSTFLAG="-nostdlib"
24162 fi
24163
24164 ## FIXME? What setting of EDIT_LDFLAGS should this have?
24165 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
24166
24167
24168
24169
24170 ## FIXME? The logic here is not precisely the same as that above.
24171 ## There is no check here for a pre-defined LD_FIRSTFLAG.
24172 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
24173 LIB_GCC=
24174 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
24175
24176 case "$opsys" in
24177 freebsd|netbsd|openbsd) LIB_GCC= ;;
24178
24179 gnu-*)
24180 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
24181 ## build on ARM EABI under GNU/Linux. (Bug#5518)
24182 case $host_cpu in
24183 arm*)
24184 LIB_GCC="-lgcc_s"
24185 ;;
24186 *)
24187 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
24188 ## immediately undefine it again and redefine it to empty.
24189 ## Was the C_SWITCH_X_SITE part really necessary?
24190 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
24191 LIB_GCC=
24192 ;;
24193 esac
24194 ;;
24195
24196 ## Ask GCC where to find libgcc.a.
24197 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
24198 esac
24199 fi
24200
24201 ## Common for all window systems
24202 if test "$window_system" != "none"; then
24203
24204 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
24205
24206
24207 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
24208
24209 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
24210 fi
24211
24212
24213
24214
24215
24216 #### Report on what we decided to do.
24217 #### Report GTK as a toolkit, even if it doesn't use Xt.
24218 #### It makes printing result more understandable as using GTK sets
24219 #### toolkit_scroll_bars to yes by default.
24220 if test "${HAVE_GTK}" = "yes"; then
24221 if test "${with_gtk3}" = "yes"; then
24222 USE_X_TOOLKIT=GTK3
24223 else
24224 USE_X_TOOLKIT=GTK
24225 fi
24226 fi
24227
24228 echo "
24229 Configured for \`${canonical}'.
24230
24231 Where should the build process find the source code? ${srcdir}
24232 What compiler should emacs be built with? ${CC} ${CFLAGS}
24233 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
24234 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
24235 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
24236 What window system should Emacs use? ${window_system}
24237 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
24238
24239 if test -n "${x_includes}"; then
24240 echo " Where do we find X Windows header files? ${x_includes}"
24241 else
24242 echo " Where do we find X Windows header files? Standard dirs"
24243 fi
24244 if test -n "${x_libraries}"; then
24245 echo " Where do we find X Windows libraries? ${x_libraries}"
24246 else
24247 echo " Where do we find X Windows libraries? Standard dirs"
24248 fi
24249
24250 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
24251 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
24252 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
24253 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
24254 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
24255 echo " Does Emacs use -lpng? ${HAVE_PNG}"
24256 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
24257 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
24258
24259 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
24260 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
24261 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
24262 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
24263 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
24264 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
24265 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
24266
24267 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
24268 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
24269 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
24270 echo " Does Emacs use -lxft? ${HAVE_XFT}"
24271
24272 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
24273 echo
24274
24275 if test -n "${EMACSDATA}"; then
24276 echo " Environment variable EMACSDATA set to: $EMACSDATA"
24277 fi
24278 if test -n "${EMACSDOC}"; then
24279 echo " Environment variable EMACSDOC set to: $EMACSDOC"
24280 fi
24281
24282 echo
24283
24284 if test "$HAVE_NS" = "yes"; then
24285 echo
24286 echo "You must run \"${MAKE-make} install\" in order to test the built application.
24287 The installed application will go to nextstep/Emacs.app and can be
24288 run or moved from there."
24289 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
24290 echo "The application will be fully self-contained."
24291 else
24292 echo "The lisp resources for the application will be installed under ${prefix}.
24293 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
24294 to run if these resources are not installed."
24295 fi
24296 echo
24297 fi
24298
24299 if test "${opsys}" = "cygwin"; then
24300 case `uname -r` in
24301 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
24302 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
24303 echo
24304 ;;
24305 esac
24306 fi
24307
24308 # Remove any trailing slashes in these variables.
24309 test "${prefix}" != NONE &&
24310 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
24311 test "${exec_prefix}" != NONE &&
24312 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
24313
24314 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"
24315
24316 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"
24317
24318
24319 opt_makefile=test/automated/Makefile
24320
24321 if test -f $srcdir/${opt_makefile}.in; then
24322 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24323 ac_config_files="$ac_config_files test/automated/Makefile"
24324
24325 fi
24326
24327
24328 opt_makefile=admin/unidata/Makefile
24329
24330 if test -f $srcdir/${opt_makefile}.in; then
24331 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24332 ac_config_files="$ac_config_files admin/unidata/Makefile"
24333
24334 fi
24335
24336
24337 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
24338
24339
24340
24341 ac_config_commands="$ac_config_commands mkdirs"
24342
24343
24344 ac_config_commands="$ac_config_commands epaths"
24345
24346
24347 ac_config_commands="$ac_config_commands gdbinit"
24348
24349
24350 cat >confcache <<\_ACEOF
24351 # This file is a shell script that caches the results of configure
24352 # tests run on this system so they can be shared between configure
24353 # scripts and configure runs, see configure's option --config-cache.
24354 # It is not useful on other systems. If it contains results you don't
24355 # want to keep, you may remove or edit it.
24356 #
24357 # config.status only pays attention to the cache file if you give it
24358 # the --recheck option to rerun configure.
24359 #
24360 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24361 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24362 # following values.
24363
24364 _ACEOF
24365
24366 # The following way of writing the cache mishandles newlines in values,
24367 # but we know of no workaround that is simple, portable, and efficient.
24368 # So, we kill variables containing newlines.
24369 # Ultrix sh set writes to stderr and can't be redirected directly,
24370 # and sets the high bit in the cache file unless we assign to the vars.
24371 (
24372 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24373 eval ac_val=\$$ac_var
24374 case $ac_val in #(
24375 *${as_nl}*)
24376 case $ac_var in #(
24377 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24378 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24379 esac
24380 case $ac_var in #(
24381 _ | IFS | as_nl) ;; #(
24382 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24383 *) { eval $ac_var=; unset $ac_var;} ;;
24384 esac ;;
24385 esac
24386 done
24387
24388 (set) 2>&1 |
24389 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24390 *${as_nl}ac_space=\ *)
24391 # `set' does not quote correctly, so add quotes: double-quote
24392 # substitution turns \\\\ into \\, and sed turns \\ into \.
24393 sed -n \
24394 "s/'/'\\\\''/g;
24395 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24396 ;; #(
24397 *)
24398 # `set' quotes correctly as required by POSIX, so do not add quotes.
24399 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24400 ;;
24401 esac |
24402 sort
24403 ) |
24404 sed '
24405 /^ac_cv_env_/b end
24406 t clear
24407 :clear
24408 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24409 t end
24410 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24411 :end' >>confcache
24412 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24413 if test -w "$cache_file"; then
24414 test "x$cache_file" != "x/dev/null" &&
24415 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24416 $as_echo "$as_me: updating cache $cache_file" >&6;}
24417 cat confcache >$cache_file
24418 else
24419 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24420 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24421 fi
24422 fi
24423 rm -f confcache
24424
24425 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24426 # Let make expand exec_prefix.
24427 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24428
24429 DEFS=-DHAVE_CONFIG_H
24430
24431 ac_libobjs=
24432 ac_ltlibobjs=
24433 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24434 # 1. Remove the extension, and $U if already installed.
24435 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24436 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24437 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24438 # will be set to the directory where LIBOBJS objects are built.
24439 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24440 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24441 done
24442 LIBOBJS=$ac_libobjs
24443
24444 LTLIBOBJS=$ac_ltlibobjs
24445
24446
24447 if test -n "$EXEEXT"; then
24448 am__EXEEXT_TRUE=
24449 am__EXEEXT_FALSE='#'
24450 else
24451 am__EXEEXT_TRUE='#'
24452 am__EXEEXT_FALSE=
24453 fi
24454
24455 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24456 as_fn_error "conditional \"AMDEP\" was never defined.
24457 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24458 fi
24459 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24460 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24461 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24462 fi
24463 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24464 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24465 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24466 fi
24467 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24468 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24469 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24470 fi
24471
24472 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
24473 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
24474 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24475 fi
24476 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24477 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24478 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24479 fi
24480 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
24481 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
24482 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24483 fi
24484 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
24485 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
24486 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24487 fi
24488 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24489 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24490 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24491 fi
24492 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24493 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24494 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24495 fi
24496 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
24497 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
24498 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24499 fi
24500 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
24501 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
24502 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24503 fi
24504 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
24505 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
24506 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24507 fi
24508 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
24509 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
24510 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24511 fi
24512 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
24513 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
24514 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24515 fi
24516 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
24517 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
24518 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24519 fi
24520 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
24521 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
24522 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24523 fi
24524
24525 gl_libobjs=
24526 gl_ltlibobjs=
24527 if test -n "$gl_LIBOBJS"; then
24528 # Remove the extension.
24529 sed_drop_objext='s/\.o$//;s/\.obj$//'
24530 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24531 gl_libobjs="$gl_libobjs $i.$ac_objext"
24532 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
24533 done
24534 fi
24535 gl_LIBOBJS=$gl_libobjs
24536
24537 gl_LTLIBOBJS=$gl_ltlibobjs
24538
24539
24540
24541 gltests_libobjs=
24542 gltests_ltlibobjs=
24543 if test -n "$gltests_LIBOBJS"; then
24544 # Remove the extension.
24545 sed_drop_objext='s/\.o$//;s/\.obj$//'
24546 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24547 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
24548 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
24549 done
24550 fi
24551 gltests_LIBOBJS=$gltests_libobjs
24552
24553 gltests_LTLIBOBJS=$gltests_ltlibobjs
24554
24555
24556
24557 : ${CONFIG_STATUS=./config.status}
24558 ac_write_fail=0
24559 ac_clean_files_save=$ac_clean_files
24560 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24561 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
24562 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
24563 as_write_fail=0
24564 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
24565 #! $SHELL
24566 # Generated by $as_me.
24567 # Run this file to recreate the current configuration.
24568 # Compiler output produced by configure, useful for debugging
24569 # configure, is in config.log if it exists.
24570
24571 debug=false
24572 ac_cs_recheck=false
24573 ac_cs_silent=false
24574
24575 SHELL=\${CONFIG_SHELL-$SHELL}
24576 export SHELL
24577 _ASEOF
24578 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
24579 ## -------------------- ##
24580 ## M4sh Initialization. ##
24581 ## -------------------- ##
24582
24583 # Be more Bourne compatible
24584 DUALCASE=1; export DUALCASE # for MKS sh
24585 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24586 emulate sh
24587 NULLCMD=:
24588 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
24589 # is contrary to our usage. Disable this feature.
24590 alias -g '${1+"$@"}'='"$@"'
24591 setopt NO_GLOB_SUBST
24592 else
24593 case `(set -o) 2>/dev/null` in #(
24594 *posix*) :
24595 set -o posix ;; #(
24596 *) :
24597 ;;
24598 esac
24599 fi
24600
24601
24602 as_nl='
24603 '
24604 export as_nl
24605 # Printing a long string crashes Solaris 7 /usr/bin/printf.
24606 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
24607 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
24608 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
24609 # Prefer a ksh shell builtin over an external printf program on Solaris,
24610 # but without wasting forks for bash or zsh.
24611 if test -z "$BASH_VERSION$ZSH_VERSION" \
24612 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
24613 as_echo='print -r --'
24614 as_echo_n='print -rn --'
24615 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
24616 as_echo='printf %s\n'
24617 as_echo_n='printf %s'
24618 else
24619 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
24620 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
24621 as_echo_n='/usr/ucb/echo -n'
24622 else
24623 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
24624 as_echo_n_body='eval
24625 arg=$1;
24626 case $arg in #(
24627 *"$as_nl"*)
24628 expr "X$arg" : "X\\(.*\\)$as_nl";
24629 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
24630 esac;
24631 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
24632 '
24633 export as_echo_n_body
24634 as_echo_n='sh -c $as_echo_n_body as_echo'
24635 fi
24636 export as_echo_body
24637 as_echo='sh -c $as_echo_body as_echo'
24638 fi
24639
24640 # The user is always right.
24641 if test "${PATH_SEPARATOR+set}" != set; then
24642 PATH_SEPARATOR=:
24643 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
24644 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
24645 PATH_SEPARATOR=';'
24646 }
24647 fi
24648
24649
24650 # IFS
24651 # We need space, tab and new line, in precisely that order. Quoting is
24652 # there to prevent editors from complaining about space-tab.
24653 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
24654 # splitting by setting IFS to empty value.)
24655 IFS=" "" $as_nl"
24656
24657 # Find who we are. Look in the path if we contain no directory separator.
24658 case $0 in #((
24659 *[\\/]* ) as_myself=$0 ;;
24660 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24661 for as_dir in $PATH
24662 do
24663 IFS=$as_save_IFS
24664 test -z "$as_dir" && as_dir=.
24665 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
24666 done
24667 IFS=$as_save_IFS
24668
24669 ;;
24670 esac
24671 # We did not find ourselves, most probably we were run as `sh COMMAND'
24672 # in which case we are not to be found in the path.
24673 if test "x$as_myself" = x; then
24674 as_myself=$0
24675 fi
24676 if test ! -f "$as_myself"; then
24677 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
24678 exit 1
24679 fi
24680
24681 # Unset variables that we do not need and which cause bugs (e.g. in
24682 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
24683 # suppresses any "Segmentation fault" message there. '((' could
24684 # trigger a bug in pdksh 5.2.14.
24685 for as_var in BASH_ENV ENV MAIL MAILPATH
24686 do eval test x\${$as_var+set} = xset \
24687 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
24688 done
24689 PS1='$ '
24690 PS2='> '
24691 PS4='+ '
24692
24693 # NLS nuisances.
24694 LC_ALL=C
24695 export LC_ALL
24696 LANGUAGE=C
24697 export LANGUAGE
24698
24699 # CDPATH.
24700 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
24701
24702
24703 # as_fn_error ERROR [LINENO LOG_FD]
24704 # ---------------------------------
24705 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
24706 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
24707 # script with status $?, using 1 if that was 0.
24708 as_fn_error ()
24709 {
24710 as_status=$?; test $as_status -eq 0 && as_status=1
24711 if test "$3"; then
24712 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
24713 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
24714 fi
24715 $as_echo "$as_me: error: $1" >&2
24716 as_fn_exit $as_status
24717 } # as_fn_error
24718
24719
24720 # as_fn_set_status STATUS
24721 # -----------------------
24722 # Set $? to STATUS, without forking.
24723 as_fn_set_status ()
24724 {
24725 return $1
24726 } # as_fn_set_status
24727
24728 # as_fn_exit STATUS
24729 # -----------------
24730 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
24731 as_fn_exit ()
24732 {
24733 set +e
24734 as_fn_set_status $1
24735 exit $1
24736 } # as_fn_exit
24737
24738 # as_fn_unset VAR
24739 # ---------------
24740 # Portably unset VAR.
24741 as_fn_unset ()
24742 {
24743 { eval $1=; unset $1;}
24744 }
24745 as_unset=as_fn_unset
24746 # as_fn_append VAR VALUE
24747 # ----------------------
24748 # Append the text in VALUE to the end of the definition contained in VAR. Take
24749 # advantage of any shell optimizations that allow amortized linear growth over
24750 # repeated appends, instead of the typical quadratic growth present in naive
24751 # implementations.
24752 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
24753 eval 'as_fn_append ()
24754 {
24755 eval $1+=\$2
24756 }'
24757 else
24758 as_fn_append ()
24759 {
24760 eval $1=\$$1\$2
24761 }
24762 fi # as_fn_append
24763
24764 # as_fn_arith ARG...
24765 # ------------------
24766 # Perform arithmetic evaluation on the ARGs, and store the result in the
24767 # global $as_val. Take advantage of shells that can avoid forks. The arguments
24768 # must be portable across $(()) and expr.
24769 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
24770 eval 'as_fn_arith ()
24771 {
24772 as_val=$(( $* ))
24773 }'
24774 else
24775 as_fn_arith ()
24776 {
24777 as_val=`expr "$@" || test $? -eq 1`
24778 }
24779 fi # as_fn_arith
24780
24781
24782 if expr a : '\(a\)' >/dev/null 2>&1 &&
24783 test "X`expr 00001 : '.*\(...\)'`" = X001; then
24784 as_expr=expr
24785 else
24786 as_expr=false
24787 fi
24788
24789 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
24790 as_basename=basename
24791 else
24792 as_basename=false
24793 fi
24794
24795 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
24796 as_dirname=dirname
24797 else
24798 as_dirname=false
24799 fi
24800
24801 as_me=`$as_basename -- "$0" ||
24802 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
24803 X"$0" : 'X\(//\)$' \| \
24804 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
24805 $as_echo X/"$0" |
24806 sed '/^.*\/\([^/][^/]*\)\/*$/{
24807 s//\1/
24808 q
24809 }
24810 /^X\/\(\/\/\)$/{
24811 s//\1/
24812 q
24813 }
24814 /^X\/\(\/\).*/{
24815 s//\1/
24816 q
24817 }
24818 s/.*/./; q'`
24819
24820 # Avoid depending upon Character Ranges.
24821 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
24822 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
24823 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
24824 as_cr_digits='0123456789'
24825 as_cr_alnum=$as_cr_Letters$as_cr_digits
24826
24827 ECHO_C= ECHO_N= ECHO_T=
24828 case `echo -n x` in #(((((
24829 -n*)
24830 case `echo 'xy\c'` in
24831 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
24832 xy) ECHO_C='\c';;
24833 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
24834 ECHO_T=' ';;
24835 esac;;
24836 *)
24837 ECHO_N='-n';;
24838 esac
24839
24840 rm -f conf$$ conf$$.exe conf$$.file
24841 if test -d conf$$.dir; then
24842 rm -f conf$$.dir/conf$$.file
24843 else
24844 rm -f conf$$.dir
24845 mkdir conf$$.dir 2>/dev/null
24846 fi
24847 if (echo >conf$$.file) 2>/dev/null; then
24848 if ln -s conf$$.file conf$$ 2>/dev/null; then
24849 as_ln_s='ln -s'
24850 # ... but there are two gotchas:
24851 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
24852 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
24853 # In both cases, we have to default to `cp -p'.
24854 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
24855 as_ln_s='cp -p'
24856 elif ln conf$$.file conf$$ 2>/dev/null; then
24857 as_ln_s=ln
24858 else
24859 as_ln_s='cp -p'
24860 fi
24861 else
24862 as_ln_s='cp -p'
24863 fi
24864 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
24865 rmdir conf$$.dir 2>/dev/null
24866
24867
24868 # as_fn_mkdir_p
24869 # -------------
24870 # Create "$as_dir" as a directory, including parents if necessary.
24871 as_fn_mkdir_p ()
24872 {
24873
24874 case $as_dir in #(
24875 -*) as_dir=./$as_dir;;
24876 esac
24877 test -d "$as_dir" || eval $as_mkdir_p || {
24878 as_dirs=
24879 while :; do
24880 case $as_dir in #(
24881 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
24882 *) as_qdir=$as_dir;;
24883 esac
24884 as_dirs="'$as_qdir' $as_dirs"
24885 as_dir=`$as_dirname -- "$as_dir" ||
24886 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24887 X"$as_dir" : 'X\(//\)[^/]' \| \
24888 X"$as_dir" : 'X\(//\)$' \| \
24889 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24890 $as_echo X"$as_dir" |
24891 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24892 s//\1/
24893 q
24894 }
24895 /^X\(\/\/\)[^/].*/{
24896 s//\1/
24897 q
24898 }
24899 /^X\(\/\/\)$/{
24900 s//\1/
24901 q
24902 }
24903 /^X\(\/\).*/{
24904 s//\1/
24905 q
24906 }
24907 s/.*/./; q'`
24908 test -d "$as_dir" && break
24909 done
24910 test -z "$as_dirs" || eval "mkdir $as_dirs"
24911 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
24912
24913
24914 } # as_fn_mkdir_p
24915 if mkdir -p . 2>/dev/null; then
24916 as_mkdir_p='mkdir -p "$as_dir"'
24917 else
24918 test -d ./-p && rmdir ./-p
24919 as_mkdir_p=false
24920 fi
24921
24922 if test -x / >/dev/null 2>&1; then
24923 as_test_x='test -x'
24924 else
24925 if ls -dL / >/dev/null 2>&1; then
24926 as_ls_L_option=L
24927 else
24928 as_ls_L_option=
24929 fi
24930 as_test_x='
24931 eval sh -c '\''
24932 if test -d "$1"; then
24933 test -d "$1/.";
24934 else
24935 case $1 in #(
24936 -*)set "./$1";;
24937 esac;
24938 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
24939 ???[sx]*):;;*)false;;esac;fi
24940 '\'' sh
24941 '
24942 fi
24943 as_executable_p=$as_test_x
24944
24945 # Sed expression to map a string onto a valid CPP name.
24946 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
24947
24948 # Sed expression to map a string onto a valid variable name.
24949 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
24950
24951
24952 exec 6>&1
24953 ## ----------------------------------- ##
24954 ## Main body of $CONFIG_STATUS script. ##
24955 ## ----------------------------------- ##
24956 _ASEOF
24957 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
24958
24959 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24960 # Save the log message, to keep $0 and so on meaningful, and to
24961 # report actual input values of CONFIG_FILES etc. instead of their
24962 # values after options handling.
24963 ac_log="
24964 This file was extended by emacs $as_me 24.2.50, which was
24965 generated by GNU Autoconf 2.65. Invocation command line was
24966
24967 CONFIG_FILES = $CONFIG_FILES
24968 CONFIG_HEADERS = $CONFIG_HEADERS
24969 CONFIG_LINKS = $CONFIG_LINKS
24970 CONFIG_COMMANDS = $CONFIG_COMMANDS
24971 $ $0 $@
24972
24973 on `(hostname || uname -n) 2>/dev/null | sed 1q`
24974 "
24975
24976 _ACEOF
24977
24978 case $ac_config_files in *"
24979 "*) set x $ac_config_files; shift; ac_config_files=$*;;
24980 esac
24981
24982 case $ac_config_headers in *"
24983 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
24984 esac
24985
24986
24987 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24988 # Files that config.status was made for.
24989 config_files="$ac_config_files"
24990 config_headers="$ac_config_headers"
24991 config_commands="$ac_config_commands"
24992
24993 _ACEOF
24994
24995 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24996 ac_cs_usage="\
24997 \`$as_me' instantiates files and other configuration actions
24998 from templates according to the current configuration. Unless the files
24999 and actions are specified as TAGs, all are instantiated by default.
25000
25001 Usage: $0 [OPTION]... [TAG]...
25002
25003 -h, --help print this help, then exit
25004 -V, --version print version number and configuration settings, then exit
25005 --config print configuration, then exit
25006 -q, --quiet, --silent
25007 do not print progress messages
25008 -d, --debug don't remove temporary files
25009 --recheck update $as_me by reconfiguring in the same conditions
25010 --file=FILE[:TEMPLATE]
25011 instantiate the configuration file FILE
25012 --header=FILE[:TEMPLATE]
25013 instantiate the configuration header FILE
25014
25015 Configuration files:
25016 $config_files
25017
25018 Configuration headers:
25019 $config_headers
25020
25021 Configuration commands:
25022 $config_commands
25023
25024 Report bugs to the package provider."
25025
25026 _ACEOF
25027 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25028 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
25029 ac_cs_version="\\
25030 emacs config.status 24.2.50
25031 configured by $0, generated by GNU Autoconf 2.65,
25032 with options \\"\$ac_cs_config\\"
25033
25034 Copyright (C) 2009 Free Software Foundation, Inc.
25035 This config.status script is free software; the Free Software Foundation
25036 gives unlimited permission to copy, distribute and modify it."
25037
25038 ac_pwd='$ac_pwd'
25039 srcdir='$srcdir'
25040 INSTALL='$INSTALL'
25041 MKDIR_P='$MKDIR_P'
25042 AWK='$AWK'
25043 test -n "\$AWK" || AWK=awk
25044 _ACEOF
25045
25046 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25047 # The default lists apply if the user does not specify any file.
25048 ac_need_defaults=:
25049 while test $# != 0
25050 do
25051 case $1 in
25052 --*=*)
25053 ac_option=`expr "X$1" : 'X\([^=]*\)='`
25054 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
25055 ac_shift=:
25056 ;;
25057 *)
25058 ac_option=$1
25059 ac_optarg=$2
25060 ac_shift=shift
25061 ;;
25062 esac
25063
25064 case $ac_option in
25065 # Handling of the options.
25066 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25067 ac_cs_recheck=: ;;
25068 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
25069 $as_echo "$ac_cs_version"; exit ;;
25070 --config | --confi | --conf | --con | --co | --c )
25071 $as_echo "$ac_cs_config"; exit ;;
25072 --debug | --debu | --deb | --de | --d | -d )
25073 debug=: ;;
25074 --file | --fil | --fi | --f )
25075 $ac_shift
25076 case $ac_optarg in
25077 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25078 esac
25079 as_fn_append CONFIG_FILES " '$ac_optarg'"
25080 ac_need_defaults=false;;
25081 --header | --heade | --head | --hea )
25082 $ac_shift
25083 case $ac_optarg in
25084 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25085 esac
25086 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
25087 ac_need_defaults=false;;
25088 --he | --h)
25089 # Conflict between --help and --header
25090 as_fn_error "ambiguous option: \`$1'
25091 Try \`$0 --help' for more information.";;
25092 --help | --hel | -h )
25093 $as_echo "$ac_cs_usage"; exit ;;
25094 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25095 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25096 ac_cs_silent=: ;;
25097
25098 # This is an error.
25099 -*) as_fn_error "unrecognized option: \`$1'
25100 Try \`$0 --help' for more information." ;;
25101
25102 *) as_fn_append ac_config_targets " $1"
25103 ac_need_defaults=false ;;
25104
25105 esac
25106 shift
25107 done
25108
25109 ac_configure_extra_args=
25110
25111 if $ac_cs_silent; then
25112 exec 6>/dev/null
25113 ac_configure_extra_args="$ac_configure_extra_args --silent"
25114 fi
25115
25116 _ACEOF
25117 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25118 if \$ac_cs_recheck; then
25119 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
25120 shift
25121 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
25122 CONFIG_SHELL='$SHELL'
25123 export CONFIG_SHELL
25124 exec "\$@"
25125 fi
25126
25127 _ACEOF
25128 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25129 exec 5>>config.log
25130 {
25131 echo
25132 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25133 ## Running $as_me. ##
25134 _ASBOX
25135 $as_echo "$ac_log"
25136 } >&5
25137
25138 _ACEOF
25139 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25140 #
25141 # INIT-COMMANDS
25142 #
25143 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
25144 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
25145
25146 _ACEOF
25147
25148 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25149
25150 # Handling of arguments.
25151 for ac_config_target in $ac_config_targets
25152 do
25153 case $ac_config_target in
25154 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
25155 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25156 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25157 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
25158 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
25159 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
25160 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
25161 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
25162 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
25163 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
25164 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
25165 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
25166 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
25167 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
25168 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
25169 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
25170 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
25171 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
25172 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
25173
25174 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25175 esac
25176 done
25177
25178
25179 # If the user did not use the arguments to specify the items to instantiate,
25180 # then the envvar interface is used. Set only those that are not.
25181 # We use the long form for the default assignment because of an extremely
25182 # bizarre bug on SunOS 4.1.3.
25183 if $ac_need_defaults; then
25184 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25185 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25186 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25187 fi
25188
25189 # Have a temporary directory for convenience. Make it in the build tree
25190 # simply because there is no reason against having it here, and in addition,
25191 # creating and moving files from /tmp can sometimes cause problems.
25192 # Hook for its removal unless debugging.
25193 # Note that there is a small window in which the directory will not be cleaned:
25194 # after its creation but before its name has been assigned to `$tmp'.
25195 $debug ||
25196 {
25197 tmp=
25198 trap 'exit_status=$?
25199 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25200 ' 0
25201 trap 'as_fn_exit 1' 1 2 13 15
25202 }
25203 # Create a (secure) tmp directory for tmp files.
25204
25205 {
25206 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25207 test -n "$tmp" && test -d "$tmp"
25208 } ||
25209 {
25210 tmp=./conf$$-$RANDOM
25211 (umask 077 && mkdir "$tmp")
25212 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25213
25214 # Set up the scripts for CONFIG_FILES section.
25215 # No need to generate them if there are no CONFIG_FILES.
25216 # This happens for instance with `./config.status config.h'.
25217 if test -n "$CONFIG_FILES"; then
25218
25219 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
25220 ac_cs_awk_getline=:
25221 ac_cs_awk_pipe_init=
25222 ac_cs_awk_read_file='
25223 while ((getline aline < (F[key])) > 0)
25224 print(aline)
25225 close(F[key])'
25226 ac_cs_awk_pipe_fini=
25227 else
25228 ac_cs_awk_getline=false
25229 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
25230 ac_cs_awk_read_file='
25231 print "|#_!!_#|"
25232 print "cat " F[key] " &&"
25233 '$ac_cs_awk_pipe_init
25234 # The final `:' finishes the AND list.
25235 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
25236 fi
25237 ac_cr=`echo X | tr X '\015'`
25238 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25239 # But we know of no other shell where ac_cr would be empty at this
25240 # point, so we can use a bashism as a fallback.
25241 if test "x$ac_cr" = x; then
25242 eval ac_cr=\$\'\\r\'
25243 fi
25244 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25245 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25246 ac_cs_awk_cr='\r'
25247 else
25248 ac_cs_awk_cr=$ac_cr
25249 fi
25250
25251 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25252 _ACEOF
25253
25254 # Create commands to substitute file output variables.
25255 {
25256 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
25257 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
25258 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
25259 echo "_ACAWK" &&
25260 echo "_ACEOF"
25261 } >conf$$files.sh &&
25262 . ./conf$$files.sh ||
25263 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25264 rm -f conf$$files.sh
25265
25266 {
25267 echo "cat >conf$$subs.awk <<_ACEOF" &&
25268 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25269 echo "_ACEOF"
25270 } >conf$$subs.sh ||
25271 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25272 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25273 ac_delim='%!_!# '
25274 for ac_last_try in false false false false false :; do
25275 . ./conf$$subs.sh ||
25276 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25277
25278 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25279 if test $ac_delim_n = $ac_delim_num; then
25280 break
25281 elif $ac_last_try; then
25282 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25283 else
25284 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25285 fi
25286 done
25287 rm -f conf$$subs.sh
25288
25289 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25290 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25291 _ACEOF
25292 sed -n '
25293 h
25294 s/^/S["/; s/!.*/"]=/
25295 p
25296 g
25297 s/^[^!]*!//
25298 :repl
25299 t repl
25300 s/'"$ac_delim"'$//
25301 t delim
25302 :nl
25303 h
25304 s/\(.\{148\}\)..*/\1/
25305 t more1
25306 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25307 p
25308 n
25309 b repl
25310 :more1
25311 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25312 p
25313 g
25314 s/.\{148\}//
25315 t nl
25316 :delim
25317 h
25318 s/\(.\{148\}\)..*/\1/
25319 t more2
25320 s/["\\]/\\&/g; s/^/"/; s/$/"/
25321 p
25322 b
25323 :more2
25324 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25325 p
25326 g
25327 s/.\{148\}//
25328 t delim
25329 ' <conf$$subs.awk | sed '
25330 /^[^""]/{
25331 N
25332 s/\n//
25333 }
25334 ' >>$CONFIG_STATUS || ac_write_fail=1
25335 rm -f conf$$subs.awk
25336 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25337 _ACAWK
25338 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25339 for (key in S) S_is_set[key] = 1
25340 FS = "\a"
25341 \$ac_cs_awk_pipe_init
25342 }
25343 {
25344 line = $ 0
25345 nfields = split(line, field, "@")
25346 substed = 0
25347 len = length(field[1])
25348 for (i = 2; i < nfields; i++) {
25349 key = field[i]
25350 keylen = length(key)
25351 if (S_is_set[key]) {
25352 value = S[key]
25353 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25354 len += length(value) + length(field[++i])
25355 substed = 1
25356 } else
25357 len += 1 + keylen
25358 }
25359 if (nfields == 3 && !substed) {
25360 key = field[2]
25361 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
25362 \$ac_cs_awk_read_file
25363 next
25364 }
25365 }
25366 print line
25367 }
25368 \$ac_cs_awk_pipe_fini
25369 _ACAWK
25370 _ACEOF
25371 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25372 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25373 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25374 else
25375 cat
25376 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25377 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25378 _ACEOF
25379
25380 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25381 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25382 # trailing colons and then remove the whole line if VPATH becomes empty
25383 # (actually we leave an empty line to preserve line numbers).
25384 if test "x$srcdir" = x.; then
25385 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25386 s/:*\$(srcdir):*/:/
25387 s/:*\${srcdir}:*/:/
25388 s/:*@srcdir@:*/:/
25389 s/^\([^=]*=[ ]*\):*/\1/
25390 s/:*$//
25391 s/^[^=]*=[ ]*$//
25392 }'
25393 fi
25394
25395 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25396 fi # test -n "$CONFIG_FILES"
25397
25398 # Set up the scripts for CONFIG_HEADERS section.
25399 # No need to generate them if there are no CONFIG_HEADERS.
25400 # This happens for instance with `./config.status Makefile'.
25401 if test -n "$CONFIG_HEADERS"; then
25402 cat >"$tmp/defines.awk" <<\_ACAWK ||
25403 BEGIN {
25404 _ACEOF
25405
25406 # Transform confdefs.h into an awk script `defines.awk', embedded as
25407 # here-document in config.status, that substitutes the proper values into
25408 # config.h.in to produce config.h.
25409
25410 # Create a delimiter string that does not exist in confdefs.h, to ease
25411 # handling of long lines.
25412 ac_delim='%!_!# '
25413 for ac_last_try in false false :; do
25414 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25415 if test -z "$ac_t"; then
25416 break
25417 elif $ac_last_try; then
25418 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25419 else
25420 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25421 fi
25422 done
25423
25424 # For the awk script, D is an array of macro values keyed by name,
25425 # likewise P contains macro parameters if any. Preserve backslash
25426 # newline sequences.
25427
25428 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25429 sed -n '
25430 s/.\{148\}/&'"$ac_delim"'/g
25431 t rset
25432 :rset
25433 s/^[ ]*#[ ]*define[ ][ ]*/ /
25434 t def
25435 d
25436 :def
25437 s/\\$//
25438 t bsnl
25439 s/["\\]/\\&/g
25440 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25441 D["\1"]=" \3"/p
25442 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25443 d
25444 :bsnl
25445 s/["\\]/\\&/g
25446 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25447 D["\1"]=" \3\\\\\\n"\\/p
25448 t cont
25449 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25450 t cont
25451 d
25452 :cont
25453 n
25454 s/.\{148\}/&'"$ac_delim"'/g
25455 t clear
25456 :clear
25457 s/\\$//
25458 t bsnlc
25459 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25460 d
25461 :bsnlc
25462 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25463 b cont
25464 ' <confdefs.h | sed '
25465 s/'"$ac_delim"'/"\\\
25466 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25467
25468 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25469 for (key in D) D_is_set[key] = 1
25470 FS = "\a"
25471 }
25472 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25473 line = \$ 0
25474 split(line, arg, " ")
25475 if (arg[1] == "#") {
25476 defundef = arg[2]
25477 mac1 = arg[3]
25478 } else {
25479 defundef = substr(arg[1], 2)
25480 mac1 = arg[2]
25481 }
25482 split(mac1, mac2, "(") #)
25483 macro = mac2[1]
25484 prefix = substr(line, 1, index(line, defundef) - 1)
25485 if (D_is_set[macro]) {
25486 # Preserve the white space surrounding the "#".
25487 print prefix "define", macro P[macro] D[macro]
25488 next
25489 } else {
25490 # Replace #undef with comments. This is necessary, for example,
25491 # in the case of _POSIX_SOURCE, which is predefined and required
25492 # on some systems where configure will not decide to define it.
25493 if (defundef == "undef") {
25494 print "/*", prefix defundef, macro, "*/"
25495 next
25496 }
25497 }
25498 }
25499 { print }
25500 _ACAWK
25501 _ACEOF
25502 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25503 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25504 fi # test -n "$CONFIG_HEADERS"
25505
25506
25507 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25508 shift
25509 for ac_tag
25510 do
25511 case $ac_tag in
25512 :[FHLC]) ac_mode=$ac_tag; continue;;
25513 esac
25514 case $ac_mode$ac_tag in
25515 :[FHL]*:*);;
25516 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25517 :[FH]-) ac_tag=-:-;;
25518 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25519 esac
25520 ac_save_IFS=$IFS
25521 IFS=:
25522 set x $ac_tag
25523 IFS=$ac_save_IFS
25524 shift
25525 ac_file=$1
25526 shift
25527
25528 case $ac_mode in
25529 :L) ac_source=$1;;
25530 :[FH])
25531 ac_file_inputs=
25532 for ac_f
25533 do
25534 case $ac_f in
25535 -) ac_f="$tmp/stdin";;
25536 *) # Look for the file first in the build tree, then in the source tree
25537 # (if the path is not absolute). The absolute path cannot be DOS-style,
25538 # because $ac_f cannot contain `:'.
25539 test -f "$ac_f" ||
25540 case $ac_f in
25541 [\\/$]*) false;;
25542 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
25543 esac ||
25544 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
25545 esac
25546 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
25547 as_fn_append ac_file_inputs " '$ac_f'"
25548 done
25549
25550 # Let's still pretend it is `configure' which instantiates (i.e., don't
25551 # use $as_me), people would be surprised to read:
25552 # /* config.h. Generated by config.status. */
25553 configure_input='Generated from '`
25554 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
25555 `' by configure.'
25556 if test x"$ac_file" != x-; then
25557 configure_input="$ac_file. $configure_input"
25558 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
25559 $as_echo "$as_me: creating $ac_file" >&6;}
25560 fi
25561 # Neutralize special characters interpreted by sed in replacement strings.
25562 case $configure_input in #(
25563 *\&* | *\|* | *\\* )
25564 ac_sed_conf_input=`$as_echo "$configure_input" |
25565 sed 's/[\\\\&|]/\\\\&/g'`;; #(
25566 *) ac_sed_conf_input=$configure_input;;
25567 esac
25568
25569 case $ac_tag in
25570 *:-:* | *:-) cat >"$tmp/stdin" \
25571 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
25572 esac
25573 ;;
25574 esac
25575
25576 ac_dir=`$as_dirname -- "$ac_file" ||
25577 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25578 X"$ac_file" : 'X\(//\)[^/]' \| \
25579 X"$ac_file" : 'X\(//\)$' \| \
25580 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
25581 $as_echo X"$ac_file" |
25582 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25583 s//\1/
25584 q
25585 }
25586 /^X\(\/\/\)[^/].*/{
25587 s//\1/
25588 q
25589 }
25590 /^X\(\/\/\)$/{
25591 s//\1/
25592 q
25593 }
25594 /^X\(\/\).*/{
25595 s//\1/
25596 q
25597 }
25598 s/.*/./; q'`
25599 as_dir="$ac_dir"; as_fn_mkdir_p
25600 ac_builddir=.
25601
25602 case "$ac_dir" in
25603 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
25604 *)
25605 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
25606 # A ".." for each directory in $ac_dir_suffix.
25607 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
25608 case $ac_top_builddir_sub in
25609 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
25610 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
25611 esac ;;
25612 esac
25613 ac_abs_top_builddir=$ac_pwd
25614 ac_abs_builddir=$ac_pwd$ac_dir_suffix
25615 # for backward compatibility:
25616 ac_top_builddir=$ac_top_build_prefix
25617
25618 case $srcdir in
25619 .) # We are building in place.
25620 ac_srcdir=.
25621 ac_top_srcdir=$ac_top_builddir_sub
25622 ac_abs_top_srcdir=$ac_pwd ;;
25623 [\\/]* | ?:[\\/]* ) # Absolute name.
25624 ac_srcdir=$srcdir$ac_dir_suffix;
25625 ac_top_srcdir=$srcdir
25626 ac_abs_top_srcdir=$srcdir ;;
25627 *) # Relative name.
25628 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
25629 ac_top_srcdir=$ac_top_build_prefix$srcdir
25630 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
25631 esac
25632 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
25633
25634
25635 case $ac_mode in
25636 :F)
25637 #
25638 # CONFIG_FILE
25639 #
25640
25641 case $INSTALL in
25642 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
25643 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
25644 esac
25645 ac_MKDIR_P=$MKDIR_P
25646 case $MKDIR_P in
25647 [\\/$]* | ?:[\\/]* ) ;;
25648 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
25649 esac
25650 _ACEOF
25651
25652 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25653 # If the template does not know about datarootdir, expand it.
25654 # FIXME: This hack should be removed a few years after 2.60.
25655 ac_datarootdir_hack=; ac_datarootdir_seen=
25656 ac_sed_dataroot='
25657 /datarootdir/ {
25658 p
25659 q
25660 }
25661 /@datadir@/p
25662 /@docdir@/p
25663 /@infodir@/p
25664 /@localedir@/p
25665 /@mandir@/p'
25666 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
25667 *datarootdir*) ac_datarootdir_seen=yes;;
25668 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
25669 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
25670 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
25671 _ACEOF
25672 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25673 ac_datarootdir_hack='
25674 s&@datadir@&$datadir&g
25675 s&@docdir@&$docdir&g
25676 s&@infodir@&$infodir&g
25677 s&@localedir@&$localedir&g
25678 s&@mandir@&$mandir&g
25679 s&\\\${datarootdir}&$datarootdir&g' ;;
25680 esac
25681 _ACEOF
25682
25683 # Neutralize VPATH when `$srcdir' = `.'.
25684 # Shell code in configure.ac might set extrasub.
25685 # FIXME: do we really want to maintain this feature?
25686 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25687 ac_sed_extra="$ac_vpsub
25688 $extrasub
25689 _ACEOF
25690 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25691 :t
25692 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
25693 s|@configure_input@|$ac_sed_conf_input|;t t
25694 s&@top_builddir@&$ac_top_builddir_sub&;t t
25695 s&@top_build_prefix@&$ac_top_build_prefix&;t t
25696 s&@srcdir@&$ac_srcdir&;t t
25697 s&@abs_srcdir@&$ac_abs_srcdir&;t t
25698 s&@top_srcdir@&$ac_top_srcdir&;t t
25699 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
25700 s&@builddir@&$ac_builddir&;t t
25701 s&@abs_builddir@&$ac_abs_builddir&;t t
25702 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
25703 s&@INSTALL@&$ac_INSTALL&;t t
25704 s&@MKDIR_P@&$ac_MKDIR_P&;t t
25705 $ac_datarootdir_hack
25706 "
25707 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
25708 if $ac_cs_awk_getline; then
25709 $AWK -f "$tmp/subs.awk"
25710 else
25711 $AWK -f "$tmp/subs.awk" | $SHELL
25712 fi >$tmp/out \
25713 || as_fn_error "could not create $ac_file" "$LINENO" 5
25714
25715 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
25716 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
25717 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
25718 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25719 which seems to be undefined. Please make sure it is defined." >&5
25720 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25721 which seems to be undefined. Please make sure it is defined." >&2;}
25722
25723 rm -f "$tmp/stdin"
25724 case $ac_file in
25725 -) cat "$tmp/out" && rm -f "$tmp/out";;
25726 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
25727 esac \
25728 || as_fn_error "could not create $ac_file" "$LINENO" 5
25729 ;;
25730 :H)
25731 #
25732 # CONFIG_HEADER
25733 #
25734 if test x"$ac_file" != x-; then
25735 {
25736 $as_echo "/* $configure_input */" \
25737 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
25738 } >"$tmp/config.h" \
25739 || as_fn_error "could not create $ac_file" "$LINENO" 5
25740 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
25741 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
25742 $as_echo "$as_me: $ac_file is unchanged" >&6;}
25743 else
25744 rm -f "$ac_file"
25745 mv "$tmp/config.h" "$ac_file" \
25746 || as_fn_error "could not create $ac_file" "$LINENO" 5
25747 fi
25748 else
25749 $as_echo "/* $configure_input */" \
25750 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
25751 || as_fn_error "could not create -" "$LINENO" 5
25752 fi
25753 # Compute "$ac_file"'s index in $config_headers.
25754 _am_arg="$ac_file"
25755 _am_stamp_count=1
25756 for _am_header in $config_headers :; do
25757 case $_am_header in
25758 $_am_arg | $_am_arg:* )
25759 break ;;
25760 * )
25761 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
25762 esac
25763 done
25764 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
25765 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25766 X"$_am_arg" : 'X\(//\)[^/]' \| \
25767 X"$_am_arg" : 'X\(//\)$' \| \
25768 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
25769 $as_echo X"$_am_arg" |
25770 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25771 s//\1/
25772 q
25773 }
25774 /^X\(\/\/\)[^/].*/{
25775 s//\1/
25776 q
25777 }
25778 /^X\(\/\/\)$/{
25779 s//\1/
25780 q
25781 }
25782 /^X\(\/\).*/{
25783 s//\1/
25784 q
25785 }
25786 s/.*/./; q'`/stamp-h$_am_stamp_count
25787 ;;
25788
25789 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
25790 $as_echo "$as_me: executing $ac_file commands" >&6;}
25791 ;;
25792 esac
25793
25794
25795 case $ac_file$ac_mode in
25796 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
25797 # Autoconf 2.62 quotes --file arguments for eval, but not when files
25798 # are listed without --file. Let's play safe and only enable the eval
25799 # if we detect the quoting.
25800 case $CONFIG_FILES in
25801 *\'*) eval set x "$CONFIG_FILES" ;;
25802 *) set x $CONFIG_FILES ;;
25803 esac
25804 shift
25805 for mf
25806 do
25807 # Strip MF so we end up with the name of the file.
25808 mf=`echo "$mf" | sed -e 's/:.*$//'`
25809 # Check whether this is an Automake generated Makefile or not.
25810 # We used to match only the files named `Makefile.in', but
25811 # some people rename them; so instead we look at the file content.
25812 # Grep'ing the first line is not enough: some people post-process
25813 # each Makefile.in and add a new line on top of each file to say so.
25814 # Grep'ing the whole file is not good either: AIX grep has a line
25815 # limit of 2048, but all sed's we know have understand at least 4000.
25816 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
25817 dirpart=`$as_dirname -- "$mf" ||
25818 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25819 X"$mf" : 'X\(//\)[^/]' \| \
25820 X"$mf" : 'X\(//\)$' \| \
25821 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
25822 $as_echo X"$mf" |
25823 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25824 s//\1/
25825 q
25826 }
25827 /^X\(\/\/\)[^/].*/{
25828 s//\1/
25829 q
25830 }
25831 /^X\(\/\/\)$/{
25832 s//\1/
25833 q
25834 }
25835 /^X\(\/\).*/{
25836 s//\1/
25837 q
25838 }
25839 s/.*/./; q'`
25840 else
25841 continue
25842 fi
25843 # Extract the definition of DEPDIR, am__include, and am__quote
25844 # from the Makefile without running `make'.
25845 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
25846 test -z "$DEPDIR" && continue
25847 am__include=`sed -n 's/^am__include = //p' < "$mf"`
25848 test -z "am__include" && continue
25849 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
25850 # When using ansi2knr, U may be empty or an underscore; expand it
25851 U=`sed -n 's/^U = //p' < "$mf"`
25852 # Find all dependency output files, they are included files with
25853 # $(DEPDIR) in their names. We invoke sed twice because it is the
25854 # simplest approach to changing $(DEPDIR) to its actual value in the
25855 # expansion.
25856 for file in `sed -n "
25857 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
25858 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
25859 # Make sure the directory exists.
25860 test -f "$dirpart/$file" && continue
25861 fdir=`$as_dirname -- "$file" ||
25862 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25863 X"$file" : 'X\(//\)[^/]' \| \
25864 X"$file" : 'X\(//\)$' \| \
25865 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
25866 $as_echo X"$file" |
25867 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25868 s//\1/
25869 q
25870 }
25871 /^X\(\/\/\)[^/].*/{
25872 s//\1/
25873 q
25874 }
25875 /^X\(\/\/\)$/{
25876 s//\1/
25877 q
25878 }
25879 /^X\(\/\).*/{
25880 s//\1/
25881 q
25882 }
25883 s/.*/./; q'`
25884 as_dir=$dirpart/$fdir; as_fn_mkdir_p
25885 # echo "creating $dirpart/$file"
25886 echo '# dummy' > "$dirpart/$file"
25887 done
25888 done
25889 }
25890 ;;
25891 "mkdirs":C)
25892 for dir in etc lisp ; do
25893 test -d ${dir} || mkdir ${dir}
25894 done
25895 ;;
25896 "epaths":C)
25897 echo creating src/epaths.h
25898 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
25899 ;;
25900 "gdbinit":C)
25901 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
25902 echo creating src/.gdbinit
25903 echo source $srcdir/src/.gdbinit > src/.gdbinit
25904 fi
25905 ;;
25906
25907 esac
25908 done # for ac_tag
25909
25910
25911 as_fn_exit 0
25912 _ACEOF
25913 ac_clean_files=$ac_clean_files_save
25914
25915 test $ac_write_fail = 0 ||
25916 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
25917
25918
25919 # configure is writing to config.log, and then calls config.status.
25920 # config.status does its own redirection, appending to config.log.
25921 # Unfortunately, on DOS this fails, as config.log is still kept open
25922 # by configure, so config.status won't be able to write to it; its
25923 # output is simply discarded. So we exec the FD to /dev/null,
25924 # effectively closing config.log, so it can be properly (re)opened and
25925 # appended to by config.status. When coming back to configure, we
25926 # need to make the FD available again.
25927 if test "$no_create" != yes; then
25928 ac_cs_success=:
25929 ac_config_status_args=
25930 test "$silent" = yes &&
25931 ac_config_status_args="$ac_config_status_args --quiet"
25932 exec 5>/dev/null
25933 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
25934 exec 5>>config.log
25935 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
25936 # would make configure fail if this is the last instruction.
25937 $ac_cs_success || as_fn_exit $?
25938 fi
25939 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
25940 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
25941 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
25942 fi
25943